Date: Fri, 7 Jan 2022 10:38:27 -0500
Subject: [PATCH 072/733] Fix broken links (#12472)
---
docs/serving-api.md | 38 ++++++++++++++---------------
hack/reference-docs-gen-config.json | 2 +-
2 files changed, 20 insertions(+), 20 deletions(-)
diff --git a/docs/serving-api.md b/docs/serving-api.md
index 3337486c9a12..dde87fb89ee4 100644
--- a/docs/serving-api.md
+++ b/docs/serving-api.md
@@ -58,7 +58,7 @@ string
metadata
-
+
Kubernetes meta/v1.ObjectMeta
@@ -102,7 +102,7 @@ Defaults to 0 which means unlimited concurrency.
|
scaleTargetRef
-
+
Kubernetes core/v1.ObjectReference
@@ -176,7 +176,7 @@ PodAutoscalerStatus
|
metadata
-
+
Kubernetes meta/v1.ObjectMeta
@@ -380,7 +380,7 @@ Defaults to 0 which means unlimited concurrency.
|
scaleTargetRef
-
+
Kubernetes core/v1.ObjectReference
@@ -520,7 +520,7 @@ the referenced resources may take.
|
metadata
-
+
Kubernetes meta/v1.ObjectMeta
@@ -557,7 +557,7 @@ int32
|
selector
-
+
Kubernetes meta/v1.LabelSelector
@@ -569,7 +569,7 @@ Kubernetes meta/v1.LabelSelector
|
template
-
+
Kubernetes core/v1.PodTemplateSpec
@@ -625,7 +625,7 @@ int32
|
selector
-
+
Kubernetes meta/v1.LabelSelector
@@ -637,7 +637,7 @@ Kubernetes meta/v1.LabelSelector
|
template
-
+
Kubernetes core/v1.PodTemplateSpec
@@ -757,7 +757,7 @@ string
|
metadata
-
+
Kubernetes meta/v1.ObjectMeta
@@ -851,7 +851,7 @@ string
|
metadata
-
+
Kubernetes meta/v1.ObjectMeta
@@ -880,7 +880,7 @@ RevisionSpec
|
PodSpec
-
+
Kubernetes core/v1.PodSpec
@@ -990,7 +990,7 @@ string
|
metadata
-
+
Kubernetes meta/v1.ObjectMeta
@@ -1093,7 +1093,7 @@ string
|
metadata
-
+
Kubernetes meta/v1.ObjectMeta
@@ -1355,7 +1355,7 @@ string
|
PodSpec
-
+
Kubernetes core/v1.PodSpec
@@ -1539,7 +1539,7 @@ Based on:
+
Kubernetes meta/v1.ObjectMeta
@@ -1568,7 +1568,7 @@ RevisionSpec
|
PodSpec
-
+
Kubernetes core/v1.PodSpec
@@ -2085,7 +2085,7 @@ string
|
metadata
-
+
Kubernetes meta/v1.ObjectMeta
@@ -2389,7 +2389,7 @@ string
|
metadata
-
+
Kubernetes meta/v1.ObjectMeta
diff --git a/hack/reference-docs-gen-config.json b/hack/reference-docs-gen-config.json
index 8bed9223023c..1cf8db3503c6 100644
--- a/hack/reference-docs-gen-config.json
+++ b/hack/reference-docs-gen-config.json
@@ -13,7 +13,7 @@
},
{
"typeMatchPrefix": "^k8s\\.io/(api|apimachinery/pkg/apis)/",
- "docsURLTemplate": "https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.18/#{{lower .TypeIdentifier}}-{{arrIndex .PackageSegments -1}}-{{arrIndex .PackageSegments -2}}"
+ "docsURLTemplate": "https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.21/#{{lower .TypeIdentifier}}-{{arrIndex .PackageSegments -1}}-{{arrIndex .PackageSegments -2}}"
},
{
"typeMatchPrefix": "^knative\\.dev/pkg/apis/duck",
From 03091748d2795f7bbdd79477c97ff69ef960bf51 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Fri, 7 Jan 2022 09:01:25 -0800
Subject: [PATCH 073/733] upgrade to latest dependencies (#12481)
bumping knative.dev/networking e40187c...0dbedcd:
> 0dbedcd upgrade to latest dependencies (# 598)
Signed-off-by: Knative Automation
---
go.mod | 2 +-
go.sum | 14 ++------------
.../versioned/fake/clientset_generated.go | 5 ++++-
vendor/modules.txt | 2 +-
4 files changed, 8 insertions(+), 15 deletions(-)
diff --git a/go.mod b/go.mod
index 3b62b497a44d..c3e5cf7fd5ab 100644
--- a/go.mod
+++ b/go.mod
@@ -38,7 +38,7 @@ require (
k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c
knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6
knative.dev/hack v0.0.0-20211222071919-abd085fc43de
- knative.dev/networking v0.0.0-20211223134928-e40187c3026d
+ knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf
knative.dev/pkg v0.0.0-20220105211333-96f18522d78d
sigs.k8s.io/yaml v1.3.0
)
diff --git a/go.sum b/go.sum
index 1406ecda2dc4..b57e348e5899 100644
--- a/go.sum
+++ b/go.sum
@@ -1078,7 +1078,6 @@ golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzB
golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
-golang.org/x/mod v0.3.1-0.20200828183125-ce943fd02449/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
@@ -1143,7 +1142,6 @@ golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qx
golang.org/x/net v0.0.0-20210917221730-978cfadd31cf/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
-golang.org/x/net v0.0.0-20211205041911-012df41ee64c/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211209124913-491a49abca63 h1:iocB37TsdFuN6IBRZ+ry36wrkoV51/tl5vOWqkcPGvY=
golang.org/x/net v0.0.0-20211209124913-491a49abca63/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
@@ -1597,10 +1595,8 @@ k8s.io/api v0.20.4/go.mod h1:++lNL1AJMkDymriNniQsWRkMDzRaX2Y/POTUi8yvqYQ=
k8s.io/api v0.20.6/go.mod h1:X9e8Qag6JV/bL5G6bU8sdVRltWKmdHsFUGS3eVndqE8=
k8s.io/api v0.21.0/go.mod h1:+YbrhBBGgsxbF6o6Kj4KJPJnBmAKuXDeS3E18bgHNVU=
k8s.io/api v0.21.1/go.mod h1:FstGROTmsSHBarKc8bylzXih8BLNYTiS3TZcsoEDg2s=
-k8s.io/api v0.21.4/go.mod h1:fTVGP+M4D8+00FN2cMnJqk/eb/GH53bvmNs2SVTmpFk=
k8s.io/api v0.22.5 h1:xk7C+rMjF/EGELiD560jdmwzrB788mfcHiNbMQLIVI8=
k8s.io/api v0.22.5/go.mod h1:mEhXyLaSD1qTOf40rRiKXkc+2iCem09rWLlFwhCEiAs=
-k8s.io/apiextensions-apiserver v0.21.4/go.mod h1:OoC8LhI9LnV+wKjZkXIBbLUwtnOGJiTRE33qctH5CIk=
k8s.io/apiextensions-apiserver v0.22.5 h1:ML0QqT7FIlmZHN+9+2EtARJ3cJVHeoizt6GCteFRE0o=
k8s.io/apiextensions-apiserver v0.22.5/go.mod h1:tIXeZ0BrDxUb1PoAz+tgOz43Zi1Bp4BEEqVtUccMJbE=
k8s.io/apimachinery v0.20.1/go.mod h1:WlLqWAHZGg07AeltaI0MV5uk1Omp8xaN0JGLY6gkRpU=
@@ -1608,33 +1604,28 @@ k8s.io/apimachinery v0.20.4/go.mod h1:WlLqWAHZGg07AeltaI0MV5uk1Omp8xaN0JGLY6gkRp
k8s.io/apimachinery v0.20.6/go.mod h1:ejZXtW1Ra6V1O5H8xPBGz+T3+4gfkTCeExAHKU57MAc=
k8s.io/apimachinery v0.21.0/go.mod h1:jbreFvJo3ov9rj7eWT7+sYiRx+qZuCYXwWT1bcDswPY=
k8s.io/apimachinery v0.21.1/go.mod h1:jbreFvJo3ov9rj7eWT7+sYiRx+qZuCYXwWT1bcDswPY=
-k8s.io/apimachinery v0.21.4/go.mod h1:H/IM+5vH9kZRNJ4l3x/fXP/5bOPJaVP/guptnZPeCFI=
k8s.io/apimachinery v0.22.5 h1:cIPwldOYm1Slq9VLBRPtEYpyhjIm1C6aAMAoENuvN9s=
k8s.io/apimachinery v0.22.5/go.mod h1:xziclGKwuuJ2RM5/rSFQSYAj0zdbci3DH8kj+WvyN0U=
k8s.io/apiserver v0.20.1/go.mod h1:ro5QHeQkgMS7ZGpvf4tSMx6bBOgPfE+f52KwvXfScaU=
k8s.io/apiserver v0.20.4/go.mod h1:Mc80thBKOyy7tbvFtB4kJv1kbdD0eIH8k8vianJcbFM=
k8s.io/apiserver v0.20.6/go.mod h1:QIJXNt6i6JB+0YQRNcS0hdRHJlMhflFmsBDeSgT1r8Q=
k8s.io/apiserver v0.21.0/go.mod h1:w2YSn4/WIwYuxG5zJmcqtRdtqgW/J2JRgFAqps3bBpg=
-k8s.io/apiserver v0.21.4/go.mod h1:SErUuFBBPZUcD2nsUU8hItxoYheqyYr2o/pCINEPW8g=
k8s.io/apiserver v0.22.5/go.mod h1:s2WbtgZAkTKt679sYtSudEQrTGWUSQAPe6MupLnlmaQ=
k8s.io/client-go v0.20.1/go.mod h1:/zcHdt1TeWSd5HoUe6elJmHSQ6uLLgp4bIJHVEuy+/Y=
k8s.io/client-go v0.20.4/go.mod h1:LiMv25ND1gLUdBeYxBIwKpkSC5IsozMMmOOeSJboP+k=
k8s.io/client-go v0.20.6/go.mod h1:nNQMnOvEUEsOzRRFIIkdmYOjAZrC8bgq0ExboWSU1I0=
k8s.io/client-go v0.21.0/go.mod h1:nNBytTF9qPFDEhoqgEPaarobC8QPae13bElIVHzIglA=
k8s.io/client-go v0.21.1/go.mod h1:/kEw4RgW+3xnBGzvp9IWxKSNA+lXn3A7AuH3gdOAzLs=
-k8s.io/client-go v0.21.4/go.mod h1:t0/eMKyUAq/DoQ7vW8NVVA00/nomlwC+eInsS8PxSew=
k8s.io/client-go v0.22.5 h1:I8Zn/UqIdi2r02aZmhaJ1hqMxcpfJ3t5VqvHtctHYFo=
k8s.io/client-go v0.22.5/go.mod h1:cs6yf/61q2T1SdQL5Rdcjg9J1ElXSwbjSrW2vFImM4Y=
k8s.io/cloud-provider v0.21.0 h1:NSTS+czpv6LQAaIpY/VUghsT4oj62hYmQPErkDKTzKU=
k8s.io/cloud-provider v0.21.0/go.mod h1:z17TQgu3JgUFjcgby8sj5X86YdVK5Pbt+jm/eYMZU9M=
-k8s.io/code-generator v0.21.4/go.mod h1:K3y0Bv9Cz2cOW2vXUrNZlFbflhuPvuadW6JdnN6gGKo=
k8s.io/code-generator v0.22.5 h1:jn+mYXI5q7rzo7Bz/n8xZIgbe61SeXlIjU5jA8jLVps=
k8s.io/code-generator v0.22.5/go.mod h1:sbdWCOVob+KaQ5O7xs8PNNaCTpbWVqNgA6EPwLOmRNk=
k8s.io/component-base v0.20.1/go.mod h1:guxkoJnNoh8LNrbtiQOlyp2Y2XFCZQmrcg2n/DeYNLk=
k8s.io/component-base v0.20.4/go.mod h1:t4p9EdiagbVCJKrQ1RsA5/V4rFQNDfRlevJajlGwgjI=
k8s.io/component-base v0.20.6/go.mod h1:6f1MPBAeI+mvuts3sIdtpjljHWBQ2cIy38oBIWMYnrM=
k8s.io/component-base v0.21.0/go.mod h1:qvtjz6X0USWXbgmbfXR+Agik4RZ3jv2Bgr5QnZzdPYw=
-k8s.io/component-base v0.21.4/go.mod h1:ZKG0eHVX+tUDcaoIGpU3Vtk4TIjMddN9uhEWDmW6Nyg=
k8s.io/component-base v0.22.5 h1:U0eHqZm7mAFE42hFwYhY6ze/MmVaW00JpMrzVsQmzYE=
k8s.io/component-base v0.22.5/go.mod h1:VK3I+TjuF9eaa+Ln67dKxhGar5ynVbwnGrUiNF4MqCI=
k8s.io/controller-manager v0.21.0/go.mod h1:Ohy0GRNRKPVjB8C8G+dV+4aPn26m8HYUI6ejloUBvUA=
@@ -1672,9 +1663,8 @@ knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6/go.mod h1:SgmDCiZNxriP5d1
knative.dev/hack v0.0.0-20211203062838-e11ac125e707/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/hack v0.0.0-20211222071919-abd085fc43de h1:K7UeyvIfdTjznffAZg2L4fDkOuFWEDiaxgEa+B33nP8=
knative.dev/hack v0.0.0-20211222071919-abd085fc43de/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/networking v0.0.0-20211223134928-e40187c3026d h1:P7hiubMdWREI+vwKcGNCq10jauwkBOUwqNk0WXWXhkA=
-knative.dev/networking v0.0.0-20211223134928-e40187c3026d/go.mod h1:NTfJpL2xQVdJtdPYuIE2j7rxC4/Cttplh1g0oYqQJFE=
-knative.dev/pkg v0.0.0-20211216142117-79271798f696/go.mod h1:hrD91/shO1o4KMZa4oWhnbRPmVJhvq86TLy/STF/qf8=
+knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf h1:1RqxCIJBwvpahPVNCfxEk4Z/z7nHgmBhPp7ba9A1My0=
+knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf/go.mod h1:kXbsW1qHQcwHyd7qV1bHeYxGysR6XHh/hCkEvk28R/s=
knative.dev/pkg v0.0.0-20220104185830-52e42b760b54/go.mod h1:189cvGP0mwpqwZGFrLk5WuERIsNI/J6HuQ1CIX7SXxY=
knative.dev/pkg v0.0.0-20220105211333-96f18522d78d h1:KqTqUP+w382CaI7NdIGaFLSI0qq2vo4QT93zzbsLnYY=
knative.dev/pkg v0.0.0-20220105211333-96f18522d78d/go.mod h1:189cvGP0mwpqwZGFrLk5WuERIsNI/J6HuQ1CIX7SXxY=
diff --git a/vendor/knative.dev/networking/pkg/client/clientset/versioned/fake/clientset_generated.go b/vendor/knative.dev/networking/pkg/client/clientset/versioned/fake/clientset_generated.go
index ab20ab289455..eb9da6f0a83e 100644
--- a/vendor/knative.dev/networking/pkg/client/clientset/versioned/fake/clientset_generated.go
+++ b/vendor/knative.dev/networking/pkg/client/clientset/versioned/fake/clientset_generated.go
@@ -74,7 +74,10 @@ func (c *Clientset) Tracker() testing.ObjectTracker {
return c.tracker
}
-var _ clientset.Interface = &Clientset{}
+var (
+ _ clientset.Interface = &Clientset{}
+ _ testing.FakeClient = &Clientset{}
+)
// NetworkingV1alpha1 retrieves the NetworkingV1alpha1Client
func (c *Clientset) NetworkingV1alpha1() networkingv1alpha1.NetworkingV1alpha1Interface {
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 33d7e5b0bfae..45f958671363 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -1011,7 +1011,7 @@ knative.dev/caching/pkg/client/listers/caching/v1alpha1
## explicit
knative.dev/hack
knative.dev/hack/shell
-# knative.dev/networking v0.0.0-20211223134928-e40187c3026d
+# knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf
## explicit
knative.dev/networking/config
knative.dev/networking/pkg
From a7df96e928236353f69a56c2414893ef6bdb6176 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 11 Jan 2022 05:43:14 -0800
Subject: [PATCH 074/733] upgrade to latest dependencies (#12485)
bumping knative.dev/hack abd085f...f08cb0d:
> f08cb0d Fixing issue knative/hack# 136 (# 137)
Signed-off-by: Knative Automation
---
go.mod | 2 +-
go.sum | 3 ++-
vendor/knative.dev/hack/e2e-tests.sh | 10 +++++++---
vendor/modules.txt | 2 +-
4 files changed, 11 insertions(+), 6 deletions(-)
diff --git a/go.mod b/go.mod
index c3e5cf7fd5ab..1c9313e573d1 100644
--- a/go.mod
+++ b/go.mod
@@ -37,7 +37,7 @@ require (
k8s.io/code-generator v0.22.5
k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c
knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6
- knative.dev/hack v0.0.0-20211222071919-abd085fc43de
+ knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7
knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf
knative.dev/pkg v0.0.0-20220105211333-96f18522d78d
sigs.k8s.io/yaml v1.3.0
diff --git a/go.sum b/go.sum
index b57e348e5899..15e01e56737b 100644
--- a/go.sum
+++ b/go.sum
@@ -1661,8 +1661,9 @@ k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/
knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6 h1:GdKaM4S2blx/BPcKIztafPa176mdPuEdQBQg/0FpXog=
knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6/go.mod h1:SgmDCiZNxriP5d1ie3cDZ+/3nXVk8cCd7dEVPWz0beo=
knative.dev/hack v0.0.0-20211203062838-e11ac125e707/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/hack v0.0.0-20211222071919-abd085fc43de h1:K7UeyvIfdTjznffAZg2L4fDkOuFWEDiaxgEa+B33nP8=
knative.dev/hack v0.0.0-20211222071919-abd085fc43de/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
+knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7 h1:TPnyJuwP2cRXUZvLFSkGPzc/gEavAnj/HcV1Ut7UA+U=
+knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf h1:1RqxCIJBwvpahPVNCfxEk4Z/z7nHgmBhPp7ba9A1My0=
knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf/go.mod h1:kXbsW1qHQcwHyd7qV1bHeYxGysR6XHh/hCkEvk28R/s=
knative.dev/pkg v0.0.0-20220104185830-52e42b760b54/go.mod h1:189cvGP0mwpqwZGFrLk5WuERIsNI/J6HuQ1CIX7SXxY=
diff --git a/vendor/knative.dev/hack/e2e-tests.sh b/vendor/knative.dev/hack/e2e-tests.sh
index c5906d610852..537b3867e238 100644
--- a/vendor/knative.dev/hack/e2e-tests.sh
+++ b/vendor/knative.dev/hack/e2e-tests.sh
@@ -17,7 +17,7 @@
# This is a helper script for Knative E2E test scripts.
# See README.md for instructions on how to use it.
-source $(dirname "${BASH_SOURCE[0]}")/infra-library.sh
+source "$(dirname "${BASH_SOURCE[0]:-$0}")/infra-library.sh"
readonly TEST_RESULT_FILE=/tmp/${REPO_NAME}-e2e-result
@@ -29,8 +29,12 @@ function teardown_test_resources() {
# On boskos, save time and don't teardown as the cluster will be destroyed anyway.
(( IS_BOSKOS )) && return
header "Tearing down test environment"
- function_exists test_teardown && test_teardown
- function_exists knative_teardown && knative_teardown
+ if function_exists test_teardown; then
+ test_teardown
+ fi
+ if function_exists knative_teardown; then
+ knative_teardown
+ fi
}
# Run the given E2E tests. Assume tests are tagged e2e, unless `-tags=XXX` is passed.
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 45f958671363..5c2761cebb91 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -1007,7 +1007,7 @@ knative.dev/caching/pkg/client/injection/informers/caching/v1alpha1/image/fake
knative.dev/caching/pkg/client/injection/informers/factory
knative.dev/caching/pkg/client/injection/informers/factory/fake
knative.dev/caching/pkg/client/listers/caching/v1alpha1
-# knative.dev/hack v0.0.0-20211222071919-abd085fc43de
+# knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7
## explicit
knative.dev/hack
knative.dev/hack/shell
From f6d38a9ef951bb88b62c8d52ad7758e322a031f3 Mon Sep 17 00:00:00 2001
From: Nader Ziada
Date: Tue, 11 Jan 2022 12:01:14 -0500
Subject: [PATCH 075/733] update rotation (#12489)
---
support/support.rotation | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/support/support.rotation b/support/support.rotation
index a64fce33490e..61d98c0f5baf 100644
--- a/support/support.rotation
+++ b/support/support.rotation
@@ -21,7 +21,7 @@
2021-12-27T01:00:00Z | N/A - break
2022-01-03T01:00:00Z | TBD
2022-01-10T01:00:00Z | nader-ziada
-2022-01-11T01:00:00Z | yanweiguo
2022-01-17T01:00:00Z | nak3
2022-01-24T01:00:00Z | shinigambit
+2022-01-31T01:00:00Z | yanweiguo
2022-02-07T01:00:00Z | ZhiminXiang
From 39af71665e8f9146ca6bdfe5addb8e441a804a98 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 11 Jan 2022 18:46:50 -0800
Subject: [PATCH 076/733] upgrade to latest dependencies (#12491)
bumping knative.dev/pkg 96f1852...785eb63:
> 785eb63 switch to klog/v2 (# 2386)
> bba4470 Validate Sink in SourceSpec (# 2384)
> 80b253f upgrade to latest dependencies (# 2385)
bumping knative.dev/caching 30ba0b6...669d362:
> 669d362 upgrade to latest dependencies (# 589)
bumping knative.dev/hack f08cb0d...59b0cf1:
> 59b0cf1 Proper search for tags in Go files only (# 135)
Signed-off-by: Knative Automation
---
go.mod | 6 +-
go.sum | 18 +-
.../VENDOR-LICENSE/k8s.io/klog/LICENSE | 191 -------
vendor/github.com/go-logr/logr/.golangci.yaml | 29 +
vendor/github.com/go-logr/logr/CHANGELOG.md | 6 +
.../github.com/go-logr/logr/CONTRIBUTING.md | 17 +
vendor/github.com/go-logr/logr/README.md | 209 +++++--
vendor/github.com/go-logr/logr/discard.go | 35 +-
vendor/github.com/go-logr/logr/go.mod | 2 +-
vendor/github.com/go-logr/logr/logr.go | 533 +++++++++++++-----
vendor/k8s.io/klog/v2/go.mod | 2 +-
vendor/k8s.io/klog/v2/go.sum | 4 +-
vendor/k8s.io/klog/v2/klog.go | 250 ++++++--
vendor/k8s.io/klog/v2/klog_file.go | 34 --
vendor/k8s.io/klog/v2/klog_file_others.go | 19 +
vendor/k8s.io/klog/v2/klog_file_windows.go | 34 ++
vendor/knative.dev/hack/presubmit-tests.sh | 38 +-
.../pkg/apis/duck/v1/source_types.go | 5 +-
.../cmd/injection-gen/generators/client.go | 2 +-
.../cmd/injection-gen/generators/duck.go | 2 +-
.../cmd/injection-gen/generators/factory.go | 2 +-
.../injection-gen/generators/fake_client.go | 2 +-
.../cmd/injection-gen/generators/fake_duck.go | 2 +-
.../injection-gen/generators/fake_factory.go | 2 +-
.../generators/fake_filtered_factory.go | 2 +-
.../generators/fake_filtered_informer.go | 2 +-
.../injection-gen/generators/fake_informer.go | 2 +-
.../generators/filtered_factory.go | 3 +-
.../generators/filtered_informer.go | 2 +-
.../cmd/injection-gen/generators/informer.go | 2 +-
.../cmd/injection-gen/generators/packages.go | 2 +-
.../generators/reconciler_controller.go | 2 +-
.../generators/reconciler_controller_stub.go | 2 +-
.../generators/reconciler_reconciler.go | 2 +-
.../generators/reconciler_reconciler_stub.go | 2 +-
.../generators/reconciler_state.go | 2 +-
.../pkg/codegen/cmd/injection-gen/main.go | 2 +-
vendor/knative.dev/pkg/injection/config.go | 2 +-
.../knative.dev/pkg/test/logging/logging.go | 2 +-
vendor/modules.txt | 10 +-
40 files changed, 916 insertions(+), 569 deletions(-)
delete mode 100644 third_party/VENDOR-LICENSE/k8s.io/klog/LICENSE
create mode 100644 vendor/github.com/go-logr/logr/.golangci.yaml
create mode 100644 vendor/github.com/go-logr/logr/CHANGELOG.md
create mode 100644 vendor/github.com/go-logr/logr/CONTRIBUTING.md
create mode 100644 vendor/k8s.io/klog/v2/klog_file_others.go
create mode 100644 vendor/k8s.io/klog/v2/klog_file_windows.go
diff --git a/go.mod b/go.mod
index 1c9313e573d1..dde69507268d 100644
--- a/go.mod
+++ b/go.mod
@@ -36,9 +36,9 @@ require (
k8s.io/client-go v0.22.5
k8s.io/code-generator v0.22.5
k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c
- knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6
- knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7
+ knative.dev/caching v0.0.0-20220111134414-669d362b44c5
+ knative.dev/hack v0.0.0-20220111151514-59b0cf17578e
knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf
- knative.dev/pkg v0.0.0-20220105211333-96f18522d78d
+ knative.dev/pkg v0.0.0-20220111210214-785eb637f693
sigs.k8s.io/yaml v1.3.0
)
diff --git a/go.sum b/go.sum
index 15e01e56737b..db765a720ab3 100644
--- a/go.sum
+++ b/go.sum
@@ -416,8 +416,10 @@ github.com/go-logfmt/logfmt v0.5.0 h1:TrB8swr/68K7m9CcGut2g3UOihhbcbiMAYiuTXdEih
github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A=
github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas=
github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
-github.com/go-logr/logr v0.4.0 h1:K7/B1jt6fIBQVd4Owv2MqGQClcgf0R266+7C/QjRcLc=
github.com/go-logr/logr v0.4.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
+github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
+github.com/go-logr/logr v1.2.2 h1:ahHml/yUpnlb96Rp8HCvtYVPY8ZYpxq3g7UYchIYwbs=
+github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
github.com/go-openapi/jsonpointer v0.19.2/go.mod h1:3akKfEdA7DF1sugOqz1dVQHBcuDBPKZGEoHC/NkiQRg=
github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
github.com/go-openapi/jsonpointer v0.19.5 h1:gZr+CIYByUqjcgeLXnQu2gHYQC9o73G2XUeOFYEICuY=
@@ -1646,8 +1648,9 @@ k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE=
k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
k8s.io/klog/v2 v2.4.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
k8s.io/klog/v2 v2.8.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
-k8s.io/klog/v2 v2.9.0 h1:D7HV+n1V57XeZ0m6tdRkfknthUaM06VFbWldOFh8kzM=
k8s.io/klog/v2 v2.9.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
+k8s.io/klog/v2 v2.40.1 h1:P4RRucWk/lFOlDdkAr3mc7iWFkgKrZY9qZMAgek06S4=
+k8s.io/klog/v2 v2.40.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
k8s.io/kube-openapi v0.0.0-20201113171705-d219536bb9fd/go.mod h1:WOJ3KddDSol4tAGcJo0Tvi+dK12EcqSLqcWsryKMpfM=
k8s.io/kube-openapi v0.0.0-20210305001622-591a79e4bda7/go.mod h1:wXW5VT87nVfh/iLV8FpR2uDvrFyomxbtb1KivDbvPTE=
k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c h1:jvamsI1tn9V0S8jicyX82qaFC0H/NKxv2e5mbqsgR80=
@@ -1658,17 +1661,18 @@ k8s.io/legacy-cloud-providers v0.21.0/go.mod h1:bNxo7gDg+PGkBmT/MFZswLTWdSWK9kAl
k8s.io/utils v0.0.0-20201110183641-67b214c5f920/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a h1:8dYfu/Fc9Gz2rNJKB9IQRGgQOh2clmRzNIPPY1xLY5g=
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
-knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6 h1:GdKaM4S2blx/BPcKIztafPa176mdPuEdQBQg/0FpXog=
-knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6/go.mod h1:SgmDCiZNxriP5d1ie3cDZ+/3nXVk8cCd7dEVPWz0beo=
+knative.dev/caching v0.0.0-20220111134414-669d362b44c5 h1:fkUkaIkFBPtxp/9thpmFze0XmgQTq7BLdk3Ce3rlzjs=
+knative.dev/caching v0.0.0-20220111134414-669d362b44c5/go.mod h1:uyFdKZ2WHnhTd+qc8sghvh/gAij28QAhs7qv7CgEP+U=
knative.dev/hack v0.0.0-20211203062838-e11ac125e707/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/hack v0.0.0-20211222071919-abd085fc43de/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7 h1:TPnyJuwP2cRXUZvLFSkGPzc/gEavAnj/HcV1Ut7UA+U=
knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
+knative.dev/hack v0.0.0-20220111151514-59b0cf17578e h1:tESsFI1iMD2Al+6FZueFN9CddxJ8Fa2cd9KmyNINe3w=
+knative.dev/hack v0.0.0-20220111151514-59b0cf17578e/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf h1:1RqxCIJBwvpahPVNCfxEk4Z/z7nHgmBhPp7ba9A1My0=
knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf/go.mod h1:kXbsW1qHQcwHyd7qV1bHeYxGysR6XHh/hCkEvk28R/s=
-knative.dev/pkg v0.0.0-20220104185830-52e42b760b54/go.mod h1:189cvGP0mwpqwZGFrLk5WuERIsNI/J6HuQ1CIX7SXxY=
-knative.dev/pkg v0.0.0-20220105211333-96f18522d78d h1:KqTqUP+w382CaI7NdIGaFLSI0qq2vo4QT93zzbsLnYY=
knative.dev/pkg v0.0.0-20220105211333-96f18522d78d/go.mod h1:189cvGP0mwpqwZGFrLk5WuERIsNI/J6HuQ1CIX7SXxY=
+knative.dev/pkg v0.0.0-20220111210214-785eb637f693 h1:uOIXXDSMBe50XmdVwORYzN5zh/drNDAtkzmpT+yCvns=
+knative.dev/pkg v0.0.0-20220111210214-785eb637f693/go.mod h1:YVa0jO4t3eLg9YD/4IDs9TsZsF+g1nx8T9szmlbY/Yc=
pgregory.net/rapid v0.3.3 h1:jCjBsY4ln4Atz78QoBWxUEvAHaFyNDQg9+WU62aCn1U=
pgregory.net/rapid v0.3.3/go.mod h1:UYpPVyjFHzYBGHIxLFoupi8vwk6rXNzRY9OMvVxFIOU=
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
diff --git a/third_party/VENDOR-LICENSE/k8s.io/klog/LICENSE b/third_party/VENDOR-LICENSE/k8s.io/klog/LICENSE
deleted file mode 100644
index 37ec93a14fdc..000000000000
--- a/third_party/VENDOR-LICENSE/k8s.io/klog/LICENSE
+++ /dev/null
@@ -1,191 +0,0 @@
-Apache License
-Version 2.0, January 2004
-http://www.apache.org/licenses/
-
-TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-1. Definitions.
-
-"License" shall mean the terms and conditions for use, reproduction, and
-distribution as defined by Sections 1 through 9 of this document.
-
-"Licensor" shall mean the copyright owner or entity authorized by the copyright
-owner that is granting the License.
-
-"Legal Entity" shall mean the union of the acting entity and all other entities
-that control, are controlled by, or are under common control with that entity.
-For the purposes of this definition, "control" means (i) the power, direct or
-indirect, to cause the direction or management of such entity, whether by
-contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the
-outstanding shares, or (iii) beneficial ownership of such entity.
-
-"You" (or "Your") shall mean an individual or Legal Entity exercising
-permissions granted by this License.
-
-"Source" form shall mean the preferred form for making modifications, including
-but not limited to software source code, documentation source, and configuration
-files.
-
-"Object" form shall mean any form resulting from mechanical transformation or
-translation of a Source form, including but not limited to compiled object code,
-generated documentation, and conversions to other media types.
-
-"Work" shall mean the work of authorship, whether in Source or Object form, made
-available under the License, as indicated by a copyright notice that is included
-in or attached to the work (an example is provided in the Appendix below).
-
-"Derivative Works" shall mean any work, whether in Source or Object form, that
-is based on (or derived from) the Work and for which the editorial revisions,
-annotations, elaborations, or other modifications represent, as a whole, an
-original work of authorship. For the purposes of this License, Derivative Works
-shall not include works that remain separable from, or merely link (or bind by
-name) to the interfaces of, the Work and Derivative Works thereof.
-
-"Contribution" shall mean any work of authorship, including the original version
-of the Work and any modifications or additions to that Work or Derivative Works
-thereof, that is intentionally submitted to Licensor for inclusion in the Work
-by the copyright owner or by an individual or Legal Entity authorized to submit
-on behalf of the copyright owner. For the purposes of this definition,
-"submitted" means any form of electronic, verbal, or written communication sent
-to the Licensor or its representatives, including but not limited to
-communication on electronic mailing lists, source code control systems, and
-issue tracking systems that are managed by, or on behalf of, the Licensor for
-the purpose of discussing and improving the Work, but excluding communication
-that is conspicuously marked or otherwise designated in writing by the copyright
-owner as "Not a Contribution."
-
-"Contributor" shall mean Licensor and any individual or Legal Entity on behalf
-of whom a Contribution has been received by Licensor and subsequently
-incorporated within the Work.
-
-2. Grant of Copyright License.
-
-Subject to the terms and conditions of this License, each Contributor hereby
-grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free,
-irrevocable copyright license to reproduce, prepare Derivative Works of,
-publicly display, publicly perform, sublicense, and distribute the Work and such
-Derivative Works in Source or Object form.
-
-3. Grant of Patent License.
-
-Subject to the terms and conditions of this License, each Contributor hereby
-grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free,
-irrevocable (except as stated in this section) patent license to make, have
-made, use, offer to sell, sell, import, and otherwise transfer the Work, where
-such license applies only to those patent claims licensable by such Contributor
-that are necessarily infringed by their Contribution(s) alone or by combination
-of their Contribution(s) with the Work to which such Contribution(s) was
-submitted. If You institute patent litigation against any entity (including a
-cross-claim or counterclaim in a lawsuit) alleging that the Work or a
-Contribution incorporated within the Work constitutes direct or contributory
-patent infringement, then any patent licenses granted to You under this License
-for that Work shall terminate as of the date such litigation is filed.
-
-4. Redistribution.
-
-You may reproduce and distribute copies of the Work or Derivative Works thereof
-in any medium, with or without modifications, and in Source or Object form,
-provided that You meet the following conditions:
-
-You must give any other recipients of the Work or Derivative Works a copy of
-this License; and
-You must cause any modified files to carry prominent notices stating that You
-changed the files; and
-You must retain, in the Source form of any Derivative Works that You distribute,
-all copyright, patent, trademark, and attribution notices from the Source form
-of the Work, excluding those notices that do not pertain to any part of the
-Derivative Works; and
-If the Work includes a "NOTICE" text file as part of its distribution, then any
-Derivative Works that You distribute must include a readable copy of the
-attribution notices contained within such NOTICE file, excluding those notices
-that do not pertain to any part of the Derivative Works, in at least one of the
-following places: within a NOTICE text file distributed as part of the
-Derivative Works; within the Source form or documentation, if provided along
-with the Derivative Works; or, within a display generated by the Derivative
-Works, if and wherever such third-party notices normally appear. The contents of
-the NOTICE file are for informational purposes only and do not modify the
-License. You may add Your own attribution notices within Derivative Works that
-You distribute, alongside or as an addendum to the NOTICE text from the Work,
-provided that such additional attribution notices cannot be construed as
-modifying the License.
-You may add Your own copyright statement to Your modifications and may provide
-additional or different license terms and conditions for use, reproduction, or
-distribution of Your modifications, or for any such Derivative Works as a whole,
-provided Your use, reproduction, and distribution of the Work otherwise complies
-with the conditions stated in this License.
-
-5. Submission of Contributions.
-
-Unless You explicitly state otherwise, any Contribution intentionally submitted
-for inclusion in the Work by You to the Licensor shall be under the terms and
-conditions of this License, without any additional terms or conditions.
-Notwithstanding the above, nothing herein shall supersede or modify the terms of
-any separate license agreement you may have executed with Licensor regarding
-such Contributions.
-
-6. Trademarks.
-
-This License does not grant permission to use the trade names, trademarks,
-service marks, or product names of the Licensor, except as required for
-reasonable and customary use in describing the origin of the Work and
-reproducing the content of the NOTICE file.
-
-7. Disclaimer of Warranty.
-
-Unless required by applicable law or agreed to in writing, Licensor provides the
-Work (and each Contributor provides its Contributions) on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied,
-including, without limitation, any warranties or conditions of TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are
-solely responsible for determining the appropriateness of using or
-redistributing the Work and assume any risks associated with Your exercise of
-permissions under this License.
-
-8. Limitation of Liability.
-
-In no event and under no legal theory, whether in tort (including negligence),
-contract, or otherwise, unless required by applicable law (such as deliberate
-and grossly negligent acts) or agreed to in writing, shall any Contributor be
-liable to You for damages, including any direct, indirect, special, incidental,
-or consequential damages of any character arising as a result of this License or
-out of the use or inability to use the Work (including but not limited to
-damages for loss of goodwill, work stoppage, computer failure or malfunction, or
-any and all other commercial damages or losses), even if such Contributor has
-been advised of the possibility of such damages.
-
-9. Accepting Warranty or Additional Liability.
-
-While redistributing the Work or Derivative Works thereof, You may choose to
-offer, and charge a fee for, acceptance of support, warranty, indemnity, or
-other liability obligations and/or rights consistent with this License. However,
-in accepting such obligations, You may act only on Your own behalf and on Your
-sole responsibility, not on behalf of any other Contributor, and only if You
-agree to indemnify, defend, and hold each Contributor harmless for any liability
-incurred by, or claims asserted against, such Contributor by reason of your
-accepting any such warranty or additional liability.
-
-END OF TERMS AND CONDITIONS
-
-APPENDIX: How to apply the Apache License to your work
-
-To apply the Apache License to your work, attach the following boilerplate
-notice, with the fields enclosed by brackets "[]" replaced with your own
-identifying information. (Don't include the brackets!) The text should be
-enclosed in the appropriate comment syntax for the file format. We also
-recommend that a file or class name and description of purpose be included on
-the same "printed page" as the copyright notice for easier identification within
-third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/vendor/github.com/go-logr/logr/.golangci.yaml b/vendor/github.com/go-logr/logr/.golangci.yaml
new file mode 100644
index 000000000000..94ff801df1ac
--- /dev/null
+++ b/vendor/github.com/go-logr/logr/.golangci.yaml
@@ -0,0 +1,29 @@
+run:
+ timeout: 1m
+ tests: true
+
+linters:
+ disable-all: true
+ enable:
+ - asciicheck
+ - deadcode
+ - errcheck
+ - forcetypeassert
+ - gocritic
+ - gofmt
+ - goimports
+ - gosimple
+ - govet
+ - ineffassign
+ - misspell
+ - revive
+ - staticcheck
+ - structcheck
+ - typecheck
+ - unused
+ - varcheck
+
+issues:
+ exclude-use-default: false
+ max-issues-per-linter: 0
+ max-same-issues: 10
diff --git a/vendor/github.com/go-logr/logr/CHANGELOG.md b/vendor/github.com/go-logr/logr/CHANGELOG.md
new file mode 100644
index 000000000000..c3569600463c
--- /dev/null
+++ b/vendor/github.com/go-logr/logr/CHANGELOG.md
@@ -0,0 +1,6 @@
+# CHANGELOG
+
+## v1.0.0-rc1
+
+This is the first logged release. Major changes (including breaking changes)
+have occurred since earlier tags.
diff --git a/vendor/github.com/go-logr/logr/CONTRIBUTING.md b/vendor/github.com/go-logr/logr/CONTRIBUTING.md
new file mode 100644
index 000000000000..5d37e294c5fe
--- /dev/null
+++ b/vendor/github.com/go-logr/logr/CONTRIBUTING.md
@@ -0,0 +1,17 @@
+# Contributing
+
+Logr is open to pull-requests, provided they fit within the intended scope of
+the project. Specifically, this library aims to be VERY small and minimalist,
+with no external dependencies.
+
+## Compatibility
+
+This project intends to follow [semantic versioning](http://semver.org) and
+is very strict about compatibility. Any proposed changes MUST follow those
+rules.
+
+## Performance
+
+As a logging library, logr must be as light-weight as possible. Any proposed
+code change must include results of running the [benchmark](./benchmark)
+before and after the change.
diff --git a/vendor/github.com/go-logr/logr/README.md b/vendor/github.com/go-logr/logr/README.md
index e9b5520a1c58..ad825f5f0ae9 100644
--- a/vendor/github.com/go-logr/logr/README.md
+++ b/vendor/github.com/go-logr/logr/README.md
@@ -1,112 +1,182 @@
-# A more minimal logging API for Go
+# A minimal logging API for Go
-Before you consider this package, please read [this blog post by the
-inimitable Dave Cheney][warning-makes-no-sense]. I really appreciate what
-he has to say, and it largely aligns with my own experiences. Too many
-choices of levels means inconsistent logs.
+[](https://pkg.go.dev/github.com/go-logr/logr)
+
+logr offers an(other) opinion on how Go programs and libraries can do logging
+without becoming coupled to a particular logging implementation. This is not
+an implementation of logging - it is an API. In fact it is two APIs with two
+different sets of users.
+
+The `Logger` type is intended for application and library authors. It provides
+a relatively small API which can be used everywhere you want to emit logs. It
+defers the actual act of writing logs (to files, to stdout, or whatever) to the
+`LogSink` interface.
+
+The `LogSink` interface is intended for logging library implementers. It is a
+pure interface which can be implemented by logging frameworks to provide the actual logging
+functionality.
+
+This decoupling allows application and library developers to write code in
+terms of `logr.Logger` (which has very low dependency fan-out) while the
+implementation of logging is managed "up stack" (e.g. in or near `main()`.)
+Application developers can then switch out implementations as necessary.
+
+Many people assert that libraries should not be logging, and as such efforts
+like this are pointless. Those people are welcome to convince the authors of
+the tens-of-thousands of libraries that *DO* write logs that they are all
+wrong. In the meantime, logr takes a more practical approach.
+
+## Typical usage
+
+Somewhere, early in an application's life, it will make a decision about which
+logging library (implementation) it actually wants to use. Something like:
+
+```
+ func main() {
+ // ... other setup code ...
+
+ // Create the "root" logger. We have chosen the "logimpl" implementation,
+ // which takes some initial parameters and returns a logr.Logger.
+ logger := logimpl.New(param1, param2)
+
+ // ... other setup code ...
+```
+
+Most apps will call into other libraries, create structures to govern the flow,
+etc. The `logr.Logger` object can be passed to these other libraries, stored
+in structs, or even used as a package-global variable, if needed. For example:
+
+```
+ app := createTheAppObject(logger)
+ app.Run()
+```
+
+Outside of this early setup, no other packages need to know about the choice of
+implementation. They write logs in terms of the `logr.Logger` that they
+received:
-This package offers a purely abstract interface, based on these ideas but with
-a few twists. Code can depend on just this interface and have the actual
-logging implementation be injected from callers. Ideally only `main()` knows
-what logging implementation is being used.
+```
+ type appObject struct {
+ // ... other fields ...
+ logger logr.Logger
+ // ... other fields ...
+ }
-# Differences from Dave's ideas
+ func (app *appObject) Run() {
+ app.logger.Info("starting up", "timestamp", time.Now())
+
+ // ... app code ...
+```
+
+## Background
+
+If the Go standard library had defined an interface for logging, this project
+probably would not be needed. Alas, here we are.
+
+### Inspiration
+
+Before you consider this package, please read [this blog post by the
+inimitable Dave Cheney][warning-makes-no-sense]. We really appreciate what
+he has to say, and it largely aligns with our own experiences.
+
+### Differences from Dave's ideas
The main differences are:
-1) Dave basically proposes doing away with the notion of a logging API in favor
-of `fmt.Printf()`. I disagree, especially when you consider things like output
-locations, timestamps, file and line decorations, and structured logging. I
-restrict the API to just 2 types of logs: info and error.
+1. Dave basically proposes doing away with the notion of a logging API in favor
+of `fmt.Printf()`. We disagree, especially when you consider things like output
+locations, timestamps, file and line decorations, and structured logging. This
+package restricts the logging API to just 2 types of logs: info and error.
Info logs are things you want to tell the user which are not errors. Error
logs are, well, errors. If your code receives an `error` from a subordinate
function call and is logging that `error` *and not returning it*, use error
logs.
-2) Verbosity-levels on info logs. This gives developers a chance to indicate
+2. Verbosity-levels on info logs. This gives developers a chance to indicate
arbitrary grades of importance for info logs, without assigning names with
-semantic meaning such as "warning", "trace", and "debug". Superficially this
+semantic meaning such as "warning", "trace", and "debug." Superficially this
may feel very similar, but the primary difference is the lack of semantics.
Because verbosity is a numerical value, it's safe to assume that an app running
with higher verbosity means more (and less important) logs will be generated.
-This is a BETA grade API.
+## Implementations (non-exhaustive)
There are implementations for the following logging libraries:
+- **a function** (can bridge to non-structured libraries): [funcr](https://github.com/go-logr/logr/tree/master/funcr)
- **github.com/google/glog**: [glogr](https://github.com/go-logr/glogr)
-- **k8s.io/klog**: [klogr](https://git.k8s.io/klog/klogr)
+- **k8s.io/klog** (for Kubernetes): [klogr](https://git.k8s.io/klog/klogr)
- **go.uber.org/zap**: [zapr](https://github.com/go-logr/zapr)
-- **log** (the Go standard library logger):
- [stdr](https://github.com/go-logr/stdr)
+- **log** (the Go standard library logger): [stdr](https://github.com/go-logr/stdr)
- **github.com/sirupsen/logrus**: [logrusr](https://github.com/bombsimon/logrusr)
- **github.com/wojas/genericr**: [genericr](https://github.com/wojas/genericr) (makes it easy to implement your own backend)
- **logfmt** (Heroku style [logging](https://www.brandur.org/logfmt)): [logfmtr](https://github.com/iand/logfmtr)
+- **github.com/rs/zerolog**: [zerologr](https://github.com/go-logr/zerologr)
-# FAQ
+## FAQ
-## Conceptual
+### Conceptual
-## Why structured logging?
+#### Why structured logging?
-- **Structured logs are more easily queriable**: Since you've got
+- **Structured logs are more easily queryable**: Since you've got
key-value pairs, it's much easier to query your structured logs for
particular values by filtering on the contents of a particular key --
think searching request logs for error codes, Kubernetes reconcilers for
- the name and namespace of the reconciled object, etc
+ the name and namespace of the reconciled object, etc.
-- **Structured logging makes it easier to have cross-referencable logs**:
+- **Structured logging makes it easier to have cross-referenceable logs**:
Similarly to searchability, if you maintain conventions around your
keys, it becomes easy to gather all log lines related to a particular
concept.
-
+
- **Structured logs allow better dimensions of filtering**: if you have
structure to your logs, you've got more precise control over how much
information is logged -- you might choose in a particular configuration
to log certain keys but not others, only log lines where a certain key
- matches a certain value, etc, instead of just having v-levels and names
+ matches a certain value, etc., instead of just having v-levels and names
to key off of.
- **Structured logs better represent structured data**: sometimes, the
data that you want to log is inherently structured (think tuple-link
- objects). Structured logs allow you to preserve that structure when
+ objects.) Structured logs allow you to preserve that structure when
outputting.
-## Why V-levels?
+#### Why V-levels?
**V-levels give operators an easy way to control the chattiness of log
operations**. V-levels provide a way for a given package to distinguish
the relative importance or verbosity of a given log message. Then, if
a particular logger or package is logging too many messages, the user
-of the package can simply change the v-levels for that library.
+of the package can simply change the v-levels for that library.
-## Why not more named levels, like Warning?
+#### Why not named levels, like Info/Warning/Error?
Read [Dave Cheney's post][warning-makes-no-sense]. Then read [Differences
from Dave's ideas](#differences-from-daves-ideas).
-## Why not allow format strings, too?
+#### Why not allow format strings, too?
**Format strings negate many of the benefits of structured logs**:
- They're not easily searchable without resorting to fuzzy searching,
- regular expressions, etc
+ regular expressions, etc.
- They don't store structured data well, since contents are flattened into
- a string
+ a string.
-- They're not cross-referencable
+- They're not cross-referenceable.
-- They don't compress easily, since the message is not constant
+- They don't compress easily, since the message is not constant.
-(unless you turn positional parameters into key-value pairs with numerical
+(Unless you turn positional parameters into key-value pairs with numerical
keys, at which point you've gotten key-value logging with meaningless
-keys)
+keys.)
-## Practical
+### Practical
-## Why key-value pairs, and not a map?
+#### Why key-value pairs, and not a map?
Key-value pairs are *much* easier to optimize, especially around
allocations. Zap (a structured logger that inspired logr's interface) has
@@ -117,26 +187,26 @@ While the interface ends up being a little less obvious, you get
potentially better performance, plus avoid making users type
`map[string]string{}` every time they want to log.
-## What if my V-levels differ between libraries?
+#### What if my V-levels differ between libraries?
That's fine. Control your V-levels on a per-logger basis, and use the
-`WithName` function to pass different loggers to different libraries.
+`WithName` method to pass different loggers to different libraries.
Generally, you should take care to ensure that you have relatively
consistent V-levels within a given logger, however, as this makes deciding
on what verbosity of logs to request easier.
-## But I *really* want to use a format string!
+#### But I really want to use a format string!
That's not actually a question. Assuming your question is "how do
I convert my mental model of logging with format strings to logging with
constant messages":
-1. figure out what the error actually is, as you'd write in a TL;DR style,
- and use that as a message
+1. Figure out what the error actually is, as you'd write in a TL;DR style,
+ and use that as a message.
2. For every place you'd write a format specifier, look to the word before
- it, and add that as a key value pair
+ it, and add that as a key value pair.
For instance, consider the following examples (all taken from spots in the
Kubernetes codebase):
@@ -150,34 +220,59 @@ Kubernetes codebase):
response when requesting url", "attempt", retries, "after
seconds", seconds, "url", url)`
-If you *really* must use a format string, place it as a key value, and
-call `fmt.Sprintf` yourself -- for instance, `log.Printf("unable to
+If you *really* must use a format string, use it in a key's value, and
+call `fmt.Sprintf` yourself. For instance: `log.Printf("unable to
reflect over type %T")` becomes `logger.Info("unable to reflect over
type", "type", fmt.Sprintf("%T"))`. In general though, the cases where
this is necessary should be few and far between.
-## How do I choose my V-levels?
+#### How do I choose my V-levels?
This is basically the only hard constraint: increase V-levels to denote
more verbose or more debug-y logs.
Otherwise, you can start out with `0` as "you always want to see this",
`1` as "common logging that you might *possibly* want to turn off", and
-`10` as "I would like to performance-test your log collection stack".
+`10` as "I would like to performance-test your log collection stack."
Then gradually choose levels in between as you need them, working your way
down from 10 (for debug and trace style logs) and up from 1 (for chattier
-info-type logs).
+info-type logs.)
+
+#### How do I choose my keys?
-## How do I choose my keys
+Keys are fairly flexible, and can hold more or less any string
+value. For best compatibility with implementations and consistency
+with existing code in other projects, there are a few conventions you
+should consider.
-- make your keys human-readable
-- constant keys are generally a good idea
-- be consistent across your codebase
-- keys should naturally match parts of the message string
+- Make your keys human-readable.
+- Constant keys are generally a good idea.
+- Be consistent across your codebase.
+- Keys should naturally match parts of the message string.
+- Use lower case for simple keys and
+ [lowerCamelCase](https://en.wiktionary.org/wiki/lowerCamelCase) for
+ more complex ones. Kubernetes is one example of a project that has
+ [adopted that
+ convention](https://github.com/kubernetes/community/blob/HEAD/contributors/devel/sig-instrumentation/migration-to-structured-logging.md#name-arguments).
While key names are mostly unrestricted (and spaces are acceptable),
it's generally a good idea to stick to printable ascii characters, or at
least match the general character set of your log lines.
+#### Why should keys be constant values?
+
+The point of structured logging is to make later log processing easier. Your
+keys are, effectively, the schema of each log message. If you use different
+keys across instances of the same log line, you will make your structured logs
+much harder to use. `Sprintf()` is for values, not for keys!
+
+#### Why is this not a pure interface?
+
+The Logger type is implemented as a struct in order to allow the Go compiler to
+optimize things like high-V `Info` logs that are not triggered. Not all of
+these implementations are implemented yet, but this structure was suggested as
+a way to ensure they *can* be implemented. All of the real work is behind the
+`LogSink` interface.
+
[warning-makes-no-sense]: http://dave.cheney.net/2015/11/05/lets-talk-about-logging
diff --git a/vendor/github.com/go-logr/logr/discard.go b/vendor/github.com/go-logr/logr/discard.go
index 2bafb13d15ce..9d92a38f1d75 100644
--- a/vendor/github.com/go-logr/logr/discard.go
+++ b/vendor/github.com/go-logr/logr/discard.go
@@ -16,36 +16,39 @@ limitations under the License.
package logr
-// Discard returns a valid Logger that discards all messages logged to it.
-// It can be used whenever the caller is not interested in the logs.
+// Discard returns a Logger that discards all messages logged to it. It can be
+// used whenever the caller is not interested in the logs. Logger instances
+// produced by this function always compare as equal.
func Discard() Logger {
- return DiscardLogger{}
+ return Logger{
+ level: 0,
+ sink: discardLogSink{},
+ }
}
-// DiscardLogger is a Logger that discards all messages.
-type DiscardLogger struct{}
+// discardLogSink is a LogSink that discards all messages.
+type discardLogSink struct{}
-func (l DiscardLogger) Enabled() bool {
- return false
+// Verify that it actually implements the interface
+var _ LogSink = discardLogSink{}
+
+func (l discardLogSink) Init(RuntimeInfo) {
}
-func (l DiscardLogger) Info(msg string, keysAndValues ...interface{}) {
+func (l discardLogSink) Enabled(int) bool {
+ return false
}
-func (l DiscardLogger) Error(err error, msg string, keysAndValues ...interface{}) {
+func (l discardLogSink) Info(int, string, ...interface{}) {
}
-func (l DiscardLogger) V(level int) Logger {
- return l
+func (l discardLogSink) Error(error, string, ...interface{}) {
}
-func (l DiscardLogger) WithValues(keysAndValues ...interface{}) Logger {
+func (l discardLogSink) WithValues(...interface{}) LogSink {
return l
}
-func (l DiscardLogger) WithName(name string) Logger {
+func (l discardLogSink) WithName(string) LogSink {
return l
}
-
-// Verify that it actually implements the interface
-var _ Logger = DiscardLogger{}
diff --git a/vendor/github.com/go-logr/logr/go.mod b/vendor/github.com/go-logr/logr/go.mod
index 591884e91f14..7baec9b57073 100644
--- a/vendor/github.com/go-logr/logr/go.mod
+++ b/vendor/github.com/go-logr/logr/go.mod
@@ -1,3 +1,3 @@
module github.com/go-logr/logr
-go 1.14
+go 1.16
diff --git a/vendor/github.com/go-logr/logr/logr.go b/vendor/github.com/go-logr/logr/logr.go
index 842428bd3a39..c05482a20319 100644
--- a/vendor/github.com/go-logr/logr/logr.go
+++ b/vendor/github.com/go-logr/logr/logr.go
@@ -16,83 +16,104 @@ limitations under the License.
// This design derives from Dave Cheney's blog:
// http://dave.cheney.net/2015/11/05/lets-talk-about-logging
-//
-// This is a BETA grade API. Until there is a significant 2nd implementation,
-// I don't really know how it will change.
-// Package logr defines abstract interfaces for logging. Packages can depend on
-// these interfaces and callers can implement logging in whatever way is
-// appropriate.
+// Package logr defines a general-purpose logging API and abstract interfaces
+// to back that API. Packages in the Go ecosystem can depend on this package,
+// while callers can implement logging with whatever backend is appropriate.
//
// Usage
//
-// Logging is done using a Logger. Loggers can have name prefixes and named
-// values attached, so that all log messages logged with that Logger have some
-// base context associated.
+// Logging is done using a Logger instance. Logger is a concrete type with
+// methods, which defers the actual logging to a LogSink interface. The main
+// methods of Logger are Info() and Error(). Arguments to Info() and Error()
+// are key/value pairs rather than printf-style formatted strings, emphasizing
+// "structured logging".
//
-// The term "key" is used to refer to the name associated with a particular
-// value, to disambiguate it from the general Logger name.
+// With Go's standard log package, we might write:
+// log.Printf("setting target value %s", targetValue)
//
-// For instance, suppose we're trying to reconcile the state of an object, and
-// we want to log that we've made some decision.
+// With logr's structured logging, we'd write:
+// logger.Info("setting target", "value", targetValue)
//
-// With the traditional log package, we might write:
-// log.Printf("decided to set field foo to value %q for object %s/%s",
-// targetValue, object.Namespace, object.Name)
+// Errors are much the same. Instead of:
+// log.Printf("failed to open the pod bay door for user %s: %v", user, err)
//
-// With logr's structured logging, we'd write:
-// // elsewhere in the file, set up the logger to log with the prefix of
-// // "reconcilers", and the named value target-type=Foo, for extra context.
-// log := mainLogger.WithName("reconcilers").WithValues("target-type", "Foo")
+// We'd write:
+// logger.Error(err, "failed to open the pod bay door", "user", user)
//
-// // later on...
-// log.Info("setting foo on object", "value", targetValue, "object", object)
+// Info() and Error() are very similar, but they are separate methods so that
+// LogSink implementations can choose to do things like attach additional
+// information (such as stack traces) on calls to Error(). Error() messages are
+// always logged, regardless of the current verbosity. If there is no error
+// instance available, passing nil is valid.
+//
+// Verbosity
+//
+// Often we want to log information only when the application in "verbose
+// mode". To write log lines that are more verbose, Logger has a V() method.
+// The higher the V-level of a log line, the less critical it is considered.
+// Log-lines with V-levels that are not enabled (as per the LogSink) will not
+// be written. Level V(0) is the default, and logger.V(0).Info() has the same
+// meaning as logger.Info(). Negative V-levels have the same meaning as V(0).
+// Error messages do not have a verbosity level and are always logged.
+//
+// Where we might have written:
+// if flVerbose >= 2 {
+// log.Printf("an unusual thing happened")
+// }
+//
+// We can write:
+// logger.V(2).Info("an unusual thing happened")
+//
+// Logger Names
+//
+// Logger instances can have name strings so that all messages logged through
+// that instance have additional context. For example, you might want to add
+// a subsystem name:
//
-// Depending on our logging implementation, we could then make logging decisions
-// based on field values (like only logging such events for objects in a certain
-// namespace), or copy the structured information into a structured log store.
+// logger.WithName("compactor").Info("started", "time", time.Now())
//
-// For logging errors, Logger has a method called Error. Suppose we wanted to
-// log an error while reconciling. With the traditional log package, we might
-// write:
-// log.Errorf("unable to reconcile object %s/%s: %v", object.Namespace, object.Name, err)
+// The WithName() method returns a new Logger, which can be passed to
+// constructors or other functions for further use. Repeated use of WithName()
+// will accumulate name "segments". These name segments will be joined in some
+// way by the LogSink implementation. It is strongly recommended that name
+// segments contain simple identifiers (letters, digits, and hyphen), and do
+// not contain characters that could muddle the log output or confuse the
+// joining operation (e.g. whitespace, commas, periods, slashes, brackets,
+// quotes, etc).
//
-// With logr, we'd instead write:
-// // assuming the above setup for log
-// log.Error(err, "unable to reconcile object", "object", object)
+// Saved Values
//
-// This functions similarly to:
-// log.Info("unable to reconcile object", "error", err, "object", object)
+// Logger instances can store any number of key/value pairs, which will be
+// logged alongside all messages logged through that instance. For example,
+// you might want to create a Logger instance per managed object:
//
-// However, it ensures that a standard key for the error value ("error") is used
-// across all error logging. Furthermore, certain implementations may choose to
-// attach additional information (such as stack traces) on calls to Error, so
-// it's preferred to use Error to log errors.
+// With the standard log package, we might write:
+// log.Printf("decided to set field foo to value %q for object %s/%s",
+// targetValue, object.Namespace, object.Name)
//
-// Parts of a log line
+// With logr we'd write:
+// // Elsewhere: set up the logger to log the object name.
+// obj.logger = mainLogger.WithValues(
+// "name", obj.name, "namespace", obj.namespace)
//
-// Each log message from a Logger has four types of context:
-// logger name, log verbosity, log message, and the named values.
+// // later on...
+// obj.logger.Info("setting foo", "value", targetValue)
//
-// The Logger name consists of a series of name "segments" added by successive
-// calls to WithName. These name segments will be joined in some way by the
-// underlying implementation. It is strongly recommended that name segments
-// contain simple identifiers (letters, digits, and hyphen), and do not contain
-// characters that could muddle the log output or confuse the joining operation
-// (e.g. whitespace, commas, periods, slashes, brackets, quotes, etc).
+// Best Practices
//
-// Log verbosity represents how little a log matters. Level zero, the default,
-// matters most. Increasing levels matter less and less. Try to avoid lots of
-// different verbosity levels, and instead provide useful keys, logger names,
-// and log messages for users to filter on. It's illegal to pass a log level
-// below zero.
+// Logger has very few hard rules, with the goal that LogSink implementations
+// might have a lot of freedom to differentiate. There are, however, some
+// things to consider.
//
// The log message consists of a constant message attached to the log line.
// This should generally be a simple description of what's occurring, and should
-// never be a format string.
+// never be a format string. Variable information can then be attached using
+// named values.
//
-// Variable information can then be attached using named values (key/value
-// pairs). Keys are arbitrary strings, while values may be any Go value.
+// Keys are arbitrary strings, but should generally be constant values. Values
+// may be any Go value, but how the value is formatted is determined by the
+// LogSink implementation.
//
// Key Naming Conventions
//
@@ -102,6 +123,7 @@ limitations under the License.
// * be constant (not dependent on input data)
// * contain only printable characters
// * not contain whitespace or punctuation
+// * use lower case for simple keys and lowerCamelCase for more complex ones
//
// These guidelines help ensure that log data is processed properly regardless
// of the log implementation. For example, log implementations will try to
@@ -110,21 +132,22 @@ limitations under the License.
// While users are generally free to use key names of their choice, it's
// generally best to avoid using the following keys, as they're frequently used
// by implementations:
-//
-// * `"caller"`: the calling information (file/line) of a particular log line.
-// * `"error"`: the underlying error value in the `Error` method.
-// * `"level"`: the log level.
-// * `"logger"`: the name of the associated logger.
-// * `"msg"`: the log message.
-// * `"stacktrace"`: the stack trace associated with a particular log line or
-// error (often from the `Error` message).
-// * `"ts"`: the timestamp for a log line.
+// * "caller": the calling information (file/line) of a particular log line
+// * "error": the underlying error value in the `Error` method
+// * "level": the log level
+// * "logger": the name of the associated logger
+// * "msg": the log message
+// * "stacktrace": the stack trace associated with a particular log line or
+// error (often from the `Error` message)
+// * "ts": the timestamp for a log line
//
// Implementations are encouraged to make use of these keys to represent the
// above concepts, when necessary (for example, in a pure-JSON output form, it
// would be necessary to represent at least message and timestamp as ordinary
// named values).
//
+// Break Glass
+//
// Implementations may choose to give callers access to the underlying
// logging implementation. The recommended pattern for this is:
// // Underlier exposes access to the underlying logging implementation.
@@ -134,81 +157,222 @@ limitations under the License.
// type Underlier interface {
// GetUnderlying()
// }
+//
+// Logger grants access to the sink to enable type assertions like this:
+// func DoSomethingWithImpl(log logr.Logger) {
+// if underlier, ok := log.GetSink()(impl.Underlier) {
+// implLogger := underlier.GetUnderlying()
+// ...
+// }
+// }
+//
+// Custom `With*` functions can be implemented by copying the complete
+// Logger struct and replacing the sink in the copy:
+// // WithFooBar changes the foobar parameter in the log sink and returns a
+// // new logger with that modified sink. It does nothing for loggers where
+// // the sink doesn't support that parameter.
+// func WithFoobar(log logr.Logger, foobar int) logr.Logger {
+// if foobarLogSink, ok := log.GetSink()(FoobarSink); ok {
+// log = log.WithSink(foobarLogSink.WithFooBar(foobar))
+// }
+// return log
+// }
+//
+// Don't use New to construct a new Logger with a LogSink retrieved from an
+// existing Logger. Source code attribution might not work correctly and
+// unexported fields in Logger get lost.
+//
+// Beware that the same LogSink instance may be shared by different logger
+// instances. Calling functions that modify the LogSink will affect all of
+// those.
package logr
import (
"context"
)
-// TODO: consider adding back in format strings if they're really needed
-// TODO: consider other bits of zap/zapcore functionality like ObjectMarshaller (for arbitrary objects)
-// TODO: consider other bits of glog functionality like Flush, OutputStats
+// New returns a new Logger instance. This is primarily used by libraries
+// implementing LogSink, rather than end users.
+func New(sink LogSink) Logger {
+ logger := Logger{}
+ logger.setSink(sink)
+ sink.Init(runtimeInfo)
+ return logger
+}
-// Logger represents the ability to log messages, both errors and not.
-type Logger interface {
- // Enabled tests whether this Logger is enabled. For example, commandline
- // flags might be used to set the logging verbosity and disable some info
- // logs.
- Enabled() bool
+// setSink stores the sink and updates any related fields. It mutates the
+// logger and thus is only safe to use for loggers that are not currently being
+// used concurrently.
+func (l *Logger) setSink(sink LogSink) {
+ l.sink = sink
+}
- // Info logs a non-error message with the given key/value pairs as context.
- //
- // The msg argument should be used to add some constant description to
- // the log line. The key/value pairs can then be used to add additional
- // variable information. The key/value pairs should alternate string
- // keys and arbitrary values.
- Info(msg string, keysAndValues ...interface{})
-
- // Error logs an error, with the given message and key/value pairs as context.
- // It functions similarly to calling Info with the "error" named value, but may
- // have unique behavior, and should be preferred for logging errors (see the
- // package documentations for more information).
- //
- // The msg field should be used to add context to any underlying error,
- // while the err field should be used to attach the actual error that
- // triggered this log line, if present.
- Error(err error, msg string, keysAndValues ...interface{})
+// GetSink returns the stored sink.
+func (l Logger) GetSink() LogSink {
+ return l.sink
+}
+
+// WithSink returns a copy of the logger with the new sink.
+func (l Logger) WithSink(sink LogSink) Logger {
+ l.setSink(sink)
+ return l
+}
+
+// Logger is an interface to an abstract logging implementation. This is a
+// concrete type for performance reasons, but all the real work is passed on to
+// a LogSink. Implementations of LogSink should provide their own constructors
+// that return Logger, not LogSink.
+//
+// The underlying sink can be accessed through GetSink and be modified through
+// WithSink. This enables the implementation of custom extensions (see "Break
+// Glass" in the package documentation). Normally the sink should be used only
+// indirectly.
+type Logger struct {
+ sink LogSink
+ level int
+}
+
+// Enabled tests whether this Logger is enabled. For example, commandline
+// flags might be used to set the logging verbosity and disable some info logs.
+func (l Logger) Enabled() bool {
+ return l.sink.Enabled(l.level)
+}
+
+// Info logs a non-error message with the given key/value pairs as context.
+//
+// The msg argument should be used to add some constant description to the log
+// line. The key/value pairs can then be used to add additional variable
+// information. The key/value pairs must alternate string keys and arbitrary
+// values.
+func (l Logger) Info(msg string, keysAndValues ...interface{}) {
+ if l.Enabled() {
+ if withHelper, ok := l.sink.(CallStackHelperLogSink); ok {
+ withHelper.GetCallStackHelper()()
+ }
+ l.sink.Info(l.level, msg, keysAndValues...)
+ }
+}
+
+// Error logs an error, with the given message and key/value pairs as context.
+// It functions similarly to Info, but may have unique behavior, and should be
+// preferred for logging errors (see the package documentations for more
+// information). The log message will always be emitted, regardless of
+// verbosity level.
+//
+// The msg argument should be used to add context to any underlying error,
+// while the err argument should be used to attach the actual error that
+// triggered this log line, if present. The err parameter is optional
+// and nil may be passed instead of an error instance.
+func (l Logger) Error(err error, msg string, keysAndValues ...interface{}) {
+ if withHelper, ok := l.sink.(CallStackHelperLogSink); ok {
+ withHelper.GetCallStackHelper()()
+ }
+ l.sink.Error(err, msg, keysAndValues...)
+}
+
+// V returns a new Logger instance for a specific verbosity level, relative to
+// this Logger. In other words, V-levels are additive. A higher verbosity
+// level means a log message is less important. Negative V-levels are treated
+// as 0.
+func (l Logger) V(level int) Logger {
+ if level < 0 {
+ level = 0
+ }
+ l.level += level
+ return l
+}
+
+// WithValues returns a new Logger instance with additional key/value pairs.
+// See Info for documentation on how key/value pairs work.
+func (l Logger) WithValues(keysAndValues ...interface{}) Logger {
+ l.setSink(l.sink.WithValues(keysAndValues...))
+ return l
+}
- // V returns an Logger value for a specific verbosity level, relative to
- // this Logger. In other words, V values are additive. V higher verbosity
- // level means a log message is less important. It's illegal to pass a log
- // level less than zero.
- V(level int) Logger
-
- // WithValues adds some key-value pairs of context to a logger.
- // See Info for documentation on how key/value pairs work.
- WithValues(keysAndValues ...interface{}) Logger
-
- // WithName adds a new element to the logger's name.
- // Successive calls with WithName continue to append
- // suffixes to the logger's name. It's strongly recommended
- // that name segments contain only letters, digits, and hyphens
- // (see the package documentation for more information).
- WithName(name string) Logger
+// WithName returns a new Logger instance with the specified name element added
+// to the Logger's name. Successive calls with WithName append additional
+// suffixes to the Logger's name. It's strongly recommended that name segments
+// contain only letters, digits, and hyphens (see the package documentation for
+// more information).
+func (l Logger) WithName(name string) Logger {
+ l.setSink(l.sink.WithName(name))
+ return l
}
-// InfoLogger provides compatibility with code that relies on the v0.1.0
-// interface.
+// WithCallDepth returns a Logger instance that offsets the call stack by the
+// specified number of frames when logging call site information, if possible.
+// This is useful for users who have helper functions between the "real" call
+// site and the actual calls to Logger methods. If depth is 0 the attribution
+// should be to the direct caller of this function. If depth is 1 the
+// attribution should skip 1 call frame, and so on. Successive calls to this
+// are additive.
+//
+// If the underlying log implementation supports a WithCallDepth(int) method,
+// it will be called and the result returned. If the implementation does not
+// support CallDepthLogSink, the original Logger will be returned.
+//
+// To skip one level, WithCallStackHelper() should be used instead of
+// WithCallDepth(1) because it works with implementions that support the
+// CallDepthLogSink and/or CallStackHelperLogSink interfaces.
+func (l Logger) WithCallDepth(depth int) Logger {
+ if withCallDepth, ok := l.sink.(CallDepthLogSink); ok {
+ l.setSink(withCallDepth.WithCallDepth(depth))
+ }
+ return l
+}
+
+// WithCallStackHelper returns a new Logger instance that skips the direct
+// caller when logging call site information, if possible. This is useful for
+// users who have helper functions between the "real" call site and the actual
+// calls to Logger methods and want to support loggers which depend on marking
+// each individual helper function, like loggers based on testing.T.
+//
+// In addition to using that new logger instance, callers also must call the
+// returned function.
//
-// Deprecated: InfoLogger is an artifact of early versions of this API. New
-// users should never use it and existing users should use Logger instead. This
-// will be removed in a future release.
-type InfoLogger = Logger
+// If the underlying log implementation supports a WithCallDepth(int) method,
+// WithCallDepth(1) will be called to produce a new logger. If it supports a
+// WithCallStackHelper() method, that will be also called. If the
+// implementation does not support either of these, the original Logger will be
+// returned.
+func (l Logger) WithCallStackHelper() (func(), Logger) {
+ var helper func()
+ if withCallDepth, ok := l.sink.(CallDepthLogSink); ok {
+ l.setSink(withCallDepth.WithCallDepth(1))
+ }
+ if withHelper, ok := l.sink.(CallStackHelperLogSink); ok {
+ helper = withHelper.GetCallStackHelper()
+ } else {
+ helper = func() {}
+ }
+ return helper, l
+}
+// contextKey is how we find Loggers in a context.Context.
type contextKey struct{}
-// FromContext returns a Logger constructed from ctx or nil if no
-// logger details are found.
-func FromContext(ctx context.Context) Logger {
+// FromContext returns a Logger from ctx or an error if no Logger is found.
+func FromContext(ctx context.Context) (Logger, error) {
if v, ok := ctx.Value(contextKey{}).(Logger); ok {
- return v
+ return v, nil
}
- return nil
+ return Logger{}, notFoundError{}
}
-// FromContextOrDiscard returns a Logger constructed from ctx or a Logger
-// that discards all messages if no logger details are found.
+// notFoundError exists to carry an IsNotFound method.
+type notFoundError struct{}
+
+func (notFoundError) Error() string {
+ return "no logr.Logger was present"
+}
+
+func (notFoundError) IsNotFound() bool {
+ return true
+}
+
+// FromContextOrDiscard returns a Logger from ctx. If no Logger is found, this
+// returns a Logger that discards all log messages.
func FromContextOrDiscard(ctx context.Context) Logger {
if v, ok := ctx.Value(contextKey{}).(Logger); ok {
return v
@@ -217,12 +381,59 @@ func FromContextOrDiscard(ctx context.Context) Logger {
return Discard()
}
-// NewContext returns a new context derived from ctx that embeds the Logger.
-func NewContext(ctx context.Context, l Logger) context.Context {
- return context.WithValue(ctx, contextKey{}, l)
+// NewContext returns a new Context, derived from ctx, which carries the
+// provided Logger.
+func NewContext(ctx context.Context, logger Logger) context.Context {
+ return context.WithValue(ctx, contextKey{}, logger)
}
-// CallDepthLogger represents a Logger that knows how to climb the call stack
+// RuntimeInfo holds information that the logr "core" library knows which
+// LogSinks might want to know.
+type RuntimeInfo struct {
+ // CallDepth is the number of call frames the logr library adds between the
+ // end-user and the LogSink. LogSink implementations which choose to print
+ // the original logging site (e.g. file & line) should climb this many
+ // additional frames to find it.
+ CallDepth int
+}
+
+// runtimeInfo is a static global. It must not be changed at run time.
+var runtimeInfo = RuntimeInfo{
+ CallDepth: 1,
+}
+
+// LogSink represents a logging implementation. End-users will generally not
+// interact with this type.
+type LogSink interface {
+ // Init receives optional information about the logr library for LogSink
+ // implementations that need it.
+ Init(info RuntimeInfo)
+
+ // Enabled tests whether this LogSink is enabled at the specified V-level.
+ // For example, commandline flags might be used to set the logging
+ // verbosity and disable some info logs.
+ Enabled(level int) bool
+
+ // Info logs a non-error message with the given key/value pairs as context.
+ // The level argument is provided for optional logging. This method will
+ // only be called when Enabled(level) is true. See Logger.Info for more
+ // details.
+ Info(level int, msg string, keysAndValues ...interface{})
+
+ // Error logs an error, with the given message and key/value pairs as
+ // context. See Logger.Error for more details.
+ Error(err error, msg string, keysAndValues ...interface{})
+
+ // WithValues returns a new LogSink with additional key/value pairs. See
+ // Logger.WithValues for more details.
+ WithValues(keysAndValues ...interface{}) LogSink
+
+ // WithName returns a new LogSink with the specified name appended. See
+ // Logger.WithName for more details.
+ WithName(name string) LogSink
+}
+
+// CallDepthLogSink represents a Logger that knows how to climb the call stack
// to identify the original call site and can offset the depth by a specified
// number of frames. This is useful for users who have helper functions
// between the "real" call site and the actual calls to Logger methods.
@@ -232,35 +443,59 @@ func NewContext(ctx context.Context, l Logger) context.Context {
//
// This is an optional interface and implementations are not required to
// support it.
-type CallDepthLogger interface {
- Logger
-
- // WithCallDepth returns a Logger that will offset the call stack by the
- // specified number of frames when logging call site information. If depth
- // is 0 the attribution should be to the direct caller of this method. If
- // depth is 1 the attribution should skip 1 call frame, and so on.
+type CallDepthLogSink interface {
+ // WithCallDepth returns a LogSink that will offset the call
+ // stack by the specified number of frames when logging call
+ // site information.
+ //
+ // If depth is 0, the LogSink should skip exactly the number
+ // of call frames defined in RuntimeInfo.CallDepth when Info
+ // or Error are called, i.e. the attribution should be to the
+ // direct caller of Logger.Info or Logger.Error.
+ //
+ // If depth is 1 the attribution should skip 1 call frame, and so on.
// Successive calls to this are additive.
- WithCallDepth(depth int) Logger
+ WithCallDepth(depth int) LogSink
}
-// WithCallDepth returns a Logger that will offset the call stack by the
-// specified number of frames when logging call site information, if possible.
-// This is useful for users who have helper functions between the "real" call
-// site and the actual calls to Logger methods. If depth is 0 the attribution
-// should be to the direct caller of this function. If depth is 1 the
-// attribution should skip 1 call frame, and so on. Successive calls to this
-// are additive.
+// CallStackHelperLogSink represents a Logger that knows how to climb
+// the call stack to identify the original call site and can skip
+// intermediate helper functions if they mark themselves as
+// helper. Go's testing package uses that approach.
//
-// If the underlying log implementation supports the CallDepthLogger interface,
-// the WithCallDepth method will be called and the result returned. If the
-// implementation does not support CallDepthLogger, the original Logger will be
-// returned.
+// This is useful for users who have helper functions between the
+// "real" call site and the actual calls to Logger methods.
+// Implementations that log information about the call site (such as
+// file, function, or line) would otherwise log information about the
+// intermediate helper functions.
//
-// Callers which care about whether this was supported or not should test for
-// CallDepthLogger support themselves.
-func WithCallDepth(logger Logger, depth int) Logger {
- if decorator, ok := logger.(CallDepthLogger); ok {
- return decorator.WithCallDepth(depth)
- }
- return logger
+// This is an optional interface and implementations are not required
+// to support it. Implementations that choose to support this must not
+// simply implement it as WithCallDepth(1), because
+// Logger.WithCallStackHelper will call both methods if they are
+// present. This should only be implemented for LogSinks that actually
+// need it, as with testing.T.
+type CallStackHelperLogSink interface {
+ // GetCallStackHelper returns a function that must be called
+ // to mark the direct caller as helper function when logging
+ // call site information.
+ GetCallStackHelper() func()
+}
+
+// Marshaler is an optional interface that logged values may choose to
+// implement. Loggers with structured output, such as JSON, should
+// log the object return by the MarshalLog method instead of the
+// original value.
+type Marshaler interface {
+ // MarshalLog can be used to:
+ // - ensure that structs are not logged as strings when the original
+ // value has a String method: return a different type without a
+ // String method
+ // - select which fields of a complex type should get logged:
+ // return a simpler struct with fewer fields
+ // - log unexported fields: return a different struct
+ // with exported fields
+ //
+ // It may return any value of any type.
+ MarshalLog() interface{}
}
diff --git a/vendor/k8s.io/klog/v2/go.mod b/vendor/k8s.io/klog/v2/go.mod
index eb297b6a1ed6..31aefba74a71 100644
--- a/vendor/k8s.io/klog/v2/go.mod
+++ b/vendor/k8s.io/klog/v2/go.mod
@@ -2,4 +2,4 @@ module k8s.io/klog/v2
go 1.13
-require github.com/go-logr/logr v0.4.0
+require github.com/go-logr/logr v1.2.0
diff --git a/vendor/k8s.io/klog/v2/go.sum b/vendor/k8s.io/klog/v2/go.sum
index 5778f81742b4..919fbadbc0d0 100644
--- a/vendor/k8s.io/klog/v2/go.sum
+++ b/vendor/k8s.io/klog/v2/go.sum
@@ -1,2 +1,2 @@
-github.com/go-logr/logr v0.4.0 h1:K7/B1jt6fIBQVd4Owv2MqGQClcgf0R266+7C/QjRcLc=
-github.com/go-logr/logr v0.4.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
+github.com/go-logr/logr v1.2.0 h1:QK40JKJyMdUDz+h+xvCsru/bJhvG0UxvePV0ufL/AcE=
+github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
diff --git a/vendor/k8s.io/klog/v2/klog.go b/vendor/k8s.io/klog/v2/klog.go
index 1e187f76354b..dacdf91120a7 100644
--- a/vendor/k8s.io/klog/v2/klog.go
+++ b/vendor/k8s.io/klog/v2/klog.go
@@ -509,7 +509,7 @@ type loggingT struct {
addDirHeader bool
// If set, all output will be redirected unconditionally to the provided logr.Logger
- logr logr.Logger
+ logr *logr.Logger
// If true, messages will not be propagated to lower severity log levels
oneOutput bool
@@ -698,11 +698,11 @@ func (buf *buffer) someDigits(i, d int) int {
return copy(buf.tmp[i:], buf.tmp[j:])
}
-func (l *loggingT) println(s severity, logr logr.Logger, filter LogFilter, args ...interface{}) {
+func (l *loggingT) println(s severity, logger *logr.Logger, filter LogFilter, args ...interface{}) {
buf, file, line := l.header(s, 0)
- // if logr is set, we clear the generated header as we rely on the backing
- // logr implementation to print headers
- if logr != nil {
+ // if logger is set, we clear the generated header as we rely on the backing
+ // logger implementation to print headers
+ if logger != nil {
l.putBuffer(buf)
buf = l.getBuffer()
}
@@ -710,18 +710,18 @@ func (l *loggingT) println(s severity, logr logr.Logger, filter LogFilter, args
args = filter.Filter(args)
}
fmt.Fprintln(buf, args...)
- l.output(s, logr, buf, 0 /* depth */, file, line, false)
+ l.output(s, logger, buf, 0 /* depth */, file, line, false)
}
-func (l *loggingT) print(s severity, logr logr.Logger, filter LogFilter, args ...interface{}) {
- l.printDepth(s, logr, filter, 1, args...)
+func (l *loggingT) print(s severity, logger *logr.Logger, filter LogFilter, args ...interface{}) {
+ l.printDepth(s, logger, filter, 1, args...)
}
-func (l *loggingT) printDepth(s severity, logr logr.Logger, filter LogFilter, depth int, args ...interface{}) {
+func (l *loggingT) printDepth(s severity, logger *logr.Logger, filter LogFilter, depth int, args ...interface{}) {
buf, file, line := l.header(s, depth)
// if logr is set, we clear the generated header as we rely on the backing
// logr implementation to print headers
- if logr != nil {
+ if logger != nil {
l.putBuffer(buf)
buf = l.getBuffer()
}
@@ -732,14 +732,14 @@ func (l *loggingT) printDepth(s severity, logr logr.Logger, filter LogFilter, de
if buf.Bytes()[buf.Len()-1] != '\n' {
buf.WriteByte('\n')
}
- l.output(s, logr, buf, depth, file, line, false)
+ l.output(s, logger, buf, depth, file, line, false)
}
-func (l *loggingT) printf(s severity, logr logr.Logger, filter LogFilter, format string, args ...interface{}) {
+func (l *loggingT) printf(s severity, logger *logr.Logger, filter LogFilter, format string, args ...interface{}) {
buf, file, line := l.header(s, 0)
// if logr is set, we clear the generated header as we rely on the backing
// logr implementation to print headers
- if logr != nil {
+ if logger != nil {
l.putBuffer(buf)
buf = l.getBuffer()
}
@@ -750,17 +750,17 @@ func (l *loggingT) printf(s severity, logr logr.Logger, filter LogFilter, format
if buf.Bytes()[buf.Len()-1] != '\n' {
buf.WriteByte('\n')
}
- l.output(s, logr, buf, 0 /* depth */, file, line, false)
+ l.output(s, logger, buf, 0 /* depth */, file, line, false)
}
// printWithFileLine behaves like print but uses the provided file and line number. If
// alsoLogToStderr is true, the log message always appears on standard error; it
// will also appear in the log file unless --logtostderr is set.
-func (l *loggingT) printWithFileLine(s severity, logr logr.Logger, filter LogFilter, file string, line int, alsoToStderr bool, args ...interface{}) {
+func (l *loggingT) printWithFileLine(s severity, logger *logr.Logger, filter LogFilter, file string, line int, alsoToStderr bool, args ...interface{}) {
buf := l.formatHeader(s, file, line)
// if logr is set, we clear the generated header as we rely on the backing
// logr implementation to print headers
- if logr != nil {
+ if logger != nil {
l.putBuffer(buf)
buf = l.getBuffer()
}
@@ -771,28 +771,28 @@ func (l *loggingT) printWithFileLine(s severity, logr logr.Logger, filter LogFil
if buf.Bytes()[buf.Len()-1] != '\n' {
buf.WriteByte('\n')
}
- l.output(s, logr, buf, 2 /* depth */, file, line, alsoToStderr)
+ l.output(s, logger, buf, 2 /* depth */, file, line, alsoToStderr)
}
// if loggr is specified, will call loggr.Error, otherwise output with logging module.
-func (l *loggingT) errorS(err error, loggr logr.Logger, filter LogFilter, depth int, msg string, keysAndValues ...interface{}) {
+func (l *loggingT) errorS(err error, logger *logr.Logger, filter LogFilter, depth int, msg string, keysAndValues ...interface{}) {
if filter != nil {
msg, keysAndValues = filter.FilterS(msg, keysAndValues)
}
- if loggr != nil {
- logr.WithCallDepth(loggr, depth+2).Error(err, msg, keysAndValues...)
+ if logger != nil {
+ logger.WithCallDepth(depth+2).Error(err, msg, keysAndValues...)
return
}
l.printS(err, errorLog, depth+1, msg, keysAndValues...)
}
// if loggr is specified, will call loggr.Info, otherwise output with logging module.
-func (l *loggingT) infoS(loggr logr.Logger, filter LogFilter, depth int, msg string, keysAndValues ...interface{}) {
+func (l *loggingT) infoS(logger *logr.Logger, filter LogFilter, depth int, msg string, keysAndValues ...interface{}) {
if filter != nil {
msg, keysAndValues = filter.FilterS(msg, keysAndValues)
}
- if loggr != nil {
- logr.WithCallDepth(loggr, depth+2).Info(msg, keysAndValues...)
+ if logger != nil {
+ logger.WithCallDepth(depth+2).Info(msg, keysAndValues...)
return
}
l.printS(nil, infoLog, depth+1, msg, keysAndValues...)
@@ -801,14 +801,19 @@ func (l *loggingT) infoS(loggr logr.Logger, filter LogFilter, depth int, msg str
// printS is called from infoS and errorS if loggr is not specified.
// set log severity by s
func (l *loggingT) printS(err error, s severity, depth int, msg string, keysAndValues ...interface{}) {
- b := &bytes.Buffer{}
- b.WriteString(fmt.Sprintf("%q", msg))
+ // Only create a new buffer if we don't have one cached.
+ b := l.getBuffer()
+ // The message is always quoted, even if it contains line breaks.
+ // If developers want multi-line output, they should use a small, fixed
+ // message and put the multi-line output into a value.
+ b.WriteString(strconv.Quote(msg))
if err != nil {
- b.WriteByte(' ')
- b.WriteString(fmt.Sprintf("err=%q", err.Error()))
+ kvListFormat(&b.Buffer, "err", err)
}
- kvListFormat(b, keysAndValues...)
- l.printDepth(s, logging.logr, nil, depth+1, b)
+ kvListFormat(&b.Buffer, keysAndValues...)
+ l.printDepth(s, logging.logr, nil, depth+1, &b.Buffer)
+ // Make the buffer available for reuse.
+ l.putBuffer(b)
}
const missingValue = "(MISSING)"
@@ -823,19 +828,106 @@ func kvListFormat(b *bytes.Buffer, keysAndValues ...interface{}) {
v = missingValue
}
b.WriteByte(' ')
+ // Keys are assumed to be well-formed according to
+ // https://github.com/kubernetes/community/blob/master/contributors/devel/sig-instrumentation/migration-to-structured-logging.md#name-arguments
+ // for the sake of performance. Keys with spaces,
+ // special characters, etc. will break parsing.
+ if k, ok := k.(string); ok {
+ // Avoid one allocation when the key is a string, which
+ // normally it should be.
+ b.WriteString(k)
+ } else {
+ b.WriteString(fmt.Sprintf("%s", k))
+ }
- switch v.(type) {
- case string, error:
- b.WriteString(fmt.Sprintf("%s=%q", k, v))
+ // The type checks are sorted so that more frequently used ones
+ // come first because that is then faster in the common
+ // cases. In Kubernetes, ObjectRef (a Stringer) is more common
+ // than plain strings
+ // (https://github.com/kubernetes/kubernetes/pull/106594#issuecomment-975526235).
+ switch v := v.(type) {
+ case fmt.Stringer:
+ writeStringValue(b, true, stringerToString(v))
+ case string:
+ writeStringValue(b, true, v)
+ case error:
+ writeStringValue(b, true, v.Error())
case []byte:
- b.WriteString(fmt.Sprintf("%s=%+q", k, v))
+ // In https://github.com/kubernetes/klog/pull/237 it was decided
+ // to format byte slices with "%+q". The advantages of that are:
+ // - readable output if the bytes happen to be printable
+ // - non-printable bytes get represented as unicode escape
+ // sequences (\uxxxx)
+ //
+ // The downsides are that we cannot use the faster
+ // strconv.Quote here and that multi-line output is not
+ // supported. If developers know that a byte array is
+ // printable and they want multi-line output, they can
+ // convert the value to string before logging it.
+ b.WriteByte('=')
+ b.WriteString(fmt.Sprintf("%+q", v))
default:
- if _, ok := v.(fmt.Stringer); ok {
- b.WriteString(fmt.Sprintf("%s=%q", k, v))
- } else {
- b.WriteString(fmt.Sprintf("%s=%+v", k, v))
- }
+ writeStringValue(b, false, fmt.Sprintf("%+v", v))
+ }
+ }
+}
+
+func stringerToString(s fmt.Stringer) (ret string) {
+ defer func() {
+ if err := recover(); err != nil {
+ ret = "nil"
+ }
+ }()
+ ret = s.String()
+ return
+}
+
+func writeStringValue(b *bytes.Buffer, quote bool, v string) {
+ data := []byte(v)
+ index := bytes.IndexByte(data, '\n')
+ if index == -1 {
+ b.WriteByte('=')
+ if quote {
+ // Simple string, quote quotation marks and non-printable characters.
+ b.WriteString(strconv.Quote(v))
+ return
}
+ // Non-string with no line breaks.
+ b.WriteString(v)
+ return
+ }
+
+ // Complex multi-line string, show as-is with indention like this:
+ // I... "hello world" key=<
+ // line 1
+ // line 2
+ // >
+ //
+ // Tabs indent the lines of the value while the end of string delimiter
+ // is indented with a space. That has two purposes:
+ // - visual difference between the two for a human reader because indention
+ // will be different
+ // - no ambiguity when some value line starts with the end delimiter
+ //
+ // One downside is that the output cannot distinguish between strings that
+ // end with a line break and those that don't because the end delimiter
+ // will always be on the next line.
+ b.WriteString("=<\n")
+ for index != -1 {
+ b.WriteByte('\t')
+ b.Write(data[0 : index+1])
+ data = data[index+1:]
+ index = bytes.IndexByte(data, '\n')
+ }
+ if len(data) == 0 {
+ // String ended with line break, don't add another.
+ b.WriteString(" >")
+ } else {
+ // No line break at end of last line, write rest of string and
+ // add one.
+ b.WriteByte('\t')
+ b.Write(data)
+ b.WriteString("\n >")
}
}
@@ -862,11 +954,23 @@ func (rb *redirectBuffer) Write(bytes []byte) (n int, err error) {
// Use as:
// ...
// klog.SetLogger(zapr.NewLogger(zapLog))
+//
+// To remove a backing logr implemention, use ClearLogger. Setting an
+// empty logger with SetLogger(logr.Logger{}) does not work.
func SetLogger(logr logr.Logger) {
logging.mu.Lock()
defer logging.mu.Unlock()
- logging.logr = logr
+ logging.logr = &logr
+}
+
+// ClearLogger removes a backing logr implementation if one was set earlier
+// with SetLogger.
+func ClearLogger() {
+ logging.mu.Lock()
+ defer logging.mu.Unlock()
+
+ logging.logr = nil
}
// SetOutput sets the output destination for all severities
@@ -904,8 +1008,16 @@ func LogToStderr(stderr bool) {
}
// output writes the data to the log files and releases the buffer.
-func (l *loggingT) output(s severity, log logr.Logger, buf *buffer, depth int, file string, line int, alsoToStderr bool) {
+func (l *loggingT) output(s severity, log *logr.Logger, buf *buffer, depth int, file string, line int, alsoToStderr bool) {
+ var isLocked = true
l.mu.Lock()
+ defer func() {
+ if isLocked {
+ // Unlock before returning in case that it wasn't done already.
+ l.mu.Unlock()
+ }
+ }()
+
if l.traceLocation.isSet() {
if l.traceLocation.match(file, line) {
buf.Write(stacks(false))
@@ -916,9 +1028,9 @@ func (l *loggingT) output(s severity, log logr.Logger, buf *buffer, depth int, f
// TODO: set 'severity' and caller information as structured log info
// keysAndValues := []interface{}{"severity", severityName[s], "file", file, "line", line}
if s == errorLog {
- logr.WithCallDepth(l.logr, depth+3).Error(nil, string(data))
+ l.logr.WithCallDepth(depth+3).Error(nil, string(data))
} else {
- logr.WithCallDepth(log, depth+3).Info(string(data))
+ log.WithCallDepth(depth + 3).Info(string(data))
}
} else if l.toStderr {
os.Stderr.Write(data)
@@ -968,6 +1080,7 @@ func (l *loggingT) output(s severity, log logr.Logger, buf *buffer, depth int, f
// If we got here via Exit rather than Fatal, print no stacks.
if atomic.LoadUint32(&fatalNoStacks) > 0 {
l.mu.Unlock()
+ isLocked = false
timeoutFlush(10 * time.Second)
os.Exit(1)
}
@@ -985,11 +1098,12 @@ func (l *loggingT) output(s severity, log logr.Logger, buf *buffer, depth int, f
}
}
l.mu.Unlock()
+ isLocked = false
timeoutFlush(10 * time.Second)
- os.Exit(255) // C++ uses -1, which is silly because it's anded with 255 anyway.
+ os.Exit(255) // C++ uses -1, which is silly because it's anded(&) with 255 anyway.
}
l.putBuffer(buf)
- l.mu.Unlock()
+
if stats := severityStats[s]; stats != nil {
atomic.AddInt64(&stats.lines, 1)
atomic.AddInt64(&stats.bytes, int64(len(data)))
@@ -1269,7 +1383,7 @@ func (l *loggingT) setV(pc uintptr) Level {
// See the documentation of V for more information.
type Verbose struct {
enabled bool
- logr logr.Logger
+ logr *logr.Logger
filter LogFilter
}
@@ -1277,7 +1391,8 @@ func newVerbose(level Level, b bool) Verbose {
if logging.logr == nil {
return Verbose{b, nil, logging.filter}
}
- return Verbose{b, logging.logr.V(int(level)), logging.filter}
+ v := logging.logr.V(int(level))
+ return Verbose{b, &v, logging.filter}
}
// V reports whether verbosity at the call site is at least the requested level.
@@ -1315,9 +1430,14 @@ func V(level Level) Verbose {
if runtime.Callers(2, logging.pcs[:]) == 0 {
return newVerbose(level, false)
}
- v, ok := logging.vmap[logging.pcs[0]]
+ // runtime.Callers returns "return PCs", but we want
+ // to look up the symbolic information for the call,
+ // so subtract 1 from the PC. runtime.CallersFrames
+ // would be cleaner, but allocates.
+ pc := logging.pcs[0] - 1
+ v, ok := logging.vmap[pc]
if !ok {
- v = logging.setV(logging.pcs[0])
+ v = logging.setV(pc)
}
return newVerbose(level, v >= level)
}
@@ -1369,6 +1489,14 @@ func InfoSDepth(depth int, msg string, keysAndValues ...interface{}) {
logging.infoS(logging.logr, logging.filter, depth, msg, keysAndValues...)
}
+// InfoSDepth is equivalent to the global InfoSDepth function, guarded by the value of v.
+// See the documentation of V for usage.
+func (v Verbose) InfoSDepth(depth int, msg string, keysAndValues ...interface{}) {
+ if v.enabled {
+ logging.infoS(v.logr, v.filter, depth, msg, keysAndValues...)
+ }
+}
+
// Deprecated: Use ErrorS instead.
func (v Verbose) Error(err error, msg string, args ...interface{}) {
if v.enabled {
@@ -1573,6 +1701,15 @@ func (ref ObjectRef) String() string {
return ref.Name
}
+// MarshalLog ensures that loggers with support for structured output will log
+// as a struct by removing the String method via a custom type.
+func (ref ObjectRef) MarshalLog() interface{} {
+ type or ObjectRef
+ return or(ref)
+}
+
+var _ logr.Marshaler = ObjectRef{}
+
// KMetadata is a subset of the kubernetes k8s.io/apimachinery/pkg/apis/meta/v1.Object interface
// this interface may expand in the future, but will always be a subset of the
// kubernetes k8s.io/apimachinery/pkg/apis/meta/v1.Object interface
@@ -1603,3 +1740,20 @@ func KRef(namespace, name string) ObjectRef {
Namespace: namespace,
}
}
+
+// KObjs returns slice of ObjectRef from an slice of ObjectMeta
+func KObjs(arg interface{}) []ObjectRef {
+ s := reflect.ValueOf(arg)
+ if s.Kind() != reflect.Slice {
+ return nil
+ }
+ objectRefs := make([]ObjectRef, 0, s.Len())
+ for i := 0; i < s.Len(); i++ {
+ if v, ok := s.Index(i).Interface().(KMetadata); ok {
+ objectRefs = append(objectRefs, KObj(v))
+ } else {
+ return nil
+ }
+ }
+ return objectRefs
+}
diff --git a/vendor/k8s.io/klog/v2/klog_file.go b/vendor/k8s.io/klog/v2/klog_file.go
index de830d9221c2..1025d644f38c 100644
--- a/vendor/k8s.io/klog/v2/klog_file.go
+++ b/vendor/k8s.io/klog/v2/klog_file.go
@@ -22,9 +22,7 @@ import (
"errors"
"fmt"
"os"
- "os/user"
"path/filepath"
- "runtime"
"strings"
"sync"
"time"
@@ -57,38 +55,6 @@ func init() {
}
}
-func getUserName() string {
- userNameOnce.Do(func() {
- // On Windows, the Go 'user' package requires netapi32.dll.
- // This affects Windows Nano Server:
- // https://github.com/golang/go/issues/21867
- // Fallback to using environment variables.
- if runtime.GOOS == "windows" {
- u := os.Getenv("USERNAME")
- if len(u) == 0 {
- return
- }
- // Sanitize the USERNAME since it may contain filepath separators.
- u = strings.Replace(u, `\`, "_", -1)
-
- // user.Current().Username normally produces something like 'USERDOMAIN\USERNAME'
- d := os.Getenv("USERDOMAIN")
- if len(d) != 0 {
- userName = d + "_" + u
- } else {
- userName = u
- }
- } else {
- current, err := user.Current()
- if err == nil {
- userName = current.Username
- }
- }
- })
-
- return userName
-}
-
// shortHostname returns its argument, truncating at the first period.
// For instance, given "www.google.com" it returns "www".
func shortHostname(hostname string) string {
diff --git a/vendor/k8s.io/klog/v2/klog_file_others.go b/vendor/k8s.io/klog/v2/klog_file_others.go
new file mode 100644
index 000000000000..aa467268512f
--- /dev/null
+++ b/vendor/k8s.io/klog/v2/klog_file_others.go
@@ -0,0 +1,19 @@
+//go:build !windows
+// +build !windows
+
+package klog
+
+import (
+ "os/user"
+)
+
+func getUserName() string {
+ userNameOnce.Do(func() {
+ current, err := user.Current()
+ if err == nil {
+ userName = current.Username
+ }
+ })
+
+ return userName
+}
diff --git a/vendor/k8s.io/klog/v2/klog_file_windows.go b/vendor/k8s.io/klog/v2/klog_file_windows.go
new file mode 100644
index 000000000000..2517f9c53841
--- /dev/null
+++ b/vendor/k8s.io/klog/v2/klog_file_windows.go
@@ -0,0 +1,34 @@
+//go:build windows
+// +build windows
+
+package klog
+
+import (
+ "os"
+ "strings"
+)
+
+func getUserName() string {
+ userNameOnce.Do(func() {
+ // On Windows, the Go 'user' package requires netapi32.dll.
+ // This affects Windows Nano Server:
+ // https://github.com/golang/go/issues/21867
+ // Fallback to using environment variables.
+ u := os.Getenv("USERNAME")
+ if len(u) == 0 {
+ return
+ }
+ // Sanitize the USERNAME since it may contain filepath separators.
+ u = strings.Replace(u, `\`, "_", -1)
+
+ // user.Current().Username normally produces something like 'USERDOMAIN\USERNAME'
+ d := os.Getenv("USERDOMAIN")
+ if len(d) != 0 {
+ userName = d + "_" + u
+ } else {
+ userName = u
+ }
+ })
+
+ return userName
+}
diff --git a/vendor/knative.dev/hack/presubmit-tests.sh b/vendor/knative.dev/hack/presubmit-tests.sh
index c3b279ba9a27..70a399c8e3c3 100644
--- a/vendor/knative.dev/hack/presubmit-tests.sh
+++ b/vendor/knative.dev/hack/presubmit-tests.sh
@@ -138,42 +138,18 @@ function default_build_test_runner() {
[[ -z "${go_pkg_dirs}" ]] && return ${failed}
# Ensure all the code builds
subheader "Checking that go code builds"
- local report
- report="$(mktemp)"
- local errors_go1=""
- local errors_go2=""
- if ! capture_output "${report}" go build -v ./... ; then
- failed=1
- # Consider an error message everything that's not a package name.
- errors_go1="$(grep -v '^\(github\.com\|knative\.dev\)/' "${report}" | sort | uniq)"
- fi
# Get all build tags in go code (ignore /vendor, /hack and /third_party)
local tags
- tags="$(grep -r '// +build' . \
- | grep -v '^./vendor/' | grep -v '^./hack/' | grep -v '^./third_party' \
- | cut -f3 -d' ' | tr ',' '\n' | sort | uniq | tr '\n' ' ')"
- local tagged_pkgs
- tagged_pkgs="$(grep -r '// +build' . \
- | grep -v '^./vendor/' | grep -v '^./hack/' | grep -v '^./third_party' \
- | grep ":// +build " | cut -f1 -d: | xargs dirname \
- | sort | uniq | tr '\n' ' ')"
- for pkg in ${tagged_pkgs}; do
- # `go test -c` lets us compile the tests but do not run them.
- if ! capture_output "${report}" go test -c -tags="${tags}" "${pkg}" ; then
- failed=1
- # Consider an error message everything that's not a successful test result.
- errors_go2+="$(grep -v '^\(ok\|\?\)\s\+\(github\.com\|knative\.dev\)/' "${report}")"
- fi
- # Remove unused generated binary, if any.
- rm -f e2e.test
- done
+ tags="$(find . \
+ -path './vendor' -prune -o -path './hack' -prune -o -path './third_party' -prune \
+ -o -type f -name '*.go' -exec grep '// +build' {} + \
+ | cut -f3 -d' ' | tr ',' '\n' | uniq | sort | tr '\n' ' ')"
+ report_build_test Build_Go \
+ go test -vet=off -tags "${tags}" -exec echo ./... || failed=2
- local errors_go
- errors_go="$(echo -e "${errors_go1}\n${errors_go2}" | uniq)"
- create_junit_xml _build_tests Build_Go "${errors_go}"
# Check that we don't have any forbidden licenses in our images.
subheader "Checking for forbidden licenses"
- report_build_test Check_Licenses check_licenses || failed=1
+ report_build_test Check_Licenses check_licenses || failed=3
return ${failed}
}
diff --git a/vendor/knative.dev/pkg/apis/duck/v1/source_types.go b/vendor/knative.dev/pkg/apis/duck/v1/source_types.go
index 2c5493d8cd19..bed832f32f12 100644
--- a/vendor/knative.dev/pkg/apis/duck/v1/source_types.go
+++ b/vendor/knative.dev/pkg/apis/duck/v1/source_types.go
@@ -181,9 +181,10 @@ func (s *Source) Validate(ctx context.Context) *apis.FieldError {
func (s *SourceSpec) Validate(ctx context.Context) *apis.FieldError {
if s == nil {
- return nil
+ return apis.ErrMissingField("spec")
}
- return s.CloudEventOverrides.Validate(ctx).ViaField("ceOverrides")
+ return s.Sink.Validate(ctx).ViaField("sink").
+ Also(s.CloudEventOverrides.Validate(ctx).ViaField("ceOverrides"))
}
func (ceOverrides *CloudEventOverrides) Validate(ctx context.Context) *apis.FieldError {
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/client.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/client.go
index 41cc82eaffcc..602a06911cf4 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/client.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/client.go
@@ -29,7 +29,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// clientGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/duck.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/duck.go
index 678ddcc7dd34..997863f2654a 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/duck.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/duck.go
@@ -23,7 +23,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// duckGenerator produces logic to register a duck.InformerFactory for a particular
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/factory.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/factory.go
index 55a0db18cb25..1885cad6bb84 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/factory.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/factory.go
@@ -23,7 +23,7 @@ import (
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// factoryTestGenerator produces a file of factory injection of a given type.
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_client.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_client.go
index 76725f2bd963..4eee7212ffde 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_client.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_client.go
@@ -22,7 +22,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// fakeClientGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_duck.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_duck.go
index 8d7616a39292..d297c896750f 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_duck.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_duck.go
@@ -23,7 +23,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// fakeDuckGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_factory.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_factory.go
index 63fbdc37944e..d0f25d00a8aa 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_factory.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_factory.go
@@ -22,7 +22,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// fakeFactoryGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_filtered_factory.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_filtered_factory.go
index 1e747f4b7b4f..c5a9f972869f 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_filtered_factory.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_filtered_factory.go
@@ -22,7 +22,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// fakeFilteredFactoryGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_filtered_informer.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_filtered_informer.go
index 47b7008844f1..7e5e8ae203ad 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_filtered_informer.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_filtered_informer.go
@@ -23,7 +23,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// fakeFilteredInformerGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_informer.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_informer.go
index 6be8a1b692b0..84769e05d954 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_informer.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/fake_informer.go
@@ -23,7 +23,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// fakeInformerGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/filtered_factory.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/filtered_factory.go
index 58e65432f5a1..f82923062234 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/filtered_factory.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/filtered_factory.go
@@ -22,8 +22,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
-
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// factoryTestGenerator produces a file of factory injection of a given type.
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/filtered_informer.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/filtered_informer.go
index 3100052a86d2..53debfb38e53 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/filtered_informer.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/filtered_informer.go
@@ -24,7 +24,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// injectionTestGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/informer.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/informer.go
index 2138b85f6a73..d00158b28e56 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/informer.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/informer.go
@@ -24,7 +24,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// injectionTestGenerator produces a file of listers for a given GroupVersion and
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/packages.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/packages.go
index f79339824bf2..62a143d43ed5 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/packages.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/packages.go
@@ -27,7 +27,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
informergenargs "knative.dev/pkg/codegen/cmd/injection-gen/args"
)
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_controller.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_controller.go
index 63556dec60ac..376623537a04 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_controller.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_controller.go
@@ -22,7 +22,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// reconcilerControllerGenerator produces a file for setting up the reconciler
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_controller_stub.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_controller_stub.go
index 13dff4d51692..83b913d5e4cd 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_controller_stub.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_controller_stub.go
@@ -22,7 +22,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// reconcilerControllerStubGenerator produces a file of the stub of the
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_reconciler.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_reconciler.go
index 5e3f23faf41b..a292a24b5572 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_reconciler.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_reconciler.go
@@ -24,7 +24,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// reconcilerReconcilerGenerator produces a reconciler struct for the given type.
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_reconciler_stub.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_reconciler_stub.go
index 197afe9d0e16..bb7d59eeaa97 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_reconciler_stub.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_reconciler_stub.go
@@ -22,7 +22,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// reconcilerReconcilerStubGenerator produces a file of the stub of how to
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_state.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_state.go
index 9ef36250536c..08b148efff15 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_state.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/generators/reconciler_state.go
@@ -22,7 +22,7 @@ import (
"k8s.io/gengo/generator"
"k8s.io/gengo/namer"
"k8s.io/gengo/types"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
// reconcilerStateGenerator produces a reconciler state object to manage reconciliation runs.
diff --git a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/main.go b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/main.go
index 30f20a0dd3fa..eae5699f7398 100644
--- a/vendor/knative.dev/pkg/codegen/cmd/injection-gen/main.go
+++ b/vendor/knative.dev/pkg/codegen/cmd/injection-gen/main.go
@@ -22,7 +22,7 @@ import (
"k8s.io/code-generator/pkg/util"
"k8s.io/gengo/args"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
"github.com/spf13/pflag"
generatorargs "knative.dev/pkg/codegen/cmd/injection-gen/args"
diff --git a/vendor/knative.dev/pkg/injection/config.go b/vendor/knative.dev/pkg/injection/config.go
index f54f84b45194..c3531b9e4073 100644
--- a/vendor/knative.dev/pkg/injection/config.go
+++ b/vendor/knative.dev/pkg/injection/config.go
@@ -21,7 +21,7 @@ import (
"log"
"k8s.io/client-go/rest"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
"knative.dev/pkg/environment"
)
diff --git a/vendor/knative.dev/pkg/test/logging/logging.go b/vendor/knative.dev/pkg/test/logging/logging.go
index ace644699442..74df6dfdeaad 100644
--- a/vendor/knative.dev/pkg/test/logging/logging.go
+++ b/vendor/knative.dev/pkg/test/logging/logging.go
@@ -33,7 +33,7 @@ import (
"go.opencensus.io/trace"
"go.uber.org/zap"
"go.uber.org/zap/zapcore"
- "k8s.io/klog"
+ "k8s.io/klog/v2"
)
const (
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 5c2761cebb91..3a0ffe9ea15a 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -122,7 +122,7 @@ github.com/go-kit/log
github.com/go-kit/log/level
# github.com/go-logfmt/logfmt v0.5.0
github.com/go-logfmt/logfmt
-# github.com/go-logr/logr v0.4.0
+# github.com/go-logr/logr v1.2.2
github.com/go-logr/logr
# github.com/go-openapi/jsonpointer v0.19.5
github.com/go-openapi/jsonpointer
@@ -966,7 +966,7 @@ k8s.io/gengo/parser
k8s.io/gengo/types
# k8s.io/klog v1.0.0
k8s.io/klog
-# k8s.io/klog/v2 v2.9.0
+# k8s.io/klog/v2 v2.40.1
k8s.io/klog/v2
# k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c
## explicit
@@ -986,7 +986,7 @@ k8s.io/utils/buffer
k8s.io/utils/integer
k8s.io/utils/pointer
k8s.io/utils/trace
-# knative.dev/caching v0.0.0-20220105210833-30ba0b6609c6
+# knative.dev/caching v0.0.0-20220111134414-669d362b44c5
## explicit
knative.dev/caching/config
knative.dev/caching/pkg/apis/caching
@@ -1007,7 +1007,7 @@ knative.dev/caching/pkg/client/injection/informers/caching/v1alpha1/image/fake
knative.dev/caching/pkg/client/injection/informers/factory
knative.dev/caching/pkg/client/injection/informers/factory/fake
knative.dev/caching/pkg/client/listers/caching/v1alpha1
-# knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7
+# knative.dev/hack v0.0.0-20220111151514-59b0cf17578e
## explicit
knative.dev/hack
knative.dev/hack/shell
@@ -1041,7 +1041,7 @@ knative.dev/networking/pkg/client/injection/reconciler/networking/v1alpha1/serve
knative.dev/networking/pkg/client/listers/networking/v1alpha1
knative.dev/networking/pkg/ingress
knative.dev/networking/pkg/prober
-# knative.dev/pkg v0.0.0-20220105211333-96f18522d78d
+# knative.dev/pkg v0.0.0-20220111210214-785eb637f693
## explicit
knative.dev/pkg/apiextensions/storageversion
knative.dev/pkg/apiextensions/storageversion/cmd/migrate
From 421358cebe0f39dbda951b6e8f714a40b16b2e7e Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Wed, 12 Jan 2022 06:12:51 -0800
Subject: [PATCH 077/733] Update net-kourier nightly (#12486)
bumping knative.dev/net-kourier e86bc44...7c0be88:
> 7c0be88 Fix TLS listener filter chains when configured with both a secret (via env vars) and SNI (# 743)
> 32452c2 upgrade to latest dependencies (# 746)
> dfd10a6 Update community files (# 745)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index dd3a80c9fb06..0770d6dd389d 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
- serving.knative.dev/release: "v20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
+ serving.knative.dev/release: "v20220112-7c0be88f"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:c50efeb18d2a2ece78f257ce887de4191c66458343b4cc7d3cc60d409d6e5a72
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:e4b232ef86d147f3f85351694b56bf9ac22fe4d29c516b14578b2a1ac30eae41
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220106-e86bc445"
+ app.kubernetes.io/version: "20220112-7c0be88f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220106-e86bc445"
+ serving.knative.dev/release: "v20220112-7c0be88f"
spec:
ports:
- name: http2
From 9de0607dfdbe19a877390169d20e39adcce89cfa Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Wed, 12 Jan 2022 07:24:51 -0800
Subject: [PATCH 078/733] Update net-istio nightly (#12492)
bumping knative.dev/net-istio 4c6d3dc...2ab0b98:
> 2ab0b98 upgrade to latest dependencies (# 843)
> 01fef1a Update community files (# 842)
Signed-off-by: Knative Automation
---
third_party/istio-latest/net-istio.yaml | 70 ++++++++++++-------------
1 file changed, 35 insertions(+), 35 deletions(-)
diff --git a/third_party/istio-latest/net-istio.yaml b/third_party/istio-latest/net-istio.yaml
index f91568faf4a3..6d0df389f4ff 100644
--- a/third_party/istio-latest/net-istio.yaml
+++ b/third_party/istio-latest/net-istio.yaml
@@ -1,4 +1,4 @@
-# Generated when HEAD was 4c6d3dccd0d02ad86cbeb7100421a09baabfeb99
+# Generated when HEAD was 2ab0b98d40edbffd8ffef7fb03ee678c457f57ad
#
# Copyright 2019 The Knative Authors
#
@@ -22,8 +22,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
serving.knative.dev/controller: "true"
networking.knative.dev/ingress-provider: istio
rules:
@@ -55,8 +55,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -95,8 +95,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -117,8 +117,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -153,8 +153,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
data:
_example: |
@@ -220,8 +220,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -239,8 +239,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -258,8 +258,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -292,8 +292,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -311,15 +311,15 @@ spec:
app: net-istio-controller
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:832013e392703b6e3e98066d711e2a960a30e1879de20bc2e114717141aad1a1
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:126e41eac7774d4d19516b5f48cdfd0e57e8a8c56567d490e7de5e370b63fbd1
resources:
requests:
cpu: 30m
@@ -378,8 +378,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -395,15 +395,15 @@ spec:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:40132c68c6911ccd1ce7537df0e6201b5dcebb1de19b5bed21fbc55f6cc0db45
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:d4109aaeefb3d1d007528fd6027981f22af6b711159b911038aa95383479d785
resources:
requests:
cpu: 20m
@@ -458,8 +458,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
---
@@ -486,8 +486,8 @@ metadata:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
spec:
ports:
@@ -526,8 +526,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -566,8 +566,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220105-4c6d3dcc"
- serving.knative.dev/release: "v20220105-4c6d3dcc"
+ app.kubernetes.io/version: "20220112-2ab0b98d"
+ serving.knative.dev/release: "v20220112-2ab0b98d"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
From efd5db6eb5f08a5676747027e28d6355a6509f35 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Wed, 12 Jan 2022 07:24:58 -0800
Subject: [PATCH 079/733] Update net-gateway-api nightly (#12493)
bumping knative.dev/net-gateway-api f8e5a0d...efb9e44:
> efb9e44 upgrade to latest dependencies (# 229)
> 54511b3 Update community files (# 228)
Signed-off-by: Knative Automation
---
third_party/gateway-api-latest/istio-gateway.yaml | 2 +-
third_party/gateway-api-latest/net-gateway-api.yaml | 12 ++++++------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/third_party/gateway-api-latest/istio-gateway.yaml b/third_party/gateway-api-latest/istio-gateway.yaml
index bff5d4055810..c7a55ea7bd59 100644
--- a/third_party/gateway-api-latest/istio-gateway.yaml
+++ b/third_party/gateway-api-latest/istio-gateway.yaml
@@ -20,7 +20,7 @@ metadata:
name: knative-local-gateway
namespace: istio-system
labels:
- serving.knative.dev/release: "v20220105-f8e5a0d1"
+ serving.knative.dev/release: "v20220112-efb9e447"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
diff --git a/third_party/gateway-api-latest/net-gateway-api.yaml b/third_party/gateway-api-latest/net-gateway-api.yaml
index 4f9a0e736a0c..2c55f6b57262 100644
--- a/third_party/gateway-api-latest/net-gateway-api.yaml
+++ b/third_party/gateway-api-latest/net-gateway-api.yaml
@@ -2125,7 +2125,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-admin
labels:
- serving.knative.dev/release: "v20220105-f8e5a0d1"
+ serving.knative.dev/release: "v20220112-efb9e447"
aggregationRule:
clusterRoleSelectors:
- matchLabels:
@@ -2137,7 +2137,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-core
labels:
- serving.knative.dev/release: "v20220105-f8e5a0d1"
+ serving.knative.dev/release: "v20220112-efb9e447"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["networking.x-k8s.io"]
@@ -2165,7 +2165,7 @@ metadata:
name: config-gateway
namespace: knative-serving
labels:
- serving.knative.dev/release: "v20220105-f8e5a0d1"
+ serving.knative.dev/release: "v20220112-efb9e447"
data:
_example: |
################################
@@ -2219,9 +2219,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: net-gateway-api
app.kubernetes.io/component: net-gateway-api
- app.kubernetes.io/version: "20220105-f8e5a0d1"
+ app.kubernetes.io/version: "20220112-efb9e447"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-f8e5a0d1"
+ serving.knative.dev/release: "v20220112-efb9e447"
spec:
replicas: 1
selector:
@@ -2247,7 +2247,7 @@ spec:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:b6bb9c6ac954aca022b0540632a45af38316f88cbea6ca9e1e729973662ed78b
+ image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:6960594fdc6421722e54d7acf9e02f087ff6bbcd14d950313c0e39bcccdd0e1a
resources:
requests:
cpu: 100m
From 363932568df76328cf8be9af7d94303ed59086fc Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Wed, 12 Jan 2022 07:25:05 -0800
Subject: [PATCH 080/733] Update net-contour nightly (#12494)
bumping knative.dev/net-contour 35a6137...93dc2a3:
> 93dc2a3 Update actions (# 700)
> d6e75c8 [release-1.2] Bump Contour to v1.19.1 (# 694)
> 0a76979 Update community files (# 698)
Signed-off-by: Knative Automation
---
third_party/contour-latest/contour.yaml | 1620 ++++++++++++++++++-
third_party/contour-latest/net-contour.yaml | 10 +-
2 files changed, 1596 insertions(+), 34 deletions(-)
diff --git a/third_party/contour-latest/contour.yaml b/third_party/contour-latest/contour.yaml
index a7a26133ec40..7ba0cb5ae389 100644
--- a/third_party/contour-latest/contour.yaml
+++ b/third_party/contour-latest/contour.yaml
@@ -53,8 +53,6 @@ data:
# Specify the Gateway API configuration.
# gateway:
# controllerName: projectcontour.io/projectcontour/contour
- # name: contour
- # namespace: contour-external
#
# should contour expect to be running inside a k8s cluster
# incluster: true
@@ -97,6 +95,10 @@ data:
# Please see the advisory at https://github.com/projectcontour/contour/security/advisories/GHSA-5ph6-qq5x-7jwc for the details.
# enableExternalNameService: false
##
+ # Address to be placed in status.loadbalancer field of Ingress objects.
+ # May be either a literal IP address or a host name.
+ # The value will be placed directly into the relevant field inside the status.loadBalancer struct.
+ # ingress-status-address: local.projectcontour.io
### Logging options
# Default setting
accesslog-format: envoy
@@ -198,7 +200,1403 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ controller-gen.kubebuilder.io/version: v0.6.0
+ creationTimestamp: null
+ name: contourconfigurations.projectcontour.io
+ labels:
+ networking.knative.dev/ingress-provider: contour
+spec:
+ preserveUnknownFields: false
+ group: projectcontour.io
+ names:
+ kind: ContourConfiguration
+ listKind: ContourConfigurationList
+ plural: contourconfigurations
+ shortNames:
+ - contourconfig
+ singular: contourconfiguration
+ scope: Namespaced
+ versions:
+ - name: v1alpha1
+ schema:
+ openAPIV3Schema:
+ description: ContourConfiguration is the schema for a Contour instance.
+ properties:
+ apiVersion:
+ description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
+ type: string
+ kind:
+ description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
+ type: string
+ metadata:
+ type: object
+ spec:
+ description: ContourConfigurationSpec represents a configuration of a Contour controller. It contains most of all the options that can be customized, the other remaining options being command line flags.
+ properties:
+ debug:
+ default:
+ kubernetesLogLevel: 0
+ logLevel: info
+ description: Debug contains parameters to enable debug logging and debug interfaces inside Contour.
+ properties:
+ address:
+ description: Defines the Contour debug address interface.
+ type: string
+ kubernetesLogLevel:
+ default: 0
+ description: "KubernetesDebugLogLevel defines the log level which Contour will use when outputting Kubernetes specific log information. \n Details: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-instrumentation/logging.md"
+ maximum: 9
+ minimum: 0
+ type: integer
+ logLevel:
+ description: DebugLogLevel defines the log level which Contour will use when outputting log information.
+ enum:
+ - info
+ - debug
+ type: string
+ port:
+ description: Defines the Contour debug address port.
+ type: integer
+ required:
+ - logLevel
+ type: object
+ enableExternalNameService:
+ default: false
+ description: EnableExternalNameService allows processing of ExternalNameServices Defaults to disabled for security reasons.
+ type: boolean
+ envoy:
+ default:
+ cluster:
+ dnsLookupFamily: auto
+ defaultHTTPVersions:
+ - HTTP/1.1
+ - HTTP/2
+ http:
+ accessLog: /dev/stdout
+ address: 0.0.0.0
+ port: 8080
+ https:
+ accessLog: /dev/stdout
+ address: 0.0.0.0
+ port: 8443
+ listener:
+ connectionBalancer: ""
+ disableAllowChunkedLength: false
+ tls:
+ cipherSuites:
+ - '[ECDHE-ECDSA-AES128-GCM-SHA256|ECDHE-ECDSA-CHACHA20-POLY1305]'
+ - '[ECDHE-RSA-AES128-GCM-SHA256|ECDHE-RSA-CHACHA20-POLY1305]'
+ - ECDHE-ECDSA-AES256-GCM-SHA384
+ - ECDHE-RSA-AES256-GCM-SHA384
+ minimumProtocolVersion: "1.2"
+ useProxyProtocol: false
+ logging:
+ accessLogFormat: envoy
+ metrics:
+ address: 0.0.0.0
+ port: 8002
+ network:
+ adminPort: 9001
+ service:
+ name: envoy
+ namespace: projectcontour
+ description: Envoy contains parameters for Envoy as well as how to optionally configure a managed Envoy fleet.
+ properties:
+ clientCertificate:
+ description: ClientCertificate defines the namespace/name of the Kubernetes secret containing the client certificate and private key to be used when establishing TLS connection to upstream cluster.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ cluster:
+ description: Cluster holds various configurable Envoy cluster values that can be set in the config file.
+ properties:
+ dnsLookupFamily:
+ default: auto
+ description: "DNSLookupFamily defines how external names are looked up When configured as V4, the DNS resolver will only perform a lookup for addresses in the IPv4 family. If V6 is configured, the DNS resolver will only perform a lookup for addresses in the IPv6 family. If AUTO is configured, the DNS resolver will first perform a lookup for addresses in the IPv6 family and fallback to a lookup for addresses in the IPv4 family. Note: This only applies to externalName clusters. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/cluster/v3/cluster.proto.html#envoy-v3-api-enum-config-cluster-v3-cluster-dnslookupfamily for more information."
+ enum:
+ - auto
+ - v4
+ - v6
+ type: string
+ required:
+ - dnsLookupFamily
+ type: object
+ defaultHTTPVersions:
+ description: DefaultHTTPVersions defines the default set of HTTPS versions the proxy should accept. HTTP versions are strings of the form "HTTP/xx". Supported versions are "HTTP/1.1" and "HTTP/2".
+ items:
+ description: HTTPVersionType is the name of a supported HTTP version.
+ enum:
+ - HTTP/1.1
+ - HTTP/2
+ type: string
+ type: array
+ http:
+ default:
+ accessLog: /dev/stdout
+ address: 0.0.0.0
+ port: 8080
+ description: Defines the HTTP Listener for Envoy.
+ properties:
+ accessLog:
+ description: AccessLog defines where Envoy logs are outputted for this listener.
+ type: string
+ address:
+ description: Defines an Envoy Listener Address.
+ minLength: 1
+ type: string
+ port:
+ description: Defines an Envoy listener Port.
+ type: integer
+ required:
+ - accessLog
+ - address
+ - port
+ type: object
+ https:
+ default:
+ accessLog: /dev/stdout
+ address: 0.0.0.0
+ port: 8443
+ description: Defines the HTTP Listener for Envoy.
+ properties:
+ accessLog:
+ description: AccessLog defines where Envoy logs are outputted for this listener.
+ type: string
+ address:
+ description: Defines an Envoy Listener Address.
+ minLength: 1
+ type: string
+ port:
+ description: Defines an Envoy listener Port.
+ type: integer
+ required:
+ - accessLog
+ - address
+ - port
+ type: object
+ listener:
+ description: Listener hold various configurable Envoy listener values.
+ properties:
+ connectionBalancer:
+ description: ConnectionBalancer. If the value is exact, the listener will use the exact connection balancer See https://www.envoyproxy.io/docs/envoy/latest/api-v2/api/v2/listener.proto#envoy-api-msg-listener-connectionbalanceconfig for more information.
+ enum:
+ - ""
+ - exact
+ type: string
+ disableAllowChunkedLength:
+ description: 'DisableAllowChunkedLength disables the RFC-compliant Envoy behavior to strip the "Content-Length" header if "Transfer-Encoding: chunked" is also set. This is an emergency off-switch to revert back to Envoy''s default behavior in case of failures. Please file an issue if failures are encountered. See: https://github.com/projectcontour/contour/issues/3221'
+ type: boolean
+ tls:
+ description: TLS holds various configurable Envoy TLS listener values.
+ properties:
+ cipherSuites:
+ description: "CipherSuites defines the TLS ciphers to be supported by Envoy TLS listeners when negotiating TLS 1.2. Ciphers are validated against the set that Envoy supports by default. This parameter should only be used by advanced users. Note that these will be ignored when TLS 1.3 is in use. \n See: https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/transport_sockets/tls/v3/common.proto#extensions-transport-sockets-tls-v3-tlsparameters Note: This list is a superset of what is valid for stock Envoy builds and those using BoringSSL FIPS."
+ items:
+ enum:
+ - '[ECDHE-ECDSA-AES128-GCM-SHA256|ECDHE-ECDSA-CHACHA20-POLY1305]'
+ - '[ECDHE-RSA-AES128-GCM-SHA256|ECDHE-RSA-CHACHA20-POLY1305]'
+ - ECDHE-ECDSA-AES128-GCM-SHA256
+ - ECDHE-RSA-AES128-GCM-SHA256
+ - ECDHE-ECDSA-AES128-SHA
+ - ECDHE-RSA-AES128-SHA
+ - AES128-GCM-SHA256
+ - AES128-SHA
+ - ECDHE-ECDSA-AES256-GCM-SHA384
+ - ECDHE-RSA-AES256-GCM-SHA384
+ - ECDHE-ECDSA-AES256-SHA
+ - ECDHE-RSA-AES256-SHA
+ - AES256-GCM-SHA384
+ - AES256-SHA
+ type: string
+ type: array
+ minimumProtocolVersion:
+ description: MinimumProtocolVersion is the minimum TLS version this vhost should negotiate. Valid options are `1.2` (default) and `1.3`.
+ enum:
+ - "1.2"
+ - "1.3"
+ type: string
+ required:
+ - cipherSuites
+ - minimumProtocolVersion
+ type: object
+ useProxyProtocol:
+ description: Use PROXY protocol for all listeners.
+ type: boolean
+ required:
+ - connectionBalancer
+ - disableAllowChunkedLength
+ - tls
+ - useProxyProtocol
+ type: object
+ logging:
+ description: Logging defines how Envoy's logs can be configured.
+ properties:
+ accessLogFormat:
+ description: AccessLogFormat sets the global access log format. Valid options are 'envoy' or 'json'
+ enum:
+ - envoy
+ - json
+ type: string
+ accessLogFormatString:
+ description: AccessLogFormatString sets the access log format when format is set to `envoy`. When empty, Envoy's default format is used.
+ type: string
+ jsonFields:
+ description: AccessLogFields sets the fields that JSON logging will output when AccessLogFormat is json.
+ items:
+ type: string
+ type: array
+ required:
+ - accessLogFormat
+ type: object
+ metrics:
+ default:
+ address: 0.0.0.0
+ port: 8002
+ description: Metrics defines the endpoints Envoy use to serve to metrics.
+ properties:
+ address:
+ description: Defines the metrics address interface.
+ maxLength: 253
+ minLength: 1
+ type: string
+ port:
+ description: Defines the metrics port.
+ type: integer
+ required:
+ - address
+ - port
+ type: object
+ network:
+ description: Network holds various configurable Envoy network values.
+ properties:
+ adminPort:
+ default: 9001
+ description: Configure the port used to access the Envoy Admin interface. If configured to port "0" then the admin interface is disabled.
+ type: integer
+ numTrustedHops:
+ description: "XffNumTrustedHops defines the number of additional ingress proxy hops from the right side of the x-forwarded-for HTTP header to trust when determining the origin client’s IP address. \n See https://www.envoyproxy.io/docs/envoy/v1.17.0/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto?highlight=xff_num_trusted_hops for more information."
+ format: int32
+ type: integer
+ required:
+ - adminPort
+ type: object
+ service:
+ default:
+ name: envoy
+ namespace: projectcontour
+ description: Service holds Envoy service parameters for setting Ingress status.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ timeouts:
+ description: Timeouts holds various configurable timeouts that can be set in the config file.
+ properties:
+ connectionIdleTimeout:
+ description: "ConnectionIdleTimeout defines how long the proxy should wait while there are no active requests (for HTTP/1.1) or streams (for HTTP/2) before terminating an HTTP connection. Set to \"infinity\" to disable the timeout entirely. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/protocol.proto#envoy-v3-api-field-config-core-v3-httpprotocoloptions-idle-timeout for more information."
+ type: string
+ connectionShutdownGracePeriod:
+ description: "ConnectionShutdownGracePeriod defines how long the proxy will wait between sending an initial GOAWAY frame and a second, final GOAWAY frame when terminating an HTTP/2 connection. During this grace period, the proxy will continue to respond to new streams. After the final GOAWAY frame has been sent, the proxy will refuse new streams. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto#envoy-v3-api-field-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-drain-timeout for more information."
+ type: string
+ delayedCloseTimeout:
+ description: "DelayedCloseTimeout defines how long envoy will wait, once connection close processing has been initiated, for the downstream peer to close the connection before Envoy closes the socket associated with the connection. \n Setting this timeout to 'infinity' will disable it, equivalent to setting it to '0' in Envoy. Leaving it unset will result in the Envoy default value being used. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto#envoy-v3-api-field-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-delayed-close-timeout for more information."
+ type: string
+ maxConnectionDuration:
+ description: "MaxConnectionDuration defines the maximum period of time after an HTTP connection has been established from the client to the proxy before it is closed by the proxy, regardless of whether there has been activity or not. Omit or set to \"infinity\" for no max duration. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/protocol.proto#envoy-v3-api-field-config-core-v3-httpprotocoloptions-max-connection-duration for more information."
+ type: string
+ requestTimeout:
+ description: "RequestTimeout sets the client request timeout globally for Contour. Note that this is a timeout for the entire request, not an idle timeout. Omit or set to \"infinity\" to disable the timeout entirely. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto#envoy-v3-api-field-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-request-timeout for more information."
+ type: string
+ streamIdleTimeout:
+ description: "StreamIdleTimeout defines how long the proxy should wait while there is no request activity (for HTTP/1.1) or stream activity (for HTTP/2) before terminating the HTTP request or stream. Set to \"infinity\" to disable the timeout entirely. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto#envoy-v3-api-field-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-stream-idle-timeout for more information."
+ type: string
+ type: object
+ required:
+ - cluster
+ - defaultHTTPVersions
+ - http
+ - https
+ - listener
+ - logging
+ - metrics
+ - network
+ - service
+ type: object
+ gateway:
+ description: Gateway contains parameters for the gateway-api Gateway that Contour is configured to serve traffic.
+ properties:
+ controllerName:
+ default: projectcontour.io/projectcontour/contour
+ description: ControllerName is used to determine whether Contour should reconcile a GatewayClass. The string takes the form of "projectcontour.io//contour". If unset, the gatewayclass controller will not be started.
+ type: string
+ required:
+ - controllerName
+ type: object
+ health:
+ default:
+ address: 0.0.0.0
+ port: 8000
+ description: Health contains parameters to configure endpoints which Contour exposes to respond to Kubernetes health checks.
+ properties:
+ address:
+ description: Defines the Contour health address interface.
+ minLength: 1
+ type: string
+ port:
+ description: Defines the Contour health port.
+ type: integer
+ required:
+ - address
+ - port
+ type: object
+ httpproxy:
+ default:
+ disablePermitInsecure: false
+ description: HTTPProxy defines parameters on HTTPProxy.
+ properties:
+ disablePermitInsecure:
+ description: DisablePermitInsecure disables the use of the permitInsecure field in HTTPProxy.
+ type: boolean
+ fallbackCertificate:
+ description: FallbackCertificate defines the namespace/name of the Kubernetes secret to use as fallback when a non-SNI request is received.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ rootNamespaces:
+ description: Restrict Contour to searching these namespaces for root ingress routes.
+ items:
+ type: string
+ type: array
+ required:
+ - disablePermitInsecure
+ type: object
+ ingress:
+ description: Ingress contains parameters for ingress options.
+ properties:
+ className:
+ description: Ingress Class Name Contour should use.
+ type: string
+ statusAddress:
+ description: Address to set in Ingress object status.
+ type: string
+ type: object
+ leaderElection:
+ default:
+ configmap:
+ name: leader-elect
+ namespace: projectcontour
+ disableLeaderElection: false
+ leaseDuration: 15s
+ renewDeadline: 10s
+ retryPeriod: 2s
+ description: LeaderElection contains leader election parameters.
+ properties:
+ configmap:
+ description: NamespacedName defines the namespace/name of the Kubernetes resource referred from the config file. Used for Contour config YAML file parsing, otherwise we could use K8s types.NamespacedName.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ disableLeaderElection:
+ type: boolean
+ leaseDuration:
+ type: string
+ renewDeadline:
+ type: string
+ retryPeriod:
+ type: string
+ required:
+ - disableLeaderElection
+ type: object
+ metrics:
+ default:
+ address: 0.0.0.0
+ port: 8000
+ description: Metrics defines the endpoints Contour uses to serve to metrics.
+ properties:
+ address:
+ description: Defines the metrics address interface.
+ maxLength: 253
+ minLength: 1
+ type: string
+ port:
+ description: Defines the metrics port.
+ type: integer
+ required:
+ - address
+ - port
+ type: object
+ policy:
+ description: Policy specifies default policy applied if not overridden by the user
+ properties:
+ applyToIngress:
+ description: ApplyToIngress determines if the Policies will apply to ingress objects
+ type: boolean
+ requestHeaders:
+ description: RequestHeadersPolicy defines the request headers set/removed on all routes
+ properties:
+ remove:
+ items:
+ type: string
+ type: array
+ set:
+ additionalProperties:
+ type: string
+ type: object
+ type: object
+ responseHeaders:
+ description: ResponseHeadersPolicy defines the response headers set/removed on all routes
+ properties:
+ remove:
+ items:
+ type: string
+ type: array
+ set:
+ additionalProperties:
+ type: string
+ type: object
+ type: object
+ type: object
+ rateLimitService:
+ description: RateLimitService optionally holds properties of the Rate Limit Service to be used for global rate limiting.
+ properties:
+ domain:
+ description: Domain is passed to the Rate Limit Service.
+ type: string
+ enableXRateLimitHeaders:
+ description: "EnableXRateLimitHeaders defines whether to include the X-RateLimit headers X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset (as defined by the IETF Internet-Draft linked below), on responses to clients when the Rate Limit Service is consulted for a request. \n ref. https://tools.ietf.org/id/draft-polli-ratelimit-headers-03.html"
+ type: boolean
+ extensionService:
+ description: ExtensionService identifies the extension service defining the RLS.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ failOpen:
+ description: FailOpen defines whether to allow requests to proceed when the Rate Limit Service fails to respond with a valid rate limit decision within the timeout defined on the extension service.
+ type: boolean
+ required:
+ - domain
+ - enableXRateLimitHeaders
+ - failOpen
+ type: object
+ xdsServer:
+ default:
+ address: 0.0.0.0
+ port: 8001
+ tls:
+ caFile: /certs/ca.crt
+ certFile: /certs/tls.crt
+ insecure: false
+ keyFile: /certs/tls.key
+ type: contour
+ description: XDSServer contains parameters for the xDS server.
+ properties:
+ address:
+ description: Defines the xDS gRPC API address which Contour will serve.
+ minLength: 1
+ type: string
+ port:
+ description: Defines the xDS gRPC API port which Contour will serve.
+ type: integer
+ tls:
+ description: TLS holds TLS file config details.
+ properties:
+ caFile:
+ description: CA filename.
+ type: string
+ certFile:
+ description: Client certificate filename.
+ type: string
+ insecure:
+ description: Allow serving the xDS gRPC API without TLS.
+ type: boolean
+ keyFile:
+ description: Client key filename.
+ type: string
+ required:
+ - insecure
+ type: object
+ type:
+ description: Defines the XDSServer to use for `contour serve`.
+ enum:
+ - contour
+ - envoy
+ type: string
+ required:
+ - address
+ - port
+ - type
+ type: object
+ type: object
+ status:
+ description: ContourConfigurationStatus defines the observed state of a ContourConfiguration resource.
+ properties:
+ conditions:
+ description: "Conditions contains the current status of the Contour resource. \n Contour will update a single condition, `Valid`, that is in normal-true polarity. \n Contour will not modify any other Conditions set in this block, in case some other controller wants to add a Condition."
+ items:
+ description: "DetailedCondition is an extension of the normal Kubernetes conditions, with two extra fields to hold sub-conditions, which provide more detailed reasons for the state (True or False) of the condition. \n `errors` holds information about sub-conditions which are fatal to that condition and render its state False. \n `warnings` holds information about sub-conditions which are not fatal to that condition and do not force the state to be False. \n Remember that Conditions have a type, a status, and a reason. \n The type is the type of the condition, the most important one in this CRD set is `Valid`. `Valid` is a positive-polarity condition: when it is `status: true` there are no problems. \n In more detail, `status: true` means that the object is has been ingested into Contour with no errors. `warnings` may still be present, and will be indicated in the Reason field. There must be zero entries in the `errors` slice in this case. \n `Valid`, `status: false` means that the object has had one or more fatal errors during processing into Contour. The details of the errors will be present under the `errors` field. There must be at least one error in the `errors` slice if `status` is `false`. \n For DetailedConditions of types other than `Valid`, the Condition must be in the negative polarity. When they have `status` `true`, there is an error. There must be at least one entry in the `errors` Subcondition slice. When they have `status` `false`, there are no serious errors, and there must be zero entries in the `errors` slice. In either case, there may be entries in the `warnings` slice. \n Regardless of the polarity, the `reason` and `message` fields must be updated with either the detail of the reason (if there is one and only one entry in total across both the `errors` and `warnings` slices), or `MultipleReasons` if there is more than one entry."
+ properties:
+ errors:
+ description: "Errors contains a slice of relevant error subconditions for this object. \n Subconditions are expected to appear when relevant (when there is a error), and disappear when not relevant. An empty slice here indicates no errors."
+ items:
+ description: "SubCondition is a Condition-like type intended for use as a subcondition inside a DetailedCondition. \n It contains a subset of the Condition fields. \n It is intended for warnings and errors, so `type` names should use abnormal-true polarity, that is, they should be of the form \"ErrorPresent: true\". \n The expected lifecycle for these errors is that they should only be present when the error or warning is, and should be removed when they are not relevant."
+ properties:
+ message:
+ description: "Message is a human readable message indicating details about the transition. \n This may be an empty string."
+ maxLength: 32768
+ type: string
+ reason:
+ description: "Reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. \n The value should be a CamelCase string. \n This field may not be empty."
+ maxLength: 1024
+ minLength: 1
+ pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
+ type: string
+ status:
+ description: Status of the condition, one of True, False, Unknown.
+ enum:
+ - "True"
+ - "False"
+ - Unknown
+ type: string
+ type:
+ description: "Type of condition in `CamelCase` or in `foo.example.com/CamelCase`. \n This must be in abnormal-true polarity, that is, `ErrorFound` or `controller.io/ErrorFound`. \n The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)"
+ maxLength: 316
+ pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
+ type: string
+ required:
+ - message
+ - reason
+ - status
+ - type
+ type: object
+ type: array
+ lastTransitionTime:
+ description: lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
+ format: date-time
+ type: string
+ message:
+ description: message is a human readable message indicating details about the transition. This may be an empty string.
+ maxLength: 32768
+ type: string
+ observedGeneration:
+ description: observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.
+ format: int64
+ minimum: 0
+ type: integer
+ reason:
+ description: reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.
+ maxLength: 1024
+ minLength: 1
+ pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
+ type: string
+ status:
+ description: status of the condition, one of True, False, Unknown.
+ enum:
+ - "True"
+ - "False"
+ - Unknown
+ type: string
+ type:
+ description: type of condition in CamelCase or in foo.example.com/CamelCase. --- Many .condition.type values are consistent across resources like Available, but because arbitrary conditions can be useful (see .node.status.conditions), the ability to deconflict is important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)
+ maxLength: 316
+ pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
+ type: string
+ warnings:
+ description: "Warnings contains a slice of relevant warning subconditions for this object. \n Subconditions are expected to appear when relevant (when there is a warning), and disappear when not relevant. An empty slice here indicates no warnings."
+ items:
+ description: "SubCondition is a Condition-like type intended for use as a subcondition inside a DetailedCondition. \n It contains a subset of the Condition fields. \n It is intended for warnings and errors, so `type` names should use abnormal-true polarity, that is, they should be of the form \"ErrorPresent: true\". \n The expected lifecycle for these errors is that they should only be present when the error or warning is, and should be removed when they are not relevant."
+ properties:
+ message:
+ description: "Message is a human readable message indicating details about the transition. \n This may be an empty string."
+ maxLength: 32768
+ type: string
+ reason:
+ description: "Reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. \n The value should be a CamelCase string. \n This field may not be empty."
+ maxLength: 1024
+ minLength: 1
+ pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
+ type: string
+ status:
+ description: Status of the condition, one of True, False, Unknown.
+ enum:
+ - "True"
+ - "False"
+ - Unknown
+ type: string
+ type:
+ description: "Type of condition in `CamelCase` or in `foo.example.com/CamelCase`. \n This must be in abnormal-true polarity, that is, `ErrorFound` or `controller.io/ErrorFound`. \n The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)"
+ maxLength: 316
+ pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
+ type: string
+ required:
+ - message
+ - reason
+ - status
+ - type
+ type: object
+ type: array
+ required:
+ - lastTransitionTime
+ - message
+ - reason
+ - status
+ - type
+ type: object
+ type: array
+ x-kubernetes-list-map-keys:
+ - type
+ x-kubernetes-list-type: map
+ type: object
+ required:
+ - spec
+ type: object
+ served: true
+ storage: true
+ subresources:
+ status: {}
+status:
+ acceptedNames:
+ kind: ""
+ plural: ""
+ conditions: []
+ storedVersions: []
+---
+apiVersion: apiextensions.k8s.io/v1
+kind: CustomResourceDefinition
+metadata:
+ annotations:
+ controller-gen.kubebuilder.io/version: v0.6.0
+ creationTimestamp: null
+ name: contourdeployments.projectcontour.io
+ labels:
+ networking.knative.dev/ingress-provider: contour
+spec:
+ preserveUnknownFields: false
+ group: projectcontour.io
+ names:
+ kind: ContourDeployment
+ listKind: ContourDeploymentList
+ plural: contourdeployments
+ shortNames:
+ - contourdeploy
+ singular: contourdeployment
+ scope: Namespaced
+ versions:
+ - name: v1alpha1
+ schema:
+ openAPIV3Schema:
+ description: ContourDeployment is the schema for a Contour Deployment.
+ properties:
+ apiVersion:
+ description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
+ type: string
+ kind:
+ description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
+ type: string
+ metadata:
+ type: object
+ spec:
+ description: ContourDeploymentSpec defines the parameters of how a Contour instance should be configured.
+ properties:
+ config:
+ description: Config is the config that the instances of Contour are to utilize.
+ properties:
+ debug:
+ default:
+ kubernetesLogLevel: 0
+ logLevel: info
+ description: Debug contains parameters to enable debug logging and debug interfaces inside Contour.
+ properties:
+ address:
+ description: Defines the Contour debug address interface.
+ type: string
+ kubernetesLogLevel:
+ default: 0
+ description: "KubernetesDebugLogLevel defines the log level which Contour will use when outputting Kubernetes specific log information. \n Details: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-instrumentation/logging.md"
+ maximum: 9
+ minimum: 0
+ type: integer
+ logLevel:
+ description: DebugLogLevel defines the log level which Contour will use when outputting log information.
+ enum:
+ - info
+ - debug
+ type: string
+ port:
+ description: Defines the Contour debug address port.
+ type: integer
+ required:
+ - logLevel
+ type: object
+ enableExternalNameService:
+ default: false
+ description: EnableExternalNameService allows processing of ExternalNameServices Defaults to disabled for security reasons.
+ type: boolean
+ envoy:
+ default:
+ cluster:
+ dnsLookupFamily: auto
+ defaultHTTPVersions:
+ - HTTP/1.1
+ - HTTP/2
+ http:
+ accessLog: /dev/stdout
+ address: 0.0.0.0
+ port: 8080
+ https:
+ accessLog: /dev/stdout
+ address: 0.0.0.0
+ port: 8443
+ listener:
+ connectionBalancer: ""
+ disableAllowChunkedLength: false
+ tls:
+ cipherSuites:
+ - '[ECDHE-ECDSA-AES128-GCM-SHA256|ECDHE-ECDSA-CHACHA20-POLY1305]'
+ - '[ECDHE-RSA-AES128-GCM-SHA256|ECDHE-RSA-CHACHA20-POLY1305]'
+ - ECDHE-ECDSA-AES256-GCM-SHA384
+ - ECDHE-RSA-AES256-GCM-SHA384
+ minimumProtocolVersion: "1.2"
+ useProxyProtocol: false
+ logging:
+ accessLogFormat: envoy
+ metrics:
+ address: 0.0.0.0
+ port: 8002
+ network:
+ adminPort: 9001
+ service:
+ name: envoy
+ namespace: projectcontour
+ description: Envoy contains parameters for Envoy as well as how to optionally configure a managed Envoy fleet.
+ properties:
+ clientCertificate:
+ description: ClientCertificate defines the namespace/name of the Kubernetes secret containing the client certificate and private key to be used when establishing TLS connection to upstream cluster.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ cluster:
+ description: Cluster holds various configurable Envoy cluster values that can be set in the config file.
+ properties:
+ dnsLookupFamily:
+ default: auto
+ description: "DNSLookupFamily defines how external names are looked up When configured as V4, the DNS resolver will only perform a lookup for addresses in the IPv4 family. If V6 is configured, the DNS resolver will only perform a lookup for addresses in the IPv6 family. If AUTO is configured, the DNS resolver will first perform a lookup for addresses in the IPv6 family and fallback to a lookup for addresses in the IPv4 family. Note: This only applies to externalName clusters. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/cluster/v3/cluster.proto.html#envoy-v3-api-enum-config-cluster-v3-cluster-dnslookupfamily for more information."
+ enum:
+ - auto
+ - v4
+ - v6
+ type: string
+ required:
+ - dnsLookupFamily
+ type: object
+ defaultHTTPVersions:
+ description: DefaultHTTPVersions defines the default set of HTTPS versions the proxy should accept. HTTP versions are strings of the form "HTTP/xx". Supported versions are "HTTP/1.1" and "HTTP/2".
+ items:
+ description: HTTPVersionType is the name of a supported HTTP version.
+ enum:
+ - HTTP/1.1
+ - HTTP/2
+ type: string
+ type: array
+ http:
+ default:
+ accessLog: /dev/stdout
+ address: 0.0.0.0
+ port: 8080
+ description: Defines the HTTP Listener for Envoy.
+ properties:
+ accessLog:
+ description: AccessLog defines where Envoy logs are outputted for this listener.
+ type: string
+ address:
+ description: Defines an Envoy Listener Address.
+ minLength: 1
+ type: string
+ port:
+ description: Defines an Envoy listener Port.
+ type: integer
+ required:
+ - accessLog
+ - address
+ - port
+ type: object
+ https:
+ default:
+ accessLog: /dev/stdout
+ address: 0.0.0.0
+ port: 8443
+ description: Defines the HTTP Listener for Envoy.
+ properties:
+ accessLog:
+ description: AccessLog defines where Envoy logs are outputted for this listener.
+ type: string
+ address:
+ description: Defines an Envoy Listener Address.
+ minLength: 1
+ type: string
+ port:
+ description: Defines an Envoy listener Port.
+ type: integer
+ required:
+ - accessLog
+ - address
+ - port
+ type: object
+ listener:
+ description: Listener hold various configurable Envoy listener values.
+ properties:
+ connectionBalancer:
+ description: ConnectionBalancer. If the value is exact, the listener will use the exact connection balancer See https://www.envoyproxy.io/docs/envoy/latest/api-v2/api/v2/listener.proto#envoy-api-msg-listener-connectionbalanceconfig for more information.
+ enum:
+ - ""
+ - exact
+ type: string
+ disableAllowChunkedLength:
+ description: 'DisableAllowChunkedLength disables the RFC-compliant Envoy behavior to strip the "Content-Length" header if "Transfer-Encoding: chunked" is also set. This is an emergency off-switch to revert back to Envoy''s default behavior in case of failures. Please file an issue if failures are encountered. See: https://github.com/projectcontour/contour/issues/3221'
+ type: boolean
+ tls:
+ description: TLS holds various configurable Envoy TLS listener values.
+ properties:
+ cipherSuites:
+ description: "CipherSuites defines the TLS ciphers to be supported by Envoy TLS listeners when negotiating TLS 1.2. Ciphers are validated against the set that Envoy supports by default. This parameter should only be used by advanced users. Note that these will be ignored when TLS 1.3 is in use. \n See: https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/transport_sockets/tls/v3/common.proto#extensions-transport-sockets-tls-v3-tlsparameters Note: This list is a superset of what is valid for stock Envoy builds and those using BoringSSL FIPS."
+ items:
+ enum:
+ - '[ECDHE-ECDSA-AES128-GCM-SHA256|ECDHE-ECDSA-CHACHA20-POLY1305]'
+ - '[ECDHE-RSA-AES128-GCM-SHA256|ECDHE-RSA-CHACHA20-POLY1305]'
+ - ECDHE-ECDSA-AES128-GCM-SHA256
+ - ECDHE-RSA-AES128-GCM-SHA256
+ - ECDHE-ECDSA-AES128-SHA
+ - ECDHE-RSA-AES128-SHA
+ - AES128-GCM-SHA256
+ - AES128-SHA
+ - ECDHE-ECDSA-AES256-GCM-SHA384
+ - ECDHE-RSA-AES256-GCM-SHA384
+ - ECDHE-ECDSA-AES256-SHA
+ - ECDHE-RSA-AES256-SHA
+ - AES256-GCM-SHA384
+ - AES256-SHA
+ type: string
+ type: array
+ minimumProtocolVersion:
+ description: MinimumProtocolVersion is the minimum TLS version this vhost should negotiate. Valid options are `1.2` (default) and `1.3`.
+ enum:
+ - "1.2"
+ - "1.3"
+ type: string
+ required:
+ - cipherSuites
+ - minimumProtocolVersion
+ type: object
+ useProxyProtocol:
+ description: Use PROXY protocol for all listeners.
+ type: boolean
+ required:
+ - connectionBalancer
+ - disableAllowChunkedLength
+ - tls
+ - useProxyProtocol
+ type: object
+ logging:
+ description: Logging defines how Envoy's logs can be configured.
+ properties:
+ accessLogFormat:
+ description: AccessLogFormat sets the global access log format. Valid options are 'envoy' or 'json'
+ enum:
+ - envoy
+ - json
+ type: string
+ accessLogFormatString:
+ description: AccessLogFormatString sets the access log format when format is set to `envoy`. When empty, Envoy's default format is used.
+ type: string
+ jsonFields:
+ description: AccessLogFields sets the fields that JSON logging will output when AccessLogFormat is json.
+ items:
+ type: string
+ type: array
+ required:
+ - accessLogFormat
+ type: object
+ metrics:
+ default:
+ address: 0.0.0.0
+ port: 8002
+ description: Metrics defines the endpoints Envoy use to serve to metrics.
+ properties:
+ address:
+ description: Defines the metrics address interface.
+ maxLength: 253
+ minLength: 1
+ type: string
+ port:
+ description: Defines the metrics port.
+ type: integer
+ required:
+ - address
+ - port
+ type: object
+ network:
+ description: Network holds various configurable Envoy network values.
+ properties:
+ adminPort:
+ default: 9001
+ description: Configure the port used to access the Envoy Admin interface. If configured to port "0" then the admin interface is disabled.
+ type: integer
+ numTrustedHops:
+ description: "XffNumTrustedHops defines the number of additional ingress proxy hops from the right side of the x-forwarded-for HTTP header to trust when determining the origin client’s IP address. \n See https://www.envoyproxy.io/docs/envoy/v1.17.0/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto?highlight=xff_num_trusted_hops for more information."
+ format: int32
+ type: integer
+ required:
+ - adminPort
+ type: object
+ service:
+ default:
+ name: envoy
+ namespace: projectcontour
+ description: Service holds Envoy service parameters for setting Ingress status.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ timeouts:
+ description: Timeouts holds various configurable timeouts that can be set in the config file.
+ properties:
+ connectionIdleTimeout:
+ description: "ConnectionIdleTimeout defines how long the proxy should wait while there are no active requests (for HTTP/1.1) or streams (for HTTP/2) before terminating an HTTP connection. Set to \"infinity\" to disable the timeout entirely. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/protocol.proto#envoy-v3-api-field-config-core-v3-httpprotocoloptions-idle-timeout for more information."
+ type: string
+ connectionShutdownGracePeriod:
+ description: "ConnectionShutdownGracePeriod defines how long the proxy will wait between sending an initial GOAWAY frame and a second, final GOAWAY frame when terminating an HTTP/2 connection. During this grace period, the proxy will continue to respond to new streams. After the final GOAWAY frame has been sent, the proxy will refuse new streams. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto#envoy-v3-api-field-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-drain-timeout for more information."
+ type: string
+ delayedCloseTimeout:
+ description: "DelayedCloseTimeout defines how long envoy will wait, once connection close processing has been initiated, for the downstream peer to close the connection before Envoy closes the socket associated with the connection. \n Setting this timeout to 'infinity' will disable it, equivalent to setting it to '0' in Envoy. Leaving it unset will result in the Envoy default value being used. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto#envoy-v3-api-field-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-delayed-close-timeout for more information."
+ type: string
+ maxConnectionDuration:
+ description: "MaxConnectionDuration defines the maximum period of time after an HTTP connection has been established from the client to the proxy before it is closed by the proxy, regardless of whether there has been activity or not. Omit or set to \"infinity\" for no max duration. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/protocol.proto#envoy-v3-api-field-config-core-v3-httpprotocoloptions-max-connection-duration for more information."
+ type: string
+ requestTimeout:
+ description: "RequestTimeout sets the client request timeout globally for Contour. Note that this is a timeout for the entire request, not an idle timeout. Omit or set to \"infinity\" to disable the timeout entirely. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto#envoy-v3-api-field-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-request-timeout for more information."
+ type: string
+ streamIdleTimeout:
+ description: "StreamIdleTimeout defines how long the proxy should wait while there is no request activity (for HTTP/1.1) or stream activity (for HTTP/2) before terminating the HTTP request or stream. Set to \"infinity\" to disable the timeout entirely. \n See https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto#envoy-v3-api-field-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-stream-idle-timeout for more information."
+ type: string
+ type: object
+ required:
+ - cluster
+ - defaultHTTPVersions
+ - http
+ - https
+ - listener
+ - logging
+ - metrics
+ - network
+ - service
+ type: object
+ gateway:
+ description: Gateway contains parameters for the gateway-api Gateway that Contour is configured to serve traffic.
+ properties:
+ controllerName:
+ default: projectcontour.io/projectcontour/contour
+ description: ControllerName is used to determine whether Contour should reconcile a GatewayClass. The string takes the form of "projectcontour.io//contour". If unset, the gatewayclass controller will not be started.
+ type: string
+ required:
+ - controllerName
+ type: object
+ health:
+ default:
+ address: 0.0.0.0
+ port: 8000
+ description: Health contains parameters to configure endpoints which Contour exposes to respond to Kubernetes health checks.
+ properties:
+ address:
+ description: Defines the Contour health address interface.
+ minLength: 1
+ type: string
+ port:
+ description: Defines the Contour health port.
+ type: integer
+ required:
+ - address
+ - port
+ type: object
+ httpproxy:
+ default:
+ disablePermitInsecure: false
+ description: HTTPProxy defines parameters on HTTPProxy.
+ properties:
+ disablePermitInsecure:
+ description: DisablePermitInsecure disables the use of the permitInsecure field in HTTPProxy.
+ type: boolean
+ fallbackCertificate:
+ description: FallbackCertificate defines the namespace/name of the Kubernetes secret to use as fallback when a non-SNI request is received.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ rootNamespaces:
+ description: Restrict Contour to searching these namespaces for root ingress routes.
+ items:
+ type: string
+ type: array
+ required:
+ - disablePermitInsecure
+ type: object
+ ingress:
+ description: Ingress contains parameters for ingress options.
+ properties:
+ className:
+ description: Ingress Class Name Contour should use.
+ type: string
+ statusAddress:
+ description: Address to set in Ingress object status.
+ type: string
+ type: object
+ leaderElection:
+ default:
+ configmap:
+ name: leader-elect
+ namespace: projectcontour
+ disableLeaderElection: false
+ leaseDuration: 15s
+ renewDeadline: 10s
+ retryPeriod: 2s
+ description: LeaderElection contains leader election parameters.
+ properties:
+ configmap:
+ description: NamespacedName defines the namespace/name of the Kubernetes resource referred from the config file. Used for Contour config YAML file parsing, otherwise we could use K8s types.NamespacedName.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ disableLeaderElection:
+ type: boolean
+ leaseDuration:
+ type: string
+ renewDeadline:
+ type: string
+ retryPeriod:
+ type: string
+ required:
+ - disableLeaderElection
+ type: object
+ metrics:
+ default:
+ address: 0.0.0.0
+ port: 8000
+ description: Metrics defines the endpoints Contour uses to serve to metrics.
+ properties:
+ address:
+ description: Defines the metrics address interface.
+ maxLength: 253
+ minLength: 1
+ type: string
+ port:
+ description: Defines the metrics port.
+ type: integer
+ required:
+ - address
+ - port
+ type: object
+ policy:
+ description: Policy specifies default policy applied if not overridden by the user
+ properties:
+ applyToIngress:
+ description: ApplyToIngress determines if the Policies will apply to ingress objects
+ type: boolean
+ requestHeaders:
+ description: RequestHeadersPolicy defines the request headers set/removed on all routes
+ properties:
+ remove:
+ items:
+ type: string
+ type: array
+ set:
+ additionalProperties:
+ type: string
+ type: object
+ type: object
+ responseHeaders:
+ description: ResponseHeadersPolicy defines the response headers set/removed on all routes
+ properties:
+ remove:
+ items:
+ type: string
+ type: array
+ set:
+ additionalProperties:
+ type: string
+ type: object
+ type: object
+ type: object
+ rateLimitService:
+ description: RateLimitService optionally holds properties of the Rate Limit Service to be used for global rate limiting.
+ properties:
+ domain:
+ description: Domain is passed to the Rate Limit Service.
+ type: string
+ enableXRateLimitHeaders:
+ description: "EnableXRateLimitHeaders defines whether to include the X-RateLimit headers X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset (as defined by the IETF Internet-Draft linked below), on responses to clients when the Rate Limit Service is consulted for a request. \n ref. https://tools.ietf.org/id/draft-polli-ratelimit-headers-03.html"
+ type: boolean
+ extensionService:
+ description: ExtensionService identifies the extension service defining the RLS.
+ properties:
+ name:
+ type: string
+ namespace:
+ type: string
+ required:
+ - name
+ - namespace
+ type: object
+ failOpen:
+ description: FailOpen defines whether to allow requests to proceed when the Rate Limit Service fails to respond with a valid rate limit decision within the timeout defined on the extension service.
+ type: boolean
+ required:
+ - domain
+ - enableXRateLimitHeaders
+ - failOpen
+ type: object
+ xdsServer:
+ default:
+ address: 0.0.0.0
+ port: 8001
+ tls:
+ caFile: /certs/ca.crt
+ certFile: /certs/tls.crt
+ insecure: false
+ keyFile: /certs/tls.key
+ type: contour
+ description: XDSServer contains parameters for the xDS server.
+ properties:
+ address:
+ description: Defines the xDS gRPC API address which Contour will serve.
+ minLength: 1
+ type: string
+ port:
+ description: Defines the xDS gRPC API port which Contour will serve.
+ type: integer
+ tls:
+ description: TLS holds TLS file config details.
+ properties:
+ caFile:
+ description: CA filename.
+ type: string
+ certFile:
+ description: Client certificate filename.
+ type: string
+ insecure:
+ description: Allow serving the xDS gRPC API without TLS.
+ type: boolean
+ keyFile:
+ description: Client key filename.
+ type: string
+ required:
+ - insecure
+ type: object
+ type:
+ description: Defines the XDSServer to use for `contour serve`.
+ enum:
+ - contour
+ - envoy
+ type: string
+ required:
+ - address
+ - port
+ - type
+ type: object
+ type: object
+ replicas:
+ default: 2
+ description: Replicas is the desired number of Contour replicas. If unset, defaults to 2.
+ format: int32
+ minimum: 0
+ type: integer
+ required:
+ - config
+ type: object
+ status:
+ description: ContourDeploymentStatus defines the observed state of a ContourDeployment resource.
+ properties:
+ conditions:
+ description: "Conditions contains the current status of the Contour resource. \n Contour will update a single condition, `Valid`, that is in normal-true polarity. \n Contour will not modify any other Conditions set in this block, in case some other controller wants to add a Condition."
+ items:
+ description: "DetailedCondition is an extension of the normal Kubernetes conditions, with two extra fields to hold sub-conditions, which provide more detailed reasons for the state (True or False) of the condition. \n `errors` holds information about sub-conditions which are fatal to that condition and render its state False. \n `warnings` holds information about sub-conditions which are not fatal to that condition and do not force the state to be False. \n Remember that Conditions have a type, a status, and a reason. \n The type is the type of the condition, the most important one in this CRD set is `Valid`. `Valid` is a positive-polarity condition: when it is `status: true` there are no problems. \n In more detail, `status: true` means that the object is has been ingested into Contour with no errors. `warnings` may still be present, and will be indicated in the Reason field. There must be zero entries in the `errors` slice in this case. \n `Valid`, `status: false` means that the object has had one or more fatal errors during processing into Contour. The details of the errors will be present under the `errors` field. There must be at least one error in the `errors` slice if `status` is `false`. \n For DetailedConditions of types other than `Valid`, the Condition must be in the negative polarity. When they have `status` `true`, there is an error. There must be at least one entry in the `errors` Subcondition slice. When they have `status` `false`, there are no serious errors, and there must be zero entries in the `errors` slice. In either case, there may be entries in the `warnings` slice. \n Regardless of the polarity, the `reason` and `message` fields must be updated with either the detail of the reason (if there is one and only one entry in total across both the `errors` and `warnings` slices), or `MultipleReasons` if there is more than one entry."
+ properties:
+ errors:
+ description: "Errors contains a slice of relevant error subconditions for this object. \n Subconditions are expected to appear when relevant (when there is a error), and disappear when not relevant. An empty slice here indicates no errors."
+ items:
+ description: "SubCondition is a Condition-like type intended for use as a subcondition inside a DetailedCondition. \n It contains a subset of the Condition fields. \n It is intended for warnings and errors, so `type` names should use abnormal-true polarity, that is, they should be of the form \"ErrorPresent: true\". \n The expected lifecycle for these errors is that they should only be present when the error or warning is, and should be removed when they are not relevant."
+ properties:
+ message:
+ description: "Message is a human readable message indicating details about the transition. \n This may be an empty string."
+ maxLength: 32768
+ type: string
+ reason:
+ description: "Reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. \n The value should be a CamelCase string. \n This field may not be empty."
+ maxLength: 1024
+ minLength: 1
+ pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
+ type: string
+ status:
+ description: Status of the condition, one of True, False, Unknown.
+ enum:
+ - "True"
+ - "False"
+ - Unknown
+ type: string
+ type:
+ description: "Type of condition in `CamelCase` or in `foo.example.com/CamelCase`. \n This must be in abnormal-true polarity, that is, `ErrorFound` or `controller.io/ErrorFound`. \n The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)"
+ maxLength: 316
+ pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
+ type: string
+ required:
+ - message
+ - reason
+ - status
+ - type
+ type: object
+ type: array
+ lastTransitionTime:
+ description: lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
+ format: date-time
+ type: string
+ message:
+ description: message is a human readable message indicating details about the transition. This may be an empty string.
+ maxLength: 32768
+ type: string
+ observedGeneration:
+ description: observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.
+ format: int64
+ minimum: 0
+ type: integer
+ reason:
+ description: reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.
+ maxLength: 1024
+ minLength: 1
+ pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
+ type: string
+ status:
+ description: status of the condition, one of True, False, Unknown.
+ enum:
+ - "True"
+ - "False"
+ - Unknown
+ type: string
+ type:
+ description: type of condition in CamelCase or in foo.example.com/CamelCase. --- Many .condition.type values are consistent across resources like Available, but because arbitrary conditions can be useful (see .node.status.conditions), the ability to deconflict is important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)
+ maxLength: 316
+ pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
+ type: string
+ warnings:
+ description: "Warnings contains a slice of relevant warning subconditions for this object. \n Subconditions are expected to appear when relevant (when there is a warning), and disappear when not relevant. An empty slice here indicates no warnings."
+ items:
+ description: "SubCondition is a Condition-like type intended for use as a subcondition inside a DetailedCondition. \n It contains a subset of the Condition fields. \n It is intended for warnings and errors, so `type` names should use abnormal-true polarity, that is, they should be of the form \"ErrorPresent: true\". \n The expected lifecycle for these errors is that they should only be present when the error or warning is, and should be removed when they are not relevant."
+ properties:
+ message:
+ description: "Message is a human readable message indicating details about the transition. \n This may be an empty string."
+ maxLength: 32768
+ type: string
+ reason:
+ description: "Reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. \n The value should be a CamelCase string. \n This field may not be empty."
+ maxLength: 1024
+ minLength: 1
+ pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
+ type: string
+ status:
+ description: Status of the condition, one of True, False, Unknown.
+ enum:
+ - "True"
+ - "False"
+ - Unknown
+ type: string
+ type:
+ description: "Type of condition in `CamelCase` or in `foo.example.com/CamelCase`. \n This must be in abnormal-true polarity, that is, `ErrorFound` or `controller.io/ErrorFound`. \n The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)"
+ maxLength: 316
+ pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
+ type: string
+ required:
+ - message
+ - reason
+ - status
+ - type
+ type: object
+ type: array
+ required:
+ - lastTransitionTime
+ - message
+ - reason
+ - status
+ - type
+ type: object
+ type: array
+ x-kubernetes-list-map-keys:
+ - type
+ x-kubernetes-list-type: map
+ type: object
+ type: object
+ served: true
+ storage: true
+ subresources:
+ status: {}
+status:
+ acceptedNames:
+ kind: ""
+ plural: ""
+ conditions: []
+ storedVersions: []
+---
+apiVersion: apiextensions.k8s.io/v1
+kind: CustomResourceDefinition
+metadata:
+ annotations:
+ controller-gen.kubebuilder.io/version: v0.6.0
creationTimestamp: null
name: extensionservices.projectcontour.io
labels:
@@ -296,7 +1694,7 @@ spec:
description: The timeout policy for requests to the services.
properties:
idle:
- description: Timeout after which, if there are no active requests for this route, the connection between Envoy and the backend or Envoy and the external client will be closed. If not specified, there is no per-route idle timeout, though a connection manager-wide stream_idle_timeout default of 5m still applies.
+ description: Timeout for how long the proxy should wait while there is no activity during single request/response (for HTTP/1.1) or stream (for HTTP/2). Timeout will not trigger while HTTP/1.1 connection is idle between two consecutive requests. If not specified, there is no per-route idle timeout, though a connection manager-wide stream_idle_timeout default of 5m still applies.
pattern: ^(((\d*(\.\d*)?h)|(\d*(\.\d*)?m)|(\d*(\.\d*)?s)|(\d*(\.\d*)?ms)|(\d*(\.\d*)?us)|(\d*(\.\d*)?µs)|(\d*(\.\d*)?ns))+|infinity|infinite)$
type: string
response:
@@ -455,7 +1853,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ controller-gen.kubebuilder.io/version: v0.6.0
creationTimestamp: null
name: httpproxies.projectcontour.io
labels:
@@ -615,6 +2013,54 @@ spec:
type: string
type: object
type: array
+ cookieRewritePolicies:
+ description: The policies for rewriting Set-Cookie header attributes. Note that rewritten cookie names must be unique in this list. Order rewrite policies are specified in does not matter.
+ items:
+ properties:
+ domainRewrite:
+ description: DomainRewrite enables rewriting the Set-Cookie Domain element. If not set, Domain will not be rewritten.
+ properties:
+ value:
+ description: Value is the value to rewrite the Domain attribute to. For now this is required.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ required:
+ - value
+ type: object
+ name:
+ description: Name is the name of the cookie for which attributes will be rewritten.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[^()<>@,;:\\"\/[\]?={} \t\x7f\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f]+$
+ type: string
+ pathRewrite:
+ description: PathRewrite enables rewriting the Set-Cookie Path element. If not set, Path will not be rewritten.
+ properties:
+ value:
+ description: Value is the value to rewrite the Path attribute to. For now this is required.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[^;\x7f\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f]+$
+ type: string
+ required:
+ - value
+ type: object
+ sameSite:
+ description: SameSite enables rewriting the Set-Cookie SameSite element. If not set, SameSite attribute will not be rewritten.
+ enum:
+ - Strict
+ - Lax
+ - None
+ type: string
+ secure:
+ description: Secure enables rewriting the Set-Cookie Secure element. If not set, Secure attribute will not be rewritten.
+ type: boolean
+ required:
+ - name
+ type: object
+ type: array
enableWebsockets:
description: Enables websocket support for the route.
type: boolean
@@ -895,9 +2341,10 @@ spec:
description: The retry policy for this route.
properties:
count:
- description: NumRetries is maximum allowed number of retries. If not supplied, the number of retries is one.
+ default: 1
+ description: NumRetries is maximum allowed number of retries. If set to -1, then retries are disabled. If set to 0 or not supplied, the value is set to the Envoy default of 1.
format: int64
- minimum: 0
+ minimum: -1
type: integer
perTryTimeout:
description: PerTryTimeout specifies the timeout per retry attempt. Ignored if NumRetries is not supplied.
@@ -935,6 +2382,54 @@ spec:
items:
description: Service defines an Kubernetes Service to proxy traffic.
properties:
+ cookieRewritePolicies:
+ description: The policies for rewriting Set-Cookie header attributes.
+ items:
+ properties:
+ domainRewrite:
+ description: DomainRewrite enables rewriting the Set-Cookie Domain element. If not set, Domain will not be rewritten.
+ properties:
+ value:
+ description: Value is the value to rewrite the Domain attribute to. For now this is required.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ required:
+ - value
+ type: object
+ name:
+ description: Name is the name of the cookie for which attributes will be rewritten.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[^()<>@,;:\\"\/[\]?={} \t\x7f\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f]+$
+ type: string
+ pathRewrite:
+ description: PathRewrite enables rewriting the Set-Cookie Path element. If not set, Path will not be rewritten.
+ properties:
+ value:
+ description: Value is the value to rewrite the Path attribute to. For now this is required.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[^;\x7f\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f]+$
+ type: string
+ required:
+ - value
+ type: object
+ sameSite:
+ description: SameSite enables rewriting the Set-Cookie SameSite element. If not set, SameSite attribute will not be rewritten.
+ enum:
+ - Strict
+ - Lax
+ - None
+ type: string
+ secure:
+ description: Secure enables rewriting the Set-Cookie Secure element. If not set, Secure attribute will not be rewritten.
+ type: boolean
+ required:
+ - name
+ type: object
+ type: array
mirror:
description: If Mirror is true the Service will receive a read only mirror of the traffic for this route.
type: boolean
@@ -1036,7 +2531,7 @@ spec:
description: The timeout policy for this route.
properties:
idle:
- description: Timeout after which, if there are no active requests for this route, the connection between Envoy and the backend or Envoy and the external client will be closed. If not specified, there is no per-route idle timeout, though a connection manager-wide stream_idle_timeout default of 5m still applies.
+ description: Timeout for how long the proxy should wait while there is no activity during single request/response (for HTTP/1.1) or stream (for HTTP/2). Timeout will not trigger while HTTP/1.1 connection is idle between two consecutive requests. If not specified, there is no per-route idle timeout, though a connection manager-wide stream_idle_timeout default of 5m still applies.
pattern: ^(((\d*(\.\d*)?h)|(\d*(\.\d*)?m)|(\d*(\.\d*)?s)|(\d*(\.\d*)?ms)|(\d*(\.\d*)?us)|(\d*(\.\d*)?µs)|(\d*(\.\d*)?ns))+|infinity|infinite)$
type: string
response:
@@ -1125,6 +2620,54 @@ spec:
items:
description: Service defines an Kubernetes Service to proxy traffic.
properties:
+ cookieRewritePolicies:
+ description: The policies for rewriting Set-Cookie header attributes.
+ items:
+ properties:
+ domainRewrite:
+ description: DomainRewrite enables rewriting the Set-Cookie Domain element. If not set, Domain will not be rewritten.
+ properties:
+ value:
+ description: Value is the value to rewrite the Domain attribute to. For now this is required.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ required:
+ - value
+ type: object
+ name:
+ description: Name is the name of the cookie for which attributes will be rewritten.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[^()<>@,;:\\"\/[\]?={} \t\x7f\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f]+$
+ type: string
+ pathRewrite:
+ description: PathRewrite enables rewriting the Set-Cookie Path element. If not set, Path will not be rewritten.
+ properties:
+ value:
+ description: Value is the value to rewrite the Path attribute to. For now this is required.
+ maxLength: 4096
+ minLength: 1
+ pattern: ^[^;\x7f\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f]+$
+ type: string
+ required:
+ - value
+ type: object
+ sameSite:
+ description: SameSite enables rewriting the Set-Cookie SameSite element. If not set, SameSite attribute will not be rewritten.
+ enum:
+ - Strict
+ - Lax
+ - None
+ type: string
+ secure:
+ description: Secure enables rewriting the Set-Cookie Secure element. If not set, Secure attribute will not be rewritten.
+ type: boolean
+ required:
+ - name
+ type: object
+ type: array
mirror:
description: If Mirror is true the Service will receive a read only mirror of the traffic for this route.
type: boolean
@@ -1307,6 +2850,7 @@ spec:
type: object
fqdn:
description: The fully qualified domain name of the root of the ingress tree all leaves of the DAG rooted at this object relate to the fqdn.
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
rateLimitPolicy:
description: The policy for rate limiting on the virtual host.
@@ -1661,7 +3205,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ controller-gen.kubebuilder.io/version: v0.6.0
creationTimestamp: null
name: tlscertificatedelegations.projectcontour.io
labels:
@@ -1891,7 +3435,7 @@ rules:
apiVersion: batch/v1
kind: Job
metadata:
- name: contour-certgen-v1.18.2
+ name: contour-certgen-v1.19.1
namespace: contour-external
labels:
networking.knative.dev/ingress-provider: contour
@@ -1904,7 +3448,7 @@ spec:
spec:
containers:
- name: contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:c450b024a29a5a4c9cb804a71fce7daff2fc0fc86c76d1b4fa11aee7ad49b628
+ image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
imagePullPolicy: IfNotPresent
command:
- contour
@@ -1977,12 +3521,6 @@ rules:
- get
- list
- watch
- - apiGroups:
- - apiextensions.k8s.io
- resources:
- - customresourcedefinitions
- verbs:
- - list
- apiGroups:
- networking.k8s.io
resources:
@@ -2010,7 +3548,6 @@ rules:
- apiGroups:
- networking.x-k8s.io
resources:
- - backendpolicies
- gatewayclasses
- gateways
- httproutes
@@ -2024,7 +3561,6 @@ rules:
- apiGroups:
- networking.x-k8s.io
resources:
- - backendpolicies/status
- gatewayclasses/status
- gateways/status
- httproutes/status
@@ -2033,6 +3569,22 @@ rules:
- udproutes/status
verbs:
- update
+ - apiGroups:
+ - projectcontour.io
+ resources:
+ - contourconfigurations
+ verbs:
+ - get
+ - list
+ - watch
+ - apiGroups:
+ - projectcontour.io
+ resources:
+ - contourconfigurations/status
+ verbs:
+ - create
+ - get
+ - update
- apiGroups:
- projectcontour.io
resources:
@@ -2155,7 +3707,7 @@ spec:
- --config-path=/config/contour.yaml
command:
- contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:c450b024a29a5a4c9cb804a71fce7daff2fc0fc86c76d1b4fa11aee7ad49b628
+ image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
imagePullPolicy: IfNotPresent
name: contour
ports:
@@ -2244,7 +3796,7 @@ spec:
args:
- envoy
- shutdown-manager
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:c450b024a29a5a4c9cb804a71fce7daff2fc0fc86c76d1b4fa11aee7ad49b628
+ image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
imagePullPolicy: IfNotPresent
lifecycle:
preStop:
@@ -2340,7 +3892,7 @@ spec:
- --envoy-key-file=/certs/tls.key
command:
- contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:c450b024a29a5a4c9cb804a71fce7daff2fc0fc86c76d1b4fa11aee7ad49b628
+ image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
imagePullPolicy: IfNotPresent
name: envoy-initconfig
volumeMounts:
@@ -2366,6 +3918,10 @@ spec:
secret:
secretName: envoycert
restartPolicy: Always
+ securityContext:
+ runAsNonRoot: true
+ runAsUser: 65534
+ runAsGroup: 65534
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
@@ -2422,8 +3978,6 @@ data:
# Specify the Gateway API configuration.
# gateway:
# controllerName: projectcontour.io/projectcontour/contour
- # name: contour
- # namespace: contour-internal
#
# should contour expect to be running inside a k8s cluster
# incluster: true
@@ -2466,6 +4020,10 @@ data:
# Please see the advisory at https://github.com/projectcontour/contour/security/advisories/GHSA-5ph6-qq5x-7jwc for the details.
# enableExternalNameService: false
##
+ # Address to be placed in status.loadbalancer field of Ingress objects.
+ # May be either a literal IP address or a host name.
+ # The value will be placed directly into the relevant field inside the status.loadBalancer struct.
+ # ingress-status-address: local.projectcontour.io
### Logging options
# Default setting
accesslog-format: envoy
@@ -2606,7 +4164,7 @@ rules:
apiVersion: batch/v1
kind: Job
metadata:
- name: contour-certgen-v1.18.2
+ name: contour-certgen-v1.19.1
namespace: contour-internal
labels:
networking.knative.dev/ingress-provider: contour
@@ -2619,7 +4177,7 @@ spec:
spec:
containers:
- name: contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:c450b024a29a5a4c9cb804a71fce7daff2fc0fc86c76d1b4fa11aee7ad49b628
+ image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
imagePullPolicy: IfNotPresent
command:
- contour
@@ -2731,7 +4289,7 @@ spec:
- --config-path=/config/contour.yaml
command:
- contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:c450b024a29a5a4c9cb804a71fce7daff2fc0fc86c76d1b4fa11aee7ad49b628
+ image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
imagePullPolicy: IfNotPresent
name: contour
ports:
@@ -2820,7 +4378,7 @@ spec:
args:
- envoy
- shutdown-manager
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:c450b024a29a5a4c9cb804a71fce7daff2fc0fc86c76d1b4fa11aee7ad49b628
+ image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
imagePullPolicy: IfNotPresent
lifecycle:
preStop:
@@ -2916,7 +4474,7 @@ spec:
- --envoy-key-file=/certs/tls.key
command:
- contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:c450b024a29a5a4c9cb804a71fce7daff2fc0fc86c76d1b4fa11aee7ad49b628
+ image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
imagePullPolicy: IfNotPresent
name: envoy-initconfig
volumeMounts:
@@ -2942,5 +4500,9 @@ spec:
secret:
secretName: envoycert
restartPolicy: Always
+ securityContext:
+ runAsNonRoot: true
+ runAsUser: 65534
+ runAsGroup: 65534
---
diff --git a/third_party/contour-latest/net-contour.yaml b/third_party/contour-latest/net-contour.yaml
index 3aa05d40e7d9..4b1a58b868c9 100644
--- a/third_party/contour-latest/net-contour.yaml
+++ b/third_party/contour-latest/net-contour.yaml
@@ -8,7 +8,7 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220106-35a6137f"
+ app.kubernetes.io/version: "20220112-93dc2a37"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["projectcontour.io"]
@@ -38,8 +38,8 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220106-35a6137f"
- serving.knative.dev/release: "v20220106-35a6137f"
+ app.kubernetes.io/version: "20220112-93dc2a37"
+ serving.knative.dev/release: "v20220112-93dc2a37"
data:
_example: |
################################
@@ -105,14 +105,14 @@ spec:
app: net-contour-controller
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220106-35a6137f"
+ app.kubernetes.io/version: "20220112-93dc2a37"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:d0d1f50d77c1816af98045e70dc8aaadc03088cc71d52dfc66c90f1bfabd4129
+ image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:c675affd0641cfd6a92842c8f658287779064ac97edc471312012dbba6239b9f
resources:
requests:
cpu: 40m
From 8beafe7f1683e42d0ddd72e198f665551004a493 Mon Sep 17 00:00:00 2001
From: Bin Liang
Date: Thu, 13 Jan 2022 00:36:51 +0800
Subject: [PATCH 081/733] fix container name collision (#12374)
---
pkg/apis/serving/k8s_validation.go | 23 ++++++-
pkg/apis/serving/k8s_validation_test.go | 63 ++++++++++++++++++-
.../serving/v1/revision_validation_test.go | 2 +
3 files changed, 85 insertions(+), 3 deletions(-)
diff --git a/pkg/apis/serving/k8s_validation.go b/pkg/apis/serving/k8s_validation.go
index 608afa78a217..2d03ecbdbd79 100644
--- a/pkg/apis/serving/k8s_validation.go
+++ b/pkg/apis/serving/k8s_validation.go
@@ -319,7 +319,7 @@ func ValidatePodSpec(ctx context.Context, ps corev1.PodSpec) *apis.FieldError {
volumes, err := ValidateVolumes(ctx, ps.Volumes, AllMountedVolumes(append(ps.InitContainers, ps.Containers...)))
errs = errs.Also(err.ViaField("volumes"))
- errs = errs.Also(validateInitContainers(ctx, ps.InitContainers, volumes))
+ errs = errs.Also(validateInitContainers(ctx, ps.InitContainers, ps.Containers, volumes))
port, err := validateContainersPorts(ps.Containers)
errs = errs.Also(err.ViaField("containers[*]"))
@@ -341,7 +341,7 @@ func ValidatePodSpec(ctx context.Context, ps corev1.PodSpec) *apis.FieldError {
return errs
}
-func validateInitContainers(ctx context.Context, containers []corev1.Container, volumes map[string]corev1.Volume) (errs *apis.FieldError) {
+func validateInitContainers(ctx context.Context, containers, otherContainers []corev1.Container, volumes map[string]corev1.Volume) (errs *apis.FieldError) {
if len(containers) == 0 {
return nil
}
@@ -350,7 +350,17 @@ func validateInitContainers(ctx context.Context, containers []corev1.Container,
return errs.Also(&apis.FieldError{Message: fmt.Sprintf("pod spec support for init-containers is off, "+
"but found %d init containers", len(containers))})
}
+ allNames := make(sets.String, len(otherContainers)+len(containers))
+ for _, ctr := range otherContainers {
+ allNames.Insert(ctr.Name)
+ }
for i := range containers {
+ if allNames.Has(containers[i].Name) {
+ errs = errs.Also(&apis.FieldError{
+ Message: fmt.Sprintf("duplicate container name %q", containers[i].Name),
+ Paths: []string{"name"},
+ }).ViaFieldIndex("containers", i)
+ }
errs = errs.Also(validateInitContainer(ctx, containers[i], volumes).ViaFieldIndex("containers", i))
}
return errs
@@ -362,7 +372,16 @@ func validateContainers(ctx context.Context, containers []corev1.Container, volu
return errs.Also(&apis.FieldError{Message: fmt.Sprintf("multi-container is off, "+
"but found %d containers", len(containers))})
}
+ allNames := make(sets.String, len(containers))
for i := range containers {
+ if allNames.Has(containers[i].Name) {
+ errs = errs.Also(&apis.FieldError{
+ Message: fmt.Sprintf("duplicate container name %q", containers[i].Name),
+ Paths: []string{"name"},
+ }).ViaFieldIndex("containers", i)
+ } else {
+ allNames.Insert(containers[i].Name)
+ }
// Probes are not allowed on other than serving container,
// ref: http://bit.ly/probes-condition
if len(containers[i].Ports) == 0 {
diff --git a/pkg/apis/serving/k8s_validation_test.go b/pkg/apis/serving/k8s_validation_test.go
index e9c1283b54ce..6f9b21d185b0 100644
--- a/pkg/apis/serving/k8s_validation_test.go
+++ b/pkg/apis/serving/k8s_validation_test.go
@@ -30,6 +30,7 @@ import (
"k8s.io/apimachinery/pkg/util/validation"
"knative.dev/pkg/apis"
"knative.dev/pkg/ptr"
+
"knative.dev/serving/pkg/apis/config"
)
@@ -417,6 +418,41 @@ func TestPodSpecValidation(t *testing.T) {
Message: `volume with name "debugging-support-files" not mounted`,
Paths: []string{"volumes[0].name"},
},
+ }, {
+ name: "init-container name collision",
+ ps: corev1.PodSpec{
+ InitContainers: []corev1.Container{{
+ Name: "the-name",
+ Image: "busybox",
+ }},
+ Containers: []corev1.Container{{
+ Name: "the-name",
+ Image: "busybox",
+ }},
+ },
+ cfgOpts: []configOption{withPodSpecInitContainersEnabled()},
+ want: (&apis.FieldError{
+ Message: `duplicate container name "the-name"`,
+ Paths: []string{"name"},
+ }).ViaFieldIndex("containers", 0),
+ }, {
+ name: "container name collision",
+ ps: corev1.PodSpec{
+ Containers: []corev1.Container{{
+ Name: "the-name",
+ Image: "busybox",
+ Ports: []corev1.ContainerPort{{
+ ContainerPort: 8888,
+ }},
+ }, {
+ Name: "the-name",
+ Image: "busybox",
+ }},
+ },
+ want: (&apis.FieldError{
+ Message: `duplicate container name "the-name"`,
+ Paths: []string{"name"},
+ }).ViaFieldIndex("containers", 1),
}}
for _, test := range tests {
@@ -461,11 +497,13 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: more than one container with one container port",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{
ContainerPort: 8888,
}},
}, {
+ Name: "container-b",
Image: "helloworld",
}},
},
@@ -474,11 +512,13 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: probes are not allowed for non serving containers",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{
ContainerPort: 8888,
}},
}, {
+ Name: "container-b",
Image: "helloworld",
LivenessProbe: &corev1.Probe{
TimeoutSeconds: 1,
@@ -496,8 +536,10 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: multiple containers with no port",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
}, {
+ Name: "container-b",
Image: "helloworld",
}},
},
@@ -506,11 +548,13 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: multiple containers with multiple port",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{
ContainerPort: 8888,
}},
}, {
+ Name: "container-b",
Image: "helloworld",
Ports: []corev1.ContainerPort{{
ContainerPort: 9999,
@@ -526,6 +570,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: multiple containers with multiple ports for each container",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{
ContainerPort: 8888,
@@ -533,6 +578,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
ContainerPort: 9999,
}},
}, {
+ Name: "container-b",
Image: "helloworld",
Ports: []corev1.ContainerPort{{
ContainerPort: 80,
@@ -548,6 +594,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: multiple containers with multiple port for a single container",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{
ContainerPort: 8888,
@@ -555,6 +602,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
ContainerPort: 9999,
}},
}, {
+ Name: "container-b",
Image: "helloworld",
}},
},
@@ -567,11 +615,13 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: multiple containers with readinessProbe targeting different container's port",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "work",
Ports: []corev1.ContainerPort{{
ContainerPort: 9999,
}},
}, {
+ Name: "container-b",
Image: "health",
LivenessProbe: &corev1.Probe{
Handler: corev1.Handler{
@@ -587,11 +637,13 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: multiple containers with illegal env variable defined for side car",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{
ContainerPort: 8888,
}},
}, {
+ Name: "container-b",
Image: "helloworld",
Env: []corev1.EnvVar{{
Name: "PORT",
@@ -610,11 +662,13 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
name: "flag enabled: multiple containers with PORT defined for side car",
ps: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{
ContainerPort: 8888,
}},
}, {
+ Name: "container-b",
Image: "helloworld",
Env: []corev1.EnvVar{{
Name: "PORT",
@@ -683,6 +737,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
},
Containers: []corev1.Container{
{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{ContainerPort: 8888}},
VolumeMounts: []corev1.VolumeMount{{
@@ -692,6 +747,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
}},
},
{
+ Name: "container-b",
Image: "busybox",
VolumeMounts: []corev1.VolumeMount{{
MountPath: "/mount/path",
@@ -721,6 +777,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
},
Containers: []corev1.Container{
{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{ContainerPort: 8888}},
VolumeMounts: []corev1.VolumeMount{{
@@ -729,7 +786,9 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
ReadOnly: true,
}},
},
- {Image: "busybox"},
+ {
+ Name: "container-b",
+ Image: "busybox"},
},
},
want: &apis.FieldError{
@@ -744,6 +803,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
Name: "install-nodejs-debug-support",
}},
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox1",
Ports: []corev1.ContainerPort{{ContainerPort: 8888}},
VolumeMounts: []corev1.VolumeMount{{
@@ -751,6 +811,7 @@ func TestPodSpecMultiContainerValidation(t *testing.T) {
MountPath: "/data",
}},
}, {
+ Name: "container-b",
Image: "busybox2",
VolumeMounts: []corev1.VolumeMount{{
Name: "debugging-support-files",
diff --git a/pkg/apis/serving/v1/revision_validation_test.go b/pkg/apis/serving/v1/revision_validation_test.go
index 66245ba5da7e..210060940f74 100644
--- a/pkg/apis/serving/v1/revision_validation_test.go
+++ b/pkg/apis/serving/v1/revision_validation_test.go
@@ -328,11 +328,13 @@ func TestRevisionSpecValidation(t *testing.T) {
rs: &RevisionSpec{
PodSpec: corev1.PodSpec{
Containers: []corev1.Container{{
+ Name: "container-a",
Image: "busybox",
Ports: []corev1.ContainerPort{{
ContainerPort: 8881,
}},
}, {
+ Name: "container-b",
Image: "helloworld",
}},
},
From ee55bd0fff5442f6c21c527fc85098448a107556 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Wed, 12 Jan 2022 20:51:12 -0800
Subject: [PATCH 082/733] Update actions (#12500)
Signed-off-by: Knative Automation
---
.github/workflows/knative-releasability.yaml | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/.github/workflows/knative-releasability.yaml b/.github/workflows/knative-releasability.yaml
index a9a2955a0bf3..df686a891e0d 100644
--- a/.github/workflows/knative-releasability.yaml
+++ b/.github/workflows/knative-releasability.yaml
@@ -38,9 +38,9 @@ jobs:
env:
#########################################
# Update this section each release. #
- RELEASE: 'v1.1'
- MODULE_RELEASE: 'v0.28'
- SLACK_CHANNEL: 'release-1dot1'
+ RELEASE: 'v1.2'
+ MODULE_RELEASE: 'v0.29'
+ SLACK_CHANNEL: 'release-1dot2'
#########################################
steps:
From 7537f28f1f8e966297ad4158b7168aec12f457a6 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 13 Jan 2022 06:57:12 -0800
Subject: [PATCH 083/733] Update net-kourier nightly (#12504)
bumping knative.dev/net-kourier 7c0be88...99c7171:
> 99c7171 Update actions (# 748)
> cb699ef upgrade to latest dependencies (# 749)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index 0770d6dd389d..d97b70601b96 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
- serving.knative.dev/release: "v20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
+ serving.knative.dev/release: "v20220113-99c71712"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:e4b232ef86d147f3f85351694b56bf9ac22fe4d29c516b14578b2a1ac30eae41
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:ab262ea9bec46a25fbce874960efd8d08bf53d0c272fbd4e216a3ee75c572e63
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220112-7c0be88f"
+ app.kubernetes.io/version: "20220113-99c71712"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-7c0be88f"
+ serving.knative.dev/release: "v20220113-99c71712"
spec:
ports:
- name: http2
From d7ba02e0cd69a6a0f2a98002dc2dd6f6fe43bab4 Mon Sep 17 00:00:00 2001
From: Dave Protasowski
Date: Thu, 13 Jan 2022 13:20:12 -0500
Subject: [PATCH 084/733] fix leader election issues due to defaults change
(#12506)
* fix leader election issues due to defaults change
knative.dev/pkg changed the default values of the leader election config
this change includes
- update servings config map to include these new defaults in the example
- update the unit test that had the prior defaults baked in
- update our e2e tests with the prior values
- our e2e controller HA test has some timing issues with the longer failover
* fix ytt comments
* update matching rules
---
config/core/configmaps/leader-election.yaml | 8 +++---
go.mod | 7 ++---
go.sum | 14 +++++-----
pkg/leaderelection/config_test.go | 12 ++++-----
test/config/ytt/ha/overlay-ha.yaml | 8 +++++-
.../knative.dev/pkg/leaderelection/config.go | 6 ++---
vendor/knative.dev/pkg/leaderelection/doc.go | 27 +++++++++++++++++++
vendor/modules.txt | 7 ++---
8 files changed, 61 insertions(+), 28 deletions(-)
create mode 100644 vendor/knative.dev/pkg/leaderelection/doc.go
diff --git a/config/core/configmaps/leader-election.yaml b/config/core/configmaps/leader-election.yaml
index cdfab27a3a91..6eae132359ff 100644
--- a/config/core/configmaps/leader-election.yaml
+++ b/config/core/configmaps/leader-election.yaml
@@ -23,7 +23,7 @@ metadata:
app.kubernetes.io/version: devel
serving.knative.dev/release: devel
annotations:
- knative.dev/example-checksum: "f7948630"
+ knative.dev/example-checksum: "f4b71f57"
data:
_example: |
################################
@@ -43,15 +43,15 @@ data:
# lease-duration is how long non-leaders will wait to try to acquire the
# lock; 15 seconds is the value used by core kubernetes controllers.
- lease-duration: "15s"
+ lease-duration: "60s"
# renew-deadline is how long a leader will try to renew the lease before
# giving up; 10 seconds is the value used by core kubernetes controllers.
- renew-deadline: "10s"
+ renew-deadline: "40s"
# retry-period is how long the leader election client waits between tries of
# actions; 2 seconds is the value used by core kubernetes controllers.
- retry-period: "2s"
+ retry-period: "10s"
# buckets is the number of buckets used to partition key space of each
# Reconciler. If this number is M and the replica number of the controller
diff --git a/go.mod b/go.mod
index dde69507268d..3a03f456b250 100644
--- a/go.mod
+++ b/go.mod
@@ -35,10 +35,11 @@ require (
k8s.io/apimachinery v0.22.5
k8s.io/client-go v0.22.5
k8s.io/code-generator v0.22.5
+ k8s.io/klog v1.0.0 // indirect
k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c
- knative.dev/caching v0.0.0-20220111134414-669d362b44c5
+ knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931
knative.dev/hack v0.0.0-20220111151514-59b0cf17578e
- knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf
- knative.dev/pkg v0.0.0-20220111210214-785eb637f693
+ knative.dev/networking v0.0.0-20220112013650-eac673fb5c49
+ knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1
sigs.k8s.io/yaml v1.3.0
)
diff --git a/go.sum b/go.sum
index db765a720ab3..c3750f261237 100644
--- a/go.sum
+++ b/go.sum
@@ -1661,18 +1661,16 @@ k8s.io/legacy-cloud-providers v0.21.0/go.mod h1:bNxo7gDg+PGkBmT/MFZswLTWdSWK9kAl
k8s.io/utils v0.0.0-20201110183641-67b214c5f920/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a h1:8dYfu/Fc9Gz2rNJKB9IQRGgQOh2clmRzNIPPY1xLY5g=
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
-knative.dev/caching v0.0.0-20220111134414-669d362b44c5 h1:fkUkaIkFBPtxp/9thpmFze0XmgQTq7BLdk3Ce3rlzjs=
-knative.dev/caching v0.0.0-20220111134414-669d362b44c5/go.mod h1:uyFdKZ2WHnhTd+qc8sghvh/gAij28QAhs7qv7CgEP+U=
-knative.dev/hack v0.0.0-20211203062838-e11ac125e707/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/hack v0.0.0-20211222071919-abd085fc43de/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
+knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931 h1:hyZfmjpW2ZNR2cAJUWaDagcDdcyupozf+7BpN0ApHt8=
+knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931/go.mod h1:kHPJyq2W2ADNAwB6lmmJcleEZfNWioIL5yEs/p5WHU0=
knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/hack v0.0.0-20220111151514-59b0cf17578e h1:tESsFI1iMD2Al+6FZueFN9CddxJ8Fa2cd9KmyNINe3w=
knative.dev/hack v0.0.0-20220111151514-59b0cf17578e/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf h1:1RqxCIJBwvpahPVNCfxEk4Z/z7nHgmBhPp7ba9A1My0=
-knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf/go.mod h1:kXbsW1qHQcwHyd7qV1bHeYxGysR6XHh/hCkEvk28R/s=
-knative.dev/pkg v0.0.0-20220105211333-96f18522d78d/go.mod h1:189cvGP0mwpqwZGFrLk5WuERIsNI/J6HuQ1CIX7SXxY=
-knative.dev/pkg v0.0.0-20220111210214-785eb637f693 h1:uOIXXDSMBe50XmdVwORYzN5zh/drNDAtkzmpT+yCvns=
+knative.dev/networking v0.0.0-20220112013650-eac673fb5c49 h1:JVeh94aZzA+cxaEMVdAHYkB4lJGAGuW8ajTRV+zPMLg=
+knative.dev/networking v0.0.0-20220112013650-eac673fb5c49/go.mod h1:nHxcidoraPg5khZCS12YHAjdZhXBpexWKs7Qn+lgOc8=
knative.dev/pkg v0.0.0-20220111210214-785eb637f693/go.mod h1:YVa0jO4t3eLg9YD/4IDs9TsZsF+g1nx8T9szmlbY/Yc=
+knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1 h1:vingyaoZbiMRLha4JCVxPG0ghcpjKVN9VGikAHwpqqs=
+knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1/go.mod h1:X5B0/SR3tzOioS2WQtS9uJTO71M52qcrDkWQ5wtyLVc=
pgregory.net/rapid v0.3.3 h1:jCjBsY4ln4Atz78QoBWxUEvAHaFyNDQg9+WU62aCn1U=
pgregory.net/rapid v0.3.3/go.mod h1:UYpPVyjFHzYBGHIxLFoupi8vwk6rXNzRY9OMvVxFIOU=
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
diff --git a/pkg/leaderelection/config_test.go b/pkg/leaderelection/config_test.go
index 277428f85ef4..1c3b63a8b5a8 100644
--- a/pkg/leaderelection/config_test.go
+++ b/pkg/leaderelection/config_test.go
@@ -99,18 +99,18 @@ func TestServingConfig(t *testing.T) {
name: "Default config",
want: &kle.Config{
Buckets: 1,
- LeaseDuration: 15 * time.Second,
- RenewDeadline: 10 * time.Second,
- RetryPeriod: 2 * time.Second,
+ LeaseDuration: 1 * time.Minute,
+ RenewDeadline: 40 * time.Second,
+ RetryPeriod: 10 * time.Second,
},
data: actual,
}, {
name: "Example config",
want: &kle.Config{
Buckets: 1,
- LeaseDuration: 15 * time.Second,
- RenewDeadline: 10 * time.Second,
- RetryPeriod: 2 * time.Second,
+ LeaseDuration: 1 * time.Minute,
+ RenewDeadline: 40 * time.Second,
+ RetryPeriod: 10 * time.Second,
},
data: example,
}} {
diff --git a/test/config/ytt/ha/overlay-ha.yaml b/test/config/ytt/ha/overlay-ha.yaml
index dea7ed3a8ae3..c9edb6f2d811 100644
--- a/test/config/ytt/ha/overlay-ha.yaml
+++ b/test/config/ytt/ha/overlay-ha.yaml
@@ -18,6 +18,12 @@ spec:
#@overlay/match by=system_configmap("config-leader-election"), expects=1
---
+#@overlay/match-child-defaults missing_ok=True
data:
- #@overlay/match missing_ok=True
buckets: #@ str(data.values.serving.ha.buckets)
+
+ #! These defaults are more aggressive to cause the fail over to happen
+ #! more quickly given chaosduck
+ lease-duration: "15s"
+ renew-deadline: "10s"
+ retry-period: "2s"
diff --git a/vendor/knative.dev/pkg/leaderelection/config.go b/vendor/knative.dev/pkg/leaderelection/config.go
index 0694395bf903..f07c30cea0fe 100644
--- a/vendor/knative.dev/pkg/leaderelection/config.go
+++ b/vendor/knative.dev/pkg/leaderelection/config.go
@@ -98,9 +98,9 @@ func (c *Config) GetComponentConfig(name string) ComponentConfig {
func defaultConfig() *Config {
return &Config{
Buckets: 1,
- LeaseDuration: 15 * time.Second,
- RenewDeadline: 10 * time.Second,
- RetryPeriod: 2 * time.Second,
+ LeaseDuration: 60 * time.Second,
+ RenewDeadline: 40 * time.Second,
+ RetryPeriod: 10 * time.Second,
}
}
diff --git a/vendor/knative.dev/pkg/leaderelection/doc.go b/vendor/knative.dev/pkg/leaderelection/doc.go
new file mode 100644
index 000000000000..fb7e162f7683
--- /dev/null
+++ b/vendor/knative.dev/pkg/leaderelection/doc.go
@@ -0,0 +1,27 @@
+/*
+Copyright 2020 The Knative Authors
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+
+// LeaderElection provides an interface for controllers implementing using
+// controller injection:
+// https://github.com/knative/pkg/blob/main/injection/README.md
+//
+// Leaderelection uses the context-stuffing mechanism to provide config-driven
+// management of multiple election strategies (currently, using Kubernetes
+// etcd-based election primitives or StatefulSet indexes and counts).
+//
+// For more details, see the original design document:
+// https://docs.google.com/document/d/e/2PACX-1vTh40N-Kk6EPNzYpITiLg8YJk0qZyZv7KgMpcQS72T9Lv_F2PQeGybx4TtH0E1N1aUgLQer7b8u3lDc/pub
+package leaderelection
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 3a0ffe9ea15a..93cdb8abba39 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -965,6 +965,7 @@ k8s.io/gengo/namer
k8s.io/gengo/parser
k8s.io/gengo/types
# k8s.io/klog v1.0.0
+## explicit
k8s.io/klog
# k8s.io/klog/v2 v2.40.1
k8s.io/klog/v2
@@ -986,7 +987,7 @@ k8s.io/utils/buffer
k8s.io/utils/integer
k8s.io/utils/pointer
k8s.io/utils/trace
-# knative.dev/caching v0.0.0-20220111134414-669d362b44c5
+# knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931
## explicit
knative.dev/caching/config
knative.dev/caching/pkg/apis/caching
@@ -1011,7 +1012,7 @@ knative.dev/caching/pkg/client/listers/caching/v1alpha1
## explicit
knative.dev/hack
knative.dev/hack/shell
-# knative.dev/networking v0.0.0-20220107020122-0dbedcd88acf
+# knative.dev/networking v0.0.0-20220112013650-eac673fb5c49
## explicit
knative.dev/networking/config
knative.dev/networking/pkg
@@ -1041,7 +1042,7 @@ knative.dev/networking/pkg/client/injection/reconciler/networking/v1alpha1/serve
knative.dev/networking/pkg/client/listers/networking/v1alpha1
knative.dev/networking/pkg/ingress
knative.dev/networking/pkg/prober
-# knative.dev/pkg v0.0.0-20220111210214-785eb637f693
+# knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1
## explicit
knative.dev/pkg/apiextensions/storageversion
knative.dev/pkg/apiextensions/storageversion/cmd/migrate
From 9073261f9b894a7a3f3cb5c7a8180a5ea044e9b0 Mon Sep 17 00:00:00 2001
From: Nader Ziada
Date: Thu, 13 Jan 2022 15:33:12 -0500
Subject: [PATCH 085/733] fix broken samples link (#12508)
---
sample/README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sample/README.md b/sample/README.md
index 96689717e445..ab7119883a91 100644
--- a/sample/README.md
+++ b/sample/README.md
@@ -1,4 +1,4 @@
# Serving Samples
Samples for Knative Serving are available in the
-[Knative Docs repo](https://github.com/knative/docs/tree/main/docs/serving/samples).
+[Knative Docs repo](https://github.com/knative/docs/tree/main/code-samples/serving).
From a75ee0916043a6e3d44d19b6e69fd6ee4337eb2b Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Mon, 17 Jan 2022 08:46:29 -0800
Subject: [PATCH 086/733] upgrade to latest dependencies (#12513)
bumping knative.dev/pkg c0e1594...0a429cb:
> 0a429cb Allow Unstructured callback from Defaulting Webhook (# 2363)
bumping knative.dev/networking eac673f...52fb6ee:
> 52fb6ee upgrade to latest dependencies (# 601)
> db53592 Update actions (# 600)
Signed-off-by: Knative Automation
---
go.mod | 4 +-
go.sum | 9 +-
.../defaulting/controller.go | 22 +++-
.../defaulting/defaulting.go | 124 +++++++++++++++++-
.../resourcesemantics/defaulting/user_info.go | 33 +++++
vendor/modules.txt | 4 +-
6 files changed, 178 insertions(+), 18 deletions(-)
diff --git a/go.mod b/go.mod
index 3a03f456b250..31e621b92a20 100644
--- a/go.mod
+++ b/go.mod
@@ -39,7 +39,7 @@ require (
k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c
knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931
knative.dev/hack v0.0.0-20220111151514-59b0cf17578e
- knative.dev/networking v0.0.0-20220112013650-eac673fb5c49
- knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1
+ knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9
+ knative.dev/pkg v0.0.0-20220114141842-0a429cba1c73
sigs.k8s.io/yaml v1.3.0
)
diff --git a/go.sum b/go.sum
index c3750f261237..13ef864cad05 100644
--- a/go.sum
+++ b/go.sum
@@ -1663,14 +1663,13 @@ k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a h1:8dYfu/Fc9Gz2rNJKB9IQRGgQOh2cl
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931 h1:hyZfmjpW2ZNR2cAJUWaDagcDdcyupozf+7BpN0ApHt8=
knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931/go.mod h1:kHPJyq2W2ADNAwB6lmmJcleEZfNWioIL5yEs/p5WHU0=
-knative.dev/hack v0.0.0-20220110200259-f08cb0dcdee7/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/hack v0.0.0-20220111151514-59b0cf17578e h1:tESsFI1iMD2Al+6FZueFN9CddxJ8Fa2cd9KmyNINe3w=
knative.dev/hack v0.0.0-20220111151514-59b0cf17578e/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/networking v0.0.0-20220112013650-eac673fb5c49 h1:JVeh94aZzA+cxaEMVdAHYkB4lJGAGuW8ajTRV+zPMLg=
-knative.dev/networking v0.0.0-20220112013650-eac673fb5c49/go.mod h1:nHxcidoraPg5khZCS12YHAjdZhXBpexWKs7Qn+lgOc8=
-knative.dev/pkg v0.0.0-20220111210214-785eb637f693/go.mod h1:YVa0jO4t3eLg9YD/4IDs9TsZsF+g1nx8T9szmlbY/Yc=
-knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1 h1:vingyaoZbiMRLha4JCVxPG0ghcpjKVN9VGikAHwpqqs=
+knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9 h1:wX0XDJhZelDUO5IwENO32gEwwB1pYrRyuRq42z8z3GI=
+knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9/go.mod h1:h4JrHof14QSggAnthL3DPFw1cieenumKDaT+wg0EPmE=
knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1/go.mod h1:X5B0/SR3tzOioS2WQtS9uJTO71M52qcrDkWQ5wtyLVc=
+knative.dev/pkg v0.0.0-20220114141842-0a429cba1c73 h1:O2rdhNu49InR/IciU06z+vtTa/ygtFFBGHBdZPcGMdE=
+knative.dev/pkg v0.0.0-20220114141842-0a429cba1c73/go.mod h1:X5B0/SR3tzOioS2WQtS9uJTO71M52qcrDkWQ5wtyLVc=
pgregory.net/rapid v0.3.3 h1:jCjBsY4ln4Atz78QoBWxUEvAHaFyNDQg9+WU62aCn1U=
pgregory.net/rapid v0.3.3/go.mod h1:UYpPVyjFHzYBGHIxLFoupi8vwk6rXNzRY9OMvVxFIOU=
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
diff --git a/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/controller.go b/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/controller.go
index a4a41d0beaff..b50fcf8f41d6 100644
--- a/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/controller.go
+++ b/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/controller.go
@@ -29,6 +29,7 @@ import (
"k8s.io/apimachinery/pkg/runtime/schema"
"k8s.io/apimachinery/pkg/types"
"k8s.io/client-go/tools/cache"
+
"knative.dev/pkg/controller"
"knative.dev/pkg/system"
"knative.dev/pkg/webhook"
@@ -42,6 +43,7 @@ func NewAdmissionController(
handlers map[schema.GroupVersionKind]resourcesemantics.GenericCRD,
wc func(context.Context) context.Context,
disallowUnknownFields bool,
+ callbacks ...map[schema.GroupVersionKind]Callback,
) *controller.Impl {
client := kubeclient.Get(ctx)
@@ -51,6 +53,19 @@ func NewAdmissionController(
key := types.NamespacedName{Name: name}
+ // This not ideal, we are using a variadic argument to effectively make callbacks optional
+ // This allows this addition to be non-breaking to consumers of /pkg
+ // TODO: once all sub-repos have adopted this, we might move this back to a traditional param.
+ var unwrappedCallbacks map[schema.GroupVersionKind]Callback
+ switch len(callbacks) {
+ case 0:
+ unwrappedCallbacks = map[schema.GroupVersionKind]Callback{}
+ case 1:
+ unwrappedCallbacks = callbacks[0]
+ default:
+ panic("NewAdmissionController may not be called with multiple callback maps")
+ }
+
wh := &reconciler{
LeaderAwareFuncs: pkgreconciler.LeaderAwareFuncs{
// Have this reconciler enqueue our singleton whenever it becomes leader.
@@ -60,9 +75,10 @@ func NewAdmissionController(
},
},
- key: key,
- path: path,
- handlers: handlers,
+ key: key,
+ path: path,
+ handlers: handlers,
+ callbacks: unwrappedCallbacks,
withContext: wc,
disallowUnknownFields: disallowUnknownFields,
diff --git a/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/defaulting.go b/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/defaulting.go
index 504dcaa06610..a8a30fae13dd 100644
--- a/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/defaulting.go
+++ b/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/defaulting.go
@@ -25,16 +25,18 @@ import (
"github.com/gobuffalo/flect"
"go.uber.org/zap"
- jsonpatch "gomodules.xyz/jsonpatch/v2"
+ "gomodules.xyz/jsonpatch/v2"
admissionv1 "k8s.io/api/admission/v1"
admissionregistrationv1 "k8s.io/api/admissionregistration/v1"
corev1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
"k8s.io/apimachinery/pkg/runtime/schema"
"k8s.io/apimachinery/pkg/types"
"k8s.io/client-go/kubernetes"
admissionlisters "k8s.io/client-go/listers/admissionregistration/v1"
corelisters "k8s.io/client-go/listers/core/v1"
+
"knative.dev/pkg/apis"
"knative.dev/pkg/apis/duck"
"knative.dev/pkg/controller"
@@ -56,9 +58,10 @@ type reconciler struct {
webhook.StatelessAdmissionImpl
pkgreconciler.LeaderAwareFuncs
- key types.NamespacedName
- path string
- handlers map[schema.GroupVersionKind]resourcesemantics.GenericCRD
+ key types.NamespacedName
+ path string
+ handlers map[schema.GroupVersionKind]resourcesemantics.GenericCRD
+ callbacks map[schema.GroupVersionKind]Callback
withContext func(context.Context) context.Context
@@ -70,6 +73,37 @@ type reconciler struct {
secretName string
}
+// CallbackFunc is the function to be invoked.
+type CallbackFunc func(ctx context.Context, unstructured *unstructured.Unstructured) error
+
+// Callback is a generic function to be called by a consumer of defaulting.
+type Callback struct {
+ // function is the callback to be invoked.
+ function CallbackFunc
+
+ // supportedVerbs are the verbs supported for the callback.
+ // The function will only be called on these actions.
+ supportedVerbs map[webhook.Operation]struct{}
+}
+
+// NewCallback creates a new callback function to be invoked on supported verbs.
+func NewCallback(function func(context.Context, *unstructured.Unstructured) error, supportedVerbs ...webhook.Operation) Callback {
+ if function == nil {
+ panic("expected function, got nil")
+ }
+ m := make(map[webhook.Operation]struct{})
+ for _, op := range supportedVerbs {
+ if op == webhook.Delete {
+ panic("Verb " + webhook.Delete + " not allowed")
+ }
+ if _, has := m[op]; has {
+ panic("duplicate verbs not allowed")
+ }
+ m[op] = struct{}{}
+ }
+ return Callback{function: function, supportedVerbs: m}
+}
+
var _ controller.Reconciler = (*reconciler)(nil)
var _ pkgreconciler.LeaderAware = (*reconciler)(nil)
var _ webhook.AdmissionController = (*reconciler)(nil)
@@ -137,7 +171,17 @@ func (ac *reconciler) reconcileMutatingWebhook(ctx context.Context, caCert []byt
logger := logging.FromContext(ctx)
rules := make([]admissionregistrationv1.RuleWithOperations, 0, len(ac.handlers))
+ gvks := make(map[schema.GroupVersionKind]struct{}, len(ac.handlers)+len(ac.callbacks))
for gvk := range ac.handlers {
+ gvks[gvk] = struct{}{}
+ }
+ for gvk := range ac.callbacks {
+ if _, ok := gvks[gvk]; !ok {
+ gvks[gvk] = struct{}{}
+ }
+ }
+
+ for gvk := range gvks {
plural := strings.ToLower(flect.Pluralize(gvk.Kind))
rules = append(rules, admissionregistrationv1.RuleWithOperations{
@@ -231,8 +275,18 @@ func (ac *reconciler) mutate(ctx context.Context, req *admissionv1.AdmissionRequ
logger := logging.FromContext(ctx)
handler, ok := ac.handlers[gvk]
if !ok {
- logger.Error("Unhandled kind: ", gvk)
- return nil, fmt.Errorf("unhandled kind: %v", gvk)
+ if _, ok := ac.callbacks[gvk]; !ok {
+ logger.Error("Unhandled kind: ", gvk)
+ return nil, fmt.Errorf("unhandled kind: %v", gvk)
+ }
+ patches, err := ac.callback(ctx, gvk, req, true /* shouldSetUserInfo */, duck.JSONPatch{})
+ if err != nil {
+ logger.Errorw("Failed the callback defaulter", zap.Error(err))
+ // Return the error message as-is to give the defaulter callback
+ // discretion over (our portion of) the message that the user sees.
+ return nil, err
+ }
+ return json.Marshal(patches)
}
// nil values denote absence of `old` (create) or `new` (delete) objects.
@@ -302,6 +356,13 @@ func (ac *reconciler) mutate(ctx context.Context, req *admissionv1.AdmissionRequ
return nil, err
}
+ if patches, err = ac.callback(ctx, gvk, req, false /* shouldSetUserInfo */, patches); err != nil {
+ logger.Errorw("Failed the callback defaulter", zap.Error(err))
+ // Return the error message as-is to give the defaulter callback
+ // discretion over (our portion of) the message that the user sees.
+ return nil, err
+ }
+
// None of the validators will accept a nil value for newObj.
if newObj == nil {
return nil, errMissingNewObject
@@ -329,6 +390,57 @@ func (ac *reconciler) setUserInfoAnnotations(ctx context.Context, patches duck.J
return append(patches, patch...), nil
}
+func (ac *reconciler) callback(ctx context.Context, gvk schema.GroupVersionKind, req *admissionv1.AdmissionRequest, shouldSetUserInfo bool, patches duck.JSONPatch) (duck.JSONPatch, error) {
+ // Get callback.
+ callback, ok := ac.callbacks[gvk]
+ if !ok {
+ return patches, nil
+ }
+
+ // Check if request operation is a supported webhook operation.
+ if _, isSupported := callback.supportedVerbs[req.Operation]; !isSupported {
+ return patches, nil
+ }
+
+ oldBytes := req.OldObject.Raw
+ newBytes := req.Object.Raw
+
+ before := &unstructured.Unstructured{}
+ after := &unstructured.Unstructured{}
+
+ // Get unstructured object.
+ if err := json.Unmarshal(newBytes, before); err != nil {
+ return nil, fmt.Errorf("cannot decode object: %w", err)
+ }
+ // Copy before in after unstructured objects.
+ before.DeepCopyInto(after)
+
+ // Setup context.
+ if len(oldBytes) != 0 {
+ if req.SubResource == "" {
+ ctx = apis.WithinUpdate(ctx, before)
+ } else {
+ ctx = apis.WithinSubResourceUpdate(ctx, before, req.SubResource)
+ }
+ } else {
+ ctx = apis.WithinCreate(ctx)
+ }
+ ctx = apis.WithUserInfo(ctx, &req.UserInfo)
+
+ // Call callback passing after.
+ if err := callback.function(ctx, after); err != nil {
+ return patches, err
+ }
+
+ if shouldSetUserInfo {
+ setUserInfoAnnotations(adaptUnstructuredHasSpecCtx(ctx, req), unstructuredHasSpec{after}, req.Resource.Group)
+ }
+
+ // Create patches.
+ patch, err := duck.CreatePatch(before.Object, after.Object)
+ return append(patches, patch...), err
+}
+
// roundTripPatch generates the JSONPatch that corresponds to round tripping the given bytes through
// the Golang type (JSON -> Golang type -> JSON). Because it is not always true that
// bytes == json.Marshal(json.Unmarshal(bytes)).
diff --git a/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/user_info.go b/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/user_info.go
index 36c1cfbd215b..fcd97a45617d 100644
--- a/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/user_info.go
+++ b/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/user_info.go
@@ -19,8 +19,11 @@ package defaulting
import (
"context"
+ admissionv1 "k8s.io/api/admission/v1"
"k8s.io/apimachinery/pkg/api/equality"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
+
"knative.dev/pkg/apis"
)
@@ -48,5 +51,35 @@ func setUserInfoAnnotations(ctx context.Context, resource apis.HasSpec, groupNam
annotations[groupName+apis.CreatorAnnotationSuffix] = ui.Username
annotations[groupName+apis.UpdaterAnnotationSuffix] = ui.Username
}
+ objectMetaAccessor.GetObjectMeta().SetAnnotations(annotations)
+ }
+}
+
+type unstructuredHasSpec struct {
+ *unstructured.Unstructured
+}
+
+func (us unstructuredHasSpec) GetObjectMeta() metav1.Object {
+ return us.Unstructured
+}
+
+var _ metav1.ObjectMetaAccessor = unstructuredHasSpec{}
+
+func (us unstructuredHasSpec) GetUntypedSpec() interface{} {
+ if s, ok := us.Unstructured.Object["spec"]; ok {
+ return s
+ }
+ return nil
+}
+
+func adaptUnstructuredHasSpecCtx(ctx context.Context, req *admissionv1.AdmissionRequest) context.Context {
+ if apis.IsInUpdate(ctx) {
+ b := apis.GetBaseline(ctx)
+ if apis.IsInStatusUpdate(ctx) {
+ ctx = apis.WithinSubResourceUpdate(ctx, unstructuredHasSpec{b.(*unstructured.Unstructured)}, req.SubResource)
+ } else {
+ ctx = apis.WithinUpdate(ctx, unstructuredHasSpec{b.(*unstructured.Unstructured)})
+ }
}
+ return ctx
}
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 93cdb8abba39..617044e86c0e 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -1012,7 +1012,7 @@ knative.dev/caching/pkg/client/listers/caching/v1alpha1
## explicit
knative.dev/hack
knative.dev/hack/shell
-# knative.dev/networking v0.0.0-20220112013650-eac673fb5c49
+# knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9
## explicit
knative.dev/networking/config
knative.dev/networking/pkg
@@ -1042,7 +1042,7 @@ knative.dev/networking/pkg/client/injection/reconciler/networking/v1alpha1/serve
knative.dev/networking/pkg/client/listers/networking/v1alpha1
knative.dev/networking/pkg/ingress
knative.dev/networking/pkg/prober
-# knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1
+# knative.dev/pkg v0.0.0-20220114141842-0a429cba1c73
## explicit
knative.dev/pkg/apiextensions/storageversion
knative.dev/pkg/apiextensions/storageversion/cmd/migrate
From db1b4adbedcb7bab5427a8432adf572d94262324 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Mon, 17 Jan 2022 10:00:29 -0800
Subject: [PATCH 087/733] Update net-kourier nightly (#12515)
bumping knative.dev/net-kourier 99c7171...37d3663:
> 37d3663 Update actions (# 752)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index d97b70601b96..52e572bbd4f9 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
- serving.knative.dev/release: "v20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
+ serving.knative.dev/release: "v20220117-37d36631"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:ab262ea9bec46a25fbce874960efd8d08bf53d0c272fbd4e216a3ee75c572e63
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:8a15c99a0d1808b6a84a302d863dc1f1d5c85f19c6cd06ca6b3f9460a3c7190b
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220113-99c71712"
+ app.kubernetes.io/version: "20220117-37d36631"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220113-99c71712"
+ serving.knative.dev/release: "v20220117-37d36631"
spec:
ports:
- name: http2
From a56024272594aebd32e0a7dee90bbf1480204c03 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Mon, 17 Jan 2022 11:12:29 -0800
Subject: [PATCH 088/733] Update net-contour nightly (#12514)
bumping knative.dev/net-contour 93dc2a3...de98775:
> de98775 Re-use upstream contour image for cmd/contour (# 702)
Signed-off-by: Knative Automation
---
third_party/contour-latest/contour.yaml | 20 ++++++++++----------
third_party/contour-latest/net-contour.yaml | 10 +++++-----
2 files changed, 15 insertions(+), 15 deletions(-)
diff --git a/third_party/contour-latest/contour.yaml b/third_party/contour-latest/contour.yaml
index 7ba0cb5ae389..5be7509799f4 100644
--- a/third_party/contour-latest/contour.yaml
+++ b/third_party/contour-latest/contour.yaml
@@ -3448,8 +3448,8 @@ spec:
spec:
containers:
- name: contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
- imagePullPolicy: IfNotPresent
+ image: ghcr.io/projectcontour/contour:v1.19.1
+ imagePullPolicy: Always
command:
- contour
- certgen
@@ -3707,7 +3707,7 @@ spec:
- --config-path=/config/contour.yaml
command:
- contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
+ image: ghcr.io/projectcontour/contour:v1.19.1
imagePullPolicy: IfNotPresent
name: contour
ports:
@@ -3796,7 +3796,7 @@ spec:
args:
- envoy
- shutdown-manager
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
+ image: ghcr.io/projectcontour/contour:v1.19.1
imagePullPolicy: IfNotPresent
lifecycle:
preStop:
@@ -3892,7 +3892,7 @@ spec:
- --envoy-key-file=/certs/tls.key
command:
- contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
+ image: ghcr.io/projectcontour/contour:v1.19.1
imagePullPolicy: IfNotPresent
name: envoy-initconfig
volumeMounts:
@@ -4177,8 +4177,8 @@ spec:
spec:
containers:
- name: contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
- imagePullPolicy: IfNotPresent
+ image: ghcr.io/projectcontour/contour:v1.19.1
+ imagePullPolicy: Always
command:
- contour
- certgen
@@ -4289,7 +4289,7 @@ spec:
- --config-path=/config/contour.yaml
command:
- contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
+ image: ghcr.io/projectcontour/contour:v1.19.1
imagePullPolicy: IfNotPresent
name: contour
ports:
@@ -4378,7 +4378,7 @@ spec:
args:
- envoy
- shutdown-manager
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
+ image: ghcr.io/projectcontour/contour:v1.19.1
imagePullPolicy: IfNotPresent
lifecycle:
preStop:
@@ -4474,7 +4474,7 @@ spec:
- --envoy-key-file=/certs/tls.key
command:
- contour
- image: gcr.io/knative-nightly/github.com/projectcontour/contour/cmd/contour@sha256:9f784c04adfb7efcca970e5680cf6d0b0f6fdfb8d7f2a87a4a74a0525871bbe0
+ image: ghcr.io/projectcontour/contour:v1.19.1
imagePullPolicy: IfNotPresent
name: envoy-initconfig
volumeMounts:
diff --git a/third_party/contour-latest/net-contour.yaml b/third_party/contour-latest/net-contour.yaml
index 4b1a58b868c9..1e567706f74e 100644
--- a/third_party/contour-latest/net-contour.yaml
+++ b/third_party/contour-latest/net-contour.yaml
@@ -8,7 +8,7 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-93dc2a37"
+ app.kubernetes.io/version: "20220117-de98775a"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["projectcontour.io"]
@@ -38,8 +38,8 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-93dc2a37"
- serving.knative.dev/release: "v20220112-93dc2a37"
+ app.kubernetes.io/version: "20220117-de98775a"
+ serving.knative.dev/release: "v20220117-de98775a"
data:
_example: |
################################
@@ -105,14 +105,14 @@ spec:
app: net-contour-controller
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-93dc2a37"
+ app.kubernetes.io/version: "20220117-de98775a"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:c675affd0641cfd6a92842c8f658287779064ac97edc471312012dbba6239b9f
+ image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:5f446852a99dd5ea82399e21804c1fd7e9513be211571832c5465660c1526b73
resources:
requests:
cpu: 40m
From d44ad85d738150f318894ce17cb017c9c0182750 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Mon, 17 Jan 2022 18:06:33 -0800
Subject: [PATCH 089/733] Update community files (#12518)
Signed-off-by: Knative Automation
---
OWNERS_ALIASES | 2 ++
1 file changed, 2 insertions(+)
diff --git a/OWNERS_ALIASES b/OWNERS_ALIASES
index 9416fb4b7411..4a3752e39e4e 100644
--- a/OWNERS_ALIASES
+++ b/OWNERS_ALIASES
@@ -7,6 +7,7 @@ aliases:
autoscaling-reviewers:
- nader-ziada
- psschwei
+ - skonto
- taragu
autoscaling-wg-leads:
- julz
@@ -175,6 +176,7 @@ aliases:
- nader-ziada
- nealhu
- psschwei
+ - skonto
- whaught
serving-writers:
- dprotaso
From b74e3c775750c0c67bdd75fd78638a221939a3fb Mon Sep 17 00:00:00 2001
From: Dave Protasowski
Date: Tue, 18 Jan 2022 09:59:33 -0500
Subject: [PATCH 090/733] bump ggcr/k8schain to the latest (#12510)
* bump ggcr/k8schain to the latest
This version of k8s chain uses the newer cloud providers
* bump ggcr again
* bump k8schain
* fix linter - drop use of deprecated grpc function
---
go.mod | 13 +-
go.sum | 277 +-
test/e2e/grpc_test.go | 7 +-
.../autorest/{to => azure/auth}/LICENSE | 0
.../{validation => azure/cli}/LICENSE | 0
.../{aws-sdk-go => aws-sdk-go-v2}/LICENSE.txt | 0
.../{aws-sdk-go => aws-sdk-go-v2}/NOTICE.txt | 2 +-
.../aws/aws-sdk-go-v2/config}/LICENSE.txt | 0
.../aws-sdk-go-v2/credentials/LICENSE.txt} | 0
.../feature/ec2/imds/LICENSE.txt | 0
.../internal/configsources/LICENSE.txt | 5 +-
.../internal/endpoints/v2/LICENSE.txt | 5 +-
.../aws-sdk-go-v2/internal/ini/LICENSE.txt | 202 +
.../internal/sync/singleflight/LICENSE | 0
.../aws/aws-sdk-go-v2/service/ecr/LICENSE.txt | 202 +
.../service/ecrpublic/LICENSE.txt | 202 +
.../internal/presigned-url/LICENSE.txt | 202 +
.../aws/aws-sdk-go-v2/service/sso/LICENSE.txt | 202 +
.../aws/aws-sdk-go-v2/service/sts/LICENSE.txt | 202 +
.../github.com/aws/smithy-go/LICENSE | 175 +
.../github.com/aws/smithy-go/NOTICE | 1 +
.../ecr-login/LICENSE | 51 +
.../docker-credential-acr-env/pkg}/LICENSE | 5 +-
.../dimchansky/utfbom}/LICENSE | 0
.../pkg/authn/kubernetes/LICENSE | 202 +
.../2019-05-01/containerregistry/models.go | 5139 ------
.../containerregistry/operations.go | 147 -
.../containerregistry/registries.go | 1243 --
.../containerregistry/replications.go | 540 -
.../mgmt/2019-05-01/containerregistry/runs.go | 530 -
.../2019-05-01/containerregistry/tasks.go | 645 -
.../2019-05-01/containerregistry/webhooks.go | 860 -
.../containerregistry/accesstokens.go | 187 +
.../containerregistry/blob.go | 842 +
.../containerregistry/client.go | 26 +-
.../containerregistry/manifests.go | 496 +
.../containerregistry/models.go | 639 +
.../containerregistry/refreshtokens.go | 121 +
.../containerregistry/repository.go | 328 +
.../containerregistry/tag.go | 346 +
.../containerregistry/v2support.go | 99 +
.../containerregistry/version.go | 2 +-
.../Azure/azure-sdk-for-go/version/version.go | 2 +-
.../autorest/{to => azure/auth}/LICENSE | 0
.../go-autorest/autorest/azure/auth/auth.go | 730 +
.../go-autorest/autorest/azure/auth/go.mod | 11 +
.../go-autorest/autorest/azure/auth/go.sum | 29 +
.../{to => azure/auth}/go_mod_tidy_hack.go | 6 +-
.../{validation => azure/cli}/LICENSE | 0
.../go-autorest/autorest/azure/cli/go.mod | 11 +
.../go-autorest/autorest/azure/cli/go.sum | 24 +
.../autorest/azure/cli/go_mod_tidy_hack.go | 24 +
.../go-autorest/autorest/azure/cli/profile.go | 83 +
.../go-autorest/autorest/azure/cli/token.go | 175 +
.../Azure/go-autorest/autorest/to/convert.go | 152 -
.../Azure/go-autorest/autorest/to/go.mod | 5 -
.../Azure/go-autorest/autorest/to/go.sum | 17 -
.../go-autorest/autorest/validation/error.go | 48 -
.../go-autorest/autorest/validation/go.mod | 5 -
.../go-autorest/autorest/validation/go.sum | 7 -
.../autorest/validation/validation.go | 400 -
.../github.com/aws/aws-sdk-go-v2/.gitignore | 11 +
.../aws/aws-sdk-go-v2/.golangci.toml | 27 +
.../github.com/aws/aws-sdk-go-v2/.travis.yml | 31 +
.../github.com/aws/aws-sdk-go-v2/CHANGELOG.md | 2961 ++++
.../aws/aws-sdk-go-v2/CODE_OF_CONDUCT.md | 4 +
.../aws/aws-sdk-go-v2/CONTRIBUTING.md | 178 +
vendor/github.com/aws/aws-sdk-go-v2/DESIGN.md | 15 +
.../github.com/aws/aws-sdk-go-v2/LICENSE.txt | 202 +
vendor/github.com/aws/aws-sdk-go-v2/Makefile | 491 +
.../{aws-sdk-go => aws-sdk-go-v2}/NOTICE.txt | 2 +-
vendor/github.com/aws/aws-sdk-go-v2/README.md | 155 +
.../aws/aws-sdk-go-v2/aws/config.go | 132 +
.../aws/aws-sdk-go-v2/aws/context.go | 22 +
.../aws/aws-sdk-go-v2/aws/credential_cache.go | 139 +
.../aws/aws-sdk-go-v2/aws/credentials.go | 127 +
.../{aws-sdk-go => aws-sdk-go-v2}/aws/doc.go | 10 +-
.../aws/aws-sdk-go-v2/aws/endpoints.go | 229 +
.../aws/aws-sdk-go-v2/aws/errors.go | 9 +
.../aws/aws-sdk-go-v2/aws/from_ptr.go | 344 +
.../aws-sdk-go-v2/aws/go_module_metadata.go | 6 +
.../aws/aws-sdk-go-v2/aws/logging.go | 117 +
.../aws/aws-sdk-go-v2/aws/logging_generate.go | 95 +
.../aws-sdk-go-v2/aws/middleware/metadata.go | 180 +
.../aws/middleware/middleware.go | 168 +
.../aws-sdk-go-v2/aws/middleware/osname.go | 24 +
.../aws/middleware/osname_go115.go | 24 +
.../aws/middleware/request_id.go | 27 +
.../aws/middleware/request_id_retriever.go | 49 +
.../aws/middleware/user_agent.go | 241 +
.../aws-sdk-go-v2/aws/protocol/query/array.go | 61 +
.../aws/protocol/query/encoder.go | 80 +
.../aws-sdk-go-v2/aws/protocol/query/map.go | 78 +
.../aws/protocol/query/middleware.go | 62 +
.../aws/protocol/query/object.go | 56 +
.../aws-sdk-go-v2/aws/protocol/query/value.go | 106 +
.../aws/protocol/restjson/decoder_util.go | 85 +
.../aws/protocol/xml/error_utils.go | 56 +
.../aws/ratelimit/token_bucket.go | 51 +
.../aws/ratelimit/token_rate_limit.go | 82 +
.../aws/aws-sdk-go-v2/aws/request.go | 25 +
.../aws/aws-sdk-go-v2/aws/retry/doc.go | 80 +
.../aws/aws-sdk-go-v2/aws/retry/errors.go | 20 +
.../aws-sdk-go-v2/aws/retry/jitter_backoff.go | 49 +
.../aws/aws-sdk-go-v2/aws/retry/metadata.go | 52 +
.../aws/aws-sdk-go-v2/aws/retry/middleware.go | 277 +
.../aws/aws-sdk-go-v2/aws/retry/retry.go | 72 +
.../aws/retry/retryable_error.go | 186 +
.../aws/aws-sdk-go-v2/aws/retry/standard.go | 208 +
.../aws-sdk-go-v2/aws/retry/timeout_error.go | 52 +
.../aws/aws-sdk-go-v2/aws/retryer.go | 62 +
.../aws/signer/internal/v4/cache.go | 115 +
.../aws/signer/internal/v4/const.go | 40 +
.../aws/signer/internal/v4/header_rules.go | 82 +
.../aws/signer/internal/v4/headers.go | 68 +
.../aws/signer/internal/v4/hmac.go | 13 +
.../aws/signer/internal/v4/host.go | 75 +
.../aws/signer/internal/v4/scope.go | 13 +
.../aws/signer/internal/v4/time.go | 36 +
.../aws/signer/internal/v4/util.go | 64 +
.../aws-sdk-go-v2/aws/signer/v4/middleware.go | 400 +
.../aws/signer/v4/presign_middleware.go | 127 +
.../aws/aws-sdk-go-v2/aws/signer/v4/stream.go | 86 +
.../aws/aws-sdk-go-v2/aws/signer/v4/v4.go | 534 +
.../aws/aws-sdk-go-v2/aws/to_ptr.go | 280 +
.../aws/transport/http/client.go | 301 +
.../aws/transport/http/content_type.go | 42 +
.../aws/transport/http/response_error.go | 33 +
.../http/response_error_middleware.go | 54 +
.../aws/transport/http/timeout_read_closer.go | 104 +
.../github.com/aws/aws-sdk-go-v2/aws/types.go | 42 +
.../aws/version.go | 4 +-
.../aws/aws-sdk-go-v2/buildspec.yml | 12 +
.../aws/aws-sdk-go-v2/config/CHANGELOG.md | 96 +
.../aws/aws-sdk-go-v2/config/LICENSE.txt | 202 +
.../aws/aws-sdk-go-v2/config/config.go | 192 +
.../aws/aws-sdk-go-v2/config/doc.go | 20 +
.../aws/aws-sdk-go-v2/config/env_config.go | 567 +
.../aws/aws-sdk-go-v2/config/generate.go | 4 +
.../aws/aws-sdk-go-v2/config/go.mod | 32 +
.../aws/aws-sdk-go-v2/config/go.sum | 14 +
.../config/go_module_metadata.go | 6 +
.../aws/aws-sdk-go-v2/config/load_options.go | 808 +
.../aws/aws-sdk-go-v2/config/local.go | 51 +
.../aws/aws-sdk-go-v2/config/provider.go | 468 +
.../aws/aws-sdk-go-v2/config/resolve.go | 243 +
.../config/resolve_credentials.go | 472 +
.../aws/aws-sdk-go-v2/config/shared_config.go | 1310 ++
.../aws-sdk-go-v2/credentials/CHANGELOG.md | 83 +
.../aws/aws-sdk-go-v2/credentials/LICENSE.txt | 202 +
.../aws/aws-sdk-go-v2/credentials/doc.go | 4 +
.../credentials/ec2rolecreds/doc.go | 58 +
.../credentials/ec2rolecreds/provider.go | 174 +
.../endpointcreds/internal/client/client.go | 148 +
.../internal/client/middleware.go | 120 +
.../credentials/endpointcreds/provider.go | 133 +
.../aws/aws-sdk-go-v2/credentials/go.mod | 26 +
.../aws/aws-sdk-go-v2/credentials/go.sum | 14 +
.../credentials/go_module_metadata.go | 6 +
.../credentials/processcreds/doc.go | 92 +
.../credentials/processcreds/provider.go | 269 +
.../aws-sdk-go-v2/credentials/ssocreds/doc.go | 63 +
.../aws-sdk-go-v2/credentials/ssocreds/os.go | 10 +
.../credentials/ssocreds/os_windows.go | 7 +
.../credentials/ssocreds/provider.go | 184 +
.../credentials/static_provider.go | 53 +
.../stscreds/assume_role_provider.go | 302 +
.../stscreds/web_identity_provider.go | 127 +
vendor/github.com/aws/aws-sdk-go-v2/doc.go | 58 +
.../feature/ec2/imds/CHANGELOG.md | 68 +
.../feature/ec2/imds/LICENSE.txt | 202 +
.../feature/ec2/imds/api_client.go | 318 +
.../feature/ec2/imds/api_op_GetDynamicData.go | 76 +
.../feature/ec2/imds/api_op_GetIAMInfo.go | 102 +
.../api_op_GetInstanceIdentityDocument.go | 109 +
.../feature/ec2/imds/api_op_GetMetadata.go | 76 +
.../feature/ec2/imds/api_op_GetRegion.go | 72 +
.../feature/ec2/imds/api_op_GetToken.go | 118 +
.../feature/ec2/imds/api_op_GetUserData.go | 60 +
.../aws/aws-sdk-go-v2/feature/ec2/imds/doc.go | 11 +
.../aws/aws-sdk-go-v2/feature/ec2/imds/go.mod | 11 +
.../aws/aws-sdk-go-v2/feature/ec2/imds/go.sum | 14 +
.../feature/ec2/imds/go_module_metadata.go | 6 +
.../ec2/imds/internal/config/resolvers.go | 98 +
.../feature/ec2/imds/request_middleware.go | 266 +
.../feature/ec2/imds/token_provider.go | 237 +
vendor/github.com/aws/aws-sdk-go-v2/go.mod | 9 +
vendor/github.com/aws/aws-sdk-go-v2/go.sum | 20 +
.../internal/configsources/CHANGELOG.md | 50 +
.../internal/configsources/LICENSE.txt | 202 +
.../internal/configsources/config.go | 65 +
.../internal/configsources/go.mod | 7 +
.../internal/configsources/go.sum | 14 +
.../configsources/go_module_metadata.go | 6 +
.../internal/endpoints/v2/CHANGELOG.md | 20 +
.../internal/endpoints/v2/LICENSE.txt | 202 +
.../internal/endpoints/v2/endpoints.go | 302 +
.../internal/endpoints/v2/go.mod | 11 +
.../internal/endpoints/v2/go.sum | 14 +
.../endpoints/v2/go_module_metadata.go | 6 +
.../aws-sdk-go-v2/internal/ini/CHANGELOG.md | 59 +
.../aws-sdk-go-v2/internal/ini/LICENSE.txt | 202 +
.../internal/ini/ast.go | 0
.../internal/ini/comma_token.go | 0
.../internal/ini/comment_token.go | 0
.../aws-sdk-go-v2/internal/ini/dependency.go | 6 +
.../aws/aws-sdk-go-v2/internal/ini/doc.go | 42 +
.../internal/ini/empty_token.go | 0
.../aws/aws-sdk-go-v2/internal/ini/errors.go | 22 +
.../internal/ini/expression.go | 0
.../internal/ini/fuzz.go | 1 +
.../aws/aws-sdk-go-v2/internal/ini/go.mod | 7 +
.../aws/aws-sdk-go-v2/internal/ini/go.sum | 11 +
.../internal/ini/go_module_metadata.go | 6 +
.../internal/ini/ini.go | 29 +-
.../internal/ini/ini_lexer.go | 10 +-
.../internal/ini/ini_parser.go | 54 +-
.../internal/ini/literal_tokens.go | 30 +-
.../internal/ini/newline_token.go | 0
.../internal/ini/number_helper.go | 0
.../internal/ini/op_tokens.go | 0
.../aws-sdk-go-v2/internal/ini/parse_error.go | 19 +
.../internal/ini/parse_stack.go | 0
.../internal/ini/sep_tokens.go | 0
.../internal/ini/skipper.go | 2 +-
.../internal/ini/statement.go | 2 +-
.../internal/ini/value_util.go | 2 +-
.../internal/ini/visitor.go | 119 +-
.../internal/ini/walker.go | 0
.../internal/ini/ws_token.go | 0
.../aws/aws-sdk-go-v2/internal/rand/rand.go | 33 +
.../aws-sdk-go-v2/internal/sdk/interfaces.go | 9 +
.../aws/aws-sdk-go-v2/internal/sdk/time.go | 74 +
.../internal/sdkio/byte.go | 0
.../internal/strings/strings.go | 0
.../internal/sync/singleflight/LICENSE | 0
.../sync/singleflight/singleflight.go | 0
.../internal/timeconv/duration.go | 13 +
.../aws/aws-sdk-go-v2/local-mod-replace.sh | 39 +
.../github.com/aws/aws-sdk-go-v2/modman.toml | 65 +
.../aws-sdk-go-v2/service/ecr/CHANGELOG.md | 87 +
.../aws/aws-sdk-go-v2/service/ecr/LICENSE.txt | 202 +
.../aws-sdk-go-v2/service/ecr/api_client.go | 297 +
.../ecr/api_op_BatchCheckLayerAvailability.go | 140 +
.../service/ecr/api_op_BatchDeleteImage.go | 141 +
.../service/ecr/api_op_BatchGetImage.go | 143 +
...BatchGetRepositoryScanningConfiguration.go | 124 +
.../service/ecr/api_op_CompleteLayerUpload.go | 151 +
.../ecr/api_op_CreatePullThroughCacheRule.go | 144 +
.../service/ecr/api_op_CreateRepository.go | 150 +
.../ecr/api_op_DeleteLifecyclePolicy.go | 135 +
.../ecr/api_op_DeletePullThroughCacheRule.go | 136 +
.../ecr/api_op_DeleteRegistryPolicy.go | 114 +
.../service/ecr/api_op_DeleteRepository.go | 130 +
.../ecr/api_op_DeleteRepositoryPolicy.go | 132 +
.../api_op_DescribeImageReplicationStatus.go | 136 +
.../ecr/api_op_DescribeImageScanFindings.go | 447 +
.../service/ecr/api_op_DescribeImages.go | 257 +
.../api_op_DescribePullThroughCacheRules.go | 249 +
.../service/ecr/api_op_DescribeRegistry.go | 117 +
.../ecr/api_op_DescribeRepositories.go | 247 +
.../ecr/api_op_GetAuthorizationToken.go | 132 +
.../ecr/api_op_GetDownloadUrlForLayer.go | 138 +
.../service/ecr/api_op_GetLifecyclePolicy.go | 135 +
.../ecr/api_op_GetLifecyclePolicyPreview.go | 463 +
.../service/ecr/api_op_GetRegistryPolicy.go | 114 +
...api_op_GetRegistryScanningConfiguration.go | 115 +
.../service/ecr/api_op_GetRepositoryPolicy.go | 131 +
.../service/ecr/api_op_InitiateLayerUpload.go | 135 +
.../service/ecr/api_op_ListImages.go | 253 +
.../service/ecr/api_op_ListTagsForResource.go | 122 +
.../service/ecr/api_op_PutImage.go | 149 +
.../api_op_PutImageScanningConfiguration.go | 140 +
.../ecr/api_op_PutImageTagMutability.go | 142 +
.../service/ecr/api_op_PutLifecyclePolicy.go | 138 +
.../service/ecr/api_op_PutRegistryPolicy.go | 131 +
...api_op_PutRegistryScanningConfiguration.go | 128 +
.../ecr/api_op_PutReplicationConfiguration.go | 131 +
.../service/ecr/api_op_SetRepositoryPolicy.go | 148 +
.../service/ecr/api_op_StartImageScan.go | 144 +
.../ecr/api_op_StartLifecyclePolicyPreview.go | 141 +
.../service/ecr/api_op_TagResource.go | 126 +
.../service/ecr/api_op_UntagResource.go | 122 +
.../service/ecr/api_op_UploadLayerPart.go | 160 +
.../service/ecr/deserializers.go | 13496 ++++++++++++++++
.../aws/aws-sdk-go-v2/service/ecr/doc.go | 16 +
.../aws-sdk-go-v2/service/ecr/endpoints.go | 200 +
.../aws-sdk-go-v2/service/ecr/generated.json | 68 +
.../aws/aws-sdk-go-v2/service/ecr/go.mod | 17 +
.../aws/aws-sdk-go-v2/service/ecr/go.sum | 20 +
.../service/ecr/go_module_metadata.go | 6 +
.../ecr/internal/endpoints/endpoints.go | 762 +
.../aws-sdk-go-v2/service/ecr/serializers.go | 3570 ++++
.../aws-sdk-go-v2/service/ecr/types/enums.go | 324 +
.../aws-sdk-go-v2/service/ecr/types/errors.go | 697 +
.../aws-sdk-go-v2/service/ecr/types/types.go | 867 +
.../aws-sdk-go-v2/service/ecr/validators.go | 1630 ++
.../service/ecrpublic/CHANGELOG.md | 75 +
.../service/ecrpublic/LICENSE.txt | 202 +
.../service/ecrpublic/api_client.go | 297 +
.../api_op_BatchCheckLayerAvailability.go | 140 +
.../ecrpublic/api_op_BatchDeleteImage.go | 140 +
.../ecrpublic/api_op_CompleteLayerUpload.go | 151 +
.../ecrpublic/api_op_CreateRepository.go | 141 +
.../ecrpublic/api_op_DeleteRepository.go | 131 +
.../api_op_DeleteRepositoryPolicy.go | 132 +
.../ecrpublic/api_op_DescribeImageTags.go | 247 +
.../ecrpublic/api_op_DescribeImages.go | 254 +
.../ecrpublic/api_op_DescribeRegistries.go | 237 +
.../ecrpublic/api_op_DescribeRepositories.go | 247 +
.../ecrpublic/api_op_GetAuthorizationToken.go | 116 +
.../api_op_GetRegistryCatalogData.go | 114 +
.../api_op_GetRepositoryCatalogData.go | 127 +
.../ecrpublic/api_op_GetRepositoryPolicy.go | 132 +
.../ecrpublic/api_op_InitiateLayerUpload.go | 135 +
.../ecrpublic/api_op_ListTagsForResource.go | 122 +
.../service/ecrpublic/api_op_PutImage.go | 149 +
.../api_op_PutRegistryCatalogData.go | 120 +
.../api_op_PutRepositoryCatalogData.go | 131 +
.../ecrpublic/api_op_SetRepositoryPolicy.go | 147 +
.../service/ecrpublic/api_op_TagResource.go | 128 +
.../service/ecrpublic/api_op_UntagResource.go | 122 +
.../ecrpublic/api_op_UploadLayerPart.go | 159 +
.../service/ecrpublic/deserializers.go | 7053 ++++++++
.../aws-sdk-go-v2/service/ecrpublic/doc.go | 15 +
.../service/ecrpublic/endpoints.go | 200 +
.../service/ecrpublic/generated.json | 49 +
.../aws-sdk-go-v2/service/ecrpublic/go.mod | 16 +
.../aws-sdk-go-v2/service/ecrpublic/go.sum | 14 +
.../service/ecrpublic/go_module_metadata.go | 6 +
.../ecrpublic/internal/endpoints/endpoints.go | 250 +
.../service/ecrpublic/serializers.go | 1948 +++
.../service/ecrpublic/types/enums.go | 87 +
.../service/ecrpublic/types/errors.go | 476 +
.../service/ecrpublic/types/types.go | 405 +
.../service/ecrpublic/validators.go | 751 +
.../internal/presigned-url/CHANGELOG.md | 64 +
.../internal/presigned-url/LICENSE.txt | 202 +
.../service/internal/presigned-url/context.go | 48 +
.../service/internal/presigned-url/doc.go | 3 +
.../service/internal/presigned-url/go.mod | 11 +
.../service/internal/presigned-url/go.sum | 14 +
.../presigned-url/go_module_metadata.go | 6 +
.../internal/presigned-url/middleware.go | 110 +
.../aws-sdk-go-v2/service/sso/CHANGELOG.md | 71 +
.../aws/aws-sdk-go-v2/service/sso/LICENSE.txt | 202 +
.../aws-sdk-go-v2/service/sso/api_client.go | 296 +
.../service/sso/api_op_GetRoleCredentials.go | 127 +
.../service/sso/api_op_ListAccountRoles.go | 223 +
.../service/sso/api_op_ListAccounts.go | 220 +
.../service/sso/api_op_Logout.go | 111 +
.../service/sso/deserializers.go | 1151 ++
.../aws/aws-sdk-go-v2/service/sso/doc.go | 20 +
.../aws-sdk-go-v2/service/sso/endpoints.go | 200 +
.../aws-sdk-go-v2/service/sso/generated.json | 29 +
.../aws/aws-sdk-go-v2/service/sso/go.mod | 16 +
.../aws/aws-sdk-go-v2/service/sso/go.sum | 14 +
.../service/sso/go_module_metadata.go | 6 +
.../sso/internal/endpoints/endpoints.go | 382 +
.../aws-sdk-go-v2/service/sso/serializers.go | 256 +
.../aws-sdk-go-v2/service/sso/types/errors.go | 87 +
.../aws-sdk-go-v2/service/sso/types/types.go | 64 +
.../aws-sdk-go-v2/service/sso/validators.go | 175 +
.../aws-sdk-go-v2/service/sts/CHANGELOG.md | 82 +
.../aws/aws-sdk-go-v2/service/sts/LICENSE.txt | 202 +
.../aws-sdk-go-v2/service/sts/api_client.go | 397 +
.../service/sts/api_op_AssumeRole.go | 417 +
.../service/sts/api_op_AssumeRoleWithSAML.go | 377 +
.../sts/api_op_AssumeRoleWithWebIdentity.go | 393 +
.../sts/api_op_DecodeAuthorizationMessage.go | 155 +
.../service/sts/api_op_GetAccessKeyInfo.go | 141 +
.../service/sts/api_op_GetCallerIdentity.go | 156 +
.../service/sts/api_op_GetFederationToken.go | 324 +
.../service/sts/api_op_GetSessionToken.go | 196 +
.../service/sts/deserializers.go | 2507 +++
.../aws/aws-sdk-go-v2/service/sts/doc.go | 12 +
.../aws-sdk-go-v2/service/sts/endpoints.go | 200 +
.../aws-sdk-go-v2/service/sts/generated.json | 34 +
.../aws/aws-sdk-go-v2/service/sts/go.mod | 19 +
.../aws/aws-sdk-go-v2/service/sts/go.sum | 14 +
.../service/sts/go_module_metadata.go | 6 +
.../sts/internal/endpoints/endpoints.go | 445 +
.../aws-sdk-go-v2/service/sts/serializers.go | 835 +
.../aws-sdk-go-v2/service/sts/types/errors.go | 193 +
.../aws-sdk-go-v2/service/sts/types/types.go | 124 +
.../aws-sdk-go-v2/service/sts/validators.go | 305 +
.../aws/aws-sdk-go/aws/awserr/error.go | 164 -
.../aws/aws-sdk-go/aws/awserr/types.go | 221 -
.../aws/aws-sdk-go/aws/awsutil/copy.go | 108 -
.../aws/aws-sdk-go/aws/awsutil/equal.go | 27 -
.../aws/aws-sdk-go/aws/awsutil/path_value.go | 221 -
.../aws/aws-sdk-go/aws/awsutil/prettify.go | 113 -
.../aws-sdk-go/aws/awsutil/string_value.go | 88 -
.../aws/aws-sdk-go/aws/client/client.go | 97 -
.../aws-sdk-go/aws/client/default_retryer.go | 177 -
.../aws/aws-sdk-go/aws/client/logger.go | 194 -
.../aws/client/metadata/client_info.go | 14 -
.../aws-sdk-go/aws/client/no_op_retryer.go | 28 -
.../github.com/aws/aws-sdk-go/aws/config.go | 587 -
.../aws/aws-sdk-go/aws/context_1_5.go | 37 -
.../aws/aws-sdk-go/aws/context_1_9.go | 11 -
.../aws-sdk-go/aws/context_background_1_5.go | 22 -
.../aws-sdk-go/aws/context_background_1_7.go | 20 -
.../aws/aws-sdk-go/aws/context_sleep.go | 24 -
.../aws/aws-sdk-go/aws/convert_types.go | 918 --
.../aws-sdk-go/aws/corehandlers/handlers.go | 232 -
.../aws/corehandlers/param_validator.go | 17 -
.../aws-sdk-go/aws/corehandlers/user_agent.go | 37 -
.../aws/credentials/chain_provider.go | 100 -
.../credentials/context_background_go1.5.go | 22 -
.../credentials/context_background_go1.7.go | 20 -
.../aws/credentials/context_go1.5.go | 39 -
.../aws/credentials/context_go1.9.go | 13 -
.../aws-sdk-go/aws/credentials/credentials.go | 383 -
.../ec2rolecreds/ec2_role_provider.go | 188 -
.../aws/credentials/endpointcreds/provider.go | 210 -
.../aws/credentials/env_provider.go | 74 -
.../aws-sdk-go/aws/credentials/example.ini | 12 -
.../aws/credentials/processcreds/provider.go | 426 -
.../shared_credentials_provider.go | 151 -
.../aws/credentials/static_provider.go | 57 -
.../stscreds/assume_role_provider.go | 363 -
.../stscreds/web_identity_provider.go | 154 -
.../github.com/aws/aws-sdk-go/aws/csm/doc.go | 69 -
.../aws/aws-sdk-go/aws/csm/enable.go | 89 -
.../aws/aws-sdk-go/aws/csm/metric.go | 109 -
.../aws/aws-sdk-go/aws/csm/metric_chan.go | 55 -
.../aws-sdk-go/aws/csm/metric_exception.go | 26 -
.../aws/aws-sdk-go/aws/csm/reporter.go | 264 -
.../aws/aws-sdk-go/aws/defaults/defaults.go | 207 -
.../aws-sdk-go/aws/defaults/shared_config.go | 27 -
.../aws/aws-sdk-go/aws/ec2metadata/api.go | 250 -
.../aws/aws-sdk-go/aws/ec2metadata/service.go | 245 -
.../aws/ec2metadata/token_provider.go | 93 -
.../aws/aws-sdk-go/aws/endpoints/decode.go | 216 -
.../aws/aws-sdk-go/aws/endpoints/defaults.go | 9912 ------------
.../aws/endpoints/dep_service_ids.go | 141 -
.../aws/aws-sdk-go/aws/endpoints/doc.go | 66 -
.../aws/aws-sdk-go/aws/endpoints/endpoints.go | 564 -
.../aws/endpoints/legacy_regions.go | 24 -
.../aws/aws-sdk-go/aws/endpoints/v3model.go | 351 -
.../aws/endpoints/v3model_codegen.go | 351 -
.../github.com/aws/aws-sdk-go/aws/errors.go | 13 -
.../aws/aws-sdk-go/aws/jsonvalue.go | 12 -
.../github.com/aws/aws-sdk-go/aws/logger.go | 118 -
.../aws/request/connection_reset_error.go | 19 -
.../aws/aws-sdk-go/aws/request/handlers.go | 343 -
.../aws-sdk-go/aws/request/http_request.go | 24 -
.../aws-sdk-go/aws/request/offset_reader.go | 65 -
.../aws/aws-sdk-go/aws/request/request.go | 698 -
.../aws/aws-sdk-go/aws/request/request_1_7.go | 39 -
.../aws/aws-sdk-go/aws/request/request_1_8.go | 36 -
.../aws-sdk-go/aws/request/request_context.go | 14 -
.../aws/request/request_context_1_6.go | 14 -
.../aws/request/request_pagination.go | 266 -
.../aws/aws-sdk-go/aws/request/retryer.go | 309 -
.../aws/request/timeout_read_closer.go | 94 -
.../aws/aws-sdk-go/aws/request/validation.go | 286 -
.../aws/aws-sdk-go/aws/request/waiter.go | 295 -
.../aws/session/cabundle_transport.go | 26 -
.../aws/session/cabundle_transport_1_5.go | 22 -
.../aws/session/cabundle_transport_1_6.go | 23 -
.../aws/aws-sdk-go/aws/session/credentials.go | 267 -
.../aws/aws-sdk-go/aws/session/doc.go | 262 -
.../aws/aws-sdk-go/aws/session/env_config.go | 355 -
.../aws/aws-sdk-go/aws/session/session.go | 791 -
.../aws-sdk-go/aws/session/shared_config.go | 555 -
.../aws-sdk-go/aws/signer/v4/header_rules.go | 81 -
.../aws/aws-sdk-go/aws/signer/v4/options.go | 7 -
.../aws/signer/v4/request_context_go1.5.go | 13 -
.../aws/signer/v4/request_context_go1.7.go | 13 -
.../aws/aws-sdk-go/aws/signer/v4/stream.go | 63 -
.../aws/aws-sdk-go/aws/signer/v4/uri_path.go | 24 -
.../aws/aws-sdk-go/aws/signer/v4/v4.go | 846 -
vendor/github.com/aws/aws-sdk-go/aws/types.go | 264 -
vendor/github.com/aws/aws-sdk-go/aws/url.go | 12 -
.../github.com/aws/aws-sdk-go/aws/url_1_7.go | 29 -
.../internal/context/background_go1.5.go | 40 -
.../aws/aws-sdk-go/internal/ini/doc.go | 29 -
.../aws-sdk-go/internal/ini/parse_error.go | 43 -
.../aws/aws-sdk-go/internal/sdkio/io_go1.6.go | 10 -
.../aws/aws-sdk-go/internal/sdkio/io_go1.7.go | 12 -
.../aws/aws-sdk-go/internal/sdkmath/floor.go | 15 -
.../internal/sdkmath/floor_go1.9.go | 56 -
.../internal/sdkrand/locked_source.go | 29 -
.../aws/aws-sdk-go/internal/sdkrand/read.go | 11 -
.../aws-sdk-go/internal/sdkrand/read_1_5.go | 24 -
.../aws/aws-sdk-go/internal/sdkuri/path.go | 23 -
.../internal/shareddefaults/ecs_container.go | 12 -
.../internal/shareddefaults/shared_config.go | 40 -
.../aws/aws-sdk-go/private/protocol/host.go | 68 -
.../private/protocol/host_prefix.go | 54 -
.../private/protocol/idempotency.go | 75 -
.../private/protocol/json/jsonutil/build.go | 296 -
.../protocol/json/jsonutil/unmarshal.go | 304 -
.../private/protocol/jsonrpc/jsonrpc.go | 88 -
.../protocol/jsonrpc/unmarshal_error.go | 107 -
.../aws-sdk-go/private/protocol/jsonvalue.go | 76 -
.../aws-sdk-go/private/protocol/payload.go | 81 -
.../aws-sdk-go/private/protocol/protocol.go | 49 -
.../private/protocol/query/build.go | 36 -
.../protocol/query/queryutil/queryutil.go | 246 -
.../private/protocol/query/unmarshal.go | 39 -
.../private/protocol/query/unmarshal_error.go | 69 -
.../aws-sdk-go/private/protocol/rest/build.go | 310 -
.../private/protocol/rest/payload.go | 45 -
.../private/protocol/rest/unmarshal.go | 257 -
.../aws-sdk-go/private/protocol/timestamp.go | 85 -
.../aws-sdk-go/private/protocol/unmarshal.go | 27 -
.../private/protocol/unmarshal_error.go | 65 -
.../private/protocol/xml/xmlutil/build.go | 315 -
.../private/protocol/xml/xmlutil/sort.go | 32 -
.../private/protocol/xml/xmlutil/unmarshal.go | 299 -
.../protocol/xml/xmlutil/xml_to_struct.go | 159 -
.../aws/aws-sdk-go/service/ecr/api.go | 9194 -----------
.../aws/aws-sdk-go/service/ecr/doc.go | 34 -
.../aws/aws-sdk-go/service/ecr/errors.go | 228 -
.../aws/aws-sdk-go/service/ecr/service.go | 106 -
.../aws/aws-sdk-go/service/ecr/waiters.go | 112 -
.../aws/aws-sdk-go/service/sts/api.go | 3119 ----
.../aws-sdk-go/service/sts/customizations.go | 11 -
.../aws/aws-sdk-go/service/sts/doc.go | 32 -
.../aws/aws-sdk-go/service/sts/errors.go | 82 -
.../aws/aws-sdk-go/service/sts/service.go | 98 -
.../service/sts/stsiface/interface.go | 96 -
vendor/github.com/aws/smithy-go/.gitignore | 22 +
vendor/github.com/aws/smithy-go/.travis.yml | 28 +
vendor/github.com/aws/smithy-go/CHANGELOG.md | 99 +
.../aws/smithy-go/CODE_OF_CONDUCT.md | 4 +
.../github.com/aws/smithy-go/CONTRIBUTING.md | 59 +
vendor/github.com/aws/smithy-go/LICENSE | 175 +
vendor/github.com/aws/smithy-go/Makefile | 63 +
vendor/github.com/aws/smithy-go/NOTICE | 1 +
vendor/github.com/aws/smithy-go/README.md | 12 +
vendor/github.com/aws/smithy-go/doc.go | 2 +
vendor/github.com/aws/smithy-go/document.go | 10 +
.../github.com/aws/smithy-go/document/doc.go | 12 +
.../aws/smithy-go/document/document.go | 153 +
.../aws/smithy-go/document/errors.go | 75 +
.../github.com/aws/smithy-go/encoding/doc.go | 4 +
.../aws/smithy-go/encoding/encoding.go | 40 +
.../smithy-go/encoding/httpbinding/encode.go | 116 +
.../smithy-go/encoding/httpbinding/header.go | 122 +
.../encoding/httpbinding/path_replace.go | 108 +
.../smithy-go/encoding/httpbinding/query.go | 107 +
.../aws/smithy-go/encoding/httpbinding/uri.go | 108 +
.../aws/smithy-go/encoding/json/array.go | 35 +
.../aws/smithy-go/encoding/json/constants.go | 15 +
.../smithy-go/encoding/json/decoder_util.go | 139 +
.../aws/smithy-go/encoding/json/encoder.go | 30 +
.../aws/smithy-go/encoding/json/escape.go | 198 +
.../aws/smithy-go/encoding/json/object.go | 42 +
.../aws/smithy-go/encoding/json/value.go | 149 +
.../aws/smithy-go/encoding/xml/array.go | 49 +
.../aws/smithy-go/encoding/xml/constants.go | 10 +
.../aws/smithy-go/encoding/xml/doc.go | 49 +
.../aws/smithy-go/encoding/xml/element.go | 91 +
.../aws/smithy-go/encoding/xml/encoder.go | 51 +
.../aws/smithy-go/encoding/xml/error_utils.go | 51 +
.../aws/smithy-go/encoding/xml/escape.go | 137 +
.../aws/smithy-go/encoding/xml/map.go | 53 +
.../aws/smithy-go/encoding/xml/value.go | 302 +
.../aws/smithy-go/encoding/xml/xml_decoder.go | 154 +
vendor/github.com/aws/smithy-go/errors.go | 137 +
vendor/github.com/aws/smithy-go/go.mod | 5 +
vendor/github.com/aws/smithy-go/go.sum | 4 +
.../aws/smithy-go/go_module_metadata.go | 6 +
vendor/github.com/aws/smithy-go/io/byte.go | 12 +
vendor/github.com/aws/smithy-go/io/doc.go | 2 +
vendor/github.com/aws/smithy-go/io/reader.go | 16 +
.../github.com/aws/smithy-go/io/ringbuffer.go | 94 +
.../aws/smithy-go/local-mod-replace.sh | 39 +
.../aws/smithy-go/logging/logger.go | 82 +
.../aws/smithy-go/middleware/doc.go | 67 +
.../aws/smithy-go/middleware/logging.go | 46 +
.../aws/smithy-go/middleware/metadata.go | 65 +
.../aws/smithy-go/middleware/middleware.go | 71 +
.../aws/smithy-go/middleware/ordered_group.go | 268 +
.../aws/smithy-go/middleware/stack.go | 209 +
.../aws/smithy-go/middleware/stack_values.go | 100 +
.../aws/smithy-go/middleware/step_build.go | 211 +
.../smithy-go/middleware/step_deserialize.go | 217 +
.../aws/smithy-go/middleware/step_finalize.go | 211 +
.../smithy-go/middleware/step_initialize.go | 211 +
.../smithy-go/middleware/step_serialize.go | 219 +
vendor/github.com/aws/smithy-go/ptr/doc.go | 5 +
.../github.com/aws/smithy-go/ptr/from_ptr.go | 566 +
.../aws/smithy-go/ptr/gen_scalars.go | 82 +
vendor/github.com/aws/smithy-go/ptr/to_ptr.go | 470 +
vendor/github.com/aws/smithy-go/rand/doc.go | 3 +
vendor/github.com/aws/smithy-go/rand/rand.go | 31 +
vendor/github.com/aws/smithy-go/rand/uuid.go | 87 +
vendor/github.com/aws/smithy-go/time/time.go | 134 +
.../transport/http/checksum_middleware.go | 65 +
.../aws/smithy-go/transport/http/client.go | 120 +
.../aws/smithy-go/transport/http/doc.go | 5 +
.../smithy-go/transport/http/headerlist.go | 90 +
.../aws/smithy-go/transport/http/host.go | 89 +
.../transport/http/internal/io/safe.go | 75 +
.../smithy-go/transport/http/md5_checksum.go | 25 +
.../http/middleware_close_response_body.go | 79 +
.../http/middleware_content_length.go | 90 +
.../transport/http/middleware_headers.go | 88 +
.../transport/http/middleware_http_logging.go | 75 +
.../transport/http/middleware_metadata.go | 51 +
.../transport/http/middleware_min_proto.go | 79 +
.../aws/smithy-go/transport/http/request.go | 154 +
.../aws/smithy-go/transport/http/response.go | 34 +
.../aws/smithy-go/transport/http/time.go | 13 +
.../aws/smithy-go/transport/http/url.go | 44 +
.../smithy-go/transport/http/user_agent.go | 37 +
vendor/github.com/aws/smithy-go/validation.go | 140 +
.../github.com/aws/smithy-go/waiter/logger.go | 36 +
.../github.com/aws/smithy-go/waiter/waiter.go | 66 +
.../ecr-login/LICENSE | 51 +
.../ecr-login/api/client.go | 302 +
.../ecr-login/api/factory.go | 107 +
.../ecr-login/cache/build.go | 73 +
.../ecr-login/cache/credentials.go | 49 +
.../ecr-login/cache/file.go | 195 +
.../ecr-login/cache/null.go | 38 +
.../ecr-login/config/cache_dir.go | 23 +
.../ecr-login/config/log.go | 48 +
.../ecr-login/ecr.go | 91 +
.../ecr-login/go.mod | 19 +
.../ecr-login/go.sum | 59 +
.../ecr-login/version/version.go | 7 +
.../github.com/cespare/xxhash/v2/.travis.yml | 8 -
vendor/github.com/cespare/xxhash/v2/README.md | 6 +-
vendor/github.com/cespare/xxhash/v2/xxhash.go | 1 -
.../cespare/xxhash/v2/xxhash_amd64.s | 62 +-
.../cespare/xxhash/v2/xxhash_unsafe.go | 53 +-
.../docker-credential-acr-env}/LICENSE | 5 +-
.../pkg/credhelper/helper.go | 59 +
.../pkg/registry/const.go} | 14 +-
.../pkg/registry/registry.go | 63 +
.../pkg/token/token.go | 72 +
.../github.com/dimchansky/utfbom/.gitignore | 37 +
.../github.com/dimchansky/utfbom/.travis.yml | 18 +
.../github.com/dimchansky/utfbom}/LICENSE | 0
vendor/github.com/dimchansky/utfbom/README.md | 66 +
vendor/github.com/dimchansky/utfbom/go.mod | 1 +
vendor/github.com/dimchansky/utfbom/utfbom.go | 192 +
.../github.com/evanphx/json-patch/.gitignore | 6 +
vendor/github.com/evanphx/json-patch/patch.go | 63 +
.../go-containerregistry/internal/gzip/zip.go | 29 +
.../internal/verify/verify.go | 25 +-
.../go-containerregistry/pkg/authn/README.md | 100 +-
.../pkg/authn/k8schain/go.mod | 21 +-
.../pkg/authn/k8schain/go.sum | 360 +-
.../pkg/authn/k8schain/k8schain.go | 147 +-
.../pkg/authn/k8schain/k8schain_azure.go | 23 -
.../pkg/authn/k8schain/k8schain_gcp.go | 23 -
.../pkg/authn/keychain.go | 24 +
.../pkg/authn/kubernetes/LICENSE | 202 +
.../pkg/authn/kubernetes/go.mod | 46 +
.../pkg/authn/kubernetes/go.sum | 1398 ++
.../pkg/authn/kubernetes/keychain.go | 172 +
.../go-containerregistry/pkg/name/check.go | 4 +-
.../pkg/v1/google/README.md | 7 +
.../pkg/v1/google/auth.go | 180 +
.../k8schain_aws.go => v1/google/doc.go} | 13 +-
.../pkg/v1/google/keychain.go | 81 +
.../pkg/v1/google/list.go | 331 +
.../pkg/v1/google/options.go | 73 +
.../pkg/v1/mutate/image.go | 9 +-
.../pkg/v1/mutate/index.go | 9 +-
.../pkg/v1/partial/compressed.go | 22 +-
.../pkg/v1/remote/transport/error.go | 5 +
.../pkg/v1/remote/transport/ping.go | 39 +-
.../pkg/v1/remote/transport/transport.go | 4 +-
.../pkg/v1/stream/layer.go | 155 +-
.../pkg/v1/zz_deepcopy_generated.go | 1 +
vendor/github.com/json-iterator/go/README.md | 2 -
vendor/github.com/json-iterator/go/go.mod | 2 +-
vendor/github.com/json-iterator/go/go.sum | 5 +-
.../github.com/modern-go/reflect2/.travis.yml | 2 +-
.../github.com/modern-go/reflect2/Gopkg.lock | 8 +-
.../github.com/modern-go/reflect2/Gopkg.toml | 4 -
vendor/github.com/modern-go/reflect2/go.mod | 3 +
.../modern-go/reflect2/go_above_118.go | 23 +
.../modern-go/reflect2/go_above_17.go | 8 -
.../modern-go/reflect2/go_above_19.go | 3 +
.../modern-go/reflect2/go_below_118.go | 21 +
.../modern-go/reflect2/go_below_17.go | 9 -
.../modern-go/reflect2/go_below_19.go | 14 -
.../github.com/modern-go/reflect2/reflect2.go | 20 +-
vendor/github.com/modern-go/reflect2/test.sh | 12 -
.../github.com/modern-go/reflect2/type_map.go | 51 +-
.../modern-go/reflect2/unsafe_link.go | 26 +-
.../modern-go/reflect2/unsafe_map.go | 8 -
.../k8s-pkg-credentialprovider/README.md | 8 -
.../aws/aws_credentials.go | 305 -
.../azure/azure_acr_helper.go | 285 -
.../azure/azure_credentials.go | 369 -
.../k8s-pkg-credentialprovider/azure/doc.go | 17 -
.../k8s-pkg-credentialprovider/config.go | 329 -
.../k8s-pkg-credentialprovider/doc.go | 19 -
.../k8s-pkg-credentialprovider/gcp/doc.go | 19 -
.../gcp/metadata.go | 253 -
.../k8s-pkg-credentialprovider/go.mod | 22 -
.../k8s-pkg-credentialprovider/go.sum | 755 -
.../k8s-pkg-credentialprovider/keyring.go | 303 -
.../k8s-pkg-credentialprovider/plugins.go | 70 -
.../k8s-pkg-credentialprovider/provider.go | 109 -
.../secrets/secrets.go | 58 -
.../k8s-pkg-credentialprovider/sync.sh | 23 -
vendor/golang.org/x/net/http2/server.go | 2 +-
.../golang.org/x/sys/plan9/syscall_plan9.go | 6 +-
vendor/golang.org/x/sys/unix/mkerrors.sh | 2 +
vendor/golang.org/x/sys/unix/syscall_aix.go | 6 +-
.../golang.org/x/sys/unix/syscall_darwin.go | 6 +-
.../x/sys/unix/syscall_dragonfly.go | 10 +-
.../golang.org/x/sys/unix/syscall_freebsd.go | 6 +-
vendor/golang.org/x/sys/unix/syscall_linux.go | 6 +-
.../golang.org/x/sys/unix/syscall_netbsd.go | 14 +-
.../golang.org/x/sys/unix/syscall_openbsd.go | 6 +-
.../golang.org/x/sys/unix/syscall_solaris.go | 12 +-
.../x/sys/unix/syscall_zos_s390x.go | 6 +-
vendor/golang.org/x/sys/unix/zerrors_linux.go | 30 +-
.../x/sys/unix/zerrors_linux_386.go | 3 +
.../x/sys/unix/zerrors_linux_amd64.go | 3 +
.../x/sys/unix/zerrors_linux_arm.go | 3 +
.../x/sys/unix/zerrors_linux_arm64.go | 3 +
.../x/sys/unix/zerrors_linux_mips.go | 3 +
.../x/sys/unix/zerrors_linux_mips64.go | 3 +
.../x/sys/unix/zerrors_linux_mips64le.go | 3 +
.../x/sys/unix/zerrors_linux_mipsle.go | 3 +
.../x/sys/unix/zerrors_linux_ppc.go | 3 +
.../x/sys/unix/zerrors_linux_ppc64.go | 3 +
.../x/sys/unix/zerrors_linux_ppc64le.go | 3 +
.../x/sys/unix/zerrors_linux_riscv64.go | 3 +
.../x/sys/unix/zerrors_linux_s390x.go | 3 +
.../x/sys/unix/zerrors_linux_sparc64.go | 3 +
.../x/sys/unix/zsyscall_netbsd_386.go | 12 -
.../x/sys/unix/zsyscall_netbsd_amd64.go | 12 -
.../x/sys/unix/zsyscall_netbsd_arm.go | 12 -
.../x/sys/unix/zsyscall_netbsd_arm64.go | 12 -
.../x/sys/unix/zsysnum_linux_386.go | 1 +
.../x/sys/unix/zsysnum_linux_amd64.go | 1 +
.../x/sys/unix/zsysnum_linux_arm.go | 1 +
.../x/sys/unix/zsysnum_linux_arm64.go | 1 +
.../x/sys/unix/zsysnum_linux_mips.go | 1 +
.../x/sys/unix/zsysnum_linux_mips64.go | 1 +
.../x/sys/unix/zsysnum_linux_mips64le.go | 1 +
.../x/sys/unix/zsysnum_linux_mipsle.go | 1 +
.../x/sys/unix/zsysnum_linux_ppc.go | 1 +
.../x/sys/unix/zsysnum_linux_ppc64.go | 1 +
.../x/sys/unix/zsysnum_linux_ppc64le.go | 1 +
.../x/sys/unix/zsysnum_linux_riscv64.go | 1 +
.../x/sys/unix/zsysnum_linux_s390x.go | 1 +
.../x/sys/unix/zsysnum_linux_sparc64.go | 1 +
vendor/golang.org/x/sys/unix/ztypes_linux.go | 107 +-
.../golang.org/x/sys/windows/exec_windows.go | 37 +-
.../x/sys/windows/syscall_windows.go | 4 +
.../golang.org/x/sys/windows/types_windows.go | 60 +-
.../x/sys/windows/zsyscall_windows.go | 32 +
vendor/golang.org/x/term/go.mod | 4 +-
vendor/golang.org/x/term/go.sum | 4 +-
vendor/golang.org/x/term/term.go | 4 +-
vendor/golang.org/x/term/term_solaris.go | 111 -
vendor/golang.org/x/term/term_unix.go | 4 +-
vendor/golang.org/x/term/term_unix_linux.go | 10 -
.../{term_unix_aix.go => term_unix_other.go} | 5 +-
vendor/golang.org/x/term/term_unix_zos.go | 10 -
.../google.golang.org/api/dns/v1/dns-gen.go | 50 +-
.../grpc/balancer/balancer.go | 29 +-
vendor/google.golang.org/grpc/clientconn.go | 43 +-
.../grpc/credentials/credentials.go | 10 +
.../grpc/credentials/insecure/insecure.go | 77 +
vendor/google.golang.org/grpc/dialoptions.go | 24 +-
.../grpc/internal/channelz/funcs.go | 20 +-
.../grpc/internal/envconfig/envconfig.go | 6 -
.../{xds/env/env.go => envconfig/xds.go} | 61 +-
.../grpc/internal/transport/flowcontrol.go | 4 +-
.../grpc/internal/transport/http2_client.go | 15 +-
.../grpc/internal/transport/http2_server.go | 36 +-
.../grpc/internal/transport/proxy.go | 4 +-
vendor/google.golang.org/grpc/pickfirst.go | 2 +-
vendor/google.golang.org/grpc/regenerate.sh | 4 +-
vendor/google.golang.org/grpc/rpc_util.go | 12 +-
.../google.golang.org/grpc/status/status.go | 19 +-
vendor/google.golang.org/grpc/version.go | 2 +-
.../credentialconfig/registry.go | 31 -
.../component-base/version/.gitattributes | 1 -
vendor/k8s.io/component-base/version/base.go | 63 -
.../k8s.io/component-base/version/version.go | 42 -
.../k8s.io/kube-openapi/pkg/common/common.go | 5 +
.../kube-openapi/pkg/generators/enum.go | 152 +
.../kube-openapi/pkg/generators/extension.go | 4 +
.../kube-openapi/pkg/generators/openapi.go | 21 +-
.../kube-openapi/pkg/validation/spec/info.go | 19 +
.../azure/auth/azure_auth.go | 290 -
.../gce/gcpcredential/credentialutil.go | 113 -
.../gce/gcpcredential/gcpcredential.go | 130 -
.../gce/gcpcredential/registry_marshal.go | 110 -
vendor/modules.txt | 187 +-
797 files changed, 96243 insertions(+), 56334 deletions(-)
rename third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/{to => azure/auth}/LICENSE (100%)
rename third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/{validation => azure/cli}/LICENSE (100%)
rename third_party/VENDOR-LICENSE/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/LICENSE.txt (100%)
rename third_party/VENDOR-LICENSE/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/NOTICE.txt (92%)
rename {vendor/github.com/aws/aws-sdk-go => third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/config}/LICENSE.txt (100%)
rename third_party/VENDOR-LICENSE/{k8s.io/component-base/version/LICENSE => github.com/aws/aws-sdk-go-v2/credentials/LICENSE.txt} (100%)
rename vendor/k8s.io/component-base/LICENSE => third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/LICENSE.txt (100%)
rename vendor/k8s.io/legacy-cloud-providers/LICENSE => third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/configsources/LICENSE.txt (99%)
rename vendor/k8s.io/cloud-provider/LICENSE => third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/LICENSE.txt (99%)
create mode 100644 third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/ini/LICENSE.txt
rename third_party/VENDOR-LICENSE/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/sync/singleflight/LICENSE (100%)
create mode 100644 third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/ecr/LICENSE.txt
create mode 100644 third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/ecrpublic/LICENSE.txt
create mode 100644 third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/LICENSE.txt
create mode 100644 third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/sso/LICENSE.txt
create mode 100644 third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/sts/LICENSE.txt
create mode 100644 third_party/VENDOR-LICENSE/github.com/aws/smithy-go/LICENSE
create mode 100644 third_party/VENDOR-LICENSE/github.com/aws/smithy-go/NOTICE
create mode 100644 third_party/VENDOR-LICENSE/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/LICENSE
rename {vendor/github.com/vdemeester/k8s-pkg-credentialprovider => third_party/VENDOR-LICENSE/github.com/chrismellard/docker-credential-acr-env/pkg}/LICENSE (99%)
rename third_party/VENDOR-LICENSE/{k8s.io/cloud-provider/credentialconfig => github.com/dimchansky/utfbom}/LICENSE (100%)
create mode 100644 third_party/VENDOR-LICENSE/github.com/google/go-containerregistry/pkg/authn/kubernetes/LICENSE
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/models.go
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/operations.go
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/registries.go
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/replications.go
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/runs.go
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/tasks.go
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/webhooks.go
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/accesstokens.go
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/blob.go
rename vendor/github.com/Azure/azure-sdk-for-go/services/{containerregistry/mgmt/2019-05-01 => preview/containerregistry/runtime/2019-08-15-preview}/containerregistry/client.go (60%)
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/manifests.go
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/models.go
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/refreshtokens.go
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/repository.go
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/tag.go
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/v2support.go
rename vendor/github.com/Azure/azure-sdk-for-go/services/{containerregistry/mgmt/2019-05-01 => preview/containerregistry/runtime/2019-08-15-preview}/containerregistry/version.go (98%)
rename vendor/github.com/Azure/go-autorest/autorest/{to => azure/auth}/LICENSE (100%)
create mode 100644 vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go
create mode 100644 vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod
create mode 100644 vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum
rename vendor/github.com/Azure/go-autorest/autorest/{to => azure/auth}/go_mod_tidy_hack.go (83%)
rename vendor/github.com/Azure/go-autorest/autorest/{validation => azure/cli}/LICENSE (100%)
create mode 100644 vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod
create mode 100644 vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum
create mode 100644 vendor/github.com/Azure/go-autorest/autorest/azure/cli/go_mod_tidy_hack.go
create mode 100644 vendor/github.com/Azure/go-autorest/autorest/azure/cli/profile.go
create mode 100644 vendor/github.com/Azure/go-autorest/autorest/azure/cli/token.go
delete mode 100644 vendor/github.com/Azure/go-autorest/autorest/to/convert.go
delete mode 100644 vendor/github.com/Azure/go-autorest/autorest/to/go.mod
delete mode 100644 vendor/github.com/Azure/go-autorest/autorest/to/go.sum
delete mode 100644 vendor/github.com/Azure/go-autorest/autorest/validation/error.go
delete mode 100644 vendor/github.com/Azure/go-autorest/autorest/validation/go.mod
delete mode 100644 vendor/github.com/Azure/go-autorest/autorest/validation/go.sum
delete mode 100644 vendor/github.com/Azure/go-autorest/autorest/validation/validation.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/.gitignore
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/.golangci.toml
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/.travis.yml
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/CODE_OF_CONDUCT.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/CONTRIBUTING.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/DESIGN.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/Makefile
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/NOTICE.txt (92%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/README.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/config.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/context.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/credential_cache.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/credentials.go
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/aws/doc.go (86%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/errors.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/from_ptr.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/logging.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/logging_generate.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/osname.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/osname_go115.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/request_id.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/request_id_retriever.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/user_agent.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/array.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/encoder.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/map.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/object.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/value.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/restjson/decoder_util.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/xml/error_utils.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/ratelimit/token_bucket.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/ratelimit/token_rate_limit.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/request.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/errors.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/jitter_backoff.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/retry.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/retryable_error.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/standard.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retry/timeout_error.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/retryer.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/cache.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/const.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/header_rules.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/headers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/hmac.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/host.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/scope.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/time.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/util.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/presign_middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/stream.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/v4.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/to_ptr.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/client.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/content_type.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/response_error.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/response_error_middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/timeout_read_closer.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/aws/types.go
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/aws/version.go (72%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/buildspec.yml
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/config.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/env_config.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/generate.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/load_options.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/local.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/resolve.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/resolve_credentials.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/config/shared_config.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds/provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client/client.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client/middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/processcreds/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/processcreds/provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/os.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/os_windows.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/static_provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/stscreds/assume_role_provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/credentials/stscreds/web_identity_provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_client.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetDynamicData.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetIAMInfo.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetInstanceIdentityDocument.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetMetadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetRegion.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetToken.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetUserData.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/internal/config/resolvers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/request_middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/token_provider.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/config.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/LICENSE.txt
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/ast.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/comma_token.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/comment_token.go (100%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/dependency.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/doc.go
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/empty_token.go (100%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/errors.go
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/expression.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/fuzz.go (90%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go_module_metadata.go
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/ini.go (57%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/ini_lexer.go (91%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/ini_parser.go (87%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/literal_tokens.go (88%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/newline_token.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/number_helper.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/op_tokens.go (100%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/ini/parse_error.go
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/parse_stack.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/sep_tokens.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/skipper.go (91%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/statement.go (93%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/value_util.go (99%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/visitor.go (51%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/walker.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/ini/ws_token.go (100%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/rand/rand.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/sdk/interfaces.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/sdk/time.go
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/sdkio/byte.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/strings/strings.go (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/sync/singleflight/LICENSE (100%)
rename vendor/github.com/aws/{aws-sdk-go => aws-sdk-go-v2}/internal/sync/singleflight/singleflight.go (100%)
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/internal/timeconv/duration.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/local-mod-replace.sh
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/modman.toml
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_client.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchCheckLayerAvailability.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchDeleteImage.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchGetImage.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchGetRepositoryScanningConfiguration.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CompleteLayerUpload.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CreatePullThroughCacheRule.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CreateRepository.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteLifecyclePolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeletePullThroughCacheRule.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRegistryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRepository.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRepositoryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImageReplicationStatus.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImageScanFindings.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImages.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribePullThroughCacheRules.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeRegistry.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeRepositories.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetAuthorizationToken.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetDownloadUrlForLayer.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetLifecyclePolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetLifecyclePolicyPreview.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRegistryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRegistryScanningConfiguration.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRepositoryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_InitiateLayerUpload.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_ListImages.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_ListTagsForResource.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImage.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImageScanningConfiguration.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImageTagMutability.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutLifecyclePolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutRegistryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutRegistryScanningConfiguration.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutReplicationConfiguration.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_SetRepositoryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_StartImageScan.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_StartLifecyclePolicyPreview.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_TagResource.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_UntagResource.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_UploadLayerPart.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/deserializers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/generated.json
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/internal/endpoints/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/serializers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/enums.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/errors.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/types.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecr/validators.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_client.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_BatchCheckLayerAvailability.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_BatchDeleteImage.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_CompleteLayerUpload.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_CreateRepository.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DeleteRepository.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DeleteRepositoryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeImageTags.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeImages.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeRegistries.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeRepositories.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetAuthorizationToken.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRegistryCatalogData.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRepositoryCatalogData.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRepositoryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_InitiateLayerUpload.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_ListTagsForResource.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutImage.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutRegistryCatalogData.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutRepositoryCatalogData.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_SetRepositoryPolicy.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_TagResource.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_UntagResource.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_UploadLayerPart.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/deserializers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/generated.json
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/internal/endpoints/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/serializers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/enums.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/errors.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/types.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/validators.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/context.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/middleware.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_client.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_GetRoleCredentials.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_ListAccountRoles.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_ListAccounts.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_Logout.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/deserializers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/generated.json
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/internal/endpoints/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/serializers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/types/errors.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/types/types.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sso/validators.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/CHANGELOG.md
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/LICENSE.txt
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_client.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRole.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRoleWithSAML.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRoleWithWebIdentity.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_DecodeAuthorizationMessage.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetAccessKeyInfo.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetCallerIdentity.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetFederationToken.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetSessionToken.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/deserializers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/doc.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/generated.json
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/go.mod
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/go.sum
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/go_module_metadata.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/internal/endpoints/endpoints.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/serializers.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/types/errors.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/types/types.go
create mode 100644 vendor/github.com/aws/aws-sdk-go-v2/service/sts/validators.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/awsutil/copy.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/awsutil/equal.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/awsutil/path_value.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/awsutil/prettify.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/client/client.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/client/default_retryer.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/client/logger.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/client/metadata/client_info.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/client/no_op_retryer.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/config.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/convert_types.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/corehandlers/param_validator.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.5.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.7.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.5.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.9.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/example.ini
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/csm/metric_chan.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/defaults/shared_config.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/token_provider.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/endpoints/doc.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/endpoints/legacy_regions.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/errors.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/jsonvalue.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/logger.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/http_request.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/request.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/request_1_7.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/request_1_8.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/request_context.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/request_context_1_6.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/request_pagination.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/timeout_read_closer.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/validation.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/request/waiter.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_5.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_6.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/session/doc.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/session/session.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/signer/v4/header_rules.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/signer/v4/options.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.5.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.7.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/signer/v4/stream.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/signer/v4/uri_path.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/types.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/url.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/aws/url_1_7.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/context/background_go1.5.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/ini/parse_error.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor_go1.9.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read_1_5.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkuri/path.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/shared_config.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/host.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/idempotency.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/build.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/jsonrpc.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/unmarshal_error.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/jsonvalue.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/payload.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/protocol.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal_error.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/rest/build.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/rest/payload.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/rest/unmarshal.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/timestamp.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal_error.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/sort.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/unmarshal.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/xml_to_struct.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/ecr/api.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/ecr/doc.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/ecr/service.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/ecr/waiters.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/sts/api.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/sts/customizations.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/sts/doc.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/sts/errors.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/sts/service.go
delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/sts/stsiface/interface.go
create mode 100644 vendor/github.com/aws/smithy-go/.gitignore
create mode 100644 vendor/github.com/aws/smithy-go/.travis.yml
create mode 100644 vendor/github.com/aws/smithy-go/CHANGELOG.md
create mode 100644 vendor/github.com/aws/smithy-go/CODE_OF_CONDUCT.md
create mode 100644 vendor/github.com/aws/smithy-go/CONTRIBUTING.md
create mode 100644 vendor/github.com/aws/smithy-go/LICENSE
create mode 100644 vendor/github.com/aws/smithy-go/Makefile
create mode 100644 vendor/github.com/aws/smithy-go/NOTICE
create mode 100644 vendor/github.com/aws/smithy-go/README.md
create mode 100644 vendor/github.com/aws/smithy-go/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/document.go
create mode 100644 vendor/github.com/aws/smithy-go/document/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/document/document.go
create mode 100644 vendor/github.com/aws/smithy-go/document/errors.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/encoding.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/httpbinding/encode.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/httpbinding/header.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/httpbinding/path_replace.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/httpbinding/query.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/httpbinding/uri.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/json/array.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/json/constants.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/json/decoder_util.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/json/encoder.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/json/escape.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/json/object.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/json/value.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/array.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/constants.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/element.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/encoder.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/error_utils.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/escape.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/map.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/value.go
create mode 100644 vendor/github.com/aws/smithy-go/encoding/xml/xml_decoder.go
create mode 100644 vendor/github.com/aws/smithy-go/errors.go
create mode 100644 vendor/github.com/aws/smithy-go/go.mod
create mode 100644 vendor/github.com/aws/smithy-go/go.sum
create mode 100644 vendor/github.com/aws/smithy-go/go_module_metadata.go
create mode 100644 vendor/github.com/aws/smithy-go/io/byte.go
create mode 100644 vendor/github.com/aws/smithy-go/io/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/io/reader.go
create mode 100644 vendor/github.com/aws/smithy-go/io/ringbuffer.go
create mode 100644 vendor/github.com/aws/smithy-go/local-mod-replace.sh
create mode 100644 vendor/github.com/aws/smithy-go/logging/logger.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/logging.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/metadata.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/middleware.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/ordered_group.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/stack.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/stack_values.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/step_build.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/step_deserialize.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/step_finalize.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/step_initialize.go
create mode 100644 vendor/github.com/aws/smithy-go/middleware/step_serialize.go
create mode 100644 vendor/github.com/aws/smithy-go/ptr/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/ptr/from_ptr.go
create mode 100644 vendor/github.com/aws/smithy-go/ptr/gen_scalars.go
create mode 100644 vendor/github.com/aws/smithy-go/ptr/to_ptr.go
create mode 100644 vendor/github.com/aws/smithy-go/rand/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/rand/rand.go
create mode 100644 vendor/github.com/aws/smithy-go/rand/uuid.go
create mode 100644 vendor/github.com/aws/smithy-go/time/time.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/checksum_middleware.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/client.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/doc.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/headerlist.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/host.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/internal/io/safe.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/md5_checksum.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/middleware_close_response_body.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/middleware_content_length.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/middleware_headers.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/middleware_http_logging.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/middleware_metadata.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/middleware_min_proto.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/request.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/response.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/time.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/url.go
create mode 100644 vendor/github.com/aws/smithy-go/transport/http/user_agent.go
create mode 100644 vendor/github.com/aws/smithy-go/validation.go
create mode 100644 vendor/github.com/aws/smithy-go/waiter/logger.go
create mode 100644 vendor/github.com/aws/smithy-go/waiter/waiter.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/LICENSE
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api/client.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api/factory.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/build.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/credentials.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/file.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/null.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config/cache_dir.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config/log.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/ecr.go
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/go.mod
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/go.sum
create mode 100644 vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/version/version.go
delete mode 100644 vendor/github.com/cespare/xxhash/v2/.travis.yml
rename {third_party/VENDOR-LICENSE/github.com/vdemeester/k8s-pkg-credentialprovider => vendor/github.com/chrismellard/docker-credential-acr-env}/LICENSE (99%)
create mode 100644 vendor/github.com/chrismellard/docker-credential-acr-env/pkg/credhelper/helper.go
rename vendor/{k8s.io/legacy-cloud-providers/azure/auth/doc.go => github.com/chrismellard/docker-credential-acr-env/pkg/registry/const.go} (69%)
create mode 100644 vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/registry.go
create mode 100644 vendor/github.com/chrismellard/docker-credential-acr-env/pkg/token/token.go
create mode 100644 vendor/github.com/dimchansky/utfbom/.gitignore
create mode 100644 vendor/github.com/dimchansky/utfbom/.travis.yml
rename {third_party/VENDOR-LICENSE/k8s.io/legacy-cloud-providers => vendor/github.com/dimchansky/utfbom}/LICENSE (100%)
create mode 100644 vendor/github.com/dimchansky/utfbom/README.md
create mode 100644 vendor/github.com/dimchansky/utfbom/go.mod
create mode 100644 vendor/github.com/dimchansky/utfbom/utfbom.go
create mode 100644 vendor/github.com/evanphx/json-patch/.gitignore
delete mode 100644 vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_azure.go
delete mode 100644 vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_gcp.go
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/LICENSE
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/go.mod
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/go.sum
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/keychain.go
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/v1/google/README.md
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/v1/google/auth.go
rename vendor/github.com/google/go-containerregistry/pkg/{authn/k8schain/k8schain_aws.go => v1/google/doc.go} (72%)
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/v1/google/keychain.go
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/v1/google/list.go
create mode 100644 vendor/github.com/google/go-containerregistry/pkg/v1/google/options.go
create mode 100644 vendor/github.com/modern-go/reflect2/go.mod
create mode 100644 vendor/github.com/modern-go/reflect2/go_above_118.go
delete mode 100644 vendor/github.com/modern-go/reflect2/go_above_17.go
create mode 100644 vendor/github.com/modern-go/reflect2/go_below_118.go
delete mode 100644 vendor/github.com/modern-go/reflect2/go_below_17.go
delete mode 100644 vendor/github.com/modern-go/reflect2/go_below_19.go
delete mode 100644 vendor/github.com/modern-go/reflect2/test.sh
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/README.md
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/aws/aws_credentials.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/azure_acr_helper.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/azure_credentials.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/doc.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/config.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/doc.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/gcp/doc.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/gcp/metadata.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/go.mod
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/go.sum
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/keyring.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/plugins.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/provider.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/secrets/secrets.go
delete mode 100644 vendor/github.com/vdemeester/k8s-pkg-credentialprovider/sync.sh
delete mode 100644 vendor/golang.org/x/term/term_solaris.go
delete mode 100644 vendor/golang.org/x/term/term_unix_linux.go
rename vendor/golang.org/x/term/{term_unix_aix.go => term_unix_other.go} (63%)
delete mode 100644 vendor/golang.org/x/term/term_unix_zos.go
create mode 100644 vendor/google.golang.org/grpc/credentials/insecure/insecure.go
rename vendor/google.golang.org/grpc/internal/{xds/env/env.go => envconfig/xds.go} (50%)
delete mode 100644 vendor/k8s.io/cloud-provider/credentialconfig/registry.go
delete mode 100644 vendor/k8s.io/component-base/version/.gitattributes
delete mode 100644 vendor/k8s.io/component-base/version/base.go
delete mode 100644 vendor/k8s.io/component-base/version/version.go
create mode 100644 vendor/k8s.io/kube-openapi/pkg/generators/enum.go
delete mode 100644 vendor/k8s.io/legacy-cloud-providers/azure/auth/azure_auth.go
delete mode 100644 vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/credentialutil.go
delete mode 100644 vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/gcpcredential.go
delete mode 100644 vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/registry_marshal.go
diff --git a/go.mod b/go.mod
index 31e621b92a20..5e9850a3314f 100644
--- a/go.mod
+++ b/go.mod
@@ -8,14 +8,13 @@ require (
github.com/davecgh/go-spew v1.1.1
github.com/gogo/protobuf v1.3.2
github.com/google/go-cmp v0.5.6
- github.com/google/go-containerregistry v0.7.1-0.20211118220127-abdc633f8305
- github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20211118220127-abdc633f8305
+ github.com/google/go-containerregistry v0.8.1-0.20220114205711-890d5b362eb8
+ github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220114205711-890d5b362eb8
github.com/google/gofuzz v1.2.0
github.com/gorilla/websocket v1.4.2
github.com/hashicorp/golang-lru v0.5.4
github.com/influxdata/tdigest v0.0.1 // indirect
github.com/kelseyhightower/envconfig v1.4.0
- github.com/miekg/dns v1.1.29 // indirect
github.com/prometheus/client_golang v1.11.0
github.com/prometheus/client_model v0.2.0
github.com/tsenart/go-tsz v0.0.0-20180814235614-0bd30b3df1c3 // indirect
@@ -24,19 +23,19 @@ require (
go.uber.org/atomic v1.9.0
go.uber.org/automaxprocs v1.4.0
go.uber.org/zap v1.19.1
- golang.org/x/net v0.0.0-20211209124913-491a49abca63
+ golang.org/x/net v0.0.0-20211216030914-fe4d6282115f
golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c
golang.org/x/time v0.0.0-20211116232009-f0f3c7e86c11
- google.golang.org/api v0.61.0
- google.golang.org/grpc v1.42.0
+ google.golang.org/api v0.62.0
+ google.golang.org/grpc v1.43.0
k8s.io/api v0.22.5
k8s.io/apiextensions-apiserver v0.22.5
k8s.io/apimachinery v0.22.5
k8s.io/client-go v0.22.5
k8s.io/code-generator v0.22.5
k8s.io/klog v1.0.0 // indirect
- k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c
+ k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65
knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931
knative.dev/hack v0.0.0-20220111151514-59b0cf17578e
knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9
diff --git a/go.sum b/go.sum
index 13ef864cad05..89722abc7c1b 100644
--- a/go.sum
+++ b/go.sum
@@ -7,7 +7,6 @@ cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxK
cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc=
cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0=
cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To=
-cloud.google.com/go v0.51.0/go.mod h1:hWtGJ6gnXH+KgDv+V0zFGDvpi07n3z8ZNj3T1RW0Gcw=
cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4=
cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M=
cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc=
@@ -27,8 +26,9 @@ cloud.google.com/go v0.90.0/go.mod h1:kRX0mNRHe0e2rC6oNakvwQqzyDmg57xJ+SZU1eT2aD
cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+YI=
cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4=
cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc=
-cloud.google.com/go v0.98.0 h1:w6LozQJyDDEyhf64Uusu1LCcnLt0I1VMLiJC2kV+eXk=
cloud.google.com/go v0.98.0/go.mod h1:ua6Ush4NALrHk5QXDWnjvZHN93OuF0HfuEPq9I1X0cM=
+cloud.google.com/go v0.99.0 h1:y/cM2iqGgGi5D5DQZl6D9STN/3dR/Vx5Mp8s752oJTY=
+cloud.google.com/go v0.99.0/go.mod h1:w0Xx2nLzqWJPuozYQX+hFfCSI8WioryfRDzkoI/Y2ZA=
cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o=
cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE=
cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc=
@@ -38,6 +38,7 @@ cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM7
cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE=
cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk=
cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk=
+cloud.google.com/go/firestore v1.6.1/go.mod h1:asNXNOzBdyVQmEU+ggO8UPodTkEVFW5Qx+rwHnAz+EY=
cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I=
cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw=
cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA=
@@ -56,47 +57,41 @@ contrib.go.opencensus.io/exporter/zipkin v0.1.2 h1:YqE293IZrKtqPnpwDPH/lOqTWD/s3
contrib.go.opencensus.io/exporter/zipkin v0.1.2/go.mod h1:mP5xM3rrgOjpn79MM8fZbj3gsxcuytSqtH0dxSWW1RE=
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
github.com/Azure/azure-sdk-for-go v16.2.1+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
-github.com/Azure/azure-sdk-for-go v43.0.0+incompatible h1:/wSNCu0e6EsHFR4Qa3vBEBbicaprEHMyyga9g8RTULI=
-github.com/Azure/azure-sdk-for-go v43.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
+github.com/Azure/azure-sdk-for-go v46.4.0+incompatible h1:fCN6Pi+tEiEwFa8RSmtVlFHRXEZ+DJm9gfx/MKqYWw4=
+github.com/Azure/azure-sdk-for-go v46.4.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
github.com/Azure/go-ansiterm v0.0.0-20210608223527-2377c96fe795/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E=
github.com/Azure/go-autorest v10.8.1+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
-github.com/Azure/go-autorest/autorest v0.9.0/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+BFDTQ8rEZB0s4Yfa6bI=
github.com/Azure/go-autorest/autorest v0.11.1/go.mod h1:JFgpikqFJ/MleTTxwepExTKnFUKKszPS8UavbQYUMuw=
-github.com/Azure/go-autorest/autorest v0.11.12/go.mod h1:eipySxLmqSyC5s5k1CLupqet0PSENBEDP93LQ9a8QYw=
+github.com/Azure/go-autorest/autorest v0.11.6/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
+github.com/Azure/go-autorest/autorest v0.11.8/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
github.com/Azure/go-autorest/autorest v0.11.18 h1:90Y4srNYrwOtAgVo3ndrQkTYn6kf1Eg/AjTFJ8Is2aM=
github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA=
-github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEgQTmVqjGhiHBW7RJJEciWzS0=
github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg=
+github.com/Azure/go-autorest/autorest/adal v0.9.4/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
github.com/Azure/go-autorest/autorest/adal v0.9.13 h1:Mp5hbtOePIzM8pJVRa3YLrWWmZtoxRXqUEzCfJt3+/Q=
github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M=
-github.com/Azure/go-autorest/autorest/date v0.1.0/go.mod h1:plvfp3oPSKwf2DNjlBjWF/7vwR+cUD/ELuzDCXwHUVA=
+github.com/Azure/go-autorest/autorest/azure/auth v0.5.2 h1:R1pgoZkhXuv4+0ky9r3e5pcnRXWcXGIuPXpC/xkc7uI=
+github.com/Azure/go-autorest/autorest/azure/auth v0.5.2/go.mod h1:q98IH4qgc3eWM4/WOeR5+YPmBuy8Lq0jNRDwSM0CuFk=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.1 h1:jwcD1wURu0+hKceV04MubZmKLzwEYOCz6q4aOtVZ+Ng=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.1/go.mod h1:JfDgiIO1/RPu6z42AdQTyjOoCM2MFhLqSBDvMEkDgcg=
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
-github.com/Azure/go-autorest/autorest/mocks v0.1.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0=
-github.com/Azure/go-autorest/autorest/mocks v0.2.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0=
github.com/Azure/go-autorest/autorest/mocks v0.4.0/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
-github.com/Azure/go-autorest/autorest/to v0.2.0/go.mod h1:GunWKJp1AEqgMaGLV+iocmRAJWqST1wQYhyyjXJ3SJc=
-github.com/Azure/go-autorest/autorest/to v0.3.0 h1:zebkZaadz7+wIQYgC7GXaz3Wb28yKYfVkkBKwc38VF8=
-github.com/Azure/go-autorest/autorest/to v0.3.0/go.mod h1:MgwOyqaIuKdG4TL/2ywSsIWKAfJfgHDo8ObuUk3t5sA=
-github.com/Azure/go-autorest/autorest/validation v0.1.0 h1:ISSNzGUh+ZSzizJWOWzs8bwpXIePbGLW4z/AmUFGH5A=
-github.com/Azure/go-autorest/autorest/validation v0.1.0/go.mod h1:Ha3z/SqBeaalWQvokg3NZAlQTalVMtOIAs1aGK7G6u8=
-github.com/Azure/go-autorest/logger v0.1.0/go.mod h1:oExouG+K6PryycPJfVSxi/koC6LSNgds39diKLz7Vrc=
github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
github.com/Azure/go-autorest/logger v0.2.1 h1:IG7i4p/mDa2Ce4TRyAO8IHnVhAVF3RFU+ZtXWSmf4Tg=
github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
-github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbtp2fGCgRFtBroKn4Dk=
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
-github.com/GoogleCloudPlatform/k8s-cloud-provider v0.0.0-20200415212048-7901bc822317/go.mod h1:DF8FZRxMHMGv/vP2lQP6h+dYzzjpuRn24VeRiYn3qjQ=
+github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ=
github.com/Microsoft/go-winio v0.4.11/go.mod h1:VhR8bwka0BXejwEJY73c50VrPtXAaKcyvVC4A4RozmA=
github.com/Microsoft/go-winio v0.4.14/go.mod h1:qXqCSQ3Xa7+6tgxaGTIe4Kpcdsi+P8jBhyzoq1bpyYA=
github.com/Microsoft/go-winio v0.4.15-0.20190919025122-fc70bd9a86b5/go.mod h1:tTuCMEN+UleMWgg9dVx4Hu52b1bJo+59jBh3ajtinzw=
@@ -105,7 +100,6 @@ github.com/Microsoft/go-winio v0.4.16/go.mod h1:XB6nPKklQyQ7GC9LdcBEcBl8PF76WugX
github.com/Microsoft/go-winio v0.4.17-0.20210211115548-6eac466e5fa3/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
github.com/Microsoft/go-winio v0.4.17-0.20210324224401-5516f17a5958/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
github.com/Microsoft/go-winio v0.4.17/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
-github.com/Microsoft/go-winio v0.5.0/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
github.com/Microsoft/go-winio v0.5.1/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
github.com/Microsoft/hcsshim v0.8.6/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg=
github.com/Microsoft/hcsshim v0.8.7-0.20190325164909-8abdbb8205e4/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg=
@@ -142,11 +136,50 @@ github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kd
github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o=
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY=
+github.com/armon/go-metrics v0.3.10/go.mod h1:4O98XIr/9W0sxpJ8UaYkvjk10Iff7SnFrb4QAOwNTFc=
github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
+github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY=
github.com/aws/aws-sdk-go v1.15.11/go.mod h1:mFuSZ37Z9YOHbQEwBWztmVzqXrEkub65tZoCYDt7FT0=
-github.com/aws/aws-sdk-go v1.35.24 h1:U3GNTg8+7xSM6OAJ8zksiSM4bRqxBWmVwwehvOSNG3A=
-github.com/aws/aws-sdk-go v1.35.24/go.mod h1:tlPOdRjfxPBpNIwqDj61rmsnA85v9jc0Ps9+muhnW+k=
+github.com/aws/aws-sdk-go-v2 v1.7.1/go.mod h1:L5LuPC1ZgDr2xQS7AmIec/Jlc7O/Y1u2KxJyNVab250=
+github.com/aws/aws-sdk-go-v2 v1.12.0 h1:z5bijqy+eXLK/QqF6eQcwCN2qw1k+m9OUDicqCZygu0=
+github.com/aws/aws-sdk-go-v2 v1.12.0/go.mod h1:tWhQI5N5SiMawto3uMAQJU5OUN/1ivhDDHq7HTsJvZ0=
+github.com/aws/aws-sdk-go-v2/config v1.5.0/go.mod h1:RWlPOAW3E3tbtNAqTwvSW54Of/yP3oiZXMI0xfUdjyA=
+github.com/aws/aws-sdk-go-v2/config v1.12.0 h1:WOhIzj5HdixjlvQ4SLYAOk6OUUsuu88RwcsTzexa9cg=
+github.com/aws/aws-sdk-go-v2/config v1.12.0/go.mod h1:GQONFVSDdG6RRho1C730SGNyDhS1kSTnxpOE76ptBqo=
+github.com/aws/aws-sdk-go-v2/credentials v1.3.1/go.mod h1:r0n73xwsIVagq8RsxmZbGSRQFj9As3je72C2WzUIToc=
+github.com/aws/aws-sdk-go-v2/credentials v1.7.0 h1:KFuKwPs7i5SE5a0LxqAxz75qxSjr2HnHnhu0UPGlvpM=
+github.com/aws/aws-sdk-go-v2/credentials v1.7.0/go.mod h1:Kmq64kahHJtXfmnEwnvRKeNjLBqkdP++Itln9BmQerE=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.3.0/go.mod h1:2LAuqPx1I6jNfaGDucWfA2zqQCYCOMCDHiCOciALyNw=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.9.0 h1:fPq3oloONbHaA0O8KX/KYUQk7pG9JjKBwYQvQsQDK84=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.9.0/go.mod h1:19SxQ+9zANyJCnNaoF3ovl8bFil4TaqCYEDdqNGKM+A=
+github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3 h1:YPNiEXnuWdkpNOwBFHhcLwkSmewwQRcPFO9dHmxU0qg=
+github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3/go.mod h1:L72JSFj9OwHwyukeuKFFyTj6uFWE4AjB0IQp97bd9Lc=
+github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0 h1:ArRd27pSm66f7cCBDPS77wvxiS4IRjFatpzVBD7Aojc=
+github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0/go.mod h1:KdVvdk4gb7iatuHZgIkIqvJlWHBtjCJLUtD/uO/FkWw=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.1.1/go.mod h1:Zy8smImhTdOETZqfyn01iNOe0CNggVbPjCajyaz6Gvg=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.3.3 h1:fmGqMNlFTHr9Y48qmYYv2qIo+TAsST3qZa2d1HcwBeo=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.3.3/go.mod h1:N4dv+zawriMFZBO/6UKg3zt+XO6xWOQo1neAA0lFbo4=
+github.com/aws/aws-sdk-go-v2/service/ecr v1.4.1/go.mod h1:FglZcyeiBqcbvyinl+n14aT/EWC7S1MIH+Gan2iizt0=
+github.com/aws/aws-sdk-go-v2/service/ecr v1.13.0 h1:2XQbjtiOokE9jq2CSQv2wMBMYUEZ/UXwQ0jkLsTW0lk=
+github.com/aws/aws-sdk-go-v2/service/ecr v1.13.0/go.mod h1:X9rkClmo0/dXh2fwvhkMoXR5zxirrzCqMgfU+Z0HIgs=
+github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.4.1/go.mod h1:eD5Eo4drVP2FLTw0G+SMIPWNWvQRGGTtIZR2XeAagoA=
+github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.10.0 h1:d+uTsVjpo8MNNjr+7+1axbFNr0BiLoITecb2cQwofJI=
+github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.10.0/go.mod h1:wlxlU/f1AOpsYIxt86LyrztTAIhyp/6HRNHcZjLzHjg=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.2.1/go.mod h1:zceowr5Z1Nh2WVP8bf/3ikB41IZW59E4yIYbg+pC6mw=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.6.0 h1:rwE0kWa5qm0yEoNPwC3zhrt1tFVXTmkWRlUxLayAwyc=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.6.0/go.mod h1:wTgFkG6t7jS/6Y0SILXwfspV3IXowb6ngsAlSajW0Kc=
+github.com/aws/aws-sdk-go-v2/service/sso v1.3.1/go.mod h1:J3A3RGUvuCZjvSuZEcOpHDnzZP/sKbhDWV2T1EOzFIM=
+github.com/aws/aws-sdk-go-v2/service/sso v1.8.0 h1:X77LUt6Djy3Z02r6tW7Z+4FNr6GCnEG54EXfskc19M4=
+github.com/aws/aws-sdk-go-v2/service/sso v1.8.0/go.mod h1:AB6v3BedyhVRIbPQbJnUsBmtup2pFiikpp5n3YyB6Ac=
+github.com/aws/aws-sdk-go-v2/service/sts v1.6.0/go.mod h1:q7o0j7d7HrJk/vr9uUt3BVRASvcU7gYZB9PUgPiByXg=
+github.com/aws/aws-sdk-go-v2/service/sts v1.13.0 h1:n8+dZMOvwkGtmhub8B2wYvRHut45/NB7DeNhNcUnBpg=
+github.com/aws/aws-sdk-go-v2/service/sts v1.13.0/go.mod h1:jQto17aC9pJ6xRa1g29uXZhbcS6qNT3PSnKfPShq4sY=
+github.com/aws/smithy-go v1.6.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20211215200129-69c85dc22db6 h1:eZSlkTaUtlhgnbn4gOl2Y248cXT+T/jtOww+pQ8m3ow=
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20211215200129-69c85dc22db6/go.mod h1:8vJsEZ4iRqG+Vx6pKhWK6U00qcj0KC37IsfszMkY6UE=
github.com/benbjohnson/clock v1.0.3/go.mod h1:bGMdMPoPVvcYyt1gHDf4J2KE153Yf9BuiUKYMaxlTDM=
github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8=
github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA=
@@ -159,7 +192,6 @@ github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kB
github.com/bitly/go-simplejson v0.5.0/go.mod h1:cXHtHw4XUPsvGaxgjIAn8PhEWG9NfngEKAMDJEczWVA=
github.com/bits-and-blooms/bitset v1.2.0/go.mod h1:gIdJ4wp64HaoK2YrL1Q5/N7Y16edYb8uY+O0FJTyyDA=
github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84=
-github.com/bketelsen/crypt v0.0.4/go.mod h1:aI6NrJ0pMGgvZKL1iVgXLnfIFJtfV+bKCoqOes/6LfM=
github.com/blang/semver v3.1.0+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
github.com/blang/semver v3.5.1+incompatible h1:cQNTCjp13qL8KC3Nbxr/y2Bqb63oX6wdnnjpJbkM4JQ=
github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
@@ -186,10 +218,13 @@ github.com/certifi/gocertifi v0.0.0-20191021191039-0944d244cd40/go.mod h1:sGbDF6
github.com/certifi/gocertifi v0.0.0-20200922220541-2c3bb06c6054/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA=
github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko=
github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc=
-github.com/cespare/xxhash/v2 v2.1.1 h1:6MnRN8NT7+YBpUIWxHtefFZOKTAPgGjpQSxqLNn0+qY=
github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
+github.com/cespare/xxhash/v2 v2.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE=
+github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
github.com/checkpoint-restore/go-criu/v4 v4.1.0/go.mod h1:xUQBLp4RLc5zJtWY++yjOoMoB5lihDt7fai+75m+rGw=
github.com/checkpoint-restore/go-criu/v5 v5.0.0/go.mod h1:cfwC0EG7HMUenopBsUf9d89JlCLQIfgVcNsNN0t6T2M=
+github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86 h1:VZogJ199yfR3BRTzpDcejsFrBCJKLgi9V37K74/YWC8=
+github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86/go.mod h1:Zlre/PVxuSI9y6/UV4NwGixQ48RHQDSPiUkofr6rbMU=
github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
@@ -198,6 +233,8 @@ github.com/cilium/ebpf v0.0.0-20200702112145-1c8d4c9ef775/go.mod h1:7cR51M8ViRLI
github.com/cilium/ebpf v0.2.0/go.mod h1:To2CFviqOWL/M0gIMsvSMlqe7em/l1ALkX1PyjrX2Qs=
github.com/cilium/ebpf v0.4.0/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs=
github.com/cilium/ebpf v0.6.2/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs=
+github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag=
+github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I=
github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc=
github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
@@ -206,7 +243,9 @@ github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4/go.mod h1:6pvJx4me5XP
github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20211130200136-a8f946100490/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8=
github.com/cockroachdb/datadriven v0.0.0-20200714090401-bf6692d28da5/go.mod h1:h6jFvWxBdQXxjopDMZyH2UVceIRfR84bdzbkoKrsWNo=
github.com/cockroachdb/errors v1.2.4/go.mod h1:rQD95gz6FARkaKkQXUksEje/d9a6wBJoCr5oaCLELYA=
@@ -243,7 +282,6 @@ github.com/containerd/containerd v1.5.0-beta.1/go.mod h1:5HfvG1V2FsKesEGQ17k5/T7
github.com/containerd/containerd v1.5.0-beta.3/go.mod h1:/wr9AVtEM7x9c+n0+stptlo/uBBoBORwEx6ardVcmKU=
github.com/containerd/containerd v1.5.0-beta.4/go.mod h1:GmdgZd2zA2GYIBZ0w09ZvgqEq8EfBp/m3lcVZIvPHhI=
github.com/containerd/containerd v1.5.0-rc.0/go.mod h1:V/IXoMqNGgBlabz3tHD2TWDoTJseu1FGOKuoA4nNb2s=
-github.com/containerd/containerd v1.5.2/go.mod h1:0DOxVqwDy2iZvrZp2JUx/E+hS0UNTVn7dJnIOwtYR4g=
github.com/containerd/containerd v1.5.8/go.mod h1:YdFSv5bTFLpG2HIYmfqDpSYYTDX+mc5qtSuYx1YUb/s=
github.com/containerd/continuity v0.0.0-20190426062206-aaeac12a7ffc/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y=
github.com/containerd/continuity v0.0.0-20190815185530-f2a389ac0a02/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y=
@@ -272,7 +310,6 @@ github.com/containerd/imgcrypt v1.1.1/go.mod h1:xpLnwiQmEUJPvQoAapeb2SNCxz7Xr6PJ
github.com/containerd/nri v0.0.0-20201007170849-eb1350a75164/go.mod h1:+2wGSDGFYfE5+So4M5syatU0N0f0LbWpuqyMi4/BE8c=
github.com/containerd/nri v0.0.0-20210316161719-dbaa18c31c14/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY=
github.com/containerd/nri v0.1.0/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY=
-github.com/containerd/stargz-snapshotter/estargz v0.6.4/go.mod h1:83VWDqHnurTKliEB0YvWMiCfLDwv4Cjj1X9Vk98GJZw=
github.com/containerd/stargz-snapshotter/estargz v0.10.1 h1:hd1EoVjI2Ax8Cr64tdYqnJ4i4pZU49FkEf5kU8KxQng=
github.com/containerd/stargz-snapshotter/estargz v0.10.1/go.mod h1:aE5PCyhFMwR8sbrErO5eM2GcvkyXTTJremG883D4qF0=
github.com/containerd/ttrpc v0.0.0-20190828154514-0e0f228740de/go.mod h1:PvCDdDGpgqzQIzDW1TphrGLssLDZp2GuS+X5DkEJB8o=
@@ -338,17 +375,17 @@ github.com/dgryski/go-gk v0.0.0-20200319235926-a69029f61654/go.mod h1:qm+vckxRlD
github.com/dgryski/go-lttb v0.0.0-20180810165845-318fcdf10a77 h1:iRnqZBF0a1hoOOjOdPKf+IxqlJZOas7A48j77RAc7Yg=
github.com/dgryski/go-lttb v0.0.0-20180810165845-318fcdf10a77/go.mod h1:Va5MyIzkU0rAM92tn3hb3Anb7oz7KcnixF49+2wOMe4=
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
+github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
+github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
github.com/dnaeon/go-vcr v1.0.1/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E=
-github.com/docker/cli v20.10.7+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
-github.com/docker/cli v20.10.11+incompatible h1:tXU1ezXcruZQRrMP8RN2z9N91h+6egZTS1gsPsKantc=
-github.com/docker/cli v20.10.11+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
+github.com/docker/cli v20.10.12+incompatible h1:lZlz0uzG+GH+c0plStMUdF/qk3ppmgnswpR5EbqzVGA=
+github.com/docker/cli v20.10.12+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
github.com/docker/distribution v0.0.0-20190905152932-14b96e55d84c/go.mod h1:0+TTO4EOBfRPhZXAeF1Vu+W3hHZ8eLp8PgKVZlcvtFY=
github.com/docker/distribution v2.7.1-0.20190205005809-0d3efadf0154+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w=
github.com/docker/distribution v2.7.1+incompatible h1:a5mlkVzth6W5A4fOsS3D2EO5BUmsJpcB+cRlLU7cSug=
github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w=
-github.com/docker/docker v20.10.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
-github.com/docker/docker v20.10.11+incompatible h1:OqzI/g/W54LczvhnccGqniFoQghHx3pklbLuhfXpqGo=
-github.com/docker/docker v20.10.11+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
+github.com/docker/docker v20.10.12+incompatible h1:CEeNmFM0QZIsJCZKMkZx0ZcahTiewkrgiwfYD+dfl1U=
+github.com/docker/docker v20.10.12+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
github.com/docker/docker-credential-helpers v0.6.3/go.mod h1:WRaJzqw3CTB9bk10avuGsjVBZsD05qeibJ1/TYlvc0Y=
github.com/docker/docker-credential-helpers v0.6.4 h1:axCks+yV+2MR3/kZhAmy07yC56WZ2Pwu/fKWtKuZB0o=
github.com/docker/docker-credential-helpers v0.6.4/go.mod h1:ofX3UI0Gz1TteYBjtgs07O36Pyasyp66D2uKT7H8W1c=
@@ -380,14 +417,19 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.m
github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk=
github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ=
github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0=
+github.com/envoyproxy/go-control-plane v0.10.1/go.mod h1:AY7fTTXNdv/aJ2O5jwpxAPOWUZ7hQAEvzN5Pf27BkQQ=
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
+github.com/envoyproxy/protoc-gen-validate v0.6.2/go.mod h1:2t7qjJNvHPx8IjnBOzl9E9/baC+qXE/TeeyBRzgJDws=
github.com/evanphx/json-patch v0.5.2/go.mod h1:ZWS5hhDbVDyob71nXKNL0+PWn6ToqBHMikGIFbs31qQ=
github.com/evanphx/json-patch v4.9.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
-github.com/evanphx/json-patch v4.11.0+incompatible h1:glyUF9yIYtMHzn8xaKw5rMhdWcwsYV8dZHIq5567/xs=
github.com/evanphx/json-patch v4.11.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
+github.com/evanphx/json-patch v4.12.0+incompatible h1:4onqiflcdA9EOZ4RxV643DvftH5pOlLGNtQ5lPWQu84=
+github.com/evanphx/json-patch v4.12.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
github.com/evanphx/json-patch/v5 v5.6.0 h1:b91NhWfaz02IuVxO9faSllyAtNXHMPkC5J8sJCLunww=
github.com/evanphx/json-patch/v5 v5.6.0/go.mod h1:G79N1coSVB93tBe7j6PhzjmR3/2VvlbKOFpnXhI9Bw4=
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
+github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU=
+github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U=
github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
github.com/form3tech-oss/jwt-go v3.2.3+incompatible h1:7ZaBxOI7TMoYBfyA3cQHErNNyAWIKUMIwqxEtgHOs5c=
@@ -395,10 +437,12 @@ github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoD
github.com/fortytw2/leaktest v1.3.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g=
github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
-github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4=
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
+github.com/fsnotify/fsnotify v1.5.1 h1:mZcQUHVQUQWoPXXtuf9yuEXKudkV2sx1E06UadKWpgI=
+github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU=
github.com/fullsailor/pkcs7 v0.0.0-20190404230743-d7302db945fa/go.mod h1:KnogPXtdwXqoenmZCw6S+25EAm2MkxbG0deNDu4cbSA=
github.com/garyburd/redigo v0.0.0-20150301180006-535138d7bcd7/go.mod h1:NR3MbYisc3/PwhQ00EMzDiPmrwpPxAn5GI05/YaO1SY=
+github.com/getkin/kin-openapi v0.76.0/go.mod h1:660oXbgy5JFMKreazJaQTw7o+X00qeSyhcnluiMv+Xg=
github.com/getsentry/raven-go v0.2.0/go.mod h1:KungGk8q33+aIAZUIVWZDr2OfAEBsO49PX4NzFV5kcQ=
github.com/ghodss/yaml v0.0.0-20150909031657-73d445a93680/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
@@ -429,7 +473,6 @@ github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL9
github.com/go-openapi/jsonreference v0.19.5 h1:1WJP/wi4OjB4iV8KVbH73rQaoialJrqv8gitZLxGLtM=
github.com/go-openapi/jsonreference v0.19.5/go.mod h1:RdybgQwPxbL4UEjuAruzK1x3nE69AqPYEJeo/TWfEeg=
github.com/go-openapi/spec v0.19.3/go.mod h1:FpwSN1ksY1eteniUU7X0N/BgJ7a4WvBFVA8Lj9mJglo=
-github.com/go-openapi/spec v0.19.5/go.mod h1:Hm2Jr4jv8G1ciIAo+frC/Ft+rR2kQDh8JHKHb3gWUSk=
github.com/go-openapi/swag v0.19.2/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
github.com/go-openapi/swag v0.19.14/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ=
@@ -519,11 +562,14 @@ github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/
github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
-github.com/google/go-containerregistry v0.5.2-0.20210609162550-f0ce2270b3b4/go.mod h1:R5WRYyTdQqTchlBhX4q+WICGh8HQIL5wDFoFZv7Jq6Q=
-github.com/google/go-containerregistry v0.7.1-0.20211118220127-abdc633f8305 h1:4upgCb+N0/tewaAT+rPGk8zuKCG1hOoICHvFMxy1CMQ=
-github.com/google/go-containerregistry v0.7.1-0.20211118220127-abdc633f8305/go.mod h1:6cMIl1RfryEiPzBE67OgtZdEiLWz4myqCQIiBMy3CsM=
-github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20211118220127-abdc633f8305 h1:qTOzXf3EnTMdD0CEHSNAa/s5hBDPe9TmynX/6NMJ48Q=
-github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20211118220127-abdc633f8305/go.mod h1:/wxgGW8xlALyJwgyqAOe19EMFzNi+pePDhT33XMD1Yo=
+github.com/google/go-containerregistry v0.8.0/go.mod h1:wW5v71NHGnQyb4k+gSshjxidrC7lN33MdWEn+Mz9TsI=
+github.com/google/go-containerregistry v0.8.1-0.20220110151055-a61fd0a8e2bb/go.mod h1:wW5v71NHGnQyb4k+gSshjxidrC7lN33MdWEn+Mz9TsI=
+github.com/google/go-containerregistry v0.8.1-0.20220114205711-890d5b362eb8 h1:ApavQfyjPOgZ8j/yCWZy4UV/CpLILzhBdjvFx+fvRTc=
+github.com/google/go-containerregistry v0.8.1-0.20220114205711-890d5b362eb8/go.mod h1:wW5v71NHGnQyb4k+gSshjxidrC7lN33MdWEn+Mz9TsI=
+github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220114205711-890d5b362eb8 h1:TQE5iKoyn94B7nqOBaVsSUIvC9ufsnqQy8zN4BJOlww=
+github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220114205711-890d5b362eb8/go.mod h1:gUz0Xep+89eZOY19OVQ9u+9xfaQZPtLmBgx4CFmNuhU=
+github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20220110151055-a61fd0a8e2bb h1:TVAKj23PFWViWiy7iGOuVSHSD8T8DZ7gdDvW138EFgg=
+github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20220110151055-a61fd0a8e2bb/go.mod h1:SK4EqntTk6tHEyNngoqHUwjjZaW6mfzLukei4+cbvu8=
github.com/google/go-github/v27 v27.0.6/go.mod h1:/0Gr8pJ55COkmv+S/yPKCczSkUPIM/LnFyubufRNIS0=
github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck=
github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
@@ -565,13 +611,11 @@ github.com/googleapis/gnostic v0.4.1/go.mod h1:LRhVm6pbyptWbWbuZ38d1eyptfvIytN3i
github.com/googleapis/gnostic v0.5.1/go.mod h1:6U4PtQXGIEt/Z3h5MAT7FNofLnw9vXk2cUuW7uA/OeU=
github.com/googleapis/gnostic v0.5.5 h1:9fHAtK0uDfpveeqqo1hkEZJcFvYXAiCN3UutL8F9xHw=
github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA=
-github.com/gophercloud/gophercloud v0.1.0/go.mod h1:vxM41WHh5uqHVBMZHzuwNOHh8XEoIEcSTewFxm1c5g8=
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg=
github.com/gorilla/handlers v0.0.0-20150720190736-60c7bfde3e33/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ=
github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
github.com/gorilla/mux v1.7.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
-github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So=
github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4=
github.com/gorilla/sessions v1.2.1/go.mod h1:dk2InVEVJ0sfLlnXv9EAgkf6ecYs/i80K/zI+bUmuGM=
@@ -590,15 +634,25 @@ github.com/grpc-ecosystem/grpc-gateway v1.14.6/go.mod h1:zdiPV4Yse/1gnckTHtghG4G
github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo=
github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw=
github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q=
+github.com/hashicorp/consul/api v1.11.0/go.mod h1:XjsvQN+RJGWI2TWy1/kqaE16HrR2J/FWgkYjdZQsX9M=
github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8=
+github.com/hashicorp/consul/sdk v0.8.0/go.mod h1:GBvyrGALthsZObzUGsfgHZQDXjg4lOjagTIwIR1vPms=
github.com/hashicorp/errwrap v0.0.0-20141028054710-7554cd9344ce/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
+github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
+github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48=
+github.com/hashicorp/go-hclog v0.12.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
+github.com/hashicorp/go-hclog v1.0.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
+github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM=
github.com/hashicorp/go-multierror v0.0.0-20161216184304-ed905158d874/go.mod h1:JMRHfdO9jKNzS/+BTlxCjKNQHg/jZAft8U7LloJvN7I=
github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk=
+github.com/hashicorp/go-multierror v1.1.0/go.mod h1:spPvp8C1qA32ftKqdAHm4hHTbPw+vmowP0z+KUhOZdA=
+github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs=
github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU=
+github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8=
github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU=
github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4=
github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
@@ -612,9 +666,16 @@ github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uG
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64=
github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ=
+github.com/hashicorp/mdns v1.0.1/go.mod h1:4gW7WsVCke5TE7EPeYliwHlRUyBtfCwuFwuMg2DmyNY=
+github.com/hashicorp/mdns v1.0.4/go.mod h1:mtBihi+LeNXGtG8L9dX59gAEa12BDtBQSp4v/YAJqrc=
github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I=
+github.com/hashicorp/memberlist v0.2.2/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOnAH9VT3Sh9MUE=
+github.com/hashicorp/memberlist v0.3.0/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOnAH9VT3Sh9MUE=
github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc=
+github.com/hashicorp/serf v0.9.5/go.mod h1:UWDWwZeL5cuWDJdl0C6wrvrUwEqtQ4ZKBKKENpqIUyk=
+github.com/hashicorp/serf v0.9.6/go.mod h1:TXZNMjZQijwlDvp+r0b63xZ45H7JmCmgg4gpTwn9UV4=
github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
+github.com/iancoleman/strcase v0.2.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho=
github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
@@ -648,9 +709,11 @@ github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFF
github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4=
github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
+github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
-github.com/json-iterator/go v1.1.11 h1:uVUAXhF2To8cbw/3xN3pxj6kk7TYKs98NIrTqPlMWAQ=
github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
+github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM=
+github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo=
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU=
github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk=
github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
@@ -664,8 +727,6 @@ github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
github.com/klauspost/compress v1.11.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs=
github.com/klauspost/compress v1.11.13/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs=
-github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg=
-github.com/klauspost/compress v1.13.0/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg=
github.com/klauspost/compress v1.13.6 h1:P76CopJELS0TiO2mebmnzgWaajssP/EszplttgQxcgc=
github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk=
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
@@ -682,9 +743,11 @@ github.com/kr/pty v1.1.5/go.mod h1:9r2w37qlBe7rQ6e1fg1S/9xpWHSnaqNdHD3WcMdbPDA=
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
+github.com/lyft/protoc-gen-star v0.5.3/go.mod h1:V0xaHgaf5oCCqmcxYcWiDfTiKsZsRc87/1qhoTACD8w=
github.com/lyft/protoc-gen-validate v0.0.13/go.mod h1:XbGvPuh87YZc5TdIa2/I4pLk0QoUACkjt2znoq26NVQ=
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
+github.com/magiconair/properties v1.8.4/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
@@ -694,8 +757,17 @@ github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0
github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc=
github.com/marstr/guid v1.1.0/go.mod h1:74gB1z2wpxxInTG6yaqA7KrtM0NZ+RbrcqDvYHefzho=
github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
+github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE=
+github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
+github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
+github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4=
github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
+github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
+github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84=
+github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE=
+github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
+github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU=
github.com/mattn/go-shellwords v1.0.3/go.mod h1:3xCvwCdWdlDJUrvuMn7Wuy9eWs4pE8vqg+NOMyg4B2o=
github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
@@ -703,11 +775,13 @@ github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182aff
github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4=
github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg=
github.com/miekg/dns v1.1.17/go.mod h1:WgzbA6oji13JREwiNsRDNfl7jYdPnmz+VEuLrA+/48M=
-github.com/miekg/dns v1.1.29 h1:xHBEhR+t5RzcFJjBLJlax2daXOrTYtr9z4WdKEfWFzg=
-github.com/miekg/dns v1.1.29/go.mod h1:KNUDUusw/aVsxyTYZM1oqvCicbwhgbNgztCETuNZ7xM=
+github.com/miekg/dns v1.1.26/go.mod h1:bPDLeHnStXmXAq1m/Ch/hvfNHr14JKNPMBo3VZKjuso=
+github.com/miekg/dns v1.1.41 h1:WMszZWJG0XmzbK9FEmzH2TVcqYzFesusSIB41b8KHxY=
+github.com/miekg/dns v1.1.41/go.mod h1:p6aan82bvRIyn+zDIv9xYNUpwa73JcSh9BKwknJysuI=
github.com/miekg/pkcs11 v1.0.3/go.mod h1:XsNlhZGX73bx86s2hdc/FuaLm2CPZJemRLMA+WTFxgs=
github.com/mistifyio/go-zfs v2.1.2-0.20190413222219-f784269be439+incompatible/go.mod h1:8AuVvqP/mXw1px98n46wfvcGfQ4ci2FwoAjKYxuo3Z4=
github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc=
+github.com/mitchellh/cli v1.1.0/go.mod h1:xcISNoH86gajksDmfB23e/pu+B+GeFRMYmoHXxx3xhI=
github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
@@ -716,7 +790,8 @@ github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS4
github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY=
github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
-github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
+github.com/mitchellh/mapstructure v1.3.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
+github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/mitchellh/osext v0.0.0-20151018003038-5e2d6d41470f/go.mod h1:OkQIRizQZAeMln+1tSwduZz7+Af5oFlKirV/MSYes2A=
github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQppc=
github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c=
@@ -730,8 +805,9 @@ github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJ
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
-github.com/modern-go/reflect2 v1.0.1 h1:9f412s+6RmYXLWZSEzVVgPGK7C2PphHj5RJrvfx9AWI=
github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
+github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M=
+github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc=
github.com/mrunalp/fileutils v0.5.0/go.mod h1:M1WthSahJixYnrXQl/DFQuteStB1weuxD2QJNHXfbSQ=
github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
@@ -798,9 +874,10 @@ github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnh
github.com/openzipkin/zipkin-go v0.3.0 h1:XtuXmOLIXLjiU2XduuWREDT0LOKtSgos/g7i7RYyoZQ=
github.com/openzipkin/zipkin-go v0.3.0/go.mod h1:4c3sLeE8xjNqehmF5RpAFLPLJxXscc0R4l6Zg0P1tTQ=
github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
+github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc=
-github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c=
+github.com/pelletier/go-toml v1.9.4/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c=
github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU=
github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc=
github.com/pierrec/lz4 v2.6.1+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY=
@@ -814,12 +891,14 @@ github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZ
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
+github.com/posener/complete v1.2.3/go.mod h1:WZIdtGGp+qx0sLrYKtIRAruyNpv6hFCicSgv7Sy7s/s=
github.com/pquerna/cachecontrol v0.0.0-20171018203845-0dec1b30a021/go.mod h1:prYjPmNq4d1NPVmpShWobRqXY3q7Vp+80DqgxxUrUIA=
github.com/prometheus/client_golang v0.0.0-20180209125602-c332b6f63c06/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso=
github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo=
github.com/prometheus/client_golang v1.1.0/go.mod h1:I1FGZT9+L76gKKOs5djB6ezCbFQP1xR9D75/vuwEF3g=
+github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU=
github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M=
github.com/prometheus/client_golang v1.11.0 h1:HNkLOAEQMIDv/K+04rukrLx6ch7msSRwf3/SASFAGtQ=
github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0=
@@ -834,6 +913,7 @@ github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7q
github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc=
+github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4=
github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo=
github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc=
github.com/prometheus/common v0.28.0/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls=
@@ -861,12 +941,12 @@ github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6So
github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ=
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
github.com/rs/dnscache v0.0.0-20211102005908-e0241e321417/go.mod h1:qe5TWALJ8/a1Lqznoc5BDHpYX/8HU60Hm2AwRmqzxqA=
-github.com/rubiojr/go-vhd v0.0.0-20200706105327-02e210299021/go.mod h1:DM5xW0nvfNNm2uytzsvhI3OnX8uzaRAg8UX/CnDqbto=
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk=
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
github.com/safchain/ethtool v0.0.0-20190326074333-42ed695e3de8/go.mod h1:Z0q5wiBQGYcxhMZ6gUqHn6pYNLypFAvaL3UvgZLR0U4=
+github.com/sagikazarmark/crypt v0.3.0/go.mod h1:uD/D+6UF4SrIR1uGEv7bBNkNqLGqUr43MRiaGWX1Nig=
github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
github.com/seccomp/libseccomp-golang v0.9.1/go.mod h1:GbW5+tmTXfcxTToHLXlScSlAvWlF4P2Ca7zGrPiEpWo=
@@ -888,15 +968,17 @@ github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
+github.com/spf13/afero v1.3.3/go.mod h1:5KUK8ByomD5Ti5Artl0RtHeI5pTF7MIDuXL3yY520V4=
+github.com/spf13/afero v1.4.1/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
+github.com/spf13/cast v1.4.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cobra v0.0.2-0.20171109065643-2da4a54c5cee/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE=
-github.com/spf13/cobra v1.1.1/go.mod h1:WnodtKOvamDL/PwE2M4iKs8aMDBZ5Q5klgD3qfVJQMI=
github.com/spf13/cobra v1.1.3/go.mod h1:pGADOWyqRD/YMrPZigI/zbliZ2wVD/23d+is3pSWzOo=
-github.com/spf13/cobra v1.2.1/go.mod h1:ExllRjgxM/piMAM+3tAZvg8fsklGAf3tPfi+i8t68Nk=
+github.com/spf13/cobra v1.3.0/go.mod h1:BrRVncBjOJa/eUcVVm9CE+oC6as8k+VYr4NY7WCi9V4=
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
@@ -907,7 +989,8 @@ github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE=
github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg=
-github.com/spf13/viper v1.8.1/go.mod h1:o0Pch8wJ9BVSWGQMbra6iw0oQ5oktSIBaujf1rJH9Ns=
+github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg=
+github.com/spf13/viper v1.10.0/go.mod h1:SoyBPwAtKDzypXNDFKN5kzH7ppppbGZtls1UpIy5AsM=
github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980/go.mod h1:AO3tvPzVZ/ayst6UlUKUv6rcPQInYe3IknH3jYhAKu8=
github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8=
github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw=
@@ -938,6 +1021,7 @@ github.com/tsenart/go-tsz v0.0.0-20180814235614-0bd30b3df1c3 h1:pcQGQzTwCg//7FgV
github.com/tsenart/go-tsz v0.0.0-20180814235614-0bd30b3df1c3/go.mod h1:SWZznP1z5Ki7hDT2ioqiFKEse8K9tU2OUvaRI0NeGQo=
github.com/tsenart/vegeta/v12 v12.8.4 h1:UQ7tG7WkDorKj0wjx78Z4/vsMBP8RJQMGJqRVrkvngg=
github.com/tsenart/vegeta/v12 v12.8.4/go.mod h1:ZiJtwLn/9M4fTPdMY7bdbIeyNeFVE8/AHbWFqCsUuho=
+github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM=
github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc=
github.com/urfave/cli v0.0.0-20171014202726-7bc6a0acffa5/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
@@ -947,15 +1031,12 @@ github.com/urfave/cli v1.22.4/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtX
github.com/urfave/cli/v2 v2.3.0/go.mod h1:LJmUH05zAU44vOAcrfzZQKsZbVcdbOG8rtL3/XcUArI=
github.com/vbatts/tar-split v0.11.2 h1:Via6XqJr0hceW4wff3QRzD5gAk/tatMw/4ZA7cTlIME=
github.com/vbatts/tar-split v0.11.2/go.mod h1:vV3ZuO2yWSVsz+pfFzDG/upWH1JhjOiEaWq6kXyQ3VI=
-github.com/vdemeester/k8s-pkg-credentialprovider v1.21.0-1 h1:7Ajl3rjeYoB5V47jPknnLbyxYlhMXTTJiQsye5aT7f0=
-github.com/vdemeester/k8s-pkg-credentialprovider v1.21.0-1/go.mod h1:l4LxiP0cmEcc5q4BTDE8tZSyIiyXe0T28x37yHpMzoM=
github.com/vishvananda/netlink v0.0.0-20181108222139-023a6dafdcdf/go.mod h1:+SR5DhBJrl6ZM7CoCKvpw5BKroDKQ+PJqOg65H/2ktk=
github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE=
github.com/vishvananda/netlink v1.1.1-0.20201029203352-d40f9887b852/go.mod h1:twkDnbuQxJYemMlGd4JFIcuhgX83tXhKS2B/PRMpOho=
github.com/vishvananda/netns v0.0.0-20180720170159-13995c7128cc/go.mod h1:ZjcWmFBXmLKZu9Nxj3WKYEafiSqer2rnvPr0en9UNpI=
github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df/go.mod h1:JP3t17pCcGlemwknint6hfoeCVQrEMVwxRLRjXpq+BU=
github.com/vishvananda/netns v0.0.0-20200728191858-db3c7e526aae/go.mod h1:DD4vA1DwXk04H54A1oHXtwZmA0grkVMdPxx/VGLCah0=
-github.com/vmware/govmomi v0.20.3/go.mod h1:URlwyTFZX72RmxtxuaFL2Uj3fD1JTvZdx59bHWk6aFU=
github.com/willf/bitset v1.1.11-0.20200630133818-d5bec3311243/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4=
github.com/willf/bitset v1.1.11/go.mod h1:83CECat5yLh5zVOf4P1ErAgKA5UDvKtgyUABdr3+MjI=
github.com/xdg-go/pbkdf2 v1.0.0/go.mod h1:jrpuAogTd400dnrH08LKmI/xc1MbPOebTwRqcT5RDeI=
@@ -981,8 +1062,11 @@ go.etcd.io/bbolt v1.3.5/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ=
go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4=
go.etcd.io/etcd v0.5.0-alpha.5.0.20200910180754-dd1b699fc489/go.mod h1:yVHk9ub3CSBatqGNg7GRmsnfLWtoW60w4eDYfh7vHDg=
go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
+go.etcd.io/etcd/api/v3 v3.5.1/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
+go.etcd.io/etcd/client/pkg/v3 v3.5.1/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ=
+go.etcd.io/etcd/client/v2 v2.305.1/go.mod h1:pMEacxZW7o8pg4CrFE7pquyCJJzZvkvdD2RibOCCCGs=
go.etcd.io/etcd/client/v3 v3.5.0/go.mod h1:AIKXXVX/DQXtfTEqBryiLTUXwON+GuvO6Z7lLS/oTh0=
go.etcd.io/etcd/pkg/v3 v3.5.0/go.mod h1:UzJGatBQ1lXChBkQF0AuAtkRQMYnHubxAEYIrC3MSsE=
go.etcd.io/etcd/raft/v3 v3.5.0/go.mod h1:UFOHSIvO/nKwd4lhkwabrTD3cqW5yVyYYf/KlD00Szc=
@@ -1029,7 +1113,6 @@ golang.org/x/crypto v0.0.0-20171113213409-9f005a07e0d3/go.mod h1:6SG95UA2DQfeDnf
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/crypto v0.0.0-20181009213950-7c1a557ab941/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
-golang.org/x/crypto v0.0.0-20190211182817-74369b46fc67/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
@@ -1037,6 +1120,7 @@ golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8U
golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20190829043050-9756ffdc2472/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY=
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
@@ -1044,6 +1128,7 @@ golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPh
golang.org/x/crypto v0.0.0-20201112155050-0c6587e931a9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
+golang.org/x/crypto v0.0.0-20210817164053-32db794688a5/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/crypto v0.0.0-20210920023735-84f357641f63 h1:kETrAMYZq6WVGPa8IIixL0CaEcIUNi+1WX7grUoi3y8=
golang.org/x/crypto v0.0.0-20210920023735-84f357641f63/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
@@ -1083,6 +1168,7 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
+golang.org/x/mod v0.5.0/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
golang.org/x/mod v0.5.1 h1:OJxoQ/rynoF0dcCdI7cLPktw/hR2cueqYfjm43oqK38=
golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
@@ -1134,18 +1220,19 @@ golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb/go.mod h1:sp8m0HH+o8qH0wwXwY
golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
-golang.org/x/net v0.0.0-20210224082022-3d97a244fca7/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc=
golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM=
+golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8=
golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk=
golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20210813160813-60bc85c4be6d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20210917221730-978cfadd31cf/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
-golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
-golang.org/x/net v0.0.0-20211209124913-491a49abca63 h1:iocB37TsdFuN6IBRZ+ry36wrkoV51/tl5vOWqkcPGvY=
golang.org/x/net v0.0.0-20211209124913-491a49abca63/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211216030914-fe4d6282115f h1:hEYJvxw1lSnWIl8X9ofsYMklzaDs90JI2az5YMd4fPM=
+golang.org/x/net v0.0.0-20211216030914-fe4d6282115f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
@@ -1157,8 +1244,6 @@ golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ
golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
-golang.org/x/oauth2 v0.0.0-20210402161424-2e8d93401602/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
-golang.org/x/oauth2 v0.0.0-20210427180440-81ed05c6b58c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210628180205-a41e5a781914/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210805134026-6f1e6394065a/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
@@ -1185,8 +1270,8 @@ golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5h
golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190209173611-3b5209105503/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1205,9 +1290,11 @@ golang.org/x/sys v0.0.0-20190812073006-9eafafc0a87e/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190922100055-0a153f010e69/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191022100944-742c48ecaeb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191115151921-52ab43148777/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1246,6 +1333,7 @@ golang.org/x/sys v0.0.0-20200916030750-2334cc1a136f/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20200922070232-aee5d888a860/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20201005172224-997123666555/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201112073958-5cba982894dd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201117170446-d9b008d0a637/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1256,7 +1344,7 @@ golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1273,17 +1361,23 @@ golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210917161153-d61c044b1678/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.0.0-20211117180635-dee7805ff2e1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.0.0-20211124211545-fe61309f8881 h1:TyHqChC80pFkXWraUUf6RuB5IqFdQieMLwwCJokV2pc=
golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211205182925-97ca703d548d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20220111092808-5a964db01320 h1:0jf+tOCoZ3LyutmCOWpVni1chK4VfFLhRsDK7MhqGRY=
+golang.org/x/sys v0.0.0-20220111092808-5a964db01320/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
-golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d h1:SZxvLBoTP5yHO3Frd4z4vrF+DBX9vMVanchswa69toE=
golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
+golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b h1:9zKuko04nR4gjZ4+DNjHqRlAJqbJETHwiNKDqTfOjfE=
+golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
@@ -1332,7 +1426,6 @@ golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtn
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20191125144606-a911d9008d1f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191216052735-49a3e744a425/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
@@ -1388,7 +1481,6 @@ google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEn
google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
google.golang.org/api v0.14.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
-google.golang.org/api v0.15.1-0.20200106000736-b8fc810ca6b5/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
google.golang.org/api v0.17.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
google.golang.org/api v0.18.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
google.golang.org/api v0.19.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
@@ -1404,7 +1496,6 @@ google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34q
google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8=
google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU=
google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94=
-google.golang.org/api v0.44.0/go.mod h1:EBOGZqzyhtvMDoxwS97ctnh0zUmYY6CxqXsc1AvkYD8=
google.golang.org/api v0.47.0/go.mod h1:Wbvgpq1HddcWVtzsVLyfLp8lDg6AA241LmgIL59tHXo=
google.golang.org/api v0.48.0/go.mod h1:71Pr1vy+TAZRPkPs/xlCf5SsU8WjuAWv1Pfjbtukyy4=
google.golang.org/api v0.50.0/go.mod h1:4bNT5pAuq5ji4SRZm+5QIkjny9JAyVD/3gaSihNefaw=
@@ -1414,8 +1505,10 @@ google.golang.org/api v0.55.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqiv
google.golang.org/api v0.56.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE=
google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdrMgI=
google.golang.org/api v0.58.0/go.mod h1:cAbP2FsxoGVNwtgNAmmn3y5G1TWAiVYRmg4yku3lv+E=
-google.golang.org/api v0.61.0 h1:TXXKS1slM3b2bZNJwD5DV/Tp6/M2cLzLOLh9PjDhrw8=
+google.golang.org/api v0.59.0/go.mod h1:sT2boj7M9YJxZzgeZqXogmhfmRWDtPzT31xkieUbuZU=
google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I=
+google.golang.org/api v0.62.0 h1:PhGymJMXfGBzc4lBRmrx9+1w4w2wEzURHNGF/sD/xGc=
+google.golang.org/api v0.62.0/go.mod h1:dKmwPCydfsad4qCH08MSdgWjfHOyfpd4VtDGgRFdavw=
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
@@ -1488,10 +1581,15 @@ google.golang.org/genproto v0.0.0-20210903162649-d08c68adba83/go.mod h1:eFjDcFEc
google.golang.org/genproto v0.0.0-20210909211513-a8c4777a87af/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
google.golang.org/genproto v0.0.0-20210917145530-b395a37504d4/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
google.golang.org/genproto v0.0.0-20210924002016-3dee208752a0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211008145708-270636b82663/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
google.golang.org/genproto v0.0.0-20211016002631-37fc39342514/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211028162531-8db9c33dc351/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
google.golang.org/genproto v0.0.0-20211118181313-81c1377c94b1/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
-google.golang.org/genproto v0.0.0-20211129164237-f09f9a12af12 h1:DN5b3HU13J4sMd/QjDx34U6afpaexKTDdop+26pdjdk=
google.golang.org/genproto v0.0.0-20211129164237-f09f9a12af12/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211203200212-54befc351ae9/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211206160659-862468c7d6e0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa h1:I0YcKz0I7OAhddo7ya8kMnvprhcWM045PmkBdMO9zN0=
+google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
google.golang.org/grpc v0.0.0-20160317175043-d3ddb4469d5a/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw=
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM=
@@ -1522,9 +1620,11 @@ google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQ
google.golang.org/grpc v1.39.0/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE=
google.golang.org/grpc v1.39.1/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE=
google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34=
+google.golang.org/grpc v1.40.1/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34=
google.golang.org/grpc v1.41.0/go.mod h1:U3l9uK9J0sini8mHphKoXyaqDA/8VyGnDee1zzIUK6k=
-google.golang.org/grpc v1.42.0 h1:XT2/MFpuPFsEX2fWh3YQtHkZ+WYZFQRfaUgLZYj/p6A=
google.golang.org/grpc v1.42.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU=
+google.golang.org/grpc v1.43.0 h1:Eeu7bZtDZ2DpRCsLhUlcrLnvYaMK1Gz86a+hMVvELmM=
+google.golang.org/grpc v1.43.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU=
google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw=
google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0=
@@ -1552,12 +1652,12 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EV
gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw=
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
-gopkg.in/gcfg.v1 v1.2.0/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o=
gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2/go.mod h1:Xk6kEKp8OKb+X14hQBKWaSkCsqBpgog8nAV2xsGOxlo=
gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc=
gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
gopkg.in/ini.v1 v1.62.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
+gopkg.in/ini.v1 v1.66.2/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k=
gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo=
gopkg.in/square/go-jose.v2 v2.2.2/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
@@ -1565,7 +1665,6 @@ gopkg.in/square/go-jose.v2 v2.3.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76
gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ=
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
-gopkg.in/warnings.v0 v0.1.1/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI=
gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74=
gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
@@ -1592,11 +1691,10 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh
honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
+honnef.co/go/tools v0.0.1-2020.1.5/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
k8s.io/api v0.20.1/go.mod h1:KqwcCVogGxQY3nBlRpwt+wpAMF/KjaCc7RpywacvqUo=
k8s.io/api v0.20.4/go.mod h1:++lNL1AJMkDymriNniQsWRkMDzRaX2Y/POTUi8yvqYQ=
k8s.io/api v0.20.6/go.mod h1:X9e8Qag6JV/bL5G6bU8sdVRltWKmdHsFUGS3eVndqE8=
-k8s.io/api v0.21.0/go.mod h1:+YbrhBBGgsxbF6o6Kj4KJPJnBmAKuXDeS3E18bgHNVU=
-k8s.io/api v0.21.1/go.mod h1:FstGROTmsSHBarKc8bylzXih8BLNYTiS3TZcsoEDg2s=
k8s.io/api v0.22.5 h1:xk7C+rMjF/EGELiD560jdmwzrB788mfcHiNbMQLIVI8=
k8s.io/api v0.22.5/go.mod h1:mEhXyLaSD1qTOf40rRiKXkc+2iCem09rWLlFwhCEiAs=
k8s.io/apiextensions-apiserver v0.22.5 h1:ML0QqT7FIlmZHN+9+2EtARJ3cJVHeoizt6GCteFRE0o=
@@ -1604,41 +1702,31 @@ k8s.io/apiextensions-apiserver v0.22.5/go.mod h1:tIXeZ0BrDxUb1PoAz+tgOz43Zi1Bp4B
k8s.io/apimachinery v0.20.1/go.mod h1:WlLqWAHZGg07AeltaI0MV5uk1Omp8xaN0JGLY6gkRpU=
k8s.io/apimachinery v0.20.4/go.mod h1:WlLqWAHZGg07AeltaI0MV5uk1Omp8xaN0JGLY6gkRpU=
k8s.io/apimachinery v0.20.6/go.mod h1:ejZXtW1Ra6V1O5H8xPBGz+T3+4gfkTCeExAHKU57MAc=
-k8s.io/apimachinery v0.21.0/go.mod h1:jbreFvJo3ov9rj7eWT7+sYiRx+qZuCYXwWT1bcDswPY=
-k8s.io/apimachinery v0.21.1/go.mod h1:jbreFvJo3ov9rj7eWT7+sYiRx+qZuCYXwWT1bcDswPY=
k8s.io/apimachinery v0.22.5 h1:cIPwldOYm1Slq9VLBRPtEYpyhjIm1C6aAMAoENuvN9s=
k8s.io/apimachinery v0.22.5/go.mod h1:xziclGKwuuJ2RM5/rSFQSYAj0zdbci3DH8kj+WvyN0U=
k8s.io/apiserver v0.20.1/go.mod h1:ro5QHeQkgMS7ZGpvf4tSMx6bBOgPfE+f52KwvXfScaU=
k8s.io/apiserver v0.20.4/go.mod h1:Mc80thBKOyy7tbvFtB4kJv1kbdD0eIH8k8vianJcbFM=
k8s.io/apiserver v0.20.6/go.mod h1:QIJXNt6i6JB+0YQRNcS0hdRHJlMhflFmsBDeSgT1r8Q=
-k8s.io/apiserver v0.21.0/go.mod h1:w2YSn4/WIwYuxG5zJmcqtRdtqgW/J2JRgFAqps3bBpg=
k8s.io/apiserver v0.22.5/go.mod h1:s2WbtgZAkTKt679sYtSudEQrTGWUSQAPe6MupLnlmaQ=
k8s.io/client-go v0.20.1/go.mod h1:/zcHdt1TeWSd5HoUe6elJmHSQ6uLLgp4bIJHVEuy+/Y=
k8s.io/client-go v0.20.4/go.mod h1:LiMv25ND1gLUdBeYxBIwKpkSC5IsozMMmOOeSJboP+k=
k8s.io/client-go v0.20.6/go.mod h1:nNQMnOvEUEsOzRRFIIkdmYOjAZrC8bgq0ExboWSU1I0=
-k8s.io/client-go v0.21.0/go.mod h1:nNBytTF9qPFDEhoqgEPaarobC8QPae13bElIVHzIglA=
-k8s.io/client-go v0.21.1/go.mod h1:/kEw4RgW+3xnBGzvp9IWxKSNA+lXn3A7AuH3gdOAzLs=
k8s.io/client-go v0.22.5 h1:I8Zn/UqIdi2r02aZmhaJ1hqMxcpfJ3t5VqvHtctHYFo=
k8s.io/client-go v0.22.5/go.mod h1:cs6yf/61q2T1SdQL5Rdcjg9J1ElXSwbjSrW2vFImM4Y=
-k8s.io/cloud-provider v0.21.0 h1:NSTS+czpv6LQAaIpY/VUghsT4oj62hYmQPErkDKTzKU=
-k8s.io/cloud-provider v0.21.0/go.mod h1:z17TQgu3JgUFjcgby8sj5X86YdVK5Pbt+jm/eYMZU9M=
k8s.io/code-generator v0.22.5 h1:jn+mYXI5q7rzo7Bz/n8xZIgbe61SeXlIjU5jA8jLVps=
k8s.io/code-generator v0.22.5/go.mod h1:sbdWCOVob+KaQ5O7xs8PNNaCTpbWVqNgA6EPwLOmRNk=
k8s.io/component-base v0.20.1/go.mod h1:guxkoJnNoh8LNrbtiQOlyp2Y2XFCZQmrcg2n/DeYNLk=
k8s.io/component-base v0.20.4/go.mod h1:t4p9EdiagbVCJKrQ1RsA5/V4rFQNDfRlevJajlGwgjI=
k8s.io/component-base v0.20.6/go.mod h1:6f1MPBAeI+mvuts3sIdtpjljHWBQ2cIy38oBIWMYnrM=
-k8s.io/component-base v0.21.0/go.mod h1:qvtjz6X0USWXbgmbfXR+Agik4RZ3jv2Bgr5QnZzdPYw=
-k8s.io/component-base v0.22.5 h1:U0eHqZm7mAFE42hFwYhY6ze/MmVaW00JpMrzVsQmzYE=
k8s.io/component-base v0.22.5/go.mod h1:VK3I+TjuF9eaa+Ln67dKxhGar5ynVbwnGrUiNF4MqCI=
-k8s.io/controller-manager v0.21.0/go.mod h1:Ohy0GRNRKPVjB8C8G+dV+4aPn26m8HYUI6ejloUBvUA=
k8s.io/cri-api v0.17.3/go.mod h1:X1sbHmuXhwaHs9xxYffLqJogVsnI+f6cPRcgPel7ywM=
k8s.io/cri-api v0.20.1/go.mod h1:2JRbKt+BFLTjtrILYVqQK5jqhI+XNdF6UiGMgczeBCI=
k8s.io/cri-api v0.20.4/go.mod h1:2JRbKt+BFLTjtrILYVqQK5jqhI+XNdF6UiGMgczeBCI=
k8s.io/cri-api v0.20.6/go.mod h1:ew44AjNXwyn1s0U4xCKGodU7J1HzBeZ1MpGrpa5r8Yc=
-k8s.io/csi-translation-lib v0.21.0/go.mod h1:edq+UMpgqEx3roTuGF/03uIuSOsI986jtu65+ytLlkA=
k8s.io/gengo v0.0.0-20200413195148-3a45101e95ac/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0=
k8s.io/gengo v0.0.0-20201203183100-97869a43a9d9/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
k8s.io/gengo v0.0.0-20201214224949-b6c5ce23f027/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
+k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
k8s.io/gengo v0.0.0-20211129171323-c02415ce4185 h1:TT1WdmqqXareKxZ/oNXEUSwKlLiHzPMyB0t8BaFeBYI=
k8s.io/gengo v0.0.0-20211129171323-c02415ce4185/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
k8s.io/klog v0.2.0/go.mod h1:Gq+BEi5rUBO/HRz0bTSXDUcqjScdoY3a9IHpCEIOOfk=
@@ -1647,20 +1735,20 @@ k8s.io/klog v1.0.0/go.mod h1:4Bi6QPql/J/LkTDqv7R/cd3hPo4k2DG6Ptcz060Ez5I=
k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE=
k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
k8s.io/klog/v2 v2.4.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
-k8s.io/klog/v2 v2.8.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
k8s.io/klog/v2 v2.9.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
+k8s.io/klog/v2 v2.30.0/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
k8s.io/klog/v2 v2.40.1 h1:P4RRucWk/lFOlDdkAr3mc7iWFkgKrZY9qZMAgek06S4=
k8s.io/klog/v2 v2.40.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
k8s.io/kube-openapi v0.0.0-20201113171705-d219536bb9fd/go.mod h1:WOJ3KddDSol4tAGcJo0Tvi+dK12EcqSLqcWsryKMpfM=
-k8s.io/kube-openapi v0.0.0-20210305001622-591a79e4bda7/go.mod h1:wXW5VT87nVfh/iLV8FpR2uDvrFyomxbtb1KivDbvPTE=
-k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c h1:jvamsI1tn9V0S8jicyX82qaFC0H/NKxv2e5mbqsgR80=
k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c/go.mod h1:vHXdDvt9+2spS2Rx9ql3I8tycm3H9FDfdUoIuKCefvw=
+k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65 h1:E3J9oCLlaobFUqsjG9DfKbP2BmgwBL2p7pn0A3dG9W4=
+k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65/go.mod h1:sX9MT8g7NVZM5lVL/j8QyCCJe8YSMW30QvGZWaCIDIk=
k8s.io/kubernetes v1.13.0/go.mod h1:ocZa8+6APFNC2tX1DZASIbocyYT5jHzqFVsY5aoB7Jk=
-k8s.io/legacy-cloud-providers v0.21.0 h1:iWf5xaX9yvYT5mkz8UB96UtISQ5IkrWeuMPMhRp01ZY=
-k8s.io/legacy-cloud-providers v0.21.0/go.mod h1:bNxo7gDg+PGkBmT/MFZswLTWdSWK9kAlS1s8DJca5q4=
k8s.io/utils v0.0.0-20201110183641-67b214c5f920/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
-k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a h1:8dYfu/Fc9Gz2rNJKB9IQRGgQOh2clmRzNIPPY1xLY5g=
+k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
+k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b h1:wxEMGetGMur3J1xuGLQY7GEQYg9bZxKn3tKo5k/eYcs=
+k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931 h1:hyZfmjpW2ZNR2cAJUWaDagcDdcyupozf+7BpN0ApHt8=
knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931/go.mod h1:kHPJyq2W2ADNAwB6lmmJcleEZfNWioIL5yEs/p5WHU0=
knative.dev/hack v0.0.0-20220111151514-59b0cf17578e h1:tESsFI1iMD2Al+6FZueFN9CddxJ8Fa2cd9KmyNINe3w=
@@ -1680,7 +1768,6 @@ sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.15/go.mod h1:LEScyz
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.22/go.mod h1:LEScyzhFmoF5pso/YSeBstl57mOzx9xlU9n85RGrDQg=
sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
sigs.k8s.io/structured-merge-diff/v4 v4.0.3/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
-sigs.k8s.io/structured-merge-diff/v4 v4.1.0/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
sigs.k8s.io/structured-merge-diff/v4 v4.1.2 h1:Hr/htKFmJEbtMgS/UD0N+gtgctAqz81t3nu+sPzynno=
sigs.k8s.io/structured-merge-diff/v4 v4.1.2/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4=
sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o=
diff --git a/test/e2e/grpc_test.go b/test/e2e/grpc_test.go
index 6730081d1835..cab0aa22d8a0 100644
--- a/test/e2e/grpc_test.go
+++ b/test/e2e/grpc_test.go
@@ -35,6 +35,7 @@ import (
"golang.org/x/sync/errgroup"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials"
+ "google.golang.org/grpc/credentials/insecure"
corev1 "k8s.io/api/core/v1"
@@ -81,18 +82,18 @@ func dial(ctx *TestContext, host, domain string) (*grpc.ClientConn, error) {
}
}
- secureOpt := grpc.WithInsecure()
+ creds := insecure.NewCredentials()
if test.ServingFlags.HTTPS {
tlsConfig := test.TLSClientConfig(context.Background(), ctx.t.Logf, ctx.clients)
// Set ServerName for pseudo hostname with TLS.
tlsConfig.ServerName = domain
- secureOpt = grpc.WithTransportCredentials(credentials.NewTLS(tlsConfig))
+ creds = credentials.NewTLS(tlsConfig)
}
return grpc.Dial(
host,
grpc.WithAuthority(domain),
- secureOpt,
+ grpc.WithTransportCredentials(creds),
// Retrying DNS errors to avoid .sslip.io issues.
grpc.WithDefaultCallOptions(grpc.WaitForReady(true)),
)
diff --git a/third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/to/LICENSE b/third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/azure/auth/LICENSE
similarity index 100%
rename from third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/to/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/azure/auth/LICENSE
diff --git a/third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/validation/LICENSE b/third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/azure/cli/LICENSE
similarity index 100%
rename from third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/validation/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/Azure/go-autorest/autorest/azure/cli/LICENSE
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/LICENSE.txt
similarity index 100%
rename from third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go/LICENSE.txt
rename to third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/LICENSE.txt
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go/NOTICE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/NOTICE.txt
similarity index 92%
rename from third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go/NOTICE.txt
rename to third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/NOTICE.txt
index 899129ecc465..5f14d1162ed4 100644
--- a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go/NOTICE.txt
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/NOTICE.txt
@@ -1,3 +1,3 @@
AWS SDK for Go
-Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved.
Copyright 2014-2015 Stripe, Inc.
diff --git a/vendor/github.com/aws/aws-sdk-go/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/config/LICENSE.txt
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/LICENSE.txt
rename to third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/config/LICENSE.txt
diff --git a/third_party/VENDOR-LICENSE/k8s.io/component-base/version/LICENSE b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/credentials/LICENSE.txt
similarity index 100%
rename from third_party/VENDOR-LICENSE/k8s.io/component-base/version/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/credentials/LICENSE.txt
diff --git a/vendor/k8s.io/component-base/LICENSE b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/LICENSE.txt
similarity index 100%
rename from vendor/k8s.io/component-base/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/LICENSE.txt
diff --git a/vendor/k8s.io/legacy-cloud-providers/LICENSE b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/configsources/LICENSE.txt
similarity index 99%
rename from vendor/k8s.io/legacy-cloud-providers/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/configsources/LICENSE.txt
index 8dada3edaf50..d64569567334 100644
--- a/vendor/k8s.io/legacy-cloud-providers/LICENSE
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/configsources/LICENSE.txt
@@ -1,3 +1,4 @@
+
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
@@ -178,7 +179,7 @@
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "{}"
+ boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
@@ -186,7 +187,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
- Copyright {yyyy} {name of copyright owner}
+ Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
diff --git a/vendor/k8s.io/cloud-provider/LICENSE b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/LICENSE.txt
similarity index 99%
rename from vendor/k8s.io/cloud-provider/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/LICENSE.txt
index 8dada3edaf50..d64569567334 100644
--- a/vendor/k8s.io/cloud-provider/LICENSE
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/LICENSE.txt
@@ -1,3 +1,4 @@
+
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
@@ -178,7 +179,7 @@
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "{}"
+ boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
@@ -186,7 +187,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
- Copyright {yyyy} {name of copyright owner}
+ Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/ini/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/ini/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/ini/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go/internal/sync/singleflight/LICENSE b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/sync/singleflight/LICENSE
similarity index 100%
rename from third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go/internal/sync/singleflight/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/internal/sync/singleflight/LICENSE
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/ecr/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/ecr/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/ecr/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/ecrpublic/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/ecrpublic/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/ecrpublic/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/sso/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/sso/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/sso/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/sts/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/sts/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/aws/aws-sdk-go-v2/service/sts/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/smithy-go/LICENSE b/third_party/VENDOR-LICENSE/github.com/aws/smithy-go/LICENSE
new file mode 100644
index 000000000000..67db8588217f
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/aws/smithy-go/LICENSE
@@ -0,0 +1,175 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
diff --git a/third_party/VENDOR-LICENSE/github.com/aws/smithy-go/NOTICE b/third_party/VENDOR-LICENSE/github.com/aws/smithy-go/NOTICE
new file mode 100644
index 000000000000..616fc5889451
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/aws/smithy-go/NOTICE
@@ -0,0 +1 @@
+Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
diff --git a/third_party/VENDOR-LICENSE/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/LICENSE b/third_party/VENDOR-LICENSE/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/LICENSE
new file mode 100644
index 000000000000..bb3f49d69bc7
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/LICENSE
@@ -0,0 +1,51 @@
+Apache License
+
+Version 2.0, January 2004
+
+http://www.apache.org/licenses/
+TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+1. Definitions.
+"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.
+"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.
+"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
+"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.
+"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.
+"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.
+"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).
+"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.
+"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution."
+"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.
+2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.
+3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.
+4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
+1. You must give any other recipients of the Work or Derivative Works a copy of this License; and
+2. You must cause any modified files to carry prominent notices stating that You changed the files; and
+3. You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
+4. If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License.
+
+You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.
+5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.
+6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.
+7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.
+8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.
+9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.
+END OF TERMS AND CONDITIONS
+APPENDIX: How to apply the Apache License to your work
+To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives.
+Copyright [yyyy] [name of copyright owner]
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+***
+
+Note: Other license terms may apply to certain, identified software files contained within or distributed with the accompanying software if such terms are included in the directory containing the accompanying software. Such other license terms will then apply in lieu of the terms of the software license above.
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/LICENSE b/third_party/VENDOR-LICENSE/github.com/chrismellard/docker-credential-acr-env/pkg/LICENSE
similarity index 99%
rename from vendor/github.com/vdemeester/k8s-pkg-credentialprovider/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/chrismellard/docker-credential-acr-env/pkg/LICENSE
index 3de5f349011a..d64569567334 100644
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/LICENSE
+++ b/third_party/VENDOR-LICENSE/github.com/chrismellard/docker-credential-acr-env/pkg/LICENSE
@@ -1,3 +1,4 @@
+
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
@@ -178,7 +179,7 @@
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "{}"
+ boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
@@ -186,7 +187,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
- Copyright 2019-2020 Vincent Demeester
+ Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
diff --git a/third_party/VENDOR-LICENSE/k8s.io/cloud-provider/credentialconfig/LICENSE b/third_party/VENDOR-LICENSE/github.com/dimchansky/utfbom/LICENSE
similarity index 100%
rename from third_party/VENDOR-LICENSE/k8s.io/cloud-provider/credentialconfig/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/dimchansky/utfbom/LICENSE
diff --git a/third_party/VENDOR-LICENSE/github.com/google/go-containerregistry/pkg/authn/kubernetes/LICENSE b/third_party/VENDOR-LICENSE/github.com/google/go-containerregistry/pkg/authn/kubernetes/LICENSE
new file mode 100644
index 000000000000..7a4a3ea2424c
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/google/go-containerregistry/pkg/authn/kubernetes/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
\ No newline at end of file
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/models.go
deleted file mode 100644
index cf551f2a5e17..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/models.go
+++ /dev/null
@@ -1,5139 +0,0 @@
-package containerregistry
-
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is regenerated.
-
-import (
- "context"
- "encoding/json"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/date"
- "github.com/Azure/go-autorest/autorest/to"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// The package's fully qualified name.
-const fqdn = "github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry"
-
-// Action enumerates the values for action.
-type Action string
-
-const (
- // Allow ...
- Allow Action = "Allow"
-)
-
-// PossibleActionValues returns an array of possible values for the Action const type.
-func PossibleActionValues() []Action {
- return []Action{Allow}
-}
-
-// Architecture enumerates the values for architecture.
-type Architecture string
-
-const (
- // Amd64 ...
- Amd64 Architecture = "amd64"
- // Arm ...
- Arm Architecture = "arm"
- // X86 ...
- X86 Architecture = "x86"
-)
-
-// PossibleArchitectureValues returns an array of possible values for the Architecture const type.
-func PossibleArchitectureValues() []Architecture {
- return []Architecture{Amd64, Arm, X86}
-}
-
-// BaseImageDependencyType enumerates the values for base image dependency type.
-type BaseImageDependencyType string
-
-const (
- // BuildTime ...
- BuildTime BaseImageDependencyType = "BuildTime"
- // RunTime ...
- RunTime BaseImageDependencyType = "RunTime"
-)
-
-// PossibleBaseImageDependencyTypeValues returns an array of possible values for the BaseImageDependencyType const type.
-func PossibleBaseImageDependencyTypeValues() []BaseImageDependencyType {
- return []BaseImageDependencyType{BuildTime, RunTime}
-}
-
-// BaseImageTriggerType enumerates the values for base image trigger type.
-type BaseImageTriggerType string
-
-const (
- // All ...
- All BaseImageTriggerType = "All"
- // Runtime ...
- Runtime BaseImageTriggerType = "Runtime"
-)
-
-// PossibleBaseImageTriggerTypeValues returns an array of possible values for the BaseImageTriggerType const type.
-func PossibleBaseImageTriggerTypeValues() []BaseImageTriggerType {
- return []BaseImageTriggerType{All, Runtime}
-}
-
-// DefaultAction enumerates the values for default action.
-type DefaultAction string
-
-const (
- // DefaultActionAllow ...
- DefaultActionAllow DefaultAction = "Allow"
- // DefaultActionDeny ...
- DefaultActionDeny DefaultAction = "Deny"
-)
-
-// PossibleDefaultActionValues returns an array of possible values for the DefaultAction const type.
-func PossibleDefaultActionValues() []DefaultAction {
- return []DefaultAction{DefaultActionAllow, DefaultActionDeny}
-}
-
-// ImportMode enumerates the values for import mode.
-type ImportMode string
-
-const (
- // Force ...
- Force ImportMode = "Force"
- // NoForce ...
- NoForce ImportMode = "NoForce"
-)
-
-// PossibleImportModeValues returns an array of possible values for the ImportMode const type.
-func PossibleImportModeValues() []ImportMode {
- return []ImportMode{Force, NoForce}
-}
-
-// OS enumerates the values for os.
-type OS string
-
-const (
- // Linux ...
- Linux OS = "Linux"
- // Windows ...
- Windows OS = "Windows"
-)
-
-// PossibleOSValues returns an array of possible values for the OS const type.
-func PossibleOSValues() []OS {
- return []OS{Linux, Windows}
-}
-
-// PasswordName enumerates the values for password name.
-type PasswordName string
-
-const (
- // Password ...
- Password PasswordName = "password"
- // Password2 ...
- Password2 PasswordName = "password2"
-)
-
-// PossiblePasswordNameValues returns an array of possible values for the PasswordName const type.
-func PossiblePasswordNameValues() []PasswordName {
- return []PasswordName{Password, Password2}
-}
-
-// PolicyStatus enumerates the values for policy status.
-type PolicyStatus string
-
-const (
- // Disabled ...
- Disabled PolicyStatus = "disabled"
- // Enabled ...
- Enabled PolicyStatus = "enabled"
-)
-
-// PossiblePolicyStatusValues returns an array of possible values for the PolicyStatus const type.
-func PossiblePolicyStatusValues() []PolicyStatus {
- return []PolicyStatus{Disabled, Enabled}
-}
-
-// ProvisioningState enumerates the values for provisioning state.
-type ProvisioningState string
-
-const (
- // Canceled ...
- Canceled ProvisioningState = "Canceled"
- // Creating ...
- Creating ProvisioningState = "Creating"
- // Deleting ...
- Deleting ProvisioningState = "Deleting"
- // Failed ...
- Failed ProvisioningState = "Failed"
- // Succeeded ...
- Succeeded ProvisioningState = "Succeeded"
- // Updating ...
- Updating ProvisioningState = "Updating"
-)
-
-// PossibleProvisioningStateValues returns an array of possible values for the ProvisioningState const type.
-func PossibleProvisioningStateValues() []ProvisioningState {
- return []ProvisioningState{Canceled, Creating, Deleting, Failed, Succeeded, Updating}
-}
-
-// RegistryUsageUnit enumerates the values for registry usage unit.
-type RegistryUsageUnit string
-
-const (
- // Bytes ...
- Bytes RegistryUsageUnit = "Bytes"
- // Count ...
- Count RegistryUsageUnit = "Count"
-)
-
-// PossibleRegistryUsageUnitValues returns an array of possible values for the RegistryUsageUnit const type.
-func PossibleRegistryUsageUnitValues() []RegistryUsageUnit {
- return []RegistryUsageUnit{Bytes, Count}
-}
-
-// ResourceIdentityType enumerates the values for resource identity type.
-type ResourceIdentityType string
-
-const (
- // None ...
- None ResourceIdentityType = "None"
- // SystemAssigned ...
- SystemAssigned ResourceIdentityType = "SystemAssigned"
- // SystemAssignedUserAssigned ...
- SystemAssignedUserAssigned ResourceIdentityType = "SystemAssigned, UserAssigned"
- // UserAssigned ...
- UserAssigned ResourceIdentityType = "UserAssigned"
-)
-
-// PossibleResourceIdentityTypeValues returns an array of possible values for the ResourceIdentityType const type.
-func PossibleResourceIdentityTypeValues() []ResourceIdentityType {
- return []ResourceIdentityType{None, SystemAssigned, SystemAssignedUserAssigned, UserAssigned}
-}
-
-// RunStatus enumerates the values for run status.
-type RunStatus string
-
-const (
- // RunStatusCanceled ...
- RunStatusCanceled RunStatus = "Canceled"
- // RunStatusError ...
- RunStatusError RunStatus = "Error"
- // RunStatusFailed ...
- RunStatusFailed RunStatus = "Failed"
- // RunStatusQueued ...
- RunStatusQueued RunStatus = "Queued"
- // RunStatusRunning ...
- RunStatusRunning RunStatus = "Running"
- // RunStatusStarted ...
- RunStatusStarted RunStatus = "Started"
- // RunStatusSucceeded ...
- RunStatusSucceeded RunStatus = "Succeeded"
- // RunStatusTimeout ...
- RunStatusTimeout RunStatus = "Timeout"
-)
-
-// PossibleRunStatusValues returns an array of possible values for the RunStatus const type.
-func PossibleRunStatusValues() []RunStatus {
- return []RunStatus{RunStatusCanceled, RunStatusError, RunStatusFailed, RunStatusQueued, RunStatusRunning, RunStatusStarted, RunStatusSucceeded, RunStatusTimeout}
-}
-
-// RunType enumerates the values for run type.
-type RunType string
-
-const (
- // AutoBuild ...
- AutoBuild RunType = "AutoBuild"
- // AutoRun ...
- AutoRun RunType = "AutoRun"
- // QuickBuild ...
- QuickBuild RunType = "QuickBuild"
- // QuickRun ...
- QuickRun RunType = "QuickRun"
-)
-
-// PossibleRunTypeValues returns an array of possible values for the RunType const type.
-func PossibleRunTypeValues() []RunType {
- return []RunType{AutoBuild, AutoRun, QuickBuild, QuickRun}
-}
-
-// SecretObjectType enumerates the values for secret object type.
-type SecretObjectType string
-
-const (
- // Opaque ...
- Opaque SecretObjectType = "Opaque"
- // Vaultsecret ...
- Vaultsecret SecretObjectType = "Vaultsecret"
-)
-
-// PossibleSecretObjectTypeValues returns an array of possible values for the SecretObjectType const type.
-func PossibleSecretObjectTypeValues() []SecretObjectType {
- return []SecretObjectType{Opaque, Vaultsecret}
-}
-
-// SkuName enumerates the values for sku name.
-type SkuName string
-
-const (
- // Basic ...
- Basic SkuName = "Basic"
- // Classic ...
- Classic SkuName = "Classic"
- // Premium ...
- Premium SkuName = "Premium"
- // Standard ...
- Standard SkuName = "Standard"
-)
-
-// PossibleSkuNameValues returns an array of possible values for the SkuName const type.
-func PossibleSkuNameValues() []SkuName {
- return []SkuName{Basic, Classic, Premium, Standard}
-}
-
-// SkuTier enumerates the values for sku tier.
-type SkuTier string
-
-const (
- // SkuTierBasic ...
- SkuTierBasic SkuTier = "Basic"
- // SkuTierClassic ...
- SkuTierClassic SkuTier = "Classic"
- // SkuTierPremium ...
- SkuTierPremium SkuTier = "Premium"
- // SkuTierStandard ...
- SkuTierStandard SkuTier = "Standard"
-)
-
-// PossibleSkuTierValues returns an array of possible values for the SkuTier const type.
-func PossibleSkuTierValues() []SkuTier {
- return []SkuTier{SkuTierBasic, SkuTierClassic, SkuTierPremium, SkuTierStandard}
-}
-
-// SourceControlType enumerates the values for source control type.
-type SourceControlType string
-
-const (
- // Github ...
- Github SourceControlType = "Github"
- // VisualStudioTeamService ...
- VisualStudioTeamService SourceControlType = "VisualStudioTeamService"
-)
-
-// PossibleSourceControlTypeValues returns an array of possible values for the SourceControlType const type.
-func PossibleSourceControlTypeValues() []SourceControlType {
- return []SourceControlType{Github, VisualStudioTeamService}
-}
-
-// SourceRegistryLoginMode enumerates the values for source registry login mode.
-type SourceRegistryLoginMode string
-
-const (
- // SourceRegistryLoginModeDefault ...
- SourceRegistryLoginModeDefault SourceRegistryLoginMode = "Default"
- // SourceRegistryLoginModeNone ...
- SourceRegistryLoginModeNone SourceRegistryLoginMode = "None"
-)
-
-// PossibleSourceRegistryLoginModeValues returns an array of possible values for the SourceRegistryLoginMode const type.
-func PossibleSourceRegistryLoginModeValues() []SourceRegistryLoginMode {
- return []SourceRegistryLoginMode{SourceRegistryLoginModeDefault, SourceRegistryLoginModeNone}
-}
-
-// SourceTriggerEvent enumerates the values for source trigger event.
-type SourceTriggerEvent string
-
-const (
- // Commit ...
- Commit SourceTriggerEvent = "commit"
- // Pullrequest ...
- Pullrequest SourceTriggerEvent = "pullrequest"
-)
-
-// PossibleSourceTriggerEventValues returns an array of possible values for the SourceTriggerEvent const type.
-func PossibleSourceTriggerEventValues() []SourceTriggerEvent {
- return []SourceTriggerEvent{Commit, Pullrequest}
-}
-
-// TaskStatus enumerates the values for task status.
-type TaskStatus string
-
-const (
- // TaskStatusDisabled ...
- TaskStatusDisabled TaskStatus = "Disabled"
- // TaskStatusEnabled ...
- TaskStatusEnabled TaskStatus = "Enabled"
-)
-
-// PossibleTaskStatusValues returns an array of possible values for the TaskStatus const type.
-func PossibleTaskStatusValues() []TaskStatus {
- return []TaskStatus{TaskStatusDisabled, TaskStatusEnabled}
-}
-
-// TokenType enumerates the values for token type.
-type TokenType string
-
-const (
- // OAuth ...
- OAuth TokenType = "OAuth"
- // PAT ...
- PAT TokenType = "PAT"
-)
-
-// PossibleTokenTypeValues returns an array of possible values for the TokenType const type.
-func PossibleTokenTypeValues() []TokenType {
- return []TokenType{OAuth, PAT}
-}
-
-// TriggerStatus enumerates the values for trigger status.
-type TriggerStatus string
-
-const (
- // TriggerStatusDisabled ...
- TriggerStatusDisabled TriggerStatus = "Disabled"
- // TriggerStatusEnabled ...
- TriggerStatusEnabled TriggerStatus = "Enabled"
-)
-
-// PossibleTriggerStatusValues returns an array of possible values for the TriggerStatus const type.
-func PossibleTriggerStatusValues() []TriggerStatus {
- return []TriggerStatus{TriggerStatusDisabled, TriggerStatusEnabled}
-}
-
-// TrustPolicyType enumerates the values for trust policy type.
-type TrustPolicyType string
-
-const (
- // Notary ...
- Notary TrustPolicyType = "Notary"
-)
-
-// PossibleTrustPolicyTypeValues returns an array of possible values for the TrustPolicyType const type.
-func PossibleTrustPolicyTypeValues() []TrustPolicyType {
- return []TrustPolicyType{Notary}
-}
-
-// Type enumerates the values for type.
-type Type string
-
-const (
- // TypeDockerBuildRequest ...
- TypeDockerBuildRequest Type = "DockerBuildRequest"
- // TypeEncodedTaskRunRequest ...
- TypeEncodedTaskRunRequest Type = "EncodedTaskRunRequest"
- // TypeFileTaskRunRequest ...
- TypeFileTaskRunRequest Type = "FileTaskRunRequest"
- // TypeRunRequest ...
- TypeRunRequest Type = "RunRequest"
- // TypeTaskRunRequest ...
- TypeTaskRunRequest Type = "TaskRunRequest"
-)
-
-// PossibleTypeValues returns an array of possible values for the Type const type.
-func PossibleTypeValues() []Type {
- return []Type{TypeDockerBuildRequest, TypeEncodedTaskRunRequest, TypeFileTaskRunRequest, TypeRunRequest, TypeTaskRunRequest}
-}
-
-// TypeBasicTaskStepProperties enumerates the values for type basic task step properties.
-type TypeBasicTaskStepProperties string
-
-const (
- // TypeDocker ...
- TypeDocker TypeBasicTaskStepProperties = "Docker"
- // TypeEncodedTask ...
- TypeEncodedTask TypeBasicTaskStepProperties = "EncodedTask"
- // TypeFileTask ...
- TypeFileTask TypeBasicTaskStepProperties = "FileTask"
- // TypeTaskStepProperties ...
- TypeTaskStepProperties TypeBasicTaskStepProperties = "TaskStepProperties"
-)
-
-// PossibleTypeBasicTaskStepPropertiesValues returns an array of possible values for the TypeBasicTaskStepProperties const type.
-func PossibleTypeBasicTaskStepPropertiesValues() []TypeBasicTaskStepProperties {
- return []TypeBasicTaskStepProperties{TypeDocker, TypeEncodedTask, TypeFileTask, TypeTaskStepProperties}
-}
-
-// TypeBasicTaskStepUpdateParameters enumerates the values for type basic task step update parameters.
-type TypeBasicTaskStepUpdateParameters string
-
-const (
- // TypeBasicTaskStepUpdateParametersTypeDocker ...
- TypeBasicTaskStepUpdateParametersTypeDocker TypeBasicTaskStepUpdateParameters = "Docker"
- // TypeBasicTaskStepUpdateParametersTypeEncodedTask ...
- TypeBasicTaskStepUpdateParametersTypeEncodedTask TypeBasicTaskStepUpdateParameters = "EncodedTask"
- // TypeBasicTaskStepUpdateParametersTypeFileTask ...
- TypeBasicTaskStepUpdateParametersTypeFileTask TypeBasicTaskStepUpdateParameters = "FileTask"
- // TypeBasicTaskStepUpdateParametersTypeTaskStepUpdateParameters ...
- TypeBasicTaskStepUpdateParametersTypeTaskStepUpdateParameters TypeBasicTaskStepUpdateParameters = "TaskStepUpdateParameters"
-)
-
-// PossibleTypeBasicTaskStepUpdateParametersValues returns an array of possible values for the TypeBasicTaskStepUpdateParameters const type.
-func PossibleTypeBasicTaskStepUpdateParametersValues() []TypeBasicTaskStepUpdateParameters {
- return []TypeBasicTaskStepUpdateParameters{TypeBasicTaskStepUpdateParametersTypeDocker, TypeBasicTaskStepUpdateParametersTypeEncodedTask, TypeBasicTaskStepUpdateParametersTypeFileTask, TypeBasicTaskStepUpdateParametersTypeTaskStepUpdateParameters}
-}
-
-// Variant enumerates the values for variant.
-type Variant string
-
-const (
- // V6 ...
- V6 Variant = "v6"
- // V7 ...
- V7 Variant = "v7"
- // V8 ...
- V8 Variant = "v8"
-)
-
-// PossibleVariantValues returns an array of possible values for the Variant const type.
-func PossibleVariantValues() []Variant {
- return []Variant{V6, V7, V8}
-}
-
-// WebhookAction enumerates the values for webhook action.
-type WebhookAction string
-
-const (
- // ChartDelete ...
- ChartDelete WebhookAction = "chart_delete"
- // ChartPush ...
- ChartPush WebhookAction = "chart_push"
- // Delete ...
- Delete WebhookAction = "delete"
- // Push ...
- Push WebhookAction = "push"
- // Quarantine ...
- Quarantine WebhookAction = "quarantine"
-)
-
-// PossibleWebhookActionValues returns an array of possible values for the WebhookAction const type.
-func PossibleWebhookActionValues() []WebhookAction {
- return []WebhookAction{ChartDelete, ChartPush, Delete, Push, Quarantine}
-}
-
-// WebhookStatus enumerates the values for webhook status.
-type WebhookStatus string
-
-const (
- // WebhookStatusDisabled ...
- WebhookStatusDisabled WebhookStatus = "disabled"
- // WebhookStatusEnabled ...
- WebhookStatusEnabled WebhookStatus = "enabled"
-)
-
-// PossibleWebhookStatusValues returns an array of possible values for the WebhookStatus const type.
-func PossibleWebhookStatusValues() []WebhookStatus {
- return []WebhookStatus{WebhookStatusDisabled, WebhookStatusEnabled}
-}
-
-// Actor the agent that initiated the event. For most situations, this could be from the authorization
-// context of the request.
-type Actor struct {
- // Name - The subject or username associated with the request context that generated the event.
- Name *string `json:"name,omitempty"`
-}
-
-// AgentProperties the properties that determine the run agent configuration.
-type AgentProperties struct {
- // CPU - The CPU configuration in terms of number of cores required for the run.
- CPU *int32 `json:"cpu,omitempty"`
-}
-
-// Argument the properties of a run argument.
-type Argument struct {
- // Name - The name of the argument.
- Name *string `json:"name,omitempty"`
- // Value - The value of the argument.
- Value *string `json:"value,omitempty"`
- // IsSecret - Flag to indicate whether the argument represents a secret and want to be removed from build logs.
- IsSecret *bool `json:"isSecret,omitempty"`
-}
-
-// AuthInfo the authorization properties for accessing the source code repository.
-type AuthInfo struct {
- // TokenType - The type of Auth token. Possible values include: 'PAT', 'OAuth'
- TokenType TokenType `json:"tokenType,omitempty"`
- // Token - The access token used to access the source control provider.
- Token *string `json:"token,omitempty"`
- // RefreshToken - The refresh token used to refresh the access token.
- RefreshToken *string `json:"refreshToken,omitempty"`
- // Scope - The scope of the access token.
- Scope *string `json:"scope,omitempty"`
- // ExpiresIn - Time in seconds that the token remains valid
- ExpiresIn *int32 `json:"expiresIn,omitempty"`
-}
-
-// AuthInfoUpdateParameters the authorization properties for accessing the source code repository.
-type AuthInfoUpdateParameters struct {
- // TokenType - The type of Auth token. Possible values include: 'PAT', 'OAuth'
- TokenType TokenType `json:"tokenType,omitempty"`
- // Token - The access token used to access the source control provider.
- Token *string `json:"token,omitempty"`
- // RefreshToken - The refresh token used to refresh the access token.
- RefreshToken *string `json:"refreshToken,omitempty"`
- // Scope - The scope of the access token.
- Scope *string `json:"scope,omitempty"`
- // ExpiresIn - Time in seconds that the token remains valid
- ExpiresIn *int32 `json:"expiresIn,omitempty"`
-}
-
-// BaseImageDependency properties that describe a base image dependency.
-type BaseImageDependency struct {
- // Type - The type of the base image dependency. Possible values include: 'BuildTime', 'RunTime'
- Type BaseImageDependencyType `json:"type,omitempty"`
- // Registry - The registry login server.
- Registry *string `json:"registry,omitempty"`
- // Repository - The repository name.
- Repository *string `json:"repository,omitempty"`
- // Tag - The tag name.
- Tag *string `json:"tag,omitempty"`
- // Digest - The sha256-based digest of the image manifest.
- Digest *string `json:"digest,omitempty"`
-}
-
-// BaseImageTrigger the trigger based on base image dependency.
-type BaseImageTrigger struct {
- // BaseImageTriggerType - The type of the auto trigger for base image dependency updates. Possible values include: 'All', 'Runtime'
- BaseImageTriggerType BaseImageTriggerType `json:"baseImageTriggerType,omitempty"`
- // Status - The current status of trigger. Possible values include: 'TriggerStatusDisabled', 'TriggerStatusEnabled'
- Status TriggerStatus `json:"status,omitempty"`
- // Name - The name of the trigger.
- Name *string `json:"name,omitempty"`
-}
-
-// BaseImageTriggerUpdateParameters the properties for updating base image dependency trigger.
-type BaseImageTriggerUpdateParameters struct {
- // BaseImageTriggerType - The type of the auto trigger for base image dependency updates. Possible values include: 'All', 'Runtime'
- BaseImageTriggerType BaseImageTriggerType `json:"baseImageTriggerType,omitempty"`
- // Status - The current status of trigger. Possible values include: 'TriggerStatusDisabled', 'TriggerStatusEnabled'
- Status TriggerStatus `json:"status,omitempty"`
- // Name - The name of the trigger.
- Name *string `json:"name,omitempty"`
-}
-
-// CallbackConfig the configuration of service URI and custom headers for the webhook.
-type CallbackConfig struct {
- autorest.Response `json:"-"`
- // ServiceURI - The service URI for the webhook to post notifications.
- ServiceURI *string `json:"serviceUri,omitempty"`
- // CustomHeaders - Custom headers that will be added to the webhook notifications.
- CustomHeaders map[string]*string `json:"customHeaders"`
-}
-
-// MarshalJSON is the custom marshaler for CallbackConfig.
-func (cc CallbackConfig) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if cc.ServiceURI != nil {
- objectMap["serviceUri"] = cc.ServiceURI
- }
- if cc.CustomHeaders != nil {
- objectMap["customHeaders"] = cc.CustomHeaders
- }
- return json.Marshal(objectMap)
-}
-
-// Credentials the parameters that describes a set of credentials that will be used when a run is invoked.
-type Credentials struct {
- // SourceRegistry - Describes the credential parameters for accessing the source registry.
- SourceRegistry *SourceRegistryCredentials `json:"sourceRegistry,omitempty"`
- // CustomRegistries - Describes the credential parameters for accessing other custom registries. The key
- // for the dictionary item will be the registry login server (myregistry.azurecr.io) and
- // the value of the item will be the registry credentials for accessing the registry.
- CustomRegistries map[string]*CustomRegistryCredentials `json:"customRegistries"`
-}
-
-// MarshalJSON is the custom marshaler for Credentials.
-func (c Credentials) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if c.SourceRegistry != nil {
- objectMap["sourceRegistry"] = c.SourceRegistry
- }
- if c.CustomRegistries != nil {
- objectMap["customRegistries"] = c.CustomRegistries
- }
- return json.Marshal(objectMap)
-}
-
-// CustomRegistryCredentials describes the credentials that will be used to access a custom registry during
-// a run.
-type CustomRegistryCredentials struct {
- // UserName - The username for logging into the custom registry.
- UserName *SecretObject `json:"userName,omitempty"`
- // Password - The password for logging into the custom registry. The password is a secret
- // object that allows multiple ways of providing the value for it.
- Password *SecretObject `json:"password,omitempty"`
- // Identity - Indicates the managed identity assigned to the custom credential. If a user-assigned identity
- // this value is the Client ID. If a system-assigned identity, the value will be `system`. In
- // the case of a system-assigned identity, the Client ID will be determined by the runner. This
- // identity may be used to authenticate to key vault to retrieve credentials or it may be the only
- // source of authentication used for accessing the registry.
- Identity *string `json:"identity,omitempty"`
-}
-
-// DockerBuildRequest the parameters for a docker quick build.
-type DockerBuildRequest struct {
- // ImageNames - The fully qualified image names including the repository and tag.
- ImageNames *[]string `json:"imageNames,omitempty"`
- // IsPushEnabled - The value of this property indicates whether the image built should be pushed to the registry or not.
- IsPushEnabled *bool `json:"isPushEnabled,omitempty"`
- // NoCache - The value of this property indicates whether the image cache is enabled or not.
- NoCache *bool `json:"noCache,omitempty"`
- // DockerFilePath - The Docker file path relative to the source location.
- DockerFilePath *string `json:"dockerFilePath,omitempty"`
- // Target - The name of the target build stage for the docker build.
- Target *string `json:"target,omitempty"`
- // Arguments - The collection of override arguments to be used when executing the run.
- Arguments *[]Argument `json:"arguments,omitempty"`
- // Timeout - Run timeout in seconds.
- Timeout *int32 `json:"timeout,omitempty"`
- // Platform - The platform properties against which the run has to happen.
- Platform *PlatformProperties `json:"platform,omitempty"`
- // AgentConfiguration - The machine configuration of the run agent.
- AgentConfiguration *AgentProperties `json:"agentConfiguration,omitempty"`
- // SourceLocation - The URL(absolute or relative) of the source context. It can be an URL to a tar or git repository.
- // If it is relative URL, the relative path should be obtained from calling listBuildSourceUploadUrl API.
- SourceLocation *string `json:"sourceLocation,omitempty"`
- // Credentials - The properties that describes a set of credentials that will be used when this run is invoked.
- Credentials *Credentials `json:"credentials,omitempty"`
- // IsArchiveEnabled - The value that indicates whether archiving is enabled for the run or not.
- IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
- // Type - Possible values include: 'TypeRunRequest', 'TypeDockerBuildRequest', 'TypeFileTaskRunRequest', 'TypeTaskRunRequest', 'TypeEncodedTaskRunRequest'
- Type Type `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for DockerBuildRequest.
-func (dbr DockerBuildRequest) MarshalJSON() ([]byte, error) {
- dbr.Type = TypeDockerBuildRequest
- objectMap := make(map[string]interface{})
- if dbr.ImageNames != nil {
- objectMap["imageNames"] = dbr.ImageNames
- }
- if dbr.IsPushEnabled != nil {
- objectMap["isPushEnabled"] = dbr.IsPushEnabled
- }
- if dbr.NoCache != nil {
- objectMap["noCache"] = dbr.NoCache
- }
- if dbr.DockerFilePath != nil {
- objectMap["dockerFilePath"] = dbr.DockerFilePath
- }
- if dbr.Target != nil {
- objectMap["target"] = dbr.Target
- }
- if dbr.Arguments != nil {
- objectMap["arguments"] = dbr.Arguments
- }
- if dbr.Timeout != nil {
- objectMap["timeout"] = dbr.Timeout
- }
- if dbr.Platform != nil {
- objectMap["platform"] = dbr.Platform
- }
- if dbr.AgentConfiguration != nil {
- objectMap["agentConfiguration"] = dbr.AgentConfiguration
- }
- if dbr.SourceLocation != nil {
- objectMap["sourceLocation"] = dbr.SourceLocation
- }
- if dbr.Credentials != nil {
- objectMap["credentials"] = dbr.Credentials
- }
- if dbr.IsArchiveEnabled != nil {
- objectMap["isArchiveEnabled"] = dbr.IsArchiveEnabled
- }
- if dbr.Type != "" {
- objectMap["type"] = dbr.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildRequest is the BasicRunRequest implementation for DockerBuildRequest.
-func (dbr DockerBuildRequest) AsDockerBuildRequest() (*DockerBuildRequest, bool) {
- return &dbr, true
-}
-
-// AsFileTaskRunRequest is the BasicRunRequest implementation for DockerBuildRequest.
-func (dbr DockerBuildRequest) AsFileTaskRunRequest() (*FileTaskRunRequest, bool) {
- return nil, false
-}
-
-// AsTaskRunRequest is the BasicRunRequest implementation for DockerBuildRequest.
-func (dbr DockerBuildRequest) AsTaskRunRequest() (*TaskRunRequest, bool) {
- return nil, false
-}
-
-// AsEncodedTaskRunRequest is the BasicRunRequest implementation for DockerBuildRequest.
-func (dbr DockerBuildRequest) AsEncodedTaskRunRequest() (*EncodedTaskRunRequest, bool) {
- return nil, false
-}
-
-// AsRunRequest is the BasicRunRequest implementation for DockerBuildRequest.
-func (dbr DockerBuildRequest) AsRunRequest() (*RunRequest, bool) {
- return nil, false
-}
-
-// AsBasicRunRequest is the BasicRunRequest implementation for DockerBuildRequest.
-func (dbr DockerBuildRequest) AsBasicRunRequest() (BasicRunRequest, bool) {
- return &dbr, true
-}
-
-// DockerBuildStep the Docker build step.
-type DockerBuildStep struct {
- // ImageNames - The fully qualified image names including the repository and tag.
- ImageNames *[]string `json:"imageNames,omitempty"`
- // IsPushEnabled - The value of this property indicates whether the image built should be pushed to the registry or not.
- IsPushEnabled *bool `json:"isPushEnabled,omitempty"`
- // NoCache - The value of this property indicates whether the image cache is enabled or not.
- NoCache *bool `json:"noCache,omitempty"`
- // DockerFilePath - The Docker file path relative to the source context.
- DockerFilePath *string `json:"dockerFilePath,omitempty"`
- // Target - The name of the target build stage for the docker build.
- Target *string `json:"target,omitempty"`
- // Arguments - The collection of override arguments to be used when executing this build step.
- Arguments *[]Argument `json:"arguments,omitempty"`
- // BaseImageDependencies - READ-ONLY; List of base image dependencies for a step.
- BaseImageDependencies *[]BaseImageDependency `json:"baseImageDependencies,omitempty"`
- // ContextPath - The URL(absolute or relative) of the source context for the task step.
- ContextPath *string `json:"contextPath,omitempty"`
- // ContextAccessToken - The token (git PAT or SAS token of storage account blob) associated with the context for a step.
- ContextAccessToken *string `json:"contextAccessToken,omitempty"`
- // Type - Possible values include: 'TypeTaskStepProperties', 'TypeDocker', 'TypeFileTask', 'TypeEncodedTask'
- Type TypeBasicTaskStepProperties `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for DockerBuildStep.
-func (dbs DockerBuildStep) MarshalJSON() ([]byte, error) {
- dbs.Type = TypeDocker
- objectMap := make(map[string]interface{})
- if dbs.ImageNames != nil {
- objectMap["imageNames"] = dbs.ImageNames
- }
- if dbs.IsPushEnabled != nil {
- objectMap["isPushEnabled"] = dbs.IsPushEnabled
- }
- if dbs.NoCache != nil {
- objectMap["noCache"] = dbs.NoCache
- }
- if dbs.DockerFilePath != nil {
- objectMap["dockerFilePath"] = dbs.DockerFilePath
- }
- if dbs.Target != nil {
- objectMap["target"] = dbs.Target
- }
- if dbs.Arguments != nil {
- objectMap["arguments"] = dbs.Arguments
- }
- if dbs.ContextPath != nil {
- objectMap["contextPath"] = dbs.ContextPath
- }
- if dbs.ContextAccessToken != nil {
- objectMap["contextAccessToken"] = dbs.ContextAccessToken
- }
- if dbs.Type != "" {
- objectMap["type"] = dbs.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildStep is the BasicTaskStepProperties implementation for DockerBuildStep.
-func (dbs DockerBuildStep) AsDockerBuildStep() (*DockerBuildStep, bool) {
- return &dbs, true
-}
-
-// AsFileTaskStep is the BasicTaskStepProperties implementation for DockerBuildStep.
-func (dbs DockerBuildStep) AsFileTaskStep() (*FileTaskStep, bool) {
- return nil, false
-}
-
-// AsEncodedTaskStep is the BasicTaskStepProperties implementation for DockerBuildStep.
-func (dbs DockerBuildStep) AsEncodedTaskStep() (*EncodedTaskStep, bool) {
- return nil, false
-}
-
-// AsTaskStepProperties is the BasicTaskStepProperties implementation for DockerBuildStep.
-func (dbs DockerBuildStep) AsTaskStepProperties() (*TaskStepProperties, bool) {
- return nil, false
-}
-
-// AsBasicTaskStepProperties is the BasicTaskStepProperties implementation for DockerBuildStep.
-func (dbs DockerBuildStep) AsBasicTaskStepProperties() (BasicTaskStepProperties, bool) {
- return &dbs, true
-}
-
-// DockerBuildStepUpdateParameters the properties for updating a docker build step.
-type DockerBuildStepUpdateParameters struct {
- // ImageNames - The fully qualified image names including the repository and tag.
- ImageNames *[]string `json:"imageNames,omitempty"`
- // IsPushEnabled - The value of this property indicates whether the image built should be pushed to the registry or not.
- IsPushEnabled *bool `json:"isPushEnabled,omitempty"`
- // NoCache - The value of this property indicates whether the image cache is enabled or not.
- NoCache *bool `json:"noCache,omitempty"`
- // DockerFilePath - The Docker file path relative to the source context.
- DockerFilePath *string `json:"dockerFilePath,omitempty"`
- // Arguments - The collection of override arguments to be used when executing this build step.
- Arguments *[]Argument `json:"arguments,omitempty"`
- // Target - The name of the target build stage for the docker build.
- Target *string `json:"target,omitempty"`
- // ContextPath - The URL(absolute or relative) of the source context for the task step.
- ContextPath *string `json:"contextPath,omitempty"`
- // ContextAccessToken - The token (git PAT or SAS token of storage account blob) associated with the context for a step.
- ContextAccessToken *string `json:"contextAccessToken,omitempty"`
- // Type - Possible values include: 'TypeBasicTaskStepUpdateParametersTypeTaskStepUpdateParameters', 'TypeBasicTaskStepUpdateParametersTypeDocker', 'TypeBasicTaskStepUpdateParametersTypeFileTask', 'TypeBasicTaskStepUpdateParametersTypeEncodedTask'
- Type TypeBasicTaskStepUpdateParameters `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for DockerBuildStepUpdateParameters.
-func (dbsup DockerBuildStepUpdateParameters) MarshalJSON() ([]byte, error) {
- dbsup.Type = TypeBasicTaskStepUpdateParametersTypeDocker
- objectMap := make(map[string]interface{})
- if dbsup.ImageNames != nil {
- objectMap["imageNames"] = dbsup.ImageNames
- }
- if dbsup.IsPushEnabled != nil {
- objectMap["isPushEnabled"] = dbsup.IsPushEnabled
- }
- if dbsup.NoCache != nil {
- objectMap["noCache"] = dbsup.NoCache
- }
- if dbsup.DockerFilePath != nil {
- objectMap["dockerFilePath"] = dbsup.DockerFilePath
- }
- if dbsup.Arguments != nil {
- objectMap["arguments"] = dbsup.Arguments
- }
- if dbsup.Target != nil {
- objectMap["target"] = dbsup.Target
- }
- if dbsup.ContextPath != nil {
- objectMap["contextPath"] = dbsup.ContextPath
- }
- if dbsup.ContextAccessToken != nil {
- objectMap["contextAccessToken"] = dbsup.ContextAccessToken
- }
- if dbsup.Type != "" {
- objectMap["type"] = dbsup.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for DockerBuildStepUpdateParameters.
-func (dbsup DockerBuildStepUpdateParameters) AsDockerBuildStepUpdateParameters() (*DockerBuildStepUpdateParameters, bool) {
- return &dbsup, true
-}
-
-// AsFileTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for DockerBuildStepUpdateParameters.
-func (dbsup DockerBuildStepUpdateParameters) AsFileTaskStepUpdateParameters() (*FileTaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsEncodedTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for DockerBuildStepUpdateParameters.
-func (dbsup DockerBuildStepUpdateParameters) AsEncodedTaskStepUpdateParameters() (*EncodedTaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for DockerBuildStepUpdateParameters.
-func (dbsup DockerBuildStepUpdateParameters) AsTaskStepUpdateParameters() (*TaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsBasicTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for DockerBuildStepUpdateParameters.
-func (dbsup DockerBuildStepUpdateParameters) AsBasicTaskStepUpdateParameters() (BasicTaskStepUpdateParameters, bool) {
- return &dbsup, true
-}
-
-// EncodedTaskRunRequest the parameters for a quick task run request.
-type EncodedTaskRunRequest struct {
- // EncodedTaskContent - Base64 encoded value of the template/definition file content.
- EncodedTaskContent *string `json:"encodedTaskContent,omitempty"`
- // EncodedValuesContent - Base64 encoded value of the parameters/values file content.
- EncodedValuesContent *string `json:"encodedValuesContent,omitempty"`
- // Values - The collection of overridable values that can be passed when running a task.
- Values *[]SetValue `json:"values,omitempty"`
- // Timeout - Run timeout in seconds.
- Timeout *int32 `json:"timeout,omitempty"`
- // Platform - The platform properties against which the run has to happen.
- Platform *PlatformProperties `json:"platform,omitempty"`
- // AgentConfiguration - The machine configuration of the run agent.
- AgentConfiguration *AgentProperties `json:"agentConfiguration,omitempty"`
- // SourceLocation - The URL(absolute or relative) of the source context. It can be an URL to a tar or git repository.
- // If it is relative URL, the relative path should be obtained from calling listBuildSourceUploadUrl API.
- SourceLocation *string `json:"sourceLocation,omitempty"`
- // Credentials - The properties that describes a set of credentials that will be used when this run is invoked.
- Credentials *Credentials `json:"credentials,omitempty"`
- // IsArchiveEnabled - The value that indicates whether archiving is enabled for the run or not.
- IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
- // Type - Possible values include: 'TypeRunRequest', 'TypeDockerBuildRequest', 'TypeFileTaskRunRequest', 'TypeTaskRunRequest', 'TypeEncodedTaskRunRequest'
- Type Type `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for EncodedTaskRunRequest.
-func (etrr EncodedTaskRunRequest) MarshalJSON() ([]byte, error) {
- etrr.Type = TypeEncodedTaskRunRequest
- objectMap := make(map[string]interface{})
- if etrr.EncodedTaskContent != nil {
- objectMap["encodedTaskContent"] = etrr.EncodedTaskContent
- }
- if etrr.EncodedValuesContent != nil {
- objectMap["encodedValuesContent"] = etrr.EncodedValuesContent
- }
- if etrr.Values != nil {
- objectMap["values"] = etrr.Values
- }
- if etrr.Timeout != nil {
- objectMap["timeout"] = etrr.Timeout
- }
- if etrr.Platform != nil {
- objectMap["platform"] = etrr.Platform
- }
- if etrr.AgentConfiguration != nil {
- objectMap["agentConfiguration"] = etrr.AgentConfiguration
- }
- if etrr.SourceLocation != nil {
- objectMap["sourceLocation"] = etrr.SourceLocation
- }
- if etrr.Credentials != nil {
- objectMap["credentials"] = etrr.Credentials
- }
- if etrr.IsArchiveEnabled != nil {
- objectMap["isArchiveEnabled"] = etrr.IsArchiveEnabled
- }
- if etrr.Type != "" {
- objectMap["type"] = etrr.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildRequest is the BasicRunRequest implementation for EncodedTaskRunRequest.
-func (etrr EncodedTaskRunRequest) AsDockerBuildRequest() (*DockerBuildRequest, bool) {
- return nil, false
-}
-
-// AsFileTaskRunRequest is the BasicRunRequest implementation for EncodedTaskRunRequest.
-func (etrr EncodedTaskRunRequest) AsFileTaskRunRequest() (*FileTaskRunRequest, bool) {
- return nil, false
-}
-
-// AsTaskRunRequest is the BasicRunRequest implementation for EncodedTaskRunRequest.
-func (etrr EncodedTaskRunRequest) AsTaskRunRequest() (*TaskRunRequest, bool) {
- return nil, false
-}
-
-// AsEncodedTaskRunRequest is the BasicRunRequest implementation for EncodedTaskRunRequest.
-func (etrr EncodedTaskRunRequest) AsEncodedTaskRunRequest() (*EncodedTaskRunRequest, bool) {
- return &etrr, true
-}
-
-// AsRunRequest is the BasicRunRequest implementation for EncodedTaskRunRequest.
-func (etrr EncodedTaskRunRequest) AsRunRequest() (*RunRequest, bool) {
- return nil, false
-}
-
-// AsBasicRunRequest is the BasicRunRequest implementation for EncodedTaskRunRequest.
-func (etrr EncodedTaskRunRequest) AsBasicRunRequest() (BasicRunRequest, bool) {
- return &etrr, true
-}
-
-// EncodedTaskStep the properties of a encoded task step.
-type EncodedTaskStep struct {
- // EncodedTaskContent - Base64 encoded value of the template/definition file content.
- EncodedTaskContent *string `json:"encodedTaskContent,omitempty"`
- // EncodedValuesContent - Base64 encoded value of the parameters/values file content.
- EncodedValuesContent *string `json:"encodedValuesContent,omitempty"`
- // Values - The collection of overridable values that can be passed when running a task.
- Values *[]SetValue `json:"values,omitempty"`
- // BaseImageDependencies - READ-ONLY; List of base image dependencies for a step.
- BaseImageDependencies *[]BaseImageDependency `json:"baseImageDependencies,omitempty"`
- // ContextPath - The URL(absolute or relative) of the source context for the task step.
- ContextPath *string `json:"contextPath,omitempty"`
- // ContextAccessToken - The token (git PAT or SAS token of storage account blob) associated with the context for a step.
- ContextAccessToken *string `json:"contextAccessToken,omitempty"`
- // Type - Possible values include: 'TypeTaskStepProperties', 'TypeDocker', 'TypeFileTask', 'TypeEncodedTask'
- Type TypeBasicTaskStepProperties `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for EncodedTaskStep.
-func (ets EncodedTaskStep) MarshalJSON() ([]byte, error) {
- ets.Type = TypeEncodedTask
- objectMap := make(map[string]interface{})
- if ets.EncodedTaskContent != nil {
- objectMap["encodedTaskContent"] = ets.EncodedTaskContent
- }
- if ets.EncodedValuesContent != nil {
- objectMap["encodedValuesContent"] = ets.EncodedValuesContent
- }
- if ets.Values != nil {
- objectMap["values"] = ets.Values
- }
- if ets.ContextPath != nil {
- objectMap["contextPath"] = ets.ContextPath
- }
- if ets.ContextAccessToken != nil {
- objectMap["contextAccessToken"] = ets.ContextAccessToken
- }
- if ets.Type != "" {
- objectMap["type"] = ets.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildStep is the BasicTaskStepProperties implementation for EncodedTaskStep.
-func (ets EncodedTaskStep) AsDockerBuildStep() (*DockerBuildStep, bool) {
- return nil, false
-}
-
-// AsFileTaskStep is the BasicTaskStepProperties implementation for EncodedTaskStep.
-func (ets EncodedTaskStep) AsFileTaskStep() (*FileTaskStep, bool) {
- return nil, false
-}
-
-// AsEncodedTaskStep is the BasicTaskStepProperties implementation for EncodedTaskStep.
-func (ets EncodedTaskStep) AsEncodedTaskStep() (*EncodedTaskStep, bool) {
- return &ets, true
-}
-
-// AsTaskStepProperties is the BasicTaskStepProperties implementation for EncodedTaskStep.
-func (ets EncodedTaskStep) AsTaskStepProperties() (*TaskStepProperties, bool) {
- return nil, false
-}
-
-// AsBasicTaskStepProperties is the BasicTaskStepProperties implementation for EncodedTaskStep.
-func (ets EncodedTaskStep) AsBasicTaskStepProperties() (BasicTaskStepProperties, bool) {
- return &ets, true
-}
-
-// EncodedTaskStepUpdateParameters the properties for updating encoded task step.
-type EncodedTaskStepUpdateParameters struct {
- // EncodedTaskContent - Base64 encoded value of the template/definition file content.
- EncodedTaskContent *string `json:"encodedTaskContent,omitempty"`
- // EncodedValuesContent - Base64 encoded value of the parameters/values file content.
- EncodedValuesContent *string `json:"encodedValuesContent,omitempty"`
- // Values - The collection of overridable values that can be passed when running a task.
- Values *[]SetValue `json:"values,omitempty"`
- // ContextPath - The URL(absolute or relative) of the source context for the task step.
- ContextPath *string `json:"contextPath,omitempty"`
- // ContextAccessToken - The token (git PAT or SAS token of storage account blob) associated with the context for a step.
- ContextAccessToken *string `json:"contextAccessToken,omitempty"`
- // Type - Possible values include: 'TypeBasicTaskStepUpdateParametersTypeTaskStepUpdateParameters', 'TypeBasicTaskStepUpdateParametersTypeDocker', 'TypeBasicTaskStepUpdateParametersTypeFileTask', 'TypeBasicTaskStepUpdateParametersTypeEncodedTask'
- Type TypeBasicTaskStepUpdateParameters `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for EncodedTaskStepUpdateParameters.
-func (etsup EncodedTaskStepUpdateParameters) MarshalJSON() ([]byte, error) {
- etsup.Type = TypeBasicTaskStepUpdateParametersTypeEncodedTask
- objectMap := make(map[string]interface{})
- if etsup.EncodedTaskContent != nil {
- objectMap["encodedTaskContent"] = etsup.EncodedTaskContent
- }
- if etsup.EncodedValuesContent != nil {
- objectMap["encodedValuesContent"] = etsup.EncodedValuesContent
- }
- if etsup.Values != nil {
- objectMap["values"] = etsup.Values
- }
- if etsup.ContextPath != nil {
- objectMap["contextPath"] = etsup.ContextPath
- }
- if etsup.ContextAccessToken != nil {
- objectMap["contextAccessToken"] = etsup.ContextAccessToken
- }
- if etsup.Type != "" {
- objectMap["type"] = etsup.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for EncodedTaskStepUpdateParameters.
-func (etsup EncodedTaskStepUpdateParameters) AsDockerBuildStepUpdateParameters() (*DockerBuildStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsFileTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for EncodedTaskStepUpdateParameters.
-func (etsup EncodedTaskStepUpdateParameters) AsFileTaskStepUpdateParameters() (*FileTaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsEncodedTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for EncodedTaskStepUpdateParameters.
-func (etsup EncodedTaskStepUpdateParameters) AsEncodedTaskStepUpdateParameters() (*EncodedTaskStepUpdateParameters, bool) {
- return &etsup, true
-}
-
-// AsTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for EncodedTaskStepUpdateParameters.
-func (etsup EncodedTaskStepUpdateParameters) AsTaskStepUpdateParameters() (*TaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsBasicTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for EncodedTaskStepUpdateParameters.
-func (etsup EncodedTaskStepUpdateParameters) AsBasicTaskStepUpdateParameters() (BasicTaskStepUpdateParameters, bool) {
- return &etsup, true
-}
-
-// Event the event for a webhook.
-type Event struct {
- // EventRequestMessage - The event request message sent to the service URI.
- EventRequestMessage *EventRequestMessage `json:"eventRequestMessage,omitempty"`
- // EventResponseMessage - The event response message received from the service URI.
- EventResponseMessage *EventResponseMessage `json:"eventResponseMessage,omitempty"`
- // ID - The event ID.
- ID *string `json:"id,omitempty"`
-}
-
-// EventContent the content of the event request message.
-type EventContent struct {
- // ID - The event ID.
- ID *string `json:"id,omitempty"`
- // Timestamp - The time at which the event occurred.
- Timestamp *date.Time `json:"timestamp,omitempty"`
- // Action - The action that encompasses the provided event.
- Action *string `json:"action,omitempty"`
- // Target - The target of the event.
- Target *Target `json:"target,omitempty"`
- // Request - The request that generated the event.
- Request *Request `json:"request,omitempty"`
- // Actor - The agent that initiated the event. For most situations, this could be from the authorization context of the request.
- Actor *Actor `json:"actor,omitempty"`
- // Source - The registry node that generated the event. Put differently, while the actor initiates the event, the source generates it.
- Source *Source `json:"source,omitempty"`
-}
-
-// EventInfo the basic information of an event.
-type EventInfo struct {
- autorest.Response `json:"-"`
- // ID - The event ID.
- ID *string `json:"id,omitempty"`
-}
-
-// EventListResult the result of a request to list events for a webhook.
-type EventListResult struct {
- autorest.Response `json:"-"`
- // Value - The list of events. Since this list may be incomplete, the nextLink field should be used to request the next list of events.
- Value *[]Event `json:"value,omitempty"`
- // NextLink - The URI that can be used to request the next list of events.
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// EventListResultIterator provides access to a complete listing of Event values.
-type EventListResultIterator struct {
- i int
- page EventListResultPage
-}
-
-// NextWithContext advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *EventListResultIterator) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/EventListResultIterator.NextWithContext")
- defer func() {
- sc := -1
- if iter.Response().Response.Response != nil {
- sc = iter.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err = iter.page.NextWithContext(ctx)
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (iter *EventListResultIterator) Next() error {
- return iter.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter EventListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter EventListResultIterator) Response() EventListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter EventListResultIterator) Value() Event {
- if !iter.page.NotDone() {
- return Event{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// Creates a new instance of the EventListResultIterator type.
-func NewEventListResultIterator(page EventListResultPage) EventListResultIterator {
- return EventListResultIterator{page: page}
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (elr EventListResult) IsEmpty() bool {
- return elr.Value == nil || len(*elr.Value) == 0
-}
-
-// eventListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (elr EventListResult) eventListResultPreparer(ctx context.Context) (*http.Request, error) {
- if elr.NextLink == nil || len(to.String(elr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare((&http.Request{}).WithContext(ctx),
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(elr.NextLink)))
-}
-
-// EventListResultPage contains a page of Event values.
-type EventListResultPage struct {
- fn func(context.Context, EventListResult) (EventListResult, error)
- elr EventListResult
-}
-
-// NextWithContext advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *EventListResultPage) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/EventListResultPage.NextWithContext")
- defer func() {
- sc := -1
- if page.Response().Response.Response != nil {
- sc = page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- next, err := page.fn(ctx, page.elr)
- if err != nil {
- return err
- }
- page.elr = next
- return nil
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (page *EventListResultPage) Next() error {
- return page.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page EventListResultPage) NotDone() bool {
- return !page.elr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page EventListResultPage) Response() EventListResult {
- return page.elr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page EventListResultPage) Values() []Event {
- if page.elr.IsEmpty() {
- return nil
- }
- return *page.elr.Value
-}
-
-// Creates a new instance of the EventListResultPage type.
-func NewEventListResultPage(getNextPage func(context.Context, EventListResult) (EventListResult, error)) EventListResultPage {
- return EventListResultPage{fn: getNextPage}
-}
-
-// EventRequestMessage the event request message sent to the service URI.
-type EventRequestMessage struct {
- // Content - The content of the event request message.
- Content *EventContent `json:"content,omitempty"`
- // Headers - The headers of the event request message.
- Headers map[string]*string `json:"headers"`
- // Method - The HTTP method used to send the event request message.
- Method *string `json:"method,omitempty"`
- // RequestURI - The URI used to send the event request message.
- RequestURI *string `json:"requestUri,omitempty"`
- // Version - The HTTP message version.
- Version *string `json:"version,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for EventRequestMessage.
-func (erm EventRequestMessage) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if erm.Content != nil {
- objectMap["content"] = erm.Content
- }
- if erm.Headers != nil {
- objectMap["headers"] = erm.Headers
- }
- if erm.Method != nil {
- objectMap["method"] = erm.Method
- }
- if erm.RequestURI != nil {
- objectMap["requestUri"] = erm.RequestURI
- }
- if erm.Version != nil {
- objectMap["version"] = erm.Version
- }
- return json.Marshal(objectMap)
-}
-
-// EventResponseMessage the event response message received from the service URI.
-type EventResponseMessage struct {
- // Content - The content of the event response message.
- Content *string `json:"content,omitempty"`
- // Headers - The headers of the event response message.
- Headers map[string]*string `json:"headers"`
- // ReasonPhrase - The reason phrase of the event response message.
- ReasonPhrase *string `json:"reasonPhrase,omitempty"`
- // StatusCode - The status code of the event response message.
- StatusCode *string `json:"statusCode,omitempty"`
- // Version - The HTTP message version.
- Version *string `json:"version,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for EventResponseMessage.
-func (erm EventResponseMessage) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if erm.Content != nil {
- objectMap["content"] = erm.Content
- }
- if erm.Headers != nil {
- objectMap["headers"] = erm.Headers
- }
- if erm.ReasonPhrase != nil {
- objectMap["reasonPhrase"] = erm.ReasonPhrase
- }
- if erm.StatusCode != nil {
- objectMap["statusCode"] = erm.StatusCode
- }
- if erm.Version != nil {
- objectMap["version"] = erm.Version
- }
- return json.Marshal(objectMap)
-}
-
-// FileTaskRunRequest the request parameters for a scheduling run against a task file.
-type FileTaskRunRequest struct {
- // TaskFilePath - The template/definition file path relative to the source.
- TaskFilePath *string `json:"taskFilePath,omitempty"`
- // ValuesFilePath - The values/parameters file path relative to the source.
- ValuesFilePath *string `json:"valuesFilePath,omitempty"`
- // Values - The collection of overridable values that can be passed when running a task.
- Values *[]SetValue `json:"values,omitempty"`
- // Timeout - Run timeout in seconds.
- Timeout *int32 `json:"timeout,omitempty"`
- // Platform - The platform properties against which the run has to happen.
- Platform *PlatformProperties `json:"platform,omitempty"`
- // AgentConfiguration - The machine configuration of the run agent.
- AgentConfiguration *AgentProperties `json:"agentConfiguration,omitempty"`
- // SourceLocation - The URL(absolute or relative) of the source context. It can be an URL to a tar or git repository.
- // If it is relative URL, the relative path should be obtained from calling listBuildSourceUploadUrl API.
- SourceLocation *string `json:"sourceLocation,omitempty"`
- // Credentials - The properties that describes a set of credentials that will be used when this run is invoked.
- Credentials *Credentials `json:"credentials,omitempty"`
- // IsArchiveEnabled - The value that indicates whether archiving is enabled for the run or not.
- IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
- // Type - Possible values include: 'TypeRunRequest', 'TypeDockerBuildRequest', 'TypeFileTaskRunRequest', 'TypeTaskRunRequest', 'TypeEncodedTaskRunRequest'
- Type Type `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for FileTaskRunRequest.
-func (ftrr FileTaskRunRequest) MarshalJSON() ([]byte, error) {
- ftrr.Type = TypeFileTaskRunRequest
- objectMap := make(map[string]interface{})
- if ftrr.TaskFilePath != nil {
- objectMap["taskFilePath"] = ftrr.TaskFilePath
- }
- if ftrr.ValuesFilePath != nil {
- objectMap["valuesFilePath"] = ftrr.ValuesFilePath
- }
- if ftrr.Values != nil {
- objectMap["values"] = ftrr.Values
- }
- if ftrr.Timeout != nil {
- objectMap["timeout"] = ftrr.Timeout
- }
- if ftrr.Platform != nil {
- objectMap["platform"] = ftrr.Platform
- }
- if ftrr.AgentConfiguration != nil {
- objectMap["agentConfiguration"] = ftrr.AgentConfiguration
- }
- if ftrr.SourceLocation != nil {
- objectMap["sourceLocation"] = ftrr.SourceLocation
- }
- if ftrr.Credentials != nil {
- objectMap["credentials"] = ftrr.Credentials
- }
- if ftrr.IsArchiveEnabled != nil {
- objectMap["isArchiveEnabled"] = ftrr.IsArchiveEnabled
- }
- if ftrr.Type != "" {
- objectMap["type"] = ftrr.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildRequest is the BasicRunRequest implementation for FileTaskRunRequest.
-func (ftrr FileTaskRunRequest) AsDockerBuildRequest() (*DockerBuildRequest, bool) {
- return nil, false
-}
-
-// AsFileTaskRunRequest is the BasicRunRequest implementation for FileTaskRunRequest.
-func (ftrr FileTaskRunRequest) AsFileTaskRunRequest() (*FileTaskRunRequest, bool) {
- return &ftrr, true
-}
-
-// AsTaskRunRequest is the BasicRunRequest implementation for FileTaskRunRequest.
-func (ftrr FileTaskRunRequest) AsTaskRunRequest() (*TaskRunRequest, bool) {
- return nil, false
-}
-
-// AsEncodedTaskRunRequest is the BasicRunRequest implementation for FileTaskRunRequest.
-func (ftrr FileTaskRunRequest) AsEncodedTaskRunRequest() (*EncodedTaskRunRequest, bool) {
- return nil, false
-}
-
-// AsRunRequest is the BasicRunRequest implementation for FileTaskRunRequest.
-func (ftrr FileTaskRunRequest) AsRunRequest() (*RunRequest, bool) {
- return nil, false
-}
-
-// AsBasicRunRequest is the BasicRunRequest implementation for FileTaskRunRequest.
-func (ftrr FileTaskRunRequest) AsBasicRunRequest() (BasicRunRequest, bool) {
- return &ftrr, true
-}
-
-// FileTaskStep the properties of a task step.
-type FileTaskStep struct {
- // TaskFilePath - The task template/definition file path relative to the source context.
- TaskFilePath *string `json:"taskFilePath,omitempty"`
- // ValuesFilePath - The task values/parameters file path relative to the source context.
- ValuesFilePath *string `json:"valuesFilePath,omitempty"`
- // Values - The collection of overridable values that can be passed when running a task.
- Values *[]SetValue `json:"values,omitempty"`
- // BaseImageDependencies - READ-ONLY; List of base image dependencies for a step.
- BaseImageDependencies *[]BaseImageDependency `json:"baseImageDependencies,omitempty"`
- // ContextPath - The URL(absolute or relative) of the source context for the task step.
- ContextPath *string `json:"contextPath,omitempty"`
- // ContextAccessToken - The token (git PAT or SAS token of storage account blob) associated with the context for a step.
- ContextAccessToken *string `json:"contextAccessToken,omitempty"`
- // Type - Possible values include: 'TypeTaskStepProperties', 'TypeDocker', 'TypeFileTask', 'TypeEncodedTask'
- Type TypeBasicTaskStepProperties `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for FileTaskStep.
-func (fts FileTaskStep) MarshalJSON() ([]byte, error) {
- fts.Type = TypeFileTask
- objectMap := make(map[string]interface{})
- if fts.TaskFilePath != nil {
- objectMap["taskFilePath"] = fts.TaskFilePath
- }
- if fts.ValuesFilePath != nil {
- objectMap["valuesFilePath"] = fts.ValuesFilePath
- }
- if fts.Values != nil {
- objectMap["values"] = fts.Values
- }
- if fts.ContextPath != nil {
- objectMap["contextPath"] = fts.ContextPath
- }
- if fts.ContextAccessToken != nil {
- objectMap["contextAccessToken"] = fts.ContextAccessToken
- }
- if fts.Type != "" {
- objectMap["type"] = fts.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildStep is the BasicTaskStepProperties implementation for FileTaskStep.
-func (fts FileTaskStep) AsDockerBuildStep() (*DockerBuildStep, bool) {
- return nil, false
-}
-
-// AsFileTaskStep is the BasicTaskStepProperties implementation for FileTaskStep.
-func (fts FileTaskStep) AsFileTaskStep() (*FileTaskStep, bool) {
- return &fts, true
-}
-
-// AsEncodedTaskStep is the BasicTaskStepProperties implementation for FileTaskStep.
-func (fts FileTaskStep) AsEncodedTaskStep() (*EncodedTaskStep, bool) {
- return nil, false
-}
-
-// AsTaskStepProperties is the BasicTaskStepProperties implementation for FileTaskStep.
-func (fts FileTaskStep) AsTaskStepProperties() (*TaskStepProperties, bool) {
- return nil, false
-}
-
-// AsBasicTaskStepProperties is the BasicTaskStepProperties implementation for FileTaskStep.
-func (fts FileTaskStep) AsBasicTaskStepProperties() (BasicTaskStepProperties, bool) {
- return &fts, true
-}
-
-// FileTaskStepUpdateParameters the properties of updating a task step.
-type FileTaskStepUpdateParameters struct {
- // TaskFilePath - The task template/definition file path relative to the source context.
- TaskFilePath *string `json:"taskFilePath,omitempty"`
- // ValuesFilePath - The values/parameters file path relative to the source context.
- ValuesFilePath *string `json:"valuesFilePath,omitempty"`
- // Values - The collection of overridable values that can be passed when running a task.
- Values *[]SetValue `json:"values,omitempty"`
- // ContextPath - The URL(absolute or relative) of the source context for the task step.
- ContextPath *string `json:"contextPath,omitempty"`
- // ContextAccessToken - The token (git PAT or SAS token of storage account blob) associated with the context for a step.
- ContextAccessToken *string `json:"contextAccessToken,omitempty"`
- // Type - Possible values include: 'TypeBasicTaskStepUpdateParametersTypeTaskStepUpdateParameters', 'TypeBasicTaskStepUpdateParametersTypeDocker', 'TypeBasicTaskStepUpdateParametersTypeFileTask', 'TypeBasicTaskStepUpdateParametersTypeEncodedTask'
- Type TypeBasicTaskStepUpdateParameters `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for FileTaskStepUpdateParameters.
-func (ftsup FileTaskStepUpdateParameters) MarshalJSON() ([]byte, error) {
- ftsup.Type = TypeBasicTaskStepUpdateParametersTypeFileTask
- objectMap := make(map[string]interface{})
- if ftsup.TaskFilePath != nil {
- objectMap["taskFilePath"] = ftsup.TaskFilePath
- }
- if ftsup.ValuesFilePath != nil {
- objectMap["valuesFilePath"] = ftsup.ValuesFilePath
- }
- if ftsup.Values != nil {
- objectMap["values"] = ftsup.Values
- }
- if ftsup.ContextPath != nil {
- objectMap["contextPath"] = ftsup.ContextPath
- }
- if ftsup.ContextAccessToken != nil {
- objectMap["contextAccessToken"] = ftsup.ContextAccessToken
- }
- if ftsup.Type != "" {
- objectMap["type"] = ftsup.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for FileTaskStepUpdateParameters.
-func (ftsup FileTaskStepUpdateParameters) AsDockerBuildStepUpdateParameters() (*DockerBuildStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsFileTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for FileTaskStepUpdateParameters.
-func (ftsup FileTaskStepUpdateParameters) AsFileTaskStepUpdateParameters() (*FileTaskStepUpdateParameters, bool) {
- return &ftsup, true
-}
-
-// AsEncodedTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for FileTaskStepUpdateParameters.
-func (ftsup FileTaskStepUpdateParameters) AsEncodedTaskStepUpdateParameters() (*EncodedTaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for FileTaskStepUpdateParameters.
-func (ftsup FileTaskStepUpdateParameters) AsTaskStepUpdateParameters() (*TaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsBasicTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for FileTaskStepUpdateParameters.
-func (ftsup FileTaskStepUpdateParameters) AsBasicTaskStepUpdateParameters() (BasicTaskStepUpdateParameters, bool) {
- return &ftsup, true
-}
-
-// IdentityProperties managed identity for the resource.
-type IdentityProperties struct {
- // PrincipalID - The principal ID of resource identity.
- PrincipalID *string `json:"principalId,omitempty"`
- // TenantID - The tenant ID of resource.
- TenantID *string `json:"tenantId,omitempty"`
- // Type - The identity type. Possible values include: 'SystemAssigned', 'UserAssigned', 'SystemAssignedUserAssigned', 'None'
- Type ResourceIdentityType `json:"type,omitempty"`
- // UserAssignedIdentities - The list of user identities associated with the resource. The user identity
- // dictionary key references will be ARM resource ids in the form:
- // '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/
- // providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
- UserAssignedIdentities map[string]*UserIdentityProperties `json:"userAssignedIdentities"`
-}
-
-// MarshalJSON is the custom marshaler for IdentityProperties.
-func (IP IdentityProperties) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if IP.PrincipalID != nil {
- objectMap["principalId"] = IP.PrincipalID
- }
- if IP.TenantID != nil {
- objectMap["tenantId"] = IP.TenantID
- }
- if IP.Type != "" {
- objectMap["type"] = IP.Type
- }
- if IP.UserAssignedIdentities != nil {
- objectMap["userAssignedIdentities"] = IP.UserAssignedIdentities
- }
- return json.Marshal(objectMap)
-}
-
-// ImageDescriptor properties for a registry image.
-type ImageDescriptor struct {
- // Registry - The registry login server.
- Registry *string `json:"registry,omitempty"`
- // Repository - The repository name.
- Repository *string `json:"repository,omitempty"`
- // Tag - The tag name.
- Tag *string `json:"tag,omitempty"`
- // Digest - The sha256-based digest of the image manifest.
- Digest *string `json:"digest,omitempty"`
-}
-
-// ImageUpdateTrigger the image update trigger that caused a build.
-type ImageUpdateTrigger struct {
- // ID - The unique ID of the trigger.
- ID *string `json:"id,omitempty"`
- // Timestamp - The timestamp when the image update happened.
- Timestamp *date.Time `json:"timestamp,omitempty"`
- // Images - The list of image updates that caused the build.
- Images *[]ImageDescriptor `json:"images,omitempty"`
-}
-
-// ImportImageParameters ...
-type ImportImageParameters struct {
- // Source - The source of the image.
- Source *ImportSource `json:"source,omitempty"`
- // TargetTags - List of strings of the form repo[:tag]. When tag is omitted the source will be used (or 'latest' if source tag is also omitted).
- TargetTags *[]string `json:"targetTags,omitempty"`
- // UntaggedTargetRepositories - List of strings of repository names to do a manifest only copy. No tag will be created.
- UntaggedTargetRepositories *[]string `json:"untaggedTargetRepositories,omitempty"`
- // Mode - When Force, any existing target tags will be overwritten. When NoForce, any existing target tags will fail the operation before any copying begins. Possible values include: 'NoForce', 'Force'
- Mode ImportMode `json:"mode,omitempty"`
-}
-
-// ImportSource ...
-type ImportSource struct {
- // ResourceID - The resource identifier of the source Azure Container Registry.
- ResourceID *string `json:"resourceId,omitempty"`
- // RegistryURI - The address of the source registry (e.g. 'mcr.microsoft.com').
- RegistryURI *string `json:"registryUri,omitempty"`
- // Credentials - Credentials used when importing from a registry uri.
- Credentials *ImportSourceCredentials `json:"credentials,omitempty"`
- // SourceImage - Repository name of the source image.
- // Specify an image by repository ('hello-world'). This will use the 'latest' tag.
- // Specify an image by tag ('hello-world:latest').
- // Specify an image by sha256-based manifest digest ('hello-world@sha256:abc123').
- SourceImage *string `json:"sourceImage,omitempty"`
-}
-
-// ImportSourceCredentials ...
-type ImportSourceCredentials struct {
- // Username - The username to authenticate with the source registry.
- Username *string `json:"username,omitempty"`
- // Password - The password used to authenticate with the source registry.
- Password *string `json:"password,omitempty"`
-}
-
-// IPRule IP rule with specific IP or IP range in CIDR format.
-type IPRule struct {
- // Action - The action of IP ACL rule. Possible values include: 'Allow'
- Action Action `json:"action,omitempty"`
- // IPAddressOrRange - Specifies the IP or IP range in CIDR format. Only IPV4 address is allowed.
- IPAddressOrRange *string `json:"value,omitempty"`
-}
-
-// NetworkRuleSet the network rule set for a container registry.
-type NetworkRuleSet struct {
- // DefaultAction - The default action of allow or deny when no other rules match. Possible values include: 'DefaultActionAllow', 'DefaultActionDeny'
- DefaultAction DefaultAction `json:"defaultAction,omitempty"`
- // VirtualNetworkRules - The virtual network rules.
- VirtualNetworkRules *[]VirtualNetworkRule `json:"virtualNetworkRules,omitempty"`
- // IPRules - The IP ACL rules.
- IPRules *[]IPRule `json:"ipRules,omitempty"`
-}
-
-// OperationDefinition the definition of a container registry operation.
-type OperationDefinition struct {
- // Origin - The origin information of the container registry operation.
- Origin *string `json:"origin,omitempty"`
- // Name - Operation name: {provider}/{resource}/{operation}.
- Name *string `json:"name,omitempty"`
- // Display - The display information for the container registry operation.
- Display *OperationDisplayDefinition `json:"display,omitempty"`
- // OperationPropertiesDefinition - The properties information for the container registry operation.
- *OperationPropertiesDefinition `json:"properties,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for OperationDefinition.
-func (od OperationDefinition) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if od.Origin != nil {
- objectMap["origin"] = od.Origin
- }
- if od.Name != nil {
- objectMap["name"] = od.Name
- }
- if od.Display != nil {
- objectMap["display"] = od.Display
- }
- if od.OperationPropertiesDefinition != nil {
- objectMap["properties"] = od.OperationPropertiesDefinition
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for OperationDefinition struct.
-func (od *OperationDefinition) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "origin":
- if v != nil {
- var origin string
- err = json.Unmarshal(*v, &origin)
- if err != nil {
- return err
- }
- od.Origin = &origin
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- od.Name = &name
- }
- case "display":
- if v != nil {
- var display OperationDisplayDefinition
- err = json.Unmarshal(*v, &display)
- if err != nil {
- return err
- }
- od.Display = &display
- }
- case "properties":
- if v != nil {
- var operationPropertiesDefinition OperationPropertiesDefinition
- err = json.Unmarshal(*v, &operationPropertiesDefinition)
- if err != nil {
- return err
- }
- od.OperationPropertiesDefinition = &operationPropertiesDefinition
- }
- }
- }
-
- return nil
-}
-
-// OperationDisplayDefinition the display information for a container registry operation.
-type OperationDisplayDefinition struct {
- // Provider - The resource provider name: Microsoft.ContainerRegistry.
- Provider *string `json:"provider,omitempty"`
- // Resource - The resource on which the operation is performed.
- Resource *string `json:"resource,omitempty"`
- // Operation - The operation that users can perform.
- Operation *string `json:"operation,omitempty"`
- // Description - The description for the operation.
- Description *string `json:"description,omitempty"`
-}
-
-// OperationListResult the result of a request to list container registry operations.
-type OperationListResult struct {
- autorest.Response `json:"-"`
- // Value - The list of container registry operations. Since this list may be incomplete, the nextLink field should be used to request the next list of operations.
- Value *[]OperationDefinition `json:"value,omitempty"`
- // NextLink - The URI that can be used to request the next list of container registry operations.
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// OperationListResultIterator provides access to a complete listing of OperationDefinition values.
-type OperationListResultIterator struct {
- i int
- page OperationListResultPage
-}
-
-// NextWithContext advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *OperationListResultIterator) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/OperationListResultIterator.NextWithContext")
- defer func() {
- sc := -1
- if iter.Response().Response.Response != nil {
- sc = iter.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err = iter.page.NextWithContext(ctx)
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (iter *OperationListResultIterator) Next() error {
- return iter.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter OperationListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter OperationListResultIterator) Response() OperationListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter OperationListResultIterator) Value() OperationDefinition {
- if !iter.page.NotDone() {
- return OperationDefinition{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// Creates a new instance of the OperationListResultIterator type.
-func NewOperationListResultIterator(page OperationListResultPage) OperationListResultIterator {
- return OperationListResultIterator{page: page}
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (olr OperationListResult) IsEmpty() bool {
- return olr.Value == nil || len(*olr.Value) == 0
-}
-
-// operationListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (olr OperationListResult) operationListResultPreparer(ctx context.Context) (*http.Request, error) {
- if olr.NextLink == nil || len(to.String(olr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare((&http.Request{}).WithContext(ctx),
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(olr.NextLink)))
-}
-
-// OperationListResultPage contains a page of OperationDefinition values.
-type OperationListResultPage struct {
- fn func(context.Context, OperationListResult) (OperationListResult, error)
- olr OperationListResult
-}
-
-// NextWithContext advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *OperationListResultPage) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/OperationListResultPage.NextWithContext")
- defer func() {
- sc := -1
- if page.Response().Response.Response != nil {
- sc = page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- next, err := page.fn(ctx, page.olr)
- if err != nil {
- return err
- }
- page.olr = next
- return nil
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (page *OperationListResultPage) Next() error {
- return page.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page OperationListResultPage) NotDone() bool {
- return !page.olr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page OperationListResultPage) Response() OperationListResult {
- return page.olr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page OperationListResultPage) Values() []OperationDefinition {
- if page.olr.IsEmpty() {
- return nil
- }
- return *page.olr.Value
-}
-
-// Creates a new instance of the OperationListResultPage type.
-func NewOperationListResultPage(getNextPage func(context.Context, OperationListResult) (OperationListResult, error)) OperationListResultPage {
- return OperationListResultPage{fn: getNextPage}
-}
-
-// OperationMetricSpecificationDefinition the definition of Azure Monitoring metric.
-type OperationMetricSpecificationDefinition struct {
- // Name - Metric name.
- Name *string `json:"name,omitempty"`
- // DisplayName - Metric display name.
- DisplayName *string `json:"displayName,omitempty"`
- // DisplayDescription - Metric description.
- DisplayDescription *string `json:"displayDescription,omitempty"`
- // Unit - Metric unit.
- Unit *string `json:"unit,omitempty"`
- // AggregationType - Metric aggregation type.
- AggregationType *string `json:"aggregationType,omitempty"`
- // InternalMetricName - Internal metric name.
- InternalMetricName *string `json:"internalMetricName,omitempty"`
-}
-
-// OperationPropertiesDefinition the definition of Azure Monitoring properties.
-type OperationPropertiesDefinition struct {
- // ServiceSpecification - The definition of Azure Monitoring service.
- ServiceSpecification *OperationServiceSpecificationDefinition `json:"serviceSpecification,omitempty"`
-}
-
-// OperationServiceSpecificationDefinition the definition of Azure Monitoring list.
-type OperationServiceSpecificationDefinition struct {
- // MetricSpecifications - A list of Azure Monitoring metrics definition.
- MetricSpecifications *[]OperationMetricSpecificationDefinition `json:"metricSpecifications,omitempty"`
-}
-
-// PlatformProperties the platform properties against which the run has to happen.
-type PlatformProperties struct {
- // Os - The operating system type required for the run. Possible values include: 'Windows', 'Linux'
- Os OS `json:"os,omitempty"`
- // Architecture - The OS architecture. Possible values include: 'Amd64', 'X86', 'Arm'
- Architecture Architecture `json:"architecture,omitempty"`
- // Variant - Variant of the CPU. Possible values include: 'V6', 'V7', 'V8'
- Variant Variant `json:"variant,omitempty"`
-}
-
-// PlatformUpdateParameters the properties for updating the platform configuration.
-type PlatformUpdateParameters struct {
- // Os - The operating system type required for the run. Possible values include: 'Windows', 'Linux'
- Os OS `json:"os,omitempty"`
- // Architecture - The OS architecture. Possible values include: 'Amd64', 'X86', 'Arm'
- Architecture Architecture `json:"architecture,omitempty"`
- // Variant - Variant of the CPU. Possible values include: 'V6', 'V7', 'V8'
- Variant Variant `json:"variant,omitempty"`
-}
-
-// Policies the policies for a container registry.
-type Policies struct {
- // QuarantinePolicy - The quarantine policy for a container registry.
- QuarantinePolicy *QuarantinePolicy `json:"quarantinePolicy,omitempty"`
- // TrustPolicy - The content trust policy for a container registry.
- TrustPolicy *TrustPolicy `json:"trustPolicy,omitempty"`
- // RetentionPolicy - The retention policy for a container registry.
- RetentionPolicy *RetentionPolicy `json:"retentionPolicy,omitempty"`
-}
-
-// ProxyResource the resource model definition for a ARM proxy resource. It will have everything other than
-// required location and tags.
-type ProxyResource struct {
- // ID - READ-ONLY; The resource ID.
- ID *string `json:"id,omitempty"`
- // Name - READ-ONLY; The name of the resource.
- Name *string `json:"name,omitempty"`
- // Type - READ-ONLY; The type of the resource.
- Type *string `json:"type,omitempty"`
-}
-
-// QuarantinePolicy the quarantine policy for a container registry.
-type QuarantinePolicy struct {
- // Status - The value that indicates whether the policy is enabled or not. Possible values include: 'Enabled', 'Disabled'
- Status PolicyStatus `json:"status,omitempty"`
-}
-
-// RegenerateCredentialParameters the parameters used to regenerate the login credential.
-type RegenerateCredentialParameters struct {
- // Name - Specifies name of the password which should be regenerated -- password or password2. Possible values include: 'Password', 'Password2'
- Name PasswordName `json:"name,omitempty"`
-}
-
-// RegistriesCreateFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type RegistriesCreateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *RegistriesCreateFuture) Result(client RegistriesClient) (r Registry, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesCreateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.RegistriesCreateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if r.Response.Response, err = future.GetResult(sender); err == nil && r.Response.Response.StatusCode != http.StatusNoContent {
- r, err = client.CreateResponder(r.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesCreateFuture", "Result", r.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// RegistriesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type RegistriesDeleteFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *RegistriesDeleteFuture) Result(client RegistriesClient) (ar autorest.Response, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesDeleteFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.RegistriesDeleteFuture")
- return
- }
- ar.Response = future.Response()
- return
-}
-
-// RegistriesImportImageFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type RegistriesImportImageFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *RegistriesImportImageFuture) Result(client RegistriesClient) (ar autorest.Response, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesImportImageFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.RegistriesImportImageFuture")
- return
- }
- ar.Response = future.Response()
- return
-}
-
-// RegistriesScheduleRunFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type RegistriesScheduleRunFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *RegistriesScheduleRunFuture) Result(client RegistriesClient) (r Run, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesScheduleRunFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.RegistriesScheduleRunFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if r.Response.Response, err = future.GetResult(sender); err == nil && r.Response.Response.StatusCode != http.StatusNoContent {
- r, err = client.ScheduleRunResponder(r.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesScheduleRunFuture", "Result", r.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// RegistriesUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type RegistriesUpdateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *RegistriesUpdateFuture) Result(client RegistriesClient) (r Registry, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesUpdateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.RegistriesUpdateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if r.Response.Response, err = future.GetResult(sender); err == nil && r.Response.Response.StatusCode != http.StatusNoContent {
- r, err = client.UpdateResponder(r.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesUpdateFuture", "Result", r.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// Registry an object that represents a container registry.
-type Registry struct {
- autorest.Response `json:"-"`
- // Sku - The SKU of the container registry.
- Sku *Sku `json:"sku,omitempty"`
- // RegistryProperties - The properties of the container registry.
- *RegistryProperties `json:"properties,omitempty"`
- // ID - READ-ONLY; The resource ID.
- ID *string `json:"id,omitempty"`
- // Name - READ-ONLY; The name of the resource.
- Name *string `json:"name,omitempty"`
- // Type - READ-ONLY; The type of the resource.
- Type *string `json:"type,omitempty"`
- // Location - The location of the resource. This cannot be changed after the resource is created.
- Location *string `json:"location,omitempty"`
- // Tags - The tags of the resource.
- Tags map[string]*string `json:"tags"`
-}
-
-// MarshalJSON is the custom marshaler for Registry.
-func (r Registry) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if r.Sku != nil {
- objectMap["sku"] = r.Sku
- }
- if r.RegistryProperties != nil {
- objectMap["properties"] = r.RegistryProperties
- }
- if r.Location != nil {
- objectMap["location"] = r.Location
- }
- if r.Tags != nil {
- objectMap["tags"] = r.Tags
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for Registry struct.
-func (r *Registry) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "sku":
- if v != nil {
- var sku Sku
- err = json.Unmarshal(*v, &sku)
- if err != nil {
- return err
- }
- r.Sku = &sku
- }
- case "properties":
- if v != nil {
- var registryProperties RegistryProperties
- err = json.Unmarshal(*v, ®istryProperties)
- if err != nil {
- return err
- }
- r.RegistryProperties = ®istryProperties
- }
- case "id":
- if v != nil {
- var ID string
- err = json.Unmarshal(*v, &ID)
- if err != nil {
- return err
- }
- r.ID = &ID
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- r.Name = &name
- }
- case "type":
- if v != nil {
- var typeVar string
- err = json.Unmarshal(*v, &typeVar)
- if err != nil {
- return err
- }
- r.Type = &typeVar
- }
- case "location":
- if v != nil {
- var location string
- err = json.Unmarshal(*v, &location)
- if err != nil {
- return err
- }
- r.Location = &location
- }
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- r.Tags = tags
- }
- }
- }
-
- return nil
-}
-
-// RegistryListCredentialsResult the response from the ListCredentials operation.
-type RegistryListCredentialsResult struct {
- autorest.Response `json:"-"`
- // Username - The username for a container registry.
- Username *string `json:"username,omitempty"`
- // Passwords - The list of passwords for a container registry.
- Passwords *[]RegistryPassword `json:"passwords,omitempty"`
-}
-
-// RegistryListResult the result of a request to list container registries.
-type RegistryListResult struct {
- autorest.Response `json:"-"`
- // Value - The list of container registries. Since this list may be incomplete, the nextLink field should be used to request the next list of container registries.
- Value *[]Registry `json:"value,omitempty"`
- // NextLink - The URI that can be used to request the next list of container registries.
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// RegistryListResultIterator provides access to a complete listing of Registry values.
-type RegistryListResultIterator struct {
- i int
- page RegistryListResultPage
-}
-
-// NextWithContext advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *RegistryListResultIterator) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistryListResultIterator.NextWithContext")
- defer func() {
- sc := -1
- if iter.Response().Response.Response != nil {
- sc = iter.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err = iter.page.NextWithContext(ctx)
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (iter *RegistryListResultIterator) Next() error {
- return iter.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter RegistryListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter RegistryListResultIterator) Response() RegistryListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter RegistryListResultIterator) Value() Registry {
- if !iter.page.NotDone() {
- return Registry{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// Creates a new instance of the RegistryListResultIterator type.
-func NewRegistryListResultIterator(page RegistryListResultPage) RegistryListResultIterator {
- return RegistryListResultIterator{page: page}
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (rlr RegistryListResult) IsEmpty() bool {
- return rlr.Value == nil || len(*rlr.Value) == 0
-}
-
-// registryListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (rlr RegistryListResult) registryListResultPreparer(ctx context.Context) (*http.Request, error) {
- if rlr.NextLink == nil || len(to.String(rlr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare((&http.Request{}).WithContext(ctx),
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(rlr.NextLink)))
-}
-
-// RegistryListResultPage contains a page of Registry values.
-type RegistryListResultPage struct {
- fn func(context.Context, RegistryListResult) (RegistryListResult, error)
- rlr RegistryListResult
-}
-
-// NextWithContext advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *RegistryListResultPage) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistryListResultPage.NextWithContext")
- defer func() {
- sc := -1
- if page.Response().Response.Response != nil {
- sc = page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- next, err := page.fn(ctx, page.rlr)
- if err != nil {
- return err
- }
- page.rlr = next
- return nil
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (page *RegistryListResultPage) Next() error {
- return page.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page RegistryListResultPage) NotDone() bool {
- return !page.rlr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page RegistryListResultPage) Response() RegistryListResult {
- return page.rlr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page RegistryListResultPage) Values() []Registry {
- if page.rlr.IsEmpty() {
- return nil
- }
- return *page.rlr.Value
-}
-
-// Creates a new instance of the RegistryListResultPage type.
-func NewRegistryListResultPage(getNextPage func(context.Context, RegistryListResult) (RegistryListResult, error)) RegistryListResultPage {
- return RegistryListResultPage{fn: getNextPage}
-}
-
-// RegistryNameCheckRequest a request to check whether a container registry name is available.
-type RegistryNameCheckRequest struct {
- // Name - The name of the container registry.
- Name *string `json:"name,omitempty"`
- // Type - The resource type of the container registry. This field must be set to 'Microsoft.ContainerRegistry/registries'.
- Type *string `json:"type,omitempty"`
-}
-
-// RegistryNameStatus the result of a request to check the availability of a container registry name.
-type RegistryNameStatus struct {
- autorest.Response `json:"-"`
- // NameAvailable - The value that indicates whether the name is available.
- NameAvailable *bool `json:"nameAvailable,omitempty"`
- // Reason - If any, the reason that the name is not available.
- Reason *string `json:"reason,omitempty"`
- // Message - If any, the error message that provides more detail for the reason that the name is not available.
- Message *string `json:"message,omitempty"`
-}
-
-// RegistryPassword the login password for the container registry.
-type RegistryPassword struct {
- // Name - The password name. Possible values include: 'Password', 'Password2'
- Name PasswordName `json:"name,omitempty"`
- // Value - The password value.
- Value *string `json:"value,omitempty"`
-}
-
-// RegistryProperties the properties of a container registry.
-type RegistryProperties struct {
- // LoginServer - READ-ONLY; The URL that can be used to log into the container registry.
- LoginServer *string `json:"loginServer,omitempty"`
- // CreationDate - READ-ONLY; The creation date of the container registry in ISO8601 format.
- CreationDate *date.Time `json:"creationDate,omitempty"`
- // ProvisioningState - READ-ONLY; The provisioning state of the container registry at the time the operation was called. Possible values include: 'Creating', 'Updating', 'Deleting', 'Succeeded', 'Failed', 'Canceled'
- ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
- // Status - READ-ONLY; The status of the container registry at the time the operation was called.
- Status *Status `json:"status,omitempty"`
- // AdminUserEnabled - The value that indicates whether the admin user is enabled.
- AdminUserEnabled *bool `json:"adminUserEnabled,omitempty"`
- // StorageAccount - The properties of the storage account for the container registry. Only applicable to Classic SKU.
- StorageAccount *StorageAccountProperties `json:"storageAccount,omitempty"`
- // NetworkRuleSet - The network rule set for a container registry.
- NetworkRuleSet *NetworkRuleSet `json:"networkRuleSet,omitempty"`
- // Policies - The policies for a container registry.
- Policies *Policies `json:"policies,omitempty"`
-}
-
-// RegistryPropertiesUpdateParameters the parameters for updating the properties of a container registry.
-type RegistryPropertiesUpdateParameters struct {
- // AdminUserEnabled - The value that indicates whether the admin user is enabled.
- AdminUserEnabled *bool `json:"adminUserEnabled,omitempty"`
- // NetworkRuleSet - The network rule set for a container registry.
- NetworkRuleSet *NetworkRuleSet `json:"networkRuleSet,omitempty"`
- // Policies - The policies for a container registry.
- Policies *Policies `json:"policies,omitempty"`
-}
-
-// RegistryUpdateParameters the parameters for updating a container registry.
-type RegistryUpdateParameters struct {
- // Tags - The tags for the container registry.
- Tags map[string]*string `json:"tags"`
- // Sku - The SKU of the container registry.
- Sku *Sku `json:"sku,omitempty"`
- // RegistryPropertiesUpdateParameters - The properties that the container registry will be updated with.
- *RegistryPropertiesUpdateParameters `json:"properties,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for RegistryUpdateParameters.
-func (rup RegistryUpdateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if rup.Tags != nil {
- objectMap["tags"] = rup.Tags
- }
- if rup.Sku != nil {
- objectMap["sku"] = rup.Sku
- }
- if rup.RegistryPropertiesUpdateParameters != nil {
- objectMap["properties"] = rup.RegistryPropertiesUpdateParameters
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for RegistryUpdateParameters struct.
-func (rup *RegistryUpdateParameters) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- rup.Tags = tags
- }
- case "sku":
- if v != nil {
- var sku Sku
- err = json.Unmarshal(*v, &sku)
- if err != nil {
- return err
- }
- rup.Sku = &sku
- }
- case "properties":
- if v != nil {
- var registryPropertiesUpdateParameters RegistryPropertiesUpdateParameters
- err = json.Unmarshal(*v, ®istryPropertiesUpdateParameters)
- if err != nil {
- return err
- }
- rup.RegistryPropertiesUpdateParameters = ®istryPropertiesUpdateParameters
- }
- }
- }
-
- return nil
-}
-
-// RegistryUsage the quota usage for a container registry.
-type RegistryUsage struct {
- // Name - The name of the usage.
- Name *string `json:"name,omitempty"`
- // Limit - The limit of the usage.
- Limit *int64 `json:"limit,omitempty"`
- // CurrentValue - The current value of the usage.
- CurrentValue *int64 `json:"currentValue,omitempty"`
- // Unit - The unit of measurement. Possible values include: 'Count', 'Bytes'
- Unit RegistryUsageUnit `json:"unit,omitempty"`
-}
-
-// RegistryUsageListResult the result of a request to get container registry quota usages.
-type RegistryUsageListResult struct {
- autorest.Response `json:"-"`
- // Value - The list of container registry quota usages.
- Value *[]RegistryUsage `json:"value,omitempty"`
-}
-
-// Replication an object that represents a replication for a container registry.
-type Replication struct {
- autorest.Response `json:"-"`
- // ReplicationProperties - The properties of the replication.
- *ReplicationProperties `json:"properties,omitempty"`
- // ID - READ-ONLY; The resource ID.
- ID *string `json:"id,omitempty"`
- // Name - READ-ONLY; The name of the resource.
- Name *string `json:"name,omitempty"`
- // Type - READ-ONLY; The type of the resource.
- Type *string `json:"type,omitempty"`
- // Location - The location of the resource. This cannot be changed after the resource is created.
- Location *string `json:"location,omitempty"`
- // Tags - The tags of the resource.
- Tags map[string]*string `json:"tags"`
-}
-
-// MarshalJSON is the custom marshaler for Replication.
-func (r Replication) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if r.ReplicationProperties != nil {
- objectMap["properties"] = r.ReplicationProperties
- }
- if r.Location != nil {
- objectMap["location"] = r.Location
- }
- if r.Tags != nil {
- objectMap["tags"] = r.Tags
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for Replication struct.
-func (r *Replication) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "properties":
- if v != nil {
- var replicationProperties ReplicationProperties
- err = json.Unmarshal(*v, &replicationProperties)
- if err != nil {
- return err
- }
- r.ReplicationProperties = &replicationProperties
- }
- case "id":
- if v != nil {
- var ID string
- err = json.Unmarshal(*v, &ID)
- if err != nil {
- return err
- }
- r.ID = &ID
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- r.Name = &name
- }
- case "type":
- if v != nil {
- var typeVar string
- err = json.Unmarshal(*v, &typeVar)
- if err != nil {
- return err
- }
- r.Type = &typeVar
- }
- case "location":
- if v != nil {
- var location string
- err = json.Unmarshal(*v, &location)
- if err != nil {
- return err
- }
- r.Location = &location
- }
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- r.Tags = tags
- }
- }
- }
-
- return nil
-}
-
-// ReplicationListResult the result of a request to list replications for a container registry.
-type ReplicationListResult struct {
- autorest.Response `json:"-"`
- // Value - The list of replications. Since this list may be incomplete, the nextLink field should be used to request the next list of replications.
- Value *[]Replication `json:"value,omitempty"`
- // NextLink - The URI that can be used to request the next list of replications.
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// ReplicationListResultIterator provides access to a complete listing of Replication values.
-type ReplicationListResultIterator struct {
- i int
- page ReplicationListResultPage
-}
-
-// NextWithContext advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *ReplicationListResultIterator) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationListResultIterator.NextWithContext")
- defer func() {
- sc := -1
- if iter.Response().Response.Response != nil {
- sc = iter.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err = iter.page.NextWithContext(ctx)
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (iter *ReplicationListResultIterator) Next() error {
- return iter.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter ReplicationListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter ReplicationListResultIterator) Response() ReplicationListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter ReplicationListResultIterator) Value() Replication {
- if !iter.page.NotDone() {
- return Replication{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// Creates a new instance of the ReplicationListResultIterator type.
-func NewReplicationListResultIterator(page ReplicationListResultPage) ReplicationListResultIterator {
- return ReplicationListResultIterator{page: page}
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (rlr ReplicationListResult) IsEmpty() bool {
- return rlr.Value == nil || len(*rlr.Value) == 0
-}
-
-// replicationListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (rlr ReplicationListResult) replicationListResultPreparer(ctx context.Context) (*http.Request, error) {
- if rlr.NextLink == nil || len(to.String(rlr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare((&http.Request{}).WithContext(ctx),
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(rlr.NextLink)))
-}
-
-// ReplicationListResultPage contains a page of Replication values.
-type ReplicationListResultPage struct {
- fn func(context.Context, ReplicationListResult) (ReplicationListResult, error)
- rlr ReplicationListResult
-}
-
-// NextWithContext advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *ReplicationListResultPage) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationListResultPage.NextWithContext")
- defer func() {
- sc := -1
- if page.Response().Response.Response != nil {
- sc = page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- next, err := page.fn(ctx, page.rlr)
- if err != nil {
- return err
- }
- page.rlr = next
- return nil
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (page *ReplicationListResultPage) Next() error {
- return page.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page ReplicationListResultPage) NotDone() bool {
- return !page.rlr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page ReplicationListResultPage) Response() ReplicationListResult {
- return page.rlr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page ReplicationListResultPage) Values() []Replication {
- if page.rlr.IsEmpty() {
- return nil
- }
- return *page.rlr.Value
-}
-
-// Creates a new instance of the ReplicationListResultPage type.
-func NewReplicationListResultPage(getNextPage func(context.Context, ReplicationListResult) (ReplicationListResult, error)) ReplicationListResultPage {
- return ReplicationListResultPage{fn: getNextPage}
-}
-
-// ReplicationProperties the properties of a replication.
-type ReplicationProperties struct {
- // ProvisioningState - READ-ONLY; The provisioning state of the replication at the time the operation was called. Possible values include: 'Creating', 'Updating', 'Deleting', 'Succeeded', 'Failed', 'Canceled'
- ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
- // Status - READ-ONLY; The status of the replication at the time the operation was called.
- Status *Status `json:"status,omitempty"`
-}
-
-// ReplicationsCreateFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type ReplicationsCreateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *ReplicationsCreateFuture) Result(client ReplicationsClient) (r Replication, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsCreateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.ReplicationsCreateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if r.Response.Response, err = future.GetResult(sender); err == nil && r.Response.Response.StatusCode != http.StatusNoContent {
- r, err = client.CreateResponder(r.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsCreateFuture", "Result", r.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// ReplicationsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type ReplicationsDeleteFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *ReplicationsDeleteFuture) Result(client ReplicationsClient) (ar autorest.Response, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsDeleteFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.ReplicationsDeleteFuture")
- return
- }
- ar.Response = future.Response()
- return
-}
-
-// ReplicationsUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type ReplicationsUpdateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *ReplicationsUpdateFuture) Result(client ReplicationsClient) (r Replication, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsUpdateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.ReplicationsUpdateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if r.Response.Response, err = future.GetResult(sender); err == nil && r.Response.Response.StatusCode != http.StatusNoContent {
- r, err = client.UpdateResponder(r.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsUpdateFuture", "Result", r.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// ReplicationUpdateParameters the parameters for updating a replication.
-type ReplicationUpdateParameters struct {
- // Tags - The tags for the replication.
- Tags map[string]*string `json:"tags"`
-}
-
-// MarshalJSON is the custom marshaler for ReplicationUpdateParameters.
-func (rup ReplicationUpdateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if rup.Tags != nil {
- objectMap["tags"] = rup.Tags
- }
- return json.Marshal(objectMap)
-}
-
-// Request the request that generated the event.
-type Request struct {
- // ID - The ID of the request that initiated the event.
- ID *string `json:"id,omitempty"`
- // Addr - The IP or hostname and possibly port of the client connection that initiated the event. This is the RemoteAddr from the standard http request.
- Addr *string `json:"addr,omitempty"`
- // Host - The externally accessible hostname of the registry instance, as specified by the http host header on incoming requests.
- Host *string `json:"host,omitempty"`
- // Method - The request method that generated the event.
- Method *string `json:"method,omitempty"`
- // Useragent - The user agent header of the request.
- Useragent *string `json:"useragent,omitempty"`
-}
-
-// Resource an Azure resource.
-type Resource struct {
- // ID - READ-ONLY; The resource ID.
- ID *string `json:"id,omitempty"`
- // Name - READ-ONLY; The name of the resource.
- Name *string `json:"name,omitempty"`
- // Type - READ-ONLY; The type of the resource.
- Type *string `json:"type,omitempty"`
- // Location - The location of the resource. This cannot be changed after the resource is created.
- Location *string `json:"location,omitempty"`
- // Tags - The tags of the resource.
- Tags map[string]*string `json:"tags"`
-}
-
-// MarshalJSON is the custom marshaler for Resource.
-func (r Resource) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if r.Location != nil {
- objectMap["location"] = r.Location
- }
- if r.Tags != nil {
- objectMap["tags"] = r.Tags
- }
- return json.Marshal(objectMap)
-}
-
-// RetentionPolicy the retention policy for a container registry.
-type RetentionPolicy struct {
- // Days - The number of days to retain an untagged manifest after which it gets purged.
- Days *int32 `json:"days,omitempty"`
- // LastUpdatedTime - READ-ONLY; The timestamp when the policy was last updated.
- LastUpdatedTime *date.Time `json:"lastUpdatedTime,omitempty"`
- // Status - The value that indicates whether the policy is enabled or not. Possible values include: 'Enabled', 'Disabled'
- Status PolicyStatus `json:"status,omitempty"`
-}
-
-// Run run resource properties
-type Run struct {
- autorest.Response `json:"-"`
- // RunProperties - The properties of a run.
- *RunProperties `json:"properties,omitempty"`
- // ID - READ-ONLY; The resource ID.
- ID *string `json:"id,omitempty"`
- // Name - READ-ONLY; The name of the resource.
- Name *string `json:"name,omitempty"`
- // Type - READ-ONLY; The type of the resource.
- Type *string `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for Run.
-func (r Run) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if r.RunProperties != nil {
- objectMap["properties"] = r.RunProperties
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for Run struct.
-func (r *Run) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "properties":
- if v != nil {
- var runProperties RunProperties
- err = json.Unmarshal(*v, &runProperties)
- if err != nil {
- return err
- }
- r.RunProperties = &runProperties
- }
- case "id":
- if v != nil {
- var ID string
- err = json.Unmarshal(*v, &ID)
- if err != nil {
- return err
- }
- r.ID = &ID
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- r.Name = &name
- }
- case "type":
- if v != nil {
- var typeVar string
- err = json.Unmarshal(*v, &typeVar)
- if err != nil {
- return err
- }
- r.Type = &typeVar
- }
- }
- }
-
- return nil
-}
-
-// RunFilter properties that are enabled for Odata querying on runs.
-type RunFilter struct {
- // RunID - The unique identifier for the run.
- RunID *string `json:"runId,omitempty"`
- // RunType - The type of run. Possible values include: 'QuickBuild', 'QuickRun', 'AutoBuild', 'AutoRun'
- RunType RunType `json:"runType,omitempty"`
- // Status - The current status of the run. Possible values include: 'RunStatusQueued', 'RunStatusStarted', 'RunStatusRunning', 'RunStatusSucceeded', 'RunStatusFailed', 'RunStatusCanceled', 'RunStatusError', 'RunStatusTimeout'
- Status RunStatus `json:"status,omitempty"`
- // CreateTime - The create time for a run.
- CreateTime *date.Time `json:"createTime,omitempty"`
- // FinishTime - The time the run finished.
- FinishTime *date.Time `json:"finishTime,omitempty"`
- // OutputImageManifests - The list of comma-separated image manifests that were generated from the run. This is applicable if the run is of
- // build type.
- OutputImageManifests *string `json:"outputImageManifests,omitempty"`
- // IsArchiveEnabled - The value that indicates whether archiving is enabled or not.
- IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
- // TaskName - The name of the task that the run corresponds to.
- TaskName *string `json:"taskName,omitempty"`
-}
-
-// RunGetLogResult the result of get log link operation.
-type RunGetLogResult struct {
- autorest.Response `json:"-"`
- // LogLink - The link to logs for a run on a azure container registry.
- LogLink *string `json:"logLink,omitempty"`
-}
-
-// RunListResult collection of runs.
-type RunListResult struct {
- autorest.Response `json:"-"`
- // Value - The collection value.
- Value *[]Run `json:"value,omitempty"`
- // NextLink - The URI that can be used to request the next set of paged results.
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// RunListResultIterator provides access to a complete listing of Run values.
-type RunListResultIterator struct {
- i int
- page RunListResultPage
-}
-
-// NextWithContext advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *RunListResultIterator) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RunListResultIterator.NextWithContext")
- defer func() {
- sc := -1
- if iter.Response().Response.Response != nil {
- sc = iter.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err = iter.page.NextWithContext(ctx)
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (iter *RunListResultIterator) Next() error {
- return iter.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter RunListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter RunListResultIterator) Response() RunListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter RunListResultIterator) Value() Run {
- if !iter.page.NotDone() {
- return Run{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// Creates a new instance of the RunListResultIterator type.
-func NewRunListResultIterator(page RunListResultPage) RunListResultIterator {
- return RunListResultIterator{page: page}
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (rlr RunListResult) IsEmpty() bool {
- return rlr.Value == nil || len(*rlr.Value) == 0
-}
-
-// runListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (rlr RunListResult) runListResultPreparer(ctx context.Context) (*http.Request, error) {
- if rlr.NextLink == nil || len(to.String(rlr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare((&http.Request{}).WithContext(ctx),
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(rlr.NextLink)))
-}
-
-// RunListResultPage contains a page of Run values.
-type RunListResultPage struct {
- fn func(context.Context, RunListResult) (RunListResult, error)
- rlr RunListResult
-}
-
-// NextWithContext advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *RunListResultPage) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RunListResultPage.NextWithContext")
- defer func() {
- sc := -1
- if page.Response().Response.Response != nil {
- sc = page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- next, err := page.fn(ctx, page.rlr)
- if err != nil {
- return err
- }
- page.rlr = next
- return nil
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (page *RunListResultPage) Next() error {
- return page.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page RunListResultPage) NotDone() bool {
- return !page.rlr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page RunListResultPage) Response() RunListResult {
- return page.rlr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page RunListResultPage) Values() []Run {
- if page.rlr.IsEmpty() {
- return nil
- }
- return *page.rlr.Value
-}
-
-// Creates a new instance of the RunListResultPage type.
-func NewRunListResultPage(getNextPage func(context.Context, RunListResult) (RunListResult, error)) RunListResultPage {
- return RunListResultPage{fn: getNextPage}
-}
-
-// RunProperties the properties for a run.
-type RunProperties struct {
- // RunID - The unique identifier for the run.
- RunID *string `json:"runId,omitempty"`
- // Status - The current status of the run. Possible values include: 'RunStatusQueued', 'RunStatusStarted', 'RunStatusRunning', 'RunStatusSucceeded', 'RunStatusFailed', 'RunStatusCanceled', 'RunStatusError', 'RunStatusTimeout'
- Status RunStatus `json:"status,omitempty"`
- // LastUpdatedTime - The last updated time for the run.
- LastUpdatedTime *date.Time `json:"lastUpdatedTime,omitempty"`
- // RunType - The type of run. Possible values include: 'QuickBuild', 'QuickRun', 'AutoBuild', 'AutoRun'
- RunType RunType `json:"runType,omitempty"`
- // CreateTime - The time the run was scheduled.
- CreateTime *date.Time `json:"createTime,omitempty"`
- // StartTime - The time the run started.
- StartTime *date.Time `json:"startTime,omitempty"`
- // FinishTime - The time the run finished.
- FinishTime *date.Time `json:"finishTime,omitempty"`
- // OutputImages - The list of all images that were generated from the run. This is applicable if the run generates base image dependencies.
- OutputImages *[]ImageDescriptor `json:"outputImages,omitempty"`
- // Task - The task against which run was scheduled.
- Task *string `json:"task,omitempty"`
- // ImageUpdateTrigger - The image update trigger that caused the run. This is applicable if the task has base image trigger configured.
- ImageUpdateTrigger *ImageUpdateTrigger `json:"imageUpdateTrigger,omitempty"`
- // SourceTrigger - The source trigger that caused the run.
- SourceTrigger *SourceTriggerDescriptor `json:"sourceTrigger,omitempty"`
- // Platform - The platform properties against which the run will happen.
- Platform *PlatformProperties `json:"platform,omitempty"`
- // AgentConfiguration - The machine configuration of the run agent.
- AgentConfiguration *AgentProperties `json:"agentConfiguration,omitempty"`
- // SourceRegistryAuth - The scope of the credentials that were used to login to the source registry during this run.
- SourceRegistryAuth *string `json:"sourceRegistryAuth,omitempty"`
- // CustomRegistries - The list of custom registries that were logged in during this run.
- CustomRegistries *[]string `json:"customRegistries,omitempty"`
- // RunErrorMessage - READ-ONLY; The error message received from backend systems after the run is scheduled.
- RunErrorMessage *string `json:"runErrorMessage,omitempty"`
- // ProvisioningState - The provisioning state of a run. Possible values include: 'Creating', 'Updating', 'Deleting', 'Succeeded', 'Failed', 'Canceled'
- ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
- // IsArchiveEnabled - The value that indicates whether archiving is enabled or not.
- IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
- // TimerTrigger - The timer trigger that caused the run.
- TimerTrigger *TimerTriggerDescriptor `json:"timerTrigger,omitempty"`
-}
-
-// BasicRunRequest the request parameters for scheduling a run.
-type BasicRunRequest interface {
- AsDockerBuildRequest() (*DockerBuildRequest, bool)
- AsFileTaskRunRequest() (*FileTaskRunRequest, bool)
- AsTaskRunRequest() (*TaskRunRequest, bool)
- AsEncodedTaskRunRequest() (*EncodedTaskRunRequest, bool)
- AsRunRequest() (*RunRequest, bool)
-}
-
-// RunRequest the request parameters for scheduling a run.
-type RunRequest struct {
- // IsArchiveEnabled - The value that indicates whether archiving is enabled for the run or not.
- IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
- // Type - Possible values include: 'TypeRunRequest', 'TypeDockerBuildRequest', 'TypeFileTaskRunRequest', 'TypeTaskRunRequest', 'TypeEncodedTaskRunRequest'
- Type Type `json:"type,omitempty"`
-}
-
-func unmarshalBasicRunRequest(body []byte) (BasicRunRequest, error) {
- var m map[string]interface{}
- err := json.Unmarshal(body, &m)
- if err != nil {
- return nil, err
- }
-
- switch m["type"] {
- case string(TypeDockerBuildRequest):
- var dbr DockerBuildRequest
- err := json.Unmarshal(body, &dbr)
- return dbr, err
- case string(TypeFileTaskRunRequest):
- var ftrr FileTaskRunRequest
- err := json.Unmarshal(body, &ftrr)
- return ftrr, err
- case string(TypeTaskRunRequest):
- var trr TaskRunRequest
- err := json.Unmarshal(body, &trr)
- return trr, err
- case string(TypeEncodedTaskRunRequest):
- var etrr EncodedTaskRunRequest
- err := json.Unmarshal(body, &etrr)
- return etrr, err
- default:
- var rr RunRequest
- err := json.Unmarshal(body, &rr)
- return rr, err
- }
-}
-func unmarshalBasicRunRequestArray(body []byte) ([]BasicRunRequest, error) {
- var rawMessages []*json.RawMessage
- err := json.Unmarshal(body, &rawMessages)
- if err != nil {
- return nil, err
- }
-
- rrArray := make([]BasicRunRequest, len(rawMessages))
-
- for index, rawMessage := range rawMessages {
- rr, err := unmarshalBasicRunRequest(*rawMessage)
- if err != nil {
- return nil, err
- }
- rrArray[index] = rr
- }
- return rrArray, nil
-}
-
-// MarshalJSON is the custom marshaler for RunRequest.
-func (rr RunRequest) MarshalJSON() ([]byte, error) {
- rr.Type = TypeRunRequest
- objectMap := make(map[string]interface{})
- if rr.IsArchiveEnabled != nil {
- objectMap["isArchiveEnabled"] = rr.IsArchiveEnabled
- }
- if rr.Type != "" {
- objectMap["type"] = rr.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildRequest is the BasicRunRequest implementation for RunRequest.
-func (rr RunRequest) AsDockerBuildRequest() (*DockerBuildRequest, bool) {
- return nil, false
-}
-
-// AsFileTaskRunRequest is the BasicRunRequest implementation for RunRequest.
-func (rr RunRequest) AsFileTaskRunRequest() (*FileTaskRunRequest, bool) {
- return nil, false
-}
-
-// AsTaskRunRequest is the BasicRunRequest implementation for RunRequest.
-func (rr RunRequest) AsTaskRunRequest() (*TaskRunRequest, bool) {
- return nil, false
-}
-
-// AsEncodedTaskRunRequest is the BasicRunRequest implementation for RunRequest.
-func (rr RunRequest) AsEncodedTaskRunRequest() (*EncodedTaskRunRequest, bool) {
- return nil, false
-}
-
-// AsRunRequest is the BasicRunRequest implementation for RunRequest.
-func (rr RunRequest) AsRunRequest() (*RunRequest, bool) {
- return &rr, true
-}
-
-// AsBasicRunRequest is the BasicRunRequest implementation for RunRequest.
-func (rr RunRequest) AsBasicRunRequest() (BasicRunRequest, bool) {
- return &rr, true
-}
-
-// RunsCancelFuture an abstraction for monitoring and retrieving the results of a long-running operation.
-type RunsCancelFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *RunsCancelFuture) Result(client RunsClient) (ar autorest.Response, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsCancelFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.RunsCancelFuture")
- return
- }
- ar.Response = future.Response()
- return
-}
-
-// RunsUpdateFuture an abstraction for monitoring and retrieving the results of a long-running operation.
-type RunsUpdateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *RunsUpdateFuture) Result(client RunsClient) (r Run, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsUpdateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.RunsUpdateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if r.Response.Response, err = future.GetResult(sender); err == nil && r.Response.Response.StatusCode != http.StatusNoContent {
- r, err = client.UpdateResponder(r.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsUpdateFuture", "Result", r.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// RunUpdateParameters the set of run properties that can be updated.
-type RunUpdateParameters struct {
- // IsArchiveEnabled - The value that indicates whether archiving is enabled or not.
- IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
-}
-
-// SecretObject describes the properties of a secret object value.
-type SecretObject struct {
- // Value - The value of the secret. The format of this value will be determined
- // based on the type of the secret object. If the type is Opaque, the value will be
- // used as is without any modification.
- Value *string `json:"value,omitempty"`
- // Type - The type of the secret object which determines how the value of the secret object has to be
- // interpreted. Possible values include: 'Opaque', 'Vaultsecret'
- Type SecretObjectType `json:"type,omitempty"`
-}
-
-// SetValue the properties of a overridable value that can be passed to a task template.
-type SetValue struct {
- // Name - The name of the overridable value.
- Name *string `json:"name,omitempty"`
- // Value - The overridable value.
- Value *string `json:"value,omitempty"`
- // IsSecret - Flag to indicate whether the value represents a secret or not.
- IsSecret *bool `json:"isSecret,omitempty"`
-}
-
-// Sku the SKU of a container registry.
-type Sku struct {
- // Name - The SKU name of the container registry. Required for registry creation. Possible values include: 'Classic', 'Basic', 'Standard', 'Premium'
- Name SkuName `json:"name,omitempty"`
- // Tier - READ-ONLY; The SKU tier based on the SKU name. Possible values include: 'SkuTierClassic', 'SkuTierBasic', 'SkuTierStandard', 'SkuTierPremium'
- Tier SkuTier `json:"tier,omitempty"`
-}
-
-// Source the registry node that generated the event. Put differently, while the actor initiates the event,
-// the source generates it.
-type Source struct {
- // Addr - The IP or hostname and the port of the registry node that generated the event. Generally, this will be resolved by os.Hostname() along with the running port.
- Addr *string `json:"addr,omitempty"`
- // InstanceID - The running instance of an application. Changes after each restart.
- InstanceID *string `json:"instanceID,omitempty"`
-}
-
-// SourceProperties the properties of the source code repository.
-type SourceProperties struct {
- // SourceControlType - The type of source control service. Possible values include: 'Github', 'VisualStudioTeamService'
- SourceControlType SourceControlType `json:"sourceControlType,omitempty"`
- // RepositoryURL - The full URL to the source code repository
- RepositoryURL *string `json:"repositoryUrl,omitempty"`
- // Branch - The branch name of the source code.
- Branch *string `json:"branch,omitempty"`
- // SourceControlAuthProperties - The authorization properties for accessing the source code repository and to set up
- // webhooks for notifications.
- SourceControlAuthProperties *AuthInfo `json:"sourceControlAuthProperties,omitempty"`
-}
-
-// SourceRegistryCredentials describes the credential parameters for accessing the source registry.
-type SourceRegistryCredentials struct {
- // LoginMode - The authentication mode which determines the source registry login scope. The credentials for the source registry
- // will be generated using the given scope. These credentials will be used to login to
- // the source registry during the run. Possible values include: 'SourceRegistryLoginModeNone', 'SourceRegistryLoginModeDefault'
- LoginMode SourceRegistryLoginMode `json:"loginMode,omitempty"`
-}
-
-// SourceTrigger the properties of a source based trigger.
-type SourceTrigger struct {
- // SourceRepository - The properties that describes the source(code) for the task.
- SourceRepository *SourceProperties `json:"sourceRepository,omitempty"`
- // SourceTriggerEvents - The source event corresponding to the trigger.
- SourceTriggerEvents *[]SourceTriggerEvent `json:"sourceTriggerEvents,omitempty"`
- // Status - The current status of trigger. Possible values include: 'TriggerStatusDisabled', 'TriggerStatusEnabled'
- Status TriggerStatus `json:"status,omitempty"`
- // Name - The name of the trigger.
- Name *string `json:"name,omitempty"`
-}
-
-// SourceTriggerDescriptor the source trigger that caused a run.
-type SourceTriggerDescriptor struct {
- // ID - The unique ID of the trigger.
- ID *string `json:"id,omitempty"`
- // EventType - The event type of the trigger.
- EventType *string `json:"eventType,omitempty"`
- // CommitID - The unique ID that identifies a commit.
- CommitID *string `json:"commitId,omitempty"`
- // PullRequestID - The unique ID that identifies pull request.
- PullRequestID *string `json:"pullRequestId,omitempty"`
- // RepositoryURL - The repository URL.
- RepositoryURL *string `json:"repositoryUrl,omitempty"`
- // BranchName - The branch name in the repository.
- BranchName *string `json:"branchName,omitempty"`
- // ProviderType - The source control provider type.
- ProviderType *string `json:"providerType,omitempty"`
-}
-
-// SourceTriggerUpdateParameters the properties for updating a source based trigger.
-type SourceTriggerUpdateParameters struct {
- // SourceRepository - The properties that describes the source(code) for the task.
- SourceRepository *SourceUpdateParameters `json:"sourceRepository,omitempty"`
- // SourceTriggerEvents - The source event corresponding to the trigger.
- SourceTriggerEvents *[]SourceTriggerEvent `json:"sourceTriggerEvents,omitempty"`
- // Status - The current status of trigger. Possible values include: 'TriggerStatusDisabled', 'TriggerStatusEnabled'
- Status TriggerStatus `json:"status,omitempty"`
- // Name - The name of the trigger.
- Name *string `json:"name,omitempty"`
-}
-
-// SourceUpdateParameters the properties for updating the source code repository.
-type SourceUpdateParameters struct {
- // SourceControlType - The type of source control service. Possible values include: 'Github', 'VisualStudioTeamService'
- SourceControlType SourceControlType `json:"sourceControlType,omitempty"`
- // RepositoryURL - The full URL to the source code repository
- RepositoryURL *string `json:"repositoryUrl,omitempty"`
- // Branch - The branch name of the source code.
- Branch *string `json:"branch,omitempty"`
- // SourceControlAuthProperties - The authorization properties for accessing the source code repository and to set up
- // webhooks for notifications.
- SourceControlAuthProperties *AuthInfoUpdateParameters `json:"sourceControlAuthProperties,omitempty"`
-}
-
-// SourceUploadDefinition the properties of a response to source upload request.
-type SourceUploadDefinition struct {
- autorest.Response `json:"-"`
- // UploadURL - The URL where the client can upload the source.
- UploadURL *string `json:"uploadUrl,omitempty"`
- // RelativePath - The relative path to the source. This is used to submit the subsequent queue build request.
- RelativePath *string `json:"relativePath,omitempty"`
-}
-
-// Status the status of an Azure resource at the time the operation was called.
-type Status struct {
- // DisplayStatus - READ-ONLY; The short label for the status.
- DisplayStatus *string `json:"displayStatus,omitempty"`
- // Message - READ-ONLY; The detailed message for the status, including alerts and error messages.
- Message *string `json:"message,omitempty"`
- // Timestamp - READ-ONLY; The timestamp when the status was changed to the current value.
- Timestamp *date.Time `json:"timestamp,omitempty"`
-}
-
-// StorageAccountProperties the properties of a storage account for a container registry. Only applicable
-// to Classic SKU.
-type StorageAccountProperties struct {
- // ID - The resource ID of the storage account.
- ID *string `json:"id,omitempty"`
-}
-
-// Target the target of the event.
-type Target struct {
- // MediaType - The MIME type of the referenced object.
- MediaType *string `json:"mediaType,omitempty"`
- // Size - The number of bytes of the content. Same as Length field.
- Size *int64 `json:"size,omitempty"`
- // Digest - The digest of the content, as defined by the Registry V2 HTTP API Specification.
- Digest *string `json:"digest,omitempty"`
- // Length - The number of bytes of the content. Same as Size field.
- Length *int64 `json:"length,omitempty"`
- // Repository - The repository name.
- Repository *string `json:"repository,omitempty"`
- // URL - The direct URL to the content.
- URL *string `json:"url,omitempty"`
- // Tag - The tag name.
- Tag *string `json:"tag,omitempty"`
- // Name - The name of the artifact.
- Name *string `json:"name,omitempty"`
- // Version - The version of the artifact.
- Version *string `json:"version,omitempty"`
-}
-
-// Task the task that has the ARM resource and task properties.
-// The task will have all information to schedule a run against it.
-type Task struct {
- autorest.Response `json:"-"`
- // Identity - Identity for the resource.
- Identity *IdentityProperties `json:"identity,omitempty"`
- // TaskProperties - The properties of a task.
- *TaskProperties `json:"properties,omitempty"`
- // ID - READ-ONLY; The resource ID.
- ID *string `json:"id,omitempty"`
- // Name - READ-ONLY; The name of the resource.
- Name *string `json:"name,omitempty"`
- // Type - READ-ONLY; The type of the resource.
- Type *string `json:"type,omitempty"`
- // Location - The location of the resource. This cannot be changed after the resource is created.
- Location *string `json:"location,omitempty"`
- // Tags - The tags of the resource.
- Tags map[string]*string `json:"tags"`
-}
-
-// MarshalJSON is the custom marshaler for Task.
-func (t Task) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if t.Identity != nil {
- objectMap["identity"] = t.Identity
- }
- if t.TaskProperties != nil {
- objectMap["properties"] = t.TaskProperties
- }
- if t.Location != nil {
- objectMap["location"] = t.Location
- }
- if t.Tags != nil {
- objectMap["tags"] = t.Tags
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for Task struct.
-func (t *Task) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "identity":
- if v != nil {
- var identity IdentityProperties
- err = json.Unmarshal(*v, &identity)
- if err != nil {
- return err
- }
- t.Identity = &identity
- }
- case "properties":
- if v != nil {
- var taskProperties TaskProperties
- err = json.Unmarshal(*v, &taskProperties)
- if err != nil {
- return err
- }
- t.TaskProperties = &taskProperties
- }
- case "id":
- if v != nil {
- var ID string
- err = json.Unmarshal(*v, &ID)
- if err != nil {
- return err
- }
- t.ID = &ID
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- t.Name = &name
- }
- case "type":
- if v != nil {
- var typeVar string
- err = json.Unmarshal(*v, &typeVar)
- if err != nil {
- return err
- }
- t.Type = &typeVar
- }
- case "location":
- if v != nil {
- var location string
- err = json.Unmarshal(*v, &location)
- if err != nil {
- return err
- }
- t.Location = &location
- }
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- t.Tags = tags
- }
- }
- }
-
- return nil
-}
-
-// TaskListResult the collection of tasks.
-type TaskListResult struct {
- autorest.Response `json:"-"`
- // Value - The collection value.
- Value *[]Task `json:"value,omitempty"`
- // NextLink - The URI that can be used to request the next set of paged results.
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// TaskListResultIterator provides access to a complete listing of Task values.
-type TaskListResultIterator struct {
- i int
- page TaskListResultPage
-}
-
-// NextWithContext advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *TaskListResultIterator) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TaskListResultIterator.NextWithContext")
- defer func() {
- sc := -1
- if iter.Response().Response.Response != nil {
- sc = iter.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err = iter.page.NextWithContext(ctx)
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (iter *TaskListResultIterator) Next() error {
- return iter.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter TaskListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter TaskListResultIterator) Response() TaskListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter TaskListResultIterator) Value() Task {
- if !iter.page.NotDone() {
- return Task{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// Creates a new instance of the TaskListResultIterator type.
-func NewTaskListResultIterator(page TaskListResultPage) TaskListResultIterator {
- return TaskListResultIterator{page: page}
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (tlr TaskListResult) IsEmpty() bool {
- return tlr.Value == nil || len(*tlr.Value) == 0
-}
-
-// taskListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (tlr TaskListResult) taskListResultPreparer(ctx context.Context) (*http.Request, error) {
- if tlr.NextLink == nil || len(to.String(tlr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare((&http.Request{}).WithContext(ctx),
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(tlr.NextLink)))
-}
-
-// TaskListResultPage contains a page of Task values.
-type TaskListResultPage struct {
- fn func(context.Context, TaskListResult) (TaskListResult, error)
- tlr TaskListResult
-}
-
-// NextWithContext advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *TaskListResultPage) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TaskListResultPage.NextWithContext")
- defer func() {
- sc := -1
- if page.Response().Response.Response != nil {
- sc = page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- next, err := page.fn(ctx, page.tlr)
- if err != nil {
- return err
- }
- page.tlr = next
- return nil
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (page *TaskListResultPage) Next() error {
- return page.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page TaskListResultPage) NotDone() bool {
- return !page.tlr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page TaskListResultPage) Response() TaskListResult {
- return page.tlr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page TaskListResultPage) Values() []Task {
- if page.tlr.IsEmpty() {
- return nil
- }
- return *page.tlr.Value
-}
-
-// Creates a new instance of the TaskListResultPage type.
-func NewTaskListResultPage(getNextPage func(context.Context, TaskListResult) (TaskListResult, error)) TaskListResultPage {
- return TaskListResultPage{fn: getNextPage}
-}
-
-// TaskProperties the properties of a task.
-type TaskProperties struct {
- // ProvisioningState - READ-ONLY; The provisioning state of the task. Possible values include: 'Creating', 'Updating', 'Deleting', 'Succeeded', 'Failed', 'Canceled'
- ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
- // CreationDate - READ-ONLY; The creation date of task.
- CreationDate *date.Time `json:"creationDate,omitempty"`
- // Status - The current status of task. Possible values include: 'TaskStatusDisabled', 'TaskStatusEnabled'
- Status TaskStatus `json:"status,omitempty"`
- // Platform - The platform properties against which the run has to happen.
- Platform *PlatformProperties `json:"platform,omitempty"`
- // AgentConfiguration - The machine configuration of the run agent.
- AgentConfiguration *AgentProperties `json:"agentConfiguration,omitempty"`
- // Timeout - Run timeout in seconds.
- Timeout *int32 `json:"timeout,omitempty"`
- // Step - The properties of a task step.
- Step BasicTaskStepProperties `json:"step,omitempty"`
- // Trigger - The properties that describe all triggers for the task.
- Trigger *TriggerProperties `json:"trigger,omitempty"`
- // Credentials - The properties that describes a set of credentials that will be used when this run is invoked.
- Credentials *Credentials `json:"credentials,omitempty"`
-}
-
-// UnmarshalJSON is the custom unmarshaler for TaskProperties struct.
-func (tp *TaskProperties) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "provisioningState":
- if v != nil {
- var provisioningState ProvisioningState
- err = json.Unmarshal(*v, &provisioningState)
- if err != nil {
- return err
- }
- tp.ProvisioningState = provisioningState
- }
- case "creationDate":
- if v != nil {
- var creationDate date.Time
- err = json.Unmarshal(*v, &creationDate)
- if err != nil {
- return err
- }
- tp.CreationDate = &creationDate
- }
- case "status":
- if v != nil {
- var status TaskStatus
- err = json.Unmarshal(*v, &status)
- if err != nil {
- return err
- }
- tp.Status = status
- }
- case "platform":
- if v != nil {
- var platform PlatformProperties
- err = json.Unmarshal(*v, &platform)
- if err != nil {
- return err
- }
- tp.Platform = &platform
- }
- case "agentConfiguration":
- if v != nil {
- var agentConfiguration AgentProperties
- err = json.Unmarshal(*v, &agentConfiguration)
- if err != nil {
- return err
- }
- tp.AgentConfiguration = &agentConfiguration
- }
- case "timeout":
- if v != nil {
- var timeout int32
- err = json.Unmarshal(*v, &timeout)
- if err != nil {
- return err
- }
- tp.Timeout = &timeout
- }
- case "step":
- if v != nil {
- step, err := unmarshalBasicTaskStepProperties(*v)
- if err != nil {
- return err
- }
- tp.Step = step
- }
- case "trigger":
- if v != nil {
- var trigger TriggerProperties
- err = json.Unmarshal(*v, &trigger)
- if err != nil {
- return err
- }
- tp.Trigger = &trigger
- }
- case "credentials":
- if v != nil {
- var credentials Credentials
- err = json.Unmarshal(*v, &credentials)
- if err != nil {
- return err
- }
- tp.Credentials = &credentials
- }
- }
- }
-
- return nil
-}
-
-// TaskPropertiesUpdateParameters the properties for updating a task.
-type TaskPropertiesUpdateParameters struct {
- // Status - The current status of task. Possible values include: 'TaskStatusDisabled', 'TaskStatusEnabled'
- Status TaskStatus `json:"status,omitempty"`
- // Platform - The platform properties against which the run has to happen.
- Platform *PlatformUpdateParameters `json:"platform,omitempty"`
- // AgentConfiguration - The machine configuration of the run agent.
- AgentConfiguration *AgentProperties `json:"agentConfiguration,omitempty"`
- // Timeout - Run timeout in seconds.
- Timeout *int32 `json:"timeout,omitempty"`
- // Step - The properties for updating a task step.
- Step BasicTaskStepUpdateParameters `json:"step,omitempty"`
- // Trigger - The properties for updating trigger properties.
- Trigger *TriggerUpdateParameters `json:"trigger,omitempty"`
- // Credentials - The parameters that describes a set of credentials that will be used when this run is invoked.
- Credentials *Credentials `json:"credentials,omitempty"`
-}
-
-// UnmarshalJSON is the custom unmarshaler for TaskPropertiesUpdateParameters struct.
-func (tpup *TaskPropertiesUpdateParameters) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "status":
- if v != nil {
- var status TaskStatus
- err = json.Unmarshal(*v, &status)
- if err != nil {
- return err
- }
- tpup.Status = status
- }
- case "platform":
- if v != nil {
- var platform PlatformUpdateParameters
- err = json.Unmarshal(*v, &platform)
- if err != nil {
- return err
- }
- tpup.Platform = &platform
- }
- case "agentConfiguration":
- if v != nil {
- var agentConfiguration AgentProperties
- err = json.Unmarshal(*v, &agentConfiguration)
- if err != nil {
- return err
- }
- tpup.AgentConfiguration = &agentConfiguration
- }
- case "timeout":
- if v != nil {
- var timeout int32
- err = json.Unmarshal(*v, &timeout)
- if err != nil {
- return err
- }
- tpup.Timeout = &timeout
- }
- case "step":
- if v != nil {
- step, err := unmarshalBasicTaskStepUpdateParameters(*v)
- if err != nil {
- return err
- }
- tpup.Step = step
- }
- case "trigger":
- if v != nil {
- var trigger TriggerUpdateParameters
- err = json.Unmarshal(*v, &trigger)
- if err != nil {
- return err
- }
- tpup.Trigger = &trigger
- }
- case "credentials":
- if v != nil {
- var credentials Credentials
- err = json.Unmarshal(*v, &credentials)
- if err != nil {
- return err
- }
- tpup.Credentials = &credentials
- }
- }
- }
-
- return nil
-}
-
-// TaskRunRequest the parameters for a task run request.
-type TaskRunRequest struct {
- // TaskName - The name of task against which run has to be queued.
- TaskName *string `json:"taskName,omitempty"`
- // Values - The collection of overridable values that can be passed when running a task.
- Values *[]SetValue `json:"values,omitempty"`
- // IsArchiveEnabled - The value that indicates whether archiving is enabled for the run or not.
- IsArchiveEnabled *bool `json:"isArchiveEnabled,omitempty"`
- // Type - Possible values include: 'TypeRunRequest', 'TypeDockerBuildRequest', 'TypeFileTaskRunRequest', 'TypeTaskRunRequest', 'TypeEncodedTaskRunRequest'
- Type Type `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for TaskRunRequest.
-func (trr TaskRunRequest) MarshalJSON() ([]byte, error) {
- trr.Type = TypeTaskRunRequest
- objectMap := make(map[string]interface{})
- if trr.TaskName != nil {
- objectMap["taskName"] = trr.TaskName
- }
- if trr.Values != nil {
- objectMap["values"] = trr.Values
- }
- if trr.IsArchiveEnabled != nil {
- objectMap["isArchiveEnabled"] = trr.IsArchiveEnabled
- }
- if trr.Type != "" {
- objectMap["type"] = trr.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildRequest is the BasicRunRequest implementation for TaskRunRequest.
-func (trr TaskRunRequest) AsDockerBuildRequest() (*DockerBuildRequest, bool) {
- return nil, false
-}
-
-// AsFileTaskRunRequest is the BasicRunRequest implementation for TaskRunRequest.
-func (trr TaskRunRequest) AsFileTaskRunRequest() (*FileTaskRunRequest, bool) {
- return nil, false
-}
-
-// AsTaskRunRequest is the BasicRunRequest implementation for TaskRunRequest.
-func (trr TaskRunRequest) AsTaskRunRequest() (*TaskRunRequest, bool) {
- return &trr, true
-}
-
-// AsEncodedTaskRunRequest is the BasicRunRequest implementation for TaskRunRequest.
-func (trr TaskRunRequest) AsEncodedTaskRunRequest() (*EncodedTaskRunRequest, bool) {
- return nil, false
-}
-
-// AsRunRequest is the BasicRunRequest implementation for TaskRunRequest.
-func (trr TaskRunRequest) AsRunRequest() (*RunRequest, bool) {
- return nil, false
-}
-
-// AsBasicRunRequest is the BasicRunRequest implementation for TaskRunRequest.
-func (trr TaskRunRequest) AsBasicRunRequest() (BasicRunRequest, bool) {
- return &trr, true
-}
-
-// TasksCreateFuture an abstraction for monitoring and retrieving the results of a long-running operation.
-type TasksCreateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *TasksCreateFuture) Result(client TasksClient) (t Task, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksCreateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.TasksCreateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if t.Response.Response, err = future.GetResult(sender); err == nil && t.Response.Response.StatusCode != http.StatusNoContent {
- t, err = client.CreateResponder(t.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksCreateFuture", "Result", t.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// TasksDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
-type TasksDeleteFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *TasksDeleteFuture) Result(client TasksClient) (ar autorest.Response, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksDeleteFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.TasksDeleteFuture")
- return
- }
- ar.Response = future.Response()
- return
-}
-
-// BasicTaskStepProperties base properties for any task step.
-type BasicTaskStepProperties interface {
- AsDockerBuildStep() (*DockerBuildStep, bool)
- AsFileTaskStep() (*FileTaskStep, bool)
- AsEncodedTaskStep() (*EncodedTaskStep, bool)
- AsTaskStepProperties() (*TaskStepProperties, bool)
-}
-
-// TaskStepProperties base properties for any task step.
-type TaskStepProperties struct {
- // BaseImageDependencies - READ-ONLY; List of base image dependencies for a step.
- BaseImageDependencies *[]BaseImageDependency `json:"baseImageDependencies,omitempty"`
- // ContextPath - The URL(absolute or relative) of the source context for the task step.
- ContextPath *string `json:"contextPath,omitempty"`
- // ContextAccessToken - The token (git PAT or SAS token of storage account blob) associated with the context for a step.
- ContextAccessToken *string `json:"contextAccessToken,omitempty"`
- // Type - Possible values include: 'TypeTaskStepProperties', 'TypeDocker', 'TypeFileTask', 'TypeEncodedTask'
- Type TypeBasicTaskStepProperties `json:"type,omitempty"`
-}
-
-func unmarshalBasicTaskStepProperties(body []byte) (BasicTaskStepProperties, error) {
- var m map[string]interface{}
- err := json.Unmarshal(body, &m)
- if err != nil {
- return nil, err
- }
-
- switch m["type"] {
- case string(TypeDocker):
- var dbs DockerBuildStep
- err := json.Unmarshal(body, &dbs)
- return dbs, err
- case string(TypeFileTask):
- var fts FileTaskStep
- err := json.Unmarshal(body, &fts)
- return fts, err
- case string(TypeEncodedTask):
- var ets EncodedTaskStep
- err := json.Unmarshal(body, &ets)
- return ets, err
- default:
- var tsp TaskStepProperties
- err := json.Unmarshal(body, &tsp)
- return tsp, err
- }
-}
-func unmarshalBasicTaskStepPropertiesArray(body []byte) ([]BasicTaskStepProperties, error) {
- var rawMessages []*json.RawMessage
- err := json.Unmarshal(body, &rawMessages)
- if err != nil {
- return nil, err
- }
-
- tspArray := make([]BasicTaskStepProperties, len(rawMessages))
-
- for index, rawMessage := range rawMessages {
- tsp, err := unmarshalBasicTaskStepProperties(*rawMessage)
- if err != nil {
- return nil, err
- }
- tspArray[index] = tsp
- }
- return tspArray, nil
-}
-
-// MarshalJSON is the custom marshaler for TaskStepProperties.
-func (tsp TaskStepProperties) MarshalJSON() ([]byte, error) {
- tsp.Type = TypeTaskStepProperties
- objectMap := make(map[string]interface{})
- if tsp.ContextPath != nil {
- objectMap["contextPath"] = tsp.ContextPath
- }
- if tsp.ContextAccessToken != nil {
- objectMap["contextAccessToken"] = tsp.ContextAccessToken
- }
- if tsp.Type != "" {
- objectMap["type"] = tsp.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildStep is the BasicTaskStepProperties implementation for TaskStepProperties.
-func (tsp TaskStepProperties) AsDockerBuildStep() (*DockerBuildStep, bool) {
- return nil, false
-}
-
-// AsFileTaskStep is the BasicTaskStepProperties implementation for TaskStepProperties.
-func (tsp TaskStepProperties) AsFileTaskStep() (*FileTaskStep, bool) {
- return nil, false
-}
-
-// AsEncodedTaskStep is the BasicTaskStepProperties implementation for TaskStepProperties.
-func (tsp TaskStepProperties) AsEncodedTaskStep() (*EncodedTaskStep, bool) {
- return nil, false
-}
-
-// AsTaskStepProperties is the BasicTaskStepProperties implementation for TaskStepProperties.
-func (tsp TaskStepProperties) AsTaskStepProperties() (*TaskStepProperties, bool) {
- return &tsp, true
-}
-
-// AsBasicTaskStepProperties is the BasicTaskStepProperties implementation for TaskStepProperties.
-func (tsp TaskStepProperties) AsBasicTaskStepProperties() (BasicTaskStepProperties, bool) {
- return &tsp, true
-}
-
-// BasicTaskStepUpdateParameters base properties for updating any task step.
-type BasicTaskStepUpdateParameters interface {
- AsDockerBuildStepUpdateParameters() (*DockerBuildStepUpdateParameters, bool)
- AsFileTaskStepUpdateParameters() (*FileTaskStepUpdateParameters, bool)
- AsEncodedTaskStepUpdateParameters() (*EncodedTaskStepUpdateParameters, bool)
- AsTaskStepUpdateParameters() (*TaskStepUpdateParameters, bool)
-}
-
-// TaskStepUpdateParameters base properties for updating any task step.
-type TaskStepUpdateParameters struct {
- // ContextPath - The URL(absolute or relative) of the source context for the task step.
- ContextPath *string `json:"contextPath,omitempty"`
- // ContextAccessToken - The token (git PAT or SAS token of storage account blob) associated with the context for a step.
- ContextAccessToken *string `json:"contextAccessToken,omitempty"`
- // Type - Possible values include: 'TypeBasicTaskStepUpdateParametersTypeTaskStepUpdateParameters', 'TypeBasicTaskStepUpdateParametersTypeDocker', 'TypeBasicTaskStepUpdateParametersTypeFileTask', 'TypeBasicTaskStepUpdateParametersTypeEncodedTask'
- Type TypeBasicTaskStepUpdateParameters `json:"type,omitempty"`
-}
-
-func unmarshalBasicTaskStepUpdateParameters(body []byte) (BasicTaskStepUpdateParameters, error) {
- var m map[string]interface{}
- err := json.Unmarshal(body, &m)
- if err != nil {
- return nil, err
- }
-
- switch m["type"] {
- case string(TypeBasicTaskStepUpdateParametersTypeDocker):
- var dbsup DockerBuildStepUpdateParameters
- err := json.Unmarshal(body, &dbsup)
- return dbsup, err
- case string(TypeBasicTaskStepUpdateParametersTypeFileTask):
- var ftsup FileTaskStepUpdateParameters
- err := json.Unmarshal(body, &ftsup)
- return ftsup, err
- case string(TypeBasicTaskStepUpdateParametersTypeEncodedTask):
- var etsup EncodedTaskStepUpdateParameters
- err := json.Unmarshal(body, &etsup)
- return etsup, err
- default:
- var tsup TaskStepUpdateParameters
- err := json.Unmarshal(body, &tsup)
- return tsup, err
- }
-}
-func unmarshalBasicTaskStepUpdateParametersArray(body []byte) ([]BasicTaskStepUpdateParameters, error) {
- var rawMessages []*json.RawMessage
- err := json.Unmarshal(body, &rawMessages)
- if err != nil {
- return nil, err
- }
-
- tsupArray := make([]BasicTaskStepUpdateParameters, len(rawMessages))
-
- for index, rawMessage := range rawMessages {
- tsup, err := unmarshalBasicTaskStepUpdateParameters(*rawMessage)
- if err != nil {
- return nil, err
- }
- tsupArray[index] = tsup
- }
- return tsupArray, nil
-}
-
-// MarshalJSON is the custom marshaler for TaskStepUpdateParameters.
-func (tsup TaskStepUpdateParameters) MarshalJSON() ([]byte, error) {
- tsup.Type = TypeBasicTaskStepUpdateParametersTypeTaskStepUpdateParameters
- objectMap := make(map[string]interface{})
- if tsup.ContextPath != nil {
- objectMap["contextPath"] = tsup.ContextPath
- }
- if tsup.ContextAccessToken != nil {
- objectMap["contextAccessToken"] = tsup.ContextAccessToken
- }
- if tsup.Type != "" {
- objectMap["type"] = tsup.Type
- }
- return json.Marshal(objectMap)
-}
-
-// AsDockerBuildStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for TaskStepUpdateParameters.
-func (tsup TaskStepUpdateParameters) AsDockerBuildStepUpdateParameters() (*DockerBuildStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsFileTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for TaskStepUpdateParameters.
-func (tsup TaskStepUpdateParameters) AsFileTaskStepUpdateParameters() (*FileTaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsEncodedTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for TaskStepUpdateParameters.
-func (tsup TaskStepUpdateParameters) AsEncodedTaskStepUpdateParameters() (*EncodedTaskStepUpdateParameters, bool) {
- return nil, false
-}
-
-// AsTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for TaskStepUpdateParameters.
-func (tsup TaskStepUpdateParameters) AsTaskStepUpdateParameters() (*TaskStepUpdateParameters, bool) {
- return &tsup, true
-}
-
-// AsBasicTaskStepUpdateParameters is the BasicTaskStepUpdateParameters implementation for TaskStepUpdateParameters.
-func (tsup TaskStepUpdateParameters) AsBasicTaskStepUpdateParameters() (BasicTaskStepUpdateParameters, bool) {
- return &tsup, true
-}
-
-// TasksUpdateFuture an abstraction for monitoring and retrieving the results of a long-running operation.
-type TasksUpdateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *TasksUpdateFuture) Result(client TasksClient) (t Task, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksUpdateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.TasksUpdateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if t.Response.Response, err = future.GetResult(sender); err == nil && t.Response.Response.StatusCode != http.StatusNoContent {
- t, err = client.UpdateResponder(t.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksUpdateFuture", "Result", t.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// TaskUpdateParameters the parameters for updating a task.
-type TaskUpdateParameters struct {
- // Identity - Identity for the resource.
- Identity *IdentityProperties `json:"identity,omitempty"`
- // TaskPropertiesUpdateParameters - The properties for updating a task.
- *TaskPropertiesUpdateParameters `json:"properties,omitempty"`
- // Tags - The ARM resource tags.
- Tags map[string]*string `json:"tags"`
-}
-
-// MarshalJSON is the custom marshaler for TaskUpdateParameters.
-func (tup TaskUpdateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if tup.Identity != nil {
- objectMap["identity"] = tup.Identity
- }
- if tup.TaskPropertiesUpdateParameters != nil {
- objectMap["properties"] = tup.TaskPropertiesUpdateParameters
- }
- if tup.Tags != nil {
- objectMap["tags"] = tup.Tags
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for TaskUpdateParameters struct.
-func (tup *TaskUpdateParameters) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "identity":
- if v != nil {
- var identity IdentityProperties
- err = json.Unmarshal(*v, &identity)
- if err != nil {
- return err
- }
- tup.Identity = &identity
- }
- case "properties":
- if v != nil {
- var taskPropertiesUpdateParameters TaskPropertiesUpdateParameters
- err = json.Unmarshal(*v, &taskPropertiesUpdateParameters)
- if err != nil {
- return err
- }
- tup.TaskPropertiesUpdateParameters = &taskPropertiesUpdateParameters
- }
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- tup.Tags = tags
- }
- }
- }
-
- return nil
-}
-
-// TimerTrigger the properties of a timer trigger.
-type TimerTrigger struct {
- // Schedule - The CRON expression for the task schedule
- Schedule *string `json:"schedule,omitempty"`
- // Status - The current status of trigger. Possible values include: 'TriggerStatusDisabled', 'TriggerStatusEnabled'
- Status TriggerStatus `json:"status,omitempty"`
- // Name - The name of the trigger.
- Name *string `json:"name,omitempty"`
-}
-
-// TimerTriggerDescriptor ...
-type TimerTriggerDescriptor struct {
- // TimerTriggerName - The timer trigger name that caused the run.
- TimerTriggerName *string `json:"timerTriggerName,omitempty"`
- // ScheduleOccurrence - The occurrence that triggered the run.
- ScheduleOccurrence *string `json:"scheduleOccurrence,omitempty"`
-}
-
-// TimerTriggerUpdateParameters the properties for updating a timer trigger.
-type TimerTriggerUpdateParameters struct {
- // Schedule - The CRON expression for the task schedule
- Schedule *string `json:"schedule,omitempty"`
- // Status - The current status of trigger. Possible values include: 'TriggerStatusDisabled', 'TriggerStatusEnabled'
- Status TriggerStatus `json:"status,omitempty"`
- // Name - The name of the trigger.
- Name *string `json:"name,omitempty"`
-}
-
-// TriggerProperties the properties of a trigger.
-type TriggerProperties struct {
- // TimerTriggers - The collection of timer triggers.
- TimerTriggers *[]TimerTrigger `json:"timerTriggers,omitempty"`
- // SourceTriggers - The collection of triggers based on source code repository.
- SourceTriggers *[]SourceTrigger `json:"sourceTriggers,omitempty"`
- // BaseImageTrigger - The trigger based on base image dependencies.
- BaseImageTrigger *BaseImageTrigger `json:"baseImageTrigger,omitempty"`
-}
-
-// TriggerUpdateParameters the properties for updating triggers.
-type TriggerUpdateParameters struct {
- // TimerTriggers - The collection of timer triggers.
- TimerTriggers *[]TimerTriggerUpdateParameters `json:"timerTriggers,omitempty"`
- // SourceTriggers - The collection of triggers based on source code repository.
- SourceTriggers *[]SourceTriggerUpdateParameters `json:"sourceTriggers,omitempty"`
- // BaseImageTrigger - The trigger based on base image dependencies.
- BaseImageTrigger *BaseImageTriggerUpdateParameters `json:"baseImageTrigger,omitempty"`
-}
-
-// TrustPolicy the content trust policy for a container registry.
-type TrustPolicy struct {
- // Type - The type of trust policy. Possible values include: 'Notary'
- Type TrustPolicyType `json:"type,omitempty"`
- // Status - The value that indicates whether the policy is enabled or not. Possible values include: 'Enabled', 'Disabled'
- Status PolicyStatus `json:"status,omitempty"`
-}
-
-// UserIdentityProperties ...
-type UserIdentityProperties struct {
- // PrincipalID - The principal id of user assigned identity.
- PrincipalID *string `json:"principalId,omitempty"`
- // ClientID - The client id of user assigned identity.
- ClientID *string `json:"clientId,omitempty"`
-}
-
-// VirtualNetworkRule virtual network rule.
-type VirtualNetworkRule struct {
- // Action - The action of virtual network rule. Possible values include: 'Allow'
- Action Action `json:"action,omitempty"`
- // VirtualNetworkResourceID - Resource ID of a subnet, for example: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{vnetName}/subnets/{subnetName}.
- VirtualNetworkResourceID *string `json:"id,omitempty"`
-}
-
-// Webhook an object that represents a webhook for a container registry.
-type Webhook struct {
- autorest.Response `json:"-"`
- // WebhookProperties - The properties of the webhook.
- *WebhookProperties `json:"properties,omitempty"`
- // ID - READ-ONLY; The resource ID.
- ID *string `json:"id,omitempty"`
- // Name - READ-ONLY; The name of the resource.
- Name *string `json:"name,omitempty"`
- // Type - READ-ONLY; The type of the resource.
- Type *string `json:"type,omitempty"`
- // Location - The location of the resource. This cannot be changed after the resource is created.
- Location *string `json:"location,omitempty"`
- // Tags - The tags of the resource.
- Tags map[string]*string `json:"tags"`
-}
-
-// MarshalJSON is the custom marshaler for Webhook.
-func (w Webhook) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if w.WebhookProperties != nil {
- objectMap["properties"] = w.WebhookProperties
- }
- if w.Location != nil {
- objectMap["location"] = w.Location
- }
- if w.Tags != nil {
- objectMap["tags"] = w.Tags
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for Webhook struct.
-func (w *Webhook) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "properties":
- if v != nil {
- var webhookProperties WebhookProperties
- err = json.Unmarshal(*v, &webhookProperties)
- if err != nil {
- return err
- }
- w.WebhookProperties = &webhookProperties
- }
- case "id":
- if v != nil {
- var ID string
- err = json.Unmarshal(*v, &ID)
- if err != nil {
- return err
- }
- w.ID = &ID
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- w.Name = &name
- }
- case "type":
- if v != nil {
- var typeVar string
- err = json.Unmarshal(*v, &typeVar)
- if err != nil {
- return err
- }
- w.Type = &typeVar
- }
- case "location":
- if v != nil {
- var location string
- err = json.Unmarshal(*v, &location)
- if err != nil {
- return err
- }
- w.Location = &location
- }
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- w.Tags = tags
- }
- }
- }
-
- return nil
-}
-
-// WebhookCreateParameters the parameters for creating a webhook.
-type WebhookCreateParameters struct {
- // Tags - The tags for the webhook.
- Tags map[string]*string `json:"tags"`
- // Location - The location of the webhook. This cannot be changed after the resource is created.
- Location *string `json:"location,omitempty"`
- // WebhookPropertiesCreateParameters - The properties that the webhook will be created with.
- *WebhookPropertiesCreateParameters `json:"properties,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for WebhookCreateParameters.
-func (wcp WebhookCreateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if wcp.Tags != nil {
- objectMap["tags"] = wcp.Tags
- }
- if wcp.Location != nil {
- objectMap["location"] = wcp.Location
- }
- if wcp.WebhookPropertiesCreateParameters != nil {
- objectMap["properties"] = wcp.WebhookPropertiesCreateParameters
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for WebhookCreateParameters struct.
-func (wcp *WebhookCreateParameters) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- wcp.Tags = tags
- }
- case "location":
- if v != nil {
- var location string
- err = json.Unmarshal(*v, &location)
- if err != nil {
- return err
- }
- wcp.Location = &location
- }
- case "properties":
- if v != nil {
- var webhookPropertiesCreateParameters WebhookPropertiesCreateParameters
- err = json.Unmarshal(*v, &webhookPropertiesCreateParameters)
- if err != nil {
- return err
- }
- wcp.WebhookPropertiesCreateParameters = &webhookPropertiesCreateParameters
- }
- }
- }
-
- return nil
-}
-
-// WebhookListResult the result of a request to list webhooks for a container registry.
-type WebhookListResult struct {
- autorest.Response `json:"-"`
- // Value - The list of webhooks. Since this list may be incomplete, the nextLink field should be used to request the next list of webhooks.
- Value *[]Webhook `json:"value,omitempty"`
- // NextLink - The URI that can be used to request the next list of webhooks.
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// WebhookListResultIterator provides access to a complete listing of Webhook values.
-type WebhookListResultIterator struct {
- i int
- page WebhookListResultPage
-}
-
-// NextWithContext advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *WebhookListResultIterator) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhookListResultIterator.NextWithContext")
- defer func() {
- sc := -1
- if iter.Response().Response.Response != nil {
- sc = iter.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err = iter.page.NextWithContext(ctx)
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (iter *WebhookListResultIterator) Next() error {
- return iter.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter WebhookListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter WebhookListResultIterator) Response() WebhookListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter WebhookListResultIterator) Value() Webhook {
- if !iter.page.NotDone() {
- return Webhook{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// Creates a new instance of the WebhookListResultIterator type.
-func NewWebhookListResultIterator(page WebhookListResultPage) WebhookListResultIterator {
- return WebhookListResultIterator{page: page}
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (wlr WebhookListResult) IsEmpty() bool {
- return wlr.Value == nil || len(*wlr.Value) == 0
-}
-
-// webhookListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (wlr WebhookListResult) webhookListResultPreparer(ctx context.Context) (*http.Request, error) {
- if wlr.NextLink == nil || len(to.String(wlr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare((&http.Request{}).WithContext(ctx),
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(wlr.NextLink)))
-}
-
-// WebhookListResultPage contains a page of Webhook values.
-type WebhookListResultPage struct {
- fn func(context.Context, WebhookListResult) (WebhookListResult, error)
- wlr WebhookListResult
-}
-
-// NextWithContext advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *WebhookListResultPage) NextWithContext(ctx context.Context) (err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhookListResultPage.NextWithContext")
- defer func() {
- sc := -1
- if page.Response().Response.Response != nil {
- sc = page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- next, err := page.fn(ctx, page.wlr)
- if err != nil {
- return err
- }
- page.wlr = next
- return nil
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-// Deprecated: Use NextWithContext() instead.
-func (page *WebhookListResultPage) Next() error {
- return page.NextWithContext(context.Background())
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page WebhookListResultPage) NotDone() bool {
- return !page.wlr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page WebhookListResultPage) Response() WebhookListResult {
- return page.wlr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page WebhookListResultPage) Values() []Webhook {
- if page.wlr.IsEmpty() {
- return nil
- }
- return *page.wlr.Value
-}
-
-// Creates a new instance of the WebhookListResultPage type.
-func NewWebhookListResultPage(getNextPage func(context.Context, WebhookListResult) (WebhookListResult, error)) WebhookListResultPage {
- return WebhookListResultPage{fn: getNextPage}
-}
-
-// WebhookProperties the properties of a webhook.
-type WebhookProperties struct {
- // Status - The status of the webhook at the time the operation was called. Possible values include: 'WebhookStatusEnabled', 'WebhookStatusDisabled'
- Status WebhookStatus `json:"status,omitempty"`
- // Scope - The scope of repositories where the event can be triggered. For example, 'foo:*' means events for all tags under repository 'foo'. 'foo:bar' means events for 'foo:bar' only. 'foo' is equivalent to 'foo:latest'. Empty means all events.
- Scope *string `json:"scope,omitempty"`
- // Actions - The list of actions that trigger the webhook to post notifications.
- Actions *[]WebhookAction `json:"actions,omitempty"`
- // ProvisioningState - READ-ONLY; The provisioning state of the webhook at the time the operation was called. Possible values include: 'Creating', 'Updating', 'Deleting', 'Succeeded', 'Failed', 'Canceled'
- ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
-}
-
-// WebhookPropertiesCreateParameters the parameters for creating the properties of a webhook.
-type WebhookPropertiesCreateParameters struct {
- // ServiceURI - The service URI for the webhook to post notifications.
- ServiceURI *string `json:"serviceUri,omitempty"`
- // CustomHeaders - Custom headers that will be added to the webhook notifications.
- CustomHeaders map[string]*string `json:"customHeaders"`
- // Status - The status of the webhook at the time the operation was called. Possible values include: 'WebhookStatusEnabled', 'WebhookStatusDisabled'
- Status WebhookStatus `json:"status,omitempty"`
- // Scope - The scope of repositories where the event can be triggered. For example, 'foo:*' means events for all tags under repository 'foo'. 'foo:bar' means events for 'foo:bar' only. 'foo' is equivalent to 'foo:latest'. Empty means all events.
- Scope *string `json:"scope,omitempty"`
- // Actions - The list of actions that trigger the webhook to post notifications.
- Actions *[]WebhookAction `json:"actions,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for WebhookPropertiesCreateParameters.
-func (wpcp WebhookPropertiesCreateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if wpcp.ServiceURI != nil {
- objectMap["serviceUri"] = wpcp.ServiceURI
- }
- if wpcp.CustomHeaders != nil {
- objectMap["customHeaders"] = wpcp.CustomHeaders
- }
- if wpcp.Status != "" {
- objectMap["status"] = wpcp.Status
- }
- if wpcp.Scope != nil {
- objectMap["scope"] = wpcp.Scope
- }
- if wpcp.Actions != nil {
- objectMap["actions"] = wpcp.Actions
- }
- return json.Marshal(objectMap)
-}
-
-// WebhookPropertiesUpdateParameters the parameters for updating the properties of a webhook.
-type WebhookPropertiesUpdateParameters struct {
- // ServiceURI - The service URI for the webhook to post notifications.
- ServiceURI *string `json:"serviceUri,omitempty"`
- // CustomHeaders - Custom headers that will be added to the webhook notifications.
- CustomHeaders map[string]*string `json:"customHeaders"`
- // Status - The status of the webhook at the time the operation was called. Possible values include: 'WebhookStatusEnabled', 'WebhookStatusDisabled'
- Status WebhookStatus `json:"status,omitempty"`
- // Scope - The scope of repositories where the event can be triggered. For example, 'foo:*' means events for all tags under repository 'foo'. 'foo:bar' means events for 'foo:bar' only. 'foo' is equivalent to 'foo:latest'. Empty means all events.
- Scope *string `json:"scope,omitempty"`
- // Actions - The list of actions that trigger the webhook to post notifications.
- Actions *[]WebhookAction `json:"actions,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for WebhookPropertiesUpdateParameters.
-func (wpup WebhookPropertiesUpdateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if wpup.ServiceURI != nil {
- objectMap["serviceUri"] = wpup.ServiceURI
- }
- if wpup.CustomHeaders != nil {
- objectMap["customHeaders"] = wpup.CustomHeaders
- }
- if wpup.Status != "" {
- objectMap["status"] = wpup.Status
- }
- if wpup.Scope != nil {
- objectMap["scope"] = wpup.Scope
- }
- if wpup.Actions != nil {
- objectMap["actions"] = wpup.Actions
- }
- return json.Marshal(objectMap)
-}
-
-// WebhooksCreateFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type WebhooksCreateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *WebhooksCreateFuture) Result(client WebhooksClient) (w Webhook, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksCreateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.WebhooksCreateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if w.Response.Response, err = future.GetResult(sender); err == nil && w.Response.Response.StatusCode != http.StatusNoContent {
- w, err = client.CreateResponder(w.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksCreateFuture", "Result", w.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// WebhooksDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type WebhooksDeleteFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *WebhooksDeleteFuture) Result(client WebhooksClient) (ar autorest.Response, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksDeleteFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.WebhooksDeleteFuture")
- return
- }
- ar.Response = future.Response()
- return
-}
-
-// WebhooksUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
-// operation.
-type WebhooksUpdateFuture struct {
- azure.Future
-}
-
-// Result returns the result of the asynchronous operation.
-// If the operation has not completed it will return an error.
-func (future *WebhooksUpdateFuture) Result(client WebhooksClient) (w Webhook, err error) {
- var done bool
- done, err = future.DoneWithContext(context.Background(), client)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksUpdateFuture", "Result", future.Response(), "Polling failure")
- return
- }
- if !done {
- err = azure.NewAsyncOpIncompleteError("containerregistry.WebhooksUpdateFuture")
- return
- }
- sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- if w.Response.Response, err = future.GetResult(sender); err == nil && w.Response.Response.StatusCode != http.StatusNoContent {
- w, err = client.UpdateResponder(w.Response.Response)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksUpdateFuture", "Result", w.Response.Response, "Failure responding to request")
- }
- }
- return
-}
-
-// WebhookUpdateParameters the parameters for updating a webhook.
-type WebhookUpdateParameters struct {
- // Tags - The tags for the webhook.
- Tags map[string]*string `json:"tags"`
- // WebhookPropertiesUpdateParameters - The properties that the webhook will be updated with.
- *WebhookPropertiesUpdateParameters `json:"properties,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for WebhookUpdateParameters.
-func (wup WebhookUpdateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if wup.Tags != nil {
- objectMap["tags"] = wup.Tags
- }
- if wup.WebhookPropertiesUpdateParameters != nil {
- objectMap["properties"] = wup.WebhookPropertiesUpdateParameters
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for WebhookUpdateParameters struct.
-func (wup *WebhookUpdateParameters) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- wup.Tags = tags
- }
- case "properties":
- if v != nil {
- var webhookPropertiesUpdateParameters WebhookPropertiesUpdateParameters
- err = json.Unmarshal(*v, &webhookPropertiesUpdateParameters)
- if err != nil {
- return err
- }
- wup.WebhookPropertiesUpdateParameters = &webhookPropertiesUpdateParameters
- }
- }
- }
-
- return nil
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/operations.go b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/operations.go
deleted file mode 100644
index 9014900552ea..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/operations.go
+++ /dev/null
@@ -1,147 +0,0 @@
-package containerregistry
-
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is regenerated.
-
-import (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// OperationsClient is the client for the Operations methods of the Containerregistry service.
-type OperationsClient struct {
- BaseClient
-}
-
-// NewOperationsClient creates an instance of the OperationsClient client.
-func NewOperationsClient(subscriptionID string) OperationsClient {
- return NewOperationsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewOperationsClientWithBaseURI creates an instance of the OperationsClient client using a custom endpoint. Use this
-// when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
-func NewOperationsClientWithBaseURI(baseURI string, subscriptionID string) OperationsClient {
- return OperationsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// List lists all of the available Azure Container Registry REST API operations.
-func (client OperationsClient) List(ctx context.Context) (result OperationListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/OperationsClient.List")
- defer func() {
- sc := -1
- if result.olr.Response.Response != nil {
- sc = result.olr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.OperationsClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.olr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.OperationsClient", "List", resp, "Failure sending request")
- return
- }
-
- result.olr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.OperationsClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client OperationsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPath("/providers/Microsoft.ContainerRegistry/operations"),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client OperationsClient) ListSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client OperationsClient) ListResponder(resp *http.Response) (result OperationListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client OperationsClient) listNextResults(ctx context.Context, lastResults OperationListResult) (result OperationListResult, err error) {
- req, err := lastResults.operationListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "containerregistry.OperationsClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "containerregistry.OperationsClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.OperationsClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client OperationsClient) ListComplete(ctx context.Context) (result OperationListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/OperationsClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx)
- return
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/registries.go b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/registries.go
deleted file mode 100644
index 4ba0f940ead4..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/registries.go
+++ /dev/null
@@ -1,1243 +0,0 @@
-package containerregistry
-
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is regenerated.
-
-import (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// RegistriesClient is the client for the Registries methods of the Containerregistry service.
-type RegistriesClient struct {
- BaseClient
-}
-
-// NewRegistriesClient creates an instance of the RegistriesClient client.
-func NewRegistriesClient(subscriptionID string) RegistriesClient {
- return NewRegistriesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewRegistriesClientWithBaseURI creates an instance of the RegistriesClient client using a custom endpoint. Use this
-// when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
-func NewRegistriesClientWithBaseURI(baseURI string, subscriptionID string) RegistriesClient {
- return RegistriesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CheckNameAvailability checks whether the container registry name is available for use. The name must contain only
-// alphanumeric characters, be globally unique, and between 5 and 50 characters in length.
-// Parameters:
-// registryNameCheckRequest - the object containing information for the availability request.
-func (client RegistriesClient) CheckNameAvailability(ctx context.Context, registryNameCheckRequest RegistryNameCheckRequest) (result RegistryNameStatus, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.CheckNameAvailability")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: registryNameCheckRequest,
- Constraints: []validation.Constraint{{Target: "registryNameCheckRequest.Name", Name: validation.Null, Rule: true,
- Chain: []validation.Constraint{{Target: "registryNameCheckRequest.Name", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryNameCheckRequest.Name", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryNameCheckRequest.Name", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil},
- }},
- {Target: "registryNameCheckRequest.Type", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "CheckNameAvailability", err.Error())
- }
-
- req, err := client.CheckNameAvailabilityPreparer(ctx, registryNameCheckRequest)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "CheckNameAvailability", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CheckNameAvailabilitySender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "CheckNameAvailability", resp, "Failure sending request")
- return
- }
-
- result, err = client.CheckNameAvailabilityResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "CheckNameAvailability", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CheckNameAvailabilityPreparer prepares the CheckNameAvailability request.
-func (client RegistriesClient) CheckNameAvailabilityPreparer(ctx context.Context, registryNameCheckRequest RegistryNameCheckRequest) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.ContainerRegistry/checkNameAvailability", pathParameters),
- autorest.WithJSON(registryNameCheckRequest),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CheckNameAvailabilitySender sends the CheckNameAvailability request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) CheckNameAvailabilitySender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// CheckNameAvailabilityResponder handles the response to the CheckNameAvailability request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) CheckNameAvailabilityResponder(resp *http.Response) (result RegistryNameStatus, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Create creates a container registry with the specified parameters.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// registry - the parameters for creating a container registry.
-func (client RegistriesClient) Create(ctx context.Context, resourceGroupName string, registryName string, registry Registry) (result RegistriesCreateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.Create")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: registry,
- Constraints: []validation.Constraint{{Target: "registry.Sku", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "registry.RegistryProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "registry.RegistryProperties.StorageAccount", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "registry.RegistryProperties.StorageAccount.ID", Name: validation.Null, Rule: true, Chain: nil}}},
- }}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "Create", err.Error())
- }
-
- req, err := client.CreatePreparer(ctx, resourceGroupName, registryName, registry)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Create", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Create", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreatePreparer prepares the Create request.
-func (client RegistriesClient) CreatePreparer(ctx context.Context, resourceGroupName string, registryName string, registry Registry) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}", pathParameters),
- autorest.WithJSON(registry),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateSender sends the Create request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) CreateSender(req *http.Request) (future RegistriesCreateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateResponder handles the response to the Create request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) CreateResponder(resp *http.Response) (result Registry, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-func (client RegistriesClient) Delete(ctx context.Context, resourceGroupName string, registryName string) (result RegistriesDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "Delete", err.Error())
- }
-
- req, err := client.DeletePreparer(ctx, resourceGroupName, registryName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client RegistriesClient) DeletePreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) DeleteSender(req *http.Request) (future RegistriesDeleteFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets the properties of the specified container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-func (client RegistriesClient) Get(ctx context.Context, resourceGroupName string, registryName string) (result Registry, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "Get", err.Error())
- }
-
- req, err := client.GetPreparer(ctx, resourceGroupName, registryName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client RegistriesClient) GetPreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) GetSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) GetResponder(resp *http.Response) (result Registry, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// GetBuildSourceUploadURL get the upload location for the user to be able to upload the source.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-func (client RegistriesClient) GetBuildSourceUploadURL(ctx context.Context, resourceGroupName string, registryName string) (result SourceUploadDefinition, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.GetBuildSourceUploadURL")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "GetBuildSourceUploadURL", err.Error())
- }
-
- req, err := client.GetBuildSourceUploadURLPreparer(ctx, resourceGroupName, registryName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "GetBuildSourceUploadURL", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetBuildSourceUploadURLSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "GetBuildSourceUploadURL", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetBuildSourceUploadURLResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "GetBuildSourceUploadURL", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetBuildSourceUploadURLPreparer prepares the GetBuildSourceUploadURL request.
-func (client RegistriesClient) GetBuildSourceUploadURLPreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/listBuildSourceUploadUrl", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetBuildSourceUploadURLSender sends the GetBuildSourceUploadURL request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) GetBuildSourceUploadURLSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetBuildSourceUploadURLResponder handles the response to the GetBuildSourceUploadURL request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) GetBuildSourceUploadURLResponder(resp *http.Response) (result SourceUploadDefinition, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ImportImage copies an image to this container registry from the specified container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// parameters - the parameters specifying the image to copy and the source container registry.
-func (client RegistriesClient) ImportImage(ctx context.Context, resourceGroupName string, registryName string, parameters ImportImageParameters) (result RegistriesImportImageFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.ImportImage")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.Source", Name: validation.Null, Rule: true,
- Chain: []validation.Constraint{{Target: "parameters.Source.Credentials", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.Source.Credentials.Password", Name: validation.Null, Rule: true, Chain: nil}}},
- {Target: "parameters.Source.SourceImage", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "ImportImage", err.Error())
- }
-
- req, err := client.ImportImagePreparer(ctx, resourceGroupName, registryName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ImportImage", nil, "Failure preparing request")
- return
- }
-
- result, err = client.ImportImageSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ImportImage", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// ImportImagePreparer prepares the ImportImage request.
-func (client RegistriesClient) ImportImagePreparer(ctx context.Context, resourceGroupName string, registryName string, parameters ImportImageParameters) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/importImage", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ImportImageSender sends the ImportImage request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) ImportImageSender(req *http.Request) (future RegistriesImportImageFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// ImportImageResponder handles the response to the ImportImage request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) ImportImageResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// List lists all the container registries under the specified subscription.
-func (client RegistriesClient) List(ctx context.Context) (result RegistryListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.List")
- defer func() {
- sc := -1
- if result.rlr.Response.Response != nil {
- sc = result.rlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.rlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "List", resp, "Failure sending request")
- return
- }
-
- result.rlr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client RegistriesClient) ListPreparer(ctx context.Context) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.ContainerRegistry/registries", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) ListSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) ListResponder(resp *http.Response) (result RegistryListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client RegistriesClient) listNextResults(ctx context.Context, lastResults RegistryListResult) (result RegistryListResult, err error) {
- req, err := lastResults.registryListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client RegistriesClient) ListComplete(ctx context.Context) (result RegistryListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx)
- return
-}
-
-// ListByResourceGroup lists all the container registries under the specified resource group.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-func (client RegistriesClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result RegistryListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.ListByResourceGroup")
- defer func() {
- sc := -1
- if result.rlr.Response.Response != nil {
- sc = result.rlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "ListByResourceGroup", err.Error())
- }
-
- result.fn = client.listByResourceGroupNextResults
- req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListByResourceGroup", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByResourceGroupSender(req)
- if err != nil {
- result.rlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListByResourceGroup", resp, "Failure sending request")
- return
- }
-
- result.rlr, err = client.ListByResourceGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListByResourceGroup", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
-func (client RegistriesClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) ListByResourceGroupResponder(resp *http.Response) (result RegistryListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByResourceGroupNextResults retrieves the next set of results, if any.
-func (client RegistriesClient) listByResourceGroupNextResults(ctx context.Context, lastResults RegistryListResult) (result RegistryListResult, err error) {
- req, err := lastResults.registryListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByResourceGroupSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByResourceGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
-func (client RegistriesClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result RegistryListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.ListByResourceGroup")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
- return
-}
-
-// ListCredentials lists the login credentials for the specified container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-func (client RegistriesClient) ListCredentials(ctx context.Context, resourceGroupName string, registryName string) (result RegistryListCredentialsResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.ListCredentials")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "ListCredentials", err.Error())
- }
-
- req, err := client.ListCredentialsPreparer(ctx, resourceGroupName, registryName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListCredentials", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListCredentialsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListCredentials", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListCredentialsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListCredentials", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListCredentialsPreparer prepares the ListCredentials request.
-func (client RegistriesClient) ListCredentialsPreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/listCredentials", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListCredentialsSender sends the ListCredentials request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) ListCredentialsSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListCredentialsResponder handles the response to the ListCredentials request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) ListCredentialsResponder(resp *http.Response) (result RegistryListCredentialsResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListUsages gets the quota usages for the specified container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-func (client RegistriesClient) ListUsages(ctx context.Context, resourceGroupName string, registryName string) (result RegistryUsageListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.ListUsages")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "ListUsages", err.Error())
- }
-
- req, err := client.ListUsagesPreparer(ctx, resourceGroupName, registryName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListUsages", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListUsagesSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListUsages", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListUsagesResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ListUsages", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListUsagesPreparer prepares the ListUsages request.
-func (client RegistriesClient) ListUsagesPreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/listUsages", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListUsagesSender sends the ListUsages request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) ListUsagesSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListUsagesResponder handles the response to the ListUsages request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) ListUsagesResponder(resp *http.Response) (result RegistryUsageListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// RegenerateCredential regenerates one of the login credentials for the specified container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// regenerateCredentialParameters - specifies name of the password which should be regenerated -- password or
-// password2.
-func (client RegistriesClient) RegenerateCredential(ctx context.Context, resourceGroupName string, registryName string, regenerateCredentialParameters RegenerateCredentialParameters) (result RegistryListCredentialsResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.RegenerateCredential")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "RegenerateCredential", err.Error())
- }
-
- req, err := client.RegenerateCredentialPreparer(ctx, resourceGroupName, registryName, regenerateCredentialParameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "RegenerateCredential", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.RegenerateCredentialSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "RegenerateCredential", resp, "Failure sending request")
- return
- }
-
- result, err = client.RegenerateCredentialResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "RegenerateCredential", resp, "Failure responding to request")
- }
-
- return
-}
-
-// RegenerateCredentialPreparer prepares the RegenerateCredential request.
-func (client RegistriesClient) RegenerateCredentialPreparer(ctx context.Context, resourceGroupName string, registryName string, regenerateCredentialParameters RegenerateCredentialParameters) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/regenerateCredential", pathParameters),
- autorest.WithJSON(regenerateCredentialParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// RegenerateCredentialSender sends the RegenerateCredential request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) RegenerateCredentialSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// RegenerateCredentialResponder handles the response to the RegenerateCredential request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) RegenerateCredentialResponder(resp *http.Response) (result RegistryListCredentialsResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ScheduleRun schedules a new run based on the request parameters and add it to the run queue.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// runRequest - the parameters of a run that needs to scheduled.
-func (client RegistriesClient) ScheduleRun(ctx context.Context, resourceGroupName string, registryName string, runRequest BasicRunRequest) (result RegistriesScheduleRunFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.ScheduleRun")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "ScheduleRun", err.Error())
- }
-
- req, err := client.ScheduleRunPreparer(ctx, resourceGroupName, registryName, runRequest)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ScheduleRun", nil, "Failure preparing request")
- return
- }
-
- result, err = client.ScheduleRunSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "ScheduleRun", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// ScheduleRunPreparer prepares the ScheduleRun request.
-func (client RegistriesClient) ScheduleRunPreparer(ctx context.Context, resourceGroupName string, registryName string, runRequest BasicRunRequest) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/scheduleRun", pathParameters),
- autorest.WithJSON(runRequest),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ScheduleRunSender sends the ScheduleRun request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) ScheduleRunSender(req *http.Request) (future RegistriesScheduleRunFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// ScheduleRunResponder handles the response to the ScheduleRun request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) ScheduleRunResponder(resp *http.Response) (result Run, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Update updates a container registry with the specified parameters.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// registryUpdateParameters - the parameters for updating a container registry.
-func (client RegistriesClient) Update(ctx context.Context, resourceGroupName string, registryName string, registryUpdateParameters RegistryUpdateParameters) (result RegistriesUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RegistriesClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RegistriesClient", "Update", err.Error())
- }
-
- req, err := client.UpdatePreparer(ctx, resourceGroupName, registryName, registryUpdateParameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RegistriesClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client RegistriesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, registryName string, registryUpdateParameters RegistryUpdateParameters) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}", pathParameters),
- autorest.WithJSON(registryUpdateParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client RegistriesClient) UpdateSender(req *http.Request) (future RegistriesUpdateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client RegistriesClient) UpdateResponder(resp *http.Response) (result Registry, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/replications.go b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/replications.go
deleted file mode 100644
index 045c66b790f1..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/replications.go
+++ /dev/null
@@ -1,540 +0,0 @@
-package containerregistry
-
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is regenerated.
-
-import (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ReplicationsClient is the client for the Replications methods of the Containerregistry service.
-type ReplicationsClient struct {
- BaseClient
-}
-
-// NewReplicationsClient creates an instance of the ReplicationsClient client.
-func NewReplicationsClient(subscriptionID string) ReplicationsClient {
- return NewReplicationsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewReplicationsClientWithBaseURI creates an instance of the ReplicationsClient client using a custom endpoint. Use
-// this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
-func NewReplicationsClientWithBaseURI(baseURI string, subscriptionID string) ReplicationsClient {
- return ReplicationsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Create creates a replication for a container registry with the specified parameters.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// replicationName - the name of the replication.
-// replication - the parameters for creating a replication.
-func (client ReplicationsClient) Create(ctx context.Context, resourceGroupName string, registryName string, replicationName string, replication Replication) (result ReplicationsCreateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationsClient.Create")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: replicationName,
- Constraints: []validation.Constraint{{Target: "replicationName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "replicationName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "replicationName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.ReplicationsClient", "Create", err.Error())
- }
-
- req, err := client.CreatePreparer(ctx, resourceGroupName, registryName, replicationName, replication)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Create", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Create", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreatePreparer prepares the Create request.
-func (client ReplicationsClient) CreatePreparer(ctx context.Context, resourceGroupName string, registryName string, replicationName string, replication Replication) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "replicationName": autorest.Encode("path", replicationName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/replications/{replicationName}", pathParameters),
- autorest.WithJSON(replication),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateSender sends the Create request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationsClient) CreateSender(req *http.Request) (future ReplicationsCreateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateResponder handles the response to the Create request. The method always
-// closes the http.Response Body.
-func (client ReplicationsClient) CreateResponder(resp *http.Response) (result Replication, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a replication from a container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// replicationName - the name of the replication.
-func (client ReplicationsClient) Delete(ctx context.Context, resourceGroupName string, registryName string, replicationName string) (result ReplicationsDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationsClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: replicationName,
- Constraints: []validation.Constraint{{Target: "replicationName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "replicationName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "replicationName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.ReplicationsClient", "Delete", err.Error())
- }
-
- req, err := client.DeletePreparer(ctx, resourceGroupName, registryName, replicationName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ReplicationsClient) DeletePreparer(ctx context.Context, resourceGroupName string, registryName string, replicationName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "replicationName": autorest.Encode("path", replicationName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/replications/{replicationName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationsClient) DeleteSender(req *http.Request) (future ReplicationsDeleteFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ReplicationsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets the properties of the specified replication.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// replicationName - the name of the replication.
-func (client ReplicationsClient) Get(ctx context.Context, resourceGroupName string, registryName string, replicationName string) (result Replication, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: replicationName,
- Constraints: []validation.Constraint{{Target: "replicationName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "replicationName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "replicationName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.ReplicationsClient", "Get", err.Error())
- }
-
- req, err := client.GetPreparer(ctx, resourceGroupName, registryName, replicationName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ReplicationsClient) GetPreparer(ctx context.Context, resourceGroupName string, registryName string, replicationName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "replicationName": autorest.Encode("path", replicationName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/replications/{replicationName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationsClient) GetSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ReplicationsClient) GetResponder(resp *http.Response) (result Replication, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// List lists all the replications for the specified container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-func (client ReplicationsClient) List(ctx context.Context, resourceGroupName string, registryName string) (result ReplicationListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationsClient.List")
- defer func() {
- sc := -1
- if result.rlr.Response.Response != nil {
- sc = result.rlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.ReplicationsClient", "List", err.Error())
- }
-
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx, resourceGroupName, registryName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.rlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "List", resp, "Failure sending request")
- return
- }
-
- result.rlr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client ReplicationsClient) ListPreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/replications", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationsClient) ListSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client ReplicationsClient) ListResponder(resp *http.Response) (result ReplicationListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client ReplicationsClient) listNextResults(ctx context.Context, lastResults ReplicationListResult) (result ReplicationListResult, err error) {
- req, err := lastResults.replicationListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ReplicationsClient) ListComplete(ctx context.Context, resourceGroupName string, registryName string) (result ReplicationListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationsClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx, resourceGroupName, registryName)
- return
-}
-
-// Update updates a replication for a container registry with the specified parameters.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// replicationName - the name of the replication.
-// replicationUpdateParameters - the parameters for updating a replication.
-func (client ReplicationsClient) Update(ctx context.Context, resourceGroupName string, registryName string, replicationName string, replicationUpdateParameters ReplicationUpdateParameters) (result ReplicationsUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationsClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: replicationName,
- Constraints: []validation.Constraint{{Target: "replicationName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "replicationName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "replicationName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.ReplicationsClient", "Update", err.Error())
- }
-
- req, err := client.UpdatePreparer(ctx, resourceGroupName, registryName, replicationName, replicationUpdateParameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.ReplicationsClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client ReplicationsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, registryName string, replicationName string, replicationUpdateParameters ReplicationUpdateParameters) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "replicationName": autorest.Encode("path", replicationName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/replications/{replicationName}", pathParameters),
- autorest.WithJSON(replicationUpdateParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationsClient) UpdateSender(req *http.Request) (future ReplicationsUpdateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client ReplicationsClient) UpdateResponder(resp *http.Response) (result Replication, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/runs.go b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/runs.go
deleted file mode 100644
index 91c393f0c713..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/runs.go
+++ /dev/null
@@ -1,530 +0,0 @@
-package containerregistry
-
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is regenerated.
-
-import (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// RunsClient is the client for the Runs methods of the Containerregistry service.
-type RunsClient struct {
- BaseClient
-}
-
-// NewRunsClient creates an instance of the RunsClient client.
-func NewRunsClient(subscriptionID string) RunsClient {
- return NewRunsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewRunsClientWithBaseURI creates an instance of the RunsClient client using a custom endpoint. Use this when
-// interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
-func NewRunsClientWithBaseURI(baseURI string, subscriptionID string) RunsClient {
- return RunsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Cancel cancel an existing run.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// runID - the run ID.
-func (client RunsClient) Cancel(ctx context.Context, resourceGroupName string, registryName string, runID string) (result RunsCancelFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RunsClient.Cancel")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RunsClient", "Cancel", err.Error())
- }
-
- req, err := client.CancelPreparer(ctx, resourceGroupName, registryName, runID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "Cancel", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CancelSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "Cancel", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CancelPreparer prepares the Cancel request.
-func (client RunsClient) CancelPreparer(ctx context.Context, resourceGroupName string, registryName string, runID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "runId": autorest.Encode("path", runID),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/runs/{runId}/cancel", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CancelSender sends the Cancel request. The method will close the
-// http.Response Body if it receives an error.
-func (client RunsClient) CancelSender(req *http.Request) (future RunsCancelFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CancelResponder handles the response to the Cancel request. The method always
-// closes the http.Response Body.
-func (client RunsClient) CancelResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets the detailed information for a given run.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// runID - the run ID.
-func (client RunsClient) Get(ctx context.Context, resourceGroupName string, registryName string, runID string) (result Run, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RunsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RunsClient", "Get", err.Error())
- }
-
- req, err := client.GetPreparer(ctx, resourceGroupName, registryName, runID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client RunsClient) GetPreparer(ctx context.Context, resourceGroupName string, registryName string, runID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "runId": autorest.Encode("path", runID),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/runs/{runId}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client RunsClient) GetSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client RunsClient) GetResponder(resp *http.Response) (result Run, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// GetLogSasURL gets a link to download the run logs.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// runID - the run ID.
-func (client RunsClient) GetLogSasURL(ctx context.Context, resourceGroupName string, registryName string, runID string) (result RunGetLogResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RunsClient.GetLogSasURL")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RunsClient", "GetLogSasURL", err.Error())
- }
-
- req, err := client.GetLogSasURLPreparer(ctx, resourceGroupName, registryName, runID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "GetLogSasURL", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetLogSasURLSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "GetLogSasURL", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetLogSasURLResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "GetLogSasURL", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetLogSasURLPreparer prepares the GetLogSasURL request.
-func (client RunsClient) GetLogSasURLPreparer(ctx context.Context, resourceGroupName string, registryName string, runID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "runId": autorest.Encode("path", runID),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/runs/{runId}/listLogSasUrl", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetLogSasURLSender sends the GetLogSasURL request. The method will close the
-// http.Response Body if it receives an error.
-func (client RunsClient) GetLogSasURLSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetLogSasURLResponder handles the response to the GetLogSasURL request. The method always
-// closes the http.Response Body.
-func (client RunsClient) GetLogSasURLResponder(resp *http.Response) (result RunGetLogResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// List gets all the runs for a registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// filter - the runs filter to apply on the operation. Arithmetic operators are not supported. The allowed
-// string function is 'contains'. All logical operators except 'Not', 'Has', 'All' are allowed.
-// top - $top is supported for get list of runs, which limits the maximum number of runs to return.
-func (client RunsClient) List(ctx context.Context, resourceGroupName string, registryName string, filter string, top *int32) (result RunListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RunsClient.List")
- defer func() {
- sc := -1
- if result.rlr.Response.Response != nil {
- sc = result.rlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RunsClient", "List", err.Error())
- }
-
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx, resourceGroupName, registryName, filter, top)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.rlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "List", resp, "Failure sending request")
- return
- }
-
- result.rlr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client RunsClient) ListPreparer(ctx context.Context, resourceGroupName string, registryName string, filter string, top *int32) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if len(filter) > 0 {
- queryParameters["$filter"] = autorest.Encode("query", filter)
- }
- if top != nil {
- queryParameters["$top"] = autorest.Encode("query", *top)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/runs", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client RunsClient) ListSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client RunsClient) ListResponder(resp *http.Response) (result RunListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client RunsClient) listNextResults(ctx context.Context, lastResults RunListResult) (result RunListResult, err error) {
- req, err := lastResults.runListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "containerregistry.RunsClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "containerregistry.RunsClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client RunsClient) ListComplete(ctx context.Context, resourceGroupName string, registryName string, filter string, top *int32) (result RunListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RunsClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx, resourceGroupName, registryName, filter, top)
- return
-}
-
-// Update patch the run properties.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// runID - the run ID.
-// runUpdateParameters - the run update properties.
-func (client RunsClient) Update(ctx context.Context, resourceGroupName string, registryName string, runID string, runUpdateParameters RunUpdateParameters) (result RunsUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RunsClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.RunsClient", "Update", err.Error())
- }
-
- req, err := client.UpdatePreparer(ctx, resourceGroupName, registryName, runID, runUpdateParameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.RunsClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client RunsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, registryName string, runID string, runUpdateParameters RunUpdateParameters) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "runId": autorest.Encode("path", runID),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/runs/{runId}", pathParameters),
- autorest.WithJSON(runUpdateParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client RunsClient) UpdateSender(req *http.Request) (future RunsUpdateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client RunsClient) UpdateResponder(resp *http.Response) (result Run, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/tasks.go b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/tasks.go
deleted file mode 100644
index fc11eb857ed0..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/tasks.go
+++ /dev/null
@@ -1,645 +0,0 @@
-package containerregistry
-
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is regenerated.
-
-import (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// TasksClient is the client for the Tasks methods of the Containerregistry service.
-type TasksClient struct {
- BaseClient
-}
-
-// NewTasksClient creates an instance of the TasksClient client.
-func NewTasksClient(subscriptionID string) TasksClient {
- return NewTasksClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewTasksClientWithBaseURI creates an instance of the TasksClient client using a custom endpoint. Use this when
-// interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
-func NewTasksClientWithBaseURI(baseURI string, subscriptionID string) TasksClient {
- return TasksClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Create creates a task for a container registry with the specified parameters.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// taskName - the name of the container registry task.
-// taskCreateParameters - the parameters for creating a task.
-func (client TasksClient) Create(ctx context.Context, resourceGroupName string, registryName string, taskName string, taskCreateParameters Task) (result TasksCreateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TasksClient.Create")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: taskName,
- Constraints: []validation.Constraint{{Target: "taskName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "taskName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "taskName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9-_]*$`, Chain: nil}}},
- {TargetValue: taskCreateParameters,
- Constraints: []validation.Constraint{{Target: "taskCreateParameters.TaskProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "taskCreateParameters.TaskProperties.Platform", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "taskCreateParameters.TaskProperties.Timeout", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "taskCreateParameters.TaskProperties.Timeout", Name: validation.InclusiveMaximum, Rule: int64(28800), Chain: nil},
- {Target: "taskCreateParameters.TaskProperties.Timeout", Name: validation.InclusiveMinimum, Rule: int64(300), Chain: nil},
- }},
- {Target: "taskCreateParameters.TaskProperties.Step", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "taskCreateParameters.TaskProperties.Trigger", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "taskCreateParameters.TaskProperties.Trigger.BaseImageTrigger", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "taskCreateParameters.TaskProperties.Trigger.BaseImageTrigger.Name", Name: validation.Null, Rule: true, Chain: nil}}},
- }},
- }}}}}); err != nil {
- return result, validation.NewError("containerregistry.TasksClient", "Create", err.Error())
- }
-
- req, err := client.CreatePreparer(ctx, resourceGroupName, registryName, taskName, taskCreateParameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Create", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Create", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreatePreparer prepares the Create request.
-func (client TasksClient) CreatePreparer(ctx context.Context, resourceGroupName string, registryName string, taskName string, taskCreateParameters Task) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "taskName": autorest.Encode("path", taskName),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/tasks/{taskName}", pathParameters),
- autorest.WithJSON(taskCreateParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateSender sends the Create request. The method will close the
-// http.Response Body if it receives an error.
-func (client TasksClient) CreateSender(req *http.Request) (future TasksCreateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateResponder handles the response to the Create request. The method always
-// closes the http.Response Body.
-func (client TasksClient) CreateResponder(resp *http.Response) (result Task, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a specified task.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// taskName - the name of the container registry task.
-func (client TasksClient) Delete(ctx context.Context, resourceGroupName string, registryName string, taskName string) (result TasksDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TasksClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: taskName,
- Constraints: []validation.Constraint{{Target: "taskName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "taskName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "taskName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9-_]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.TasksClient", "Delete", err.Error())
- }
-
- req, err := client.DeletePreparer(ctx, resourceGroupName, registryName, taskName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client TasksClient) DeletePreparer(ctx context.Context, resourceGroupName string, registryName string, taskName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "taskName": autorest.Encode("path", taskName),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/tasks/{taskName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client TasksClient) DeleteSender(req *http.Request) (future TasksDeleteFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client TasksClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get get the properties of a specified task.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// taskName - the name of the container registry task.
-func (client TasksClient) Get(ctx context.Context, resourceGroupName string, registryName string, taskName string) (result Task, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TasksClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: taskName,
- Constraints: []validation.Constraint{{Target: "taskName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "taskName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "taskName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9-_]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.TasksClient", "Get", err.Error())
- }
-
- req, err := client.GetPreparer(ctx, resourceGroupName, registryName, taskName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client TasksClient) GetPreparer(ctx context.Context, resourceGroupName string, registryName string, taskName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "taskName": autorest.Encode("path", taskName),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/tasks/{taskName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client TasksClient) GetSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client TasksClient) GetResponder(resp *http.Response) (result Task, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// GetDetails returns a task with extended information that includes all secrets.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// taskName - the name of the container registry task.
-func (client TasksClient) GetDetails(ctx context.Context, resourceGroupName string, registryName string, taskName string) (result Task, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TasksClient.GetDetails")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: taskName,
- Constraints: []validation.Constraint{{Target: "taskName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "taskName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "taskName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9-_]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.TasksClient", "GetDetails", err.Error())
- }
-
- req, err := client.GetDetailsPreparer(ctx, resourceGroupName, registryName, taskName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "GetDetails", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetDetailsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "GetDetails", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetDetailsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "GetDetails", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetDetailsPreparer prepares the GetDetails request.
-func (client TasksClient) GetDetailsPreparer(ctx context.Context, resourceGroupName string, registryName string, taskName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "taskName": autorest.Encode("path", taskName),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/tasks/{taskName}/listDetails", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetDetailsSender sends the GetDetails request. The method will close the
-// http.Response Body if it receives an error.
-func (client TasksClient) GetDetailsSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetDetailsResponder handles the response to the GetDetails request. The method always
-// closes the http.Response Body.
-func (client TasksClient) GetDetailsResponder(resp *http.Response) (result Task, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// List lists all the tasks for a specified container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-func (client TasksClient) List(ctx context.Context, resourceGroupName string, registryName string) (result TaskListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TasksClient.List")
- defer func() {
- sc := -1
- if result.tlr.Response.Response != nil {
- sc = result.tlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.TasksClient", "List", err.Error())
- }
-
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx, resourceGroupName, registryName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.tlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "List", resp, "Failure sending request")
- return
- }
-
- result.tlr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client TasksClient) ListPreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/tasks", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client TasksClient) ListSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client TasksClient) ListResponder(resp *http.Response) (result TaskListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client TasksClient) listNextResults(ctx context.Context, lastResults TaskListResult) (result TaskListResult, err error) {
- req, err := lastResults.taskListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "containerregistry.TasksClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "containerregistry.TasksClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client TasksClient) ListComplete(ctx context.Context, resourceGroupName string, registryName string) (result TaskListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TasksClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx, resourceGroupName, registryName)
- return
-}
-
-// Update updates a task with the specified parameters.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// taskName - the name of the container registry task.
-// taskUpdateParameters - the parameters for updating a task.
-func (client TasksClient) Update(ctx context.Context, resourceGroupName string, registryName string, taskName string, taskUpdateParameters TaskUpdateParameters) (result TasksUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TasksClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: taskName,
- Constraints: []validation.Constraint{{Target: "taskName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "taskName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "taskName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9-_]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.TasksClient", "Update", err.Error())
- }
-
- req, err := client.UpdatePreparer(ctx, resourceGroupName, registryName, taskName, taskUpdateParameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.TasksClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client TasksClient) UpdatePreparer(ctx context.Context, resourceGroupName string, registryName string, taskName string, taskUpdateParameters TaskUpdateParameters) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "taskName": autorest.Encode("path", taskName),
- }
-
- const APIVersion = "2019-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/tasks/{taskName}", pathParameters),
- autorest.WithJSON(taskUpdateParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client TasksClient) UpdateSender(req *http.Request) (future TasksUpdateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client TasksClient) UpdateResponder(resp *http.Response) (result Task, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/webhooks.go b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/webhooks.go
deleted file mode 100644
index 7de5c13ec5fb..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/webhooks.go
+++ /dev/null
@@ -1,860 +0,0 @@
-package containerregistry
-
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is regenerated.
-
-import (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// WebhooksClient is the client for the Webhooks methods of the Containerregistry service.
-type WebhooksClient struct {
- BaseClient
-}
-
-// NewWebhooksClient creates an instance of the WebhooksClient client.
-func NewWebhooksClient(subscriptionID string) WebhooksClient {
- return NewWebhooksClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewWebhooksClientWithBaseURI creates an instance of the WebhooksClient client using a custom endpoint. Use this
-// when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
-func NewWebhooksClientWithBaseURI(baseURI string, subscriptionID string) WebhooksClient {
- return WebhooksClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Create creates a webhook for a container registry with the specified parameters.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// webhookName - the name of the webhook.
-// webhookCreateParameters - the parameters for creating a webhook.
-func (client WebhooksClient) Create(ctx context.Context, resourceGroupName string, registryName string, webhookName string, webhookCreateParameters WebhookCreateParameters) (result WebhooksCreateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.Create")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: webhookName,
- Constraints: []validation.Constraint{{Target: "webhookName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "webhookName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "webhookName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: webhookCreateParameters,
- Constraints: []validation.Constraint{{Target: "webhookCreateParameters.Location", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "webhookCreateParameters.WebhookPropertiesCreateParameters", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "webhookCreateParameters.WebhookPropertiesCreateParameters.ServiceURI", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "webhookCreateParameters.WebhookPropertiesCreateParameters.Actions", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("containerregistry.WebhooksClient", "Create", err.Error())
- }
-
- req, err := client.CreatePreparer(ctx, resourceGroupName, registryName, webhookName, webhookCreateParameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Create", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Create", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreatePreparer prepares the Create request.
-func (client WebhooksClient) CreatePreparer(ctx context.Context, resourceGroupName string, registryName string, webhookName string, webhookCreateParameters WebhookCreateParameters) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webhookName": autorest.Encode("path", webhookName),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/webhooks/{webhookName}", pathParameters),
- autorest.WithJSON(webhookCreateParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateSender sends the Create request. The method will close the
-// http.Response Body if it receives an error.
-func (client WebhooksClient) CreateSender(req *http.Request) (future WebhooksCreateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateResponder handles the response to the Create request. The method always
-// closes the http.Response Body.
-func (client WebhooksClient) CreateResponder(resp *http.Response) (result Webhook, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a webhook from a container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// webhookName - the name of the webhook.
-func (client WebhooksClient) Delete(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (result WebhooksDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: webhookName,
- Constraints: []validation.Constraint{{Target: "webhookName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "webhookName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "webhookName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.WebhooksClient", "Delete", err.Error())
- }
-
- req, err := client.DeletePreparer(ctx, resourceGroupName, registryName, webhookName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client WebhooksClient) DeletePreparer(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webhookName": autorest.Encode("path", webhookName),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/webhooks/{webhookName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client WebhooksClient) DeleteSender(req *http.Request) (future WebhooksDeleteFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client WebhooksClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets the properties of the specified webhook.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// webhookName - the name of the webhook.
-func (client WebhooksClient) Get(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (result Webhook, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: webhookName,
- Constraints: []validation.Constraint{{Target: "webhookName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "webhookName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "webhookName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.WebhooksClient", "Get", err.Error())
- }
-
- req, err := client.GetPreparer(ctx, resourceGroupName, registryName, webhookName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client WebhooksClient) GetPreparer(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webhookName": autorest.Encode("path", webhookName),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/webhooks/{webhookName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client WebhooksClient) GetSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client WebhooksClient) GetResponder(resp *http.Response) (result Webhook, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// GetCallbackConfig gets the configuration of service URI and custom headers for the webhook.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// webhookName - the name of the webhook.
-func (client WebhooksClient) GetCallbackConfig(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (result CallbackConfig, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.GetCallbackConfig")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: webhookName,
- Constraints: []validation.Constraint{{Target: "webhookName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "webhookName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "webhookName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.WebhooksClient", "GetCallbackConfig", err.Error())
- }
-
- req, err := client.GetCallbackConfigPreparer(ctx, resourceGroupName, registryName, webhookName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "GetCallbackConfig", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetCallbackConfigSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "GetCallbackConfig", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetCallbackConfigResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "GetCallbackConfig", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetCallbackConfigPreparer prepares the GetCallbackConfig request.
-func (client WebhooksClient) GetCallbackConfigPreparer(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webhookName": autorest.Encode("path", webhookName),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/webhooks/{webhookName}/getCallbackConfig", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetCallbackConfigSender sends the GetCallbackConfig request. The method will close the
-// http.Response Body if it receives an error.
-func (client WebhooksClient) GetCallbackConfigSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// GetCallbackConfigResponder handles the response to the GetCallbackConfig request. The method always
-// closes the http.Response Body.
-func (client WebhooksClient) GetCallbackConfigResponder(resp *http.Response) (result CallbackConfig, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// List lists all the webhooks for the specified container registry.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-func (client WebhooksClient) List(ctx context.Context, resourceGroupName string, registryName string) (result WebhookListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.List")
- defer func() {
- sc := -1
- if result.wlr.Response.Response != nil {
- sc = result.wlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.WebhooksClient", "List", err.Error())
- }
-
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx, resourceGroupName, registryName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.wlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "List", resp, "Failure sending request")
- return
- }
-
- result.wlr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client WebhooksClient) ListPreparer(ctx context.Context, resourceGroupName string, registryName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/webhooks", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client WebhooksClient) ListSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client WebhooksClient) ListResponder(resp *http.Response) (result WebhookListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client WebhooksClient) listNextResults(ctx context.Context, lastResults WebhookListResult) (result WebhookListResult, err error) {
- req, err := lastResults.webhookListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client WebhooksClient) ListComplete(ctx context.Context, resourceGroupName string, registryName string) (result WebhookListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx, resourceGroupName, registryName)
- return
-}
-
-// ListEvents lists recent events for the specified webhook.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// webhookName - the name of the webhook.
-func (client WebhooksClient) ListEvents(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (result EventListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.ListEvents")
- defer func() {
- sc := -1
- if result.elr.Response.Response != nil {
- sc = result.elr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: webhookName,
- Constraints: []validation.Constraint{{Target: "webhookName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "webhookName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "webhookName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.WebhooksClient", "ListEvents", err.Error())
- }
-
- result.fn = client.listEventsNextResults
- req, err := client.ListEventsPreparer(ctx, resourceGroupName, registryName, webhookName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "ListEvents", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListEventsSender(req)
- if err != nil {
- result.elr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "ListEvents", resp, "Failure sending request")
- return
- }
-
- result.elr, err = client.ListEventsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "ListEvents", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListEventsPreparer prepares the ListEvents request.
-func (client WebhooksClient) ListEventsPreparer(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webhookName": autorest.Encode("path", webhookName),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/webhooks/{webhookName}/listEvents", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListEventsSender sends the ListEvents request. The method will close the
-// http.Response Body if it receives an error.
-func (client WebhooksClient) ListEventsSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// ListEventsResponder handles the response to the ListEvents request. The method always
-// closes the http.Response Body.
-func (client WebhooksClient) ListEventsResponder(resp *http.Response) (result EventListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listEventsNextResults retrieves the next set of results, if any.
-func (client WebhooksClient) listEventsNextResults(ctx context.Context, lastResults EventListResult) (result EventListResult, err error) {
- req, err := lastResults.eventListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "listEventsNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListEventsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "listEventsNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListEventsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "listEventsNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListEventsComplete enumerates all values, automatically crossing page boundaries as required.
-func (client WebhooksClient) ListEventsComplete(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (result EventListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.ListEvents")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListEvents(ctx, resourceGroupName, registryName, webhookName)
- return
-}
-
-// Ping triggers a ping event to be sent to the webhook.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// webhookName - the name of the webhook.
-func (client WebhooksClient) Ping(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (result EventInfo, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.Ping")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: webhookName,
- Constraints: []validation.Constraint{{Target: "webhookName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "webhookName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "webhookName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.WebhooksClient", "Ping", err.Error())
- }
-
- req, err := client.PingPreparer(ctx, resourceGroupName, registryName, webhookName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Ping", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.PingSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Ping", resp, "Failure sending request")
- return
- }
-
- result, err = client.PingResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Ping", resp, "Failure responding to request")
- }
-
- return
-}
-
-// PingPreparer prepares the Ping request.
-func (client WebhooksClient) PingPreparer(ctx context.Context, resourceGroupName string, registryName string, webhookName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webhookName": autorest.Encode("path", webhookName),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/webhooks/{webhookName}/ping", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// PingSender sends the Ping request. The method will close the
-// http.Response Body if it receives an error.
-func (client WebhooksClient) PingSender(req *http.Request) (*http.Response, error) {
- return client.Send(req, azure.DoRetryWithRegistration(client.Client))
-}
-
-// PingResponder handles the response to the Ping request. The method always
-// closes the http.Response Body.
-func (client WebhooksClient) PingResponder(resp *http.Response) (result EventInfo, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Update updates a webhook with the specified parameters.
-// Parameters:
-// resourceGroupName - the name of the resource group to which the container registry belongs.
-// registryName - the name of the container registry.
-// webhookName - the name of the webhook.
-// webhookUpdateParameters - the parameters for updating a webhook.
-func (client WebhooksClient) Update(ctx context.Context, resourceGroupName string, registryName string, webhookName string, webhookUpdateParameters WebhookUpdateParameters) (result WebhooksUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/WebhooksClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}}},
- {TargetValue: registryName,
- Constraints: []validation.Constraint{{Target: "registryName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "registryName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "registryName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}},
- {TargetValue: webhookName,
- Constraints: []validation.Constraint{{Target: "webhookName", Name: validation.MaxLength, Rule: 50, Chain: nil},
- {Target: "webhookName", Name: validation.MinLength, Rule: 5, Chain: nil},
- {Target: "webhookName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9]*$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("containerregistry.WebhooksClient", "Update", err.Error())
- }
-
- req, err := client.UpdatePreparer(ctx, resourceGroupName, registryName, webhookName, webhookUpdateParameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "containerregistry.WebhooksClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client WebhooksClient) UpdatePreparer(ctx context.Context, resourceGroupName string, registryName string, webhookName string, webhookUpdateParameters WebhookUpdateParameters) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "registryName": autorest.Encode("path", registryName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webhookName": autorest.Encode("path", webhookName),
- }
-
- const APIVersion = "2019-05-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerRegistry/registries/{registryName}/webhooks/{webhookName}", pathParameters),
- autorest.WithJSON(webhookUpdateParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client WebhooksClient) UpdateSender(req *http.Request) (future WebhooksUpdateFuture, err error) {
- var resp *http.Response
- resp, err = client.Send(req, azure.DoRetryWithRegistration(client.Client))
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client WebhooksClient) UpdateResponder(resp *http.Response) (result Webhook, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/accesstokens.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/accesstokens.go
new file mode 100644
index 000000000000..833d2c503485
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/accesstokens.go
@@ -0,0 +1,187 @@
+package containerregistry
+
+// Copyright (c) Microsoft and contributors. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+import (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// AccessTokensClient is the metadata API definition for the Azure Container Registry runtime
+type AccessTokensClient struct {
+ BaseClient
+}
+
+// NewAccessTokensClient creates an instance of the AccessTokensClient client.
+func NewAccessTokensClient(loginURI string) AccessTokensClient {
+ return AccessTokensClient{New(loginURI)}
+}
+
+// Get exchange ACR Refresh token for an ACR Access Token
+// Parameters:
+// service - indicates the name of your Azure container registry.
+// scope - which is expected to be a valid scope, and can be specified more than once for multiple scope
+// requests. You obtained this from the Www-Authenticate response header from the challenge.
+// refreshToken - must be a valid ACR refresh token
+func (client AccessTokensClient) Get(ctx context.Context, service string, scope string, refreshToken string) (result AccessToken, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AccessTokensClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, service, scope, refreshToken)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.AccessTokensClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.AccessTokensClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.AccessTokensClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client AccessTokensClient) GetPreparer(ctx context.Context, service string, scope string, refreshToken string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ formDataParameters := map[string]interface{}{
+ "grant_type": "refresh_token",
+ "refresh_token": refreshToken,
+ "scope": scope,
+ "service": service,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPath("/oauth2/token"),
+ autorest.WithFormData(autorest.MapToValues(formDataParameters)))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client AccessTokensClient) GetSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client AccessTokensClient) GetResponder(resp *http.Response) (result AccessToken, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetFromLogin exchange Username, Password and Scope an ACR Access Token
+// Parameters:
+// service - indicates the name of your Azure container registry.
+// scope - expected to be a valid scope, and can be specified more than once for multiple scope requests. You
+// can obtain this from the Www-Authenticate response header from the challenge.
+func (client AccessTokensClient) GetFromLogin(ctx context.Context, service string, scope string) (result AccessToken, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AccessTokensClient.GetFromLogin")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetFromLoginPreparer(ctx, service, scope)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.AccessTokensClient", "GetFromLogin", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetFromLoginSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.AccessTokensClient", "GetFromLogin", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetFromLoginResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.AccessTokensClient", "GetFromLogin", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetFromLoginPreparer prepares the GetFromLogin request.
+func (client AccessTokensClient) GetFromLoginPreparer(ctx context.Context, service string, scope string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ queryParameters := map[string]interface{}{
+ "scope": autorest.Encode("query", scope),
+ "service": autorest.Encode("query", service),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPath("/oauth2/token"),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetFromLoginSender sends the GetFromLogin request. The method will close the
+// http.Response Body if it receives an error.
+func (client AccessTokensClient) GetFromLoginSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetFromLoginResponder handles the response to the GetFromLogin request. The method always
+// closes the http.Response Body.
+func (client AccessTokensClient) GetFromLoginResponder(resp *http.Response) (result AccessToken, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/blob.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/blob.go
new file mode 100644
index 000000000000..2905576c69dd
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/blob.go
@@ -0,0 +1,842 @@
+package containerregistry
+
+// Copyright (c) Microsoft and contributors. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+import (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "io"
+ "net/http"
+)
+
+// BlobClient is the metadata API definition for the Azure Container Registry runtime
+type BlobClient struct {
+ BaseClient
+}
+
+// NewBlobClient creates an instance of the BlobClient client.
+func NewBlobClient(loginURI string) BlobClient {
+ return BlobClient{New(loginURI)}
+}
+
+// CancelUpload cancel outstanding upload processes, releasing associated resources. If this is not called, the
+// unfinished uploads will eventually timeout.
+// Parameters:
+// location - link acquired from upload start or previous chunk. Note, do not include initial / (must do
+// substring(1) )
+func (client BlobClient) CancelUpload(ctx context.Context, location string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.CancelUpload")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CancelUploadPreparer(ctx, location)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "CancelUpload", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CancelUploadSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "CancelUpload", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CancelUploadResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "CancelUpload", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CancelUploadPreparer prepares the CancelUpload request.
+func (client BlobClient) CancelUploadPreparer(ctx context.Context, location string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "nextBlobUuidLink": location,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/{nextBlobUuidLink}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CancelUploadSender sends the CancelUpload request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) CancelUploadSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// CancelUploadResponder handles the response to the CancelUpload request. The method always
+// closes the http.Response Body.
+func (client BlobClient) CancelUploadResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Check same as GET, except only the headers are returned.
+// Parameters:
+// name - name of the image (including the namespace)
+// digest - digest of a BLOB
+func (client BlobClient) Check(ctx context.Context, name string, digest string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.Check")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CheckPreparer(ctx, name, digest)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Check", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CheckSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Check", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CheckResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Check", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CheckPreparer prepares the Check request.
+func (client BlobClient) CheckPreparer(ctx context.Context, name string, digest string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "digest": autorest.Encode("path", digest),
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsHead(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/blobs/{digest}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CheckSender sends the Check request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) CheckSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// CheckResponder handles the response to the Check request. The method always
+// closes the http.Response Body.
+func (client BlobClient) CheckResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusTemporaryRedirect),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// CheckChunk same as GET, except only the headers are returned.
+// Parameters:
+// name - name of the image (including the namespace)
+// digest - digest of a BLOB
+// rangeParameter - format : bytes=-, HTTP Range header specifying blob chunk.
+func (client BlobClient) CheckChunk(ctx context.Context, name string, digest string, rangeParameter string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.CheckChunk")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CheckChunkPreparer(ctx, name, digest, rangeParameter)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "CheckChunk", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CheckChunkSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "CheckChunk", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CheckChunkResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "CheckChunk", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CheckChunkPreparer prepares the CheckChunk request.
+func (client BlobClient) CheckChunkPreparer(ctx context.Context, name string, digest string, rangeParameter string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "digest": autorest.Encode("path", digest),
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsHead(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/blobs/{digest}", pathParameters),
+ autorest.WithHeader("Range", autorest.String(rangeParameter)))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CheckChunkSender sends the CheckChunk request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) CheckChunkSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// CheckChunkResponder handles the response to the CheckChunk request. The method always
+// closes the http.Response Body.
+func (client BlobClient) CheckChunkResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Delete removes an already uploaded blob.
+// Parameters:
+// name - name of the image (including the namespace)
+// digest - digest of a BLOB
+func (client BlobClient) Delete(ctx context.Context, name string, digest string) (result ReadCloser, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, name, digest)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client BlobClient) DeletePreparer(ctx context.Context, name string, digest string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "digest": autorest.Encode("path", digest),
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/blobs/{digest}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client BlobClient) DeleteResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted))
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// EndUpload complete the upload, providing all the data in the body, if necessary. A request without a body will just
+// complete the upload with previously uploaded content.
+// Parameters:
+// digest - digest of a BLOB
+// location - link acquired from upload start or previous chunk. Note, do not include initial / (must do
+// substring(1) )
+// value - optional raw data of blob
+func (client BlobClient) EndUpload(ctx context.Context, digest string, location string, value io.ReadCloser) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.EndUpload")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.EndUploadPreparer(ctx, digest, location, value)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "EndUpload", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.EndUploadSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "EndUpload", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.EndUploadResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "EndUpload", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// EndUploadPreparer prepares the EndUpload request.
+func (client BlobClient) EndUploadPreparer(ctx context.Context, digest string, location string, value io.ReadCloser) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "nextBlobUuidLink": location,
+ }
+
+ queryParameters := map[string]interface{}{
+ "digest": autorest.Encode("query", digest),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/octet-stream"),
+ autorest.AsPut(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/{nextBlobUuidLink}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ if value != nil {
+ preparer = autorest.DecoratePreparer(preparer,
+ autorest.WithFile(value))
+ }
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// EndUploadSender sends the EndUpload request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) EndUploadSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// EndUploadResponder handles the response to the EndUpload request. The method always
+// closes the http.Response Body.
+func (client BlobClient) EndUploadResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get retrieve the blob from the registry identified by digest.
+// Parameters:
+// name - name of the image (including the namespace)
+// digest - digest of a BLOB
+func (client BlobClient) Get(ctx context.Context, name string, digest string) (result ReadCloser, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, name, digest)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client BlobClient) GetPreparer(ctx context.Context, name string, digest string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "digest": autorest.Encode("path", digest),
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/blobs/{digest}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) GetSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client BlobClient) GetResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusTemporaryRedirect))
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetChunk retrieve the blob from the registry identified by `digest`. This endpoint may also support RFC7233
+// compliant range requests. Support can be detected by issuing a HEAD request. If the header `Accept-Range: bytes` is
+// returned, range requests can be used to fetch partial content.
+// Parameters:
+// name - name of the image (including the namespace)
+// digest - digest of a BLOB
+// rangeParameter - format : bytes=-, HTTP Range header specifying blob chunk.
+func (client BlobClient) GetChunk(ctx context.Context, name string, digest string, rangeParameter string) (result ReadCloser, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.GetChunk")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetChunkPreparer(ctx, name, digest, rangeParameter)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "GetChunk", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetChunkSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "GetChunk", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetChunkResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "GetChunk", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetChunkPreparer prepares the GetChunk request.
+func (client BlobClient) GetChunkPreparer(ctx context.Context, name string, digest string, rangeParameter string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "digest": autorest.Encode("path", digest),
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/blobs/{digest}", pathParameters),
+ autorest.WithHeader("Range", autorest.String(rangeParameter)))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetChunkSender sends the GetChunk request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) GetChunkSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetChunkResponder handles the response to the GetChunk request. The method always
+// closes the http.Response Body.
+func (client BlobClient) GetChunkResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusPartialContent))
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetStatus retrieve status of upload identified by uuid. The primary purpose of this endpoint is to resolve the
+// current status of a resumable upload.
+// Parameters:
+// location - link acquired from upload start or previous chunk. Note, do not include initial / (must do
+// substring(1) )
+func (client BlobClient) GetStatus(ctx context.Context, location string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.GetStatus")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetStatusPreparer(ctx, location)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "GetStatus", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetStatusSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "GetStatus", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetStatusResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "GetStatus", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetStatusPreparer prepares the GetStatus request.
+func (client BlobClient) GetStatusPreparer(ctx context.Context, location string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "nextBlobUuidLink": location,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/{nextBlobUuidLink}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetStatusSender sends the GetStatus request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) GetStatusSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetStatusResponder handles the response to the GetStatus request. The method always
+// closes the http.Response Body.
+func (client BlobClient) GetStatusResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Mount mount a blob identified by the `mount` parameter from another repository.
+// Parameters:
+// name - name of the image (including the namespace)
+// from - name of the source repository.
+// mount - digest of blob to mount from the source repository.
+func (client BlobClient) Mount(ctx context.Context, name string, from string, mount string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.Mount")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.MountPreparer(ctx, name, from, mount)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Mount", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.MountSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Mount", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.MountResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Mount", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// MountPreparer prepares the Mount request.
+func (client BlobClient) MountPreparer(ctx context.Context, name string, from string, mount string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ }
+
+ queryParameters := map[string]interface{}{
+ "from": autorest.Encode("query", from),
+ "mount": autorest.Encode("query", mount),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/blobs/uploads/", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// MountSender sends the Mount request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) MountSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// MountResponder handles the response to the Mount request. The method always
+// closes the http.Response Body.
+func (client BlobClient) MountResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// StartUpload initiate a resumable blob upload with an empty request body.
+// Parameters:
+// name - name of the image (including the namespace)
+func (client BlobClient) StartUpload(ctx context.Context, name string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.StartUpload")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.StartUploadPreparer(ctx, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "StartUpload", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.StartUploadSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "StartUpload", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.StartUploadResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "StartUpload", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// StartUploadPreparer prepares the StartUpload request.
+func (client BlobClient) StartUploadPreparer(ctx context.Context, name string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/blobs/uploads/", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// StartUploadSender sends the StartUpload request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) StartUploadSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// StartUploadResponder handles the response to the StartUpload request. The method always
+// closes the http.Response Body.
+func (client BlobClient) StartUploadResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Upload upload a stream of data without completing the upload.
+// Parameters:
+// value - raw data of blob
+// location - link acquired from upload start or previous chunk. Note, do not include initial / (must do
+// substring(1) )
+func (client BlobClient) Upload(ctx context.Context, value io.ReadCloser, location string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BlobClient.Upload")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UploadPreparer(ctx, value, location)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Upload", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.UploadSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Upload", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.UploadResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Upload", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// UploadPreparer prepares the Upload request.
+func (client BlobClient) UploadPreparer(ctx context.Context, value io.ReadCloser, location string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "nextBlobUuidLink": location,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/octet-stream"),
+ autorest.AsPatch(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/{nextBlobUuidLink}", pathParameters),
+ autorest.WithFile(value))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UploadSender sends the Upload request. The method will close the
+// http.Response Body if it receives an error.
+func (client BlobClient) UploadSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// UploadResponder handles the response to the Upload request. The method always
+// closes the http.Response Body.
+func (client BlobClient) UploadResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/client.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/client.go
similarity index 60%
rename from vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/client.go
rename to vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/client.go
index 578a43823145..bbf3fb2c3693 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/client.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/client.go
@@ -1,6 +1,6 @@
-// Package containerregistry implements the Azure ARM Containerregistry service API version .
-//
+// Package containerregistry implements the Azure ARM Containerregistry service API version 2019-08-15-preview.
//
+// Metadata API definition for the Azure Container Registry runtime
package containerregistry
// Copyright (c) Microsoft and contributors. All rights reserved.
@@ -24,29 +24,21 @@ import (
"github.com/Azure/go-autorest/autorest"
)
-const (
- // DefaultBaseURI is the default URI used for the service Containerregistry
- DefaultBaseURI = "https://management.azure.com"
-)
-
// BaseClient is the base client for Containerregistry.
type BaseClient struct {
autorest.Client
- BaseURI string
- SubscriptionID string
+ LoginURI string
}
// New creates an instance of the BaseClient client.
-func New(subscriptionID string) BaseClient {
- return NewWithBaseURI(DefaultBaseURI, subscriptionID)
+func New(loginURI string) BaseClient {
+ return NewWithoutDefaults(loginURI)
}
-// NewWithBaseURI creates an instance of the BaseClient client using a custom endpoint. Use this when interacting with
-// an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
-func NewWithBaseURI(baseURI string, subscriptionID string) BaseClient {
+// NewWithoutDefaults creates an instance of the BaseClient client.
+func NewWithoutDefaults(loginURI string) BaseClient {
return BaseClient{
- Client: autorest.NewClientWithUserAgent(UserAgent()),
- BaseURI: baseURI,
- SubscriptionID: subscriptionID,
+ Client: autorest.NewClientWithUserAgent(UserAgent()),
+ LoginURI: loginURI,
}
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/manifests.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/manifests.go
new file mode 100644
index 000000000000..e6c023fa78cb
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/manifests.go
@@ -0,0 +1,496 @@
+package containerregistry
+
+// Copyright (c) Microsoft and contributors. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+import (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ManifestsClient is the metadata API definition for the Azure Container Registry runtime
+type ManifestsClient struct {
+ BaseClient
+}
+
+// NewManifestsClient creates an instance of the ManifestsClient client.
+func NewManifestsClient(loginURI string) ManifestsClient {
+ return ManifestsClient{New(loginURI)}
+}
+
+// Create put the manifest identified by `name` and `reference` where `reference` can be a tag or digest.
+// Parameters:
+// name - name of the image (including the namespace)
+// reference - a tag or a digest, pointing to a specific image
+// payload - manifest body, can take v1 or v2 values depending on accept header
+func (client ManifestsClient) Create(ctx context.Context, name string, reference string, payload Manifest) (result SetObject, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManifestsClient.Create")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreatePreparer(ctx, name, reference, payload)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Create", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Create", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Create", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreatePreparer prepares the Create request.
+func (client ManifestsClient) CreatePreparer(ctx context.Context, name string, reference string, payload Manifest) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "reference": autorest.Encode("path", reference),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/vnd.docker.distribution.manifest.v2+json"),
+ autorest.AsPut(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/manifests/{reference}", pathParameters),
+ autorest.WithJSON(payload))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateSender sends the Create request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManifestsClient) CreateSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// CreateResponder handles the response to the Create request. The method always
+// closes the http.Response Body.
+func (client ManifestsClient) CreateResponder(resp *http.Response) (result SetObject, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result.Value),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete delete the manifest identified by `name` and `reference`. Note that a manifest can _only_ be deleted by
+// `digest`.
+// Parameters:
+// name - name of the image (including the namespace)
+// reference - a tag or a digest, pointing to a specific image
+func (client ManifestsClient) Delete(ctx context.Context, name string, reference string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManifestsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, name, reference)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ManifestsClient) DeletePreparer(ctx context.Context, name string, reference string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "reference": autorest.Encode("path", reference),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/manifests/{reference}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManifestsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ManifestsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get get the manifest identified by `name` and `reference` where `reference` can be a tag or digest.
+// Parameters:
+// name - name of the image (including the namespace)
+// reference - a tag or a digest, pointing to a specific image
+// accept - accept header string delimited by comma. For example,
+// application/vnd.docker.distribution.manifest.v2+json
+func (client ManifestsClient) Get(ctx context.Context, name string, reference string, accept string) (result ManifestWrapper, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManifestsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, name, reference, accept)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ManifestsClient) GetPreparer(ctx context.Context, name string, reference string, accept string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "reference": autorest.Encode("path", reference),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/v2/{name}/manifests/{reference}", pathParameters))
+ if len(accept) > 0 {
+ preparer = autorest.DecoratePreparer(preparer,
+ autorest.WithHeader("accept", autorest.String(accept)))
+ }
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManifestsClient) GetSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ManifestsClient) GetResponder(resp *http.Response) (result ManifestWrapper, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetAttributes get manifest attributes
+// Parameters:
+// name - name of the image (including the namespace)
+// reference - a tag or a digest, pointing to a specific image
+func (client ManifestsClient) GetAttributes(ctx context.Context, name string, reference string) (result ManifestAttributes, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManifestsClient.GetAttributes")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetAttributesPreparer(ctx, name, reference)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "GetAttributes", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetAttributesSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "GetAttributes", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetAttributesResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "GetAttributes", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetAttributesPreparer prepares the GetAttributes request.
+func (client ManifestsClient) GetAttributesPreparer(ctx context.Context, name string, reference string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "reference": autorest.Encode("path", reference),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}/_manifests/{reference}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetAttributesSender sends the GetAttributes request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManifestsClient) GetAttributesSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetAttributesResponder handles the response to the GetAttributes request. The method always
+// closes the http.Response Body.
+func (client ManifestsClient) GetAttributesResponder(resp *http.Response) (result ManifestAttributes, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetList list manifests of a repository
+// Parameters:
+// name - name of the image (including the namespace)
+// last - query parameter for the last item in previous query. Result set will include values lexically after
+// last.
+// n - query parameter for max number of items
+// orderby - orderby query parameter
+func (client ManifestsClient) GetList(ctx context.Context, name string, last string, n *int32, orderby string) (result AcrManifests, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManifestsClient.GetList")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetListPreparer(ctx, name, last, n, orderby)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "GetList", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "GetList", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "GetList", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetListPreparer prepares the GetList request.
+func (client ManifestsClient) GetListPreparer(ctx context.Context, name string, last string, n *int32, orderby string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ }
+
+ queryParameters := map[string]interface{}{}
+ if len(last) > 0 {
+ queryParameters["last"] = autorest.Encode("query", last)
+ }
+ if n != nil {
+ queryParameters["n"] = autorest.Encode("query", *n)
+ }
+ if len(orderby) > 0 {
+ queryParameters["orderby"] = autorest.Encode("query", orderby)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}/_manifests", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetListSender sends the GetList request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManifestsClient) GetListSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetListResponder handles the response to the GetList request. The method always
+// closes the http.Response Body.
+func (client ManifestsClient) GetListResponder(resp *http.Response) (result AcrManifests, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// UpdateAttributes update attributes of a manifest
+// Parameters:
+// name - name of the image (including the namespace)
+// reference - a tag or a digest, pointing to a specific image
+// value - repository attribute value
+func (client ManifestsClient) UpdateAttributes(ctx context.Context, name string, reference string, value *ChangeableAttributes) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManifestsClient.UpdateAttributes")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdateAttributesPreparer(ctx, name, reference, value)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "UpdateAttributes", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.UpdateAttributesSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "UpdateAttributes", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.UpdateAttributesResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "UpdateAttributes", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// UpdateAttributesPreparer prepares the UpdateAttributes request.
+func (client ManifestsClient) UpdateAttributesPreparer(ctx context.Context, name string, reference string, value *ChangeableAttributes) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "reference": autorest.Encode("path", reference),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}/_manifests/{reference}", pathParameters))
+ if value != nil {
+ preparer = autorest.DecoratePreparer(preparer,
+ autorest.WithJSON(value))
+ }
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateAttributesSender sends the UpdateAttributes request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManifestsClient) UpdateAttributesSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// UpdateAttributesResponder handles the response to the UpdateAttributes request. The method always
+// closes the http.Response Body.
+func (client ManifestsClient) UpdateAttributesResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/models.go
new file mode 100644
index 000000000000..5c4ae1bc4584
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/models.go
@@ -0,0 +1,639 @@
+package containerregistry
+
+// Copyright (c) Microsoft and contributors. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+import (
+ "encoding/json"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/date"
+ "io"
+)
+
+// The package's fully qualified name.
+const fqdn = "github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry"
+
+// AccessToken ...
+type AccessToken struct {
+ autorest.Response `json:"-"`
+ // AccessToken - The access token for performing authenticated requests
+ AccessToken *string `json:"access_token,omitempty"`
+}
+
+// AcrErrorInfo error information
+type AcrErrorInfo struct {
+ // Code - Error code
+ Code *string `json:"code,omitempty"`
+ // Message - Error message
+ Message *string `json:"message,omitempty"`
+ // Detail - Error details
+ Detail interface{} `json:"detail,omitempty"`
+}
+
+// AcrErrors acr error response describing why the operation failed
+type AcrErrors struct {
+ // Errors - Array of detailed error
+ Errors *[]AcrErrorInfo `json:"errors,omitempty"`
+}
+
+// AcrManifests manifest attributes
+type AcrManifests struct {
+ autorest.Response `json:"-"`
+ // Registry - Registry name
+ Registry *string `json:"registry,omitempty"`
+ // ImageName - Image name
+ ImageName *string `json:"imageName,omitempty"`
+ // ManifestsAttributes - List of manifests
+ ManifestsAttributes *[]ManifestAttributesBase `json:"manifests,omitempty"`
+}
+
+// Annotations additional information provided through arbitrary metadata.
+type Annotations struct {
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // Created - Date and time on which the image was built (string, date-time as defined by https://tools.ietf.org/html/rfc3339#section-5.6)
+ Created *date.Time `json:"org.opencontainers.image.created,omitempty"`
+ // Authors - Contact details of the people or organization responsible for the image.
+ Authors *string `json:"org.opencontainers.image.authors,omitempty"`
+ // URL - URL to find more information on the image.
+ URL *string `json:"org.opencontainers.image.url,omitempty"`
+ // Documentation - URL to get documentation on the image.
+ Documentation *string `json:"org.opencontainers.image.documentation,omitempty"`
+ // Source - URL to get source code for building the image.
+ Source *string `json:"org.opencontainers.image.source,omitempty"`
+ // Version - Version of the packaged software. The version MAY match a label or tag in the source code repository, may also be Semantic versioning-compatible
+ Version *string `json:"org.opencontainers.image.version,omitempty"`
+ // Revision - Source control revision identifier for the packaged software.
+ Revision *string `json:"org.opencontainers.image.revision,omitempty"`
+ // Vendor - Name of the distributing entity, organization or individual.
+ Vendor *string `json:"org.opencontainers.image.vendor,omitempty"`
+ // Licenses - License(s) under which contained software is distributed as an SPDX License Expression.
+ Licenses *string `json:"org.opencontainers.image.licenses,omitempty"`
+ // Name - Name of the reference for a target.
+ Name *string `json:"org.opencontainers.image.ref.name,omitempty"`
+ // Title - Human-readable title of the image
+ Title *string `json:"org.opencontainers.image.title,omitempty"`
+ // Description - Human-readable description of the software packaged in the image
+ Description *string `json:"org.opencontainers.image.description,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for Annotations.
+func (a Annotations) MarshalJSON() ([]byte, error) {
+ objectMap := make(map[string]interface{})
+ if a.Created != nil {
+ objectMap["org.opencontainers.image.created"] = a.Created
+ }
+ if a.Authors != nil {
+ objectMap["org.opencontainers.image.authors"] = a.Authors
+ }
+ if a.URL != nil {
+ objectMap["org.opencontainers.image.url"] = a.URL
+ }
+ if a.Documentation != nil {
+ objectMap["org.opencontainers.image.documentation"] = a.Documentation
+ }
+ if a.Source != nil {
+ objectMap["org.opencontainers.image.source"] = a.Source
+ }
+ if a.Version != nil {
+ objectMap["org.opencontainers.image.version"] = a.Version
+ }
+ if a.Revision != nil {
+ objectMap["org.opencontainers.image.revision"] = a.Revision
+ }
+ if a.Vendor != nil {
+ objectMap["org.opencontainers.image.vendor"] = a.Vendor
+ }
+ if a.Licenses != nil {
+ objectMap["org.opencontainers.image.licenses"] = a.Licenses
+ }
+ if a.Name != nil {
+ objectMap["org.opencontainers.image.ref.name"] = a.Name
+ }
+ if a.Title != nil {
+ objectMap["org.opencontainers.image.title"] = a.Title
+ }
+ if a.Description != nil {
+ objectMap["org.opencontainers.image.description"] = a.Description
+ }
+ for k, v := range a.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// UnmarshalJSON is the custom unmarshaler for Annotations struct.
+func (a *Annotations) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if a.AdditionalProperties == nil {
+ a.AdditionalProperties = make(map[string]interface{})
+ }
+ a.AdditionalProperties[k] = additionalProperties
+ }
+ case "org.opencontainers.image.created":
+ if v != nil {
+ var created date.Time
+ err = json.Unmarshal(*v, &created)
+ if err != nil {
+ return err
+ }
+ a.Created = &created
+ }
+ case "org.opencontainers.image.authors":
+ if v != nil {
+ var authors string
+ err = json.Unmarshal(*v, &authors)
+ if err != nil {
+ return err
+ }
+ a.Authors = &authors
+ }
+ case "org.opencontainers.image.url":
+ if v != nil {
+ var URL string
+ err = json.Unmarshal(*v, &URL)
+ if err != nil {
+ return err
+ }
+ a.URL = &URL
+ }
+ case "org.opencontainers.image.documentation":
+ if v != nil {
+ var documentation string
+ err = json.Unmarshal(*v, &documentation)
+ if err != nil {
+ return err
+ }
+ a.Documentation = &documentation
+ }
+ case "org.opencontainers.image.source":
+ if v != nil {
+ var source string
+ err = json.Unmarshal(*v, &source)
+ if err != nil {
+ return err
+ }
+ a.Source = &source
+ }
+ case "org.opencontainers.image.version":
+ if v != nil {
+ var version string
+ err = json.Unmarshal(*v, &version)
+ if err != nil {
+ return err
+ }
+ a.Version = &version
+ }
+ case "org.opencontainers.image.revision":
+ if v != nil {
+ var revision string
+ err = json.Unmarshal(*v, &revision)
+ if err != nil {
+ return err
+ }
+ a.Revision = &revision
+ }
+ case "org.opencontainers.image.vendor":
+ if v != nil {
+ var vendor string
+ err = json.Unmarshal(*v, &vendor)
+ if err != nil {
+ return err
+ }
+ a.Vendor = &vendor
+ }
+ case "org.opencontainers.image.licenses":
+ if v != nil {
+ var licenses string
+ err = json.Unmarshal(*v, &licenses)
+ if err != nil {
+ return err
+ }
+ a.Licenses = &licenses
+ }
+ case "org.opencontainers.image.ref.name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ a.Name = &name
+ }
+ case "org.opencontainers.image.title":
+ if v != nil {
+ var title string
+ err = json.Unmarshal(*v, &title)
+ if err != nil {
+ return err
+ }
+ a.Title = &title
+ }
+ case "org.opencontainers.image.description":
+ if v != nil {
+ var description string
+ err = json.Unmarshal(*v, &description)
+ if err != nil {
+ return err
+ }
+ a.Description = &description
+ }
+ }
+ }
+
+ return nil
+}
+
+// ChangeableAttributes ...
+type ChangeableAttributes struct {
+ // DeleteEnabled - Delete enabled
+ DeleteEnabled *bool `json:"deleteEnabled,omitempty"`
+ // WriteEnabled - Write enabled
+ WriteEnabled *bool `json:"writeEnabled,omitempty"`
+ // ListEnabled - List enabled
+ ListEnabled *bool `json:"listEnabled,omitempty"`
+ // ReadEnabled - Read enabled
+ ReadEnabled *bool `json:"readEnabled,omitempty"`
+}
+
+// DeletedRepository deleted repository
+type DeletedRepository struct {
+ autorest.Response `json:"-"`
+ // ManifestsDeleted - SHA of the deleted image
+ ManifestsDeleted *[]string `json:"manifestsDeleted,omitempty"`
+ // TagsDeleted - Tag of the deleted image
+ TagsDeleted *[]string `json:"tagsDeleted,omitempty"`
+}
+
+// Descriptor docker V2 image layer descriptor including config and layers
+type Descriptor struct {
+ // MediaType - Layer media type
+ MediaType *string `json:"mediaType,omitempty"`
+ // Size - Layer size
+ Size *int64 `json:"size,omitempty"`
+ // Digest - Layer digest
+ Digest *string `json:"digest,omitempty"`
+ // Urls - Specifies a list of URIs from which this object may be downloaded.
+ Urls *[]string `json:"urls,omitempty"`
+ Annotations *Annotations `json:"annotations,omitempty"`
+}
+
+// FsLayer image layer information
+type FsLayer struct {
+ // BlobSum - SHA of an image layer
+ BlobSum *string `json:"blobSum,omitempty"`
+}
+
+// History a list of unstructured historical data for v1 compatibility
+type History struct {
+ // V1Compatibility - The raw v1 compatibility information
+ V1Compatibility *string `json:"v1Compatibility,omitempty"`
+}
+
+// ImageSignature signature of a signed manifest
+type ImageSignature struct {
+ // Header - A JSON web signature
+ Header *JWK `json:"header,omitempty"`
+ // Signature - A signature for the image manifest, signed by a libtrust private key
+ Signature *string `json:"signature,omitempty"`
+ // Protected - The signed protected header
+ Protected *string `json:"protected,omitempty"`
+}
+
+// JWK a JSON web signature
+type JWK struct {
+ Jwk *JWKHeader `json:"jwk,omitempty"`
+ // Alg - The algorithm used to sign or encrypt the JWT
+ Alg *string `json:"alg,omitempty"`
+}
+
+// JWKHeader JSON web key parameter
+type JWKHeader struct {
+ // Crv - crv value
+ Crv *string `json:"crv,omitempty"`
+ // Kid - kid value
+ Kid *string `json:"kid,omitempty"`
+ // Kty - kty value
+ Kty *string `json:"kty,omitempty"`
+ // X - x value
+ X *string `json:"x,omitempty"`
+ // Y - y value
+ Y *string `json:"y,omitempty"`
+}
+
+// Manifest returns the requested manifest file
+type Manifest struct {
+ // SchemaVersion - Schema version
+ SchemaVersion *int32 `json:"schemaVersion,omitempty"`
+}
+
+// ManifestAttributes manifest attributes details
+type ManifestAttributes struct {
+ autorest.Response `json:"-"`
+ // Registry - Registry name
+ Registry *string `json:"registry,omitempty"`
+ // ImageName - Image name
+ ImageName *string `json:"imageName,omitempty"`
+ // Attributes - Manifest attributes
+ Attributes *ManifestAttributesBase `json:"manifest,omitempty"`
+}
+
+// ManifestAttributesBase manifest details
+type ManifestAttributesBase struct {
+ // Digest - Manifest
+ Digest *string `json:"digest,omitempty"`
+ // ImageSize - Image size
+ ImageSize *int64 `json:"imageSize,omitempty"`
+ // CreatedTime - Created time
+ CreatedTime *string `json:"createdTime,omitempty"`
+ // LastUpdateTime - Last update time
+ LastUpdateTime *string `json:"lastUpdateTime,omitempty"`
+ // Architecture - CPU architecture
+ Architecture *string `json:"architecture,omitempty"`
+ // Os - Operating system
+ Os *string `json:"os,omitempty"`
+ // MediaType - Media type
+ MediaType *string `json:"mediaType,omitempty"`
+ // ConfigMediaType - Config blob media type
+ ConfigMediaType *string `json:"configMediaType,omitempty"`
+ // Tags - List of tags
+ Tags *[]string `json:"tags,omitempty"`
+ // ChangeableAttributes - Changeable attributes
+ ChangeableAttributes *ChangeableAttributes `json:"changeableAttributes,omitempty"`
+}
+
+// ManifestAttributesManifest list of manifest attributes
+type ManifestAttributesManifest struct {
+ // References - List of manifest attributes details
+ References *[]ManifestAttributesManifestReferences `json:"references,omitempty"`
+ // QuarantineTag - Quarantine tag name
+ QuarantineTag *string `json:"quarantineTag,omitempty"`
+}
+
+// ManifestAttributesManifestReferences manifest attributes details
+type ManifestAttributesManifestReferences struct {
+ // Digest - Manifest digest
+ Digest *string `json:"digest,omitempty"`
+ // Architecture - CPU architecture
+ Architecture *string `json:"architecture,omitempty"`
+ // Os - Operating system
+ Os *string `json:"os,omitempty"`
+}
+
+// ManifestChangeableAttributes changeable attributes
+type ManifestChangeableAttributes struct {
+ // DeleteEnabled - Delete enabled
+ DeleteEnabled *bool `json:"deleteEnabled,omitempty"`
+ // WriteEnabled - Write enabled
+ WriteEnabled *bool `json:"writeEnabled,omitempty"`
+ // ListEnabled - List enabled
+ ListEnabled *bool `json:"listEnabled,omitempty"`
+ // ReadEnabled - Read enabled
+ ReadEnabled *bool `json:"readEnabled,omitempty"`
+ // QuarantineState - Quarantine state
+ QuarantineState *string `json:"quarantineState,omitempty"`
+ // QuarantineDetails - Quarantine details
+ QuarantineDetails *string `json:"quarantineDetails,omitempty"`
+}
+
+// ManifestList returns the requested Docker multi-arch-manifest file
+type ManifestList struct {
+ // MediaType - Media type for this Manifest
+ MediaType *string `json:"mediaType,omitempty"`
+ // Manifests - List of V2 image layer information
+ Manifests *[]ManifestListAttributes `json:"manifests,omitempty"`
+ // SchemaVersion - Schema version
+ SchemaVersion *int32 `json:"schemaVersion,omitempty"`
+}
+
+// ManifestListAttributes ...
+type ManifestListAttributes struct {
+ // MediaType - The MIME type of the referenced object. This will generally be application/vnd.docker.image.manifest.v2+json, but it could also be application/vnd.docker.image.manifest.v1+json
+ MediaType *string `json:"mediaType,omitempty"`
+ // Size - The size in bytes of the object
+ Size *int64 `json:"size,omitempty"`
+ // Digest - The digest of the content, as defined by the Registry V2 HTTP API Specification
+ Digest *string `json:"digest,omitempty"`
+ Platform *Platform `json:"platform,omitempty"`
+}
+
+// ManifestWrapper returns the requested manifest file
+type ManifestWrapper struct {
+ autorest.Response `json:"-"`
+ // MediaType - Media type for this Manifest
+ MediaType *string `json:"mediaType,omitempty"`
+ // Manifests - (ManifestList, OCIIndex) List of V2 image layer information
+ Manifests *[]ManifestListAttributes `json:"manifests,omitempty"`
+ // Config - (V2, OCI) Image config descriptor
+ Config *Descriptor `json:"config,omitempty"`
+ // Layers - (V2, OCI) List of V2 image layer information
+ Layers *[]Descriptor `json:"layers,omitempty"`
+ // Annotations - (OCI, OCIIndex) Additional metadata
+ Annotations *Annotations `json:"annotations,omitempty"`
+ // Architecture - (V1) CPU architecture
+ Architecture *string `json:"architecture,omitempty"`
+ // Name - (V1) Image name
+ Name *string `json:"name,omitempty"`
+ // Tag - (V1) Image tag
+ Tag *string `json:"tag,omitempty"`
+ // FsLayers - (V1) List of layer information
+ FsLayers *[]FsLayer `json:"fsLayers,omitempty"`
+ // History - (V1) Image history
+ History *[]History `json:"history,omitempty"`
+ // Signatures - (V1) Image signature
+ Signatures *[]ImageSignature `json:"signatures,omitempty"`
+ // SchemaVersion - Schema version
+ SchemaVersion *int32 `json:"schemaVersion,omitempty"`
+}
+
+// OCIIndex returns the requested OCI index file
+type OCIIndex struct {
+ // Manifests - List of OCI image layer information
+ Manifests *[]ManifestListAttributes `json:"manifests,omitempty"`
+ Annotations *Annotations `json:"annotations,omitempty"`
+ // SchemaVersion - Schema version
+ SchemaVersion *int32 `json:"schemaVersion,omitempty"`
+}
+
+// OCIManifest returns the requested OCI Manifest file
+type OCIManifest struct {
+ // Config - V2 image config descriptor
+ Config *Descriptor `json:"config,omitempty"`
+ // Layers - List of V2 image layer information
+ Layers *[]Descriptor `json:"layers,omitempty"`
+ Annotations *Annotations `json:"annotations,omitempty"`
+ // SchemaVersion - Schema version
+ SchemaVersion *int32 `json:"schemaVersion,omitempty"`
+}
+
+// Platform the platform object describes the platform which the image in the manifest runs on. A full list of
+// valid operating system and architecture values are listed in the Go language documentation for $GOOS and
+// $GOARCH
+type Platform struct {
+ // Architecture - Specifies the CPU architecture, for example amd64 or ppc64le.
+ Architecture *string `json:"architecture,omitempty"`
+ // Os - The os field specifies the operating system, for example linux or windows.
+ Os *string `json:"os,omitempty"`
+ // OsVersion - The optional os.version field specifies the operating system version, for example 10.0.10586.
+ OsVersion *string `json:"os.version,omitempty"`
+ // OsFeatures - The optional os.features field specifies an array of strings, each listing a required OS feature (for example on Windows win32k
+ OsFeatures *[]string `json:"os.features,omitempty"`
+ // Variant - The optional variant field specifies a variant of the CPU, for example armv6l to specify a particular CPU variant of the ARM CPU.
+ Variant *string `json:"variant,omitempty"`
+ // Features - The optional features field specifies an array of strings, each listing a required CPU feature (for example sse4 or aes
+ Features *[]string `json:"features,omitempty"`
+}
+
+// ReadCloser ...
+type ReadCloser struct {
+ autorest.Response `json:"-"`
+ Value *io.ReadCloser `json:"value,omitempty"`
+}
+
+// RefreshToken ...
+type RefreshToken struct {
+ autorest.Response `json:"-"`
+ // RefreshToken - The refresh token to be used for generating access tokens
+ RefreshToken *string `json:"refresh_token,omitempty"`
+}
+
+// Repositories list of repositories
+type Repositories struct {
+ autorest.Response `json:"-"`
+ // Names - Repository names
+ Names *[]string `json:"repositories,omitempty"`
+}
+
+// RepositoryAttributes repository attributes
+type RepositoryAttributes struct {
+ autorest.Response `json:"-"`
+ // Registry - Registry name
+ Registry *string `json:"registry,omitempty"`
+ // ImageName - Image name
+ ImageName *string `json:"imageName,omitempty"`
+ // CreatedTime - Image created time
+ CreatedTime *string `json:"createdTime,omitempty"`
+ // LastUpdateTime - Image last update time
+ LastUpdateTime *string `json:"lastUpdateTime,omitempty"`
+ // ManifestCount - Number of the manifests
+ ManifestCount *int32 `json:"manifestCount,omitempty"`
+ // TagCount - Number of the tags
+ TagCount *int32 `json:"tagCount,omitempty"`
+ // ChangeableAttributes - Changeable attributes
+ ChangeableAttributes *ChangeableAttributes `json:"changeableAttributes,omitempty"`
+}
+
+// RepositoryTags result of the request to list tags of the image
+type RepositoryTags struct {
+ // Name - Name of the image
+ Name *string `json:"name,omitempty"`
+ // Tags - List of tags
+ Tags *[]string `json:"tags,omitempty"`
+}
+
+// SetObject ...
+type SetObject struct {
+ autorest.Response `json:"-"`
+ Value interface{} `json:"value,omitempty"`
+}
+
+// TagAttributes tag attributes
+type TagAttributes struct {
+ autorest.Response `json:"-"`
+ // Registry - Registry name
+ Registry *string `json:"registry,omitempty"`
+ // ImageName - Image name
+ ImageName *string `json:"imageName,omitempty"`
+ // Attributes - List of tag attribute details
+ Attributes *TagAttributesBase `json:"tag,omitempty"`
+}
+
+// TagAttributesBase tag attribute details
+type TagAttributesBase struct {
+ // Name - Tag name
+ Name *string `json:"name,omitempty"`
+ // Digest - Tag digest
+ Digest *string `json:"digest,omitempty"`
+ // CreatedTime - Tag created time
+ CreatedTime *string `json:"createdTime,omitempty"`
+ // LastUpdateTime - Tag last update time
+ LastUpdateTime *string `json:"lastUpdateTime,omitempty"`
+ // Signed - Is signed
+ Signed *bool `json:"signed,omitempty"`
+ // ChangeableAttributes - Changeable attributes
+ ChangeableAttributes *ChangeableAttributes `json:"changeableAttributes,omitempty"`
+}
+
+// TagAttributesTag tag
+type TagAttributesTag struct {
+ // SignatureRecord - SignatureRecord value
+ SignatureRecord *string `json:"signatureRecord,omitempty"`
+}
+
+// TagList list of tag details
+type TagList struct {
+ autorest.Response `json:"-"`
+ // Registry - Registry name
+ Registry *string `json:"registry,omitempty"`
+ // ImageName - Image name
+ ImageName *string `json:"imageName,omitempty"`
+ // Tags - List of tag attribute details
+ Tags *[]TagAttributesBase `json:"tags,omitempty"`
+}
+
+// V1Manifest returns the requested V1 manifest file
+type V1Manifest struct {
+ // Architecture - CPU architecture
+ Architecture *string `json:"architecture,omitempty"`
+ // Name - Image name
+ Name *string `json:"name,omitempty"`
+ // Tag - Image tag
+ Tag *string `json:"tag,omitempty"`
+ // FsLayers - List of layer information
+ FsLayers *[]FsLayer `json:"fsLayers,omitempty"`
+ // History - Image history
+ History *[]History `json:"history,omitempty"`
+ // Signatures - Image signature
+ Signatures *[]ImageSignature `json:"signatures,omitempty"`
+ // SchemaVersion - Schema version
+ SchemaVersion *int32 `json:"schemaVersion,omitempty"`
+}
+
+// V2Manifest returns the requested Docker V2 Manifest file
+type V2Manifest struct {
+ // MediaType - Media type for this Manifest
+ MediaType *string `json:"mediaType,omitempty"`
+ // Config - V2 image config descriptor
+ Config *Descriptor `json:"config,omitempty"`
+ // Layers - List of V2 image layer information
+ Layers *[]Descriptor `json:"layers,omitempty"`
+ // SchemaVersion - Schema version
+ SchemaVersion *int32 `json:"schemaVersion,omitempty"`
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/refreshtokens.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/refreshtokens.go
new file mode 100644
index 000000000000..c1dab3b259ea
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/refreshtokens.go
@@ -0,0 +1,121 @@
+package containerregistry
+
+// Copyright (c) Microsoft and contributors. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+import (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// RefreshTokensClient is the metadata API definition for the Azure Container Registry runtime
+type RefreshTokensClient struct {
+ BaseClient
+}
+
+// NewRefreshTokensClient creates an instance of the RefreshTokensClient client.
+func NewRefreshTokensClient(loginURI string) RefreshTokensClient {
+ return RefreshTokensClient{New(loginURI)}
+}
+
+// GetFromExchange exchange AAD tokens for an ACR refresh Token
+// Parameters:
+// grantType - can take a value of access_token_refresh_token, or access_token, or refresh_token
+// service - indicates the name of your Azure container registry.
+// tenant - AAD tenant associated to the AAD credentials.
+// refreshToken - AAD refresh token, mandatory when grant_type is access_token_refresh_token or refresh_token
+// accessToken - AAD access token, mandatory when grant_type is access_token_refresh_token or access_token.
+func (client RefreshTokensClient) GetFromExchange(ctx context.Context, grantType string, service string, tenant string, refreshToken string, accessToken string) (result RefreshToken, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RefreshTokensClient.GetFromExchange")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetFromExchangePreparer(ctx, grantType, service, tenant, refreshToken, accessToken)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RefreshTokensClient", "GetFromExchange", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetFromExchangeSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.RefreshTokensClient", "GetFromExchange", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetFromExchangeResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RefreshTokensClient", "GetFromExchange", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetFromExchangePreparer prepares the GetFromExchange request.
+func (client RefreshTokensClient) GetFromExchangePreparer(ctx context.Context, grantType string, service string, tenant string, refreshToken string, accessToken string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ formDataParameters := map[string]interface{}{
+ "grant_type": grantType,
+ "service": service,
+ }
+ if len(tenant) > 0 {
+ formDataParameters["tenant"] = tenant
+ }
+ if len(refreshToken) > 0 {
+ formDataParameters["refresh_token"] = refreshToken
+ }
+ if len(accessToken) > 0 {
+ formDataParameters["access_token"] = accessToken
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPath("/oauth2/exchange"),
+ autorest.WithFormData(autorest.MapToValues(formDataParameters)))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetFromExchangeSender sends the GetFromExchange request. The method will close the
+// http.Response Body if it receives an error.
+func (client RefreshTokensClient) GetFromExchangeSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetFromExchangeResponder handles the response to the GetFromExchange request. The method always
+// closes the http.Response Body.
+func (client RefreshTokensClient) GetFromExchangeResponder(resp *http.Response) (result RefreshToken, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/repository.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/repository.go
new file mode 100644
index 000000000000..b0a856d5cb6a
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/repository.go
@@ -0,0 +1,328 @@
+package containerregistry
+
+// Copyright (c) Microsoft and contributors. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+import (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// RepositoryClient is the metadata API definition for the Azure Container Registry runtime
+type RepositoryClient struct {
+ BaseClient
+}
+
+// NewRepositoryClient creates an instance of the RepositoryClient client.
+func NewRepositoryClient(loginURI string) RepositoryClient {
+ return RepositoryClient{New(loginURI)}
+}
+
+// Delete delete the repository identified by `name`
+// Parameters:
+// name - name of the image (including the namespace)
+func (client RepositoryClient) Delete(ctx context.Context, name string) (result DeletedRepository, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RepositoryClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client RepositoryClient) DeletePreparer(ctx context.Context, name string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client RepositoryClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client RepositoryClient) DeleteResponder(resp *http.Response) (result DeletedRepository, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetAttributes get repository attributes
+// Parameters:
+// name - name of the image (including the namespace)
+func (client RepositoryClient) GetAttributes(ctx context.Context, name string) (result RepositoryAttributes, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RepositoryClient.GetAttributes")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetAttributesPreparer(ctx, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "GetAttributes", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetAttributesSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "GetAttributes", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetAttributesResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "GetAttributes", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetAttributesPreparer prepares the GetAttributes request.
+func (client RepositoryClient) GetAttributesPreparer(ctx context.Context, name string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetAttributesSender sends the GetAttributes request. The method will close the
+// http.Response Body if it receives an error.
+func (client RepositoryClient) GetAttributesSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetAttributesResponder handles the response to the GetAttributes request. The method always
+// closes the http.Response Body.
+func (client RepositoryClient) GetAttributesResponder(resp *http.Response) (result RepositoryAttributes, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetList list repositories
+// Parameters:
+// last - query parameter for the last item in previous query. Result set will include values lexically after
+// last.
+// n - query parameter for max number of items
+func (client RepositoryClient) GetList(ctx context.Context, last string, n *int32) (result Repositories, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RepositoryClient.GetList")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetListPreparer(ctx, last, n)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "GetList", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "GetList", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "GetList", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetListPreparer prepares the GetList request.
+func (client RepositoryClient) GetListPreparer(ctx context.Context, last string, n *int32) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ queryParameters := map[string]interface{}{}
+ if len(last) > 0 {
+ queryParameters["last"] = autorest.Encode("query", last)
+ }
+ if n != nil {
+ queryParameters["n"] = autorest.Encode("query", *n)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPath("/acr/v1/_catalog"),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetListSender sends the GetList request. The method will close the
+// http.Response Body if it receives an error.
+func (client RepositoryClient) GetListSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetListResponder handles the response to the GetList request. The method always
+// closes the http.Response Body.
+func (client RepositoryClient) GetListResponder(resp *http.Response) (result Repositories, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// UpdateAttributes update the attribute identified by `name` where `reference` is the name of the repository.
+// Parameters:
+// name - name of the image (including the namespace)
+// value - repository attribute value
+func (client RepositoryClient) UpdateAttributes(ctx context.Context, name string, value *ChangeableAttributes) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RepositoryClient.UpdateAttributes")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdateAttributesPreparer(ctx, name, value)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "UpdateAttributes", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.UpdateAttributesSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "UpdateAttributes", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.UpdateAttributesResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "UpdateAttributes", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// UpdateAttributesPreparer prepares the UpdateAttributes request.
+func (client RepositoryClient) UpdateAttributesPreparer(ctx context.Context, name string, value *ChangeableAttributes) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}", pathParameters))
+ if value != nil {
+ preparer = autorest.DecoratePreparer(preparer,
+ autorest.WithJSON(value))
+ }
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateAttributesSender sends the UpdateAttributes request. The method will close the
+// http.Response Body if it receives an error.
+func (client RepositoryClient) UpdateAttributesSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// UpdateAttributesResponder handles the response to the UpdateAttributes request. The method always
+// closes the http.Response Body.
+func (client RepositoryClient) UpdateAttributesResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/tag.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/tag.go
new file mode 100644
index 000000000000..5690c1ad9c99
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/tag.go
@@ -0,0 +1,346 @@
+package containerregistry
+
+// Copyright (c) Microsoft and contributors. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+import (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// TagClient is the metadata API definition for the Azure Container Registry runtime
+type TagClient struct {
+ BaseClient
+}
+
+// NewTagClient creates an instance of the TagClient client.
+func NewTagClient(loginURI string) TagClient {
+ return TagClient{New(loginURI)}
+}
+
+// Delete delete tag
+// Parameters:
+// name - name of the image (including the namespace)
+// reference - tag name
+func (client TagClient) Delete(ctx context.Context, name string, reference string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/TagClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, name, reference)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client TagClient) DeletePreparer(ctx context.Context, name string, reference string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "reference": autorest.Encode("path", reference),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}/_tags/{reference}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client TagClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client TagClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// GetAttributes get tag attributes by tag
+// Parameters:
+// name - name of the image (including the namespace)
+// reference - tag name
+func (client TagClient) GetAttributes(ctx context.Context, name string, reference string) (result TagAttributes, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/TagClient.GetAttributes")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetAttributesPreparer(ctx, name, reference)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "GetAttributes", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetAttributesSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "GetAttributes", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetAttributesResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "GetAttributes", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetAttributesPreparer prepares the GetAttributes request.
+func (client TagClient) GetAttributesPreparer(ctx context.Context, name string, reference string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "reference": autorest.Encode("path", reference),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}/_tags/{reference}", pathParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetAttributesSender sends the GetAttributes request. The method will close the
+// http.Response Body if it receives an error.
+func (client TagClient) GetAttributesSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetAttributesResponder handles the response to the GetAttributes request. The method always
+// closes the http.Response Body.
+func (client TagClient) GetAttributesResponder(resp *http.Response) (result TagAttributes, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetList list tags of a repository
+// Parameters:
+// name - name of the image (including the namespace)
+// last - query parameter for the last item in previous query. Result set will include values lexically after
+// last.
+// n - query parameter for max number of items
+// orderby - orderby query parameter
+// digest - filter by digest
+func (client TagClient) GetList(ctx context.Context, name string, last string, n *int32, orderby string, digest string) (result TagList, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/TagClient.GetList")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetListPreparer(ctx, name, last, n, orderby, digest)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "GetList", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "GetList", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "GetList", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetListPreparer prepares the GetList request.
+func (client TagClient) GetListPreparer(ctx context.Context, name string, last string, n *int32, orderby string, digest string) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ }
+
+ queryParameters := map[string]interface{}{}
+ if len(last) > 0 {
+ queryParameters["last"] = autorest.Encode("query", last)
+ }
+ if n != nil {
+ queryParameters["n"] = autorest.Encode("query", *n)
+ }
+ if len(orderby) > 0 {
+ queryParameters["orderby"] = autorest.Encode("query", orderby)
+ }
+ if len(digest) > 0 {
+ queryParameters["digest"] = autorest.Encode("query", digest)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}/_tags", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetListSender sends the GetList request. The method will close the
+// http.Response Body if it receives an error.
+func (client TagClient) GetListSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// GetListResponder handles the response to the GetList request. The method always
+// closes the http.Response Body.
+func (client TagClient) GetListResponder(resp *http.Response) (result TagList, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// UpdateAttributes update tag attributes
+// Parameters:
+// name - name of the image (including the namespace)
+// reference - tag name
+// value - repository attribute value
+func (client TagClient) UpdateAttributes(ctx context.Context, name string, reference string, value *ChangeableAttributes) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/TagClient.UpdateAttributes")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdateAttributesPreparer(ctx, name, reference, value)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "UpdateAttributes", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.UpdateAttributesSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "UpdateAttributes", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.UpdateAttributesResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "UpdateAttributes", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// UpdateAttributesPreparer prepares the UpdateAttributes request.
+func (client TagClient) UpdateAttributesPreparer(ctx context.Context, name string, reference string, value *ChangeableAttributes) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "reference": autorest.Encode("path", reference),
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPathParameters("/acr/v1/{name}/_tags/{reference}", pathParameters))
+ if value != nil {
+ preparer = autorest.DecoratePreparer(preparer,
+ autorest.WithJSON(value))
+ }
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateAttributesSender sends the UpdateAttributes request. The method will close the
+// http.Response Body if it receives an error.
+func (client TagClient) UpdateAttributesSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// UpdateAttributesResponder handles the response to the UpdateAttributes request. The method always
+// closes the http.Response Body.
+func (client TagClient) UpdateAttributesResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/v2support.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/v2support.go
new file mode 100644
index 000000000000..56543f63049f
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/v2support.go
@@ -0,0 +1,99 @@
+package containerregistry
+
+// Copyright (c) Microsoft and contributors. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+import (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// V2SupportClient is the metadata API definition for the Azure Container Registry runtime
+type V2SupportClient struct {
+ BaseClient
+}
+
+// NewV2SupportClient creates an instance of the V2SupportClient client.
+func NewV2SupportClient(loginURI string) V2SupportClient {
+ return V2SupportClient{New(loginURI)}
+}
+
+// Check tells whether this Docker Registry instance supports Docker Registry HTTP API v2
+func (client V2SupportClient) Check(ctx context.Context) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/V2SupportClient.Check")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CheckPreparer(ctx)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.V2SupportClient", "Check", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CheckSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "containerregistry.V2SupportClient", "Check", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CheckResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "containerregistry.V2SupportClient", "Check", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CheckPreparer prepares the Check request.
+func (client V2SupportClient) CheckPreparer(ctx context.Context) (*http.Request, error) {
+ urlParameters := map[string]interface{}{
+ "url": client.LoginURI,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithCustomBaseURL("{url}", urlParameters),
+ autorest.WithPath("/v2/"))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CheckSender sends the Check request. The method will close the
+// http.Response Body if it receives an error.
+func (client V2SupportClient) CheckSender(req *http.Request) (*http.Response, error) {
+ return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+}
+
+// CheckResponder handles the response to the Check request. The method always
+// closes the http.Response Body.
+func (client V2SupportClient) CheckResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/version.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/version.go
similarity index 98%
rename from vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/version.go
rename to vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/version.go
index 8c51fa478b79..874b077cf95b 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry/version.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/version.go
@@ -21,7 +21,7 @@ import "github.com/Azure/azure-sdk-for-go/version"
// UserAgent returns the UserAgent string to use when sending http.Requests.
func UserAgent() string {
- return "Azure-SDK-For-Go/" + Version() + " containerregistry/2019-05-01"
+ return "Azure-SDK-For-Go/" + Version() + " containerregistry/2019-08-15-preview"
}
// Version returns the semantic version (see http://semver.org) of the client.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/version/version.go b/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
index ae1ef97e166e..168697eafd8f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
@@ -18,4 +18,4 @@ package version
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
// Number contains the semantic version of this SDK.
-const Number = "v43.0.0"
+const Number = "v46.4.0"
diff --git a/vendor/github.com/Azure/go-autorest/autorest/to/LICENSE b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/LICENSE
similarity index 100%
rename from vendor/github.com/Azure/go-autorest/autorest/to/LICENSE
rename to vendor/github.com/Azure/go-autorest/autorest/azure/auth/LICENSE
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go
new file mode 100644
index 000000000000..596b9f5777db
--- /dev/null
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go
@@ -0,0 +1,730 @@
+package auth
+
+// Copyright 2017 Microsoft Corporation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+import (
+ "bytes"
+ "encoding/binary"
+ "encoding/json"
+ "errors"
+ "fmt"
+ "io/ioutil"
+ "log"
+ "os"
+ "strings"
+ "unicode/utf16"
+
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/adal"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/azure/cli"
+ "github.com/dimchansky/utfbom"
+)
+
+// The possible keys in the Values map.
+const (
+ SubscriptionID = "AZURE_SUBSCRIPTION_ID"
+ TenantID = "AZURE_TENANT_ID"
+ AuxiliaryTenantIDs = "AZURE_AUXILIARY_TENANT_IDS"
+ ClientID = "AZURE_CLIENT_ID"
+ ClientSecret = "AZURE_CLIENT_SECRET"
+ CertificatePath = "AZURE_CERTIFICATE_PATH"
+ CertificatePassword = "AZURE_CERTIFICATE_PASSWORD"
+ Username = "AZURE_USERNAME"
+ Password = "AZURE_PASSWORD"
+ EnvironmentName = "AZURE_ENVIRONMENT"
+ Resource = "AZURE_AD_RESOURCE"
+ ActiveDirectoryEndpoint = "ActiveDirectoryEndpoint"
+ ResourceManagerEndpoint = "ResourceManagerEndpoint"
+ GraphResourceID = "GraphResourceID"
+ SQLManagementEndpoint = "SQLManagementEndpoint"
+ GalleryEndpoint = "GalleryEndpoint"
+ ManagementEndpoint = "ManagementEndpoint"
+)
+
+// NewAuthorizerFromEnvironment creates an Authorizer configured from environment variables in the order:
+// 1. Client credentials
+// 2. Client certificate
+// 3. Username password
+// 4. MSI
+func NewAuthorizerFromEnvironment() (autorest.Authorizer, error) {
+ settings, err := GetSettingsFromEnvironment()
+ if err != nil {
+ return nil, err
+ }
+ return settings.GetAuthorizer()
+}
+
+// NewAuthorizerFromEnvironmentWithResource creates an Authorizer configured from environment variables in the order:
+// 1. Client credentials
+// 2. Client certificate
+// 3. Username password
+// 4. MSI
+func NewAuthorizerFromEnvironmentWithResource(resource string) (autorest.Authorizer, error) {
+ settings, err := GetSettingsFromEnvironment()
+ if err != nil {
+ return nil, err
+ }
+ settings.Values[Resource] = resource
+ return settings.GetAuthorizer()
+}
+
+// EnvironmentSettings contains the available authentication settings.
+type EnvironmentSettings struct {
+ Values map[string]string
+ Environment azure.Environment
+}
+
+// GetSettingsFromEnvironment returns the available authentication settings from the environment.
+func GetSettingsFromEnvironment() (s EnvironmentSettings, err error) {
+ s = EnvironmentSettings{
+ Values: map[string]string{},
+ }
+ s.setValue(SubscriptionID)
+ s.setValue(TenantID)
+ s.setValue(AuxiliaryTenantIDs)
+ s.setValue(ClientID)
+ s.setValue(ClientSecret)
+ s.setValue(CertificatePath)
+ s.setValue(CertificatePassword)
+ s.setValue(Username)
+ s.setValue(Password)
+ s.setValue(EnvironmentName)
+ s.setValue(Resource)
+ if v := s.Values[EnvironmentName]; v == "" {
+ s.Environment = azure.PublicCloud
+ } else {
+ s.Environment, err = azure.EnvironmentFromName(v)
+ }
+ if s.Values[Resource] == "" {
+ s.Values[Resource] = s.Environment.ResourceManagerEndpoint
+ }
+ return
+}
+
+// GetSubscriptionID returns the available subscription ID or an empty string.
+func (settings EnvironmentSettings) GetSubscriptionID() string {
+ return settings.Values[SubscriptionID]
+}
+
+// adds the specified environment variable value to the Values map if it exists
+func (settings EnvironmentSettings) setValue(key string) {
+ if v := os.Getenv(key); v != "" {
+ settings.Values[key] = v
+ }
+}
+
+// helper to return client and tenant IDs
+func (settings EnvironmentSettings) getClientAndTenant() (string, string) {
+ clientID := settings.Values[ClientID]
+ tenantID := settings.Values[TenantID]
+ return clientID, tenantID
+}
+
+// GetClientCredentials creates a config object from the available client credentials.
+// An error is returned if no client credentials are available.
+func (settings EnvironmentSettings) GetClientCredentials() (ClientCredentialsConfig, error) {
+ secret := settings.Values[ClientSecret]
+ if secret == "" {
+ return ClientCredentialsConfig{}, errors.New("missing client secret")
+ }
+ clientID, tenantID := settings.getClientAndTenant()
+ config := NewClientCredentialsConfig(clientID, secret, tenantID)
+ config.AADEndpoint = settings.Environment.ActiveDirectoryEndpoint
+ config.Resource = settings.Values[Resource]
+ if auxTenants, ok := settings.Values[AuxiliaryTenantIDs]; ok {
+ config.AuxTenants = strings.Split(auxTenants, ";")
+ for i := range config.AuxTenants {
+ config.AuxTenants[i] = strings.TrimSpace(config.AuxTenants[i])
+ }
+ }
+ return config, nil
+}
+
+// GetClientCertificate creates a config object from the available certificate credentials.
+// An error is returned if no certificate credentials are available.
+func (settings EnvironmentSettings) GetClientCertificate() (ClientCertificateConfig, error) {
+ certPath := settings.Values[CertificatePath]
+ if certPath == "" {
+ return ClientCertificateConfig{}, errors.New("missing certificate path")
+ }
+ certPwd := settings.Values[CertificatePassword]
+ clientID, tenantID := settings.getClientAndTenant()
+ config := NewClientCertificateConfig(certPath, certPwd, clientID, tenantID)
+ config.AADEndpoint = settings.Environment.ActiveDirectoryEndpoint
+ config.Resource = settings.Values[Resource]
+ return config, nil
+}
+
+// GetUsernamePassword creates a config object from the available username/password credentials.
+// An error is returned if no username/password credentials are available.
+func (settings EnvironmentSettings) GetUsernamePassword() (UsernamePasswordConfig, error) {
+ username := settings.Values[Username]
+ password := settings.Values[Password]
+ if username == "" || password == "" {
+ return UsernamePasswordConfig{}, errors.New("missing username/password")
+ }
+ clientID, tenantID := settings.getClientAndTenant()
+ config := NewUsernamePasswordConfig(username, password, clientID, tenantID)
+ config.AADEndpoint = settings.Environment.ActiveDirectoryEndpoint
+ config.Resource = settings.Values[Resource]
+ return config, nil
+}
+
+// GetMSI creates a MSI config object from the available client ID.
+func (settings EnvironmentSettings) GetMSI() MSIConfig {
+ config := NewMSIConfig()
+ config.Resource = settings.Values[Resource]
+ config.ClientID = settings.Values[ClientID]
+ return config
+}
+
+// GetDeviceFlow creates a device-flow config object from the available client and tenant IDs.
+func (settings EnvironmentSettings) GetDeviceFlow() DeviceFlowConfig {
+ clientID, tenantID := settings.getClientAndTenant()
+ config := NewDeviceFlowConfig(clientID, tenantID)
+ config.AADEndpoint = settings.Environment.ActiveDirectoryEndpoint
+ config.Resource = settings.Values[Resource]
+ return config
+}
+
+// GetAuthorizer creates an Authorizer configured from environment variables in the order:
+// 1. Client credentials
+// 2. Client certificate
+// 3. Username password
+// 4. MSI
+func (settings EnvironmentSettings) GetAuthorizer() (autorest.Authorizer, error) {
+ //1.Client Credentials
+ if c, e := settings.GetClientCredentials(); e == nil {
+ return c.Authorizer()
+ }
+
+ //2. Client Certificate
+ if c, e := settings.GetClientCertificate(); e == nil {
+ return c.Authorizer()
+ }
+
+ //3. Username Password
+ if c, e := settings.GetUsernamePassword(); e == nil {
+ return c.Authorizer()
+ }
+
+ // 4. MSI
+ return settings.GetMSI().Authorizer()
+}
+
+// NewAuthorizerFromFile creates an Authorizer configured from a configuration file in the following order.
+// 1. Client credentials
+// 2. Client certificate
+func NewAuthorizerFromFile(baseURI string) (autorest.Authorizer, error) {
+ settings, err := GetSettingsFromFile()
+ if err != nil {
+ return nil, err
+ }
+ if a, err := settings.ClientCredentialsAuthorizer(baseURI); err == nil {
+ return a, err
+ }
+ if a, err := settings.ClientCertificateAuthorizer(baseURI); err == nil {
+ return a, err
+ }
+ return nil, errors.New("auth file missing client and certificate credentials")
+}
+
+// NewAuthorizerFromFileWithResource creates an Authorizer configured from a configuration file in the following order.
+// 1. Client credentials
+// 2. Client certificate
+func NewAuthorizerFromFileWithResource(resource string) (autorest.Authorizer, error) {
+ s, err := GetSettingsFromFile()
+ if err != nil {
+ return nil, err
+ }
+ if a, err := s.ClientCredentialsAuthorizerWithResource(resource); err == nil {
+ return a, err
+ }
+ if a, err := s.ClientCertificateAuthorizerWithResource(resource); err == nil {
+ return a, err
+ }
+ return nil, errors.New("auth file missing client and certificate credentials")
+}
+
+// NewAuthorizerFromCLI creates an Authorizer configured from Azure CLI 2.0 for local development scenarios.
+func NewAuthorizerFromCLI() (autorest.Authorizer, error) {
+ settings, err := GetSettingsFromEnvironment()
+ if err != nil {
+ return nil, err
+ }
+
+ if settings.Values[Resource] == "" {
+ settings.Values[Resource] = settings.Environment.ResourceManagerEndpoint
+ }
+
+ return NewAuthorizerFromCLIWithResource(settings.Values[Resource])
+}
+
+// NewAuthorizerFromCLIWithResource creates an Authorizer configured from Azure CLI 2.0 for local development scenarios.
+func NewAuthorizerFromCLIWithResource(resource string) (autorest.Authorizer, error) {
+ token, err := cli.GetTokenFromCLI(resource)
+ if err != nil {
+ return nil, err
+ }
+
+ adalToken, err := token.ToADALToken()
+ if err != nil {
+ return nil, err
+ }
+
+ return autorest.NewBearerAuthorizer(&adalToken), nil
+}
+
+// GetSettingsFromFile returns the available authentication settings from an Azure CLI authentication file.
+func GetSettingsFromFile() (FileSettings, error) {
+ s := FileSettings{}
+ fileLocation := os.Getenv("AZURE_AUTH_LOCATION")
+ if fileLocation == "" {
+ return s, errors.New("environment variable AZURE_AUTH_LOCATION is not set")
+ }
+
+ contents, err := ioutil.ReadFile(fileLocation)
+ if err != nil {
+ return s, err
+ }
+
+ // Auth file might be encoded
+ decoded, err := decode(contents)
+ if err != nil {
+ return s, err
+ }
+
+ authFile := map[string]interface{}{}
+ err = json.Unmarshal(decoded, &authFile)
+ if err != nil {
+ return s, err
+ }
+
+ s.Values = map[string]string{}
+ s.setKeyValue(ClientID, authFile["clientId"])
+ s.setKeyValue(ClientSecret, authFile["clientSecret"])
+ s.setKeyValue(CertificatePath, authFile["clientCertificate"])
+ s.setKeyValue(CertificatePassword, authFile["clientCertificatePassword"])
+ s.setKeyValue(SubscriptionID, authFile["subscriptionId"])
+ s.setKeyValue(TenantID, authFile["tenantId"])
+ s.setKeyValue(ActiveDirectoryEndpoint, authFile["activeDirectoryEndpointUrl"])
+ s.setKeyValue(ResourceManagerEndpoint, authFile["resourceManagerEndpointUrl"])
+ s.setKeyValue(GraphResourceID, authFile["activeDirectoryGraphResourceId"])
+ s.setKeyValue(SQLManagementEndpoint, authFile["sqlManagementEndpointUrl"])
+ s.setKeyValue(GalleryEndpoint, authFile["galleryEndpointUrl"])
+ s.setKeyValue(ManagementEndpoint, authFile["managementEndpointUrl"])
+ return s, nil
+}
+
+// FileSettings contains the available authentication settings.
+type FileSettings struct {
+ Values map[string]string
+}
+
+// GetSubscriptionID returns the available subscription ID or an empty string.
+func (settings FileSettings) GetSubscriptionID() string {
+ return settings.Values[SubscriptionID]
+}
+
+// adds the specified value to the Values map if it isn't nil
+func (settings FileSettings) setKeyValue(key string, val interface{}) {
+ if val != nil {
+ settings.Values[key] = val.(string)
+ }
+}
+
+// returns the specified AAD endpoint or the public cloud endpoint if unspecified
+func (settings FileSettings) getAADEndpoint() string {
+ if v, ok := settings.Values[ActiveDirectoryEndpoint]; ok {
+ return v
+ }
+ return azure.PublicCloud.ActiveDirectoryEndpoint
+}
+
+// ServicePrincipalTokenFromClientCredentials creates a ServicePrincipalToken from the available client credentials.
+func (settings FileSettings) ServicePrincipalTokenFromClientCredentials(baseURI string) (*adal.ServicePrincipalToken, error) {
+ resource, err := settings.getResourceForToken(baseURI)
+ if err != nil {
+ return nil, err
+ }
+ return settings.ServicePrincipalTokenFromClientCredentialsWithResource(resource)
+}
+
+// ClientCredentialsAuthorizer creates an authorizer from the available client credentials.
+func (settings FileSettings) ClientCredentialsAuthorizer(baseURI string) (autorest.Authorizer, error) {
+ resource, err := settings.getResourceForToken(baseURI)
+ if err != nil {
+ return nil, err
+ }
+ return settings.ClientCredentialsAuthorizerWithResource(resource)
+}
+
+// ServicePrincipalTokenFromClientCredentialsWithResource creates a ServicePrincipalToken
+// from the available client credentials and the specified resource.
+func (settings FileSettings) ServicePrincipalTokenFromClientCredentialsWithResource(resource string) (*adal.ServicePrincipalToken, error) {
+ if _, ok := settings.Values[ClientSecret]; !ok {
+ return nil, errors.New("missing client secret")
+ }
+ config, err := adal.NewOAuthConfig(settings.getAADEndpoint(), settings.Values[TenantID])
+ if err != nil {
+ return nil, err
+ }
+ return adal.NewServicePrincipalToken(*config, settings.Values[ClientID], settings.Values[ClientSecret], resource)
+}
+
+func (settings FileSettings) clientCertificateConfigWithResource(resource string) (ClientCertificateConfig, error) {
+ if _, ok := settings.Values[CertificatePath]; !ok {
+ return ClientCertificateConfig{}, errors.New("missing certificate path")
+ }
+ cfg := NewClientCertificateConfig(settings.Values[CertificatePath], settings.Values[CertificatePassword], settings.Values[ClientID], settings.Values[TenantID])
+ cfg.AADEndpoint = settings.getAADEndpoint()
+ cfg.Resource = resource
+ return cfg, nil
+}
+
+// ClientCredentialsAuthorizerWithResource creates an authorizer from the available client credentials and the specified resource.
+func (settings FileSettings) ClientCredentialsAuthorizerWithResource(resource string) (autorest.Authorizer, error) {
+ spToken, err := settings.ServicePrincipalTokenFromClientCredentialsWithResource(resource)
+ if err != nil {
+ return nil, err
+ }
+ return autorest.NewBearerAuthorizer(spToken), nil
+}
+
+// ServicePrincipalTokenFromClientCertificate creates a ServicePrincipalToken from the available certificate credentials.
+func (settings FileSettings) ServicePrincipalTokenFromClientCertificate(baseURI string) (*adal.ServicePrincipalToken, error) {
+ resource, err := settings.getResourceForToken(baseURI)
+ if err != nil {
+ return nil, err
+ }
+ return settings.ServicePrincipalTokenFromClientCertificateWithResource(resource)
+}
+
+// ClientCertificateAuthorizer creates an authorizer from the available certificate credentials.
+func (settings FileSettings) ClientCertificateAuthorizer(baseURI string) (autorest.Authorizer, error) {
+ resource, err := settings.getResourceForToken(baseURI)
+ if err != nil {
+ return nil, err
+ }
+ return settings.ClientCertificateAuthorizerWithResource(resource)
+}
+
+// ServicePrincipalTokenFromClientCertificateWithResource creates a ServicePrincipalToken from the available certificate credentials.
+func (settings FileSettings) ServicePrincipalTokenFromClientCertificateWithResource(resource string) (*adal.ServicePrincipalToken, error) {
+ cfg, err := settings.clientCertificateConfigWithResource(resource)
+ if err != nil {
+ return nil, err
+ }
+ return cfg.ServicePrincipalToken()
+}
+
+// ClientCertificateAuthorizerWithResource creates an authorizer from the available certificate credentials and the specified resource.
+func (settings FileSettings) ClientCertificateAuthorizerWithResource(resource string) (autorest.Authorizer, error) {
+ cfg, err := settings.clientCertificateConfigWithResource(resource)
+ if err != nil {
+ return nil, err
+ }
+ return cfg.Authorizer()
+}
+
+func decode(b []byte) ([]byte, error) {
+ reader, enc := utfbom.Skip(bytes.NewReader(b))
+
+ switch enc {
+ case utfbom.UTF16LittleEndian:
+ u16 := make([]uint16, (len(b)/2)-1)
+ err := binary.Read(reader, binary.LittleEndian, &u16)
+ if err != nil {
+ return nil, err
+ }
+ return []byte(string(utf16.Decode(u16))), nil
+ case utfbom.UTF16BigEndian:
+ u16 := make([]uint16, (len(b)/2)-1)
+ err := binary.Read(reader, binary.BigEndian, &u16)
+ if err != nil {
+ return nil, err
+ }
+ return []byte(string(utf16.Decode(u16))), nil
+ }
+ return ioutil.ReadAll(reader)
+}
+
+func (settings FileSettings) getResourceForToken(baseURI string) (string, error) {
+ // Compare default base URI from the SDK to the endpoints from the public cloud
+ // Base URI and token resource are the same string. This func finds the authentication
+ // file field that matches the SDK base URI. The SDK defines the public cloud
+ // endpoint as its default base URI
+ if !strings.HasSuffix(baseURI, "/") {
+ baseURI += "/"
+ }
+ switch baseURI {
+ case azure.PublicCloud.ServiceManagementEndpoint:
+ return settings.Values[ManagementEndpoint], nil
+ case azure.PublicCloud.ResourceManagerEndpoint:
+ return settings.Values[ResourceManagerEndpoint], nil
+ case azure.PublicCloud.ActiveDirectoryEndpoint:
+ return settings.Values[ActiveDirectoryEndpoint], nil
+ case azure.PublicCloud.GalleryEndpoint:
+ return settings.Values[GalleryEndpoint], nil
+ case azure.PublicCloud.GraphEndpoint:
+ return settings.Values[GraphResourceID], nil
+ }
+ return "", fmt.Errorf("auth: base URI not found in endpoints")
+}
+
+// NewClientCredentialsConfig creates an AuthorizerConfig object configured to obtain an Authorizer through Client Credentials.
+// Defaults to Public Cloud and Resource Manager Endpoint.
+func NewClientCredentialsConfig(clientID string, clientSecret string, tenantID string) ClientCredentialsConfig {
+ return ClientCredentialsConfig{
+ ClientID: clientID,
+ ClientSecret: clientSecret,
+ TenantID: tenantID,
+ Resource: azure.PublicCloud.ResourceManagerEndpoint,
+ AADEndpoint: azure.PublicCloud.ActiveDirectoryEndpoint,
+ }
+}
+
+// NewClientCertificateConfig creates a ClientCertificateConfig object configured to obtain an Authorizer through client certificate.
+// Defaults to Public Cloud and Resource Manager Endpoint.
+func NewClientCertificateConfig(certificatePath string, certificatePassword string, clientID string, tenantID string) ClientCertificateConfig {
+ return ClientCertificateConfig{
+ CertificatePath: certificatePath,
+ CertificatePassword: certificatePassword,
+ ClientID: clientID,
+ TenantID: tenantID,
+ Resource: azure.PublicCloud.ResourceManagerEndpoint,
+ AADEndpoint: azure.PublicCloud.ActiveDirectoryEndpoint,
+ }
+}
+
+// NewUsernamePasswordConfig creates an UsernamePasswordConfig object configured to obtain an Authorizer through username and password.
+// Defaults to Public Cloud and Resource Manager Endpoint.
+func NewUsernamePasswordConfig(username string, password string, clientID string, tenantID string) UsernamePasswordConfig {
+ return UsernamePasswordConfig{
+ Username: username,
+ Password: password,
+ ClientID: clientID,
+ TenantID: tenantID,
+ Resource: azure.PublicCloud.ResourceManagerEndpoint,
+ AADEndpoint: azure.PublicCloud.ActiveDirectoryEndpoint,
+ }
+}
+
+// NewMSIConfig creates an MSIConfig object configured to obtain an Authorizer through MSI.
+func NewMSIConfig() MSIConfig {
+ return MSIConfig{
+ Resource: azure.PublicCloud.ResourceManagerEndpoint,
+ }
+}
+
+// NewDeviceFlowConfig creates a DeviceFlowConfig object configured to obtain an Authorizer through device flow.
+// Defaults to Public Cloud and Resource Manager Endpoint.
+func NewDeviceFlowConfig(clientID string, tenantID string) DeviceFlowConfig {
+ return DeviceFlowConfig{
+ ClientID: clientID,
+ TenantID: tenantID,
+ Resource: azure.PublicCloud.ResourceManagerEndpoint,
+ AADEndpoint: azure.PublicCloud.ActiveDirectoryEndpoint,
+ }
+}
+
+//AuthorizerConfig provides an authorizer from the configuration provided.
+type AuthorizerConfig interface {
+ Authorizer() (autorest.Authorizer, error)
+}
+
+// ClientCredentialsConfig provides the options to get a bearer authorizer from client credentials.
+type ClientCredentialsConfig struct {
+ ClientID string
+ ClientSecret string
+ TenantID string
+ AuxTenants []string
+ AADEndpoint string
+ Resource string
+}
+
+// ServicePrincipalToken creates a ServicePrincipalToken from client credentials.
+func (ccc ClientCredentialsConfig) ServicePrincipalToken() (*adal.ServicePrincipalToken, error) {
+ oauthConfig, err := adal.NewOAuthConfig(ccc.AADEndpoint, ccc.TenantID)
+ if err != nil {
+ return nil, err
+ }
+ return adal.NewServicePrincipalToken(*oauthConfig, ccc.ClientID, ccc.ClientSecret, ccc.Resource)
+}
+
+// MultiTenantServicePrincipalToken creates a MultiTenantServicePrincipalToken from client credentials.
+func (ccc ClientCredentialsConfig) MultiTenantServicePrincipalToken() (*adal.MultiTenantServicePrincipalToken, error) {
+ oauthConfig, err := adal.NewMultiTenantOAuthConfig(ccc.AADEndpoint, ccc.TenantID, ccc.AuxTenants, adal.OAuthOptions{})
+ if err != nil {
+ return nil, err
+ }
+ return adal.NewMultiTenantServicePrincipalToken(oauthConfig, ccc.ClientID, ccc.ClientSecret, ccc.Resource)
+}
+
+// Authorizer gets the authorizer from client credentials.
+func (ccc ClientCredentialsConfig) Authorizer() (autorest.Authorizer, error) {
+ if len(ccc.AuxTenants) == 0 {
+ spToken, err := ccc.ServicePrincipalToken()
+ if err != nil {
+ return nil, fmt.Errorf("failed to get SPT from client credentials: %v", err)
+ }
+ return autorest.NewBearerAuthorizer(spToken), nil
+ }
+ mtSPT, err := ccc.MultiTenantServicePrincipalToken()
+ if err != nil {
+ return nil, fmt.Errorf("failed to get multitenant SPT from client credentials: %v", err)
+ }
+ return autorest.NewMultiTenantServicePrincipalTokenAuthorizer(mtSPT), nil
+}
+
+// ClientCertificateConfig provides the options to get a bearer authorizer from a client certificate.
+type ClientCertificateConfig struct {
+ ClientID string
+ CertificatePath string
+ CertificatePassword string
+ TenantID string
+ AADEndpoint string
+ Resource string
+}
+
+// ServicePrincipalToken creates a ServicePrincipalToken from client certificate.
+func (ccc ClientCertificateConfig) ServicePrincipalToken() (*adal.ServicePrincipalToken, error) {
+ oauthConfig, err := adal.NewOAuthConfig(ccc.AADEndpoint, ccc.TenantID)
+ if err != nil {
+ return nil, err
+ }
+ certData, err := ioutil.ReadFile(ccc.CertificatePath)
+ if err != nil {
+ return nil, fmt.Errorf("failed to read the certificate file (%s): %v", ccc.CertificatePath, err)
+ }
+ certificate, rsaPrivateKey, err := adal.DecodePfxCertificateData(certData, ccc.CertificatePassword)
+ if err != nil {
+ return nil, fmt.Errorf("failed to decode pkcs12 certificate while creating spt: %v", err)
+ }
+ return adal.NewServicePrincipalTokenFromCertificate(*oauthConfig, ccc.ClientID, certificate, rsaPrivateKey, ccc.Resource)
+}
+
+// Authorizer gets an authorizer object from client certificate.
+func (ccc ClientCertificateConfig) Authorizer() (autorest.Authorizer, error) {
+ spToken, err := ccc.ServicePrincipalToken()
+ if err != nil {
+ return nil, fmt.Errorf("failed to get oauth token from certificate auth: %v", err)
+ }
+ return autorest.NewBearerAuthorizer(spToken), nil
+}
+
+// DeviceFlowConfig provides the options to get a bearer authorizer using device flow authentication.
+type DeviceFlowConfig struct {
+ ClientID string
+ TenantID string
+ AADEndpoint string
+ Resource string
+}
+
+// Authorizer gets the authorizer from device flow.
+func (dfc DeviceFlowConfig) Authorizer() (autorest.Authorizer, error) {
+ spToken, err := dfc.ServicePrincipalToken()
+ if err != nil {
+ return nil, fmt.Errorf("failed to get oauth token from device flow: %v", err)
+ }
+ return autorest.NewBearerAuthorizer(spToken), nil
+}
+
+// ServicePrincipalToken gets the service principal token from device flow.
+func (dfc DeviceFlowConfig) ServicePrincipalToken() (*adal.ServicePrincipalToken, error) {
+ oauthConfig, err := adal.NewOAuthConfig(dfc.AADEndpoint, dfc.TenantID)
+ if err != nil {
+ return nil, err
+ }
+ oauthClient := &autorest.Client{}
+ deviceCode, err := adal.InitiateDeviceAuth(oauthClient, *oauthConfig, dfc.ClientID, dfc.Resource)
+ if err != nil {
+ return nil, fmt.Errorf("failed to start device auth flow: %s", err)
+ }
+ log.Println(*deviceCode.Message)
+ token, err := adal.WaitForUserCompletion(oauthClient, deviceCode)
+ if err != nil {
+ return nil, fmt.Errorf("failed to finish device auth flow: %s", err)
+ }
+ return adal.NewServicePrincipalTokenFromManualToken(*oauthConfig, dfc.ClientID, dfc.Resource, *token)
+}
+
+// UsernamePasswordConfig provides the options to get a bearer authorizer from a username and a password.
+type UsernamePasswordConfig struct {
+ ClientID string
+ Username string
+ Password string
+ TenantID string
+ AADEndpoint string
+ Resource string
+}
+
+// ServicePrincipalToken creates a ServicePrincipalToken from username and password.
+func (ups UsernamePasswordConfig) ServicePrincipalToken() (*adal.ServicePrincipalToken, error) {
+ oauthConfig, err := adal.NewOAuthConfig(ups.AADEndpoint, ups.TenantID)
+ if err != nil {
+ return nil, err
+ }
+ return adal.NewServicePrincipalTokenFromUsernamePassword(*oauthConfig, ups.ClientID, ups.Username, ups.Password, ups.Resource)
+}
+
+// Authorizer gets the authorizer from a username and a password.
+func (ups UsernamePasswordConfig) Authorizer() (autorest.Authorizer, error) {
+ spToken, err := ups.ServicePrincipalToken()
+ if err != nil {
+ return nil, fmt.Errorf("failed to get oauth token from username and password auth: %v", err)
+ }
+ return autorest.NewBearerAuthorizer(spToken), nil
+}
+
+// MSIConfig provides the options to get a bearer authorizer through MSI.
+type MSIConfig struct {
+ Resource string
+ ClientID string
+}
+
+// ServicePrincipalToken creates a ServicePrincipalToken from MSI.
+func (mc MSIConfig) ServicePrincipalToken() (*adal.ServicePrincipalToken, error) {
+ msiEndpoint, err := adal.GetMSIEndpoint()
+ if err != nil {
+ return nil, err
+ }
+
+ var spToken *adal.ServicePrincipalToken
+ if mc.ClientID == "" {
+ spToken, err = adal.NewServicePrincipalTokenFromMSI(msiEndpoint, mc.Resource)
+ if err != nil {
+ return nil, fmt.Errorf("failed to get oauth token from MSI: %v", err)
+ }
+ } else {
+ spToken, err = adal.NewServicePrincipalTokenFromMSIWithUserAssignedID(msiEndpoint, mc.Resource, mc.ClientID)
+ if err != nil {
+ return nil, fmt.Errorf("failed to get oauth token from MSI for user assigned identity: %v", err)
+ }
+ }
+
+ return spToken, nil
+}
+
+// Authorizer gets the authorizer from MSI.
+func (mc MSIConfig) Authorizer() (autorest.Authorizer, error) {
+ spToken, err := mc.ServicePrincipalToken()
+ if err != nil {
+ return nil, err
+ }
+
+ return autorest.NewBearerAuthorizer(spToken), nil
+}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod
new file mode 100644
index 000000000000..c811a0635f99
--- /dev/null
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod
@@ -0,0 +1,11 @@
+module github.com/Azure/go-autorest/autorest/azure/auth
+
+go 1.12
+
+require (
+ github.com/Azure/go-autorest v14.2.0+incompatible
+ github.com/Azure/go-autorest/autorest v0.11.6
+ github.com/Azure/go-autorest/autorest/adal v0.9.4
+ github.com/Azure/go-autorest/autorest/azure/cli v0.4.1
+ github.com/dimchansky/utfbom v1.1.0
+)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum
new file mode 100644
index 000000000000..180b5390a19e
--- /dev/null
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum
@@ -0,0 +1,29 @@
+github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
+github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
+github.com/Azure/go-autorest/autorest v0.11.6 h1:LIzfhNo9I3+il0KO2JY1/lgJmjig7lY0wFulQNZkbtg=
+github.com/Azure/go-autorest/autorest v0.11.6/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
+github.com/Azure/go-autorest/autorest/adal v0.9.4 h1:1/DtH4Szusk4psLBrJn/gocMRIf1ji30WAz3GfyULRQ=
+github.com/Azure/go-autorest/autorest/adal v0.9.4/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.1 h1:jwcD1wURu0+hKceV04MubZmKLzwEYOCz6q4aOtVZ+Ng=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.1/go.mod h1:JfDgiIO1/RPu6z42AdQTyjOoCM2MFhLqSBDvMEkDgcg=
+github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
+github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
+github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
+github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
+github.com/Azure/go-autorest/logger v0.2.0 h1:e4RVHVZKC5p6UANLJHkM4OfR1UKZPj8Wt8Pcx+3oqrE=
+github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
+github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
+github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
+github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM=
+github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
+github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
+github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
+github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
+github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
+golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
+golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 h1:psW17arqaxU48Z5kZ0CQnkZWQJsqcURM6tKiBApRjXI=
+golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
+golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
+golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
diff --git a/vendor/github.com/Azure/go-autorest/autorest/to/go_mod_tidy_hack.go b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go_mod_tidy_hack.go
similarity index 83%
rename from vendor/github.com/Azure/go-autorest/autorest/to/go_mod_tidy_hack.go
rename to vendor/github.com/Azure/go-autorest/autorest/azure/auth/go_mod_tidy_hack.go
index 8e8292107071..38e4900ad0fb 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/to/go_mod_tidy_hack.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go_mod_tidy_hack.go
@@ -1,6 +1,6 @@
// +build modhack
-package to
+package auth
// Copyright 2017 Microsoft Corporation
//
@@ -16,9 +16,9 @@ package to
// See the License for the specific language governing permissions and
// limitations under the License.
-// This file, and the github.com/Azure/go-autorest/autorest import, won't actually become part of
+// This file, and the github.com/Azure/go-autorest import, won't actually become part of
// the resultant binary.
// Necessary for safely adding multi-module repo.
// See: https://github.com/golang/go/wiki/Modules#is-it-possible-to-add-a-module-to-a-multi-module-repository
-import _ "github.com/Azure/go-autorest/autorest"
+import _ "github.com/Azure/go-autorest"
diff --git a/vendor/github.com/Azure/go-autorest/autorest/validation/LICENSE b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/LICENSE
similarity index 100%
rename from vendor/github.com/Azure/go-autorest/autorest/validation/LICENSE
rename to vendor/github.com/Azure/go-autorest/autorest/azure/cli/LICENSE
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod
new file mode 100644
index 000000000000..28086dc59b21
--- /dev/null
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod
@@ -0,0 +1,11 @@
+module github.com/Azure/go-autorest/autorest/azure/cli
+
+go 1.12
+
+require (
+ github.com/Azure/go-autorest v14.2.0+incompatible
+ github.com/Azure/go-autorest/autorest/adal v0.9.4
+ github.com/Azure/go-autorest/autorest/date v0.3.0
+ github.com/dimchansky/utfbom v1.1.0
+ github.com/mitchellh/go-homedir v1.1.0
+)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum
new file mode 100644
index 000000000000..10a46ee677d9
--- /dev/null
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum
@@ -0,0 +1,24 @@
+github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
+github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
+github.com/Azure/go-autorest/autorest/adal v0.9.4 h1:1/DtH4Szusk4psLBrJn/gocMRIf1ji30WAz3GfyULRQ=
+github.com/Azure/go-autorest/autorest/adal v0.9.4/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
+github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
+github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
+github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
+github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
+github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
+github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
+github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM=
+github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
+github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
+github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
+github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
+github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
+golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
+golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 h1:psW17arqaxU48Z5kZ0CQnkZWQJsqcURM6tKiBApRjXI=
+golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
+golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
+golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU=
+golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go_mod_tidy_hack.go b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go_mod_tidy_hack.go
new file mode 100644
index 000000000000..861ce2984e64
--- /dev/null
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go_mod_tidy_hack.go
@@ -0,0 +1,24 @@
+// +build modhack
+
+package cli
+
+// Copyright 2017 Microsoft Corporation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// This file, and the github.com/Azure/go-autorest import, won't actually become part of
+// the resultant binary.
+
+// Necessary for safely adding multi-module repo.
+// See: https://github.com/golang/go/wiki/Modules#is-it-possible-to-add-a-module-to-a-multi-module-repository
+import _ "github.com/Azure/go-autorest"
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/profile.go b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/profile.go
new file mode 100644
index 000000000000..f45c3a516d9f
--- /dev/null
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/profile.go
@@ -0,0 +1,83 @@
+package cli
+
+// Copyright 2017 Microsoft Corporation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+import (
+ "bytes"
+ "encoding/json"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "path/filepath"
+
+ "github.com/dimchansky/utfbom"
+ "github.com/mitchellh/go-homedir"
+)
+
+// Profile represents a Profile from the Azure CLI
+type Profile struct {
+ InstallationID string `json:"installationId"`
+ Subscriptions []Subscription `json:"subscriptions"`
+}
+
+// Subscription represents a Subscription from the Azure CLI
+type Subscription struct {
+ EnvironmentName string `json:"environmentName"`
+ ID string `json:"id"`
+ IsDefault bool `json:"isDefault"`
+ Name string `json:"name"`
+ State string `json:"state"`
+ TenantID string `json:"tenantId"`
+ User *User `json:"user"`
+}
+
+// User represents a User from the Azure CLI
+type User struct {
+ Name string `json:"name"`
+ Type string `json:"type"`
+}
+
+const azureProfileJSON = "azureProfile.json"
+
+func configDir() string {
+ return os.Getenv("AZURE_CONFIG_DIR")
+}
+
+// ProfilePath returns the path where the Azure Profile is stored from the Azure CLI
+func ProfilePath() (string, error) {
+ if cfgDir := configDir(); cfgDir != "" {
+ return filepath.Join(cfgDir, azureProfileJSON), nil
+ }
+ return homedir.Expand("~/.azure/" + azureProfileJSON)
+}
+
+// LoadProfile restores a Profile object from a file located at 'path'.
+func LoadProfile(path string) (result Profile, err error) {
+ var contents []byte
+ contents, err = ioutil.ReadFile(path)
+ if err != nil {
+ err = fmt.Errorf("failed to open file (%s) while loading token: %v", path, err)
+ return
+ }
+ reader := utfbom.SkipOnly(bytes.NewReader(contents))
+
+ dec := json.NewDecoder(reader)
+ if err = dec.Decode(&result); err != nil {
+ err = fmt.Errorf("failed to decode contents of file (%s) into a Profile representation: %v", path, err)
+ return
+ }
+
+ return
+}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/token.go b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/token.go
new file mode 100644
index 000000000000..44ff446f6697
--- /dev/null
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/token.go
@@ -0,0 +1,175 @@
+package cli
+
+// Copyright 2017 Microsoft Corporation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+import (
+ "bytes"
+ "encoding/json"
+ "fmt"
+ "os"
+ "os/exec"
+ "path/filepath"
+ "regexp"
+ "runtime"
+ "strconv"
+ "time"
+
+ "github.com/Azure/go-autorest/autorest/adal"
+ "github.com/Azure/go-autorest/autorest/date"
+ "github.com/mitchellh/go-homedir"
+)
+
+// Token represents an AccessToken from the Azure CLI
+type Token struct {
+ AccessToken string `json:"accessToken"`
+ Authority string `json:"_authority"`
+ ClientID string `json:"_clientId"`
+ ExpiresOn string `json:"expiresOn"`
+ IdentityProvider string `json:"identityProvider"`
+ IsMRRT bool `json:"isMRRT"`
+ RefreshToken string `json:"refreshToken"`
+ Resource string `json:"resource"`
+ TokenType string `json:"tokenType"`
+ UserID string `json:"userId"`
+}
+
+const accessTokensJSON = "accessTokens.json"
+
+// ToADALToken converts an Azure CLI `Token`` to an `adal.Token``
+func (t Token) ToADALToken() (converted adal.Token, err error) {
+ tokenExpirationDate, err := ParseExpirationDate(t.ExpiresOn)
+ if err != nil {
+ err = fmt.Errorf("Error parsing Token Expiration Date %q: %+v", t.ExpiresOn, err)
+ return
+ }
+
+ difference := tokenExpirationDate.Sub(date.UnixEpoch())
+
+ converted = adal.Token{
+ AccessToken: t.AccessToken,
+ Type: t.TokenType,
+ ExpiresIn: "3600",
+ ExpiresOn: json.Number(strconv.Itoa(int(difference.Seconds()))),
+ RefreshToken: t.RefreshToken,
+ Resource: t.Resource,
+ }
+ return
+}
+
+// AccessTokensPath returns the path where access tokens are stored from the Azure CLI
+// TODO(#199): add unit test.
+func AccessTokensPath() (string, error) {
+ // Azure-CLI allows user to customize the path of access tokens through environment variable.
+ if accessTokenPath := os.Getenv("AZURE_ACCESS_TOKEN_FILE"); accessTokenPath != "" {
+ return accessTokenPath, nil
+ }
+
+ // Azure-CLI allows user to customize the path to Azure config directory through environment variable.
+ if cfgDir := configDir(); cfgDir != "" {
+ return filepath.Join(cfgDir, accessTokensJSON), nil
+ }
+
+ // Fallback logic to default path on non-cloud-shell environment.
+ // TODO(#200): remove the dependency on hard-coding path.
+ return homedir.Expand("~/.azure/" + accessTokensJSON)
+}
+
+// ParseExpirationDate parses either a Azure CLI or CloudShell date into a time object
+func ParseExpirationDate(input string) (*time.Time, error) {
+ // CloudShell (and potentially the Azure CLI in future)
+ expirationDate, cloudShellErr := time.Parse(time.RFC3339, input)
+ if cloudShellErr != nil {
+ // Azure CLI (Python) e.g. 2017-08-31 19:48:57.998857 (plus the local timezone)
+ const cliFormat = "2006-01-02 15:04:05.999999"
+ expirationDate, cliErr := time.ParseInLocation(cliFormat, input, time.Local)
+ if cliErr == nil {
+ return &expirationDate, nil
+ }
+
+ return nil, fmt.Errorf("Error parsing expiration date %q.\n\nCloudShell Error: \n%+v\n\nCLI Error:\n%+v", input, cloudShellErr, cliErr)
+ }
+
+ return &expirationDate, nil
+}
+
+// LoadTokens restores a set of Token objects from a file located at 'path'.
+func LoadTokens(path string) ([]Token, error) {
+ file, err := os.Open(path)
+ if err != nil {
+ return nil, fmt.Errorf("failed to open file (%s) while loading token: %v", path, err)
+ }
+ defer file.Close()
+
+ var tokens []Token
+
+ dec := json.NewDecoder(file)
+ if err = dec.Decode(&tokens); err != nil {
+ return nil, fmt.Errorf("failed to decode contents of file (%s) into a `cli.Token` representation: %v", path, err)
+ }
+
+ return tokens, nil
+}
+
+// GetTokenFromCLI gets a token using Azure CLI 2.0 for local development scenarios.
+func GetTokenFromCLI(resource string) (*Token, error) {
+ // This is the path that a developer can set to tell this class what the install path for Azure CLI is.
+ const azureCLIPath = "AzureCLIPath"
+
+ // The default install paths are used to find Azure CLI. This is for security, so that any path in the calling program's Path environment is not used to execute Azure CLI.
+ azureCLIDefaultPathWindows := fmt.Sprintf("%s\\Microsoft SDKs\\Azure\\CLI2\\wbin; %s\\Microsoft SDKs\\Azure\\CLI2\\wbin", os.Getenv("ProgramFiles(x86)"), os.Getenv("ProgramFiles"))
+
+ // Default path for non-Windows.
+ const azureCLIDefaultPath = "/bin:/sbin:/usr/bin:/usr/local/bin"
+
+ // Validate resource, since it gets sent as a command line argument to Azure CLI
+ const invalidResourceErrorTemplate = "Resource %s is not in expected format. Only alphanumeric characters, [dot], [colon], [hyphen], and [forward slash] are allowed."
+ match, err := regexp.MatchString("^[0-9a-zA-Z-.:/]+$", resource)
+ if err != nil {
+ return nil, err
+ }
+ if !match {
+ return nil, fmt.Errorf(invalidResourceErrorTemplate, resource)
+ }
+
+ // Execute Azure CLI to get token
+ var cliCmd *exec.Cmd
+ if runtime.GOOS == "windows" {
+ cliCmd = exec.Command(fmt.Sprintf("%s\\system32\\cmd.exe", os.Getenv("windir")))
+ cliCmd.Env = os.Environ()
+ cliCmd.Env = append(cliCmd.Env, fmt.Sprintf("PATH=%s;%s", os.Getenv(azureCLIPath), azureCLIDefaultPathWindows))
+ cliCmd.Args = append(cliCmd.Args, "/c", "az")
+ } else {
+ cliCmd = exec.Command("az")
+ cliCmd.Env = os.Environ()
+ cliCmd.Env = append(cliCmd.Env, fmt.Sprintf("PATH=%s:%s", os.Getenv(azureCLIPath), azureCLIDefaultPath))
+ }
+ cliCmd.Args = append(cliCmd.Args, "account", "get-access-token", "-o", "json", "--resource", resource)
+
+ var stderr bytes.Buffer
+ cliCmd.Stderr = &stderr
+
+ output, err := cliCmd.Output()
+ if err != nil {
+ return nil, fmt.Errorf("Invoking Azure CLI failed with the following error: %s", stderr.String())
+ }
+
+ tokenResponse := Token{}
+ err = json.Unmarshal(output, &tokenResponse)
+ if err != nil {
+ return nil, err
+ }
+
+ return &tokenResponse, err
+}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/to/convert.go b/vendor/github.com/Azure/go-autorest/autorest/to/convert.go
deleted file mode 100644
index 86694bd25554..000000000000
--- a/vendor/github.com/Azure/go-autorest/autorest/to/convert.go
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
-Package to provides helpers to ease working with pointer values of marshalled structures.
-*/
-package to
-
-// Copyright 2017 Microsoft Corporation
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-// String returns a string value for the passed string pointer. It returns the empty string if the
-// pointer is nil.
-func String(s *string) string {
- if s != nil {
- return *s
- }
- return ""
-}
-
-// StringPtr returns a pointer to the passed string.
-func StringPtr(s string) *string {
- return &s
-}
-
-// StringSlice returns a string slice value for the passed string slice pointer. It returns a nil
-// slice if the pointer is nil.
-func StringSlice(s *[]string) []string {
- if s != nil {
- return *s
- }
- return nil
-}
-
-// StringSlicePtr returns a pointer to the passed string slice.
-func StringSlicePtr(s []string) *[]string {
- return &s
-}
-
-// StringMap returns a map of strings built from the map of string pointers. The empty string is
-// used for nil pointers.
-func StringMap(msp map[string]*string) map[string]string {
- ms := make(map[string]string, len(msp))
- for k, sp := range msp {
- if sp != nil {
- ms[k] = *sp
- } else {
- ms[k] = ""
- }
- }
- return ms
-}
-
-// StringMapPtr returns a pointer to a map of string pointers built from the passed map of strings.
-func StringMapPtr(ms map[string]string) *map[string]*string {
- msp := make(map[string]*string, len(ms))
- for k, s := range ms {
- msp[k] = StringPtr(s)
- }
- return &msp
-}
-
-// Bool returns a bool value for the passed bool pointer. It returns false if the pointer is nil.
-func Bool(b *bool) bool {
- if b != nil {
- return *b
- }
- return false
-}
-
-// BoolPtr returns a pointer to the passed bool.
-func BoolPtr(b bool) *bool {
- return &b
-}
-
-// Int returns an int value for the passed int pointer. It returns 0 if the pointer is nil.
-func Int(i *int) int {
- if i != nil {
- return *i
- }
- return 0
-}
-
-// IntPtr returns a pointer to the passed int.
-func IntPtr(i int) *int {
- return &i
-}
-
-// Int32 returns an int value for the passed int pointer. It returns 0 if the pointer is nil.
-func Int32(i *int32) int32 {
- if i != nil {
- return *i
- }
- return 0
-}
-
-// Int32Ptr returns a pointer to the passed int32.
-func Int32Ptr(i int32) *int32 {
- return &i
-}
-
-// Int64 returns an int value for the passed int pointer. It returns 0 if the pointer is nil.
-func Int64(i *int64) int64 {
- if i != nil {
- return *i
- }
- return 0
-}
-
-// Int64Ptr returns a pointer to the passed int64.
-func Int64Ptr(i int64) *int64 {
- return &i
-}
-
-// Float32 returns an int value for the passed int pointer. It returns 0.0 if the pointer is nil.
-func Float32(i *float32) float32 {
- if i != nil {
- return *i
- }
- return 0.0
-}
-
-// Float32Ptr returns a pointer to the passed float32.
-func Float32Ptr(i float32) *float32 {
- return &i
-}
-
-// Float64 returns an int value for the passed int pointer. It returns 0.0 if the pointer is nil.
-func Float64(i *float64) float64 {
- if i != nil {
- return *i
- }
- return 0.0
-}
-
-// Float64Ptr returns a pointer to the passed float64.
-func Float64Ptr(i float64) *float64 {
- return &i
-}
-
-// ByteSlicePtr returns a pointer to the passed byte slice.
-func ByteSlicePtr(b []byte) *[]byte {
- return &b
-}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/to/go.mod b/vendor/github.com/Azure/go-autorest/autorest/to/go.mod
deleted file mode 100644
index 48fd8c6e57b4..000000000000
--- a/vendor/github.com/Azure/go-autorest/autorest/to/go.mod
+++ /dev/null
@@ -1,5 +0,0 @@
-module github.com/Azure/go-autorest/autorest/to
-
-go 1.12
-
-require github.com/Azure/go-autorest/autorest v0.9.0
diff --git a/vendor/github.com/Azure/go-autorest/autorest/to/go.sum b/vendor/github.com/Azure/go-autorest/autorest/to/go.sum
deleted file mode 100644
index d7ee6b462311..000000000000
--- a/vendor/github.com/Azure/go-autorest/autorest/to/go.sum
+++ /dev/null
@@ -1,17 +0,0 @@
-github.com/Azure/go-autorest/autorest v0.9.0 h1:MRvx8gncNaXJqOoLmhNjUAKh33JJF8LyxPhomEtOsjs=
-github.com/Azure/go-autorest/autorest v0.9.0/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+BFDTQ8rEZB0s4Yfa6bI=
-github.com/Azure/go-autorest/autorest/adal v0.5.0 h1:q2gDruN08/guU9vAjuPWff0+QIrpH6ediguzdAzXAUU=
-github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEgQTmVqjGhiHBW7RJJEciWzS0=
-github.com/Azure/go-autorest/autorest/date v0.1.0 h1:YGrhWfrgtFs84+h0o46rJrlmsZtyZRg470CqAXTZaGM=
-github.com/Azure/go-autorest/autorest/date v0.1.0/go.mod h1:plvfp3oPSKwf2DNjlBjWF/7vwR+cUD/ELuzDCXwHUVA=
-github.com/Azure/go-autorest/autorest/mocks v0.1.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0=
-github.com/Azure/go-autorest/autorest/mocks v0.2.0 h1:Ww5g4zThfD/6cLb4z6xxgeyDa7QDkizMkJKe0ysZXp0=
-github.com/Azure/go-autorest/autorest/mocks v0.2.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0=
-github.com/Azure/go-autorest/logger v0.1.0 h1:ruG4BSDXONFRrZZJ2GUXDiUyVpayPmb1GnWeHDdaNKY=
-github.com/Azure/go-autorest/logger v0.1.0/go.mod h1:oExouG+K6PryycPJfVSxi/koC6LSNgds39diKLz7Vrc=
-github.com/Azure/go-autorest/tracing v0.5.0 h1:TRn4WjSnkcSy5AEG3pnbtFSwNtwzjr4VYyQflFE619k=
-github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbtp2fGCgRFtBroKn4Dk=
-github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM=
-github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
-golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
diff --git a/vendor/github.com/Azure/go-autorest/autorest/validation/error.go b/vendor/github.com/Azure/go-autorest/autorest/validation/error.go
deleted file mode 100644
index fed156dbf6e6..000000000000
--- a/vendor/github.com/Azure/go-autorest/autorest/validation/error.go
+++ /dev/null
@@ -1,48 +0,0 @@
-package validation
-
-// Copyright 2017 Microsoft Corporation
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-import (
- "fmt"
-)
-
-// Error is the type that's returned when the validation of an APIs arguments constraints fails.
-type Error struct {
- // PackageType is the package type of the object emitting the error. For types, the value
- // matches that produced the the '%T' format specifier of the fmt package. For other elements,
- // such as functions, it is just the package name (e.g., "autorest").
- PackageType string
-
- // Method is the name of the method raising the error.
- Method string
-
- // Message is the error message.
- Message string
-}
-
-// Error returns a string containing the details of the validation failure.
-func (e Error) Error() string {
- return fmt.Sprintf("%s#%s: Invalid input: %s", e.PackageType, e.Method, e.Message)
-}
-
-// NewError creates a new Error object with the specified parameters.
-// message is treated as a format string to which the optional args apply.
-func NewError(packageType string, method string, message string, args ...interface{}) Error {
- return Error{
- PackageType: packageType,
- Method: method,
- Message: fmt.Sprintf(message, args...),
- }
-}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/validation/go.mod b/vendor/github.com/Azure/go-autorest/autorest/validation/go.mod
deleted file mode 100644
index c44c51ff60c2..000000000000
--- a/vendor/github.com/Azure/go-autorest/autorest/validation/go.mod
+++ /dev/null
@@ -1,5 +0,0 @@
-module github.com/Azure/go-autorest/autorest/validation
-
-go 1.12
-
-require github.com/stretchr/testify v1.3.0
diff --git a/vendor/github.com/Azure/go-autorest/autorest/validation/go.sum b/vendor/github.com/Azure/go-autorest/autorest/validation/go.sum
deleted file mode 100644
index 4347755afe82..000000000000
--- a/vendor/github.com/Azure/go-autorest/autorest/validation/go.sum
+++ /dev/null
@@ -1,7 +0,0 @@
-github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8=
-github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
-github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
-github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
-github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
-github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
-github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
diff --git a/vendor/github.com/Azure/go-autorest/autorest/validation/validation.go b/vendor/github.com/Azure/go-autorest/autorest/validation/validation.go
deleted file mode 100644
index 65899b69b8c8..000000000000
--- a/vendor/github.com/Azure/go-autorest/autorest/validation/validation.go
+++ /dev/null
@@ -1,400 +0,0 @@
-/*
-Package validation provides methods for validating parameter value using reflection.
-*/
-package validation
-
-// Copyright 2017 Microsoft Corporation
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-import (
- "fmt"
- "reflect"
- "regexp"
- "strings"
-)
-
-// Constraint stores constraint name, target field name
-// Rule and chain validations.
-type Constraint struct {
-
- // Target field name for validation.
- Target string
-
- // Constraint name e.g. minLength, MaxLength, Pattern, etc.
- Name string
-
- // Rule for constraint e.g. greater than 10, less than 5 etc.
- Rule interface{}
-
- // Chain Validations for struct type
- Chain []Constraint
-}
-
-// Validation stores parameter-wise validation.
-type Validation struct {
- TargetValue interface{}
- Constraints []Constraint
-}
-
-// Constraint list
-const (
- Empty = "Empty"
- Null = "Null"
- ReadOnly = "ReadOnly"
- Pattern = "Pattern"
- MaxLength = "MaxLength"
- MinLength = "MinLength"
- MaxItems = "MaxItems"
- MinItems = "MinItems"
- MultipleOf = "MultipleOf"
- UniqueItems = "UniqueItems"
- InclusiveMaximum = "InclusiveMaximum"
- ExclusiveMaximum = "ExclusiveMaximum"
- ExclusiveMinimum = "ExclusiveMinimum"
- InclusiveMinimum = "InclusiveMinimum"
-)
-
-// Validate method validates constraints on parameter
-// passed in validation array.
-func Validate(m []Validation) error {
- for _, item := range m {
- v := reflect.ValueOf(item.TargetValue)
- for _, constraint := range item.Constraints {
- var err error
- switch v.Kind() {
- case reflect.Ptr:
- err = validatePtr(v, constraint)
- case reflect.String:
- err = validateString(v, constraint)
- case reflect.Struct:
- err = validateStruct(v, constraint)
- case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64:
- err = validateInt(v, constraint)
- case reflect.Float32, reflect.Float64:
- err = validateFloat(v, constraint)
- case reflect.Array, reflect.Slice, reflect.Map:
- err = validateArrayMap(v, constraint)
- default:
- err = createError(v, constraint, fmt.Sprintf("unknown type %v", v.Kind()))
- }
-
- if err != nil {
- return err
- }
- }
- }
- return nil
-}
-
-func validateStruct(x reflect.Value, v Constraint, name ...string) error {
- //Get field name from target name which is in format a.b.c
- s := strings.Split(v.Target, ".")
- f := x.FieldByName(s[len(s)-1])
- if isZero(f) {
- return createError(x, v, fmt.Sprintf("field %q doesn't exist", v.Target))
- }
-
- return Validate([]Validation{
- {
- TargetValue: getInterfaceValue(f),
- Constraints: []Constraint{v},
- },
- })
-}
-
-func validatePtr(x reflect.Value, v Constraint) error {
- if v.Name == ReadOnly {
- if !x.IsNil() {
- return createError(x.Elem(), v, "readonly parameter; must send as nil or empty in request")
- }
- return nil
- }
- if x.IsNil() {
- return checkNil(x, v)
- }
- if v.Chain != nil {
- return Validate([]Validation{
- {
- TargetValue: getInterfaceValue(x.Elem()),
- Constraints: v.Chain,
- },
- })
- }
- return nil
-}
-
-func validateInt(x reflect.Value, v Constraint) error {
- i := x.Int()
- r, ok := toInt64(v.Rule)
- if !ok {
- return createError(x, v, fmt.Sprintf("rule must be integer value for %v constraint; got: %v", v.Name, v.Rule))
- }
- switch v.Name {
- case MultipleOf:
- if i%r != 0 {
- return createError(x, v, fmt.Sprintf("value must be a multiple of %v", r))
- }
- case ExclusiveMinimum:
- if i <= r {
- return createError(x, v, fmt.Sprintf("value must be greater than %v", r))
- }
- case ExclusiveMaximum:
- if i >= r {
- return createError(x, v, fmt.Sprintf("value must be less than %v", r))
- }
- case InclusiveMinimum:
- if i < r {
- return createError(x, v, fmt.Sprintf("value must be greater than or equal to %v", r))
- }
- case InclusiveMaximum:
- if i > r {
- return createError(x, v, fmt.Sprintf("value must be less than or equal to %v", r))
- }
- default:
- return createError(x, v, fmt.Sprintf("constraint %v is not applicable for type integer", v.Name))
- }
- return nil
-}
-
-func validateFloat(x reflect.Value, v Constraint) error {
- f := x.Float()
- r, ok := v.Rule.(float64)
- if !ok {
- return createError(x, v, fmt.Sprintf("rule must be float value for %v constraint; got: %v", v.Name, v.Rule))
- }
- switch v.Name {
- case ExclusiveMinimum:
- if f <= r {
- return createError(x, v, fmt.Sprintf("value must be greater than %v", r))
- }
- case ExclusiveMaximum:
- if f >= r {
- return createError(x, v, fmt.Sprintf("value must be less than %v", r))
- }
- case InclusiveMinimum:
- if f < r {
- return createError(x, v, fmt.Sprintf("value must be greater than or equal to %v", r))
- }
- case InclusiveMaximum:
- if f > r {
- return createError(x, v, fmt.Sprintf("value must be less than or equal to %v", r))
- }
- default:
- return createError(x, v, fmt.Sprintf("constraint %s is not applicable for type float", v.Name))
- }
- return nil
-}
-
-func validateString(x reflect.Value, v Constraint) error {
- s := x.String()
- switch v.Name {
- case Empty:
- if len(s) == 0 {
- return checkEmpty(x, v)
- }
- case Pattern:
- reg, err := regexp.Compile(v.Rule.(string))
- if err != nil {
- return createError(x, v, err.Error())
- }
- if !reg.MatchString(s) {
- return createError(x, v, fmt.Sprintf("value doesn't match pattern %v", v.Rule))
- }
- case MaxLength:
- if _, ok := v.Rule.(int); !ok {
- return createError(x, v, fmt.Sprintf("rule must be integer value for %v constraint; got: %v", v.Name, v.Rule))
- }
- if len(s) > v.Rule.(int) {
- return createError(x, v, fmt.Sprintf("value length must be less than or equal to %v", v.Rule))
- }
- case MinLength:
- if _, ok := v.Rule.(int); !ok {
- return createError(x, v, fmt.Sprintf("rule must be integer value for %v constraint; got: %v", v.Name, v.Rule))
- }
- if len(s) < v.Rule.(int) {
- return createError(x, v, fmt.Sprintf("value length must be greater than or equal to %v", v.Rule))
- }
- case ReadOnly:
- if len(s) > 0 {
- return createError(reflect.ValueOf(s), v, "readonly parameter; must send as nil or empty in request")
- }
- default:
- return createError(x, v, fmt.Sprintf("constraint %s is not applicable to string type", v.Name))
- }
-
- if v.Chain != nil {
- return Validate([]Validation{
- {
- TargetValue: getInterfaceValue(x),
- Constraints: v.Chain,
- },
- })
- }
- return nil
-}
-
-func validateArrayMap(x reflect.Value, v Constraint) error {
- switch v.Name {
- case Null:
- if x.IsNil() {
- return checkNil(x, v)
- }
- case Empty:
- if x.IsNil() || x.Len() == 0 {
- return checkEmpty(x, v)
- }
- case MaxItems:
- if _, ok := v.Rule.(int); !ok {
- return createError(x, v, fmt.Sprintf("rule must be integer for %v constraint; got: %v", v.Name, v.Rule))
- }
- if x.Len() > v.Rule.(int) {
- return createError(x, v, fmt.Sprintf("maximum item limit is %v; got: %v", v.Rule, x.Len()))
- }
- case MinItems:
- if _, ok := v.Rule.(int); !ok {
- return createError(x, v, fmt.Sprintf("rule must be integer for %v constraint; got: %v", v.Name, v.Rule))
- }
- if x.Len() < v.Rule.(int) {
- return createError(x, v, fmt.Sprintf("minimum item limit is %v; got: %v", v.Rule, x.Len()))
- }
- case UniqueItems:
- if x.Kind() == reflect.Array || x.Kind() == reflect.Slice {
- if !checkForUniqueInArray(x) {
- return createError(x, v, fmt.Sprintf("all items in parameter %q must be unique; got:%v", v.Target, x))
- }
- } else if x.Kind() == reflect.Map {
- if !checkForUniqueInMap(x) {
- return createError(x, v, fmt.Sprintf("all items in parameter %q must be unique; got:%v", v.Target, x))
- }
- } else {
- return createError(x, v, fmt.Sprintf("type must be array, slice or map for constraint %v; got: %v", v.Name, x.Kind()))
- }
- case ReadOnly:
- if x.Len() != 0 {
- return createError(x, v, "readonly parameter; must send as nil or empty in request")
- }
- case Pattern:
- reg, err := regexp.Compile(v.Rule.(string))
- if err != nil {
- return createError(x, v, err.Error())
- }
- keys := x.MapKeys()
- for _, k := range keys {
- if !reg.MatchString(k.String()) {
- return createError(k, v, fmt.Sprintf("map key doesn't match pattern %v", v.Rule))
- }
- }
- default:
- return createError(x, v, fmt.Sprintf("constraint %v is not applicable to array, slice and map type", v.Name))
- }
-
- if v.Chain != nil {
- return Validate([]Validation{
- {
- TargetValue: getInterfaceValue(x),
- Constraints: v.Chain,
- },
- })
- }
- return nil
-}
-
-func checkNil(x reflect.Value, v Constraint) error {
- if _, ok := v.Rule.(bool); !ok {
- return createError(x, v, fmt.Sprintf("rule must be bool value for %v constraint; got: %v", v.Name, v.Rule))
- }
- if v.Rule.(bool) {
- return createError(x, v, "value can not be null; required parameter")
- }
- return nil
-}
-
-func checkEmpty(x reflect.Value, v Constraint) error {
- if _, ok := v.Rule.(bool); !ok {
- return createError(x, v, fmt.Sprintf("rule must be bool value for %v constraint; got: %v", v.Name, v.Rule))
- }
-
- if v.Rule.(bool) {
- return createError(x, v, "value can not be null or empty; required parameter")
- }
- return nil
-}
-
-func checkForUniqueInArray(x reflect.Value) bool {
- if x == reflect.Zero(reflect.TypeOf(x)) || x.Len() == 0 {
- return false
- }
- arrOfInterface := make([]interface{}, x.Len())
-
- for i := 0; i < x.Len(); i++ {
- arrOfInterface[i] = x.Index(i).Interface()
- }
-
- m := make(map[interface{}]bool)
- for _, val := range arrOfInterface {
- if m[val] {
- return false
- }
- m[val] = true
- }
- return true
-}
-
-func checkForUniqueInMap(x reflect.Value) bool {
- if x == reflect.Zero(reflect.TypeOf(x)) || x.Len() == 0 {
- return false
- }
- mapOfInterface := make(map[interface{}]interface{}, x.Len())
-
- keys := x.MapKeys()
- for _, k := range keys {
- mapOfInterface[k.Interface()] = x.MapIndex(k).Interface()
- }
-
- m := make(map[interface{}]bool)
- for _, val := range mapOfInterface {
- if m[val] {
- return false
- }
- m[val] = true
- }
- return true
-}
-
-func getInterfaceValue(x reflect.Value) interface{} {
- if x.Kind() == reflect.Invalid {
- return nil
- }
- return x.Interface()
-}
-
-func isZero(x interface{}) bool {
- return x == reflect.Zero(reflect.TypeOf(x)).Interface()
-}
-
-func createError(x reflect.Value, v Constraint, err string) error {
- return fmt.Errorf("autorest/validation: validation failed: parameter=%s constraint=%s value=%#v details: %s",
- v.Target, v.Name, getInterfaceValue(x), err)
-}
-
-func toInt64(v interface{}) (int64, bool) {
- if i64, ok := v.(int64); ok {
- return i64, true
- }
- // older generators emit max constants as int, so if int64 fails fall back to int
- if i32, ok := v.(int); ok {
- return int64(i32), true
- }
- return 0, false
-}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/.gitignore b/vendor/github.com/aws/aws-sdk-go-v2/.gitignore
new file mode 100644
index 000000000000..18719daa8a76
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/.gitignore
@@ -0,0 +1,11 @@
+dist
+/doc
+/doc-staging
+.yardoc
+Gemfile.lock
+/internal/awstesting/integration/smoke/**/importmarker__.go
+/internal/awstesting/integration/smoke/_test/
+/vendor
+/private/model/cli/gen-api/gen-api
+.gradle/
+build/
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/.golangci.toml b/vendor/github.com/aws/aws-sdk-go-v2/.golangci.toml
new file mode 100644
index 000000000000..75e338858d46
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/.golangci.toml
@@ -0,0 +1,27 @@
+[run]
+concurrency = 4
+timeout = "1m"
+issues-exit-code = 0
+modules-download-mode = "readonly"
+allow-parallel-runners = true
+skip-dirs = ["internal/repotools"]
+skip-dirs-use-default = true
+
+[output]
+format = "github-actions"
+
+[linters-settings.cyclop]
+skip-tests = false
+
+[linters-settings.errcheck]
+check-blank = true
+
+[linters]
+disable-all = true
+enable = ["errcheck"]
+fast = false
+
+[issues]
+exclude-use-default = false
+
+# Refer config definitions at https://golangci-lint.run/usage/configuration/#config-file
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/.travis.yml b/vendor/github.com/aws/aws-sdk-go-v2/.travis.yml
new file mode 100644
index 000000000000..4b498a7a2bb7
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/.travis.yml
@@ -0,0 +1,31 @@
+language: go
+sudo: true
+dist: bionic
+
+branches:
+ only:
+ - main
+
+os:
+ - linux
+ - osx
+ # Travis doesn't work with windows and Go tip
+ #- windows
+
+go:
+ - tip
+
+matrix:
+ allow_failures:
+ - go: tip
+
+before_install:
+ - if [ "$TRAVIS_OS_NAME" = "windows" ]; then choco install make; fi
+ - (cd /tmp/; go get golang.org/x/lint/golint)
+
+env:
+ - EACHMODULE_CONCURRENCY=4
+
+script:
+ - make ci-test-no-generate;
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/CHANGELOG.md
new file mode 100644
index 000000000000..6c2e72f21625
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/CHANGELOG.md
@@ -0,0 +1,2961 @@
+# Release (2022-01-07)
+
+## General Highlights
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/config`: [v1.12.0](config/CHANGELOG.md#v1120-2022-01-07)
+ * **Feature**: Add load option for CredentialCache. Adds a new member to the LoadOptions struct, CredentialsCacheOptions. This member allows specifying a function that will be used to configure the CredentialsCache. The CredentialsCacheOptions will only be used if the configuration loader will wrap the underlying credential provider in the CredentialsCache.
+* `github.com/aws/aws-sdk-go-v2/service/appstream`: [v1.12.0](service/appstream/CHANGELOG.md#v1120-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudtrail`: [v1.12.0](service/cloudtrail/CHANGELOG.md#v1120-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/detective`: [v1.12.0](service/detective/CHANGELOG.md#v1120-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.27.0](service/ec2/CHANGELOG.md#v1270-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.15.0](service/ecs/CHANGELOG.md#v1150-2022-01-07)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.17.0](service/eks/CHANGELOG.md#v1170-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.18.0](service/glue/CHANGELOG.md#v1180-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/greengrassv2`: [v1.11.0](service/greengrassv2/CHANGELOG.md#v1110-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.20.0](service/iot/CHANGELOG.md#v1200-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lakeformation`: [v1.12.0](service/lakeformation/CHANGELOG.md#v1120-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.16.0](service/lambda/CHANGELOG.md#v1160-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.17.0](service/mediaconvert/CHANGELOG.md#v1170-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.17.0](service/quicksight/CHANGELOG.md#v1170-2022-01-07)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.15.0](service/rds/CHANGELOG.md#v1150-2022-01-07)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rekognition`: [v1.14.0](service/rekognition/CHANGELOG.md#v1140-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.23.0](service/s3/CHANGELOG.md#v1230-2022-01-07)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.17.0](service/s3control/CHANGELOG.md#v1170-2022-01-07)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3outposts`: [v1.9.0](service/s3outposts/CHANGELOG.md#v190-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.22.0](service/sagemaker/CHANGELOG.md#v1220-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/secretsmanager`: [v1.12.0](service/secretsmanager/CHANGELOG.md#v1120-2022-01-07)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssooidc`: [v1.9.0](service/ssooidc/CHANGELOG.md#v190-2022-01-07)
+ * **Feature**: API client updated
+
+# Release (2021-12-21)
+
+## General Highlights
+* **Feature**: API Paginators now support specifying the initial starting token, and support stopping on empty string tokens.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/accessanalyzer`: [v1.11.0](service/accessanalyzer/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/acm`: [v1.10.0](service/acm/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/apigateway`: [v1.11.0](service/apigateway/CHANGELOG.md#v1110-2021-12-21)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/applicationautoscaling`: [v1.11.0](service/applicationautoscaling/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/appsync`: [v1.10.0](service/appsync/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.17.0](service/autoscaling/CHANGELOG.md#v1170-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmeetings`: [v1.3.0](service/chimesdkmeetings/CHANGELOG.md#v130-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmessaging`: [v1.5.0](service/chimesdkmessaging/CHANGELOG.md#v150-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudcontrol`: [v1.4.0](service/cloudcontrol/CHANGELOG.md#v140-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.16.0](service/cloudformation/CHANGELOG.md#v1160-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatch`: [v1.13.0](service/cloudwatch/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatchevents`: [v1.10.0](service/cloudwatchevents/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatchlogs`: [v1.11.0](service/cloudwatchlogs/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: API client updated
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/codedeploy`: [v1.10.0](service/codedeploy/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/comprehendmedical`: [v1.9.0](service/comprehendmedical/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/configservice`: [v1.13.0](service/configservice/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/customerprofiles`: [v1.13.0](service/customerprofiles/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/databasemigrationservice`: [v1.14.0](service/databasemigrationservice/CHANGELOG.md#v1140-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/datasync`: [v1.10.0](service/datasync/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/devopsguru`: [v1.12.0](service/devopsguru/CHANGELOG.md#v1120-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/directconnect`: [v1.13.0](service/directconnect/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/docdb`: [v1.13.0](service/docdb/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/dynamodb`: [v1.11.0](service/dynamodb/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/dynamodbstreams`: [v1.9.0](service/dynamodbstreams/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.26.0](service/ec2/CHANGELOG.md#v1260-2021-12-21)
+ * **Feature**: API client updated
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/ecr`: [v1.12.0](service/ecr/CHANGELOG.md#v1120-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.14.0](service/ecs/CHANGELOG.md#v1140-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.16.0](service/elasticache/CHANGELOG.md#v1160-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancing`: [v1.10.0](service/elasticloadbalancing/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2`: [v1.14.0](service/elasticloadbalancingv2/CHANGELOG.md#v1140-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/elasticsearchservice`: [v1.11.0](service/elasticsearchservice/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/emr`: [v1.13.0](service/emr/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/eventbridge`: [v1.11.0](service/eventbridge/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/finspacedata`: [v1.6.0](service/finspacedata/CHANGELOG.md#v160-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/forecast`: [v1.15.0](service/forecast/CHANGELOG.md#v1150-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/glacier`: [v1.9.0](service/glacier/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/groundstation`: [v1.9.0](service/groundstation/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/health`: [v1.11.0](service/health/CHANGELOG.md#v1110-2021-12-21)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/imagebuilder`: [v1.15.0](service/imagebuilder/CHANGELOG.md#v1150-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.19.0](service/iot/CHANGELOG.md#v1190-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kinesis`: [v1.11.0](service/kinesis/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/kinesisanalytics`: [v1.9.0](service/kinesisanalytics/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/kinesisanalyticsv2`: [v1.10.0](service/kinesisanalyticsv2/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/kms`: [v1.12.0](service/kms/CHANGELOG.md#v1120-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.15.0](service/lambda/CHANGELOG.md#v1150-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.15.0](service/lexmodelsv2/CHANGELOG.md#v1150-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/location`: [v1.10.0](service/location/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lookoutmetrics`: [v1.6.0](service/lookoutmetrics/CHANGELOG.md#v160-2021-12-21)
+ * **Feature**: API client updated
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/lookoutvision`: [v1.8.0](service/lookoutvision/CHANGELOG.md#v180-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/marketplacemetering`: [v1.9.0](service/marketplacemetering/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/mediaconnect`: [v1.11.0](service/mediaconnect/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/neptune`: [v1.12.0](service/neptune/CHANGELOG.md#v1120-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/networkfirewall`: [v1.11.0](service/networkfirewall/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/nimble`: [v1.8.0](service/nimble/CHANGELOG.md#v180-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/opensearch`: [v1.5.0](service/opensearch/CHANGELOG.md#v150-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/outposts`: [v1.13.0](service/outposts/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/pi`: [v1.10.0](service/pi/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/qldb`: [v1.10.0](service/qldb/CHANGELOG.md#v1100-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.14.0](service/rds/CHANGELOG.md#v1140-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/redshift`: [v1.17.0](service/redshift/CHANGELOG.md#v1170-2021-12-21)
+ * **Feature**: API client updated
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/resourcegroups`: [v1.8.0](service/resourcegroups/CHANGELOG.md#v180-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/resourcegroupstaggingapi`: [v1.9.0](service/resourcegroupstaggingapi/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/route53`: [v1.15.0](service/route53/CHANGELOG.md#v1150-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/route53domains`: [v1.8.0](service/route53domains/CHANGELOG.md#v180-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/route53recoverycontrolconfig`: [v1.5.0](service/route53recoverycontrolconfig/CHANGELOG.md#v150-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.22.0](service/s3/CHANGELOG.md#v1220-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.16.0](service/s3control/CHANGELOG.md#v1160-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.21.0](service/sagemaker/CHANGELOG.md#v1210-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/savingsplans`: [v1.7.3](service/savingsplans/CHANGELOG.md#v173-2021-12-21)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/secretsmanager`: [v1.11.0](service/secretsmanager/CHANGELOG.md#v1110-2021-12-21)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/securityhub`: [v1.14.0](service/securityhub/CHANGELOG.md#v1140-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sfn`: [v1.9.0](service/sfn/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/sms`: [v1.8.0](service/sms/CHANGELOG.md#v180-2021-12-21)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sns`: [v1.13.0](service/sns/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/sqs`: [v1.14.0](service/sqs/CHANGELOG.md#v1140-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.18.0](service/ssm/CHANGELOG.md#v1180-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/sts`: [v1.12.0](service/sts/CHANGELOG.md#v1120-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/support`: [v1.9.0](service/support/CHANGELOG.md#v190-2021-12-21)
+ * **Documentation**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/swf`: [v1.9.0](service/swf/CHANGELOG.md#v190-2021-12-21)
+ * **Feature**: Updated to latest service endpoints
+* `github.com/aws/aws-sdk-go-v2/service/transfer`: [v1.13.0](service/transfer/CHANGELOG.md#v1130-2021-12-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/workmail`: [v1.11.0](service/workmail/CHANGELOG.md#v1110-2021-12-21)
+ * **Feature**: API client updated
+
+# Release (2021-12-03)
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/accessanalyzer`: [v1.10.1](service/accessanalyzer/CHANGELOG.md#v1101-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/amp`: [v1.9.3](service/amp/CHANGELOG.md#v193-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/amplifyuibuilder`: [v1.0.0](service/amplifyuibuilder/CHANGELOG.md#v100-2021-12-03)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/appmesh`: [v1.8.3](service/appmesh/CHANGELOG.md#v183-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/braket`: [v1.10.2](service/braket/CHANGELOG.md#v1102-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/codeguruprofiler`: [v1.7.3](service/codeguruprofiler/CHANGELOG.md#v173-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/evidently`: [v1.1.1](service/evidently/CHANGELOG.md#v111-2021-12-03)
+ * **Bug Fix**: Fixed a bug that prevented the resolution of the correct endpoint for some API operations.
+* `github.com/aws/aws-sdk-go-v2/service/grafana`: [v1.2.3](service/grafana/CHANGELOG.md#v123-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/location`: [v1.9.2](service/location/CHANGELOG.md#v192-2021-12-03)
+ * **Bug Fix**: Fixed a bug that prevented the resolution of the correct endpoint for some API operations.
+ * **Bug Fix**: Fixed an issue that caused some operations to not be signed using sigv4, resulting in authentication failures.
+* `github.com/aws/aws-sdk-go-v2/service/networkmanager`: [v1.7.0](service/networkmanager/CHANGELOG.md#v170-2021-12-03)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/nimble`: [v1.7.3](service/nimble/CHANGELOG.md#v173-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/proton`: [v1.7.2](service/proton/CHANGELOG.md#v172-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/ram`: [v1.10.0](service/ram/CHANGELOG.md#v1100-2021-12-03)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rekognition`: [v1.12.0](service/rekognition/CHANGELOG.md#v1120-2021-12-03)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/snowdevicemanagement`: [v1.3.3](service/snowdevicemanagement/CHANGELOG.md#v133-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+* `github.com/aws/aws-sdk-go-v2/service/wisdom`: [v1.2.3](service/wisdom/CHANGELOG.md#v123-2021-12-03)
+ * **Bug Fix**: Fixed an issue that prevent auto-filling of an API's idempotency parameters when not explictly provided by the caller.
+
+# Release (2021-12-02)
+
+## General Highlights
+* **Bug Fix**: Fixes a bug that prevented aws.EndpointResolverWithOptions from being used by the service client. ([#1514](https://github.com/aws/aws-sdk-go-v2/pull/1514))
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/config`: [v1.11.0](config/CHANGELOG.md#v1110-2021-12-02)
+ * **Feature**: Add support for specifying `EndpointResolverWithOptions` on `LoadOptions`, and associated `WithEndpointResolverWithOptions`.
+* `github.com/aws/aws-sdk-go-v2/service/accessanalyzer`: [v1.10.0](service/accessanalyzer/CHANGELOG.md#v1100-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/applicationinsights`: [v1.9.0](service/applicationinsights/CHANGELOG.md#v190-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/backupgateway`: [v1.0.0](service/backupgateway/CHANGELOG.md#v100-2021-12-02)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/cloudhsm`: [v1.8.0](service/cloudhsm/CHANGELOG.md#v180-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/devopsguru`: [v1.11.0](service/devopsguru/CHANGELOG.md#v1110-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/directconnect`: [v1.12.0](service/directconnect/CHANGELOG.md#v1120-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/dynamodb`: [v1.10.0](service/dynamodb/CHANGELOG.md#v1100-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.25.0](service/ec2/CHANGELOG.md#v1250-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/evidently`: [v1.1.0](service/evidently/CHANGELOG.md#v110-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/fsx`: [v1.14.0](service/fsx/CHANGELOG.md#v1140-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.16.0](service/glue/CHANGELOG.md#v1160-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/inspector2`: [v1.1.0](service/inspector2/CHANGELOG.md#v110-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.18.0](service/iot/CHANGELOG.md#v1180-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iottwinmaker`: [v1.0.0](service/iottwinmaker/CHANGELOG.md#v100-2021-12-02)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/kafka`: [v1.11.0](service/kafka/CHANGELOG.md#v1110-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.17.0](service/kendra/CHANGELOG.md#v1170-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kinesis`: [v1.10.0](service/kinesis/CHANGELOG.md#v1100-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lakeformation`: [v1.10.0](service/lakeformation/CHANGELOG.md#v1100-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.14.0](service/lexmodelsv2/CHANGELOG.md#v1140-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexruntimev2`: [v1.10.0](service/lexruntimev2/CHANGELOG.md#v1100-2021-12-02)
+ * **Feature**: Support has been added for the `StartConversation` API.
+* `github.com/aws/aws-sdk-go-v2/service/outposts`: [v1.12.0](service/outposts/CHANGELOG.md#v1120-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rbin`: [v1.1.0](service/rbin/CHANGELOG.md#v110-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/redshiftdata`: [v1.10.0](service/redshiftdata/CHANGELOG.md#v1100-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rum`: [v1.1.0](service/rum/CHANGELOG.md#v110-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.21.0](service/s3/CHANGELOG.md#v1210-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.20.0](service/sagemaker/CHANGELOG.md#v1200-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemakerruntime`: [v1.11.0](service/sagemakerruntime/CHANGELOG.md#v1110-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/shield`: [v1.11.0](service/shield/CHANGELOG.md#v1110-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/snowball`: [v1.10.0](service/snowball/CHANGELOG.md#v1100-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/storagegateway`: [v1.10.0](service/storagegateway/CHANGELOG.md#v1100-2021-12-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/workspacesweb`: [v1.0.0](service/workspacesweb/CHANGELOG.md#v100-2021-12-02)
+ * **Release**: New AWS service client module
+
+# Release (2021-11-30)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.16.0](service/autoscaling/CHANGELOG.md#v1160-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/backup`: [v1.10.0](service/backup/CHANGELOG.md#v1100-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/braket`: [v1.10.0](service/braket/CHANGELOG.md#v1100-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmeetings`: [v1.2.0](service/chimesdkmeetings/CHANGELOG.md#v120-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.15.0](service/cloudformation/CHANGELOG.md#v1150-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/computeoptimizer`: [v1.13.0](service/computeoptimizer/CHANGELOG.md#v1130-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/connect`: [v1.13.0](service/connect/CHANGELOG.md#v1130-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/customerprofiles`: [v1.12.0](service/customerprofiles/CHANGELOG.md#v1120-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/databasemigrationservice`: [v1.13.0](service/databasemigrationservice/CHANGELOG.md#v1130-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/dataexchange`: [v1.9.0](service/dataexchange/CHANGELOG.md#v190-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/dynamodb`: [v1.9.0](service/dynamodb/CHANGELOG.md#v190-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.24.0](service/ec2/CHANGELOG.md#v1240-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ecr`: [v1.11.0](service/ecr/CHANGELOG.md#v1110-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.13.0](service/ecs/CHANGELOG.md#v1130-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.15.0](service/eks/CHANGELOG.md#v1150-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.15.0](service/elasticache/CHANGELOG.md#v1150-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2`: [v1.13.0](service/elasticloadbalancingv2/CHANGELOG.md#v1130-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticsearchservice`: [v1.10.0](service/elasticsearchservice/CHANGELOG.md#v1100-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/evidently`: [v1.0.0](service/evidently/CHANGELOG.md#v100-2021-11-30)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/finspacedata`: [v1.5.0](service/finspacedata/CHANGELOG.md#v150-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/imagebuilder`: [v1.14.0](service/imagebuilder/CHANGELOG.md#v1140-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/inspector2`: [v1.0.0](service/inspector2/CHANGELOG.md#v100-2021-11-30)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/internal/endpoint-discovery`: [v1.3.2](service/internal/endpoint-discovery/CHANGELOG.md#v132-2021-11-30)
+ * **Bug Fix**: Fixed a race condition that caused concurrent calls relying on endpoint discovery to share the same `url.URL` reference in their operation's http.Request.
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.17.0](service/iot/CHANGELOG.md#v1170-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotdeviceadvisor`: [v1.9.0](service/iotdeviceadvisor/CHANGELOG.md#v190-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotsitewise`: [v1.15.0](service/iotsitewise/CHANGELOG.md#v1150-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotwireless`: [v1.13.0](service/iotwireless/CHANGELOG.md#v1130-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.14.0](service/lambda/CHANGELOG.md#v1140-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/macie2`: [v1.14.0](service/macie2/CHANGELOG.md#v1140-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mgn`: [v1.8.0](service/mgn/CHANGELOG.md#v180-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/migrationhubrefactorspaces`: [v1.0.0](service/migrationhubrefactorspaces/CHANGELOG.md#v100-2021-11-30)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/opensearch`: [v1.4.0](service/opensearch/CHANGELOG.md#v140-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/outposts`: [v1.11.0](service/outposts/CHANGELOG.md#v1110-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/personalize`: [v1.12.0](service/personalize/CHANGELOG.md#v1120-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/personalizeruntime`: [v1.7.0](service/personalizeruntime/CHANGELOG.md#v170-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/pinpoint`: [v1.12.0](service/pinpoint/CHANGELOG.md#v1120-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/proton`: [v1.7.0](service/proton/CHANGELOG.md#v170-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.15.0](service/quicksight/CHANGELOG.md#v1150-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rbin`: [v1.0.0](service/rbin/CHANGELOG.md#v100-2021-11-30)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.13.0](service/rds/CHANGELOG.md#v1130-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/redshift`: [v1.16.0](service/redshift/CHANGELOG.md#v1160-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rum`: [v1.0.0](service/rum/CHANGELOG.md#v100-2021-11-30)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.20.0](service/s3/CHANGELOG.md#v1200-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.15.0](service/s3control/CHANGELOG.md#v1150-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sqs`: [v1.13.0](service/sqs/CHANGELOG.md#v1130-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.17.0](service/ssm/CHANGELOG.md#v1170-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sts`: [v1.11.0](service/sts/CHANGELOG.md#v1110-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/textract`: [v1.10.0](service/textract/CHANGELOG.md#v1100-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/timestreamquery`: [v1.8.0](service/timestreamquery/CHANGELOG.md#v180-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/timestreamwrite`: [v1.8.0](service/timestreamwrite/CHANGELOG.md#v180-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/transcribestreaming`: [v1.1.0](service/transcribestreaming/CHANGELOG.md#v110-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/translate`: [v1.8.0](service/translate/CHANGELOG.md#v180-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/wellarchitected`: [v1.9.0](service/wellarchitected/CHANGELOG.md#v190-2021-11-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/workspaces`: [v1.11.0](service/workspaces/CHANGELOG.md#v1110-2021-11-30)
+ * **Feature**: API client updated
+
+# Release (2021-11-19)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2`: v1.11.1
+ * **Bug Fix**: Fixed a bug that prevented aws.EndpointResolverWithOptionsFunc from satisfying the aws.EndpointResolverWithOptions interface.
+* `github.com/aws/aws-sdk-go-v2/service/amplifybackend`: [v1.8.0](service/amplifybackend/CHANGELOG.md#v180-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/apigateway`: [v1.10.0](service/apigateway/CHANGELOG.md#v1100-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/appconfig`: [v1.7.0](service/appconfig/CHANGELOG.md#v170-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/appconfigdata`: [v1.0.0](service/appconfigdata/CHANGELOG.md#v100-2021-11-19)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/applicationinsights`: [v1.8.0](service/applicationinsights/CHANGELOG.md#v180-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/appstream`: [v1.10.0](service/appstream/CHANGELOG.md#v1100-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/auditmanager`: [v1.12.0](service/auditmanager/CHANGELOG.md#v1120-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/batch`: [v1.11.0](service/batch/CHANGELOG.md#v1110-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chime`: [v1.14.0](service/chime/CHANGELOG.md#v1140-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmeetings`: [v1.1.0](service/chimesdkmeetings/CHANGELOG.md#v110-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.14.0](service/cloudformation/CHANGELOG.md#v1140-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudtrail`: [v1.10.0](service/cloudtrail/CHANGELOG.md#v1100-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatch`: [v1.12.0](service/cloudwatch/CHANGELOG.md#v1120-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/connect`: [v1.12.0](service/connect/CHANGELOG.md#v1120-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/databasemigrationservice`: [v1.12.0](service/databasemigrationservice/CHANGELOG.md#v1120-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/databrew`: [v1.13.0](service/databrew/CHANGELOG.md#v1130-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/devopsguru`: [v1.10.0](service/devopsguru/CHANGELOG.md#v1100-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/drs`: [v1.0.0](service/drs/CHANGELOG.md#v100-2021-11-19)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/dynamodbstreams`: [v1.8.0](service/dynamodbstreams/CHANGELOG.md#v180-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.23.0](service/ec2/CHANGELOG.md#v1230-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.14.0](service/eks/CHANGELOG.md#v1140-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/forecast`: [v1.14.0](service/forecast/CHANGELOG.md#v1140-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ivs`: [v1.10.0](service/ivs/CHANGELOG.md#v1100-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kafka`: [v1.10.0](service/kafka/CHANGELOG.md#v1100-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.16.0](service/kendra/CHANGELOG.md#v1160-2021-11-19)
+ * **Announcement**: Fix API modeling bug incorrectly generating `DocumentAttributeValue` type as a union instead of a structure. This update corrects this bug by correcting the `DocumentAttributeValue` type to be a `struct` instead of an `interface`. This change also removes the `DocumentAttributeValueMember` types. To migrate to this change your application using service/kendra will need to be updated to use struct members in `DocumentAttributeValue` instead of `DocumentAttributeValueMember` types.
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kms`: [v1.11.0](service/kms/CHANGELOG.md#v1110-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.13.0](service/lambda/CHANGELOG.md#v1130-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.13.0](service/lexmodelsv2/CHANGELOG.md#v1130-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexruntimev2`: [v1.9.0](service/lexruntimev2/CHANGELOG.md#v190-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/location`: [v1.9.0](service/location/CHANGELOG.md#v190-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.15.0](service/mediaconvert/CHANGELOG.md#v1150-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/medialive`: [v1.14.0](service/medialive/CHANGELOG.md#v1140-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mgn`: [v1.7.0](service/mgn/CHANGELOG.md#v170-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/migrationhubstrategy`: [v1.0.0](service/migrationhubstrategy/CHANGELOG.md#v100-2021-11-19)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/qldb`: [v1.9.0](service/qldb/CHANGELOG.md#v190-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/qldbsession`: [v1.9.0](service/qldbsession/CHANGELOG.md#v190-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/redshift`: [v1.15.0](service/redshift/CHANGELOG.md#v1150-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sns`: [v1.12.0](service/sns/CHANGELOG.md#v1120-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.16.0](service/ssm/CHANGELOG.md#v1160-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/transfer`: [v1.12.0](service/transfer/CHANGELOG.md#v1120-2021-11-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/wafv2`: [v1.14.0](service/wafv2/CHANGELOG.md#v1140-2021-11-19)
+ * **Feature**: API client updated
+
+# Release (2021-11-12)
+
+## General Highlights
+* **Feature**: Service clients now support custom endpoints that have an initial URI path defined.
+* **Feature**: Waiters now have a `WaitForOutput` method, which can be used to retrieve the output of the successful wait operation. Thank you to [Andrew Haines](https://github.com/haines) for contributing this feature.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/backup`: [v1.9.0](service/backup/CHANGELOG.md#v190-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/batch`: [v1.10.0](service/batch/CHANGELOG.md#v1100-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmeetings`: [v1.0.0](service/chimesdkmeetings/CHANGELOG.md#v100-2021-11-12)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/computeoptimizer`: [v1.12.0](service/computeoptimizer/CHANGELOG.md#v1120-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/connect`: [v1.11.0](service/connect/CHANGELOG.md#v1110-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/docdb`: [v1.12.0](service/docdb/CHANGELOG.md#v1120-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/dynamodb`: [v1.8.0](service/dynamodb/CHANGELOG.md#v180-2021-11-12)
+ * **Documentation**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.22.0](service/ec2/CHANGELOG.md#v1220-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.12.0](service/ecs/CHANGELOG.md#v1120-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/gamelift`: [v1.9.0](service/gamelift/CHANGELOG.md#v190-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/greengrassv2`: [v1.9.0](service/greengrassv2/CHANGELOG.md#v190-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/health`: [v1.10.0](service/health/CHANGELOG.md#v1100-2021-11-12)
+ * **Documentation**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/identitystore`: [v1.9.0](service/identitystore/CHANGELOG.md#v190-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iotwireless`: [v1.12.0](service/iotwireless/CHANGELOG.md#v1120-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/neptune`: [v1.11.0](service/neptune/CHANGELOG.md#v1110-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.12.0](service/rds/CHANGELOG.md#v1120-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/resiliencehub`: [v1.0.0](service/resiliencehub/CHANGELOG.md#v100-2021-11-12)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/resourcegroupstaggingapi`: [v1.8.0](service/resourcegroupstaggingapi/CHANGELOG.md#v180-2021-11-12)
+ * **Documentation**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.14.0](service/s3control/CHANGELOG.md#v1140-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.19.0](service/sagemaker/CHANGELOG.md#v1190-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/sagemakerruntime`: [v1.10.0](service/sagemakerruntime/CHANGELOG.md#v1100-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssmincidents`: [v1.7.0](service/ssmincidents/CHANGELOG.md#v170-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/transcribe`: [v1.11.0](service/transcribe/CHANGELOG.md#v1110-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/translate`: [v1.7.0](service/translate/CHANGELOG.md#v170-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/wafv2`: [v1.13.0](service/wafv2/CHANGELOG.md#v1130-2021-11-12)
+ * **Feature**: Updated service to latest API model.
+
+# Release (2021-11-06)
+
+## General Highlights
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream`: [v1.0.0](aws/protocol/eventstream/CHANGELOG.md#v100-2021-11-06)
+ * **Announcement**: Support has been added for AWS EventStream APIs for Kinesis, S3, and Transcribe Streaming. Support for the Lex Runtime V2 EventStream API will be added in a future release.
+ * **Release**: Protocol support has been added for AWS event stream.
+* `github.com/aws/aws-sdk-go-v2/internal/endpoints/v2`: [v2.0.0](internal/endpoints/v2/CHANGELOG.md#v200-2021-11-06)
+ * **Release**: Endpoint Variant Model Support
+* `github.com/aws/aws-sdk-go-v2/service/applicationinsights`: [v1.6.0](service/applicationinsights/CHANGELOG.md#v160-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/appstream`: [v1.8.0](service/appstream/CHANGELOG.md#v180-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/auditmanager`: [v1.11.0](service/auditmanager/CHANGELOG.md#v1110-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.14.0](service/autoscaling/CHANGELOG.md#v1140-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/chime`: [v1.13.0](service/chime/CHANGELOG.md#v1130-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkidentity`: [v1.4.0](service/chimesdkidentity/CHANGELOG.md#v140-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmessaging`: [v1.4.0](service/chimesdkmessaging/CHANGELOG.md#v140-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/cloudfront`: [v1.10.0](service/cloudfront/CHANGELOG.md#v1100-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/codecommit`: [v1.7.0](service/codecommit/CHANGELOG.md#v170-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/connect`: [v1.10.0](service/connect/CHANGELOG.md#v1100-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/connectcontactlens`: [v1.7.0](service/connectcontactlens/CHANGELOG.md#v170-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/connectparticipant`: [v1.6.0](service/connectparticipant/CHANGELOG.md#v160-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/databasemigrationservice`: [v1.10.0](service/databasemigrationservice/CHANGELOG.md#v1100-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/datasync`: [v1.8.0](service/datasync/CHANGELOG.md#v180-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/docdb`: [v1.11.0](service/docdb/CHANGELOG.md#v1110-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ebs`: [v1.9.0](service/ebs/CHANGELOG.md#v190-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.21.0](service/ec2/CHANGELOG.md#v1210-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ecr`: [v1.9.0](service/ecr/CHANGELOG.md#v190-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.11.0](service/ecs/CHANGELOG.md#v1110-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.12.0](service/eks/CHANGELOG.md#v1120-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.13.0](service/elasticache/CHANGELOG.md#v1130-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/elasticsearchservice`: [v1.9.0](service/elasticsearchservice/CHANGELOG.md#v190-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/emrcontainers`: [v1.8.0](service/emrcontainers/CHANGELOG.md#v180-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/finspace`: [v1.4.0](service/finspace/CHANGELOG.md#v140-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/fsx`: [v1.12.0](service/fsx/CHANGELOG.md#v1120-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/gamelift`: [v1.8.0](service/gamelift/CHANGELOG.md#v180-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/health`: [v1.9.0](service/health/CHANGELOG.md#v190-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iam`: [v1.12.0](service/iam/CHANGELOG.md#v1120-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/internal/eventstreamtesting`: [v1.0.0](service/internal/eventstreamtesting/CHANGELOG.md#v100-2021-11-06)
+ * **Release**: Protocol support has been added for AWS event stream.
+* `github.com/aws/aws-sdk-go-v2/service/iotsitewise`: [v1.13.0](service/iotsitewise/CHANGELOG.md#v1130-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.14.0](service/kendra/CHANGELOG.md#v1140-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/kinesis`: [v1.8.0](service/kinesis/CHANGELOG.md#v180-2021-11-06)
+ * **Feature**: Support has been added for the SubscribeToShard API.
+* `github.com/aws/aws-sdk-go-v2/service/kms`: [v1.9.0](service/kms/CHANGELOG.md#v190-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/lightsail`: [v1.12.0](service/lightsail/CHANGELOG.md#v1120-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/macie2`: [v1.13.0](service/macie2/CHANGELOG.md#v1130-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/mgn`: [v1.6.0](service/mgn/CHANGELOG.md#v160-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/neptune`: [v1.10.0](service/neptune/CHANGELOG.md#v1100-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/networkmanager`: [v1.6.0](service/networkmanager/CHANGELOG.md#v160-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/nimble`: [v1.6.0](service/nimble/CHANGELOG.md#v160-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/opensearch`: [v1.3.0](service/opensearch/CHANGELOG.md#v130-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.14.0](service/quicksight/CHANGELOG.md#v1140-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.11.0](service/rds/CHANGELOG.md#v1110-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/rekognition`: [v1.10.0](service/rekognition/CHANGELOG.md#v1100-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/route53resolver`: [v1.9.0](service/route53resolver/CHANGELOG.md#v190-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.18.0](service/s3/CHANGELOG.md#v1180-2021-11-06)
+ * **Feature**: Support has been added for the SelectObjectContent API.
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.13.0](service/s3control/CHANGELOG.md#v1130-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.18.0](service/sagemaker/CHANGELOG.md#v1180-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/servicediscovery`: [v1.11.0](service/servicediscovery/CHANGELOG.md#v1110-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssmincidents`: [v1.6.0](service/ssmincidents/CHANGELOG.md#v160-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/sso`: [v1.6.0](service/sso/CHANGELOG.md#v160-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/storagegateway`: [v1.8.0](service/storagegateway/CHANGELOG.md#v180-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/support`: [v1.7.0](service/support/CHANGELOG.md#v170-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/textract`: [v1.8.0](service/textract/CHANGELOG.md#v180-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/transcribe`: [v1.10.0](service/transcribe/CHANGELOG.md#v1100-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/transcribestreaming`: [v1.0.0](service/transcribestreaming/CHANGELOG.md#v100-2021-11-06)
+ * **Release**: New AWS service client module
+ * **Feature**: Support has been added for the StartStreamTranscription and StartMedicalStreamTranscription APIs.
+* `github.com/aws/aws-sdk-go-v2/service/waf`: [v1.6.0](service/waf/CHANGELOG.md#v160-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/wisdom`: [v1.2.0](service/wisdom/CHANGELOG.md#v120-2021-11-06)
+ * **Feature**: Updated service to latest API model.
+
+# Release (2021-10-21)
+
+## General Highlights
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2`: v1.10.0
+ * **Feature**: Adds dynamic signing middleware that switches to unsigned payload when TLS is enabled.
+* `github.com/aws/aws-sdk-go-v2/service/appflow`: [v1.8.0](service/appflow/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/applicationautoscaling`: [v1.8.0](service/applicationautoscaling/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.13.0](service/autoscaling/CHANGELOG.md#v1130-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmessaging`: [v1.3.0](service/chimesdkmessaging/CHANGELOG.md#v130-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.11.0](service/cloudformation/CHANGELOG.md#v1110-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudsearch`: [v1.7.0](service/cloudsearch/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudtrail`: [v1.7.0](service/cloudtrail/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatch`: [v1.9.0](service/cloudwatch/CHANGELOG.md#v190-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatchevents`: [v1.7.0](service/cloudwatchevents/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatchlogs`: [v1.8.0](service/cloudwatchlogs/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codedeploy`: [v1.7.0](service/codedeploy/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/configservice`: [v1.10.0](service/configservice/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/dataexchange`: [v1.7.0](service/dataexchange/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/directconnect`: [v1.9.0](service/directconnect/CHANGELOG.md#v190-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/docdb`: [v1.10.0](service/docdb/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/dynamodb`: [v1.6.0](service/dynamodb/CHANGELOG.md#v160-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.20.0](service/ec2/CHANGELOG.md#v1200-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ecr`: [v1.8.0](service/ecr/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.10.0](service/ecs/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/efs`: [v1.9.0](service/efs/CHANGELOG.md#v190-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.12.0](service/elasticache/CHANGELOG.md#v1120-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancing`: [v1.7.0](service/elasticloadbalancing/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2`: [v1.10.0](service/elasticloadbalancingv2/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/emr`: [v1.10.0](service/emr/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/eventbridge`: [v1.8.0](service/eventbridge/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/glacier`: [v1.6.0](service/glacier/CHANGELOG.md#v160-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.13.0](service/glue/CHANGELOG.md#v1130-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ivs`: [v1.8.0](service/ivs/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.13.0](service/kendra/CHANGELOG.md#v1130-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kinesis`: [v1.7.0](service/kinesis/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kinesisanalyticsv2`: [v1.7.0](service/kinesisanalyticsv2/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kms`: [v1.8.0](service/kms/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.10.0](service/lambda/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.13.0](service/mediaconvert/CHANGELOG.md#v1130-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediapackage`: [v1.9.0](service/mediapackage/CHANGELOG.md#v190-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediapackagevod`: [v1.10.0](service/mediapackagevod/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediatailor`: [v1.9.0](service/mediatailor/CHANGELOG.md#v190-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/neptune`: [v1.9.0](service/neptune/CHANGELOG.md#v190-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/panorama`: [v1.0.0](service/panorama/CHANGELOG.md#v100-2021-10-21)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.13.0](service/quicksight/CHANGELOG.md#v1130-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.10.0](service/rds/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/redshift`: [v1.12.0](service/redshift/CHANGELOG.md#v1120-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/robomaker`: [v1.10.0](service/robomaker/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.17.0](service/s3/CHANGELOG.md#v1170-2021-10-21)
+ * **Feature**: Updates S3 streaming operations - PutObject, UploadPart, WriteGetObjectResponse to use unsigned payload signing auth when TLS is enabled.
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.17.0](service/sagemaker/CHANGELOG.md#v1170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/securityhub`: [v1.12.0](service/securityhub/CHANGELOG.md#v1120-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sfn`: [v1.6.0](service/sfn/CHANGELOG.md#v160-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sns`: [v1.9.0](service/sns/CHANGELOG.md#v190-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sqs`: [v1.10.0](service/sqs/CHANGELOG.md#v1100-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/storagegateway`: [v1.7.0](service/storagegateway/CHANGELOG.md#v170-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sts`: [v1.8.0](service/sts/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/swf`: [v1.6.0](service/swf/CHANGELOG.md#v160-2021-10-21)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/workmail`: [v1.8.0](service/workmail/CHANGELOG.md#v180-2021-10-21)
+ * **Feature**: API client updated
+
+# Release (2021-10-11)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/feature/ec2/imds`: [v1.6.0](feature/ec2/imds/CHANGELOG.md#v160-2021-10-11)
+ * **Feature**: Respect passed in Context Deadline/Timeout. Updates the IMDS Client operations to not override the passed in Context's Deadline or Timeout options. If an Client operation is called with a Context with a Deadline or Timeout, the client will no longer override it with the client's default timeout.
+ * **Bug Fix**: Fix IMDS client's response handling and operation timeout race. Fixes #1253
+* `github.com/aws/aws-sdk-go-v2/service/amplifybackend`: [v1.5.0](service/amplifybackend/CHANGELOG.md#v150-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/applicationautoscaling`: [v1.7.0](service/applicationautoscaling/CHANGELOG.md#v170-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/apprunner`: [v1.3.0](service/apprunner/CHANGELOG.md#v130-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/backup`: [v1.6.0](service/backup/CHANGELOG.md#v160-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chime`: [v1.11.0](service/chime/CHANGELOG.md#v1110-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codebuild`: [v1.11.0](service/codebuild/CHANGELOG.md#v1110-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/databrew`: [v1.10.0](service/databrew/CHANGELOG.md#v1100-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.19.0](service/ec2/CHANGELOG.md#v1190-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/efs`: [v1.8.0](service/efs/CHANGELOG.md#v180-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2`: [v1.9.0](service/elasticloadbalancingv2/CHANGELOG.md#v190-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/firehose`: [v1.7.0](service/firehose/CHANGELOG.md#v170-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/frauddetector`: [v1.10.0](service/frauddetector/CHANGELOG.md#v1100-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/fsx`: [v1.10.0](service/fsx/CHANGELOG.md#v1100-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.12.0](service/glue/CHANGELOG.md#v1120-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/grafana`: [v1.0.0](service/grafana/CHANGELOG.md#v100-2021-10-11)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotevents`: [v1.8.0](service/iotevents/CHANGELOG.md#v180-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.12.0](service/kendra/CHANGELOG.md#v1120-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kms`: [v1.7.0](service/kms/CHANGELOG.md#v170-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.9.0](service/lexmodelsv2/CHANGELOG.md#v190-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexruntimev2`: [v1.6.0](service/lexruntimev2/CHANGELOG.md#v160-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/location`: [v1.6.0](service/location/CHANGELOG.md#v160-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.12.0](service/mediaconvert/CHANGELOG.md#v1120-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/medialive`: [v1.10.0](service/medialive/CHANGELOG.md#v1100-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.16.0](service/sagemaker/CHANGELOG.md#v1160-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/secretsmanager`: [v1.7.0](service/secretsmanager/CHANGELOG.md#v170-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/securityhub`: [v1.11.0](service/securityhub/CHANGELOG.md#v1110-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.12.0](service/ssm/CHANGELOG.md#v1120-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssooidc`: [v1.6.0](service/ssooidc/CHANGELOG.md#v160-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/synthetics`: [v1.7.0](service/synthetics/CHANGELOG.md#v170-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/textract`: [v1.6.0](service/textract/CHANGELOG.md#v160-2021-10-11)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/workmail`: [v1.7.0](service/workmail/CHANGELOG.md#v170-2021-10-11)
+ * **Feature**: API client updated
+
+# Release (2021-09-30)
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/account`: [v1.0.0](service/account/CHANGELOG.md#v100-2021-09-30)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/amp`: [v1.6.0](service/amp/CHANGELOG.md#v160-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/appintegrations`: [v1.7.0](service/appintegrations/CHANGELOG.md#v170-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudcontrol`: [v1.0.0](service/cloudcontrol/CHANGELOG.md#v100-2021-09-30)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudhsmv2`: [v1.5.0](service/cloudhsmv2/CHANGELOG.md#v150-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/connect`: [v1.8.0](service/connect/CHANGELOG.md#v180-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/dataexchange`: [v1.6.0](service/dataexchange/CHANGELOG.md#v160-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2`: [v1.8.0](service/elasticloadbalancingv2/CHANGELOG.md#v180-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/imagebuilder`: [v1.11.0](service/imagebuilder/CHANGELOG.md#v1110-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.9.0](service/lambda/CHANGELOG.md#v190-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/macie2`: [v1.11.0](service/macie2/CHANGELOG.md#v1110-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/networkfirewall`: [v1.7.0](service/networkfirewall/CHANGELOG.md#v170-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/pinpoint`: [v1.8.0](service/pinpoint/CHANGELOG.md#v180-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sesv2`: [v1.6.0](service/sesv2/CHANGELOG.md#v160-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/transfer`: [v1.8.0](service/transfer/CHANGELOG.md#v180-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/voiceid`: [v1.0.0](service/voiceid/CHANGELOG.md#v100-2021-09-30)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/wisdom`: [v1.0.0](service/wisdom/CHANGELOG.md#v100-2021-09-30)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/workmail`: [v1.6.0](service/workmail/CHANGELOG.md#v160-2021-09-30)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/workspaces`: [v1.7.0](service/workspaces/CHANGELOG.md#v170-2021-09-30)
+ * **Feature**: API client updated
+
+# Release (2021-09-24)
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/feature/dynamodb/expression`: [v1.2.4](feature/dynamodb/expression/CHANGELOG.md#v124-2021-09-24)
+ * **Documentation**: Fixes typo in NameBuilder.NamesList example documentation to use the correct variable name.
+* `github.com/aws/aws-sdk-go-v2/service/appmesh`: [v1.6.0](service/appmesh/CHANGELOG.md#v160-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/appsync`: [v1.7.0](service/appsync/CHANGELOG.md#v170-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/auditmanager`: [v1.9.0](service/auditmanager/CHANGELOG.md#v190-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codecommit`: [v1.5.0](service/codecommit/CHANGELOG.md#v150-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/comprehend`: [v1.8.0](service/comprehend/CHANGELOG.md#v180-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/databasemigrationservice`: [v1.8.0](service/databasemigrationservice/CHANGELOG.md#v180-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.18.0](service/ec2/CHANGELOG.md#v1180-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ecr`: [v1.7.0](service/ecr/CHANGELOG.md#v170-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticsearchservice`: [v1.7.0](service/elasticsearchservice/CHANGELOG.md#v170-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iam`: [v1.10.0](service/iam/CHANGELOG.md#v1100-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/identitystore`: [v1.6.0](service/identitystore/CHANGELOG.md#v160-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/imagebuilder`: [v1.10.0](service/imagebuilder/CHANGELOG.md#v1100-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.13.0](service/iot/CHANGELOG.md#v1130-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotevents`: [v1.7.0](service/iotevents/CHANGELOG.md#v170-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kafkaconnect`: [v1.1.0](service/kafkaconnect/CHANGELOG.md#v110-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lakeformation`: [v1.6.0](service/lakeformation/CHANGELOG.md#v160-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.8.0](service/lexmodelsv2/CHANGELOG.md#v180-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexruntimev2`: [v1.5.0](service/lexruntimev2/CHANGELOG.md#v150-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/licensemanager`: [v1.8.0](service/licensemanager/CHANGELOG.md#v180-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.11.0](service/mediaconvert/CHANGELOG.md#v1110-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediapackagevod`: [v1.9.0](service/mediapackagevod/CHANGELOG.md#v190-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediatailor`: [v1.8.0](service/mediatailor/CHANGELOG.md#v180-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/opensearch`: [v1.1.0](service/opensearch/CHANGELOG.md#v110-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.12.0](service/quicksight/CHANGELOG.md#v1120-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.11.0](service/ssm/CHANGELOG.md#v1110-2021-09-24)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/wafv2`: [v1.10.0](service/wafv2/CHANGELOG.md#v1100-2021-09-24)
+ * **Feature**: API client updated
+
+# Release (2021-09-17)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/chime`: [v1.10.0](service/chime/CHANGELOG.md#v1100-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.10.1](service/cloudformation/CHANGELOG.md#v1101-2021-09-17)
+ * **Documentation**: Updated API client documentation.
+* `github.com/aws/aws-sdk-go-v2/service/comprehend`: [v1.7.0](service/comprehend/CHANGELOG.md#v170-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.17.0](service/ec2/CHANGELOG.md#v1170-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/ecr`: [v1.6.0](service/ecr/CHANGELOG.md#v160-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.12.0](service/iot/CHANGELOG.md#v1120-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/kafkaconnect`: [v1.0.0](service/kafkaconnect/CHANGELOG.md#v100-2021-09-17)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.7.0](service/lexmodelsv2/CHANGELOG.md#v170-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/lexruntimev2`: [v1.4.0](service/lexruntimev2/CHANGELOG.md#v140-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/macie2`: [v1.10.0](service/macie2/CHANGELOG.md#v1100-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/mediapackagevod`: [v1.8.0](service/mediapackagevod/CHANGELOG.md#v180-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/networkfirewall`: [v1.6.0](service/networkfirewall/CHANGELOG.md#v160-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/pinpoint`: [v1.7.0](service/pinpoint/CHANGELOG.md#v170-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.11.0](service/quicksight/CHANGELOG.md#v1110-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.9.0](service/rds/CHANGELOG.md#v190-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/robomaker`: [v1.9.0](service/robomaker/CHANGELOG.md#v190-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.16.0](service/s3/CHANGELOG.md#v1160-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.15.0](service/sagemaker/CHANGELOG.md#v1150-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/ssooidc`: [v1.5.0](service/ssooidc/CHANGELOG.md#v150-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/transcribe`: [v1.8.0](service/transcribe/CHANGELOG.md#v180-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/wafv2`: [v1.9.0](service/wafv2/CHANGELOG.md#v190-2021-09-17)
+ * **Feature**: Updated API client and endpoints to latest revision.
+
+# Release (2021-09-10)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/credentials`: [v1.4.1](credentials/CHANGELOG.md#v141-2021-09-10)
+ * **Documentation**: Fixes the AssumeRoleProvider's documentation for using custom TokenProviders.
+* `github.com/aws/aws-sdk-go-v2/service/amp`: [v1.5.0](service/amp/CHANGELOG.md#v150-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/braket`: [v1.7.0](service/braket/CHANGELOG.md#v170-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkidentity`: [v1.2.0](service/chimesdkidentity/CHANGELOG.md#v120-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmessaging`: [v1.2.0](service/chimesdkmessaging/CHANGELOG.md#v120-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codegurureviewer`: [v1.7.0](service/codegurureviewer/CHANGELOG.md#v170-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.10.0](service/eks/CHANGELOG.md#v1100-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.11.0](service/elasticache/CHANGELOG.md#v1110-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/emr`: [v1.9.0](service/emr/CHANGELOG.md#v190-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/forecast`: [v1.10.0](service/forecast/CHANGELOG.md#v1100-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/frauddetector`: [v1.9.0](service/frauddetector/CHANGELOG.md#v190-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kafka`: [v1.7.0](service/kafka/CHANGELOG.md#v170-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lookoutequipment`: [v1.4.0](service/lookoutequipment/CHANGELOG.md#v140-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediapackage`: [v1.8.0](service/mediapackage/CHANGELOG.md#v180-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/opensearch`: [v1.0.0](service/opensearch/CHANGELOG.md#v100-2021-09-10)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/outposts`: [v1.8.0](service/outposts/CHANGELOG.md#v180-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ram`: [v1.7.0](service/ram/CHANGELOG.md#v170-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.14.0](service/sagemaker/CHANGELOG.md#v1140-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/servicediscovery`: [v1.9.0](service/servicediscovery/CHANGELOG.md#v190-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssmcontacts`: [v1.5.0](service/ssmcontacts/CHANGELOG.md#v150-2021-09-10)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/xray`: [v1.6.0](service/xray/CHANGELOG.md#v160-2021-09-10)
+ * **Feature**: API client updated
+
+# Release (2021-09-02)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/config`: [v1.8.0](config/CHANGELOG.md#v180-2021-09-02)
+ * **Feature**: Add support for S3 Multi-Region Access Point ARNs.
+* `github.com/aws/aws-sdk-go-v2/service/accessanalyzer`: [v1.7.0](service/accessanalyzer/CHANGELOG.md#v170-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/acmpca`: [v1.8.0](service/acmpca/CHANGELOG.md#v180-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloud9`: [v1.8.0](service/cloud9/CHANGELOG.md#v180-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.10.0](service/cloudformation/CHANGELOG.md#v1100-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudtrail`: [v1.6.0](service/cloudtrail/CHANGELOG.md#v160-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codebuild`: [v1.10.0](service/codebuild/CHANGELOG.md#v1100-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/computeoptimizer`: [v1.9.0](service/computeoptimizer/CHANGELOG.md#v190-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/configservice`: [v1.9.0](service/configservice/CHANGELOG.md#v190-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ebs`: [v1.7.0](service/ebs/CHANGELOG.md#v170-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.16.0](service/ec2/CHANGELOG.md#v1160-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/efs`: [v1.7.0](service/efs/CHANGELOG.md#v170-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/emr`: [v1.8.0](service/emr/CHANGELOG.md#v180-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/firehose`: [v1.6.0](service/firehose/CHANGELOG.md#v160-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/frauddetector`: [v1.8.0](service/frauddetector/CHANGELOG.md#v180-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/fsx`: [v1.9.0](service/fsx/CHANGELOG.md#v190-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/internal/s3shared`: [v1.7.0](service/internal/s3shared/CHANGELOG.md#v170-2021-09-02)
+ * **Feature**: Add support for S3 Multi-Region Access Point ARNs.
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.11.0](service/iot/CHANGELOG.md#v1110-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotjobsdataplane`: [v1.5.0](service/iotjobsdataplane/CHANGELOG.md#v150-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ivs`: [v1.7.0](service/ivs/CHANGELOG.md#v170-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kms`: [v1.6.0](service/kms/CHANGELOG.md#v160-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelbuildingservice`: [v1.9.0](service/lexmodelbuildingservice/CHANGELOG.md#v190-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediatailor`: [v1.7.0](service/mediatailor/CHANGELOG.md#v170-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/memorydb`: [v1.2.0](service/memorydb/CHANGELOG.md#v120-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mwaa`: [v1.5.0](service/mwaa/CHANGELOG.md#v150-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/polly`: [v1.6.0](service/polly/CHANGELOG.md#v160-2021-09-02)
+ * **Feature**: API client updated
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.10.0](service/quicksight/CHANGELOG.md#v1100-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.15.0](service/s3/CHANGELOG.md#v1150-2021-09-02)
+ * **Feature**: API client updated
+ * **Feature**: Add support for S3 Multi-Region Access Point ARNs.
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.11.0](service/s3control/CHANGELOG.md#v1110-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemakerruntime`: [v1.7.0](service/sagemakerruntime/CHANGELOG.md#v170-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/schemas`: [v1.6.0](service/schemas/CHANGELOG.md#v160-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/securityhub`: [v1.10.0](service/securityhub/CHANGELOG.md#v1100-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/servicecatalogappregistry`: [v1.5.0](service/servicecatalogappregistry/CHANGELOG.md#v150-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sqs`: [v1.9.0](service/sqs/CHANGELOG.md#v190-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssmincidents`: [v1.4.0](service/ssmincidents/CHANGELOG.md#v140-2021-09-02)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/transfer`: [v1.7.0](service/transfer/CHANGELOG.md#v170-2021-09-02)
+ * **Feature**: API client updated
+
+# Release (2021-08-27)
+
+## General Highlights
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/credentials`: [v1.4.0](credentials/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Adds support for Tags and TransitiveTagKeys to stscreds.AssumeRoleProvider. Closes https://github.com/aws/aws-sdk-go-v2/issues/723
+* `github.com/aws/aws-sdk-go-v2/feature/dynamodb/attributevalue`: [v1.2.0](feature/dynamodb/attributevalue/CHANGELOG.md#v120-2021-08-27)
+ * **Bug Fix**: Fix unmarshaler's decoding of AttributeValueMemberN into a type that is a string alias.
+* `github.com/aws/aws-sdk-go-v2/service/acmpca`: [v1.7.0](service/acmpca/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/amplify`: [v1.5.0](service/amplify/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/amplifybackend`: [v1.4.0](service/amplifybackend/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/apigateway`: [v1.7.0](service/apigateway/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/apigatewaymanagementapi`: [v1.4.0](service/apigatewaymanagementapi/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/appflow`: [v1.7.0](service/appflow/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/applicationinsights`: [v1.4.0](service/applicationinsights/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/apprunner`: [v1.2.0](service/apprunner/CHANGELOG.md#v120-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/appstream`: [v1.6.0](service/appstream/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/appsync`: [v1.6.0](service/appsync/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/athena`: [v1.6.0](service/athena/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/auditmanager`: [v1.8.0](service/auditmanager/CHANGELOG.md#v180-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/autoscalingplans`: [v1.5.0](service/autoscalingplans/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/backup`: [v1.5.0](service/backup/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/batch`: [v1.7.0](service/batch/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/braket`: [v1.6.0](service/braket/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkidentity`: [v1.1.0](service/chimesdkidentity/CHANGELOG.md#v110-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmessaging`: [v1.1.0](service/chimesdkmessaging/CHANGELOG.md#v110-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/cloudtrail`: [v1.5.0](service/cloudtrail/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatchevents`: [v1.6.0](service/cloudwatchevents/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/codeartifact`: [v1.5.0](service/codeartifact/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/codebuild`: [v1.9.0](service/codebuild/CHANGELOG.md#v190-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/codecommit`: [v1.4.0](service/codecommit/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/codeguruprofiler`: [v1.5.0](service/codeguruprofiler/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/codestarnotifications`: [v1.4.0](service/codestarnotifications/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/cognitoidentity`: [v1.5.0](service/cognitoidentity/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/cognitoidentityprovider`: [v1.6.0](service/cognitoidentityprovider/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/comprehend`: [v1.6.0](service/comprehend/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/computeoptimizer`: [v1.8.0](service/computeoptimizer/CHANGELOG.md#v180-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/connectcontactlens`: [v1.5.0](service/connectcontactlens/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/customerprofiles`: [v1.9.0](service/customerprofiles/CHANGELOG.md#v190-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/databasemigrationservice`: [v1.7.0](service/databasemigrationservice/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/datasync`: [v1.6.0](service/datasync/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/dax`: [v1.4.0](service/dax/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/directoryservice`: [v1.5.0](service/directoryservice/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/dlm`: [v1.5.0](service/dlm/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/dynamodbstreams`: [v1.4.0](service/dynamodbstreams/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.15.0](service/ec2/CHANGELOG.md#v1150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/ecrpublic`: [v1.5.0](service/ecrpublic/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/efs`: [v1.6.0](service/efs/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.9.0](service/eks/CHANGELOG.md#v190-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/emrcontainers`: [v1.6.0](service/emrcontainers/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/eventbridge`: [v1.7.0](service/eventbridge/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/finspace`: [v1.2.0](service/finspace/CHANGELOG.md#v120-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/finspacedata`: [v1.2.0](service/finspacedata/CHANGELOG.md#v120-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/firehose`: [v1.5.0](service/firehose/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/fms`: [v1.7.0](service/fms/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/forecast`: [v1.9.0](service/forecast/CHANGELOG.md#v190-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/forecastquery`: [v1.4.0](service/forecastquery/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/frauddetector`: [v1.7.0](service/frauddetector/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/fsx`: [v1.8.0](service/fsx/CHANGELOG.md#v180-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/gamelift`: [v1.6.0](service/gamelift/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.11.0](service/glue/CHANGELOG.md#v1110-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/groundstation`: [v1.6.0](service/groundstation/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/guardduty`: [v1.5.0](service/guardduty/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/health`: [v1.7.0](service/health/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/healthlake`: [v1.6.0](service/healthlake/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.10.0](service/iot/CHANGELOG.md#v1100-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/iot1clickdevicesservice`: [v1.4.0](service/iot1clickdevicesservice/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/iotanalytics`: [v1.5.0](service/iotanalytics/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/iotdataplane`: [v1.4.0](service/iotdataplane/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/iotfleethub`: [v1.5.0](service/iotfleethub/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/iotsitewise`: [v1.11.0](service/iotsitewise/CHANGELOG.md#v1110-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/ivs`: [v1.6.0](service/ivs/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/lakeformation`: [v1.5.0](service/lakeformation/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.6.0](service/lexmodelsv2/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/lexruntimev2`: [v1.3.0](service/lexruntimev2/CHANGELOG.md#v130-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/licensemanager`: [v1.7.0](service/licensemanager/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/lightsail`: [v1.10.0](service/lightsail/CHANGELOG.md#v1100-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/lookoutequipment`: [v1.3.0](service/lookoutequipment/CHANGELOG.md#v130-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/lookoutmetrics`: [v1.3.0](service/lookoutmetrics/CHANGELOG.md#v130-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/macie2`: [v1.9.0](service/macie2/CHANGELOG.md#v190-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.10.0](service/mediaconvert/CHANGELOG.md#v1100-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/mediapackage`: [v1.7.0](service/mediapackage/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/mediapackagevod`: [v1.7.0](service/mediapackagevod/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/mq`: [v1.5.0](service/mq/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/networkfirewall`: [v1.5.0](service/networkfirewall/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/outposts`: [v1.7.0](service/outposts/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/pi`: [v1.6.0](service/pi/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/pinpointsmsvoice`: [v1.4.0](service/pinpointsmsvoice/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/polly`: [v1.5.0](service/polly/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/qldb`: [v1.6.0](service/qldb/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/qldbsession`: [v1.5.0](service/qldbsession/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/ram`: [v1.6.0](service/ram/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/rekognition`: [v1.8.0](service/rekognition/CHANGELOG.md#v180-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/resourcegroupstaggingapi`: [v1.5.0](service/resourcegroupstaggingapi/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/robomaker`: [v1.8.0](service/robomaker/CHANGELOG.md#v180-2021-08-27)
+ * **Bug Fix**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/route53recoverycontrolconfig`: [v1.1.0](service/route53recoverycontrolconfig/CHANGELOG.md#v110-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/route53resolver`: [v1.7.0](service/route53resolver/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.14.0](service/s3/CHANGELOG.md#v1140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.10.0](service/s3control/CHANGELOG.md#v1100-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/s3outposts`: [v1.5.0](service/s3outposts/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/servicecatalog`: [v1.5.0](service/servicecatalog/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/servicecatalogappregistry`: [v1.4.0](service/servicecatalogappregistry/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/signer`: [v1.5.0](service/signer/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/ssooidc`: [v1.4.0](service/ssooidc/CHANGELOG.md#v140-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/storagegateway`: [v1.6.0](service/storagegateway/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/synthetics`: [v1.6.0](service/synthetics/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/textract`: [v1.5.0](service/textract/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/transcribe`: [v1.7.0](service/transcribe/CHANGELOG.md#v170-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/transfer`: [v1.6.0](service/transfer/CHANGELOG.md#v160-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/wafregional`: [v1.5.0](service/wafregional/CHANGELOG.md#v150-2021-08-27)
+ * **Feature**: Updated API model to latest revision.
+
+# Release (2021-08-19)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/apigateway`: [v1.6.0](service/apigateway/CHANGELOG.md#v160-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/apigatewayv2`: [v1.5.0](service/apigatewayv2/CHANGELOG.md#v150-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/appflow`: [v1.6.0](service/appflow/CHANGELOG.md#v160-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/applicationautoscaling`: [v1.5.0](service/applicationautoscaling/CHANGELOG.md#v150-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloud9`: [v1.6.0](service/cloud9/CHANGELOG.md#v160-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/clouddirectory`: [v1.4.0](service/clouddirectory/CHANGELOG.md#v140-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatchlogs`: [v1.6.0](service/cloudwatchlogs/CHANGELOG.md#v160-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codebuild`: [v1.8.0](service/codebuild/CHANGELOG.md#v180-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/configservice`: [v1.7.0](service/configservice/CHANGELOG.md#v170-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/costexplorer`: [v1.8.0](service/costexplorer/CHANGELOG.md#v180-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/customerprofiles`: [v1.8.0](service/customerprofiles/CHANGELOG.md#v180-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/databrew`: [v1.8.0](service/databrew/CHANGELOG.md#v180-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/directoryservice`: [v1.4.0](service/directoryservice/CHANGELOG.md#v140-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.14.0](service/ec2/CHANGELOG.md#v1140-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.9.0](service/elasticache/CHANGELOG.md#v190-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/emr`: [v1.6.0](service/emr/CHANGELOG.md#v160-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotsitewise`: [v1.10.0](service/iotsitewise/CHANGELOG.md#v1100-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.7.0](service/lambda/CHANGELOG.md#v170-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/licensemanager`: [v1.6.0](service/licensemanager/CHANGELOG.md#v160-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/memorydb`: [v1.0.0](service/memorydb/CHANGELOG.md#v100-2021-08-19)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.8.0](service/quicksight/CHANGELOG.md#v180-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/route53`: [v1.10.0](service/route53/CHANGELOG.md#v1100-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/route53resolver`: [v1.6.0](service/route53resolver/CHANGELOG.md#v160-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.13.0](service/s3/CHANGELOG.md#v1130-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.12.0](service/sagemaker/CHANGELOG.md#v1120-2021-08-19)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemakerruntime`: [v1.5.0](service/sagemakerruntime/CHANGELOG.md#v150-2021-08-19)
+ * **Feature**: API client updated
+
+# Release (2021-08-12)
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/feature/cloudfront/sign`: [v1.3.1](feature/cloudfront/sign/CHANGELOG.md#v131-2021-08-12)
+ * **Bug Fix**: Update to not escape HTML when encoding the policy.
+* `github.com/aws/aws-sdk-go-v2/service/athena`: [v1.5.0](service/athena/CHANGELOG.md#v150-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.11.0](service/autoscaling/CHANGELOG.md#v1110-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chime`: [v1.8.0](service/chime/CHANGELOG.md#v180-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkidentity`: [v1.0.0](service/chimesdkidentity/CHANGELOG.md#v100-2021-08-12)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chimesdkmessaging`: [v1.0.0](service/chimesdkmessaging/CHANGELOG.md#v100-2021-08-12)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codebuild`: [v1.7.0](service/codebuild/CHANGELOG.md#v170-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/connect`: [v1.6.0](service/connect/CHANGELOG.md#v160-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ebs`: [v1.5.0](service/ebs/CHANGELOG.md#v150-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.8.0](service/ecs/CHANGELOG.md#v180-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.5.0](service/lexmodelsv2/CHANGELOG.md#v150-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lightsail`: [v1.9.0](service/lightsail/CHANGELOG.md#v190-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/nimble`: [v1.3.0](service/nimble/CHANGELOG.md#v130-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rekognition`: [v1.7.0](service/rekognition/CHANGELOG.md#v170-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/route53`: [v1.9.0](service/route53/CHANGELOG.md#v190-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/snowdevicemanagement`: [v1.0.0](service/snowdevicemanagement/CHANGELOG.md#v100-2021-08-12)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.9.0](service/ssm/CHANGELOG.md#v190-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/synthetics`: [v1.5.0](service/synthetics/CHANGELOG.md#v150-2021-08-12)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/wafv2`: [v1.7.0](service/wafv2/CHANGELOG.md#v170-2021-08-12)
+ * **Feature**: API client updated
+
+# Release (2021-08-04)
+
+## General Highlights
+* **Feature**: adds error handling for defered close calls
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2`: v1.8.0
+ * **Bug Fix**: Corrected an issue where the retryer was not using the last attempt's ResultMetadata as the bases for the return result from the stack. ([#1345](https://github.com/aws/aws-sdk-go-v2/pull/1345))
+* `github.com/aws/aws-sdk-go-v2/feature/dynamodb/expression`: [v1.2.0](feature/dynamodb/expression/CHANGELOG.md#v120-2021-08-04)
+ * **Feature**: Add IsSet helper for ConditionBuilder and KeyConditionBuilder ([#1329](https://github.com/aws/aws-sdk-go-v2/pull/1329))
+* `github.com/aws/aws-sdk-go-v2/service/accessanalyzer`: [v1.5.2](service/accessanalyzer/CHANGELOG.md#v152-2021-08-04)
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/amp`: [v1.3.1](service/amp/CHANGELOG.md#v131-2021-08-04)
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/appintegrations`: [v1.5.0](service/appintegrations/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/appmesh`: [v1.4.2](service/appmesh/CHANGELOG.md#v142-2021-08-04)
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/appsync`: [v1.5.0](service/appsync/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/auditmanager`: [v1.7.0](service/auditmanager/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/batch`: [v1.6.0](service/batch/CHANGELOG.md#v160-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/braket`: [v1.5.2](service/braket/CHANGELOG.md#v152-2021-08-04)
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/chime`: [v1.7.0](service/chime/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.8.0](service/cloudformation/CHANGELOG.md#v180-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatch`: [v1.7.0](service/cloudwatch/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/codebuild`: [v1.6.0](service/codebuild/CHANGELOG.md#v160-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/codeguruprofiler`: [v1.4.2](service/codeguruprofiler/CHANGELOG.md#v142-2021-08-04)
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/cognitoidentityprovider`: [v1.5.0](service/cognitoidentityprovider/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/computeoptimizer`: [v1.7.0](service/computeoptimizer/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/databrew`: [v1.7.0](service/databrew/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/directconnect`: [v1.7.0](service/directconnect/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.13.0](service/ec2/CHANGELOG.md#v1130-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.7.0](service/ecs/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2`: [v1.6.0](service/elasticloadbalancingv2/CHANGELOG.md#v160-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/emr`: [v1.5.0](service/emr/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/emrcontainers`: [v1.5.0](service/emrcontainers/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/eventbridge`: [v1.6.0](service/eventbridge/CHANGELOG.md#v160-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.10.0](service/glue/CHANGELOG.md#v1100-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/greengrassv2`: [v1.5.0](service/greengrassv2/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/groundstation`: [v1.5.2](service/groundstation/CHANGELOG.md#v152-2021-08-04)
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/iam`: [v1.8.0](service/iam/CHANGELOG.md#v180-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/identitystore`: [v1.4.0](service/identitystore/CHANGELOG.md#v140-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/imagebuilder`: [v1.8.0](service/imagebuilder/CHANGELOG.md#v180-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.9.0](service/iot/CHANGELOG.md#v190-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iotanalytics`: [v1.4.0](service/iotanalytics/CHANGELOG.md#v140-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iotsitewise`: [v1.9.0](service/iotsitewise/CHANGELOG.md#v190-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iotwireless`: [v1.8.0](service/iotwireless/CHANGELOG.md#v180-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.10.0](service/kendra/CHANGELOG.md#v1100-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.6.0](service/lambda/CHANGELOG.md#v160-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelbuildingservice`: [v1.7.0](service/lexmodelbuildingservice/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.4.0](service/lexmodelsv2/CHANGELOG.md#v140-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/location`: [v1.4.0](service/location/CHANGELOG.md#v140-2021-08-04)
+ * **Feature**: Updated to latest API model.
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.9.0](service/mediaconvert/CHANGELOG.md#v190-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/medialive`: [v1.8.0](service/medialive/CHANGELOG.md#v180-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/mgn`: [v1.3.1](service/mgn/CHANGELOG.md#v131-2021-08-04)
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/personalize`: [v1.7.0](service/personalize/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/proton`: [v1.2.0](service/proton/CHANGELOG.md#v120-2021-08-04)
+ * **Feature**: Updated to latest API model.
+ * **Bug Fix**: Fixed an issue that caused one or more API operations to fail when attempting to resolve the service endpoint. ([#1349](https://github.com/aws/aws-sdk-go-v2/pull/1349))
+* `github.com/aws/aws-sdk-go-v2/service/qldb`: [v1.5.0](service/qldb/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.7.0](service/quicksight/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.7.0](service/rds/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/redshift`: [v1.10.0](service/redshift/CHANGELOG.md#v1100-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/redshiftdata`: [v1.5.0](service/redshiftdata/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/robomaker`: [v1.7.0](service/robomaker/CHANGELOG.md#v170-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/route53`: [v1.8.0](service/route53/CHANGELOG.md#v180-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/route53recoverycluster`: [v1.0.0](service/route53recoverycluster/CHANGELOG.md#v100-2021-08-04)
+ * **Release**: New AWS service client module
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/route53recoverycontrolconfig`: [v1.0.0](service/route53recoverycontrolconfig/CHANGELOG.md#v100-2021-08-04)
+ * **Release**: New AWS service client module
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/route53recoveryreadiness`: [v1.0.0](service/route53recoveryreadiness/CHANGELOG.md#v100-2021-08-04)
+ * **Release**: New AWS service client module
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.12.0](service/s3/CHANGELOG.md#v1120-2021-08-04)
+ * **Feature**: Add `HeadObject` presign support. ([#1346](https://github.com/aws/aws-sdk-go-v2/pull/1346))
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.9.0](service/s3control/CHANGELOG.md#v190-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3outposts`: [v1.4.0](service/s3outposts/CHANGELOG.md#v140-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.11.0](service/sagemaker/CHANGELOG.md#v1110-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/secretsmanager`: [v1.5.0](service/secretsmanager/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/securityhub`: [v1.8.0](service/securityhub/CHANGELOG.md#v180-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/shield`: [v1.6.0](service/shield/CHANGELOG.md#v160-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssmcontacts`: [v1.3.0](service/ssmcontacts/CHANGELOG.md#v130-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssmincidents`: [v1.2.0](service/ssmincidents/CHANGELOG.md#v120-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssoadmin`: [v1.5.0](service/ssoadmin/CHANGELOG.md#v150-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/synthetics`: [v1.4.0](service/synthetics/CHANGELOG.md#v140-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/textract`: [v1.4.0](service/textract/CHANGELOG.md#v140-2021-08-04)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/transcribe`: [v1.6.0](service/transcribe/CHANGELOG.md#v160-2021-08-04)
+ * **Feature**: Updated to latest API model.
+
+# Release (2021-07-15)
+
+## General Highlights
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/config`: [v1.5.0](config/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: Support has been added for EC2 IPv6-enabled Instance Metadata Service Endpoints.
+* `github.com/aws/aws-sdk-go-v2/feature/ec2/imds`: [v1.3.0](feature/ec2/imds/CHANGELOG.md#v130-2021-07-15)
+ * **Feature**: Support has been added for EC2 IPv6-enabled Instance Metadata Service Endpoints.
+* `github.com/aws/aws-sdk-go-v2/service/acm`: [v1.5.0](service/acm/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/amp`: [v1.3.0](service/amp/CHANGELOG.md#v130-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/amplify`: [v1.4.0](service/amplify/CHANGELOG.md#v140-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/amplifybackend`: [v1.3.0](service/amplifybackend/CHANGELOG.md#v130-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.10.0](service/autoscaling/CHANGELOG.md#v1100-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/chime`: [v1.6.0](service/chime/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.7.0](service/cloudformation/CHANGELOG.md#v170-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/cloudfront`: [v1.7.0](service/cloudfront/CHANGELOG.md#v170-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/cloudsearch`: [v1.5.0](service/cloudsearch/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatch`: [v1.6.0](service/cloudwatch/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/databasemigrationservice`: [v1.6.0](service/databasemigrationservice/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/devopsguru`: [v1.6.0](service/devopsguru/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/directconnect`: [v1.6.0](service/directconnect/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/docdb`: [v1.8.0](service/docdb/CHANGELOG.md#v180-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.12.0](service/ec2/CHANGELOG.md#v1120-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.8.0](service/eks/CHANGELOG.md#v180-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.8.0](service/elasticache/CHANGELOG.md#v180-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/elasticbeanstalk`: [v1.5.0](service/elasticbeanstalk/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancing`: [v1.5.0](service/elasticloadbalancing/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2`: [v1.5.0](service/elasticloadbalancingv2/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/fms`: [v1.6.0](service/fms/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/frauddetector`: [v1.6.0](service/frauddetector/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.9.0](service/glue/CHANGELOG.md#v190-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/health`: [v1.6.0](service/health/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/healthlake`: [v1.5.0](service/healthlake/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/iam`: [v1.7.0](service/iam/CHANGELOG.md#v170-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/imagebuilder`: [v1.7.0](service/imagebuilder/CHANGELOG.md#v170-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.8.0](service/iot/CHANGELOG.md#v180-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/iotsitewise`: [v1.8.0](service/iotsitewise/CHANGELOG.md#v180-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.9.0](service/kendra/CHANGELOG.md#v190-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/lambda`: [v1.5.0](service/lambda/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelbuildingservice`: [v1.6.0](service/lexmodelbuildingservice/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/lightsail`: [v1.8.0](service/lightsail/CHANGELOG.md#v180-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/macie`: [v1.5.1](service/macie/CHANGELOG.md#v151-2021-07-15)
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/macie2`: [v1.8.1](service/macie2/CHANGELOG.md#v181-2021-07-15)
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.8.0](service/mediaconvert/CHANGELOG.md#v180-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/mediatailor`: [v1.5.0](service/mediatailor/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/mgn`: [v1.3.0](service/mgn/CHANGELOG.md#v130-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/mq`: [v1.4.0](service/mq/CHANGELOG.md#v140-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/neptune`: [v1.7.0](service/neptune/CHANGELOG.md#v170-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/outposts`: [v1.6.0](service/outposts/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/pricing`: [v1.5.1](service/pricing/CHANGELOG.md#v151-2021-07-15)
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.6.0](service/rds/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/redshift`: [v1.9.0](service/redshift/CHANGELOG.md#v190-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.10.0](service/sagemaker/CHANGELOG.md#v1100-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/ses`: [v1.5.0](service/ses/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/sns`: [v1.7.0](service/sns/CHANGELOG.md#v170-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/sqs`: [v1.7.0](service/sqs/CHANGELOG.md#v170-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.8.0](service/ssm/CHANGELOG.md#v180-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/storagegateway`: [v1.5.0](service/storagegateway/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+* `github.com/aws/aws-sdk-go-v2/service/sts`: [v1.6.0](service/sts/CHANGELOG.md#v160-2021-07-15)
+ * **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+ * **Documentation**: Updated service model to latest revision.
+* `github.com/aws/aws-sdk-go-v2/service/wellarchitected`: [v1.5.0](service/wellarchitected/CHANGELOG.md#v150-2021-07-15)
+ * **Feature**: Updated service model to latest version.
+
+# Release (2021-07-01)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/internal/ini`: [v1.1.0](internal/ini/CHANGELOG.md#v110-2021-07-01)
+ * **Feature**: Support for `:`, `=`, `[`, `]` being present in expression values.
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.9.0](service/autoscaling/CHANGELOG.md#v190-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/databrew`: [v1.6.0](service/databrew/CHANGELOG.md#v160-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.11.0](service/ec2/CHANGELOG.md#v1110-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.8.0](service/glue/CHANGELOG.md#v180-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.8.0](service/kendra/CHANGELOG.md#v180-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.7.0](service/mediaconvert/CHANGELOG.md#v170-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediapackagevod`: [v1.6.0](service/mediapackagevod/CHANGELOG.md#v160-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/redshift`: [v1.8.0](service/redshift/CHANGELOG.md#v180-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.9.0](service/sagemaker/CHANGELOG.md#v190-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/servicediscovery`: [v1.7.0](service/servicediscovery/CHANGELOG.md#v170-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sqs`: [v1.6.0](service/sqs/CHANGELOG.md#v160-2021-07-01)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssmcontacts`: [v1.2.0](service/ssmcontacts/CHANGELOG.md#v120-2021-07-01)
+ * **Feature**: API client updated
+
+# Release (2021-06-25)
+
+## General Highlights
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2`: v1.7.0
+ * **Feature**: Adds configuration values for enabling endpoint discovery.
+ * **Bug Fix**: Keep Object-Lock headers a header when presigning Sigv4 signing requests
+* `github.com/aws/aws-sdk-go-v2/config`: [v1.4.0](config/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: Adds configuration setting for enabling endpoint discovery.
+* `github.com/aws/aws-sdk-go-v2/credentials`: [v1.3.0](credentials/CHANGELOG.md#v130-2021-06-25)
+ * **Bug Fix**: Fixed example usages of aws.CredentialsCache ([#1275](https://github.com/aws/aws-sdk-go-v2/pull/1275))
+* `github.com/aws/aws-sdk-go-v2/feature/cloudfront/sign`: [v1.2.0](feature/cloudfront/sign/CHANGELOG.md#v120-2021-06-25)
+ * **Feature**: Add UnmarshalJSON for AWSEpochTime to correctly unmarshal AWSEpochTime, ([#1298](https://github.com/aws/aws-sdk-go-v2/pull/1298))
+* `github.com/aws/aws-sdk-go-v2/internal/configsources`: [v1.0.0](internal/configsources/CHANGELOG.md#v100-2021-06-25)
+ * **Release**: Release new modules
+* `github.com/aws/aws-sdk-go-v2/service/amp`: [v1.2.0](service/amp/CHANGELOG.md#v120-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/amplify`: [v1.3.0](service/amplify/CHANGELOG.md#v130-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/amplifybackend`: [v1.2.0](service/amplifybackend/CHANGELOG.md#v120-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/appflow`: [v1.5.0](service/appflow/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/appmesh`: [v1.4.0](service/appmesh/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/chime`: [v1.5.0](service/chime/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloud9`: [v1.5.0](service/cloud9/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudformation`: [v1.6.0](service/cloudformation/CHANGELOG.md#v160-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudfront`: [v1.6.0](service/cloudfront/CHANGELOG.md#v160-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudsearch`: [v1.4.0](service/cloudsearch/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatch`: [v1.5.0](service/cloudwatch/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatchevents`: [v1.5.0](service/cloudwatchevents/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codebuild`: [v1.5.0](service/codebuild/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/codegurureviewer`: [v1.5.0](service/codegurureviewer/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cognitoidentity`: [v1.4.0](service/cognitoidentity/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/cognitoidentityprovider`: [v1.4.0](service/cognitoidentityprovider/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/connect`: [v1.5.0](service/connect/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/dax`: [v1.3.0](service/dax/CHANGELOG.md#v130-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/docdb`: [v1.7.0](service/docdb/CHANGELOG.md#v170-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/dynamodb`: [v1.4.0](service/dynamodb/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: Adds support for endpoint discovery.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.10.0](service/ec2/CHANGELOG.md#v1100-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.7.0](service/elasticache/CHANGELOG.md#v170-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticbeanstalk`: [v1.4.0](service/elasticbeanstalk/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancing`: [v1.4.0](service/elasticloadbalancing/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2`: [v1.4.0](service/elasticloadbalancingv2/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/eventbridge`: [v1.5.0](service/eventbridge/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/greengrass`: [v1.5.0](service/greengrass/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/greengrassv2`: [v1.4.0](service/greengrassv2/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iam`: [v1.6.0](service/iam/CHANGELOG.md#v160-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/internal/endpoint-discovery`: [v1.0.0](service/internal/endpoint-discovery/CHANGELOG.md#v100-2021-06-25)
+ * **Release**: Release new modules
+ * **Feature**: Module supporting endpoint-discovery across all service clients.
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.7.0](service/iot/CHANGELOG.md#v170-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotanalytics`: [v1.3.0](service/iotanalytics/CHANGELOG.md#v130-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.7.0](service/kendra/CHANGELOG.md#v170-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kms`: [v1.4.0](service/kms/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.3.0](service/lexmodelsv2/CHANGELOG.md#v130-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexruntimev2`: [v1.2.0](service/lexruntimev2/CHANGELOG.md#v120-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/licensemanager`: [v1.5.0](service/licensemanager/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lookoutmetrics`: [v1.2.0](service/lookoutmetrics/CHANGELOG.md#v120-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/managedblockchain`: [v1.4.0](service/managedblockchain/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediaconnect`: [v1.6.0](service/mediaconnect/CHANGELOG.md#v160-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/medialive`: [v1.7.0](service/medialive/CHANGELOG.md#v170-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediatailor`: [v1.4.0](service/mediatailor/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/neptune`: [v1.6.0](service/neptune/CHANGELOG.md#v160-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/proton`: [v1.1.0](service/proton/CHANGELOG.md#v110-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.6.0](service/quicksight/CHANGELOG.md#v160-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ram`: [v1.5.0](service/ram/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.5.0](service/rds/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/redshift`: [v1.7.0](service/redshift/CHANGELOG.md#v170-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/redshiftdata`: [v1.4.0](service/redshiftdata/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/route53`: [v1.7.0](service/route53/CHANGELOG.md#v170-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.8.0](service/sagemaker/CHANGELOG.md#v180-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemakerfeaturestoreruntime`: [v1.4.0](service/sagemakerfeaturestoreruntime/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/securityhub`: [v1.7.0](service/securityhub/CHANGELOG.md#v170-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ses`: [v1.4.0](service/ses/CHANGELOG.md#v140-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/snowball`: [v1.5.0](service/snowball/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sns`: [v1.6.0](service/sns/CHANGELOG.md#v160-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sqs`: [v1.5.0](service/sqs/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sts`: [v1.5.0](service/sts/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/timestreamquery`: [v1.3.0](service/timestreamquery/CHANGELOG.md#v130-2021-06-25)
+ * **Feature**: Adds support for endpoint discovery.
+* `github.com/aws/aws-sdk-go-v2/service/timestreamwrite`: [v1.3.0](service/timestreamwrite/CHANGELOG.md#v130-2021-06-25)
+ * **Feature**: Adds support for endpoint discovery.
+* `github.com/aws/aws-sdk-go-v2/service/transfer`: [v1.5.0](service/transfer/CHANGELOG.md#v150-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/waf`: [v1.3.0](service/waf/CHANGELOG.md#v130-2021-06-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/wafv2`: [v1.6.0](service/wafv2/CHANGELOG.md#v160-2021-06-25)
+ * **Feature**: API client updated
+
+# Release (2021-06-11)
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.7.0](service/autoscaling/CHANGELOG.md#v170-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/cloudtrail`: [v1.3.2](service/cloudtrail/CHANGELOG.md#v132-2021-06-11)
+ * **Documentation**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/cognitoidentityprovider`: [v1.3.3](service/cognitoidentityprovider/CHANGELOG.md#v133-2021-06-11)
+ * **Documentation**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.6.0](service/eks/CHANGELOG.md#v160-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/fsx`: [v1.6.0](service/fsx/CHANGELOG.md#v160-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/glue`: [v1.6.0](service/glue/CHANGELOG.md#v160-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.6.0](service/kendra/CHANGELOG.md#v160-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/macie2`: [v1.7.0](service/macie2/CHANGELOG.md#v170-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/medialive`: [v1.6.0](service/medialive/CHANGELOG.md#v160-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/pi`: [v1.4.0](service/pi/CHANGELOG.md#v140-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/proton`: [v1.0.0](service/proton/CHANGELOG.md#v100-2021-06-11)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/qldb`: [v1.3.1](service/qldb/CHANGELOG.md#v131-2021-06-11)
+ * **Documentation**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/rds`: [v1.4.2](service/rds/CHANGELOG.md#v142-2021-06-11)
+ * **Documentation**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.7.0](service/sagemaker/CHANGELOG.md#v170-2021-06-11)
+ * **Feature**: Updated to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/transfer`: [v1.4.1](service/transfer/CHANGELOG.md#v141-2021-06-11)
+ * **Documentation**: Updated to latest API model.
+
+# Release (2021-06-04)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/acmpca`: [v1.5.0](service/acmpca/CHANGELOG.md#v150-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.6.0](service/autoscaling/CHANGELOG.md#v160-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/braket`: [v1.4.0](service/braket/CHANGELOG.md#v140-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/cloudfront`: [v1.5.2](service/cloudfront/CHANGELOG.md#v152-2021-06-04)
+ * **Documentation**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/datasync`: [v1.4.0](service/datasync/CHANGELOG.md#v140-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/devicefarm`: [v1.3.0](service/devicefarm/CHANGELOG.md#v130-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/docdb`: [v1.6.0](service/docdb/CHANGELOG.md#v160-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.9.0](service/ec2/CHANGELOG.md#v190-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.5.0](service/ecs/CHANGELOG.md#v150-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/forecast`: [v1.7.0](service/forecast/CHANGELOG.md#v170-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/fsx`: [v1.5.0](service/fsx/CHANGELOG.md#v150-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iam`: [v1.5.1](service/iam/CHANGELOG.md#v151-2021-06-04)
+ * **Documentation**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/internal/s3shared`: [v1.4.0](service/internal/s3shared/CHANGELOG.md#v140-2021-06-04)
+ * **Feature**: The handling of AccessPoint and Outpost ARNs have been updated.
+* `github.com/aws/aws-sdk-go-v2/service/iotevents`: [v1.4.0](service/iotevents/CHANGELOG.md#v140-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ioteventsdata`: [v1.3.0](service/ioteventsdata/CHANGELOG.md#v130-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iotsitewise`: [v1.6.0](service/iotsitewise/CHANGELOG.md#v160-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/iotwireless`: [v1.6.0](service/iotwireless/CHANGELOG.md#v160-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/kendra`: [v1.5.0](service/kendra/CHANGELOG.md#v150-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/lightsail`: [v1.6.1](service/lightsail/CHANGELOG.md#v161-2021-06-04)
+ * **Documentation**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/location`: [v1.2.0](service/location/CHANGELOG.md#v120-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/mwaa`: [v1.2.0](service/mwaa/CHANGELOG.md#v120-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/outposts`: [v1.4.0](service/outposts/CHANGELOG.md#v140-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/polly`: [v1.3.0](service/polly/CHANGELOG.md#v130-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/qldb`: [v1.3.0](service/qldb/CHANGELOG.md#v130-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/resourcegroups`: [v1.3.2](service/resourcegroups/CHANGELOG.md#v132-2021-06-04)
+ * **Documentation**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/route53`: [v1.6.2](service/route53/CHANGELOG.md#v162-2021-06-04)
+ * **Documentation**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/route53resolver`: [v1.4.2](service/route53resolver/CHANGELOG.md#v142-2021-06-04)
+ * **Documentation**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.10.0](service/s3/CHANGELOG.md#v1100-2021-06-04)
+ * **Feature**: The handling of AccessPoint and Outpost ARNs have been updated.
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.7.0](service/s3control/CHANGELOG.md#v170-2021-06-04)
+ * **Feature**: The handling of AccessPoint and Outpost ARNs have been updated.
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/servicediscovery`: [v1.5.0](service/servicediscovery/CHANGELOG.md#v150-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/sns`: [v1.5.0](service/sns/CHANGELOG.md#v150-2021-06-04)
+ * **Feature**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/sqs`: [v1.4.2](service/sqs/CHANGELOG.md#v142-2021-06-04)
+ * **Documentation**: Updated service client to latest API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.6.2](service/ssm/CHANGELOG.md#v162-2021-06-04)
+ * **Documentation**: Updated service client to latest API model.
+
+# Release (2021-05-25)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2/service/cloudwatchlogs`: [v1.4.0](service/cloudwatchlogs/CHANGELOG.md#v140-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/commander`: [v1.1.0](service/commander/CHANGELOG.md#v110-2021-05-25)
+ * **Feature**: Deprecated module. The API client was incorrectly named. Use AWS Systems Manager Incident Manager (ssmincidents) instead.
+* `github.com/aws/aws-sdk-go-v2/service/computeoptimizer`: [v1.5.0](service/computeoptimizer/CHANGELOG.md#v150-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/costexplorer`: [v1.6.0](service/costexplorer/CHANGELOG.md#v160-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.8.0](service/ec2/CHANGELOG.md#v180-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/efs`: [v1.4.0](service/efs/CHANGELOG.md#v140-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/forecast`: [v1.6.0](service/forecast/CHANGELOG.md#v160-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.6.0](service/iot/CHANGELOG.md#v160-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/opsworkscm`: [v1.4.0](service/opsworkscm/CHANGELOG.md#v140-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.5.0](service/quicksight/CHANGELOG.md#v150-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.9.0](service/s3/CHANGELOG.md#v190-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/ssmincidents`: [v1.0.0](service/ssmincidents/CHANGELOG.md#v100-2021-05-25)
+ * **Release**: New AWS service client module
+* `github.com/aws/aws-sdk-go-v2/service/transfer`: [v1.4.0](service/transfer/CHANGELOG.md#v140-2021-05-25)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/workspaces`: [v1.4.0](service/workspaces/CHANGELOG.md#v140-2021-05-25)
+ * **Feature**: API client updated
+
+# Release (2021-05-20)
+
+## General Highlights
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2`: v1.6.0
+ * **Feature**: `internal/ini`: This package has been migrated to a separate module at `github.com/aws/aws-sdk-go-v2/internal/ini`.
+* `github.com/aws/aws-sdk-go-v2/config`: [v1.3.0](config/CHANGELOG.md#v130-2021-05-20)
+ * **Feature**: SSO credentials can now be defined alongside other credential providers within the same configuration profile.
+ * **Bug Fix**: Profile names were incorrectly normalized to lower-case, which could result in unexpected profile configurations.
+* `github.com/aws/aws-sdk-go-v2/internal/ini`: [v1.0.0](internal/ini/CHANGELOG.md#v100-2021-05-20)
+ * **Release**: The `github.com/aws/aws-sdk-go-v2/internal/ini` package is now a Go Module.
+* `github.com/aws/aws-sdk-go-v2/service/applicationcostprofiler`: [v1.0.0](service/applicationcostprofiler/CHANGELOG.md#v100-2021-05-20)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/apprunner`: [v1.0.0](service/apprunner/CHANGELOG.md#v100-2021-05-20)
+ * **Release**: New AWS service client module
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/autoscaling`: [v1.5.0](service/autoscaling/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/computeoptimizer`: [v1.4.0](service/computeoptimizer/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/detective`: [v1.6.0](service/detective/CHANGELOG.md#v160-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.5.0](service/eks/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticache`: [v1.6.0](service/elasticache/CHANGELOG.md#v160-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/elasticsearchservice`: [v1.4.0](service/elasticsearchservice/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iam`: [v1.5.0](service/iam/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/imagebuilder`: [v1.5.0](service/imagebuilder/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.5.0](service/iot/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotdeviceadvisor`: [v1.4.0](service/iotdeviceadvisor/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/iotsitewise`: [v1.5.0](service/iotsitewise/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kinesis`: [v1.4.0](service/kinesis/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kinesisanalytics`: [v1.3.0](service/kinesisanalytics/CHANGELOG.md#v130-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/kinesisanalyticsv2`: [v1.4.0](service/kinesisanalyticsv2/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lexmodelsv2`: [v1.2.0](service/lexmodelsv2/CHANGELOG.md#v120-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/licensemanager`: [v1.4.0](service/licensemanager/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/lightsail`: [v1.6.0](service/lightsail/CHANGELOG.md#v160-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/macie`: [v1.4.0](service/macie/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/macie2`: [v1.6.0](service/macie2/CHANGELOG.md#v160-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/mediaconnect`: [v1.5.0](service/mediaconnect/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/neptune`: [v1.5.0](service/neptune/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/personalize`: [v1.5.0](service/personalize/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/quicksight`: [v1.4.0](service/quicksight/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/rekognition`: [v1.5.0](service/rekognition/CHANGELOG.md#v150-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.8.0](service/s3/CHANGELOG.md#v180-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemaker`: [v1.6.0](service/sagemaker/CHANGELOG.md#v160-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/sagemakera2iruntime`: [v1.3.0](service/sagemakera2iruntime/CHANGELOG.md#v130-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/securityhub`: [v1.6.0](service/securityhub/CHANGELOG.md#v160-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/support`: [v1.3.0](service/support/CHANGELOG.md#v130-2021-05-20)
+ * **Feature**: API client updated
+* `github.com/aws/aws-sdk-go-v2/service/transcribe`: [v1.4.0](service/transcribe/CHANGELOG.md#v140-2021-05-20)
+ * **Feature**: API client updated
+
+# Release (2021-05-14)
+
+## General Highlights
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+## Module Highlights
+* `github.com/aws/aws-sdk-go-v2`: v1.5.0
+ * **Feature**: `AddSDKAgentKey` and `AddSDKAgentKeyValue` in `aws/middleware` package have been updated to direct metadata to `User-Agent` HTTP header.
+* `github.com/aws/aws-sdk-go-v2/service/codeartifact`: [v1.3.0](service/codeartifact/CHANGELOG.md#v130-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/commander`: [v1.0.0](service/commander/CHANGELOG.md#v100-2021-05-14)
+ * **Release**: New AWS service client module
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/configservice`: [v1.5.0](service/configservice/CHANGELOG.md#v150-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/connect`: [v1.4.0](service/connect/CHANGELOG.md#v140-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/ec2`: [v1.7.0](service/ec2/CHANGELOG.md#v170-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/ecs`: [v1.4.0](service/ecs/CHANGELOG.md#v140-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/eks`: [v1.4.0](service/eks/CHANGELOG.md#v140-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/finspace`: [v1.0.0](service/finspace/CHANGELOG.md#v100-2021-05-14)
+ * **Release**: New AWS service client module
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/finspacedata`: [v1.0.0](service/finspacedata/CHANGELOG.md#v100-2021-05-14)
+ * **Release**: New AWS service client module
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/iot`: [v1.4.0](service/iot/CHANGELOG.md#v140-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/iotwireless`: [v1.5.0](service/iotwireless/CHANGELOG.md#v150-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/kinesis`: [v1.3.0](service/kinesis/CHANGELOG.md#v130-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/kinesisanalytics`: [v1.2.0](service/kinesisanalytics/CHANGELOG.md#v120-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/kinesisanalyticsv2`: [v1.3.0](service/kinesisanalyticsv2/CHANGELOG.md#v130-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/lakeformation`: [v1.3.0](service/lakeformation/CHANGELOG.md#v130-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/lookoutmetrics`: [v1.1.0](service/lookoutmetrics/CHANGELOG.md#v110-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/mediaconvert`: [v1.5.0](service/mediaconvert/CHANGELOG.md#v150-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/route53`: [v1.6.0](service/route53/CHANGELOG.md#v160-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3`: [v1.7.0](service/s3/CHANGELOG.md#v170-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/s3control`: [v1.6.0](service/s3control/CHANGELOG.md#v160-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssm`: [v1.6.0](service/ssm/CHANGELOG.md#v160-2021-05-14)
+ * **Feature**: Updated to latest service API model.
+* `github.com/aws/aws-sdk-go-v2/service/ssmcontacts`: [v1.0.0](service/ssmcontacts/CHANGELOG.md#v100-2021-05-14)
+ * **Release**: New AWS service client module
+ * **Feature**: Updated to latest service API model.
+
+# Release 2021-05-06
+
+## Breaking change
+* `service/ec2` - v1.6.0
+ * This release contains a breaking change to the Amazon EC2 API client. API number(int/int64/etc) and boolean members were changed from value, to pointer type. Your applications using the EC2 API client will fail to compile after upgrading for all members that were updated. To migrate to this module you'll need to update your application to use pointers for all number and boolean members in the API client module. The SDK provides helper utilities to convert between value and pointer types. For example the [aws.Bool](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/aws#Bool) function to get the address from a bool literal. Similar utilities are available for all other primitive types in the [aws](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/aws) package.
+
+## Service Client Highlights
+* `service/acmpca` - v1.3.0
+ * Feature: API client updated
+* `service/apigateway` - v1.3.0
+ * Feature: API client updated
+* `service/auditmanager` - v1.4.0
+ * Feature: API client updated
+* `service/chime` - v1.3.0
+ * Feature: API client updated
+* `service/cloudformation` - v1.4.0
+ * Feature: API client updated
+* `service/cloudfront` - v1.4.0
+ * Feature: API client updated
+* `service/codegurureviewer` - v1.3.0
+ * Feature: API client updated
+* `service/connect` - v1.3.0
+ * Feature: API client updated
+* `service/customerprofiles` - v1.5.0
+ * Feature: API client updated
+* `service/devopsguru` - v1.3.0
+ * Feature: API client updated
+* `service/docdb` - v1.4.0
+ * Feature: API client updated
+* `service/ec2` - v1.6.0
+ * Bug Fix: Fix incorrectly modeled Amazon EC2 number and boolean members in structures. The Amazon EC2 API client has been updated with a breaking change to fix all structure number and boolean members to be pointer types instead of value types. Fixes [#1107](https://github.com/aws/aws-sdk-go-v2/issues/1107), [#1178](https://github.com/aws/aws-sdk-go-v2/issues/1178), and [#1190](https://github.com/aws/aws-sdk-go-v2/issues/1190). This breaking change is made within the major version of the client' module, because the client operations failed and were unusable with value type number and boolean members with the EC2 API.
+ * Feature: API client updated
+* `service/ecs` - v1.3.0
+ * Feature: API client updated
+* `service/eks` - v1.3.0
+ * Feature: API client updated
+* `service/forecast` - v1.4.0
+ * Feature: API client updated
+* `service/glue` - v1.4.0
+ * Feature: API client updated
+* `service/health` - v1.3.0
+ * Feature: API client updated
+* `service/iotsitewise` - v1.3.0
+ * Feature: API client updated
+* `service/iotwireless` - v1.4.0
+ * Feature: API client updated
+* `service/kafka` - v1.3.0
+ * Feature: API client updated
+* `service/kinesisanalyticsv2` - v1.2.0
+ * Feature: API client updated
+* `service/macie2` - v1.4.0
+ * Feature: API client updated
+* `service/marketplacecatalog` - v1.2.0
+ * Feature: API client updated
+* `service/mediaconvert` - v1.4.0
+ * Feature: API client updated
+* `service/mediapackage` - v1.4.0
+ * Feature: API client updated
+* `service/mediapackagevod` - v1.3.0
+ * Feature: API client updated
+* `service/mturk` - v1.2.0
+ * Feature: API client updated
+* `service/nimble` - v1.0.0
+ * Feature: API client updated
+* `service/organizations` - v1.3.0
+ * Feature: API client updated
+* `service/personalize` - v1.3.0
+ * Feature: API client updated
+* `service/robomaker` - v1.4.0
+ * Feature: API client updated
+* `service/route53` - v1.5.0
+ * Feature: API client updated
+* `service/s3` - v1.6.0
+ * Bug Fix: Fix PutObject and UploadPart unseekable stream documentation link to point to the correct location.
+ * Feature: API client updated
+* `service/sagemaker` - v1.4.0
+ * Feature: API client updated
+* `service/securityhub` - v1.4.0
+ * Feature: API client updated
+* `service/servicediscovery` - v1.3.0
+ * Feature: API client updated
+* `service/snowball` - v1.3.0
+ * Feature: API client updated
+* `service/sns` - v1.3.0
+ * Feature: API client updated
+* `service/ssm` - v1.5.0
+ * Feature: API client updated
+## Core SDK Highlights
+* Dependency Update: Update smithy-go dependency to v1.4.0
+* Dependency Update: Updated SDK dependencies to their latest versions.
+* `aws` - v1.4.0
+ * Feature: Add support for FIPS global partition endpoints ([#1242](https://github.com/aws/aws-sdk-go-v2/pull/1242))
+
+# Release 2021-04-23
+## Service Client Highlights
+* `service/cloudformation` - v1.3.2
+ * Documentation: Service Documentation Updates
+* `service/cognitoidentityprovider` - v1.2.3
+ * Documentation: Service Documentation Updates
+* `service/costexplorer` - v1.4.0
+ * Feature: Service API Updates
+* `service/databasemigrationservice` - v1.3.0
+ * Feature: Service API Updates
+* `service/detective` - v1.4.0
+ * Feature: Service API Updates
+* `service/elasticache` - v1.4.0
+ * Feature: Service API Updates
+* `service/forecast` - v1.3.0
+ * Feature: Service API Updates
+* `service/groundstation` - v1.3.0
+ * Feature: Service API Updates
+* `service/kendra` - v1.3.0
+ * Feature: Service API Updates
+* `service/redshift` - v1.5.0
+ * Feature: Service API Updates
+* `service/savingsplans` - v1.2.0
+ * Feature: Service API Updates
+* `service/securityhub` - v1.3.0
+ * Feature: Service API Updates
+## Core SDK Highlights
+* Dependency Update: Updated SDK dependencies to their latest versions.
+* `feature/rds/auth` - v1.0.0
+ * Feature: Add Support for Amazon RDS IAM Authentication
+
+# Release 2021-04-14
+## Service Client Highlights
+* `service/codebuild` - v1.3.0
+ * Feature: API client updated
+* `service/codestarconnections` - v1.2.0
+ * Feature: API client updated
+* `service/comprehendmedical` - v1.2.0
+ * Feature: API client updated
+* `service/configservice` - v1.4.0
+ * Feature: API client updated
+* `service/ec2` - v1.5.0
+ * Feature: API client updated
+* `service/fsx` - v1.3.0
+ * Feature: API client updated
+* `service/lightsail` - v1.4.0
+ * Feature: API client updated
+* `service/mediaconnect` - v1.3.0
+ * Feature: API client updated
+* `service/rds` - v1.3.0
+ * Feature: API client updated
+* `service/redshift` - v1.4.0
+ * Feature: API client updated
+* `service/shield` - v1.3.0
+ * Feature: API client updated
+* `service/sts` - v1.3.0
+ * Feature: API client updated
+## Core SDK Highlights
+* Dependency Update: Updated SDK dependencies to their latest versions.
+
+# Release 2021-04-08
+## Service Client Highlights
+* Feature: API model sync
+* `service/lookoutequipment` - v1.0.0
+ * v1 Release: new service client
+* `service/mgn` - v1.0.0
+ * v1 Release: new service client
+## Core SDK Highlights
+* Dependency Update: smithy-go version bump
+* Dependency Update: Updated SDK dependencies to their latest versions.
+
+# Release 2021-04-01
+## Service Client Highlights
+* Bug Fix: Fix URL Path and RawQuery of resolved endpoint being ignored by the API client's request serialization.
+ * Fixes [issue#1191](https://github.com/aws/aws-sdk-go-v2/issues/1191)
+* Refactored internal endpoints model for accessors
+* Feature: updated to latest models
+* New services
+ * `service/location` - v1.0.0
+ * `service/lookoutmetrics` - v1.0.0
+## Core SDK Highlights
+* Dependency Update: update smithy-go module
+* Dependency Update: Updated SDK dependencies to their latest versions.
+
+# Release 2021-03-18
+## Service Client Highlights
+* Bug Fix: Updated presign URLs to no longer include the X-Amz-User-Agent header
+* Feature: Update API model
+* Add New supported API
+* `service/internal/s3shared` - v1.2.0
+ * Feature: Support for S3 Object Lambda
+* `service/s3` - v1.3.0
+ * Bug Fix: Adds documentation to the PutObject and UploadPart operations Body member how to upload unseekable objects to an Amazon S3 Bucket.
+ * Feature: S3 Object Lambda is a new S3 feature that enables users to apply their own custom code to process the output of a standard S3 GET request by automatically invoking a Lambda function with a GET request
+* `service/s3control` - v1.3.0
+ * Feature: S3 Object Lambda is a new S3 feature that enables users to apply their own custom code to process the output of a standard S3 GET request by automatically invoking a Lambda function with a GET request
+## Core SDK Highlights
+* Dependency Update: Updated SDK dependencies to their latest versions.
+* `aws` - v1.3.0
+ * Feature: Add helper to V4 signer package to swap compute payload hash middleware with unsigned payload middleware
+* `feature/s3/manager` - v1.1.0
+ * Bug Fix: Add support for Amazon S3 Object Lambda feature.
+ * Feature: Updates for S3 Object Lambda feature
+
+# Release 2021-03-12
+## Service Client Highlights
+* Bug Fix: Fixed a bug that could union shape types to be deserialized incorrectly
+* Bug Fix: Fixed a bug where unboxed shapes that were marked as required were not serialized and sent over the wire, causing an API error from the service.
+* Bug Fix: Fixed a bug with generated API Paginators' handling of nil input parameters causing a panic.
+* Dependency Update: update smithy-go dependency
+* `service/detective` - v1.1.2
+ * Bug Fix: Fix deserialization of API response timestamp member.
+* `service/docdb` - v1.2.0
+ * Feature: Client now support presigned URL generation for CopyDBClusterSnapshot and CreateDBCluster operations by specifying the target SourceRegion
+* `service/neptune` - v1.2.0
+ * Feature: Client now support presigned URL generation for CopyDBClusterSnapshot and CreateDBCluster operations by specifying the target SourceRegion
+* `service/s3` - v1.2.1
+ * Bug Fix: Fixed an issue where ListObjectsV2 and ListParts paginators could loop infinitely
+ * Bug Fix: Fixed key encoding when addressing S3 Access Points
+## Core SDK Highlights
+* Dependency Update: Updated SDK dependencies to their latest versions.
+* `config` - v1.1.2
+ * Bug Fix: Fixed a panic when using WithEC2IMDSRegion without a specified IMDS client
+
+# Release 2021-02-09
+## Service Client Highlights
+* `service/s3` - v1.2.0
+ * Feature: adds support for s3 vpc endpoint interface [#1113](https://github.com/aws/aws-sdk-go-v2/pull/1113)
+* `service/s3control` - v1.2.0
+ * Feature: adds support for s3 vpc endpoint interface [#1113](https://github.com/aws/aws-sdk-go-v2/pull/1113)
+## Core SDK Highlights
+* Dependency Update: Updated SDK dependencies to their latest versions.
+* `aws` - v1.2.0
+ * Feature: support to add endpoint source on context. Adds getter/setter for the endpoint source [#1113](https://github.com/aws/aws-sdk-go-v2/pull/1113)
+* `config` - v1.1.1
+ * Bug Fix: Only Validate SSO profile configuration when attempting to use SSO credentials [#1103](https://github.com/aws/aws-sdk-go-v2/pull/1103)
+ * Bug Fix: Environment credentials were not taking precedence over AWS_PROFILE [#1103](https://github.com/aws/aws-sdk-go-v2/pull/1103)
+
+# Release 2021-01-29
+## Service Client Highlights
+* Bug Fix: A serialization bug has been fixed that caused some service operations with empty inputs to not be serialized correctly ([#1071](https://github.com/aws/aws-sdk-go-v2/pull/1071))
+* Bug Fix: Fixes a bug that could cause a waiter to fail when comparing types ([#1083](https://github.com/aws/aws-sdk-go-v2/pull/1083))
+## Core SDK Highlights
+* Feature: EndpointResolverFromURL helpers have been added for constructing a service EndpointResolver type ([#1066](https://github.com/aws/aws-sdk-go-v2/pull/1066))
+* Dependency Update: Updated SDK dependencies to their latest versions.
+* `aws` - v1.1.0
+ * Feature: Add support for specifying the EndpointSource on aws.Endpoint types ([#1070](https://github.com/aws/aws-sdk-go-v2/pull/1070/))
+* `config` - v1.1.0
+ * Feature: Add Support for AWS Single Sign-On (SSO) credential provider ([#1072](https://github.com/aws/aws-sdk-go-v2/pull/1072))
+* `credentials` - v1.1.0
+ * Feature: Add AWS Single Sign-On (SSO) credential provider ([#1072](https://github.com/aws/aws-sdk-go-v2/pull/1072))
+
+# Release 2021-01-19
+
+We are excited to announce the [General Availability](https://aws.amazon.com/blogs/developer/aws-sdk-for-go-version-2-general-availability/)
+(GA) release of the [AWS SDK for Go version 2 (v2)](https://github.com/aws/aws-sdk-go-v2).
+This release follows the [Release candidate](https://aws.amazon.com/blogs/developer/aws-sdk-for-go-version-2-v2-release-candidate)
+of the AWS SDK for Go v2. Version 2 incorporates customer feedback from version 1 and takes advantage of modern Go language features.
+
+## Breaking Changes
+* `aws`: Updated Config.Retryer member to be a func that returns aws.Retryer ([#1033](https://github.com/aws/aws-sdk-go-v2/pull/1033))
+ * Updates the SDK's references to Config.Retryer to be a function that returns aws.Retryer value. This ensures that custom retry options specified in the `aws.Config` are scoped to individual client instances.
+ * All API clients created with the config will call the `Config.Retryer` function to get an aws.Retryer.
+ * Removes duplicate `Retryer` interface from `retry` package. Single definition is `aws.Retryer` now.
+* `aws/middleware`: Updates `AddAttemptClockSkewMiddleware` to use appropriate `AddRecordResponseTiming` naming ([#1031](https://github.com/aws/aws-sdk-go-v2/pull/1031))
+ * Removes `ResponseMetadata` struct type, and adds its members to middleware metadata directly, to improve discoverability.
+* `config`: Updated the `WithRetryer` helper to take a function that returns an aws.Retryer ([#1033](https://github.com/aws/aws-sdk-go-v2/pull/1033))
+ * All API clients created with the config will call the `Config.Retryer` function to get an aws.Retryer.
+* `API Clients`: Fix SDK's API client enum constant name generation to have expected casing ([#1020](https://github.com/aws/aws-sdk-go-v2/pull/1020))
+ * This updates of the generated enum const value names in API client's `types` package to have the expected casing. Prior to this, enum names were being generated with lowercase names instead of camel case.
+* `API Clients`: Updates SDK's API client request middleware stack values to be scoped to individual operation call ([#1019](https://github.com/aws/aws-sdk-go-v2/pull/1019))
+ * The API client request middleware stack values were mistakenly allowed to escape to nested API operation calls. This broke the SDK's presigners.
+ * Stack values that should not escape are not scoped to the individual operation call.
+* `Multiple API Clients`: Unexported the API client's `WithEndpointResolver` this type wasn't intended to be exported ([#1051](https://github.com/aws/aws-sdk-go-v2/pull/1051))
+ * Using the `aws.Config.EndpointResolver` member for setting custom endpoint resolver instead.
+
+## New Features
+* `service/sts`: Add support for presigning GetCallerIdentity operation ([#1030](https://github.com/aws/aws-sdk-go-v2/pull/1030))
+ * Adds a PresignClient to the `sts` API client module. Use PresignGetCallerIdentity to obtain presigned URLs for the create presigned URLs for the GetCallerIdentity operation.
+ * Fixes [#1021](https://github.com/aws/aws-sdk-go-v2/issues/1021)
+* `aws/retry`: Add package documentation for retry package ([#1033](https://github.com/aws/aws-sdk-go-v2/pull/1033))
+ * Adds documentation for the retry package
+
+## Bug Fixes
+* `Multiple API Clients`: Fix SDK's generated serde for unmodeled operation input/output ([#1050](https://github.com/aws/aws-sdk-go-v2/pull/1050))
+ * Fixes [#1047](https://github.com/aws/aws-sdk-go-v2/issues/1047) by fixing the how the SDKs generated serialization and deserialization of API operations that did not have modeled input or output types. This caused the SDK to incorrectly attempt to deserialize response documents that were either empty, or contained unexpected data.
+* `service/s3`: Fix Tagging parameter not serialized correctly for presigned PutObject requests ([#1017](https://github.com/aws/aws-sdk-go-v2/pull/1017))
+ * Fixes the Tagging parameter incorrectly being serialized to the URL's query string instead of being signed as a HTTP request header.
+ * When using PresignPutObject make sure to add all signed headers returned by the method to your down stream's HTTP client's request. These headers must be included in the request, or the request will fail with signature errors.
+ * Fixes [#1016](https://github.com/aws/aws-sdk-go-v2/issues/1016)
+* `service/s3`: Fix Unmarshaling `GetObjectAcl` operation's Grantee type response ([#1034](https://github.com/aws/aws-sdk-go-v2/pull/1034))
+ * Updates the SDK's codegen for correctly deserializing XML attributes in tags with XML namespaces.
+ * Fixes [#1013](https://github.com/aws/aws-sdk-go-v2/issues/1013)
+* `service/s3`: Fix Unmarshaling `GetBucketLocation` operation's response ([#1027](https://github.com/aws/aws-sdk-go-v2/pull/1027))
+ * Fixes [#908](https://github.com/aws/aws-sdk-go-v2/issues/908)
+
+## Migrating from v2 preview SDK's v0.31.0 to v1.0.0
+
+### aws.Config Retryer member
+
+If your application sets the `Config.Retryer` member the application will need
+to be updated to set a function that returns an `aws.Retryer`. In addition, if
+your application used the `config.WithRetryer` helper a function that returns
+an `aws.Retryer` needs to be used.
+
+If your application used the `retry.Retryer` type, update to using the
+`aws.Retryer` type instead.
+
+### API Client enum value names
+
+If your application used the enum values in the API Client's `types` package between v0.31.0 and the latest version of the client module you may need to update the naming of the enum value. The enum value name casing were updated to camel case instead lowercased.
+
+# Release 2020-12-23
+
+We’re happy to announce the Release Candidate (RC) of the AWS SDK for Go v2.
+This RC follows the developer preview release of the AWS SDK for Go v2. The SDK
+has undergone a major rewrite from the v1 code base to incorporate your
+feedback and to take advantage of modern Go language features.
+
+## Documentation
+* Developer Guide: https://aws.github.io/aws-sdk-go-v2/docs/
+* API Reference docs: https://pkg.go.dev/github.com/aws/aws-sdk-go-v2
+* Migration Guide: https://aws.github.io/aws-sdk-go-v2/docs/migrating/
+
+## Breaking Changes
+* Dependency `github.com/awslabs/smithy-go` has been relocated to `github.com/aws/smithy-go`
+ * The `smithy-go` repository was moved from the `awslabs` GitHub organization to `aws`.
+ * `xml`, `httpbinding`, and `json` package relocated under `encoding` package.
+* The module `ec2imds` moved to `feature/ec2/imds` path ([#984](https://github.com/aws/aws-sdk-go-v2/pull/984))
+ * Moves the `ec2imds` feature module to be in common location as other SDK features.
+* `aws/signer/v4`: Refactor AWS Sigv4 Signer and options types to allow function options ([#955](https://github.com/aws/aws-sdk-go-v2/pull/955))
+ * Fixes [#917](https://github.com/aws/aws-sdk-go-v2/issues/917), [#960](https://github.com/aws/aws-sdk-go-v2/issues/960), [#958](https://github.com/aws/aws-sdk-go-v2/issues/958)
+* `aws`: CredentialCache type updated to require constructor function ([#946](https://github.com/aws/aws-sdk-go-v2/pull/946))
+ * Fixes [#940](https://github.com/aws/aws-sdk-go-v2/issues/940)
+* `credentials`: ExpiryWindow and Jitter moved from credential provider to `CredentialCache` ([#946](https://github.com/aws/aws-sdk-go-v2/pull/946))
+ * Moves ExpiryWindow and Jitter options to common option of the `CredentialCache` instead of duplicated across providers.
+ * Fixes [#940](https://github.com/aws/aws-sdk-go-v2/issues/940)
+* `config`: Ensure shared credentials file has precedence over shared config file ([#990](https://github.com/aws/aws-sdk-go-v2/pull/990))
+ * The shared config file was incorrectly overriding the shared credentials file when merging values.
+* `config`: Add `context.Context` to `LoadDefaultConfig` ([#951](https://github.com/aws/aws-sdk-go-v2/pull/951))
+ * Updates `config#LoadDefaultConfig` function to take `context.Context` as well as functional options for the `config#LoadOptions` type.
+ * Fixes [#926](https://github.com/aws/aws-sdk-go-v2/issues/926), [#819](https://github.com/aws/aws-sdk-go-v2/issues/819)
+* `aws`: Rename `NoOpRetryer` to `NopRetryer` to have consistent naming with rest of SDK ([#987](https://github.com/aws/aws-sdk-go-v2/pull/987))
+ * Fixes [#878](https://github.com/aws/aws-sdk-go-v2/issues/878)
+* `service/s3control`: Change `S3InitiateRestoreObjectOperation.ExpirationInDays` from value to pointer type ([#988](https://github.com/aws/aws-sdk-go-v2/pull/988))
+* `aws`: `ReaderSeekerCloser` and `WriteAtBuffer` have been relocated to `feature/s3/manager`.
+
+## New Features
+* *Waiters*: Add Waiter utilities for API clients ([aws/smithy-go#237](https://github.com/aws/smithy-go/pull/237))
+ * Your application can now use Waiter utilities to wait for AWS resources.
+* `feature/dynamodb/attributevalue`: Add Amazon DynamoDB Attribute value marshaler utility ([#948](https://github.com/aws/aws-sdk-go-v2/pull/948))
+ * Adds a utility for marshaling Go types too and from Amazon DynamoDB AttributeValues.
+ * Also includes utility for converting from Amazon DynamoDB Streams AttributeValues to Amazon DynamoDB AttributeValues.
+* `feature/dynamodbstreams/attributevalue`: Add Amazon DynamoDB Streams Attribute value marshaler utility ([#948](https://github.com/aws/aws-sdk-go-v2/pull/948))
+ * Adds a utility for marshaling Go types too and from Amazon DynamoDB Streams AttributeValues.
+ * Also includes utility for converting from Amazon DynamoDB AttributeValues to Amazon DynamoDB Streams AttributeValues.
+* `feature/dynamodb/expression`: Add Amazon DynamoDB expression utility ([#981](https://github.com/aws/aws-sdk-go-v2/pull/981))
+ * Adds the expression utility to the SDK for easily building Amazon DynamoDB operation expressions in code.
+
+## Bug Fixes
+* `service/s3`: Fix Presigner to configure client correctly for Amazon S3 ([#969](https://github.com/aws/aws-sdk-go-v2/pull/969))
+* service/s3: Fix deserialization of CompleteMultipartUpload ([#965](https://github.com/aws/aws-sdk-go-v2/pull/965)
+ * Fixes [#927](https://github.com/aws/aws-sdk-go-v2/issues/927)
+* `codegen`: Fix API client union serialization ([#979](https://github.com/aws/aws-sdk-go-v2/pull/979))
+ * Fixes [#978](https://github.com/aws/aws-sdk-go-v2/issues/978)
+
+## Service Client Highlights
+* API Clients have been bumped to version `v0.31.0`
+* Regenerate API Clients from updated API models adding waiter utilities, and union parameters.
+* `codegen`:
+ * Add documentation to union API parameters describing valid member types, and usage example ([aws/smithy-go#239](https://github.com/aws/smithy-go/pull/239))
+ * Normalize Metadata header map keys to be lower case ([aws/smithy-go#241](https://github.com/aws/smithy-go/pull/241)), ([#982](https://github.com/aws/aws-sdk-go-v2/pull/982))
+ * Fixes [#376](https://github.com/aws/aws-sdk-go-v2/issues/376) Amazon S3 Metadata parameters keys are always returned as lower case.
+ * Fix API client deserialization of XML based responses ([aws/smithy-go#245](https://github.com/aws/smithy-go/pull/245)), ([#992](https://github.com/aws/aws-sdk-go-v2/pull/992))
+ * Fixes [#910](https://github.com/aws/aws-sdk-go-v2/issues/910)
+* `service/s3`, `service/s3control`:
+ * Add support for reading `s3_use_arn_region` from shared config file ([#991](https://github.com/aws/aws-sdk-go-v2/pull/991))
+ * Add Utility for getting RequestID and HostID of response ([#983](https://github.com/aws/aws-sdk-go-v2/pull/983))
+
+
+## Other changes
+* Updates branch `HEAD` points from `master` to `main`.
+ * This should not impact your application, but if you have pull requests or forks of the SDK you may need to update the upstream branch your fork is based off of.
+
+## Migrating from v2 preview SDK's v0.30.0 to v0.31.0 release candidate
+
+### smithy-go module relocation
+
+If your application uses `smithy-go` utilities for request pipeline your application will need to be updated to refer to the new import path of `github.com/aws/smithy-go`. If you application did *not* use `smithy-go` utilities directly, your application will update automatically.
+
+### EC2 IMDS module relocation
+
+If your application used the `ec2imds` module, it has been relocated to `feature/ec2/imds`. Your application will need to update to the new import path, `github.com/aws/aws-sdk-go-v2/feature/ec2/imds`.
+
+### CredentialsCache Constructor and ExpiryWindow Options
+
+The `aws#CredentialsCache` type was updated, and a new constructor function, `NewCredentialsCache` was added. This function needs to be used to initialize the `CredentialCache`. The constructor also has function options to specify additional configuration, e.g. ExpiryWindow and Jitter.
+
+If your application was specifying the `ExpiryWindow` with the `credentials/stscreds#AssumeRoleOptions`, `credentials/stscreds#WebIdentityRoleOptions`, `credentials/processcreds#Options`, or `credentials/ec2rolecrds#Options` types the `ExpiryWindow` option will need to specified on the `CredentialsCache` constructor instead.
+
+### AWS Sigv4 Signer Refactor
+
+The `aws/signer/v4` package's `Signer.SignHTTP` and `Signer.PresignHTTP` methods were updated to take functional options. If your application provided a custom implementation for API client's `HTTPSignerV4` or `HTTPPresignerV4` interfaces, that implementation will need to be updated for the new function signature.
+
+### Configuration Loading
+
+The `config#LoadDefaultConfig` function has been updated to require a `context.Context` as the first parameter, with additional optional function options as variadic additional arguments. Your application will need to update its usage of `LoadDefaultConfig` to pass in `context.Context` as the first parameter. If your application used the `With...` helpers those should continue to work without issue.
+
+The v2 SDK corrects its behavior to be inline with the AWS CLI and other AWS SDKs. Refer to https://docs.aws.amazon.com/credref/latest/refdocs/overview.html for more information how to use the shared config and credentials files.
+
+
+# Release 2020-11-30
+
+## Breaking Change
+* `codegen`: Add support for slice and maps generated with value members instead of pointer ([#887](https://github.com/aws/aws-sdk-go-v2/pull/887))
+ * This update allow the SDK's code generation to be aware of API shapes and members that are not nullable, and can be rendered as value types by the code generation instead of pointer types.
+ * Several API client parameter types will change from pointer members to value members for slice, map, number and bool member types.
+ * See Migration notes for migrating to v0.30.0 with this change.
+* `aws/transport/http`: Move aws.BuildableHTTPClient to HTTP transport package ([#898](https://github.com/aws/aws-sdk-go-v2/pull/898))
+ * Moves the `BuildableHTTPClient` from the SDK's `aws` package to the `aws/transport/http` package as `BuildableClient` to with other HTTP specific utilities.
+* `feature/cloudfront/sign`: Add CloudFront sign feature as module ([#884](https://github.com/aws/aws-sdk-go-v2/pull/884))
+ * Moves `service/cloudfront/sign` package out of the `cloudfront` module, and into its own module as `github.com/aws/aws-sdk-go-v2/feature/cloudfront/sign`.
+
+## New Features
+* `config`: Add a WithRetryer provider helper to the config loader ([#897](https://github.com/aws/aws-sdk-go-v2/pull/897))
+ * Adds a `WithRetryer` configuration provider to the config loader as a convenience helper to set the `Retryer` on the `aws.Config` when its being loaded.
+* `config`: Default to TLS 1.2 for HTTPS requests ([#892](https://github.com/aws/aws-sdk-go-v2/pull/892))
+ * Updates the SDK's default HTTP client to use TLS 1.2 as the minimum TLS version for all HTTPS requests by default.
+
+## Bug Fixes
+* `config`: Fix AWS_CA_BUNDLE usage while loading default config ([#912](https://github.com/aws/aws-sdk-go-v2/pull/))
+ * Fixes the `LoadDefaultConfig`'s configuration provider order to correctly load a custom HTTP client prior to configuring the client for `AWS_CA_BUNDLE` environment variable.
+* `service/s3`: Fix signature mismatch error for s3 ([#913](https://github.com/aws/aws-sdk-go-v2/pull/913))
+ * Fixes ([#883](https://github.com/aws/aws-sdk-go-v2/issues/883))
+* `service/s3control`:
+ * Fix HostPrefix addition behavior for s3control ([#882](https://github.com/aws/aws-sdk-go-v2/pull/882))
+ * Fixes ([#863](https://github.com/aws/aws-sdk-go-v2/issues/863))
+ * Fix s3control error deserializer ([#875](https://github.com/aws/aws-sdk-go-v2/pull/875))
+ * Fixes ([#864](https://github.com/aws/aws-sdk-go-v2/issues/864))
+
+## Service Client Highlights
+* Pagination support has been added to supported APIs. See [Using Operation Paginators](https://aws.github.io/aws-sdk-go-v2/docs/making-requests/#using-operation-paginators) in the Developer Guide. ([#885](https://github.com/aws/aws-sdk-go-v2/pull/885))
+* Logging support has been added to service clients. See [Logging](https://aws.github.io/aws-sdk-go-v2/docs/configuring-sdk/logging/) in the Developer Guide. ([#872](https://github.com/aws/aws-sdk-go-v2/pull/872))
+* `service`: Add support for pre-signed URL clients for S3, RDS, EC2 service ([#888](https://github.com/aws/aws-sdk-go-v2/pull/888))
+ * `service/s3`: operations `PutObject` and `GetObject` are now supported with s3 pre-signed url client.
+ * `service/ec2`: operation `CopySnapshot` is now supported with ec2 pre-signed url client.
+ * `service/rds`: operations `CopyDBSnapshot`, `CreateDBInstanceReadReplica`, `CopyDBClusterSnapshot`, `CreateDBCluster` are now supported with rds pre-signed url client.
+* `service/s3`: Add support for S3 access point and S3 on outposts access point ARNs ([#870](https://github.com/aws/aws-sdk-go-v2/pull/870))
+* `service/s3control`: Adds support for S3 on outposts access point and S3 on outposts bucket ARNs ([#870](https://github.com/aws/aws-sdk-go-v2/pull/870))
+
+## Migrating from v2 preview SDK's v0.29.0 to v0.30.0
+
+### aws.BuildableHTTPClient move
+The `aws`'s `BuildableHTTPClient` HTTP client implementation was moved to `aws/transport/http` as `BuildableClient`. If your application used the `aws.BuildableHTTPClient` type, update it to use the `BuildableClient` in the `aws/transport/http` package.
+
+### Slice and Map API member types
+This release includes several code generation updates for API client's slice map members. Using API modeling metadata the Slice and map members are now generated as value types instead of pointer types. For your application this means that for these types, the SDK no longer will have pointer member types, and have value member types.
+
+To migrate to this change you'll need to remove the pointer handling for slice and map members, and instead use value type handling of the member values.
+
+### Boolean and Number API member types
+Similar to the slice and map API member types being generated as value, the SDK's code generation now has metadata where the SDK can generate boolean and number members as value type instead of pointer types.
+
+To migrate to this change you'll need to remove the pointer handling for numbers and boolean member types, and instead use value handling.
+
+# Release 2020-10-30
+
+## New Features
+* Adds HostnameImmutable flag on aws.Endpoint to direct SDK if the associated endpoint is modifiable.([#848](https://github.com/aws/aws-sdk-go-v2/pull/848))
+
+## Bug Fixes
+* Fix SDK handling of xml based services - xml namespaces ([#858](https://github.com/aws/aws-sdk-go-v2/pull/858))
+ * Fixes ([#850](https://github.com/aws/aws-sdk-go-v2/issues/850))
+
+## Service Client Highlights
+* API Clients have been bumped to version `v0.29.0`
+ * Regenerate API Clients from update API models.
+* Improve client doc generation.
+
+## Core SDK Highlights
+* Dependency Update: Updated SDK dependencies to their latest versions.
+
+## Migrating from v2 preview SDK's v0.28.0 to v0.29.0
+* API Clients ResolverOptions type renamed to EndpointResolverOptions
+
+# Release 2020-10-26
+
+## New Features
+* `service/s3`: Add support for Accelerate, and Dualstack ([#836](https://github.com/aws/aws-sdk-go-v2/pull/836))
+* `service/s3control`: Add support for Dualstack ([#836](https://github.com/aws/aws-sdk-go-v2/pull/836))
+
+## Service Client Highlights
+* API Clients have been bumped to version `v0.28.0`
+ * Regenerate API Clients from update API models.
+* `service/s3`: Add support for Accelerate, and Dualstack ([#836](https://github.com/aws/aws-sdk-go-v2/pull/836))
+* `service/s3control`: Add support for Dualstack ([#836](https://github.com/aws/aws-sdk-go-v2/pull/836))
+* `service/route53`: Fix sanitizeURL customization to handle leading slash(`/`) [#846](https://github.com/aws/aws-sdk-go-v2/pull/846)
+ * Fixes [#843](https://github.com/aws/aws-sdk-go-v2/issues/843)
+* `service/route53`: Fix codegen to correctly look for operations that need sanitize url ([#851](https://github.com/aws/aws-sdk-go-v2/pull/851))
+
+## Core SDK Highlights
+* `aws/protocol/restjson`: Fix unexpected JSON error response deserialization ([#837](https://github.com/aws/aws-sdk-go-v2/pull/837))
+ * Fixes [#832](https://github.com/aws/aws-sdk-go-v2/issues/832)
+* `example/service/s3/listobjects`: Add example for Amazon S3 ListObjectsV2 ([#838](https://github.com/aws/aws-sdk-go-v2/pull/838))
+
+# Release 2020-10-16
+
+## New Features
+* `feature/s3/manager`:
+ * Initial `v0.1.0` release
+ * Add the Amazon S3 Upload and Download transfer manager ([#802](https://github.com/aws/aws-sdk-go-v2/pull/802))
+
+## Service Client Highlights
+* Clients have been bumped to version `v0.27.0`
+* `service/machinelearning`: Add customization for setting client endpoint with PredictEndpoint value if set ([#782](https://github.com/aws/aws-sdk-go-v2/pull/782))
+* `service/s3`: Fix empty response body deserialization in case of error response ([#801](https://github.com/aws/aws-sdk-go-v2/pull/801))
+ * Fixes xml deserialization util to correctly handle empty response body in case of an error response.
+* `service/s3`: Add customization to auto fill Content-Md5 request header for Amazon S3 operations ([#812](https://github.com/aws/aws-sdk-go-v2/pull/812))
+* `service/s3`: Add fallback to using HTTP status code for error code ([#818](https://github.com/aws/aws-sdk-go-v2/pull/818))
+ * Adds falling back to using the HTTP status code to create a API Error code when not error code is received from the service, such as HeadObject.
+* `service/route53`: Add support for deserialzing `InvalidChangeBatch` API error ([#792](https://github.com/aws/aws-sdk-go-v2/pull/792))
+* `codegen`: Remove API client `Options` getter methods ([#788](https://github.com/aws/aws-sdk-go-v2/pull/788))
+* `codegen`: Regenerate API Client modeled endpoints ([#791](https://github.com/aws/aws-sdk-go-v2/pull/791))
+* `codegen`: Sort API Client struct member paramaters by required and alphabetical ([#787](https://github.com/aws/aws-sdk-go-v2/pull/787))
+* `codegen`: Add package docs to API client modules ([#821](https://github.com/aws/aws-sdk-go-v2/pull/821))
+* `codegen`: Rename `smithy-go`'s `smithy.OperationError` to `smithy.OperationInvokeError`.
+
+## Core SDK Highlights
+* `config`:
+ * Bumped to `v0.2.0`
+ * Refactor Config Module, Add Config Package Documentation and Examples, Improve Overall SDK Readme ([#822](https://github.com/aws/aws-sdk-go-v2/pull/822))
+* `credentials`:
+ * Bumped to `v0.1.2`
+ * Strip Monotonic Clock Readings when Comparing Credential Expiry Time ([#789](https://github.com/aws/aws-sdk-go-v2/pull/789))
+* `ec2imds`:
+ * Bumped to `v0.1.2`
+ * Fix refreshing API token if expired ([#789](https://github.com/aws/aws-sdk-go-v2/pull/789))
+
+## Migrating from v0.26.0 to v0.27.0
+
+#### Configuration
+
+The `config` module's exported types were trimmed down to add clarity and reduce confusion. Additional changes to the `config` module' helpers.
+
+* Refactored `WithCredentialsProvider`, `WithHTTPClient`, and `WithEndpointResolver` to functions instead of structs.
+* Removed `MFATokenFuncProvider`, use `AssumeRoleCredentialOptionsProvider` for setting options for `stscreds.AssumeRoleOptions`.
+* Renamed `WithWebIdentityCredentialProviderOptions` to `WithWebIdentityRoleCredentialOptions`
+* Renamed `AssumeRoleCredentialProviderOptions` to `AssumeRoleCredentialOptionsProvider`
+* Renamed `EndpointResolverFuncProvider` to `EndpointResolverProvider`
+
+#### API Client
+* API Client `Options` type getter methods have been removed. Use the struct members instead.
+* The error returned by API Client operations was renamed from `smithy.OperationError` to `smithy.OperationInvokeError`.
+
+# Release 2020-09-30
+
+## Service Client Highlights
+* Service clients have been bumped to `v0.26.0` simplify the documentation experience when using [pkg.go.dev](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2).
+* `service/s3`: Disable automatic decompression of getting Amazon S3 objects with the `Content-Encoding: gzip` metadata header. ([#748](https://github.com/aws/aws-sdk-go-v2/pull/748))
+ * This changes the SDK's default behavior with regard to making S3 API calls. The client will no longer automatically set the `Accept-Encoding` HTTP request header, nor will it automatically decompress the gzipped response when the `Content-Encoding: gzip` response header was received.
+ * If you'd like the client to sent the `Accept-Encoding: gzip` request header, you can add this header to the API operation method call with the [SetHeaderValue](https://pkg.go.dev/github.com/awslabs/smithy-go/transport/http#SetHeaderValue). middleware helper.
+* `service/cloudfront/sign`: Fix cloudfront example usage of SignWithPolicy ([#673](https://github.com/aws/aws-sdk-go-v2/pull/673))
+ * Fixes [#671](https://github.com/aws/aws-sdk-go-v2/issues/671) documentation typo by correcting the usage of `SignWithPolicy`.
+
+## Core SDK Highlights
+* SDK core module released at `v0.26.0`
+* `config` module released at `v0.1.1`
+* `credentials` module released at `v0.1.1`
+* `ec2imds` module released at `v0.1.1`
+
+
+# Release 2020-09-28
+## Announcements
+We’re happy to share the updated clients for the v0.25.0 preview version of the AWS SDK for Go V2.
+
+The updated clients leverage new developments and advancements within AWS and the Go software ecosystem at large since
+our original preview announcement. Using the new clients will be a bit different than before. The key differences are:
+simplified API operation invocation, performance improvements, support for error wrapping, and a new middleware architecture.
+So below we have a guided walkthrough to help try it out and share your feedback in order to better influence the features
+you’d like to see in the GA version.
+
+See [Announcement Blog Post](https://aws.amazon.com/blogs/developer/client-updates-in-the-preview-version-of-the-aws-sdk-for-go-v2/) for more details.
+
+## Service Client Highlights
+* Initial service clients released at version `v0.1.0`
+## Core SDK Highlights
+* SDK core module released at `v0.25.0`
+* `config` module released at `v0.1.0`
+* `credentials` module released at `v0.1.0`
+* `ec2imds` module released at `v0.1.0`
+
+## Migrating from v2 preview SDK's v0.24.0 to v0.25.0
+
+#### Design changes
+
+The v2 preview SDK `v0.25.0` release represents a significant stepping stone bringing the v2 SDK closer to its target design and usability. This release includes significant breaking changes to the v2 preview SDK. The updates in the `v0.25.0` release focus on refactoring and modularization of the SDK’s API clients to use the new [client design](https://github.com/aws/aws-sdk-go-v2/issues/438), updated request pipeline (aka [middleware](https://pkg.go.dev/github.com/awslabs/smithy-go/middleware)), refactored [credential providers](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/credentials), and [configuration loading](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/config) packages.
+
+We've also bumped the minimum supported Go version with this release. Starting with v0.25.0 the SDK requires a minimum version of Go `v1.15`.
+
+As a part of the refactoring done to v2 preview SDK some components have not been included in this update. The following is a non exhaustive list of features that are not available.
+
+* API Paginators - [#439](https://github.com/aws/aws-sdk-go-v2/issues/439)
+* API Waiters - [#442](https://github.com/aws/aws-sdk-go-v2/issues/442)
+* Presign URL - [#794](https://github.com/aws/aws-sdk-go-v2/issues/794)
+* Amazon S3 Upload and Download manager - [#802](https://github.com/aws/aws-sdk-go-v2/pull/802)
+* Amazon DynamoDB's AttributeValue marshaler, and Expression package - [#790](https://github.com/aws/aws-sdk-go-v2/issues/790)
+* Debug Logging - [#594](https://github.com/aws/aws-sdk-go-v2/issues/594)
+
+We expect additional breaking changes to the v2 preview SDK in the coming releases. We expect these changes to focus on organizational, naming, and hardening the SDK's design for future feature capabilities after it is released for general availability.
+
+
+#### Relocated Packages
+
+In this release packages within the SDK were relocated, and in some cases those packages were converted to Go modules. The following is a list of packages have were relocated.
+
+* `github.com/aws/aws-sdk-go-v2/aws/external` => `github.com/aws/aws-sdk-go-v2/config` module
+* `github.com/aws/aws-sdk-go-v2/aws/ec2metadata` => `github.com/aws/aws-sdk-go-v2/ec2imds` module
+
+The `github.com/aws/aws-sdk-go-v2/credentials` module contains refactored credentials providers.
+
+* `github.com/aws/aws-sdk-go-v2/ec2rolecreds` => `github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds`
+* `github.com/aws/aws-sdk-go-v2/endpointcreds` => `github.com/aws/aws-sdk-go-v2/credentials/endpointcreds`
+* `github.com/aws/aws-sdk-go-v2/processcreds` => `github.com/aws/aws-sdk-go-v2/credentials/processcreds`
+* `github.com/aws/aws-sdk-go-v2/stscreds` => `github.com/aws/aws-sdk-go-v2/credentials/stscreds`
+
+
+#### Modularization
+
+New modules were added to the v2 preview SDK to allow the components to be versioned independently from each other. This allows your application to depend on specific versions of an API client module, and take discrete updates from the SDK core and other API client modules as desired.
+
+* [github.com/aws/aws-sdk-go-v2/config](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/config)
+* [github.com/aws/aws-sdk-go-v2/credentials](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/credentials)
+* Module for each API client, e.g. [github.com/aws/aws-sdk-go-v2/service/s3](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/service/s3)
+
+
+#### API Clients
+
+The following is a list of the major changes to the API client modules
+
+* Removed paginators: we plan to add these back once they are implemented to integrate with the SDK's new API client design.
+* Removed waiters: we need to further investigate how the V2 SDK should expose waiters, and how their behavior should be modeled.
+* API Clients are now Go modules. When migrating to the v2 preview SDK `v0.25.0`, you'll need to add the API client's module to your application's go.mod file.
+* API parameter nested types have been moved to a `types` package within the API client's module, e.g. `github.com/aws/aws-sdk-go-v2/service/s3/types` These types were moved to improve documentation and discovery of the API client, operation, and input/output types. For example Amazon S3's ListObject's operation [ListObjectOutput.Contents](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/service/s3/#ListObjectsOutput) input parameter is a slice of [types.Object](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/service/s3/types#Object).
+* The client operation method has been renamed, removing the `Request` suffix. The method now invokes the operation instead of constructing a request, which needed to be invoked separately. The operation methods were also expanded to include functional options for providing operation specific configuration, such as modifying the request pipeline.
+
+```go
+result, err := client.Scan(context.TODO(), &dynamodb.ScanInput{
+ TableName: aws.String("exampleTable"),
+}, func(o *Options) {
+ // Limit operation calls to only 1 attempt.
+ o.Retryer = retry.AddWithMaxAttempts(o.Retryer, 1)
+})
+```
+
+
+#### Configuration
+
+In addition to the `github.com/aws/aws-sdk-go-v2/aws/external` package being made a module at `github.com/aws/aws-sdk-go-v2/config`, the `LoadDefaultAWSConfig` function was renamed to `LoadDefaultConfig`.
+
+The `github.com/aws/aws-sdk-go-v2/aws/defaults` package has been removed. Its components have been migrated to the `github.com/aws/aws-sdk-go-v2/aws` package, and `github.com/aws/aws-sdk-go-v2/config` module.
+
+
+#### Error Handling
+
+The `github.com/aws/aws-sdk-go-v2/aws/awserr` package was removed as a part of the SDK error handling refactor. The SDK now uses typed errors built around [Go v1.13](https://golang.org/doc/go1.13#error_wrapping)'s [errors.As](https://pkg.go.dev/errors#As) and [errors.Unwrap](https://pkg.go.dev/errors#Unwrap) features. All SDK error types that wrap other errors implement the `Unwrap` method. Generic v2 preview SDK errors created with `fmt.Errorf` use `%w` to wrap the underlying error.
+
+The SDK API clients now include generated public error types for errors modeled for an API. The SDK will automatically deserialize the error response from the API into the appropriate error type. Your application should use `errors.As` to check if the returned error matches one it is interested in. Your application can also use the generic interface [smithy.APIError](https://pkg.go.dev/github.com/awslabs/smithy-go/#APIError) to test if the API client's operation method returned an API error, but not check against a specific error.
+
+API client errors returned to the caller will use error wrapping to layer the error values. This allows underlying error types to be specific to their use case, and the SDK's more generic error types to wrap the underlying error.
+
+For example, if an [Amazon DynamoDB](https://aws.amazon.com/dynamodb/) [Scan](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/service/dynamodb#Scan) operation call cannot find the `TableName` requested, the error returned will contain [dynamodb.ResourceNotFoundException](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/service/dynamodb/types#ResourceNotFoundException). The SDK will return this error value wrapped in a couple layers, with each layer adding additional contextual information such as [ResponseError](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/aws/transport/http#ResponseError) for AWS HTTP response error metadata , and [smithy.OperationError](https://pkg.go.dev/github.com/awslabs/smithy-go/#OperationError) for API operation call metadata.
+
+```go
+result, err := client.Scan(context.TODO(), params)
+if err != nil {
+ // To get a specific API error
+ var notFoundErr *types.ResourceNotFoundException
+ if errors.As(err, ¬FoundErr) {
+ log.Printf("scan failed because the table was not found, %v",
+ notFoundErr.ErrorMessage())
+ }
+
+ // To get any API error
+ var apiErr smithy.APIError
+ if errors.As(err, &apiErr) {
+ log.Printf("scan failed because of an API error, Code: %v, Message: %v",
+ apiErr.ErrorCode(), apiErr.ErrorMessage())
+ }
+
+ // To get the AWS response metadata, such as RequestID
+ var respErr *awshttp.ResponseError // Using import alias "awshttp" for package github.com/aws/aws-sdk-go-v2/aws/transport/http
+ if errors.As(err, &respErr) {
+ log.Printf("scan failed with HTTP status code %v, Request ID %v and error %v",
+ respErr.HTTPStatusCode(), respErr.ServiceRequestID(), respErr)
+ }
+
+ return err
+}
+```
+
+Logging an error value will include information from each wrapped error. For example, the following is a mock error logged for a Scan operation call that failed because the table was not found.
+
+> 2020/10/15 16:03:37 operation error DynamoDB: Scan, https response error StatusCode: 400, RequestID: ABCREQUESTID123, ResourceNotFoundException: Requested resource not found
+
+
+#### Endpoints
+
+The `github.com/aws/aws-sdk-go-v2/aws/endpoints` has been removed from the SDK, along with all exported endpoint definitions and iteration behavior. Each generated API client now includes its own endpoint definition internally to the module.
+
+API clients can optionally be configured with a generic [aws.EndpointResolver](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/aws#EndpointResolver) via the [aws.Config.EndpointResolver](https://pkg.go.dev/github.com/aws/aws-sdk-go-v2/aws#Config.EndpointResolver). If the API client is not configured with a custom endpoint resolver it will defer to the endpoint resolver the client module was generated with.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/CODE_OF_CONDUCT.md b/vendor/github.com/aws/aws-sdk-go-v2/CODE_OF_CONDUCT.md
new file mode 100644
index 000000000000..3b64466870c9
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/CODE_OF_CONDUCT.md
@@ -0,0 +1,4 @@
+## Code of Conduct
+This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct).
+For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact
+opensource-codeofconduct@amazon.com with any additional questions or comments.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/CONTRIBUTING.md b/vendor/github.com/aws/aws-sdk-go-v2/CONTRIBUTING.md
new file mode 100644
index 000000000000..c2fc3b8f5b0a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/CONTRIBUTING.md
@@ -0,0 +1,178 @@
+# Contributing to the AWS SDK for Go
+
+Thank you for your interest in contributing to the AWS SDK for Go!
+We work hard to provide a high-quality and useful SDK, and we greatly value
+feedback and contributions from our community. Whether it's a bug report,
+new feature, correction, or additional documentation, we welcome your issues
+and pull requests. Please read through this document before submitting any
+[issues] or [pull requests][pr] to ensure we have all the necessary information to
+effectively respond to your bug report or contribution.
+
+Jump To:
+
+* [Bug Reports](#bug-reports)
+* [Feature Requests](#feature-requests)
+* [Code Contributions](#code-contributions)
+
+
+## How to contribute
+
+*Before you send us a pull request, please be sure that:*
+
+1. You're working from the latest source on the master branch.
+2. You check existing open, and recently closed, pull requests to be sure
+ that someone else hasn't already addressed the problem.
+3. You create an issue before working on a contribution that will take a
+ significant amount of your time.
+
+*Creating a Pull Request*
+
+1. Fork the repository.
+2. In your fork, make your change in a branch that's based on this repo's master branch.
+3. Commit the change to your fork, using a clear and descriptive commit message.
+4. Create a pull request, answering any questions in the pull request form.
+
+For contributions that will take a significant amount of time, open a new
+issue to pitch your idea before you get started. Explain the problem and
+describe the content you want to see added to the documentation. Let us know
+if you'll write it yourself or if you'd like us to help. We'll discuss your
+proposal with you and let you know whether we're likely to accept it.
+
+## Bug Reports
+
+You can file bug reports against the SDK on the [GitHub issues][issues] page.
+
+If you are filing a report for a bug or regression in the SDK, it's extremely
+helpful to provide as much information as possible when opening the original
+issue. This helps us reproduce and investigate the possible bug without having
+to wait for this extra information to be provided. Please read the following
+guidelines prior to filing a bug report.
+
+1. Search through existing [issues][] to ensure that your specific issue has
+ not yet been reported. If it is a common issue, it is likely there is
+ already a bug report for your problem.
+
+2. Ensure that you have tested the latest version of the SDK. Although you
+ may have an issue against an older version of the SDK, we cannot provide
+ bug fixes for old versions. It's also possible that the bug may have been
+ fixed in the latest release.
+
+3. Provide as much information about your environment, SDK version, and
+ relevant dependencies as possible. For example, let us know what version
+ of Go you are using, which and version of the operating system, and the
+ the environment your code is running in. e.g Container.
+
+4. Provide a minimal test case that reproduces your issue or any error
+ information you related to your problem. We can provide feedback much
+ more quickly if we know what operations you are calling in the SDK. If
+ you cannot provide a full test case, provide as much code as you can
+ to help us diagnose the problem. Any relevant information should be provided
+ as well, like whether this is a persistent issue, or if it only occurs
+ some of the time.
+
+## Feature Requests
+
+Open an [issue][issues] with the following:
+
+* A short, descriptive title. Ideally, other community members should be able
+ to get a good idea of the feature just from reading the title.
+* A detailed description of the the proposed feature.
+ * Why it should be added to the SDK.
+ * If possible, example code to illustrate how it should work.
+* Use Markdown to make the request easier to read;
+* If you intend to implement this feature, indicate that you'd like to the issue to be assigned to you.
+
+## Code Contributions
+
+We are always happy to receive code and documentation contributions to the SDK.
+Please be aware of the following notes prior to opening a pull request:
+
+1. The SDK is released under the [Apache license][license]. Any code you submit
+ will be released under that license. For substantial contributions, we may
+ ask you to sign a [Contributor License Agreement (CLA)][cla].
+
+2. If you would like to implement support for a significant feature that is not
+ yet available in the SDK, please talk to us beforehand to avoid any
+ duplication of effort.
+
+3. Wherever possible, pull requests should contain tests as appropriate.
+ Bugfixes should contain tests that exercise the corrected behavior (i.e., the
+ test should fail without the bugfix and pass with it), and new features
+ should be accompanied by tests exercising the feature.
+
+4. Pull requests that contain failing tests will not be merged until the test
+ failures are addressed. Pull requests that cause a significant drop in the
+ SDK's test coverage percentage are unlikely to be merged until tests have
+ been added.
+
+5. The JSON files under the SDK's `models` folder are sourced from outside the SDK.
+ Such as `models/apis/ec2/2016-11-15/api.json`. We will not accept pull requests
+ directly on these models. If you discover an issue with the models please
+ create a [GitHub issue][issues] describing the issue.
+
+### Testing
+
+To run the tests locally, running the `make unit` command will `go get` the
+SDK's testing dependencies, and run vet, link and unit tests for the SDK.
+
+```
+make unit
+```
+
+Standard go testing functionality is supported as well. To test SDK code that
+is tagged with `codegen` you'll need to set the build tag in the go test
+command. The `make unit` command will do this automatically.
+
+```
+go test -tags codegen ./private/...
+```
+
+See the `Makefile` for additional testing tags that can be used in testing.
+
+To test on multiple platform the SDK includes several DockerFiles under the
+`awstesting/sandbox` folder, and associated make recipes to to execute
+unit testing within environments configured for specific Go versions.
+
+```
+make sandbox-test-go18
+```
+
+To run all sandbox environments use the following make recipe
+
+```
+# Optionally update the Go tip that will be used during the batch testing
+make update-aws-golang-tip
+
+# Run all SDK tests for supported Go versions in sandboxes
+make sandbox-test
+```
+
+In addition the sandbox environment include make recipes for interactive modes
+so you can run command within the Docker container and context of the SDK.
+
+```
+make sandbox-go18
+```
+
+### Changelog Documents
+
+You can see all release changes in the `CHANGELOG.md` file at the root of the
+repository. The release notes added to this file will contain service client
+updates, and major SDK changes. When submitting a pull request please include an entry in `CHANGELOG_PENDING.md` under the appropriate changelog type so your changelog entry is included on the following release.
+
+#### Changelog Types
+
+* `SDK Features` - For major additive features, internal changes that have
+outward impact, or updates to the SDK foundations. This will result in a minor
+version change.
+* `SDK Enhancements` - For minor additive features or incremental sized changes.
+This will result in a patch version change.
+* `SDK Bugs` - For minor changes that resolve an issue. This will result in a
+patch version change.
+
+[issues]: https://github.com/aws/aws-sdk-go/issues
+[pr]: https://github.com/aws/aws-sdk-go/pulls
+[license]: http://aws.amazon.com/apache2.0/
+[cla]: http://en.wikipedia.org/wiki/Contributor_License_Agreement
+[releasenotes]: https://github.com/aws/aws-sdk-go/releases
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/DESIGN.md b/vendor/github.com/aws/aws-sdk-go-v2/DESIGN.md
new file mode 100644
index 000000000000..8490c7d67362
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/DESIGN.md
@@ -0,0 +1,15 @@
+Open Discussions
+---
+The following issues are currently open for community feedback.
+All discourse must adhere to the [Code of Conduct] policy.
+
+* [Refactoring API Client Paginators](https://github.com/aws/aws-sdk-go-v2/issues/439)
+* [Refactoring API Client Waiters](https://github.com/aws/aws-sdk-go-v2/issues/442)
+* [Refactoring API Client Enums and Types to Discrete Packages](https://github.com/aws/aws-sdk-go-v2/issues/445)
+* [SDK Modularization](https://github.com/aws/aws-sdk-go-v2/issues/444)
+
+Past Discussions
+---
+The issues listed here are for documentation purposes, and is used to capture issues and their associated discussions.
+
+[Code of Conduct]: https://github.com/aws/aws-sdk-go-v2/blob/master/CODE_OF_CONDUCT.md
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/Makefile b/vendor/github.com/aws/aws-sdk-go-v2/Makefile
new file mode 100644
index 000000000000..d463fbcc50d3
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/Makefile
@@ -0,0 +1,491 @@
+# Lint rules to ignore
+LINTIGNORESINGLEFIGHT='internal/sync/singleflight/singleflight.go:.+error should be the last type'
+
+UNIT_TEST_TAGS=
+BUILD_TAGS=-tags "example,codegen,integration,ec2env,perftest"
+
+SMITHY_GO_SRC ?= $(shell pwd)/../smithy-go
+
+SDK_MIN_GO_VERSION ?= 1.15
+
+EACHMODULE_FAILFAST ?= true
+EACHMODULE_FAILFAST_FLAG=-fail-fast=${EACHMODULE_FAILFAST}
+
+EACHMODULE_CONCURRENCY ?= 1
+EACHMODULE_CONCURRENCY_FLAG=-c ${EACHMODULE_CONCURRENCY}
+
+EACHMODULE_SKIP ?=
+EACHMODULE_SKIP_FLAG=-skip="${EACHMODULE_SKIP}"
+
+EACHMODULE_FLAGS=${EACHMODULE_CONCURRENCY_FLAG} ${EACHMODULE_FAILFAST_FLAG} ${EACHMODULE_SKIP_FLAG}
+
+# SDK's Core and client packages that are compatible with Go 1.9+.
+SDK_CORE_PKGS=./aws/... ./internal/...
+SDK_CLIENT_PKGS=./service/...
+SDK_COMPA_PKGS=${SDK_CORE_PKGS} ${SDK_CLIENT_PKGS}
+
+# SDK additional packages that are used for development of the SDK.
+SDK_EXAMPLES_PKGS=
+SDK_ALL_PKGS=${SDK_COMPA_PKGS} ${SDK_EXAMPLES_PKGS}
+
+RUN_NONE=-run NONE
+RUN_INTEG=-run '^TestInteg_'
+
+CODEGEN_RESOURCES_PATH=$(shell pwd)/codegen/smithy-aws-go-codegen/src/main/resources/software/amazon/smithy/aws/go/codegen
+CODEGEN_API_MODELS_PATH=$(shell pwd)/codegen/sdk-codegen/aws-models
+ENDPOINTS_JSON=${CODEGEN_RESOURCES_PATH}/endpoints.json
+ENDPOINT_PREFIX_JSON=${CODEGEN_RESOURCES_PATH}/endpoint-prefix.json
+
+LICENSE_FILE=$(shell pwd)/LICENSE.txt
+
+SMITHY_GO_VERSION ?=
+PRE_RELEASE_VERSION ?=
+RELEASE_MANIFEST_FILE ?=
+RELEASE_CHGLOG_DESC_FILE ?=
+
+REPOTOOLS_VERSION ?= latest
+REPOTOOLS_MODULE = github.com/awslabs/aws-go-multi-module-repository-tools
+REPOTOOLS_CMD_ANNOTATE_STABLE_GEN = ${REPOTOOLS_MODULE}/cmd/annotatestablegen@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_MAKE_RELATIVE = ${REPOTOOLS_MODULE}/cmd/makerelative@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_CALCULATE_RELEASE = ${REPOTOOLS_MODULE}/cmd/calculaterelease@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_UPDATE_REQUIRES = ${REPOTOOLS_MODULE}/cmd/updaterequires@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_UPDATE_MODULE_METADATA = ${REPOTOOLS_MODULE}/cmd/updatemodulemeta@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_GENERATE_CHANGELOG = ${REPOTOOLS_MODULE}/cmd/generatechangelog@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_CHANGELOG = ${REPOTOOLS_MODULE}/cmd/changelog@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_TAG_RELEASE = ${REPOTOOLS_MODULE}/cmd/tagrelease@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_EDIT_MODULE_DEPENDENCY = ${REPOTOOLS_MODULE}/cmd/editmoduledependency@${REPOTOOLS_VERSION}
+
+REPOTOOLS_CALCULATE_RELEASE_VERBOSE ?= false
+REPOTOOLS_CALCULATE_RELEASE_VERBOSE_FLAG=-v=${REPOTOOLS_CALCULATE_RELEASE_VERBOSE}
+
+REPOTOOLS_CALCULATE_RELEASE_ADDITIONAL_ARGS ?=
+
+ifneq ($(PRE_RELEASE_VERSION),)
+ REPOTOOLS_CALCULATE_RELEASE_ADDITIONAL_ARGS += -preview=${PRE_RELEASE_VERSION}
+endif
+
+.PHONY: all
+all: generate unit
+
+###################
+# Code Generation #
+###################
+.PHONY: generate smithy-generate smithy-build smithy-build-% smithy-clean smithy-go-publish-local format \
+gen-config-asserts gen-repo-mod-replace gen-mod-replace-smithy gen-mod-dropreplace-smithy gen-aws-ptrs tidy-modules-% \
+add-module-license-files sync-models sync-endpoints-model sync-endpoints.json clone-v1-models gen-endpoint-prefix.json \
+sync-api-models copy-attributevalue-feature min-go-version-% update-requires smithy-annotate-stable \
+update-module-metadata download-modules-%
+
+generate: smithy-generate update-requires gen-repo-mod-replace update-module-metadata smithy-annotate-stable \
+gen-config-asserts copy-attributevalue-feature gen-mod-dropreplace-smithy min-go-version-. tidy-modules-. \
+add-module-license-files gen-aws-ptrs format
+
+smithy-generate:
+ cd codegen && ./gradlew clean build -Plog-tests && ./gradlew clean
+
+smithy-build: gen-repo-mod-replace
+ cd codegen && ./gradlew clean build -Plog-tests
+
+smithy-build-%: gen-repo-mod-replace
+ @# smithy-build- command that uses the pattern to define build filter that
+ @# the smithy API model service id starts with. Strips off the
+ @# "smithy-build-".
+ @#
+ @# e.g. smithy-build-com.amazonaws.rds
+ @# e.g. smithy-build-com.amazonaws.rds#AmazonRDSv19
+ cd codegen && \
+ SMITHY_GO_BUILD_API="$(subst smithy-build-,,$@)" ./gradlew clean build -Plog-tests
+
+smithy-annotate-stable:
+ go run ${REPOTOOLS_CMD_ANNOTATE_STABLE_GEN}
+
+smithy-clean:
+ cd codegen && ./gradlew clean
+
+smithy-go-publish-local:
+ rm -rf /tmp/smithy-go-local
+ git clone https://github.com/aws/smithy-go /tmp/smithy-go-local
+ make -C /tmp/smithy-go-local smithy-clean smithy-publish-local
+
+format:
+ gofmt -w -s .
+
+gen-config-asserts:
+ @echo "Generating SDK config package implementor assertions"
+ cd config \
+ && go mod tidy \
+ && go generate
+
+gen-repo-mod-replace:
+ @echo "Generating go.mod replace for repo modules"
+ go run ${REPOTOOLS_CMD_MAKE_RELATIVE}
+
+gen-mod-replace-smithy:
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . "go mod edit -replace github.com/aws/smithy-go=${SMITHY_GO_SRC}"
+
+gen-mod-dropreplace-smithy:
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . "go mod edit -dropreplace github.com/aws/smithy-go"
+
+gen-aws-ptrs:
+ cd aws && go generate
+
+tidy-modules-%:
+ @# tidy command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "tidy-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. tidy-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst tidy-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go mod tidy"
+
+download-modules-%:
+ @# download command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "download-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. download-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst download-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go mod download all"
+
+add-module-license-files:
+ cd internal/repotools/cmd/eachmodule && \
+ go run . -skip-root \
+ "cp $(LICENSE_FILE) ."
+
+sync-models: sync-endpoints-model sync-api-models
+
+sync-endpoints-model: sync-endpoints.json gen-endpoint-prefix.json
+
+sync-endpoints.json:
+ [[ ! -z "${ENDPOINTS_MODEL}" ]] && cp ${ENDPOINTS_MODEL} ${ENDPOINTS_JSON} || echo "ENDPOINTS_MODEL not set, must not be empty"
+
+clone-v1-models:
+ rm -rf /tmp/aws-sdk-go-model-sync
+ git clone https://github.com/aws/aws-sdk-go.git --depth 1 /tmp/aws-sdk-go-model-sync
+
+gen-endpoint-prefix.json: clone-v1-models
+ cd internal/repotools/cmd/endpointPrefix && \
+ go run . \
+ -m '/tmp/aws-sdk-go-model-sync/models/apis/*/*/api-2.json' \
+ -o ${ENDPOINT_PREFIX_JSON}
+
+sync-api-models:
+ cd internal/repotools/cmd/syncAPIModels && \
+ go run . \
+ -m ${API_MODELS} \
+ -o ${CODEGEN_API_MODELS_PATH}
+
+copy-attributevalue-feature:
+ cd ./feature/dynamodbstreams/attributevalue && \
+ find . -name "*.go" | grep -v "doc.go" | xargs -I % rm % && \
+ find ../../dynamodb/attributevalue -name "*.go" | grep -v "doc.go" | xargs -I % cp % . && \
+ ls *.go | grep -v "convert.go" | grep -v "doc.go" | \
+ xargs -I % sed -i.bk -E 's:github.com/aws/aws-sdk-go-v2/(service|feature)/dynamodb:github.com/aws/aws-sdk-go-v2/\1/dynamodbstreams:g' % && \
+ ls *.go | grep -v "convert.go" | grep -v "doc.go" | \
+ xargs -I % sed -i.bk 's:DynamoDB:DynamoDBStreams:g' % && \
+ ls *.go | grep -v "doc.go" | \
+ xargs -I % sed -i.bk 's:dynamodb\.:dynamodbstreams.:g' % && \
+ sed -i.bk 's:streams\.:ddbtypes.:g' "convert.go" && \
+ sed -i.bk 's:ddb\.:streams.:g' "convert.go" && \
+ sed -i.bk 's:ddbtypes\.:ddb.:g' "convert.go" &&\
+ sed -i.bk 's:Streams::g' "convert.go" && \
+ rm -rf ./*.bk && \
+ go mod tidy && \
+ gofmt -w -s . && \
+ go test .
+
+min-go-version-%:
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst min-go-version-,,$@)) ${EACHMODULE_FLAGS} \
+ "go mod edit -go=${SDK_MIN_GO_VERSION}"
+
+update-requires:
+ go run ${REPOTOOLS_CMD_UPDATE_REQUIRES}
+
+update-module-metadata:
+ go run ${REPOTOOLS_CMD_UPDATE_MODULE_METADATA}
+
+################
+# Unit Testing #
+################
+.PHONY: unit unit-race unit-test unit-race-test unit-race-modules-% unit-modules-% build build-modules-% \
+go-build-modules-% test test-race-modules-% test-modules-% cachedep cachedep-modules-% api-diff-modules-%
+
+unit: lint unit-modules-.
+unit-race: lint unit-race-modules-.
+
+unit-test: test-modules-.
+unit-race-test: test-race-modules-.
+
+unit-race-modules-%:
+ @# unit command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "unit-race-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. unit-race-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst unit-race-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go vet ${BUILD_TAGS} --all ./..." \
+ "go test ${BUILD_TAGS} ${RUN_NONE} ./..." \
+ "go test -timeout=1m ${UNIT_TEST_TAGS} -race -cpu=4 ./..."
+
+
+unit-modules-%:
+ @# unit command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "unit-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. unit-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst unit-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go vet ${BUILD_TAGS} --all ./..." \
+ "go test ${BUILD_TAGS} ${RUN_NONE} ./..." \
+ "go test -timeout=1m ${UNIT_TEST_TAGS} ./..."
+
+build: build-modules-.
+
+build-modules-%:
+ @# build command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "build-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. build-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst build-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go test ${BUILD_TAGS} ${RUN_NONE} ./..."
+
+go-build-modules-%:
+ @# build command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "build-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# Validates that all modules in the repo have buildable Go files.
+ @#
+ @# e.g. go-build-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst go-build-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go build ${BUILD_TAGS} ./..."
+
+test: test-modules-.
+
+test-race-modules-%:
+ @# Test command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "test-race-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. test-race-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst test-race-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go test -timeout=1m ${UNIT_TEST_TAGS} -race -cpu=4 ./..."
+
+test-modules-%:
+ @# Test command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "test-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. test-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst test-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go test -timeout=1m ${UNIT_TEST_TAGS} ./..."
+
+cachedep: cachedep-modules-.
+
+cachedep-modules-%:
+ @# build command that uses the pattern to define the root path that the
+ @# module caching will start from. Strips off the "cachedep-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. cachedep-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst cachedep-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go mod download"
+
+api-diff-modules-%:
+ @# Command that uses the pattern to define the root path that the
+ @# module testing will start from. Strips off the "api-diff-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# Requires golang.org/x/exp/cmd/gorelease to be available in the GOPATH.
+ @#
+ @# e.g. api-diff-modules-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst api-diff-modules-,,$@)) \
+ -fail-fast=true \
+ -c 1 \
+ -skip="internal/repotools" \
+ "$$(go env GOPATH)/bin/gorelease"
+
+##############
+# CI Testing #
+##############
+.PHONY: ci-test ci-test-no-generate ci-test-generate-validate
+
+ci-test: generate unit-race ci-test-generate-validate
+ci-test-no-generate: unit-race
+
+ci-test-generate-validate:
+ @echo "CI test validate no generated code changes"
+ git update-index --assume-unchanged go.mod go.sum
+ git add . -A
+ gitstatus=`git diff --cached --ignore-space-change`; \
+ echo "$$gitstatus"; \
+ if [ "$$gitstatus" != "" ] && [ "$$gitstatus" != "skipping validation" ]; then echo "$$gitstatus"; exit 1; fi
+ git update-index --no-assume-unchanged go.mod go.sum
+
+ci-lint: ci-lint-.
+
+ci-lint-%:
+ @# Run golangci-lint command that uses the pattern to define the root path that the
+ @# module check will start from. Strips off the "ci-lint-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. ci-lint-internal_protocoltest
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst ci-lint-,,$@)) \
+ -fail-fast=false \
+ -c 1 \
+ -skip="internal/repotools" \
+ "golangci-lint run"
+
+ci-lint-install:
+ @# Installs golangci-lint at GoPATH.
+ @# This should be used to run golangci-lint locally.
+ @#
+ go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
+
+#######################
+# Integration Testing #
+#######################
+.PHONY: integration integ-modules-% cleanup-integ-buckets
+
+integration: integ-modules-service
+
+integ-modules-%:
+ @# integration command that uses the pattern to define the root path that
+ @# the module testing will start from. Strips off the "integ-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. test-modules-service_dynamodb
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst integ-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go test -timeout=10m -tags "integration" -v ${RUN_INTEG} -count 1 ./..."
+
+cleanup-integ-buckets:
+ @echo "Cleaning up SDK integration resources"
+ go run -tags "integration" ./internal/awstesting/cmd/bucket_cleanup/main.go "aws-sdk-go-integration"
+
+##############
+# Benchmarks #
+##############
+.PHONY: bench bench-modules-%
+
+bench: bench-modules-.
+
+bench-modules-%:
+ @# benchmark command that uses the pattern to define the root path that
+ @# the module testing will start from. Strips off the "bench-modules-" and
+ @# replaces all "_" with "/".
+ @#
+ @# e.g. bench-modules-service_dynamodb
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst bench-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go test -timeout=10m -bench . --benchmem ${BUILD_TAGS} ${RUN_NONE} ./..."
+
+
+#####################
+# Release Process #
+#####################
+.PHONY: preview-release pre-release-validation release
+
+ls-changes:
+ go run ${REPOTOOLS_CMD_CHANGELOG} ls
+
+preview-release:
+ go run ${REPOTOOLS_CMD_CALCULATE_RELEASE} ${REPOTOOLS_CALCULATE_RELEASE_VERBOSE_FLAG} ${REPOTOOLS_CALCULATE_RELEASE_ADDITIONAL_ARGS}
+
+pre-release-validation:
+ @if [[ -z "${RELEASE_MANIFEST_FILE}" ]]; then \
+ echo "RELEASE_MANIFEST_FILE is required to specify the file to write the release manifest" && false; \
+ fi
+ @if [[ -z "${RELEASE_CHGLOG_DESC_FILE}" ]]; then \
+ echo "RELEASE_CHGLOG_DESC_FILE is required to specify the file to write the release notes" && false; \
+ fi
+
+release: pre-release-validation
+ go run ${REPOTOOLS_CMD_CALCULATE_RELEASE} -o ${RELEASE_MANIFEST_FILE} ${REPOTOOLS_CALCULATE_RELEASE_VERBOSE_FLAG} ${REPOTOOLS_CALCULATE_RELEASE_ADDITIONAL_ARGS}
+ go run ${REPOTOOLS_CMD_UPDATE_REQUIRES} -release ${RELEASE_MANIFEST_FILE}
+ go run ${REPOTOOLS_CMD_UPDATE_MODULE_METADATA} -release ${RELEASE_MANIFEST_FILE}
+ go run ${REPOTOOLS_CMD_GENERATE_CHANGELOG} -release ${RELEASE_MANIFEST_FILE} -o ${RELEASE_CHGLOG_DESC_FILE}
+ go run ${REPOTOOLS_CMD_CHANGELOG} rm -all
+ go run ${REPOTOOLS_CMD_TAG_RELEASE} -release ${RELEASE_MANIFEST_FILE}
+
+##############
+# Repo Tools #
+##############
+.PHONY: install-repotools
+
+install-repotools:
+ go install ${REPOTOOLS_MODULE}/cmd/changelog@${REPOTOOLS_VERSION}
+
+set-smithy-go-version:
+ @if [[ -z "${SMITHY_GO_VERSION}" ]]; then \
+ echo "SMITHY_GO_VERSION is required to update SDK's smithy-go module dependency version" && false; \
+ fi
+ go run ${REPOTOOLS_CMD_EDIT_MODULE_DEPENDENCY} -s "github.com/aws/smithy-go" -v "${SMITHY_GO_VERSION}"
+
+##################
+# Linting/Verify #
+##################
+.PHONY: verify lint vet vet-modules-% sdkv1check
+
+verify: lint vet sdkv1check
+
+lint:
+ @echo "go lint SDK and vendor packages"
+ @lint=`golint ./...`; \
+ dolint=`echo "$$lint" | grep -E -v \
+ -e ${LINTIGNORESINGLEFIGHT}`; \
+ echo "$$dolint"; \
+ if [ "$$dolint" != "" ]; then exit 1; fi
+
+vet: vet-modules-.
+
+vet-modules-%:
+ cd ./internal/repotools/cmd/eachmodule \
+ && go run . -p $(subst _,/,$(subst vet-modules-,,$@)) ${EACHMODULE_FLAGS} \
+ "go vet ${BUILD_TAGS} --all ./..."
+
+sdkv1check:
+ @echo "Checking for usage of AWS SDK for Go v1"
+ @sdkv1usage=`go list -test -f '''{{ if not .Standard }}{{ range $$_, $$name := .Imports }} * {{ $$.ImportPath }} -> {{ $$name }}{{ print "\n" }}{{ end }}{{ range $$_, $$name := .TestImports }} *: {{ $$.ImportPath }} -> {{ $$name }}{{ print "\n" }}{{ end }}{{ end}}''' ./... | sort -u | grep '''/aws-sdk-go/'''`; \
+ echo "$$sdkv1usage"; \
+ if [ "$$sdkv1usage" != "" ]; then exit 1; fi
+
+###################
+# Sandbox Testing #
+###################
+.PHONY: sandbox-tests sandbox-build-% sandbox-run-% sandbox-test-% update-aws-golang-tip
+
+sandbox-tests: sandbox-test-go1.15 sandbox-test-go1.16 sandbox-test-go1.17 sandbox-test-gotip
+
+sandbox-build-%:
+ @# sandbox-build-go1.17
+ @# sandbox-build-gotip
+ docker build \
+ -f ./internal/awstesting/sandbox/Dockerfile.test.$(subst sandbox-build-,,$@) \
+ -t "aws-sdk-go-$(subst sandbox-build-,,$@)" .
+sandbox-run-%: sandbox-build-%
+ @# sandbox-run-go1.17
+ @# sandbox-run-gotip
+ docker run -i -t "aws-sdk-go-$(subst sandbox-run-,,$@)" bash
+sandbox-test-%: sandbox-build-%
+ @# sandbox-test-go1.17
+ @# sandbox-test-gotip
+ docker run -t "aws-sdk-go-$(subst sandbox-test-,,$@)"
+
+update-aws-golang-tip:
+ docker build --no-cache=true -f ./internal/awstesting/sandbox/Dockerfile.golang-tip -t "aws-golang:tip" .
diff --git a/vendor/github.com/aws/aws-sdk-go/NOTICE.txt b/vendor/github.com/aws/aws-sdk-go-v2/NOTICE.txt
similarity index 92%
rename from vendor/github.com/aws/aws-sdk-go/NOTICE.txt
rename to vendor/github.com/aws/aws-sdk-go-v2/NOTICE.txt
index 899129ecc465..5f14d1162ed4 100644
--- a/vendor/github.com/aws/aws-sdk-go/NOTICE.txt
+++ b/vendor/github.com/aws/aws-sdk-go-v2/NOTICE.txt
@@ -1,3 +1,3 @@
AWS SDK for Go
-Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved.
Copyright 2014-2015 Stripe, Inc.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/README.md b/vendor/github.com/aws/aws-sdk-go-v2/README.md
new file mode 100644
index 000000000000..bb4349fea270
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/README.md
@@ -0,0 +1,155 @@
+# AWS SDK for Go v2
+
+[](https://github.com/aws/aws-sdk-go-v2/actions/workflows/go.yml)[](https://github.com/aws/aws-sdk-go-v2/actions/workflows/codegen.yml) [](https://aws.github.io/aws-sdk-go-v2/docs/) [](https://aws.github.io/aws-sdk-go-v2/docs/migrating/) [](https://pkg.go.dev/mod/github.com/aws/aws-sdk-go-v2) [](https://github.com/aws/aws-sdk-go/blob/master/LICENSE.txt)
+
+
+`aws-sdk-go-v2` is the v2 AWS SDK for the Go programming language.
+
+The v2 SDK requires a minimum version of `Go 1.15`.
+
+Checkout out the [release notes](https://github.com/aws/aws-sdk-go-v2/blob/main/CHANGELOG.md) for information about the latest bug
+fixes, updates, and features added to the SDK.
+
+Jump To:
+* [Getting Started](#getting-started)
+* [Getting Help](#getting-help)
+* [Contributing](#feedback-and-contributing)
+* [More Resources](#resources)
+
+## Maintenance and support for SDK major versions
+
+For information about maintenance and support for SDK major versions and their underlying dependencies, see the
+following in the AWS SDKs and Tools Shared Configuration and Credentials Reference Guide:
+
+* [AWS SDKs and Tools Maintenance Policy](https://docs.aws.amazon.com/credref/latest/refdocs/maint-policy.html)
+* [AWS SDKs and Tools Version Support Matrix](https://docs.aws.amazon.com/credref/latest/refdocs/version-support-matrix.html)
+
+## Getting started
+To get started working with the SDK setup your project for Go modules, and retrieve the SDK dependencies with `go get`.
+This example shows how you can use the v2 SDK to make an API request using the SDK's [Amazon DynamoDB] client.
+
+###### Initialize Project
+```sh
+$ mkdir ~/helloaws
+$ cd ~/helloaws
+$ go mod init helloaws
+```
+###### Add SDK Dependencies
+```sh
+$ go get github.com/aws/aws-sdk-go-v2/aws
+$ go get github.com/aws/aws-sdk-go-v2/config
+$ go get github.com/aws/aws-sdk-go-v2/service/dynamodb
+```
+
+###### Write Code
+In your preferred editor add the following content to `main.go`
+
+```go
+package main
+
+import (
+ "context"
+ "fmt"
+ "log"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/config"
+ "github.com/aws/aws-sdk-go-v2/service/dynamodb"
+)
+
+func main() {
+ // Using the SDK's default configuration, loading additional config
+ // and credentials values from the environment variables, shared
+ // credentials, and shared configuration files
+ cfg, err := config.LoadDefaultConfig(context.TODO(), config.WithRegion("us-west-2"))
+ if err != nil {
+ log.Fatalf("unable to load SDK config, %v", err)
+ }
+
+ // Using the Config value, create the DynamoDB client
+ svc := dynamodb.NewFromConfig(cfg)
+
+ // Build the request with its input parameters
+ resp, err := svc.ListTables(context.TODO(), &dynamodb.ListTablesInput{
+ Limit: aws.Int32(5),
+ })
+ if err != nil {
+ log.Fatalf("failed to list tables, %v", err)
+ }
+
+ fmt.Println("Tables:")
+ for _, tableName := range resp.TableNames {
+ fmt.Println(tableName)
+ }
+}
+```
+
+###### Compile and Execute
+```sh
+$ go run .
+Table:
+tableOne
+tableTwo
+```
+
+## Getting Help
+
+Please use these community resources for getting help. We use the GitHub issues
+for tracking bugs and feature requests.
+
+* Ask a question on [StackOverflow](http://stackoverflow.com/) and tag it with the [`aws-sdk-go`](http://stackoverflow.com/questions/tagged/aws-sdk-go) tag.
+* Open a support ticket with [AWS Support](http://docs.aws.amazon.com/awssupport/latest/user/getting-started.html).
+* If you think you may have found a bug, please open an [issue](https://github.com/aws/aws-sdk-go-v2/issues/new/choose).
+
+This SDK implements AWS service APIs. For general issues regarding the AWS services and their limitations, you may also take a look at the [Amazon Web Services Discussion Forums](https://forums.aws.amazon.com/).
+
+### Opening Issues
+
+If you encounter a bug with the AWS SDK for Go we would like to hear about it.
+Search the [existing issues][Issues] and see
+if others are also experiencing the issue before opening a new issue. Please
+include the version of AWS SDK for Go, Go language, and OS you’re using. Please
+also include reproduction case when appropriate.
+
+The GitHub issues are intended for bug reports and feature requests. For help
+and questions with using AWS SDK for Go please make use of the resources listed
+in the [Getting Help](#getting-help) section.
+Keeping the list of open issues lean will help us respond in a timely manner.
+
+## Feedback and contributing
+
+The v2 SDK will use GitHub [Issues] to track feature requests and issues with the SDK. In addition, we'll use GitHub [Projects] to track large tasks spanning multiple pull requests, such as refactoring the SDK's internal request lifecycle. You can provide feedback to us in several ways.
+
+**GitHub issues**. To provide feedback or report bugs, file GitHub [Issues] on the SDK. This is the preferred mechanism to give feedback so that other users can engage in the conversation, +1 issues, etc. Issues you open will be evaluated, and included in our roadmap for the GA launch.
+
+**Contributing**. You can open pull requests for fixes or additions to the AWS SDK for Go 2.0. All pull requests must be submitted under the Apache 2.0 license and will be reviewed by an SDK team member before being merged in. Accompanying unit tests, where possible, are appreciated.
+
+## Resources
+
+[SDK Developer Guide](https://aws.github.io/aws-sdk-go-v2/docs/) - Use this document to learn how to get started and
+use the AWS SDK for Go V2.
+
+[SDK API Reference Documentation](https://pkg.go.dev/mod/github.com/aws/aws-sdk-go-v2) - Use this
+document to look up all API operation input and output parameters for AWS
+services supported by the SDK. The API reference also includes documentation of
+the SDK, and examples how to using the SDK, service client API operations, and
+API operation require parameters.
+
+[Service Documentation](https://aws.amazon.com/documentation/) - Use this
+documentation to learn how to interface with AWS services. These guides are
+great for getting started with a service, or when looking for more
+information about a service. While this document is not required for coding,
+services may supply helpful samples to look out for.
+
+[Forum](https://forums.aws.amazon.com/forum.jspa?forumID=293) - Ask questions, get help, and give feedback
+
+[Issues] - Report issues, submit pull requests, and get involved
+ (see [Apache 2.0 License][license])
+
+[Dep]: https://github.com/golang/dep
+[Issues]: https://github.com/aws/aws-sdk-go-v2/issues
+[Projects]: https://github.com/aws/aws-sdk-go-v2/projects
+[CHANGELOG]: https://github.com/aws/aws-sdk-go-v2/blob/master/CHANGELOG.md
+[Amazon DynamoDB]: https://aws.amazon.com/dynamodb/
+[design]: https://github.com/aws/aws-sdk-go-v2/blob/master/DESIGN.md
+[license]: http://aws.amazon.com/apache2.0/
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/config.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/config.go
new file mode 100644
index 000000000000..2b346baee77a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/config.go
@@ -0,0 +1,132 @@
+package aws
+
+import (
+ "net/http"
+
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+)
+
+// HTTPClient provides the interface to provide custom HTTPClients. Generally
+// *http.Client is sufficient for most use cases. The HTTPClient should not
+// follow redirects.
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// A Config provides service configuration for service clients.
+type Config struct {
+ // The region to send requests to. This parameter is required and must
+ // be configured globally or on a per-client basis unless otherwise
+ // noted. A full list of regions is found in the "Regions and Endpoints"
+ // document.
+ //
+ // See http://docs.aws.amazon.com/general/latest/gr/rande.html for
+ // information on AWS regions.
+ Region string
+
+ // The credentials object to use when signing requests. Defaults to a
+ // chain of credential providers to search for credentials in environment
+ // variables, shared credential file, and EC2 Instance Roles.
+ Credentials CredentialsProvider
+
+ // The HTTP Client the SDK's API clients will use to invoke HTTP requests.
+ // The SDK defaults to a BuildableClient allowing API clients to create
+ // copies of the HTTP Client for service specific customizations.
+ //
+ // Use a (*http.Client) for custom behavior. Using a custom http.Client
+ // will prevent the SDK from modifying the HTTP client.
+ HTTPClient HTTPClient
+
+ // An endpoint resolver that can be used to provide or override an endpoint for the given
+ // service and region.
+ //
+ // See the `aws.EndpointResolver` documentation for additional usage information.
+ //
+ // Deprecated: See Config.EndpointResolverWithOptions
+ EndpointResolver EndpointResolver
+
+ // An endpoint resolver that can be used to provide or override an endpoint for the given
+ // service and region.
+ //
+ // When EndpointResolverWithOptions is specified, it will be used by a service client rather than using
+ // EndpointResolver if also specified.
+ //
+ // See the `aws.EndpointResolverWithOptions` documentation for additional usage information.
+ EndpointResolverWithOptions EndpointResolverWithOptions
+
+ // Retryer is a function that provides a Retryer implementation. A Retryer guides how HTTP requests should be
+ // retried in case of recoverable failures. When nil the API client will use a default
+ // retryer.
+ //
+ // In general, the provider function should return a new instance of a Retryer if you are attempting
+ // to provide a consistent Retryer configuration across all clients. This will ensure that each client will be
+ // provided a new instance of the Retryer implementation, and will avoid issues such as sharing the same retry token
+ // bucket across services.
+ Retryer func() Retryer
+
+ // ConfigSources are the sources that were used to construct the Config.
+ // Allows for additional configuration to be loaded by clients.
+ ConfigSources []interface{}
+
+ // APIOptions provides the set of middleware mutations modify how the API
+ // client requests will be handled. This is useful for adding additional
+ // tracing data to a request, or changing behavior of the SDK's client.
+ APIOptions []func(*middleware.Stack) error
+
+ // The logger writer interface to write logging messages to. Defaults to
+ // standard error.
+ Logger logging.Logger
+
+ // Configures the events that will be sent to the configured logger.
+ // This can be used to configure the logging of signing, retries, request, and responses
+ // of the SDK clients.
+ //
+ // See the ClientLogMode type documentation for the complete set of logging modes and available
+ // configuration.
+ ClientLogMode ClientLogMode
+}
+
+// NewConfig returns a new Config pointer that can be chained with builder
+// methods to set multiple configuration values inline without using pointers.
+func NewConfig() *Config {
+ return &Config{}
+}
+
+// Copy will return a shallow copy of the Config object. If any additional
+// configurations are provided they will be merged into the new config returned.
+func (c Config) Copy() Config {
+ cp := c
+ return cp
+}
+
+// EndpointDiscoveryEnableState indicates if endpoint discovery is
+// enabled, disabled, auto or unset state.
+//
+// Default behavior (Auto or Unset) indicates operations that require endpoint
+// discovery will use Endpoint Discovery by default. Operations that
+// optionally use Endpoint Discovery will not use Endpoint Discovery
+// unless EndpointDiscovery is explicitly enabled.
+type EndpointDiscoveryEnableState uint
+
+// Enumeration values for EndpointDiscoveryEnableState
+const (
+ // EndpointDiscoveryUnset represents EndpointDiscoveryEnableState is unset.
+ // Users do not need to use this value explicitly. The behavior for unset
+ // is the same as for EndpointDiscoveryAuto.
+ EndpointDiscoveryUnset EndpointDiscoveryEnableState = iota
+
+ // EndpointDiscoveryAuto represents an AUTO state that allows endpoint
+ // discovery only when required by the api. This is the default
+ // configuration resolved by the client if endpoint discovery is neither
+ // enabled or disabled.
+ EndpointDiscoveryAuto // default state
+
+ // EndpointDiscoveryDisabled indicates client MUST not perform endpoint
+ // discovery even when required.
+ EndpointDiscoveryDisabled
+
+ // EndpointDiscoveryEnabled indicates client MUST always perform endpoint
+ // discovery if supported for the operation.
+ EndpointDiscoveryEnabled
+)
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/context.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/context.go
new file mode 100644
index 000000000000..4d8e26ef3215
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/context.go
@@ -0,0 +1,22 @@
+package aws
+
+import (
+ "context"
+ "time"
+)
+
+type suppressedContext struct {
+ context.Context
+}
+
+func (s *suppressedContext) Deadline() (deadline time.Time, ok bool) {
+ return time.Time{}, false
+}
+
+func (s *suppressedContext) Done() <-chan struct{} {
+ return nil
+}
+
+func (s *suppressedContext) Err() error {
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/credential_cache.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/credential_cache.go
new file mode 100644
index 000000000000..1411a5c32d6c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/credential_cache.go
@@ -0,0 +1,139 @@
+package aws
+
+import (
+ "context"
+ "sync/atomic"
+ "time"
+
+ sdkrand "github.com/aws/aws-sdk-go-v2/internal/rand"
+ "github.com/aws/aws-sdk-go-v2/internal/sync/singleflight"
+)
+
+// CredentialsCacheOptions are the options
+type CredentialsCacheOptions struct {
+
+ // ExpiryWindow will allow the credentials to trigger refreshing prior to
+ // the credentials actually expiring. This is beneficial so race conditions
+ // with expiring credentials do not cause request to fail unexpectedly
+ // due to ExpiredTokenException exceptions.
+ //
+ // An ExpiryWindow of 10s would cause calls to IsExpired() to return true
+ // 10 seconds before the credentials are actually expired. This can cause an
+ // increased number of requests to refresh the credentials to occur.
+ //
+ // If ExpiryWindow is 0 or less it will be ignored.
+ ExpiryWindow time.Duration
+
+ // ExpiryWindowJitterFrac provides a mechanism for randomizing the expiration of credentials
+ // within the configured ExpiryWindow by a random percentage. Valid values are between 0.0 and 1.0.
+ //
+ // As an example if ExpiryWindow is 60 seconds and ExpiryWindowJitterFrac is 0.5 then credentials will be set to
+ // expire between 30 to 60 seconds prior to their actual expiration time.
+ //
+ // If ExpiryWindow is 0 or less then ExpiryWindowJitterFrac is ignored.
+ // If ExpiryWindowJitterFrac is 0 then no randomization will be applied to the window.
+ // If ExpiryWindowJitterFrac < 0 the value will be treated as 0.
+ // If ExpiryWindowJitterFrac > 1 the value will be treated as 1.
+ ExpiryWindowJitterFrac float64
+}
+
+// CredentialsCache provides caching and concurrency safe credentials retrieval
+// via the provider's retrieve method.
+type CredentialsCache struct {
+ // provider is the CredentialProvider implementation to be wrapped by the CredentialCache.
+ provider CredentialsProvider
+
+ options CredentialsCacheOptions
+ creds atomic.Value
+ sf singleflight.Group
+}
+
+// NewCredentialsCache returns a CredentialsCache that wraps provider. Provider is expected to not be nil. A variadic
+// list of one or more functions can be provided to modify the CredentialsCache configuration. This allows for
+// configuration of credential expiry window and jitter.
+func NewCredentialsCache(provider CredentialsProvider, optFns ...func(options *CredentialsCacheOptions)) *CredentialsCache {
+ options := CredentialsCacheOptions{}
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ if options.ExpiryWindow < 0 {
+ options.ExpiryWindow = 0
+ }
+
+ if options.ExpiryWindowJitterFrac < 0 {
+ options.ExpiryWindowJitterFrac = 0
+ } else if options.ExpiryWindowJitterFrac > 1 {
+ options.ExpiryWindowJitterFrac = 1
+ }
+
+ return &CredentialsCache{
+ provider: provider,
+ options: options,
+ }
+}
+
+// Retrieve returns the credentials. If the credentials have already been
+// retrieved, and not expired the cached credentials will be returned. If the
+// credentials have not been retrieved yet, or expired the provider's Retrieve
+// method will be called.
+//
+// Returns and error if the provider's retrieve method returns an error.
+func (p *CredentialsCache) Retrieve(ctx context.Context) (Credentials, error) {
+ if creds := p.getCreds(); creds != nil {
+ return *creds, nil
+ }
+
+ resCh := p.sf.DoChan("", func() (interface{}, error) {
+ return p.singleRetrieve(&suppressedContext{ctx})
+ })
+ select {
+ case res := <-resCh:
+ return res.Val.(Credentials), res.Err
+ case <-ctx.Done():
+ return Credentials{}, &RequestCanceledError{Err: ctx.Err()}
+ }
+}
+
+func (p *CredentialsCache) singleRetrieve(ctx context.Context) (interface{}, error) {
+ if creds := p.getCreds(); creds != nil {
+ return *creds, nil
+ }
+
+ creds, err := p.provider.Retrieve(ctx)
+ if err == nil {
+ if creds.CanExpire {
+ randFloat64, err := sdkrand.CryptoRandFloat64()
+ if err != nil {
+ return Credentials{}, err
+ }
+ jitter := time.Duration(randFloat64 * p.options.ExpiryWindowJitterFrac * float64(p.options.ExpiryWindow))
+ creds.Expires = creds.Expires.Add(-(p.options.ExpiryWindow - jitter))
+ }
+
+ p.creds.Store(&creds)
+ }
+
+ return creds, err
+}
+
+func (p *CredentialsCache) getCreds() *Credentials {
+ v := p.creds.Load()
+ if v == nil {
+ return nil
+ }
+
+ c := v.(*Credentials)
+ if c != nil && c.HasKeys() && !c.Expired() {
+ return c
+ }
+
+ return nil
+}
+
+// Invalidate will invalidate the cached credentials. The next call to Retrieve
+// will cause the provider's Retrieve method to be called.
+func (p *CredentialsCache) Invalidate() {
+ p.creds.Store((*Credentials)(nil))
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/credentials.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/credentials.go
new file mode 100644
index 000000000000..ce3868a9f01c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/credentials.go
@@ -0,0 +1,127 @@
+package aws
+
+import (
+ "context"
+ "fmt"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/internal/sdk"
+)
+
+// AnonymousCredentials provides a sentinel CredentialsProvider that should be
+// used to instruct the SDK's signing middleware to not sign the request.
+//
+// Using `nil` credentials when configuring an API client will achieve the same
+// result. The AnonymousCredentials type allows you to configure the SDK's
+// external config loading to not attempt to source credentials from the shared
+// config or environment.
+//
+// For example you can use this CredentialsProvider with an API client's
+// Options to instruct the client not to sign a request for accessing public
+// S3 bucket objects.
+//
+// The following example demonstrates using the AnonymousCredentials to prevent
+// SDK's external config loading attempt to resolve credentials.
+//
+// cfg, err := config.LoadDefaultConfig(context.TODO(),
+// config.WithCredentialsProvider(aws.AnonymousCredentials{}),
+// )
+// if err != nil {
+// log.Fatalf("failed to load config, %v", err)
+// }
+//
+// client := s3.NewFromConfig(cfg)
+//
+// Alternatively you can leave the API client Option's `Credential` member to
+// nil. If using the `NewFromConfig` constructor you'll need to explicitly set
+// the `Credentials` member to nil, if the external config resolved a
+// credential provider.
+//
+// client := s3.New(s3.Options{
+// // Credentials defaults to a nil value.
+// })
+//
+// This can also be configured for specific operations calls too.
+//
+// cfg, err := config.LoadDefaultConfig(context.TODO())
+// if err != nil {
+// log.Fatalf("failed to load config, %v", err)
+// }
+//
+// client := s3.NewFromConfig(config)
+//
+// result, err := client.GetObject(context.TODO(), s3.GetObject{
+// Bucket: aws.String("example-bucket"),
+// Key: aws.String("example-key"),
+// }, func(o *s3.Options) {
+// o.Credentials = nil
+// // Or
+// o.Credentials = aws.AnonymousCredentials{}
+// })
+type AnonymousCredentials struct{}
+
+// Retrieve implements the CredentialsProvider interface, but will always
+// return error, and cannot be used to sign a request. The AnonymousCredentials
+// type is used as a sentinel type instructing the AWS request signing
+// middleware to not sign a request.
+func (AnonymousCredentials) Retrieve(context.Context) (Credentials, error) {
+ return Credentials{Source: "AnonymousCredentials"},
+ fmt.Errorf("the AnonymousCredentials is not a valid credential provider, and cannot be used to sign AWS requests with")
+}
+
+// A Credentials is the AWS credentials value for individual credential fields.
+type Credentials struct {
+ // AWS Access key ID
+ AccessKeyID string
+
+ // AWS Secret Access Key
+ SecretAccessKey string
+
+ // AWS Session Token
+ SessionToken string
+
+ // Source of the credentials
+ Source string
+
+ // Time the credentials will expire.
+ CanExpire bool
+ Expires time.Time
+}
+
+// Expired returns if the credentials have expired.
+func (v Credentials) Expired() bool {
+ if v.CanExpire {
+ // Calling Round(0) on the current time will truncate the monotonic reading only. Ensures credential expiry
+ // time is always based on reported wall-clock time.
+ return !v.Expires.After(sdk.NowTime().Round(0))
+ }
+
+ return false
+}
+
+// HasKeys returns if the credentials keys are set.
+func (v Credentials) HasKeys() bool {
+ return len(v.AccessKeyID) > 0 && len(v.SecretAccessKey) > 0
+}
+
+// A CredentialsProvider is the interface for any component which will provide
+// credentials Credentials. A CredentialsProvider is required to manage its own
+// Expired state, and what to be expired means.
+//
+// A credentials provider implementation can be wrapped with a CredentialCache
+// to cache the credential value retrieved. Without the cache the SDK will
+// attempt to retrieve the credentials for every request.
+type CredentialsProvider interface {
+ // Retrieve returns nil if it successfully retrieved the value.
+ // Error is returned if the value were not obtainable, or empty.
+ Retrieve(ctx context.Context) (Credentials, error)
+}
+
+// CredentialsProviderFunc provides a helper wrapping a function value to
+// satisfy the CredentialsProvider interface.
+type CredentialsProviderFunc func(context.Context) (Credentials, error)
+
+// Retrieve delegates to the function value the CredentialsProviderFunc wraps.
+func (fn CredentialsProviderFunc) Retrieve(ctx context.Context) (Credentials, error) {
+ return fn(ctx)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/doc.go
similarity index 86%
rename from vendor/github.com/aws/aws-sdk-go/aws/doc.go
rename to vendor/github.com/aws/aws-sdk-go-v2/aws/doc.go
index 4fcb6161848e..befc3bee1a7d 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/doc.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/doc.go
@@ -26,7 +26,7 @@
// strPtr = aws.String("my string")
//
// // Convert *string to string value
-// str = aws.StringValue(strPtr)
+// str = aws.ToString(strPtr)
//
// In addition to scalars the aws package also includes conversion utilities for
// map and slice for commonly types used in API parameters. The map and slice
@@ -40,7 +40,7 @@
// strPtrs = aws.StringSlice(strs)
//
// // Convert []*string to []string
-// strs = aws.StringValueSlice(strPtrs)
+// strs = aws.ToStringSlice(strPtrs)
//
// SDK Default HTTP Client
//
@@ -54,3 +54,9 @@
// configure the SDK to use the custom HTTP Client by setting the HTTPClient
// value of the SDK's Config type when creating a Session or service client.
package aws
+
+// generate.go uses a build tag of "ignore", go run doesn't need to specify
+// this because go run ignores all build flags when running a go file directly.
+//go:generate go run -tags codegen generate.go
+//go:generate go run -tags codegen logging_generate.go
+//go:generate gofmt -w -s .
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/endpoints.go
new file mode 100644
index 000000000000..aa10a9b40f0d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/endpoints.go
@@ -0,0 +1,229 @@
+package aws
+
+import (
+ "fmt"
+)
+
+// DualStackEndpointState is a constant to describe the dual-stack endpoint resolution behavior.
+type DualStackEndpointState uint
+
+const (
+ // DualStackEndpointStateUnset is the default value behavior for dual-stack endpoint resolution.
+ DualStackEndpointStateUnset DualStackEndpointState = iota
+
+ // DualStackEndpointStateEnabled enables dual-stack endpoint resolution for service endpoints.
+ DualStackEndpointStateEnabled
+
+ // DualStackEndpointStateDisabled disables dual-stack endpoint resolution for endpoints.
+ DualStackEndpointStateDisabled
+)
+
+// GetUseDualStackEndpoint takes a service's EndpointResolverOptions and returns the UseDualStackEndpoint value.
+// Returns boolean false if the provided options does not have a method to retrieve the DualStackEndpointState.
+func GetUseDualStackEndpoint(options ...interface{}) (value DualStackEndpointState, found bool) {
+ type iface interface {
+ GetUseDualStackEndpoint() DualStackEndpointState
+ }
+ for _, option := range options {
+ if i, ok := option.(iface); ok {
+ value = i.GetUseDualStackEndpoint()
+ found = true
+ break
+ }
+ }
+ return value, found
+}
+
+// FIPSEndpointState is a constant to describe the FIPS endpoint resolution behavior.
+type FIPSEndpointState uint
+
+const (
+ // FIPSEndpointStateUnset is the default value behavior for FIPS endpoint resolution.
+ FIPSEndpointStateUnset FIPSEndpointState = iota
+
+ // FIPSEndpointStateEnabled enables FIPS endpoint resolution for service endpoints.
+ FIPSEndpointStateEnabled
+
+ // FIPSEndpointStateDisabled disables FIPS endpoint resolution for endpoints.
+ FIPSEndpointStateDisabled
+)
+
+// GetUseFIPSEndpoint takes a service's EndpointResolverOptions and returns the UseDualStackEndpoint value.
+// Returns boolean false if the provided options does not have a method to retrieve the DualStackEndpointState.
+func GetUseFIPSEndpoint(options ...interface{}) (value FIPSEndpointState, found bool) {
+ type iface interface {
+ GetUseFIPSEndpoint() FIPSEndpointState
+ }
+ for _, option := range options {
+ if i, ok := option.(iface); ok {
+ value = i.GetUseFIPSEndpoint()
+ found = true
+ break
+ }
+ }
+ return value, found
+}
+
+// Endpoint represents the endpoint a service client should make API operation
+// calls to.
+//
+// The SDK will automatically resolve these endpoints per API client using an
+// internal endpoint resolvers. If you'd like to provide custom endpoint
+// resolving behavior you can implement the EndpointResolver interface.
+type Endpoint struct {
+ // The base URL endpoint the SDK API clients will use to make API calls to.
+ // The SDK will suffix URI path and query elements to this endpoint.
+ URL string
+
+ // Specifies if the endpoint's hostname can be modified by the SDK's API
+ // client.
+ //
+ // If the hostname is mutable the SDK API clients may modify any part of
+ // the hostname based on the requirements of the API, (e.g. adding, or
+ // removing content in the hostname). Such as, Amazon S3 API client
+ // prefixing "bucketname" to the hostname, or changing the
+ // hostname service name component from "s3." to "s3-accesspoint.dualstack."
+ // for the dualstack endpoint of an S3 Accesspoint resource.
+ //
+ // Care should be taken when providing a custom endpoint for an API. If the
+ // endpoint hostname is mutable, and the client cannot modify the endpoint
+ // correctly, the operation call will most likely fail, or have undefined
+ // behavior.
+ //
+ // If hostname is immutable, the SDK API clients will not modify the
+ // hostname of the URL. This may cause the API client not to function
+ // correctly if the API requires the operation specific hostname values
+ // to be used by the client.
+ //
+ // This flag does not modify the API client's behavior if this endpoint
+ // will be used instead of Endpoint Discovery, or if the endpoint will be
+ // used to perform Endpoint Discovery. That behavior is configured via the
+ // API Client's Options.
+ HostnameImmutable bool
+
+ // The AWS partition the endpoint belongs to.
+ PartitionID string
+
+ // The service name that should be used for signing the requests to the
+ // endpoint.
+ SigningName string
+
+ // The region that should be used for signing the request to the endpoint.
+ SigningRegion string
+
+ // The signing method that should be used for signing the requests to the
+ // endpoint.
+ SigningMethod string
+
+ // The source of the Endpoint. By default, this will be EndpointSourceServiceMetadata.
+ // When providing a custom endpoint, you should set the source as EndpointSourceCustom.
+ // If source is not provided when providing a custom endpoint, the SDK may not
+ // perform required host mutations correctly. Source should be used along with
+ // HostnameImmutable property as per the usage requirement.
+ Source EndpointSource
+}
+
+// EndpointSource is the endpoint source type.
+type EndpointSource int
+
+const (
+ // EndpointSourceServiceMetadata denotes service modeled endpoint metadata is used as Endpoint Source.
+ EndpointSourceServiceMetadata EndpointSource = iota
+
+ // EndpointSourceCustom denotes endpoint is a custom endpoint. This source should be used when
+ // user provides a custom endpoint to be used by the SDK.
+ EndpointSourceCustom
+)
+
+// EndpointNotFoundError is a sentinel error to indicate that the
+// EndpointResolver implementation was unable to resolve an endpoint for the
+// given service and region. Resolvers should use this to indicate that an API
+// client should fallback and attempt to use it's internal default resolver to
+// resolve the endpoint.
+type EndpointNotFoundError struct {
+ Err error
+}
+
+// Error is the error message.
+func (e *EndpointNotFoundError) Error() string {
+ return fmt.Sprintf("endpoint not found, %v", e.Err)
+}
+
+// Unwrap returns the underlying error.
+func (e *EndpointNotFoundError) Unwrap() error {
+ return e.Err
+}
+
+// EndpointResolver is an endpoint resolver that can be used to provide or
+// override an endpoint for the given service and region. API clients will
+// attempt to use the EndpointResolver first to resolve an endpoint if
+// available. If the EndpointResolver returns an EndpointNotFoundError error,
+// API clients will fallback to attempting to resolve the endpoint using its
+// internal default endpoint resolver.
+//
+// Deprecated: See EndpointResolverWithOptions
+type EndpointResolver interface {
+ ResolveEndpoint(service, region string) (Endpoint, error)
+}
+
+// EndpointResolverFunc wraps a function to satisfy the EndpointResolver interface.
+//
+// Deprecated: See EndpointResolverWithOptionsFunc
+type EndpointResolverFunc func(service, region string) (Endpoint, error)
+
+// ResolveEndpoint calls the wrapped function and returns the results.
+//
+// Deprecated: See EndpointResolverWithOptions.ResolveEndpoint
+func (e EndpointResolverFunc) ResolveEndpoint(service, region string) (Endpoint, error) {
+ return e(service, region)
+}
+
+// EndpointResolverWithOptions is an endpoint resolver that can be used to provide or
+// override an endpoint for the given service, region, and the service client's EndpointOptions. API clients will
+// attempt to use the EndpointResolverWithOptions first to resolve an endpoint if
+// available. If the EndpointResolverWithOptions returns an EndpointNotFoundError error,
+// API clients will fallback to attempting to resolve the endpoint using its
+// internal default endpoint resolver.
+type EndpointResolverWithOptions interface {
+ ResolveEndpoint(service, region string, options ...interface{}) (Endpoint, error)
+}
+
+// EndpointResolverWithOptionsFunc wraps a function to satisfy the EndpointResolverWithOptions interface.
+type EndpointResolverWithOptionsFunc func(service, region string, options ...interface{}) (Endpoint, error)
+
+// ResolveEndpoint calls the wrapped function and returns the results.
+func (e EndpointResolverWithOptionsFunc) ResolveEndpoint(service, region string, options ...interface{}) (Endpoint, error) {
+ return e(service, region, options...)
+}
+
+// GetDisableHTTPS takes a service's EndpointResolverOptions and returns the DisableHTTPS value.
+// Returns boolean false if the provided options does not have a method to retrieve the DisableHTTPS.
+func GetDisableHTTPS(options ...interface{}) (value bool, found bool) {
+ type iface interface {
+ GetDisableHTTPS() bool
+ }
+ for _, option := range options {
+ if i, ok := option.(iface); ok {
+ value = i.GetDisableHTTPS()
+ found = true
+ break
+ }
+ }
+ return value, found
+}
+
+// GetResolvedRegion takes a service's EndpointResolverOptions and returns the ResolvedRegion value.
+// Returns boolean false if the provided options does not have a method to retrieve the ResolvedRegion.
+func GetResolvedRegion(options ...interface{}) (value string, found bool) {
+ type iface interface {
+ GetResolvedRegion() string
+ }
+ for _, option := range options {
+ if i, ok := option.(iface); ok {
+ value = i.GetResolvedRegion()
+ found = true
+ break
+ }
+ }
+ return value, found
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/errors.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/errors.go
new file mode 100644
index 000000000000..f390a08f9ffa
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/errors.go
@@ -0,0 +1,9 @@
+package aws
+
+// MissingRegionError is an error that is returned if region configuration
+// value was not found.
+type MissingRegionError struct{}
+
+func (*MissingRegionError) Error() string {
+ return "an AWS region is required, but was not found"
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/from_ptr.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/from_ptr.go
new file mode 100644
index 000000000000..72e29c354d3c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/from_ptr.go
@@ -0,0 +1,344 @@
+// Code generated by aws/generate.go DO NOT EDIT.
+
+package aws
+
+import (
+ "github.com/aws/smithy-go/ptr"
+ "time"
+)
+
+// ToBool returns bool value dereferenced if the passed
+// in pointer was not nil. Returns a bool zero value if the
+// pointer was nil.
+func ToBool(p *bool) (v bool) {
+ return ptr.ToBool(p)
+}
+
+// ToBoolSlice returns a slice of bool values, that are
+// dereferenced if the passed in pointer was not nil. Returns a bool
+// zero value if the pointer was nil.
+func ToBoolSlice(vs []*bool) []bool {
+ return ptr.ToBoolSlice(vs)
+}
+
+// ToBoolMap returns a map of bool values, that are
+// dereferenced if the passed in pointer was not nil. The bool
+// zero value is used if the pointer was nil.
+func ToBoolMap(vs map[string]*bool) map[string]bool {
+ return ptr.ToBoolMap(vs)
+}
+
+// ToByte returns byte value dereferenced if the passed
+// in pointer was not nil. Returns a byte zero value if the
+// pointer was nil.
+func ToByte(p *byte) (v byte) {
+ return ptr.ToByte(p)
+}
+
+// ToByteSlice returns a slice of byte values, that are
+// dereferenced if the passed in pointer was not nil. Returns a byte
+// zero value if the pointer was nil.
+func ToByteSlice(vs []*byte) []byte {
+ return ptr.ToByteSlice(vs)
+}
+
+// ToByteMap returns a map of byte values, that are
+// dereferenced if the passed in pointer was not nil. The byte
+// zero value is used if the pointer was nil.
+func ToByteMap(vs map[string]*byte) map[string]byte {
+ return ptr.ToByteMap(vs)
+}
+
+// ToString returns string value dereferenced if the passed
+// in pointer was not nil. Returns a string zero value if the
+// pointer was nil.
+func ToString(p *string) (v string) {
+ return ptr.ToString(p)
+}
+
+// ToStringSlice returns a slice of string values, that are
+// dereferenced if the passed in pointer was not nil. Returns a string
+// zero value if the pointer was nil.
+func ToStringSlice(vs []*string) []string {
+ return ptr.ToStringSlice(vs)
+}
+
+// ToStringMap returns a map of string values, that are
+// dereferenced if the passed in pointer was not nil. The string
+// zero value is used if the pointer was nil.
+func ToStringMap(vs map[string]*string) map[string]string {
+ return ptr.ToStringMap(vs)
+}
+
+// ToInt returns int value dereferenced if the passed
+// in pointer was not nil. Returns a int zero value if the
+// pointer was nil.
+func ToInt(p *int) (v int) {
+ return ptr.ToInt(p)
+}
+
+// ToIntSlice returns a slice of int values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int
+// zero value if the pointer was nil.
+func ToIntSlice(vs []*int) []int {
+ return ptr.ToIntSlice(vs)
+}
+
+// ToIntMap returns a map of int values, that are
+// dereferenced if the passed in pointer was not nil. The int
+// zero value is used if the pointer was nil.
+func ToIntMap(vs map[string]*int) map[string]int {
+ return ptr.ToIntMap(vs)
+}
+
+// ToInt8 returns int8 value dereferenced if the passed
+// in pointer was not nil. Returns a int8 zero value if the
+// pointer was nil.
+func ToInt8(p *int8) (v int8) {
+ return ptr.ToInt8(p)
+}
+
+// ToInt8Slice returns a slice of int8 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int8
+// zero value if the pointer was nil.
+func ToInt8Slice(vs []*int8) []int8 {
+ return ptr.ToInt8Slice(vs)
+}
+
+// ToInt8Map returns a map of int8 values, that are
+// dereferenced if the passed in pointer was not nil. The int8
+// zero value is used if the pointer was nil.
+func ToInt8Map(vs map[string]*int8) map[string]int8 {
+ return ptr.ToInt8Map(vs)
+}
+
+// ToInt16 returns int16 value dereferenced if the passed
+// in pointer was not nil. Returns a int16 zero value if the
+// pointer was nil.
+func ToInt16(p *int16) (v int16) {
+ return ptr.ToInt16(p)
+}
+
+// ToInt16Slice returns a slice of int16 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int16
+// zero value if the pointer was nil.
+func ToInt16Slice(vs []*int16) []int16 {
+ return ptr.ToInt16Slice(vs)
+}
+
+// ToInt16Map returns a map of int16 values, that are
+// dereferenced if the passed in pointer was not nil. The int16
+// zero value is used if the pointer was nil.
+func ToInt16Map(vs map[string]*int16) map[string]int16 {
+ return ptr.ToInt16Map(vs)
+}
+
+// ToInt32 returns int32 value dereferenced if the passed
+// in pointer was not nil. Returns a int32 zero value if the
+// pointer was nil.
+func ToInt32(p *int32) (v int32) {
+ return ptr.ToInt32(p)
+}
+
+// ToInt32Slice returns a slice of int32 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int32
+// zero value if the pointer was nil.
+func ToInt32Slice(vs []*int32) []int32 {
+ return ptr.ToInt32Slice(vs)
+}
+
+// ToInt32Map returns a map of int32 values, that are
+// dereferenced if the passed in pointer was not nil. The int32
+// zero value is used if the pointer was nil.
+func ToInt32Map(vs map[string]*int32) map[string]int32 {
+ return ptr.ToInt32Map(vs)
+}
+
+// ToInt64 returns int64 value dereferenced if the passed
+// in pointer was not nil. Returns a int64 zero value if the
+// pointer was nil.
+func ToInt64(p *int64) (v int64) {
+ return ptr.ToInt64(p)
+}
+
+// ToInt64Slice returns a slice of int64 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int64
+// zero value if the pointer was nil.
+func ToInt64Slice(vs []*int64) []int64 {
+ return ptr.ToInt64Slice(vs)
+}
+
+// ToInt64Map returns a map of int64 values, that are
+// dereferenced if the passed in pointer was not nil. The int64
+// zero value is used if the pointer was nil.
+func ToInt64Map(vs map[string]*int64) map[string]int64 {
+ return ptr.ToInt64Map(vs)
+}
+
+// ToUint returns uint value dereferenced if the passed
+// in pointer was not nil. Returns a uint zero value if the
+// pointer was nil.
+func ToUint(p *uint) (v uint) {
+ return ptr.ToUint(p)
+}
+
+// ToUintSlice returns a slice of uint values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint
+// zero value if the pointer was nil.
+func ToUintSlice(vs []*uint) []uint {
+ return ptr.ToUintSlice(vs)
+}
+
+// ToUintMap returns a map of uint values, that are
+// dereferenced if the passed in pointer was not nil. The uint
+// zero value is used if the pointer was nil.
+func ToUintMap(vs map[string]*uint) map[string]uint {
+ return ptr.ToUintMap(vs)
+}
+
+// ToUint8 returns uint8 value dereferenced if the passed
+// in pointer was not nil. Returns a uint8 zero value if the
+// pointer was nil.
+func ToUint8(p *uint8) (v uint8) {
+ return ptr.ToUint8(p)
+}
+
+// ToUint8Slice returns a slice of uint8 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint8
+// zero value if the pointer was nil.
+func ToUint8Slice(vs []*uint8) []uint8 {
+ return ptr.ToUint8Slice(vs)
+}
+
+// ToUint8Map returns a map of uint8 values, that are
+// dereferenced if the passed in pointer was not nil. The uint8
+// zero value is used if the pointer was nil.
+func ToUint8Map(vs map[string]*uint8) map[string]uint8 {
+ return ptr.ToUint8Map(vs)
+}
+
+// ToUint16 returns uint16 value dereferenced if the passed
+// in pointer was not nil. Returns a uint16 zero value if the
+// pointer was nil.
+func ToUint16(p *uint16) (v uint16) {
+ return ptr.ToUint16(p)
+}
+
+// ToUint16Slice returns a slice of uint16 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint16
+// zero value if the pointer was nil.
+func ToUint16Slice(vs []*uint16) []uint16 {
+ return ptr.ToUint16Slice(vs)
+}
+
+// ToUint16Map returns a map of uint16 values, that are
+// dereferenced if the passed in pointer was not nil. The uint16
+// zero value is used if the pointer was nil.
+func ToUint16Map(vs map[string]*uint16) map[string]uint16 {
+ return ptr.ToUint16Map(vs)
+}
+
+// ToUint32 returns uint32 value dereferenced if the passed
+// in pointer was not nil. Returns a uint32 zero value if the
+// pointer was nil.
+func ToUint32(p *uint32) (v uint32) {
+ return ptr.ToUint32(p)
+}
+
+// ToUint32Slice returns a slice of uint32 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint32
+// zero value if the pointer was nil.
+func ToUint32Slice(vs []*uint32) []uint32 {
+ return ptr.ToUint32Slice(vs)
+}
+
+// ToUint32Map returns a map of uint32 values, that are
+// dereferenced if the passed in pointer was not nil. The uint32
+// zero value is used if the pointer was nil.
+func ToUint32Map(vs map[string]*uint32) map[string]uint32 {
+ return ptr.ToUint32Map(vs)
+}
+
+// ToUint64 returns uint64 value dereferenced if the passed
+// in pointer was not nil. Returns a uint64 zero value if the
+// pointer was nil.
+func ToUint64(p *uint64) (v uint64) {
+ return ptr.ToUint64(p)
+}
+
+// ToUint64Slice returns a slice of uint64 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint64
+// zero value if the pointer was nil.
+func ToUint64Slice(vs []*uint64) []uint64 {
+ return ptr.ToUint64Slice(vs)
+}
+
+// ToUint64Map returns a map of uint64 values, that are
+// dereferenced if the passed in pointer was not nil. The uint64
+// zero value is used if the pointer was nil.
+func ToUint64Map(vs map[string]*uint64) map[string]uint64 {
+ return ptr.ToUint64Map(vs)
+}
+
+// ToFloat32 returns float32 value dereferenced if the passed
+// in pointer was not nil. Returns a float32 zero value if the
+// pointer was nil.
+func ToFloat32(p *float32) (v float32) {
+ return ptr.ToFloat32(p)
+}
+
+// ToFloat32Slice returns a slice of float32 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a float32
+// zero value if the pointer was nil.
+func ToFloat32Slice(vs []*float32) []float32 {
+ return ptr.ToFloat32Slice(vs)
+}
+
+// ToFloat32Map returns a map of float32 values, that are
+// dereferenced if the passed in pointer was not nil. The float32
+// zero value is used if the pointer was nil.
+func ToFloat32Map(vs map[string]*float32) map[string]float32 {
+ return ptr.ToFloat32Map(vs)
+}
+
+// ToFloat64 returns float64 value dereferenced if the passed
+// in pointer was not nil. Returns a float64 zero value if the
+// pointer was nil.
+func ToFloat64(p *float64) (v float64) {
+ return ptr.ToFloat64(p)
+}
+
+// ToFloat64Slice returns a slice of float64 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a float64
+// zero value if the pointer was nil.
+func ToFloat64Slice(vs []*float64) []float64 {
+ return ptr.ToFloat64Slice(vs)
+}
+
+// ToFloat64Map returns a map of float64 values, that are
+// dereferenced if the passed in pointer was not nil. The float64
+// zero value is used if the pointer was nil.
+func ToFloat64Map(vs map[string]*float64) map[string]float64 {
+ return ptr.ToFloat64Map(vs)
+}
+
+// ToTime returns time.Time value dereferenced if the passed
+// in pointer was not nil. Returns a time.Time zero value if the
+// pointer was nil.
+func ToTime(p *time.Time) (v time.Time) {
+ return ptr.ToTime(p)
+}
+
+// ToTimeSlice returns a slice of time.Time values, that are
+// dereferenced if the passed in pointer was not nil. Returns a time.Time
+// zero value if the pointer was nil.
+func ToTimeSlice(vs []*time.Time) []time.Time {
+ return ptr.ToTimeSlice(vs)
+}
+
+// ToTimeMap returns a map of time.Time values, that are
+// dereferenced if the passed in pointer was not nil. The time.Time
+// zero value is used if the pointer was nil.
+func ToTimeMap(vs map[string]*time.Time) map[string]time.Time {
+ return ptr.ToTimeMap(vs)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/go_module_metadata.go
new file mode 100644
index 000000000000..5b4eeb3ef4aa
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package aws
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.12.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/logging.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/logging.go
new file mode 100644
index 000000000000..9e34d26f2158
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/logging.go
@@ -0,0 +1,117 @@
+// Code generated by aws/logging_generate.go DO NOT EDIT.
+
+package aws
+
+// ClientLogMode represents the logging mode of SDK clients. The client logging mode is a bit-field where
+// each bit is a flag that describes the logging behavior for one or more client components.
+// The entire 64-bit group is reserved for later expansion by the SDK.
+//
+// Example: Setting ClientLogMode to enable logging of retries and requests
+// clientLogMode := aws.LogRetries | aws.LogRequest
+//
+// Example: Adding an additional log mode to an existing ClientLogMode value
+// clientLogMode |= aws.LogResponse
+type ClientLogMode uint64
+
+// Supported ClientLogMode bits that can be configured to toggle logging of specific SDK events.
+const (
+ LogSigning ClientLogMode = 1 << (64 - 1 - iota)
+ LogRetries
+ LogRequest
+ LogRequestWithBody
+ LogResponse
+ LogResponseWithBody
+ LogDeprecatedUsage
+ LogRequestEventMessage
+ LogResponseEventMessage
+)
+
+// IsSigning returns whether the Signing logging mode bit is set
+func (m ClientLogMode) IsSigning() bool {
+ return m&LogSigning != 0
+}
+
+// IsRetries returns whether the Retries logging mode bit is set
+func (m ClientLogMode) IsRetries() bool {
+ return m&LogRetries != 0
+}
+
+// IsRequest returns whether the Request logging mode bit is set
+func (m ClientLogMode) IsRequest() bool {
+ return m&LogRequest != 0
+}
+
+// IsRequestWithBody returns whether the RequestWithBody logging mode bit is set
+func (m ClientLogMode) IsRequestWithBody() bool {
+ return m&LogRequestWithBody != 0
+}
+
+// IsResponse returns whether the Response logging mode bit is set
+func (m ClientLogMode) IsResponse() bool {
+ return m&LogResponse != 0
+}
+
+// IsResponseWithBody returns whether the ResponseWithBody logging mode bit is set
+func (m ClientLogMode) IsResponseWithBody() bool {
+ return m&LogResponseWithBody != 0
+}
+
+// IsDeprecatedUsage returns whether the DeprecatedUsage logging mode bit is set
+func (m ClientLogMode) IsDeprecatedUsage() bool {
+ return m&LogDeprecatedUsage != 0
+}
+
+// IsRequestEventMessage returns whether the RequestEventMessage logging mode bit is set
+func (m ClientLogMode) IsRequestEventMessage() bool {
+ return m&LogRequestEventMessage != 0
+}
+
+// IsResponseEventMessage returns whether the ResponseEventMessage logging mode bit is set
+func (m ClientLogMode) IsResponseEventMessage() bool {
+ return m&LogResponseEventMessage != 0
+}
+
+// ClearSigning clears the Signing logging mode bit
+func (m *ClientLogMode) ClearSigning() {
+ *m &^= LogSigning
+}
+
+// ClearRetries clears the Retries logging mode bit
+func (m *ClientLogMode) ClearRetries() {
+ *m &^= LogRetries
+}
+
+// ClearRequest clears the Request logging mode bit
+func (m *ClientLogMode) ClearRequest() {
+ *m &^= LogRequest
+}
+
+// ClearRequestWithBody clears the RequestWithBody logging mode bit
+func (m *ClientLogMode) ClearRequestWithBody() {
+ *m &^= LogRequestWithBody
+}
+
+// ClearResponse clears the Response logging mode bit
+func (m *ClientLogMode) ClearResponse() {
+ *m &^= LogResponse
+}
+
+// ClearResponseWithBody clears the ResponseWithBody logging mode bit
+func (m *ClientLogMode) ClearResponseWithBody() {
+ *m &^= LogResponseWithBody
+}
+
+// ClearDeprecatedUsage clears the DeprecatedUsage logging mode bit
+func (m *ClientLogMode) ClearDeprecatedUsage() {
+ *m &^= LogDeprecatedUsage
+}
+
+// ClearRequestEventMessage clears the RequestEventMessage logging mode bit
+func (m *ClientLogMode) ClearRequestEventMessage() {
+ *m &^= LogRequestEventMessage
+}
+
+// ClearResponseEventMessage clears the ResponseEventMessage logging mode bit
+func (m *ClientLogMode) ClearResponseEventMessage() {
+ *m &^= LogResponseEventMessage
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/logging_generate.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/logging_generate.go
new file mode 100644
index 000000000000..6ecc2231a122
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/logging_generate.go
@@ -0,0 +1,95 @@
+//go:build clientlogmode
+// +build clientlogmode
+
+package main
+
+import (
+ "fmt"
+ "log"
+ "os"
+ "strings"
+ "text/template"
+)
+
+var config = struct {
+ ModeBits []string
+}{
+ // Items should be appended only to keep bit-flag positions stable
+ ModeBits: []string{
+ "Signing",
+ "Retries",
+ "Request",
+ "RequestWithBody",
+ "Response",
+ "ResponseWithBody",
+ "DeprecatedUsage",
+ "RequestEventMessage",
+ "ResponseEventMessage",
+ },
+}
+
+func bitName(name string) string {
+ return strings.ToUpper(name[:1]) + name[1:]
+}
+
+var tmpl = template.Must(template.New("ClientLogMode").Funcs(map[string]interface{}{
+ "symbolName": func(name string) string {
+ return "Log" + bitName(name)
+ },
+ "bitName": bitName,
+}).Parse(`// Code generated by aws/logging_generate.go DO NOT EDIT.
+
+package aws
+
+// ClientLogMode represents the logging mode of SDK clients. The client logging mode is a bit-field where
+// each bit is a flag that describes the logging behavior for one or more client components.
+// The entire 64-bit group is reserved for later expansion by the SDK.
+//
+// Example: Setting ClientLogMode to enable logging of retries and requests
+// clientLogMode := aws.LogRetries | aws.LogRequest
+//
+// Example: Adding an additional log mode to an existing ClientLogMode value
+// clientLogMode |= aws.LogResponse
+type ClientLogMode uint64
+
+// Supported ClientLogMode bits that can be configured to toggle logging of specific SDK events.
+const (
+{{- range $index, $field := .ModeBits }}
+ {{ (symbolName $field) }}{{- if (eq 0 $index) }} ClientLogMode = 1 << (64 - 1 - iota){{- end }}
+{{- end }}
+)
+{{ range $_, $field := .ModeBits }}
+// Is{{- bitName $field }} returns whether the {{ bitName $field }} logging mode bit is set
+func (m ClientLogMode) Is{{- bitName $field }}() bool {
+ return m&{{- (symbolName $field) }} != 0
+}
+{{ end }}
+{{- range $_, $field := .ModeBits }}
+// Clear{{- bitName $field }} clears the {{ bitName $field }} logging mode bit
+func (m *ClientLogMode) Clear{{- bitName $field }}() {
+ *m &^= {{ (symbolName $field) }}
+}
+{{ end -}}
+`))
+
+func main() {
+ uniqueBitFields := make(map[string]struct{})
+
+ for _, bitName := range config.ModeBits {
+ if _, ok := uniqueBitFields[strings.ToLower(bitName)]; ok {
+ panic(fmt.Sprintf("duplicate bit field: %s", bitName))
+ }
+ uniqueBitFields[bitName] = struct{}{}
+ }
+
+ file, err := os.Create("logging.go")
+ if err != nil {
+ log.Fatal(err)
+ }
+ defer file.Close()
+
+ err = tmpl.Execute(file, config)
+ if err != nil {
+ log.Fatal(err)
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/metadata.go
new file mode 100644
index 000000000000..e6e87ac77764
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/metadata.go
@@ -0,0 +1,180 @@
+package middleware
+
+import (
+ "context"
+ "github.com/aws/aws-sdk-go-v2/aws"
+
+ "github.com/aws/smithy-go/middleware"
+)
+
+// RegisterServiceMetadata registers metadata about the service and operation into the middleware context
+// so that it is available at runtime for other middleware to introspect.
+type RegisterServiceMetadata struct {
+ ServiceID string
+ SigningName string
+ Region string
+ OperationName string
+}
+
+// ID returns the middleware identifier.
+func (s *RegisterServiceMetadata) ID() string {
+ return "RegisterServiceMetadata"
+}
+
+// HandleInitialize registers service metadata information into the middleware context, allowing for introspection.
+func (s RegisterServiceMetadata) HandleInitialize(
+ ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler,
+) (out middleware.InitializeOutput, metadata middleware.Metadata, err error) {
+ if len(s.ServiceID) > 0 {
+ ctx = SetServiceID(ctx, s.ServiceID)
+ }
+ if len(s.SigningName) > 0 {
+ ctx = SetSigningName(ctx, s.SigningName)
+ }
+ if len(s.Region) > 0 {
+ ctx = setRegion(ctx, s.Region)
+ }
+ if len(s.OperationName) > 0 {
+ ctx = setOperationName(ctx, s.OperationName)
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+// service metadata keys for storing and lookup of runtime stack information.
+type (
+ serviceIDKey struct{}
+ signingNameKey struct{}
+ signingRegionKey struct{}
+ regionKey struct{}
+ operationNameKey struct{}
+ partitionIDKey struct{}
+)
+
+// GetServiceID retrieves the service id from the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func GetServiceID(ctx context.Context) (v string) {
+ v, _ = middleware.GetStackValue(ctx, serviceIDKey{}).(string)
+ return v
+}
+
+// GetSigningName retrieves the service signing name from the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func GetSigningName(ctx context.Context) (v string) {
+ v, _ = middleware.GetStackValue(ctx, signingNameKey{}).(string)
+ return v
+}
+
+// GetSigningRegion retrieves the region from the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func GetSigningRegion(ctx context.Context) (v string) {
+ v, _ = middleware.GetStackValue(ctx, signingRegionKey{}).(string)
+ return v
+}
+
+// GetRegion retrieves the endpoint region from the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func GetRegion(ctx context.Context) (v string) {
+ v, _ = middleware.GetStackValue(ctx, regionKey{}).(string)
+ return v
+}
+
+// GetOperationName retrieves the service operation metadata from the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func GetOperationName(ctx context.Context) (v string) {
+ v, _ = middleware.GetStackValue(ctx, operationNameKey{}).(string)
+ return v
+}
+
+// GetPartitionID retrieves the endpoint partition id from the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func GetPartitionID(ctx context.Context) string {
+ v, _ := middleware.GetStackValue(ctx, partitionIDKey{}).(string)
+ return v
+}
+
+// SetSigningName set or modifies the signing name on the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func SetSigningName(ctx context.Context, value string) context.Context {
+ return middleware.WithStackValue(ctx, signingNameKey{}, value)
+}
+
+// SetSigningRegion sets or modifies the region on the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func SetSigningRegion(ctx context.Context, value string) context.Context {
+ return middleware.WithStackValue(ctx, signingRegionKey{}, value)
+}
+
+// SetServiceID sets the service id on the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func SetServiceID(ctx context.Context, value string) context.Context {
+ return middleware.WithStackValue(ctx, serviceIDKey{}, value)
+}
+
+// setRegion sets the endpoint region on the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func setRegion(ctx context.Context, value string) context.Context {
+ return middleware.WithStackValue(ctx, regionKey{}, value)
+}
+
+// setOperationName sets the service operation on the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func setOperationName(ctx context.Context, value string) context.Context {
+ return middleware.WithStackValue(ctx, operationNameKey{}, value)
+}
+
+// SetPartitionID sets the partition id of a resolved region on the context
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func SetPartitionID(ctx context.Context, value string) context.Context {
+ return middleware.WithStackValue(ctx, partitionIDKey{}, value)
+}
+
+// EndpointSource key
+type endpointSourceKey struct{}
+
+// GetEndpointSource returns an endpoint source if set on context
+func GetEndpointSource(ctx context.Context) (v aws.EndpointSource) {
+ v, _ = middleware.GetStackValue(ctx, endpointSourceKey{}).(aws.EndpointSource)
+ return v
+}
+
+// SetEndpointSource sets endpoint source on context
+func SetEndpointSource(ctx context.Context, value aws.EndpointSource) context.Context {
+ return middleware.WithStackValue(ctx, endpointSourceKey{}, value)
+}
+
+type signingCredentialsKey struct{}
+
+// GetSigningCredentials returns the credentials that were used for signing if set on context.
+func GetSigningCredentials(ctx context.Context) (v aws.Credentials) {
+ v, _ = middleware.GetStackValue(ctx, signingCredentialsKey{}).(aws.Credentials)
+ return v
+}
+
+// SetSigningCredentials sets the credentails used for signing on the context.
+func SetSigningCredentials(ctx context.Context, value aws.Credentials) context.Context {
+ return middleware.WithStackValue(ctx, signingCredentialsKey{}, value)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/middleware.go
new file mode 100644
index 000000000000..9bd0dfb15086
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/middleware.go
@@ -0,0 +1,168 @@
+package middleware
+
+import (
+ "context"
+ "fmt"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/internal/rand"
+ "github.com/aws/aws-sdk-go-v2/internal/sdk"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+ smithyrand "github.com/aws/smithy-go/rand"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// ClientRequestID is a Smithy BuildMiddleware that will generate a unique ID for logical API operation
+// invocation.
+type ClientRequestID struct{}
+
+// ID the identifier for the ClientRequestID
+func (r *ClientRequestID) ID() string {
+ return "ClientRequestID"
+}
+
+// HandleBuild attaches a unique operation invocation id for the operation to the request
+func (r ClientRequestID) HandleBuild(ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", req)
+ }
+
+ invocationID, err := smithyrand.NewUUID(rand.Reader).GetUUID()
+ if err != nil {
+ return out, metadata, err
+ }
+
+ const invocationIDHeader = "Amz-Sdk-Invocation-Id"
+ req.Header[invocationIDHeader] = append(req.Header[invocationIDHeader][:0], invocationID)
+
+ return next.HandleBuild(ctx, in)
+}
+
+// RecordResponseTiming records the response timing for the SDK client requests.
+type RecordResponseTiming struct{}
+
+// ID is the middleware identifier
+func (a *RecordResponseTiming) ID() string {
+ return "RecordResponseTiming"
+}
+
+// HandleDeserialize calculates response metadata and clock skew
+func (a RecordResponseTiming) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ responseAt := sdk.NowTime()
+ setResponseAt(&metadata, responseAt)
+
+ var serverTime time.Time
+
+ switch resp := out.RawResponse.(type) {
+ case *smithyhttp.Response:
+ respDateHeader := resp.Header.Get("Date")
+ if len(respDateHeader) == 0 {
+ break
+ }
+ var parseErr error
+ serverTime, parseErr = smithyhttp.ParseTime(respDateHeader)
+ if parseErr != nil {
+ logger := middleware.GetLogger(ctx)
+ logger.Logf(logging.Warn, "failed to parse response Date header value, got %v",
+ parseErr.Error())
+ break
+ }
+ setServerTime(&metadata, serverTime)
+ }
+
+ if !serverTime.IsZero() {
+ attemptSkew := serverTime.Sub(responseAt)
+ setAttemptSkew(&metadata, attemptSkew)
+ }
+
+ return out, metadata, err
+}
+
+type responseAtKey struct{}
+
+// GetResponseAt returns the time response was received at.
+func GetResponseAt(metadata middleware.Metadata) (v time.Time, ok bool) {
+ v, ok = metadata.Get(responseAtKey{}).(time.Time)
+ return v, ok
+}
+
+// setResponseAt sets the response time on the metadata.
+func setResponseAt(metadata *middleware.Metadata, v time.Time) {
+ metadata.Set(responseAtKey{}, v)
+}
+
+type serverTimeKey struct{}
+
+// GetServerTime returns the server time for response.
+func GetServerTime(metadata middleware.Metadata) (v time.Time, ok bool) {
+ v, ok = metadata.Get(serverTimeKey{}).(time.Time)
+ return v, ok
+}
+
+// setServerTime sets the server time on the metadata.
+func setServerTime(metadata *middleware.Metadata, v time.Time) {
+ metadata.Set(serverTimeKey{}, v)
+}
+
+type attemptSkewKey struct{}
+
+// GetAttemptSkew returns Attempt clock skew for response from metadata.
+func GetAttemptSkew(metadata middleware.Metadata) (v time.Duration, ok bool) {
+ v, ok = metadata.Get(attemptSkewKey{}).(time.Duration)
+ return v, ok
+}
+
+// setAttemptSkew sets the attempt clock skew on the metadata.
+func setAttemptSkew(metadata *middleware.Metadata, v time.Duration) {
+ metadata.Set(attemptSkewKey{}, v)
+}
+
+// AddClientRequestIDMiddleware adds ClientRequestID to the middleware stack
+func AddClientRequestIDMiddleware(stack *middleware.Stack) error {
+ return stack.Build.Add(&ClientRequestID{}, middleware.After)
+}
+
+// AddRecordResponseTiming adds RecordResponseTiming middleware to the
+// middleware stack.
+func AddRecordResponseTiming(stack *middleware.Stack) error {
+ return stack.Deserialize.Add(&RecordResponseTiming{}, middleware.After)
+}
+
+// rawResponseKey is the accessor key used to store and access the
+// raw response within the response metadata.
+type rawResponseKey struct{}
+
+// addRawResponse middleware adds raw response on to the metadata
+type addRawResponse struct{}
+
+// ID the identifier for the ClientRequestID
+func (m *addRawResponse) ID() string {
+ return "AddRawResponseToMetadata"
+}
+
+// HandleDeserialize adds raw response on the middleware metadata
+func (m addRawResponse) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ metadata.Set(rawResponseKey{}, out.RawResponse)
+ return out, metadata, err
+}
+
+// AddRawResponseToMetadata adds middleware to the middleware stack that
+// store raw response on to the metadata.
+func AddRawResponseToMetadata(stack *middleware.Stack) error {
+ return stack.Deserialize.Add(&addRawResponse{}, middleware.Before)
+}
+
+// GetRawResponse returns raw response set on metadata
+func GetRawResponse(metadata middleware.Metadata) interface{} {
+ return metadata.Get(rawResponseKey{})
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/osname.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/osname.go
new file mode 100644
index 000000000000..ba262dadcd0d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/osname.go
@@ -0,0 +1,24 @@
+//go:build go1.16
+// +build go1.16
+
+package middleware
+
+import "runtime"
+
+func getNormalizedOSName() (os string) {
+ switch runtime.GOOS {
+ case "android":
+ os = "android"
+ case "linux":
+ os = "linux"
+ case "windows":
+ os = "windows"
+ case "darwin":
+ os = "macos"
+ case "ios":
+ os = "ios"
+ default:
+ os = "other"
+ }
+ return os
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/osname_go115.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/osname_go115.go
new file mode 100644
index 000000000000..e14a1e4ecb9d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/osname_go115.go
@@ -0,0 +1,24 @@
+//go:build !go1.16
+// +build !go1.16
+
+package middleware
+
+import "runtime"
+
+func getNormalizedOSName() (os string) {
+ switch runtime.GOOS {
+ case "android":
+ os = "android"
+ case "linux":
+ os = "linux"
+ case "windows":
+ os = "windows"
+ case "darwin":
+ // Due to Apple M1 we can't distinguish between macOS and iOS when GOOS/GOARCH is darwin/amd64
+ // For now declare this as "other" until we have a better detection mechanism.
+ fallthrough
+ default:
+ os = "other"
+ }
+ return os
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/request_id.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/request_id.go
new file mode 100644
index 000000000000..dd3391fe41e3
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/request_id.go
@@ -0,0 +1,27 @@
+package middleware
+
+import (
+ "github.com/aws/smithy-go/middleware"
+)
+
+// requestIDKey is used to retrieve request id from response metadata
+type requestIDKey struct{}
+
+// SetRequestIDMetadata sets the provided request id over middleware metadata
+func SetRequestIDMetadata(metadata *middleware.Metadata, id string) {
+ metadata.Set(requestIDKey{}, id)
+}
+
+// GetRequestIDMetadata retrieves the request id from middleware metadata
+// returns string and bool indicating value of request id, whether request id was set.
+func GetRequestIDMetadata(metadata middleware.Metadata) (string, bool) {
+ if !metadata.Has(requestIDKey{}) {
+ return "", false
+ }
+
+ v, ok := metadata.Get(requestIDKey{}).(string)
+ if !ok {
+ return "", true
+ }
+ return v, true
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/request_id_retriever.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/request_id_retriever.go
new file mode 100644
index 000000000000..7ce48c611cd1
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/request_id_retriever.go
@@ -0,0 +1,49 @@
+package middleware
+
+import (
+ "context"
+
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// AddRequestIDRetrieverMiddleware adds request id retriever middleware
+func AddRequestIDRetrieverMiddleware(stack *middleware.Stack) error {
+ // add error wrapper middleware before operation deserializers so that it can wrap the error response
+ // returned by operation deserializers
+ return stack.Deserialize.Insert(&requestIDRetriever{}, "OperationDeserializer", middleware.Before)
+}
+
+type requestIDRetriever struct {
+}
+
+// ID returns the middleware identifier
+func (m *requestIDRetriever) ID() string {
+ return "RequestIDRetriever"
+}
+
+func (m *requestIDRetriever) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+
+ resp, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ // No raw response to wrap with.
+ return out, metadata, err
+ }
+
+ // Different header which can map to request id
+ requestIDHeaderList := []string{"X-Amzn-Requestid", "X-Amz-RequestId"}
+
+ for _, h := range requestIDHeaderList {
+ // check for headers known to contain Request id
+ if v := resp.Header.Get(h); len(v) != 0 {
+ // set reqID on metadata for successful responses.
+ SetRequestIDMetadata(&metadata, v)
+ break
+ }
+ }
+
+ return out, metadata, err
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/user_agent.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/user_agent.go
new file mode 100644
index 000000000000..d5adfec90bd4
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/middleware/user_agent.go
@@ -0,0 +1,241 @@
+package middleware
+
+import (
+ "context"
+ "fmt"
+ "os"
+ "runtime"
+ "strings"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+var languageVersion = strings.TrimPrefix(runtime.Version(), "go")
+
+// SDKAgentKeyType is the metadata type to add to the SDK agent string
+type SDKAgentKeyType int
+
+// The set of valid SDKAgentKeyType constants. If an unknown value is assigned for SDKAgentKeyType it will
+// be mapped to AdditionalMetadata.
+const (
+ _ SDKAgentKeyType = iota
+ APIMetadata
+ OperatingSystemMetadata
+ LanguageMetadata
+ EnvironmentMetadata
+ FeatureMetadata
+ ConfigMetadata
+ FrameworkMetadata
+ AdditionalMetadata
+ ApplicationIdentifier
+)
+
+func (k SDKAgentKeyType) string() string {
+ switch k {
+ case APIMetadata:
+ return "api"
+ case OperatingSystemMetadata:
+ return "os"
+ case LanguageMetadata:
+ return "lang"
+ case EnvironmentMetadata:
+ return "exec-env"
+ case FeatureMetadata:
+ return "ft"
+ case ConfigMetadata:
+ return "cfg"
+ case FrameworkMetadata:
+ return "lib"
+ case ApplicationIdentifier:
+ return "app"
+ case AdditionalMetadata:
+ fallthrough
+ default:
+ return "md"
+ }
+}
+
+const execEnvVar = `AWS_EXECUTION_ENV`
+
+// requestUserAgent is a build middleware that set the User-Agent for the request.
+type requestUserAgent struct {
+ sdkAgent, userAgent *smithyhttp.UserAgentBuilder
+}
+
+// newRequestUserAgent returns a new requestUserAgent which will set the User-Agent and X-Amz-User-Agent for the
+// request.
+//
+// User-Agent example:
+// aws-sdk-go-v2/1.2.3
+//
+// X-Amz-User-Agent example:
+// aws-sdk-go-v2/1.2.3 md/GOOS/linux md/GOARCH/amd64 lang/go/1.15
+func newRequestUserAgent() *requestUserAgent {
+ userAgent, sdkAgent := smithyhttp.NewUserAgentBuilder(), smithyhttp.NewUserAgentBuilder()
+ addProductName(userAgent)
+ addProductName(sdkAgent)
+
+ r := &requestUserAgent{
+ sdkAgent: sdkAgent,
+ userAgent: userAgent,
+ }
+
+ addSDKMetadata(r)
+
+ return r
+}
+
+func addSDKMetadata(r *requestUserAgent) {
+ r.AddSDKAgentKey(OperatingSystemMetadata, getNormalizedOSName())
+ r.AddSDKAgentKeyValue(LanguageMetadata, "go", languageVersion)
+ r.AddSDKAgentKeyValue(AdditionalMetadata, "GOOS", runtime.GOOS)
+ r.AddSDKAgentKeyValue(AdditionalMetadata, "GOARCH", runtime.GOARCH)
+ if ev := os.Getenv(execEnvVar); len(ev) > 0 {
+ r.AddSDKAgentKey(EnvironmentMetadata, ev)
+ }
+}
+
+func addProductName(builder *smithyhttp.UserAgentBuilder) {
+ builder.AddKeyValue(aws.SDKName, aws.SDKVersion)
+}
+
+// AddUserAgentKey retrieves a requestUserAgent from the provided stack, or initializes one.
+func AddUserAgentKey(key string) func(*middleware.Stack) error {
+ return func(stack *middleware.Stack) error {
+ requestUserAgent, err := getOrAddRequestUserAgent(stack)
+ if err != nil {
+ return err
+ }
+ requestUserAgent.AddUserAgentKey(key)
+ return nil
+ }
+}
+
+// AddUserAgentKeyValue retrieves a requestUserAgent from the provided stack, or initializes one.
+func AddUserAgentKeyValue(key, value string) func(*middleware.Stack) error {
+ return func(stack *middleware.Stack) error {
+ requestUserAgent, err := getOrAddRequestUserAgent(stack)
+ if err != nil {
+ return err
+ }
+ requestUserAgent.AddUserAgentKeyValue(key, value)
+ return nil
+ }
+}
+
+// AddSDKAgentKey retrieves a requestUserAgent from the provided stack, or initializes one.
+func AddSDKAgentKey(keyType SDKAgentKeyType, key string) func(*middleware.Stack) error {
+ return func(stack *middleware.Stack) error {
+ requestUserAgent, err := getOrAddRequestUserAgent(stack)
+ if err != nil {
+ return err
+ }
+ requestUserAgent.AddSDKAgentKey(keyType, key)
+ return nil
+ }
+}
+
+// AddSDKAgentKeyValue retrieves a requestUserAgent from the provided stack, or initializes one.
+func AddSDKAgentKeyValue(keyType SDKAgentKeyType, key, value string) func(*middleware.Stack) error {
+ return func(stack *middleware.Stack) error {
+ requestUserAgent, err := getOrAddRequestUserAgent(stack)
+ if err != nil {
+ return err
+ }
+ requestUserAgent.AddSDKAgentKeyValue(keyType, key, value)
+ return nil
+ }
+}
+
+// AddRequestUserAgentMiddleware registers a requestUserAgent middleware on the stack if not present.
+func AddRequestUserAgentMiddleware(stack *middleware.Stack) error {
+ _, err := getOrAddRequestUserAgent(stack)
+ return err
+}
+
+func getOrAddRequestUserAgent(stack *middleware.Stack) (*requestUserAgent, error) {
+ id := (*requestUserAgent)(nil).ID()
+ bm, ok := stack.Build.Get(id)
+ if !ok {
+ bm = newRequestUserAgent()
+ err := stack.Build.Add(bm, middleware.After)
+ if err != nil {
+ return nil, err
+ }
+ }
+
+ requestUserAgent, ok := bm.(*requestUserAgent)
+ if !ok {
+ return nil, fmt.Errorf("%T for %s middleware did not match expected type", bm, id)
+ }
+
+ return requestUserAgent, nil
+}
+
+// AddUserAgentKey adds the component identified by name to the User-Agent string.
+func (u *requestUserAgent) AddUserAgentKey(key string) {
+ u.userAgent.AddKey(key)
+}
+
+// AddUserAgentKeyValue adds the key identified by the given name and value to the User-Agent string.
+func (u *requestUserAgent) AddUserAgentKeyValue(key, value string) {
+ u.userAgent.AddKeyValue(key, value)
+}
+
+// AddUserAgentKey adds the component identified by name to the User-Agent string.
+func (u *requestUserAgent) AddSDKAgentKey(keyType SDKAgentKeyType, key string) {
+ // TODO: should target sdkAgent
+ u.userAgent.AddKey(keyType.string() + "/" + key)
+}
+
+// AddUserAgentKeyValue adds the key identified by the given name and value to the User-Agent string.
+func (u *requestUserAgent) AddSDKAgentKeyValue(keyType SDKAgentKeyType, key, value string) {
+ // TODO: should target sdkAgent
+ u.userAgent.AddKeyValue(keyType.string()+"/"+key, value)
+}
+
+// ID the name of the middleware.
+func (u *requestUserAgent) ID() string {
+ return "UserAgent"
+}
+
+// HandleBuild adds or appends the constructed user agent to the request.
+func (u *requestUserAgent) HandleBuild(ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ switch req := in.Request.(type) {
+ case *smithyhttp.Request:
+ u.addHTTPUserAgent(req)
+ // TODO: To be re-enabled
+ // u.addHTTPSDKAgent(req)
+ default:
+ return out, metadata, fmt.Errorf("unknown transport type %T", in)
+ }
+
+ return next.HandleBuild(ctx, in)
+}
+
+func (u *requestUserAgent) addHTTPUserAgent(request *smithyhttp.Request) {
+ const userAgent = "User-Agent"
+ updateHTTPHeader(request, userAgent, u.userAgent.Build())
+}
+
+func (u *requestUserAgent) addHTTPSDKAgent(request *smithyhttp.Request) {
+ const sdkAgent = "X-Amz-User-Agent"
+ updateHTTPHeader(request, sdkAgent, u.sdkAgent.Build())
+}
+
+func updateHTTPHeader(request *smithyhttp.Request, header string, value string) {
+ var current string
+ if v := request.Header[header]; len(v) > 0 {
+ current = v[0]
+ }
+ if len(current) > 0 {
+ current = value + " " + current
+ } else {
+ current = value
+ }
+ request.Header[header] = append(request.Header[header][:0], current)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/array.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/array.go
new file mode 100644
index 000000000000..77dd4d8db8fa
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/array.go
@@ -0,0 +1,61 @@
+package query
+
+import (
+ "fmt"
+ "net/url"
+)
+
+// Array represents the encoding of Query lists and sets. A Query array is a
+// representation of a list of values of a fixed type. A serialized array might
+// look like the following:
+//
+// ListName.member.1=foo
+// &ListName.member.2=bar
+// &Listname.member.3=baz
+type Array struct {
+ // The query values to add the array to.
+ values url.Values
+ // The array's prefix, which includes the names of all parent structures
+ // and ends with the name of the list. For example, the prefix might be
+ // "ParentStructure.ListName". This prefix will be used to form the full
+ // keys for each element in the list. For example, an entry might have the
+ // key "ParentStructure.ListName.member.MemberName.1".
+ //
+ // While this is currently represented as a string that gets added to, it
+ // could also be represented as a stack that only gets condensed into a
+ // string when a finalized key is created. This could potentially reduce
+ // allocations.
+ prefix string
+ // Whether the list is flat or not. A list that is not flat will produce the
+ // following entry to the url.Values for a given entry:
+ // ListName.MemberName.1=value
+ // A list that is flat will produce the following:
+ // ListName.1=value
+ flat bool
+ // The location name of the member. In most cases this should be "member".
+ memberName string
+ // Elements are stored in values, so we keep track of the list size here.
+ size int32
+}
+
+func newArray(values url.Values, prefix string, flat bool, memberName string) *Array {
+ return &Array{
+ values: values,
+ prefix: prefix,
+ flat: flat,
+ memberName: memberName,
+ }
+}
+
+// Value adds a new element to the Query Array. Returns a Value type used to
+// encode the array element.
+func (a *Array) Value() Value {
+ // Query lists start a 1, so adjust the size first
+ a.size++
+ prefix := a.prefix
+ if !a.flat {
+ prefix = fmt.Sprintf("%s.%s", prefix, a.memberName)
+ }
+ // Lists can't have flat members
+ return newValue(a.values, fmt.Sprintf("%s.%d", prefix, a.size), false)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/encoder.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/encoder.go
new file mode 100644
index 000000000000..2ecf9241cdd7
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/encoder.go
@@ -0,0 +1,80 @@
+package query
+
+import (
+ "io"
+ "net/url"
+ "sort"
+)
+
+// Encoder is a Query encoder that supports construction of Query body
+// values using methods.
+type Encoder struct {
+ // The query values that will be built up to manage encoding.
+ values url.Values
+ // The writer that the encoded body will be written to.
+ writer io.Writer
+ Value
+}
+
+// NewEncoder returns a new Query body encoder
+func NewEncoder(writer io.Writer) *Encoder {
+ values := url.Values{}
+ return &Encoder{
+ values: values,
+ writer: writer,
+ Value: newBaseValue(values),
+ }
+}
+
+// Encode returns the []byte slice representing the current
+// state of the Query encoder.
+func (e Encoder) Encode() error {
+ ws, ok := e.writer.(interface{ WriteString(string) (int, error) })
+ if !ok {
+ // Fall back to less optimal byte slice casting if WriteString isn't available.
+ ws = &wrapWriteString{writer: e.writer}
+ }
+
+ // Get the keys and sort them to have a stable output
+ keys := make([]string, 0, len(e.values))
+ for k := range e.values {
+ keys = append(keys, k)
+ }
+ sort.Strings(keys)
+ isFirstEntry := true
+ for _, key := range keys {
+ queryValues := e.values[key]
+ escapedKey := url.QueryEscape(key)
+ for _, value := range queryValues {
+ if !isFirstEntry {
+ if _, err := ws.WriteString(`&`); err != nil {
+ return err
+ }
+ } else {
+ isFirstEntry = false
+ }
+ if _, err := ws.WriteString(escapedKey); err != nil {
+ return err
+ }
+ if _, err := ws.WriteString(`=`); err != nil {
+ return err
+ }
+ if _, err := ws.WriteString(url.QueryEscape(value)); err != nil {
+ return err
+ }
+ }
+ }
+ return nil
+}
+
+// wrapWriteString wraps an io.Writer to provide a WriteString method
+// where one is not available.
+type wrapWriteString struct {
+ writer io.Writer
+}
+
+// WriteString writes a string to the wrapped writer by casting it to
+// a byte array first.
+func (w wrapWriteString) WriteString(v string) (int, error) {
+ return w.writer.Write([]byte(v))
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/map.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/map.go
new file mode 100644
index 000000000000..ab91e357bc9a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/map.go
@@ -0,0 +1,78 @@
+package query
+
+import (
+ "fmt"
+ "net/url"
+)
+
+// Map represents the encoding of Query maps. A Query map is a representation
+// of a mapping of arbitrary string keys to arbitrary values of a fixed type.
+// A Map differs from an Object in that the set of keys is not fixed, in that
+// the values must all be of the same type, and that map entries are ordered.
+// A serialized map might look like the following:
+//
+// MapName.entry.1.key=Foo
+// &MapName.entry.1.value=spam
+// &MapName.entry.2.key=Bar
+// &MapName.entry.2.value=eggs
+type Map struct {
+ // The query values to add the map to.
+ values url.Values
+ // The map's prefix, which includes the names of all parent structures
+ // and ends with the name of the object. For example, the prefix might be
+ // "ParentStructure.MapName". This prefix will be used to form the full
+ // keys for each key-value pair of the map. For example, a value might have
+ // the key "ParentStructure.MapName.1.value".
+ //
+ // While this is currently represented as a string that gets added to, it
+ // could also be represented as a stack that only gets condensed into a
+ // string when a finalized key is created. This could potentially reduce
+ // allocations.
+ prefix string
+ // Whether the map is flat or not. A map that is not flat will produce the
+ // following entries to the url.Values for a given key-value pair:
+ // MapName.entry.1.KeyLocationName=mykey
+ // MapName.entry.1.ValueLocationName=myvalue
+ // A map that is flat will produce the following:
+ // MapName.1.KeyLocationName=mykey
+ // MapName.1.ValueLocationName=myvalue
+ flat bool
+ // The location name of the key. In most cases this should be "key".
+ keyLocationName string
+ // The location name of the value. In most cases this should be "value".
+ valueLocationName string
+ // Elements are stored in values, so we keep track of the list size here.
+ size int32
+}
+
+func newMap(values url.Values, prefix string, flat bool, keyLocationName string, valueLocationName string) *Map {
+ return &Map{
+ values: values,
+ prefix: prefix,
+ flat: flat,
+ keyLocationName: keyLocationName,
+ valueLocationName: valueLocationName,
+ }
+}
+
+// Key adds the given named key to the Query map.
+// Returns a Value encoder that should be used to encode a Query value type.
+func (m *Map) Key(name string) Value {
+ // Query lists start a 1, so adjust the size first
+ m.size++
+ var key string
+ var value string
+ if m.flat {
+ key = fmt.Sprintf("%s.%d.%s", m.prefix, m.size, m.keyLocationName)
+ value = fmt.Sprintf("%s.%d.%s", m.prefix, m.size, m.valueLocationName)
+ } else {
+ key = fmt.Sprintf("%s.entry.%d.%s", m.prefix, m.size, m.keyLocationName)
+ value = fmt.Sprintf("%s.entry.%d.%s", m.prefix, m.size, m.valueLocationName)
+ }
+
+ // The key can only be a string, so we just go ahead and set it here
+ newValue(m.values, key, false).String(name)
+
+ // Maps can't have flat members
+ return newValue(m.values, value, false)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/middleware.go
new file mode 100644
index 000000000000..36034479113b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/middleware.go
@@ -0,0 +1,62 @@
+package query
+
+import (
+ "context"
+ "fmt"
+ "io/ioutil"
+
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// AddAsGetRequestMiddleware adds a middleware to the Serialize stack after the
+// operation serializer that will convert the query request body to a GET
+// operation with the query message in the HTTP request querystring.
+func AddAsGetRequestMiddleware(stack *middleware.Stack) error {
+ return stack.Serialize.Insert(&asGetRequest{}, "OperationSerializer", middleware.After)
+}
+
+type asGetRequest struct{}
+
+func (*asGetRequest) ID() string { return "Query:AsGetRequest" }
+
+func (m *asGetRequest) HandleSerialize(
+ ctx context.Context, input middleware.SerializeInput, next middleware.SerializeHandler,
+) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := input.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("expect smithy HTTP Request, got %T", input.Request)
+ }
+
+ req.Method = "GET"
+
+ // If the stream is not set, nothing else to do.
+ stream := req.GetStream()
+ if stream == nil {
+ return next.HandleSerialize(ctx, input)
+ }
+
+ // Clear the stream since there will not be any body.
+ req.Header.Del("Content-Type")
+ req, err = req.SetStream(nil)
+ if err != nil {
+ return out, metadata, fmt.Errorf("unable update request body %w", err)
+ }
+ input.Request = req
+
+ // Update request query with the body's query string value.
+ delim := ""
+ if len(req.URL.RawQuery) != 0 {
+ delim = "&"
+ }
+
+ b, err := ioutil.ReadAll(stream)
+ if err != nil {
+ return out, metadata, fmt.Errorf("unable to get request body %w", err)
+ }
+ req.URL.RawQuery += delim + string(b)
+
+ return next.HandleSerialize(ctx, input)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/object.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/object.go
new file mode 100644
index 000000000000..debb413dec99
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/object.go
@@ -0,0 +1,56 @@
+package query
+
+import (
+ "fmt"
+ "net/url"
+)
+
+// Object represents the encoding of Query structures and unions. A Query
+// object is a representation of a mapping of string keys to arbitrary
+// values where there is a fixed set of keys whose values each have their
+// own known type. A serialized object might look like the following:
+//
+// ObjectName.Foo=value
+// &ObjectName.Bar=5
+type Object struct {
+ // The query values to add the object to.
+ values url.Values
+ // The object's prefix, which includes the names of all parent structures
+ // and ends with the name of the object. For example, the prefix might be
+ // "ParentStructure.ObjectName". This prefix will be used to form the full
+ // keys for each member of the object. For example, a member might have the
+ // key "ParentStructure.ObjectName.MemberName".
+ //
+ // While this is currently represented as a string that gets added to, it
+ // could also be represented as a stack that only gets condensed into a
+ // string when a finalized key is created. This could potentially reduce
+ // allocations.
+ prefix string
+}
+
+func newObject(values url.Values, prefix string) *Object {
+ return &Object{
+ values: values,
+ prefix: prefix,
+ }
+}
+
+// Key adds the given named key to the Query object.
+// Returns a Value encoder that should be used to encode a Query value type.
+func (o *Object) Key(name string) Value {
+ return o.key(name, false)
+}
+
+// FlatKey adds the given named key to the Query object.
+// Returns a Value encoder that should be used to encode a Query value type. The
+// value will be flattened if it is a map or array.
+func (o *Object) FlatKey(name string) Value {
+ return o.key(name, true)
+}
+
+func (o *Object) key(name string, flatValue bool) Value {
+ if o.prefix != "" {
+ return newValue(o.values, fmt.Sprintf("%s.%s", o.prefix, name), flatValue)
+ }
+ return newValue(o.values, name, flatValue)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/value.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/value.go
new file mode 100644
index 000000000000..302525ab1014
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/query/value.go
@@ -0,0 +1,106 @@
+package query
+
+import (
+ "math/big"
+ "net/url"
+
+ "github.com/aws/smithy-go/encoding/httpbinding"
+)
+
+// Value represents a Query Value type.
+type Value struct {
+ // The query values to add the value to.
+ values url.Values
+ // The value's key, which will form the prefix for complex types.
+ key string
+ // Whether the value should be flattened or not if it's a flattenable type.
+ flat bool
+ queryValue httpbinding.QueryValue
+}
+
+func newValue(values url.Values, key string, flat bool) Value {
+ return Value{
+ values: values,
+ key: key,
+ flat: flat,
+ queryValue: httpbinding.NewQueryValue(values, key, false),
+ }
+}
+
+func newBaseValue(values url.Values) Value {
+ return Value{
+ values: values,
+ queryValue: httpbinding.NewQueryValue(nil, "", false),
+ }
+}
+
+// Array returns a new Array encoder.
+func (qv Value) Array(locationName string) *Array {
+ return newArray(qv.values, qv.key, qv.flat, locationName)
+}
+
+// Object returns a new Object encoder.
+func (qv Value) Object() *Object {
+ return newObject(qv.values, qv.key)
+}
+
+// Map returns a new Map encoder.
+func (qv Value) Map(keyLocationName string, valueLocationName string) *Map {
+ return newMap(qv.values, qv.key, qv.flat, keyLocationName, valueLocationName)
+}
+
+// Base64EncodeBytes encodes v as a base64 query string value.
+// This is intended to enable compatibility with the JSON encoder.
+func (qv Value) Base64EncodeBytes(v []byte) {
+ qv.queryValue.Blob(v)
+}
+
+// Boolean encodes v as a query string value
+func (qv Value) Boolean(v bool) {
+ qv.queryValue.Boolean(v)
+}
+
+// String encodes v as a query string value
+func (qv Value) String(v string) {
+ qv.queryValue.String(v)
+}
+
+// Byte encodes v as a query string value
+func (qv Value) Byte(v int8) {
+ qv.queryValue.Byte(v)
+}
+
+// Short encodes v as a query string value
+func (qv Value) Short(v int16) {
+ qv.queryValue.Short(v)
+}
+
+// Integer encodes v as a query string value
+func (qv Value) Integer(v int32) {
+ qv.queryValue.Integer(v)
+}
+
+// Long encodes v as a query string value
+func (qv Value) Long(v int64) {
+ qv.queryValue.Long(v)
+}
+
+// Float encodes v as a query string value
+func (qv Value) Float(v float32) {
+ qv.queryValue.Float(v)
+}
+
+// Double encodes v as a query string value
+func (qv Value) Double(v float64) {
+ qv.queryValue.Double(v)
+}
+
+// BigInteger encodes v as a query string value
+func (qv Value) BigInteger(v *big.Int) {
+ qv.queryValue.BigInteger(v)
+}
+
+// BigDecimal encodes v as a query string value
+func (qv Value) BigDecimal(v *big.Float) {
+ qv.queryValue.BigDecimal(v)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/restjson/decoder_util.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/restjson/decoder_util.go
new file mode 100644
index 000000000000..1bce78a4d45b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/restjson/decoder_util.go
@@ -0,0 +1,85 @@
+package restjson
+
+import (
+ "encoding/json"
+ "io"
+ "strings"
+
+ "github.com/aws/smithy-go"
+)
+
+// GetErrorInfo util looks for code, __type, and message members in the
+// json body. These members are optionally available, and the function
+// returns the value of member if it is available. This function is useful to
+// identify the error code, msg in a REST JSON error response.
+func GetErrorInfo(decoder *json.Decoder) (errorType string, message string, err error) {
+ var errInfo struct {
+ Code string
+ Type string `json:"__type"`
+ Message string
+ }
+
+ err = decoder.Decode(&errInfo)
+ if err != nil {
+ if err == io.EOF {
+ return errorType, message, nil
+ }
+ return errorType, message, err
+ }
+
+ // assign error type
+ if len(errInfo.Code) != 0 {
+ errorType = errInfo.Code
+ } else if len(errInfo.Type) != 0 {
+ errorType = errInfo.Type
+ }
+
+ // assign error message
+ if len(errInfo.Message) != 0 {
+ message = errInfo.Message
+ }
+
+ // sanitize error
+ if len(errorType) != 0 {
+ errorType = SanitizeErrorCode(errorType)
+ }
+
+ return errorType, message, nil
+}
+
+// SanitizeErrorCode sanitizes the errorCode string .
+// The rule for sanitizing is if a `:` character is present, then take only the
+// contents before the first : character in the value.
+// If a # character is present, then take only the contents after the
+// first # character in the value.
+func SanitizeErrorCode(errorCode string) string {
+ if strings.ContainsAny(errorCode, ":") {
+ errorCode = strings.SplitN(errorCode, ":", 2)[0]
+ }
+
+ if strings.ContainsAny(errorCode, "#") {
+ errorCode = strings.SplitN(errorCode, "#", 2)[1]
+ }
+
+ return errorCode
+}
+
+// GetSmithyGenericAPIError returns smithy generic api error and an error interface.
+// Takes in json decoder, and error Code string as args. The function retrieves error message
+// and error code from the decoder body. If errorCode of length greater than 0 is passed in as
+// an argument, it is used instead.
+func GetSmithyGenericAPIError(decoder *json.Decoder, errorCode string) (*smithy.GenericAPIError, error) {
+ errorType, message, err := GetErrorInfo(decoder)
+ if err != nil {
+ return nil, err
+ }
+
+ if len(errorCode) == 0 {
+ errorCode = errorType
+ }
+
+ return &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: message,
+ }, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/xml/error_utils.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/xml/error_utils.go
new file mode 100644
index 000000000000..c228f7d87858
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/protocol/xml/error_utils.go
@@ -0,0 +1,56 @@
+package xml
+
+import (
+ "encoding/xml"
+ "fmt"
+ "io"
+)
+
+// ErrorComponents represents the error response fields
+// that will be deserialized from an xml error response body
+type ErrorComponents struct {
+ Code string
+ Message string
+ RequestID string
+}
+
+// GetErrorResponseComponents returns the error fields from an xml error response body
+func GetErrorResponseComponents(r io.Reader, noErrorWrapping bool) (ErrorComponents, error) {
+ if noErrorWrapping {
+ var errResponse noWrappedErrorResponse
+ if err := xml.NewDecoder(r).Decode(&errResponse); err != nil && err != io.EOF {
+ return ErrorComponents{}, fmt.Errorf("error while deserializing xml error response: %w", err)
+ }
+ return ErrorComponents{
+ Code: errResponse.Code,
+ Message: errResponse.Message,
+ RequestID: errResponse.RequestID,
+ }, nil
+ }
+
+ var errResponse wrappedErrorResponse
+ if err := xml.NewDecoder(r).Decode(&errResponse); err != nil && err != io.EOF {
+ return ErrorComponents{}, fmt.Errorf("error while deserializing xml error response: %w", err)
+ }
+ return ErrorComponents{
+ Code: errResponse.Code,
+ Message: errResponse.Message,
+ RequestID: errResponse.RequestID,
+ }, nil
+}
+
+// noWrappedErrorResponse represents the error response body with
+// no internal ...
+type wrappedErrorResponse struct {
+ Code string `xml:"Error>Code"`
+ Message string `xml:"Error>Message"`
+ RequestID string `xml:"RequestId"`
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/ratelimit/token_bucket.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/ratelimit/token_bucket.go
new file mode 100644
index 000000000000..f337803f2c1d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/ratelimit/token_bucket.go
@@ -0,0 +1,51 @@
+package ratelimit
+
+import (
+ "sync"
+)
+
+// TokenBucket provides a concurrency safe utility for adding and removing
+// tokens from the available token bucket.
+type TokenBucket struct {
+ capacity uint
+ maxCapacity uint
+ mu sync.Mutex
+}
+
+// NewTokenBucket returns an initialized TokenBucket with the capacity
+// specified.
+func NewTokenBucket(i uint) *TokenBucket {
+ return &TokenBucket{
+ capacity: i,
+ maxCapacity: i,
+ }
+}
+
+// Retrieve attempts to reduce the available tokens by the amount requested. If
+// there are tokens available true will be returned along with the number of
+// available tokens remaining. If amount requested is larger than the available
+// capacity, false will be returned along with the available capacity. If the
+// amount is less than the available capacity
+func (t *TokenBucket) Retrieve(amount uint) (available uint, retrieved bool) {
+ t.mu.Lock()
+ defer t.mu.Unlock()
+
+ if amount > t.capacity {
+ return t.capacity, false
+ }
+
+ t.capacity -= amount
+ return t.capacity, true
+}
+
+// Refund returns the amount of tokens back to the available token bucket, up
+// to the initial capacity.
+func (t *TokenBucket) Refund(amount uint) {
+ t.mu.Lock()
+ defer t.mu.Unlock()
+
+ t.capacity += amount
+ if t.capacity > t.maxCapacity {
+ t.capacity = t.maxCapacity
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/ratelimit/token_rate_limit.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/ratelimit/token_rate_limit.go
new file mode 100644
index 000000000000..d7997f42aca5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/ratelimit/token_rate_limit.go
@@ -0,0 +1,82 @@
+package ratelimit
+
+import (
+ "context"
+ "fmt"
+)
+
+type rateToken struct {
+ tokenCost uint
+ bucket *TokenBucket
+}
+
+func (t rateToken) release() error {
+ t.bucket.Refund(t.tokenCost)
+ return nil
+}
+
+// TokenRateLimit provides a Token Bucket RateLimiter implementation
+// that limits the overall number of retry attempts that can be made across
+// operation invocations.
+type TokenRateLimit struct {
+ bucket *TokenBucket
+}
+
+// NewTokenRateLimit returns an TokenRateLimit with default values.
+// Functional options can configure the retry rate limiter.
+func NewTokenRateLimit(tokens uint) *TokenRateLimit {
+ return &TokenRateLimit{
+ bucket: NewTokenBucket(tokens),
+ }
+}
+
+func isTimeoutError(error) bool {
+ return false
+}
+
+type canceledError struct {
+ Err error
+}
+
+func (c canceledError) CanceledError() bool { return true }
+func (c canceledError) Unwrap() error { return c.Err }
+func (c canceledError) Error() string {
+ return fmt.Sprintf("canceled, %v", c.Err)
+}
+
+// GetToken may cause a available pool of retry quota to be
+// decremented. Will return an error if the decremented value can not be
+// reduced from the retry quota.
+func (l *TokenRateLimit) GetToken(ctx context.Context, cost uint) (func() error, error) {
+ select {
+ case <-ctx.Done():
+ return nil, canceledError{Err: ctx.Err()}
+ default:
+ }
+ if avail, ok := l.bucket.Retrieve(cost); !ok {
+ return nil, QuotaExceededError{Available: avail, Requested: cost}
+ }
+
+ return rateToken{
+ tokenCost: cost,
+ bucket: l.bucket,
+ }.release, nil
+}
+
+// AddTokens increments the token bucket by a fixed amount.
+func (l *TokenRateLimit) AddTokens(v uint) error {
+ l.bucket.Refund(v)
+ return nil
+}
+
+// QuotaExceededError provides the SDK error when the retries for a given
+// token bucket have been exhausted.
+type QuotaExceededError struct {
+ Available uint
+ Requested uint
+}
+
+func (e QuotaExceededError) Error() string {
+ return fmt.Sprintf("retry quota exceeded, %d available, %d requested",
+ e.Available, e.Requested)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/request.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/request.go
new file mode 100644
index 000000000000..d8d00e615823
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/request.go
@@ -0,0 +1,25 @@
+package aws
+
+import (
+ "fmt"
+)
+
+// TODO remove replace with smithy.CanceledError
+
+// RequestCanceledError is the error that will be returned by an API request
+// that was canceled. Requests given a Context may return this error when
+// canceled.
+type RequestCanceledError struct {
+ Err error
+}
+
+// CanceledError returns true to satisfy interfaces checking for canceled errors.
+func (*RequestCanceledError) CanceledError() bool { return true }
+
+// Unwrap returns the underlying error, if there was one.
+func (e *RequestCanceledError) Unwrap() error {
+ return e.Err
+}
+func (e *RequestCanceledError) Error() string {
+ return fmt.Sprintf("request canceled, %v", e.Err)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/doc.go
new file mode 100644
index 000000000000..42ced06e2489
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/doc.go
@@ -0,0 +1,80 @@
+// Package retry provides interfaces and implementations for SDK request retry behavior.
+//
+// Retryer Interface and Implementations
+//
+// This packages defines Retryer interface that is used to either implement custom retry behavior
+// or to extend the existing retry implementations provided by the SDK. This packages provides a single
+// retry implementations: Standard.
+//
+// Standard
+//
+// Standard is the default retryer implementation used by service clients. The standard retryer is a rate limited
+// retryer that has a configurable max attempts to limit the number of retry attempts when a retryable error occurs.
+// In addition, the retryer uses a configurable token bucket to rate limit the retry attempts across the client,
+// and uses an additional delay policy to limit the time between a requests subsequent attempts.
+//
+// By default the standard retryer uses the DefaultRetryables slice of IsErrorRetryable types to determine whether
+// a given error is retryable. By default this list of retryables includes the following:
+// - Retrying errors that implement the RetryableError method, and return true.
+// - Connection Errors
+// - Errors that implement a ConnectionError, Temporary, or Timeout method that return true.
+// - Connection Reset Errors.
+// - net.OpErr types that are dialing errors or are temporary.
+// - HTTP Status Codes: 500, 502, 503, and 504.
+// - API Error Codes
+// - RequestTimeout, RequestTimeoutException
+// - Throttling, ThrottlingException, ThrottledException, RequestThrottledException, TooManyRequestsException,
+// RequestThrottled, SlowDown, EC2ThrottledException
+// - ProvisionedThroughputExceededException, RequestLimitExceeded, BandwidthLimitExceeded, LimitExceededException
+// - TransactionInProgressException, PriorRequestNotComplete
+//
+// The standard retryer will not retry a request in the event if the context associated with the request
+// has been cancelled. Applications must handle this case explicitly if they wish to retry with a different context
+// value.
+//
+// You can configure the standard retryer implementation to fit your applications by constructing a standard retryer
+// using the NewStandard function, and providing one more functional arguments that mutate the StandardOptions
+// structure. StandardOptions provides the ability to modify the token bucket rate limiter, retryable error conditions,
+// and the retry delay policy.
+//
+// For example to modify the default retry attempts for the standard retryer:
+//
+// // configure the custom retryer
+// customRetry := retry.NewStandard(func(o *retry.StandardOptions) {
+// o.MaxAttempts = 5
+// })
+//
+// // create a service client with the retryer
+// s3.NewFromConfig(cfg, func(o *s3.Options) {
+// o.Retryer = customRetry
+// })
+//
+// Utilities
+//
+// A number of package functions have been provided to easily wrap retryer implementations in an implementation agnostic
+// way. These are:
+//
+// AddWithErrorCodes - Provides the ability to add additional API error codes that should be considered retryable
+// in addition to those considered retryable by the provided retryer.
+//
+// AddWithMaxAttempts - Provides the ability to set the max number of attempts for retrying a request by wrapping
+// a retryer implementation.
+//
+// AddWithMaxBackoffDelay - Provides the ability to set the max back off delay that can occur before retrying a
+// request by wrapping a retryer implementation.
+//
+// The following package functions have been provided to easily satisfy different retry interfaces to further customize
+// a given retryer's behavior:
+//
+// BackoffDelayerFunc - Can be used to wrap a function to satisfy the BackoffDelayer interface. For example,
+// you can use this method to easily create custom back off policies to be used with the
+// standard retryer.
+//
+// IsErrorRetryableFunc - Can be used to wrap a function to satisfy the IsErrorRetryable interface. For example,
+// this can be used to extend the standard retryer to add additional logic ot determine if a
+// error should be retried.
+//
+// IsErrorTimeoutFunc - Can be used to wrap a function to satisfy IsErrorTimeout interface. For example,
+// this can be used to extend the standard retryer to add additional logic to determine if an
+// error should be considered a timeout.
+package retry
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/errors.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/errors.go
new file mode 100644
index 000000000000..3e432eefe77f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/errors.go
@@ -0,0 +1,20 @@
+package retry
+
+import "fmt"
+
+// MaxAttemptsError provides the error when the maximum number of attempts have
+// been exceeded.
+type MaxAttemptsError struct {
+ Attempt int
+ Err error
+}
+
+func (e *MaxAttemptsError) Error() string {
+ return fmt.Sprintf("exceeded maximum number of attempts, %d, %v", e.Attempt, e.Err)
+}
+
+// Unwrap returns the nested error causing the max attempts error. Provides the
+// implementation for errors.Is and errors.As to unwrap nested errors.
+func (e *MaxAttemptsError) Unwrap() error {
+ return e.Err
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/jitter_backoff.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/jitter_backoff.go
new file mode 100644
index 000000000000..c266996dea23
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/jitter_backoff.go
@@ -0,0 +1,49 @@
+package retry
+
+import (
+ "math"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/internal/rand"
+ "github.com/aws/aws-sdk-go-v2/internal/timeconv"
+)
+
+// ExponentialJitterBackoff provides backoff delays with jitter based on the
+// number of attempts.
+type ExponentialJitterBackoff struct {
+ maxBackoff time.Duration
+ // precomputed number of attempts needed to reach max backoff.
+ maxBackoffAttempts float64
+
+ randFloat64 func() (float64, error)
+}
+
+// NewExponentialJitterBackoff returns an ExponentialJitterBackoff configured
+// for the max backoff.
+func NewExponentialJitterBackoff(maxBackoff time.Duration) *ExponentialJitterBackoff {
+ return &ExponentialJitterBackoff{
+ maxBackoff: maxBackoff,
+ maxBackoffAttempts: math.Log2(
+ float64(maxBackoff) / float64(time.Second)),
+ randFloat64: rand.CryptoRandFloat64,
+ }
+}
+
+// BackoffDelay returns the duration to wait before the next attempt should be
+// made. Returns an error if unable get a duration.
+func (j *ExponentialJitterBackoff) BackoffDelay(attempt int, err error) (time.Duration, error) {
+ if attempt > int(j.maxBackoffAttempts) {
+ return j.maxBackoff, nil
+ }
+
+ b, err := j.randFloat64()
+ if err != nil {
+ return 0, err
+ }
+
+ // [0.0, 1.0) * 2 ^ attempts
+ ri := int64(1 << uint64(attempt))
+ delaySeconds := b * float64(ri)
+
+ return timeconv.FloatSecondsDur(delaySeconds), nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/metadata.go
new file mode 100644
index 000000000000..7a3f18301863
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/metadata.go
@@ -0,0 +1,52 @@
+package retry
+
+import (
+ awsmiddle "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/smithy-go/middleware"
+)
+
+// attemptResultsKey is a metadata accessor key to retrieve metadata
+// for all request attempts.
+type attemptResultsKey struct {
+}
+
+// GetAttemptResults retrieves attempts results from middleware metadata.
+func GetAttemptResults(metadata middleware.Metadata) (AttemptResults, bool) {
+ m, ok := metadata.Get(attemptResultsKey{}).(AttemptResults)
+ return m, ok
+}
+
+// AttemptResults represents struct containing metadata returned by all request attempts.
+type AttemptResults struct {
+
+ // Results is a slice consisting attempt result from all request attempts.
+ // Results are stored in order request attempt is made.
+ Results []AttemptResult
+}
+
+// AttemptResult represents attempt result returned by a single request attempt.
+type AttemptResult struct {
+
+ // Err is the error if received for the request attempt.
+ Err error
+
+ // Retryable denotes if request may be retried. This states if an
+ // error is considered retryable.
+ Retryable bool
+
+ // Retried indicates if this request was retried.
+ Retried bool
+
+ // ResponseMetadata is any existing metadata passed via the response middlewares.
+ ResponseMetadata middleware.Metadata
+}
+
+// addAttemptResults adds attempt results to middleware metadata
+func addAttemptResults(metadata *middleware.Metadata, v AttemptResults) {
+ metadata.Set(attemptResultsKey{}, v)
+}
+
+// GetRawResponse returns raw response recorded for the attempt result
+func (a AttemptResult) GetRawResponse() interface{} {
+ return awsmiddle.GetRawResponse(a.ResponseMetadata)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/middleware.go
new file mode 100644
index 000000000000..cd7ef0baac30
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/middleware.go
@@ -0,0 +1,277 @@
+package retry
+
+import (
+ "context"
+ "fmt"
+ "strconv"
+ "strings"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddle "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/internal/sdk"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+ smithymiddle "github.com/aws/smithy-go/middleware"
+ "github.com/aws/smithy-go/transport/http"
+)
+
+// RequestCloner is a function that can take an input request type and clone the request
+// for use in a subsequent retry attempt
+type RequestCloner func(interface{}) interface{}
+
+type retryMetadata struct {
+ AttemptNum int
+ AttemptTime time.Time
+ MaxAttempts int
+ AttemptClockSkew time.Duration
+}
+
+// Attempt is a Smithy FinalizeMiddleware that handles retry attempts using the provided
+// Retryer implementation
+type Attempt struct {
+ // Enable the logging of retry attempts performed by the SDK.
+ // This will include logging retry attempts, unretryable errors, and when max attempts are reached.
+ LogAttempts bool
+
+ retryer aws.Retryer
+ requestCloner RequestCloner
+}
+
+// NewAttemptMiddleware returns a new Attempt retry middleware.
+func NewAttemptMiddleware(retryer aws.Retryer, requestCloner RequestCloner, optFns ...func(*Attempt)) *Attempt {
+ m := &Attempt{retryer: retryer, requestCloner: requestCloner}
+ for _, fn := range optFns {
+ fn(m)
+ }
+ return m
+}
+
+// ID returns the middleware identifier
+func (r *Attempt) ID() string {
+ return "Retry"
+}
+
+func (r Attempt) logf(logger logging.Logger, classification logging.Classification, format string, v ...interface{}) {
+ if !r.LogAttempts {
+ return
+ }
+ logger.Logf(classification, format, v...)
+}
+
+// HandleFinalize utilizes the provider Retryer implementation to attempt retries over the next handler
+func (r Attempt) HandleFinalize(ctx context.Context, in smithymiddle.FinalizeInput, next smithymiddle.FinalizeHandler) (
+ out smithymiddle.FinalizeOutput, metadata smithymiddle.Metadata, err error,
+) {
+ var attemptNum int
+ var attemptClockSkew time.Duration
+ var attemptResults AttemptResults
+
+ maxAttempts := r.retryer.MaxAttempts()
+
+ for {
+ attemptNum++
+ attemptInput := in
+ attemptInput.Request = r.requestCloner(attemptInput.Request)
+
+ attemptCtx := setRetryMetadata(ctx, retryMetadata{
+ AttemptNum: attemptNum,
+ AttemptTime: sdk.NowTime().UTC(),
+ MaxAttempts: maxAttempts,
+ AttemptClockSkew: attemptClockSkew,
+ })
+
+ var attemptResult AttemptResult
+
+ out, attemptResult, err = r.handleAttempt(attemptCtx, attemptInput, next)
+
+ var ok bool
+ attemptClockSkew, ok = awsmiddle.GetAttemptSkew(attemptResult.ResponseMetadata)
+ if !ok {
+ attemptClockSkew = 0
+ }
+
+ shouldRetry := attemptResult.Retried
+
+ // add attempt metadata to list of all attempt metadata
+ attemptResults.Results = append(attemptResults.Results, attemptResult)
+
+ if !shouldRetry {
+ // Ensure the last response's metadata is used as the bases for result
+ // metadata returned by the stack.
+ metadata = attemptResult.ResponseMetadata.Clone()
+
+ break
+ }
+ }
+
+ addAttemptResults(&metadata, attemptResults)
+ return out, metadata, err
+}
+
+// handleAttempt handles an individual request attempt.
+func (r Attempt) handleAttempt(ctx context.Context, in smithymiddle.FinalizeInput, next smithymiddle.FinalizeHandler) (
+ out smithymiddle.FinalizeOutput, attemptResult AttemptResult, err error,
+) {
+ defer func() {
+ attemptResult.Err = err
+ }()
+
+ relRetryToken := r.retryer.GetInitialToken()
+ logger := smithymiddle.GetLogger(ctx)
+ service, operation := awsmiddle.GetServiceID(ctx), awsmiddle.GetOperationName(ctx)
+
+ retryMetadata, _ := getRetryMetadata(ctx)
+ attemptNum := retryMetadata.AttemptNum
+ maxAttempts := retryMetadata.MaxAttempts
+
+ if attemptNum > 1 {
+ if rewindable, ok := in.Request.(interface{ RewindStream() error }); ok {
+ if rewindErr := rewindable.RewindStream(); rewindErr != nil {
+ err = fmt.Errorf("failed to rewind transport stream for retry, %w", rewindErr)
+ return out, attemptResult, err
+ }
+ }
+
+ r.logf(logger, logging.Debug, "retrying request %s/%s, attempt %d", service, operation, attemptNum)
+ }
+
+ var metadata smithymiddle.Metadata
+ out, metadata, err = next.HandleFinalize(ctx, in)
+ attemptResult.ResponseMetadata = metadata
+
+ if releaseError := relRetryToken(err); releaseError != nil && err != nil {
+ err = fmt.Errorf("failed to release token after request error, %w", err)
+ return out, attemptResult, err
+ }
+
+ if err == nil {
+ return out, attemptResult, err
+ }
+
+ retryable := r.retryer.IsErrorRetryable(err)
+ if !retryable {
+ r.logf(logger, logging.Debug, "request failed with unretryable error %v", err)
+ return out, attemptResult, err
+ }
+
+ // set retryable to true
+ attemptResult.Retryable = true
+
+ if maxAttempts > 0 && attemptNum >= maxAttempts {
+ r.logf(logger, logging.Debug, "max retry attempts exhausted, max %d", maxAttempts)
+ err = &MaxAttemptsError{
+ Attempt: attemptNum,
+ Err: err,
+ }
+ return out, attemptResult, err
+ }
+
+ relRetryToken, reqErr := r.retryer.GetRetryToken(ctx, err)
+ if reqErr != nil {
+ return out, attemptResult, reqErr
+ }
+
+ retryDelay, reqErr := r.retryer.RetryDelay(attemptNum, err)
+ if reqErr != nil {
+ return out, attemptResult, reqErr
+ }
+
+ if reqErr = sdk.SleepWithContext(ctx, retryDelay); reqErr != nil {
+ err = &aws.RequestCanceledError{Err: reqErr}
+ return out, attemptResult, err
+ }
+
+ attemptResult.Retried = true
+
+ return out, attemptResult, err
+}
+
+// MetricsHeader attaches SDK request metric header for retries to the transport
+type MetricsHeader struct{}
+
+// ID returns the middleware identifier
+func (r *MetricsHeader) ID() string {
+ return "RetryMetricsHeader"
+}
+
+// HandleFinalize attaches the sdk request metric header to the transport layer
+func (r MetricsHeader) HandleFinalize(ctx context.Context, in smithymiddle.FinalizeInput, next smithymiddle.FinalizeHandler) (
+ out smithymiddle.FinalizeOutput, metadata smithymiddle.Metadata, err error,
+) {
+ retryMetadata, _ := getRetryMetadata(ctx)
+
+ const retryMetricHeader = "Amz-Sdk-Request"
+ var parts []string
+
+ parts = append(parts, "attempt="+strconv.Itoa(retryMetadata.AttemptNum))
+ if retryMetadata.MaxAttempts != 0 {
+ parts = append(parts, "max="+strconv.Itoa(retryMetadata.MaxAttempts))
+ }
+
+ var ttl time.Time
+ if deadline, ok := ctx.Deadline(); ok {
+ ttl = deadline
+ }
+
+ // Only append the TTL if it can be determined.
+ if !ttl.IsZero() && retryMetadata.AttemptClockSkew > 0 {
+ const unixTimeFormat = "20060102T150405Z"
+ ttl = ttl.Add(retryMetadata.AttemptClockSkew)
+ parts = append(parts, "ttl="+ttl.Format(unixTimeFormat))
+ }
+
+ switch req := in.Request.(type) {
+ case *http.Request:
+ req.Header[retryMetricHeader] = append(req.Header[retryMetricHeader][:0], strings.Join(parts, "; "))
+ default:
+ return out, metadata, fmt.Errorf("unknown transport type %T", req)
+ }
+
+ return next.HandleFinalize(ctx, in)
+}
+
+type retryMetadataKey struct{}
+
+// getRetryMetadata retrieves retryMetadata from the context and a bool
+// indicating if it was set.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func getRetryMetadata(ctx context.Context) (metadata retryMetadata, ok bool) {
+ metadata, ok = middleware.GetStackValue(ctx, retryMetadataKey{}).(retryMetadata)
+ return metadata, ok
+}
+
+// setRetryMetadata sets the retryMetadata on the context.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func setRetryMetadata(ctx context.Context, metadata retryMetadata) context.Context {
+ return middleware.WithStackValue(ctx, retryMetadataKey{}, metadata)
+}
+
+// AddRetryMiddlewaresOptions is the set of options that can be passed to AddRetryMiddlewares for configuring retry
+// associated middleware.
+type AddRetryMiddlewaresOptions struct {
+ Retryer aws.Retryer
+
+ // Enable the logging of retry attempts performed by the SDK.
+ // This will include logging retry attempts, unretryable errors, and when max attempts are reached.
+ LogRetryAttempts bool
+}
+
+// AddRetryMiddlewares adds retry middleware to operation middleware stack
+func AddRetryMiddlewares(stack *smithymiddle.Stack, options AddRetryMiddlewaresOptions) error {
+ attempt := NewAttemptMiddleware(options.Retryer, http.RequestCloner, func(middleware *Attempt) {
+ middleware.LogAttempts = options.LogRetryAttempts
+ })
+
+ if err := stack.Finalize.Add(attempt, smithymiddle.After); err != nil {
+ return err
+ }
+ if err := stack.Finalize.Add(&MetricsHeader{}, smithymiddle.After); err != nil {
+ return err
+ }
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/retry.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/retry.go
new file mode 100644
index 000000000000..ad81b8c98313
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/retry.go
@@ -0,0 +1,72 @@
+package retry
+
+import (
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+// AddWithErrorCodes returns a Retryer with additional error codes considered
+// for determining if the error should be retried.
+func AddWithErrorCodes(r aws.Retryer, codes ...string) aws.Retryer {
+ retryable := &RetryableErrorCode{
+ Codes: map[string]struct{}{},
+ }
+ for _, c := range codes {
+ retryable.Codes[c] = struct{}{}
+ }
+
+ return &withIsErrorRetryable{
+ Retryer: r,
+ Retryable: retryable,
+ }
+}
+
+type withIsErrorRetryable struct {
+ aws.Retryer
+ Retryable IsErrorRetryable
+}
+
+func (r *withIsErrorRetryable) IsErrorRetryable(err error) bool {
+ if v := r.Retryable.IsErrorRetryable(err); v != aws.UnknownTernary {
+ return v.Bool()
+ }
+ return r.Retryer.IsErrorRetryable(err)
+}
+
+// AddWithMaxAttempts returns a Retryer with MaxAttempts set to the value
+// specified.
+func AddWithMaxAttempts(r aws.Retryer, max int) aws.Retryer {
+ return &withMaxAttempts{
+ Retryer: r,
+ Max: max,
+ }
+}
+
+type withMaxAttempts struct {
+ aws.Retryer
+ Max int
+}
+
+func (w *withMaxAttempts) MaxAttempts() int {
+ return w.Max
+}
+
+// AddWithMaxBackoffDelay returns a retryer wrapping the passed in retryer
+// overriding the RetryDelay behavior for a alternate minimum initial backoff
+// delay.
+func AddWithMaxBackoffDelay(r aws.Retryer, delay time.Duration) aws.Retryer {
+ return &withMaxBackoffDelay{
+ Retryer: r,
+ backoff: NewExponentialJitterBackoff(delay),
+ }
+}
+
+type withMaxBackoffDelay struct {
+ aws.Retryer
+ backoff *ExponentialJitterBackoff
+}
+
+func (r *withMaxBackoffDelay) RetryDelay(attempt int, err error) (time.Duration, error) {
+ return r.backoff.BackoffDelay(attempt, err)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/retryable_error.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/retryable_error.go
new file mode 100644
index 000000000000..c695e6fe5277
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/retryable_error.go
@@ -0,0 +1,186 @@
+package retry
+
+import (
+ "errors"
+ "net"
+ "net/url"
+ "strings"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+// IsErrorRetryable provides the interface of an implementation to determine if
+// a error as the result of an operation is retryable.
+type IsErrorRetryable interface {
+ IsErrorRetryable(error) aws.Ternary
+}
+
+// IsErrorRetryables is a collection of checks to determine of the error is
+// retryable. Iterates through the checks and returns the state of retryable
+// if any check returns something other than unknown.
+type IsErrorRetryables []IsErrorRetryable
+
+// IsErrorRetryable returns if the error is retryable if any of the checks in
+// the list return a value other than unknown.
+func (r IsErrorRetryables) IsErrorRetryable(err error) aws.Ternary {
+ for _, re := range r {
+ if v := re.IsErrorRetryable(err); v != aws.UnknownTernary {
+ return v
+ }
+ }
+ return aws.UnknownTernary
+}
+
+// IsErrorRetryableFunc wraps a function with the IsErrorRetryable interface.
+type IsErrorRetryableFunc func(error) aws.Ternary
+
+// IsErrorRetryable returns if the error is retryable.
+func (fn IsErrorRetryableFunc) IsErrorRetryable(err error) aws.Ternary {
+ return fn(err)
+}
+
+// RetryableError is an IsErrorRetryable implementation which uses the
+// optional interface Retryable on the error value to determine if the error is
+// retryable.
+type RetryableError struct{}
+
+// IsErrorRetryable returns if the error is retryable if it satisfies the
+// Retryable interface, and returns if the attempt should be retried.
+func (RetryableError) IsErrorRetryable(err error) aws.Ternary {
+ var v interface{ RetryableError() bool }
+
+ if !errors.As(err, &v) {
+ return aws.UnknownTernary
+ }
+
+ return aws.BoolTernary(v.RetryableError())
+}
+
+// NoRetryCanceledError detects if the error was an request canceled error and
+// returns if so.
+type NoRetryCanceledError struct{}
+
+// IsErrorRetryable returns the error is not retryable if the request was
+// canceled.
+func (NoRetryCanceledError) IsErrorRetryable(err error) aws.Ternary {
+ var v interface{ CanceledError() bool }
+
+ if !errors.As(err, &v) {
+ return aws.UnknownTernary
+ }
+
+ if v.CanceledError() {
+ return aws.FalseTernary
+ }
+ return aws.UnknownTernary
+}
+
+// RetryableConnectionError determines if the underlying error is an HTTP
+// connection and returns if it should be retried.
+//
+// Includes errors such as connection reset, connection refused, net dial,
+// temporary, and timeout errors.
+type RetryableConnectionError struct{}
+
+// IsErrorRetryable returns if the error is caused by and HTTP connection
+// error, and should be retried.
+func (r RetryableConnectionError) IsErrorRetryable(err error) aws.Ternary {
+ if err == nil {
+ return aws.UnknownTernary
+ }
+ var retryable bool
+
+ var conErr interface{ ConnectionError() bool }
+ var tempErr interface{ Temporary() bool }
+ var timeoutErr interface{ Timeout() bool }
+ var urlErr *url.Error
+ var netOpErr *net.OpError
+
+ switch {
+ case errors.As(err, &conErr) && conErr.ConnectionError():
+ retryable = true
+
+ case strings.Contains(err.Error(), "connection reset"):
+ retryable = true
+
+ case errors.As(err, &urlErr):
+ // Refused connections should be retried as the service may not yet be
+ // running on the port. Go TCP dial considers refused connections as
+ // not temporary.
+ if strings.Contains(urlErr.Error(), "connection refused") {
+ retryable = true
+ } else {
+ return r.IsErrorRetryable(errors.Unwrap(urlErr))
+ }
+
+ case errors.As(err, &netOpErr):
+ // Network dial, or temporary network errors are always retryable.
+ if strings.EqualFold(netOpErr.Op, "dial") || netOpErr.Temporary() {
+ retryable = true
+ } else {
+ return r.IsErrorRetryable(errors.Unwrap(netOpErr))
+ }
+
+ case errors.As(err, &tempErr) && tempErr.Temporary():
+ // Fallback to the generic temporary check, with temporary errors
+ // retryable.
+ retryable = true
+
+ case errors.As(err, &timeoutErr) && timeoutErr.Timeout():
+ // Fallback to the generic timeout check, with timeout errors
+ // retryable.
+ retryable = true
+
+ default:
+ return aws.UnknownTernary
+ }
+
+ return aws.BoolTernary(retryable)
+
+}
+
+// RetryableHTTPStatusCode provides a IsErrorRetryable based on HTTP status
+// codes.
+type RetryableHTTPStatusCode struct {
+ Codes map[int]struct{}
+}
+
+// IsErrorRetryable return if the passed in error is retryable based on the
+// HTTP status code.
+func (r RetryableHTTPStatusCode) IsErrorRetryable(err error) aws.Ternary {
+ var v interface{ HTTPStatusCode() int }
+
+ if !errors.As(err, &v) {
+ return aws.UnknownTernary
+ }
+
+ _, ok := r.Codes[v.HTTPStatusCode()]
+ if !ok {
+ return aws.UnknownTernary
+ }
+
+ return aws.TrueTernary
+}
+
+// RetryableErrorCode determines if an attempt should be retried based on the
+// API error code.
+type RetryableErrorCode struct {
+ Codes map[string]struct{}
+}
+
+// IsErrorRetryable return if the error is retryable based on the error codes.
+// Returns unknown if the error doesn't have a code or it is unknown.
+func (r RetryableErrorCode) IsErrorRetryable(err error) aws.Ternary {
+ var v interface{ ErrorCode() string }
+
+ if !errors.As(err, &v) {
+ return aws.UnknownTernary
+ }
+
+ _, ok := r.Codes[v.ErrorCode()]
+ if !ok {
+ return aws.UnknownTernary
+ }
+
+ return aws.TrueTernary
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/standard.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/standard.go
new file mode 100644
index 000000000000..29afa3bdf056
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/standard.go
@@ -0,0 +1,208 @@
+package retry
+
+import (
+ "context"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws/ratelimit"
+)
+
+// BackoffDelayer provides the interface for determining the delay to before
+// another request attempt, that previously failed.
+type BackoffDelayer interface {
+ BackoffDelay(attempt int, err error) (time.Duration, error)
+}
+
+// BackoffDelayerFunc provides a wrapper around a function to determine the
+// backoff delay of an attempt retry.
+type BackoffDelayerFunc func(int, error) (time.Duration, error)
+
+// BackoffDelay returns the delay before attempt to retry a request.
+func (fn BackoffDelayerFunc) BackoffDelay(attempt int, err error) (time.Duration, error) {
+ return fn(attempt, err)
+}
+
+const (
+ // DefaultMaxAttempts is the maximum of attempts for an API request
+ DefaultMaxAttempts int = 3
+
+ // DefaultMaxBackoff is the maximum back off delay between attempts
+ DefaultMaxBackoff time.Duration = 20 * time.Second
+)
+
+// Default retry token quota values.
+const (
+ DefaultRetryRateTokens uint = 500
+ DefaultRetryCost uint = 5
+ DefaultRetryTimeoutCost uint = 10
+ DefaultNoRetryIncrement uint = 1
+)
+
+// DefaultRetryableHTTPStatusCodes is the default set of HTTP status codes the SDK
+// should consider as retryable errors.
+var DefaultRetryableHTTPStatusCodes = map[int]struct{}{
+ 500: {},
+ 502: {},
+ 503: {},
+ 504: {},
+}
+
+// DefaultRetryableErrorCodes provides the set of API error codes that should
+// be retried.
+var DefaultRetryableErrorCodes = map[string]struct{}{
+ "RequestTimeout": {},
+ "RequestTimeoutException": {},
+
+ // Throttled status codes
+ "Throttling": {},
+ "ThrottlingException": {},
+ "ThrottledException": {},
+ "RequestThrottledException": {},
+ "TooManyRequestsException": {},
+ "ProvisionedThroughputExceededException": {},
+ "TransactionInProgressException": {},
+ "RequestLimitExceeded": {},
+ "BandwidthLimitExceeded": {},
+ "LimitExceededException": {},
+ "RequestThrottled": {},
+ "SlowDown": {},
+ "PriorRequestNotComplete": {},
+ "EC2ThrottledException": {},
+}
+
+// DefaultRetryables provides the set of retryable checks that are used by
+// default.
+var DefaultRetryables = []IsErrorRetryable{
+ NoRetryCanceledError{},
+ RetryableError{},
+ RetryableConnectionError{},
+ RetryableHTTPStatusCode{
+ Codes: DefaultRetryableHTTPStatusCodes,
+ },
+ RetryableErrorCode{
+ Codes: DefaultRetryableErrorCodes,
+ },
+}
+
+// StandardOptions provides the functional options for configuring the standard
+// retryable, and delay behavior.
+type StandardOptions struct {
+ MaxAttempts int
+ MaxBackoff time.Duration
+ Backoff BackoffDelayer
+
+ Retryables []IsErrorRetryable
+ Timeouts []IsErrorTimeout
+
+ RateLimiter RateLimiter
+ RetryCost uint
+ RetryTimeoutCost uint
+ NoRetryIncrement uint
+}
+
+// RateLimiter provides the interface for limiting the rate of request retries
+// allowed by the retrier.
+type RateLimiter interface {
+ GetToken(ctx context.Context, cost uint) (releaseToken func() error, err error)
+ AddTokens(uint) error
+}
+
+// Standard is the standard retry pattern for the SDK. It uses a set of
+// retryable checks to determine of the failed request should be retried, and
+// what retry delay should be used.
+type Standard struct {
+ options StandardOptions
+
+ timeout IsErrorTimeout
+ retryable IsErrorRetryable
+ backoff BackoffDelayer
+}
+
+// NewStandard initializes a standard retry behavior with defaults that can be
+// overridden via functional options.
+func NewStandard(fnOpts ...func(*StandardOptions)) *Standard {
+ o := StandardOptions{
+ MaxAttempts: DefaultMaxAttempts,
+ MaxBackoff: DefaultMaxBackoff,
+ Retryables: DefaultRetryables,
+
+ RateLimiter: ratelimit.NewTokenRateLimit(DefaultRetryRateTokens),
+ RetryCost: DefaultRetryCost,
+ RetryTimeoutCost: DefaultRetryTimeoutCost,
+ NoRetryIncrement: DefaultNoRetryIncrement,
+ }
+ for _, fn := range fnOpts {
+ fn(&o)
+ }
+
+ backoff := o.Backoff
+ if backoff == nil {
+ backoff = NewExponentialJitterBackoff(o.MaxBackoff)
+ }
+
+ rs := make([]IsErrorRetryable, len(o.Retryables))
+ copy(rs, o.Retryables)
+
+ ts := make([]IsErrorTimeout, len(o.Timeouts))
+ copy(ts, o.Timeouts)
+
+ return &Standard{
+ options: o,
+ backoff: backoff,
+ retryable: IsErrorRetryables(rs),
+ timeout: IsErrorTimeouts(ts),
+ }
+}
+
+// MaxAttempts returns the maximum number of attempts that can be made for a
+// request before failing.
+func (s *Standard) MaxAttempts() int {
+ return s.options.MaxAttempts
+}
+
+// IsErrorRetryable returns if the error is can be retried or not. Should not
+// consider the number of attempts made.
+func (s *Standard) IsErrorRetryable(err error) bool {
+ return s.retryable.IsErrorRetryable(err).Bool()
+}
+
+// RetryDelay returns the delay to use before another request attempt is made.
+func (s *Standard) RetryDelay(attempt int, err error) (time.Duration, error) {
+ return s.backoff.BackoffDelay(attempt, err)
+}
+
+// GetInitialToken returns the initial request token that can increment the
+// retry token pool if the request is successful.
+func (s *Standard) GetInitialToken() func(error) error {
+ return releaseToken(s.incrementTokens).release
+}
+
+func (s *Standard) incrementTokens() error {
+ return s.options.RateLimiter.AddTokens(s.options.NoRetryIncrement)
+}
+
+// GetRetryToken attempts to deduct the retry cost from the retry token pool.
+// Returning the token release function, or error.
+func (s *Standard) GetRetryToken(ctx context.Context, err error) (func(error) error, error) {
+ cost := s.options.RetryCost
+ if s.timeout.IsErrorTimeout(err).Bool() {
+ cost = s.options.RetryTimeoutCost
+ }
+
+ fn, err := s.options.RateLimiter.GetToken(ctx, cost)
+ if err != nil {
+ return nil, err
+ }
+
+ return releaseToken(fn).release, nil
+}
+
+type releaseToken func() error
+
+func (f releaseToken) release(err error) error {
+ if err != nil {
+ return nil
+ }
+
+ return f()
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/timeout_error.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/timeout_error.go
new file mode 100644
index 000000000000..3d47870d2dc2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retry/timeout_error.go
@@ -0,0 +1,52 @@
+package retry
+
+import (
+ "errors"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+// IsErrorTimeout provides the interface of an implementation to determine if
+// a error matches.
+type IsErrorTimeout interface {
+ IsErrorTimeout(err error) aws.Ternary
+}
+
+// IsErrorTimeouts is a collection of checks to determine of the error is
+// retryable. Iterates through the checks and returns the state of retryable
+// if any check returns something other than unknown.
+type IsErrorTimeouts []IsErrorTimeout
+
+// IsErrorTimeout returns if the error is retryable if any of the checks in
+// the list return a value other than unknown.
+func (ts IsErrorTimeouts) IsErrorTimeout(err error) aws.Ternary {
+ for _, t := range ts {
+ if v := t.IsErrorTimeout(err); v != aws.UnknownTernary {
+ return v
+ }
+ }
+ return aws.UnknownTernary
+}
+
+// IsErrorTimeoutFunc wraps a function with the IsErrorTimeout interface.
+type IsErrorTimeoutFunc func(error) aws.Ternary
+
+// IsErrorTimeout returns if the error is retryable.
+func (fn IsErrorTimeoutFunc) IsErrorTimeout(err error) aws.Ternary {
+ return fn(err)
+}
+
+// TimeouterError provides the IsErrorTimeout implementation for determining if
+// an error is a timeout based on type with the Timeout method.
+type TimeouterError struct{}
+
+// IsErrorTimeout returns if the error is a timeout error.
+func (t TimeouterError) IsErrorTimeout(err error) aws.Ternary {
+ var v interface{ Timeout() bool }
+
+ if !errors.As(err, &v) {
+ return aws.UnknownTernary
+ }
+
+ return aws.BoolTernary(v.Timeout())
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/retryer.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/retryer.go
new file mode 100644
index 000000000000..0489508ef44a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/retryer.go
@@ -0,0 +1,62 @@
+package aws
+
+import (
+ "context"
+ "fmt"
+ "time"
+)
+
+// Retryer is an interface to determine if a given error from a
+// request should be retried, and if so what backoff delay to apply. The
+// default implementation used by most services is the retry package's Standard
+// type. Which contains basic retry logic using exponential backoff.
+type Retryer interface {
+ // IsErrorRetryable returns if the failed request is retryable. This check
+ // should determine if the error can be retried, or if the error is
+ // terminal.
+ IsErrorRetryable(error) bool
+
+ // MaxAttempts returns the maximum number of attempts that can be made for
+ // a request before failing. A value of 0 implies that the request should
+ // be retried until it succeeds if the errors are retryable.
+ MaxAttempts() int
+
+ // RetryDelay returns the delay that should be used before retrying the
+ // request. Will return error if the if the delay could not be determined.
+ RetryDelay(attempt int, opErr error) (time.Duration, error)
+
+ // GetRetryToken attempts to deduct the retry cost from the retry token pool.
+ // Returning the token release function, or error.
+ GetRetryToken(ctx context.Context, opErr error) (releaseToken func(error) error, err error)
+
+ // GetInitalToken returns the initial request token that can increment the
+ // retry token pool if the request is successful.
+ GetInitialToken() (releaseToken func(error) error)
+}
+
+// NopRetryer provides a RequestRetryDecider implementation that will flag
+// all attempt errors as not retryable, with a max attempts of 1.
+type NopRetryer struct{}
+
+// IsErrorRetryable returns false for all error values.
+func (NopRetryer) IsErrorRetryable(error) bool { return false }
+
+// MaxAttempts always returns 1 for the original request attempt.
+func (NopRetryer) MaxAttempts() int { return 1 }
+
+// RetryDelay is not valid for the NopRetryer. Will always return error.
+func (NopRetryer) RetryDelay(int, error) (time.Duration, error) {
+ return 0, fmt.Errorf("not retrying any request errors")
+}
+
+// GetRetryToken returns a stub function that does nothing.
+func (NopRetryer) GetRetryToken(context.Context, error) (func(error) error, error) {
+ return nopReleaseToken, nil
+}
+
+// GetInitialToken returns a stub function that does nothing.
+func (NopRetryer) GetInitialToken() func(error) error {
+ return nopReleaseToken
+}
+
+func nopReleaseToken(error) error { return nil }
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/cache.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/cache.go
new file mode 100644
index 000000000000..cbf22f1d0b0c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/cache.go
@@ -0,0 +1,115 @@
+package v4
+
+import (
+ "strings"
+ "sync"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+func lookupKey(service, region string) string {
+ var s strings.Builder
+ s.Grow(len(region) + len(service) + 3)
+ s.WriteString(region)
+ s.WriteRune('/')
+ s.WriteString(service)
+ return s.String()
+}
+
+type derivedKey struct {
+ AccessKey string
+ Date time.Time
+ Credential []byte
+}
+
+type derivedKeyCache struct {
+ values map[string]derivedKey
+ mutex sync.RWMutex
+}
+
+func newDerivedKeyCache() derivedKeyCache {
+ return derivedKeyCache{
+ values: make(map[string]derivedKey),
+ }
+}
+
+func (s *derivedKeyCache) Get(credentials aws.Credentials, service, region string, signingTime SigningTime) []byte {
+ key := lookupKey(service, region)
+ s.mutex.RLock()
+ if cred, ok := s.get(key, credentials, signingTime.Time); ok {
+ s.mutex.RUnlock()
+ return cred
+ }
+ s.mutex.RUnlock()
+
+ s.mutex.Lock()
+ if cred, ok := s.get(key, credentials, signingTime.Time); ok {
+ s.mutex.Unlock()
+ return cred
+ }
+ cred := deriveKey(credentials.SecretAccessKey, service, region, signingTime)
+ entry := derivedKey{
+ AccessKey: credentials.AccessKeyID,
+ Date: signingTime.Time,
+ Credential: cred,
+ }
+ s.values[key] = entry
+ s.mutex.Unlock()
+
+ return cred
+}
+
+func (s *derivedKeyCache) get(key string, credentials aws.Credentials, signingTime time.Time) ([]byte, bool) {
+ cacheEntry, ok := s.retrieveFromCache(key)
+ if ok && cacheEntry.AccessKey == credentials.AccessKeyID && isSameDay(signingTime, cacheEntry.Date) {
+ return cacheEntry.Credential, true
+ }
+ return nil, false
+}
+
+func (s *derivedKeyCache) retrieveFromCache(key string) (derivedKey, bool) {
+ if v, ok := s.values[key]; ok {
+ return v, true
+ }
+ return derivedKey{}, false
+}
+
+// SigningKeyDeriver derives a signing key from a set of credentials
+type SigningKeyDeriver struct {
+ cache derivedKeyCache
+}
+
+// NewSigningKeyDeriver returns a new SigningKeyDeriver
+func NewSigningKeyDeriver() *SigningKeyDeriver {
+ return &SigningKeyDeriver{
+ cache: newDerivedKeyCache(),
+ }
+}
+
+// DeriveKey returns a derived signing key from the given credentials to be used with SigV4 signing.
+func (k *SigningKeyDeriver) DeriveKey(credential aws.Credentials, service, region string, signingTime SigningTime) []byte {
+ return k.cache.Get(credential, service, region, signingTime)
+}
+
+func deriveKey(secret, service, region string, t SigningTime) []byte {
+ hmacDate := HMACSHA256([]byte("AWS4"+secret), []byte(t.ShortTimeFormat()))
+ hmacRegion := HMACSHA256(hmacDate, []byte(region))
+ hmacService := HMACSHA256(hmacRegion, []byte(service))
+ return HMACSHA256(hmacService, []byte("aws4_request"))
+}
+
+func isSameDay(x, y time.Time) bool {
+ xYear, xMonth, xDay := x.Date()
+ yYear, yMonth, yDay := y.Date()
+
+ if xYear != yYear {
+ return false
+ }
+
+ if xMonth != yMonth {
+ return false
+ }
+
+ return xDay == yDay
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/const.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/const.go
new file mode 100644
index 000000000000..a23cb003bf77
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/const.go
@@ -0,0 +1,40 @@
+package v4
+
+// Signature Version 4 (SigV4) Constants
+const (
+ // EmptyStringSHA256 is the hex encoded sha256 value of an empty string
+ EmptyStringSHA256 = `e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855`
+
+ // UnsignedPayload indicates that the request payload body is unsigned
+ UnsignedPayload = "UNSIGNED-PAYLOAD"
+
+ // AmzAlgorithmKey indicates the signing algorithm
+ AmzAlgorithmKey = "X-Amz-Algorithm"
+
+ // AmzSecurityTokenKey indicates the security token to be used with temporary credentials
+ AmzSecurityTokenKey = "X-Amz-Security-Token"
+
+ // AmzDateKey is the UTC timestamp for the request in the format YYYYMMDD'T'HHMMSS'Z'
+ AmzDateKey = "X-Amz-Date"
+
+ // AmzCredentialKey is the access key ID and credential scope
+ AmzCredentialKey = "X-Amz-Credential"
+
+ // AmzSignedHeadersKey is the set of headers signed for the request
+ AmzSignedHeadersKey = "X-Amz-SignedHeaders"
+
+ // AmzSignatureKey is the query parameter to store the SigV4 signature
+ AmzSignatureKey = "X-Amz-Signature"
+
+ // TimeFormat is the time format to be used in the X-Amz-Date header or query parameter
+ TimeFormat = "20060102T150405Z"
+
+ // ShortTimeFormat is the shorten time format used in the credential scope
+ ShortTimeFormat = "20060102"
+
+ // ContentSHAKey is the SHA256 of request body
+ ContentSHAKey = "X-Amz-Content-Sha256"
+
+ // StreamingEventsPayload indicates that the request payload body is a signed event stream.
+ StreamingEventsPayload = "STREAMING-AWS4-HMAC-SHA256-EVENTS"
+)
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/header_rules.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/header_rules.go
new file mode 100644
index 000000000000..c61955ad5b9b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/header_rules.go
@@ -0,0 +1,82 @@
+package v4
+
+import (
+ sdkstrings "github.com/aws/aws-sdk-go-v2/internal/strings"
+)
+
+// Rules houses a set of Rule needed for validation of a
+// string value
+type Rules []Rule
+
+// Rule interface allows for more flexible rules and just simply
+// checks whether or not a value adheres to that Rule
+type Rule interface {
+ IsValid(value string) bool
+}
+
+// IsValid will iterate through all rules and see if any rules
+// apply to the value and supports nested rules
+func (r Rules) IsValid(value string) bool {
+ for _, rule := range r {
+ if rule.IsValid(value) {
+ return true
+ }
+ }
+ return false
+}
+
+// MapRule generic Rule for maps
+type MapRule map[string]struct{}
+
+// IsValid for the map Rule satisfies whether it exists in the map
+func (m MapRule) IsValid(value string) bool {
+ _, ok := m[value]
+ return ok
+}
+
+// AllowList is a generic Rule for include listing
+type AllowList struct {
+ Rule
+}
+
+// IsValid for AllowList checks if the value is within the AllowList
+func (w AllowList) IsValid(value string) bool {
+ return w.Rule.IsValid(value)
+}
+
+// ExcludeList is a generic Rule for exclude listing
+type ExcludeList struct {
+ Rule
+}
+
+// IsValid for AllowList checks if the value is within the AllowList
+func (b ExcludeList) IsValid(value string) bool {
+ return !b.Rule.IsValid(value)
+}
+
+// Patterns is a list of strings to match against
+type Patterns []string
+
+// IsValid for Patterns checks each pattern and returns if a match has
+// been found
+func (p Patterns) IsValid(value string) bool {
+ for _, pattern := range p {
+ if sdkstrings.HasPrefixFold(value, pattern) {
+ return true
+ }
+ }
+ return false
+}
+
+// InclusiveRules rules allow for rules to depend on one another
+type InclusiveRules []Rule
+
+// IsValid will return true if all rules are true
+func (r InclusiveRules) IsValid(value string) bool {
+ for _, rule := range r {
+ if !rule.IsValid(value) {
+ return false
+ }
+ }
+ return true
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/headers.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/headers.go
new file mode 100644
index 000000000000..85a1d8f032fb
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/headers.go
@@ -0,0 +1,68 @@
+package v4
+
+// IgnoredHeaders is a list of headers that are ignored during signing
+var IgnoredHeaders = Rules{
+ ExcludeList{
+ MapRule{
+ "Authorization": struct{}{},
+ "User-Agent": struct{}{},
+ "X-Amzn-Trace-Id": struct{}{},
+ },
+ },
+}
+
+// RequiredSignedHeaders is a allow list for Build canonical headers.
+var RequiredSignedHeaders = Rules{
+ AllowList{
+ MapRule{
+ "Cache-Control": struct{}{},
+ "Content-Disposition": struct{}{},
+ "Content-Encoding": struct{}{},
+ "Content-Language": struct{}{},
+ "Content-Md5": struct{}{},
+ "Content-Type": struct{}{},
+ "Expires": struct{}{},
+ "If-Match": struct{}{},
+ "If-Modified-Since": struct{}{},
+ "If-None-Match": struct{}{},
+ "If-Unmodified-Since": struct{}{},
+ "Range": struct{}{},
+ "X-Amz-Acl": struct{}{},
+ "X-Amz-Copy-Source": struct{}{},
+ "X-Amz-Copy-Source-If-Match": struct{}{},
+ "X-Amz-Copy-Source-If-Modified-Since": struct{}{},
+ "X-Amz-Copy-Source-If-None-Match": struct{}{},
+ "X-Amz-Copy-Source-If-Unmodified-Since": struct{}{},
+ "X-Amz-Copy-Source-Range": struct{}{},
+ "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Algorithm": struct{}{},
+ "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Key": struct{}{},
+ "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Key-Md5": struct{}{},
+ "X-Amz-Grant-Full-control": struct{}{},
+ "X-Amz-Grant-Read": struct{}{},
+ "X-Amz-Grant-Read-Acp": struct{}{},
+ "X-Amz-Grant-Write": struct{}{},
+ "X-Amz-Grant-Write-Acp": struct{}{},
+ "X-Amz-Metadata-Directive": struct{}{},
+ "X-Amz-Mfa": struct{}{},
+ "X-Amz-Request-Payer": struct{}{},
+ "X-Amz-Server-Side-Encryption": struct{}{},
+ "X-Amz-Server-Side-Encryption-Aws-Kms-Key-Id": struct{}{},
+ "X-Amz-Server-Side-Encryption-Customer-Algorithm": struct{}{},
+ "X-Amz-Server-Side-Encryption-Customer-Key": struct{}{},
+ "X-Amz-Server-Side-Encryption-Customer-Key-Md5": struct{}{},
+ "X-Amz-Storage-Class": struct{}{},
+ "X-Amz-Website-Redirect-Location": struct{}{},
+ "X-Amz-Content-Sha256": struct{}{},
+ "X-Amz-Tagging": struct{}{},
+ },
+ },
+ Patterns{"X-Amz-Object-Lock-"},
+ Patterns{"X-Amz-Meta-"},
+}
+
+// AllowedQueryHoisting is a allowed list for Build query headers. The boolean value
+// represents whether or not it is a pattern.
+var AllowedQueryHoisting = InclusiveRules{
+ ExcludeList{RequiredSignedHeaders},
+ Patterns{"X-Amz-"},
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/hmac.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/hmac.go
new file mode 100644
index 000000000000..e7fa7a1b1e60
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/hmac.go
@@ -0,0 +1,13 @@
+package v4
+
+import (
+ "crypto/hmac"
+ "crypto/sha256"
+)
+
+// HMACSHA256 computes a HMAC-SHA256 of data given the provided key.
+func HMACSHA256(key []byte, data []byte) []byte {
+ hash := hmac.New(sha256.New, key)
+ hash.Write(data)
+ return hash.Sum(nil)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/host.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/host.go
new file mode 100644
index 000000000000..bf93659a43f3
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/host.go
@@ -0,0 +1,75 @@
+package v4
+
+import (
+ "net/http"
+ "strings"
+)
+
+// SanitizeHostForHeader removes default port from host and updates request.Host
+func SanitizeHostForHeader(r *http.Request) {
+ host := getHost(r)
+ port := portOnly(host)
+ if port != "" && isDefaultPort(r.URL.Scheme, port) {
+ r.Host = stripPort(host)
+ }
+}
+
+// Returns host from request
+func getHost(r *http.Request) string {
+ if r.Host != "" {
+ return r.Host
+ }
+
+ return r.URL.Host
+}
+
+// Hostname returns u.Host, without any port number.
+//
+// If Host is an IPv6 literal with a port number, Hostname returns the
+// IPv6 literal without the square brackets. IPv6 literals may include
+// a zone identifier.
+//
+// Copied from the Go 1.8 standard library (net/url)
+func stripPort(hostport string) string {
+ colon := strings.IndexByte(hostport, ':')
+ if colon == -1 {
+ return hostport
+ }
+ if i := strings.IndexByte(hostport, ']'); i != -1 {
+ return strings.TrimPrefix(hostport[:i], "[")
+ }
+ return hostport[:colon]
+}
+
+// Port returns the port part of u.Host, without the leading colon.
+// If u.Host doesn't contain a port, Port returns an empty string.
+//
+// Copied from the Go 1.8 standard library (net/url)
+func portOnly(hostport string) string {
+ colon := strings.IndexByte(hostport, ':')
+ if colon == -1 {
+ return ""
+ }
+ if i := strings.Index(hostport, "]:"); i != -1 {
+ return hostport[i+len("]:"):]
+ }
+ if strings.Contains(hostport, "]") {
+ return ""
+ }
+ return hostport[colon+len(":"):]
+}
+
+// Returns true if the specified URI is using the standard port
+// (i.e. port 80 for HTTP URIs or 443 for HTTPS URIs)
+func isDefaultPort(scheme, port string) bool {
+ if port == "" {
+ return true
+ }
+
+ lowerCaseScheme := strings.ToLower(scheme)
+ if (lowerCaseScheme == "http" && port == "80") || (lowerCaseScheme == "https" && port == "443") {
+ return true
+ }
+
+ return false
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/scope.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/scope.go
new file mode 100644
index 000000000000..fc7887909e29
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/scope.go
@@ -0,0 +1,13 @@
+package v4
+
+import "strings"
+
+// BuildCredentialScope builds the Signature Version 4 (SigV4) signing scope
+func BuildCredentialScope(signingTime SigningTime, region, service string) string {
+ return strings.Join([]string{
+ signingTime.ShortTimeFormat(),
+ region,
+ service,
+ "aws4_request",
+ }, "/")
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/time.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/time.go
new file mode 100644
index 000000000000..1de06a765d1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/time.go
@@ -0,0 +1,36 @@
+package v4
+
+import "time"
+
+// SigningTime provides a wrapper around a time.Time which provides cached values for SigV4 signing.
+type SigningTime struct {
+ time.Time
+ timeFormat string
+ shortTimeFormat string
+}
+
+// NewSigningTime creates a new SigningTime given a time.Time
+func NewSigningTime(t time.Time) SigningTime {
+ return SigningTime{
+ Time: t,
+ }
+}
+
+// TimeFormat provides a time formatted in the X-Amz-Date format.
+func (m *SigningTime) TimeFormat() string {
+ return m.format(&m.timeFormat, TimeFormat)
+}
+
+// ShortTimeFormat provides a time formatted of 20060102.
+func (m *SigningTime) ShortTimeFormat() string {
+ return m.format(&m.shortTimeFormat, ShortTimeFormat)
+}
+
+func (m *SigningTime) format(target *string, format string) string {
+ if len(*target) > 0 {
+ return *target
+ }
+ v := m.Time.Format(format)
+ *target = v
+ return v
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/util.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/util.go
new file mode 100644
index 000000000000..741019b5f9da
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4/util.go
@@ -0,0 +1,64 @@
+package v4
+
+import (
+ "net/url"
+ "strings"
+)
+
+const doubleSpace = " "
+
+// StripExcessSpaces will rewrite the passed in slice's string values to not
+// contain muliple side-by-side spaces.
+func StripExcessSpaces(str string) string {
+ var j, k, l, m, spaces int
+ // Trim trailing spaces
+ for j = len(str) - 1; j >= 0 && str[j] == ' '; j-- {
+ }
+
+ // Trim leading spaces
+ for k = 0; k < j && str[k] == ' '; k++ {
+ }
+ str = str[k : j+1]
+
+ // Strip multiple spaces.
+ j = strings.Index(str, doubleSpace)
+ if j < 0 {
+ return str
+ }
+
+ buf := []byte(str)
+ for k, m, l = j, j, len(buf); k < l; k++ {
+ if buf[k] == ' ' {
+ if spaces == 0 {
+ // First space.
+ buf[m] = buf[k]
+ m++
+ }
+ spaces++
+ } else {
+ // End of multiple spaces.
+ spaces = 0
+ buf[m] = buf[k]
+ m++
+ }
+ }
+
+ return string(buf[:m])
+}
+
+// GetURIPath returns the escaped URI component from the provided URL
+func GetURIPath(u *url.URL) string {
+ var uri string
+
+ if len(u.Opaque) > 0 {
+ uri = "/" + strings.Join(strings.Split(u.Opaque, "/")[3:], "/")
+ } else {
+ uri = u.EscapedPath()
+ }
+
+ if len(uri) == 0 {
+ uri = "/"
+ }
+
+ return uri
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/middleware.go
new file mode 100644
index 000000000000..3f3bcf456a78
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/middleware.go
@@ -0,0 +1,400 @@
+package v4
+
+import (
+ "context"
+ "crypto/sha256"
+ "encoding/hex"
+ "fmt"
+ "io"
+ "net/http"
+ "strings"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ v4Internal "github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4"
+ "github.com/aws/aws-sdk-go-v2/internal/sdk"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+const computePayloadHashMiddlewareID = "ComputePayloadHash"
+
+// HashComputationError indicates an error occurred while computing the signing hash
+type HashComputationError struct {
+ Err error
+}
+
+// Error is the error message
+func (e *HashComputationError) Error() string {
+ return fmt.Sprintf("failed to compute payload hash: %v", e.Err)
+}
+
+// Unwrap returns the underlying error if one is set
+func (e *HashComputationError) Unwrap() error {
+ return e.Err
+}
+
+// SigningError indicates an error condition occurred while performing SigV4 signing
+type SigningError struct {
+ Err error
+}
+
+func (e *SigningError) Error() string {
+ return fmt.Sprintf("failed to sign request: %v", e.Err)
+}
+
+// Unwrap returns the underlying error cause
+func (e *SigningError) Unwrap() error {
+ return e.Err
+}
+
+// UseDynamicPayloadSigningMiddleware swaps the compute payload sha256 middleware with a resolver middleware that
+// switches between unsigned and signed payload based on TLS state for request.
+// This middleware should not be used for AWS APIs that do not support unsigned payload signing auth.
+// By default, SDK uses this middleware for known AWS APIs that support such TLS based auth selection .
+//
+// Usage example -
+// S3 PutObject API allows unsigned payload signing auth usage when TLS is enabled, and uses this middleware to
+// dynamically switch between unsigned and signed payload based on TLS state for request.
+func UseDynamicPayloadSigningMiddleware(stack *middleware.Stack) error {
+ _, err := stack.Build.Swap(computePayloadHashMiddlewareID, &dynamicPayloadSigningMiddleware{})
+ return err
+}
+
+// dynamicPayloadSigningMiddleware dynamically resolves the middleware that computes and set payload sha256 middleware.
+type dynamicPayloadSigningMiddleware struct {
+}
+
+// ID returns the resolver identifier
+func (m *dynamicPayloadSigningMiddleware) ID() string {
+ return computePayloadHashMiddlewareID
+}
+
+// HandleBuild sets a resolver that directs to the payload sha256 compute handler.
+func (m *dynamicPayloadSigningMiddleware) HandleBuild(
+ ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler,
+) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in.Request)
+ }
+
+ // if TLS is enabled, use unsigned payload when supported
+ if strings.EqualFold(req.URL.Scheme, "https") {
+ return (&unsignedPayload{}).HandleBuild(ctx, in, next)
+ }
+
+ // else fall back to signed payload
+ return (&computePayloadSHA256{}).HandleBuild(ctx, in, next)
+}
+
+// unsignedPayload sets the SigV4 request payload hash to unsigned.
+//
+// Will not set the Unsigned Payload magic SHA value, if a SHA has already been
+// stored in the context. (e.g. application pre-computed SHA256 before making
+// API call).
+//
+// This middleware does not check the X-Amz-Content-Sha256 header, if that
+// header is serialized a middleware must translate it into the context.
+type unsignedPayload struct{}
+
+// AddUnsignedPayloadMiddleware adds unsignedPayload to the operation
+// middleware stack
+func AddUnsignedPayloadMiddleware(stack *middleware.Stack) error {
+ return stack.Build.Add(&unsignedPayload{}, middleware.After)
+}
+
+// ID returns the unsignedPayload identifier
+func (m *unsignedPayload) ID() string {
+ return computePayloadHashMiddlewareID
+}
+
+// HandleBuild sets the payload hash to be an unsigned payload
+func (m *unsignedPayload) HandleBuild(
+ ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler,
+) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ // This should not compute the content SHA256 if the value is already
+ // known. (e.g. application pre-computed SHA256 before making API call).
+ // Does not have any tight coupling to the X-Amz-Content-Sha256 header, if
+ // that header is provided a middleware must translate it into the context.
+ contentSHA := GetPayloadHash(ctx)
+ if len(contentSHA) == 0 {
+ contentSHA = v4Internal.UnsignedPayload
+ }
+
+ ctx = SetPayloadHash(ctx, contentSHA)
+ return next.HandleBuild(ctx, in)
+}
+
+// computePayloadSHA256 computes SHA256 payload hash to sign.
+//
+// Will not set the Unsigned Payload magic SHA value, if a SHA has already been
+// stored in the context. (e.g. application pre-computed SHA256 before making
+// API call).
+//
+// This middleware does not check the X-Amz-Content-Sha256 header, if that
+// header is serialized a middleware must translate it into the context.
+type computePayloadSHA256 struct{}
+
+// AddComputePayloadSHA256Middleware adds computePayloadSHA256 to the
+// operation middleware stack
+func AddComputePayloadSHA256Middleware(stack *middleware.Stack) error {
+ return stack.Build.Add(&computePayloadSHA256{}, middleware.After)
+}
+
+// RemoveComputePayloadSHA256Middleware removes computePayloadSHA256 from the
+// operation middleware stack
+func RemoveComputePayloadSHA256Middleware(stack *middleware.Stack) error {
+ _, err := stack.Build.Remove(computePayloadHashMiddlewareID)
+ return err
+}
+
+// ID is the middleware name
+func (m *computePayloadSHA256) ID() string {
+ return computePayloadHashMiddlewareID
+}
+
+// HandleBuild compute the payload hash for the request payload
+func (m *computePayloadSHA256) HandleBuild(
+ ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler,
+) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &HashComputationError{
+ Err: fmt.Errorf("unexpected request middleware type %T", in.Request),
+ }
+ }
+
+ // This should not compute the content SHA256 if the value is already
+ // known. (e.g. application pre-computed SHA256 before making API call)
+ // Does not have any tight coupling to the X-Amz-Content-Sha256 header, if
+ // that header is provided a middleware must translate it into the context.
+ if contentSHA := GetPayloadHash(ctx); len(contentSHA) != 0 {
+ return next.HandleBuild(ctx, in)
+ }
+
+ hash := sha256.New()
+ if stream := req.GetStream(); stream != nil {
+ _, err = io.Copy(hash, stream)
+ if err != nil {
+ return out, metadata, &HashComputationError{
+ Err: fmt.Errorf("failed to compute payload hash, %w", err),
+ }
+ }
+
+ if err := req.RewindStream(); err != nil {
+ return out, metadata, &HashComputationError{
+ Err: fmt.Errorf("failed to seek body to start, %w", err),
+ }
+ }
+ }
+
+ ctx = SetPayloadHash(ctx, hex.EncodeToString(hash.Sum(nil)))
+
+ return next.HandleBuild(ctx, in)
+}
+
+// SwapComputePayloadSHA256ForUnsignedPayloadMiddleware replaces the
+// ComputePayloadSHA256 middleware with the UnsignedPayload middleware.
+//
+// Use this to disable computing the Payload SHA256 checksum and instead use
+// UNSIGNED-PAYLOAD for the SHA256 value.
+func SwapComputePayloadSHA256ForUnsignedPayloadMiddleware(stack *middleware.Stack) error {
+ _, err := stack.Build.Swap(computePayloadHashMiddlewareID, &unsignedPayload{})
+ return err
+}
+
+// contentSHA256Header sets the X-Amz-Content-Sha256 header value to
+// the Payload hash stored in the context.
+type contentSHA256Header struct{}
+
+// AddContentSHA256HeaderMiddleware adds ContentSHA256Header to the
+// operation middleware stack
+func AddContentSHA256HeaderMiddleware(stack *middleware.Stack) error {
+ return stack.Build.Insert(&contentSHA256Header{}, computePayloadHashMiddlewareID, middleware.After)
+}
+
+// RemoveContentSHA256HeaderMiddleware removes contentSHA256Header middleware
+// from the operation middleware stack
+func RemoveContentSHA256HeaderMiddleware(stack *middleware.Stack) error {
+ _, err := stack.Build.Remove((*contentSHA256Header)(nil).ID())
+ return err
+}
+
+// ID returns the ContentSHA256HeaderMiddleware identifier
+func (m *contentSHA256Header) ID() string {
+ return "SigV4ContentSHA256Header"
+}
+
+// HandleBuild sets the X-Amz-Content-Sha256 header value to the Payload hash
+// stored in the context.
+func (m *contentSHA256Header) HandleBuild(
+ ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler,
+) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &HashComputationError{Err: fmt.Errorf("unexpected request middleware type %T", in.Request)}
+ }
+
+ req.Header.Set(v4Internal.ContentSHAKey, GetPayloadHash(ctx))
+
+ return next.HandleBuild(ctx, in)
+}
+
+// SignHTTPRequestMiddlewareOptions is the configuration options for the SignHTTPRequestMiddleware middleware.
+type SignHTTPRequestMiddlewareOptions struct {
+ CredentialsProvider aws.CredentialsProvider
+ Signer HTTPSigner
+ LogSigning bool
+}
+
+// SignHTTPRequestMiddleware is a `FinalizeMiddleware` implementation for SigV4 HTTP Signing
+type SignHTTPRequestMiddleware struct {
+ credentialsProvider aws.CredentialsProvider
+ signer HTTPSigner
+ logSigning bool
+}
+
+// NewSignHTTPRequestMiddleware constructs a SignHTTPRequestMiddleware using the given Signer for signing requests
+func NewSignHTTPRequestMiddleware(options SignHTTPRequestMiddlewareOptions) *SignHTTPRequestMiddleware {
+ return &SignHTTPRequestMiddleware{
+ credentialsProvider: options.CredentialsProvider,
+ signer: options.Signer,
+ logSigning: options.LogSigning,
+ }
+}
+
+// ID is the SignHTTPRequestMiddleware identifier
+func (s *SignHTTPRequestMiddleware) ID() string {
+ return "Signing"
+}
+
+// HandleFinalize will take the provided input and sign the request using the SigV4 authentication scheme
+func (s *SignHTTPRequestMiddleware) HandleFinalize(ctx context.Context, in middleware.FinalizeInput, next middleware.FinalizeHandler) (
+ out middleware.FinalizeOutput, metadata middleware.Metadata, err error,
+) {
+ if !haveCredentialProvider(s.credentialsProvider) {
+ return next.HandleFinalize(ctx, in)
+ }
+
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &SigningError{Err: fmt.Errorf("unexpected request middleware type %T", in.Request)}
+ }
+
+ signingName, signingRegion := awsmiddleware.GetSigningName(ctx), awsmiddleware.GetSigningRegion(ctx)
+ payloadHash := GetPayloadHash(ctx)
+ if len(payloadHash) == 0 {
+ return out, metadata, &SigningError{Err: fmt.Errorf("computed payload hash missing from context")}
+ }
+
+ credentials, err := s.credentialsProvider.Retrieve(ctx)
+ if err != nil {
+ return out, metadata, &SigningError{Err: fmt.Errorf("failed to retrieve credentials: %w", err)}
+ }
+
+ err = s.signer.SignHTTP(ctx, credentials, req.Request, payloadHash, signingName, signingRegion, sdk.NowTime(),
+ func(o *SignerOptions) {
+ o.Logger = middleware.GetLogger(ctx)
+ o.LogSigning = s.logSigning
+ })
+ if err != nil {
+ return out, metadata, &SigningError{Err: fmt.Errorf("failed to sign http request, %w", err)}
+ }
+
+ ctx = awsmiddleware.SetSigningCredentials(ctx, credentials)
+
+ return next.HandleFinalize(ctx, in)
+}
+
+type streamingEventsPayload struct{}
+
+// AddStreamingEventsPayload adds the streamingEventsPayload middleware to the stack.
+func AddStreamingEventsPayload(stack *middleware.Stack) error {
+ return stack.Build.Add(&streamingEventsPayload{}, middleware.After)
+}
+
+func (s *streamingEventsPayload) ID() string {
+ return computePayloadHashMiddlewareID
+}
+
+func (s *streamingEventsPayload) HandleBuild(
+ ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler,
+) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ contentSHA := GetPayloadHash(ctx)
+ if len(contentSHA) == 0 {
+ contentSHA = v4Internal.StreamingEventsPayload
+ }
+
+ ctx = SetPayloadHash(ctx, contentSHA)
+
+ return next.HandleBuild(ctx, in)
+}
+
+// GetSignedRequestSignature attempts to extract the signature of the request.
+// Returning an error if the request is unsigned, or unable to extract the
+// signature.
+func GetSignedRequestSignature(r *http.Request) ([]byte, error) {
+ const authHeaderSignatureElem = "Signature="
+
+ if auth := r.Header.Get(authorizationHeader); len(auth) != 0 {
+ ps := strings.Split(auth, ", ")
+ for _, p := range ps {
+ if idx := strings.Index(p, authHeaderSignatureElem); idx >= 0 {
+ sig := p[len(authHeaderSignatureElem):]
+ if len(sig) == 0 {
+ return nil, fmt.Errorf("invalid request signature authorization header")
+ }
+ return hex.DecodeString(sig)
+ }
+ }
+ }
+
+ if sig := r.URL.Query().Get("X-Amz-Signature"); len(sig) != 0 {
+ return hex.DecodeString(sig)
+ }
+
+ return nil, fmt.Errorf("request not signed")
+}
+
+func haveCredentialProvider(p aws.CredentialsProvider) bool {
+ if p == nil {
+ return false
+ }
+ switch p.(type) {
+ case aws.AnonymousCredentials,
+ *aws.AnonymousCredentials:
+ return false
+ }
+
+ return true
+}
+
+type payloadHashKey struct{}
+
+// GetPayloadHash retrieves the payload hash to use for signing
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func GetPayloadHash(ctx context.Context) (v string) {
+ v, _ = middleware.GetStackValue(ctx, payloadHashKey{}).(string)
+ return v
+}
+
+// SetPayloadHash sets the payload hash to be used for signing the request
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func SetPayloadHash(ctx context.Context, hash string) context.Context {
+ return middleware.WithStackValue(ctx, payloadHashKey{}, hash)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/presign_middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/presign_middleware.go
new file mode 100644
index 000000000000..e1a066512437
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/presign_middleware.go
@@ -0,0 +1,127 @@
+package v4
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/internal/sdk"
+ "github.com/aws/smithy-go/middleware"
+ smithyHTTP "github.com/aws/smithy-go/transport/http"
+)
+
+// HTTPPresigner is an interface to a SigV4 signer that can sign create a
+// presigned URL for a HTTP requests.
+type HTTPPresigner interface {
+ PresignHTTP(
+ ctx context.Context, credentials aws.Credentials, r *http.Request,
+ payloadHash string, service string, region string, signingTime time.Time,
+ optFns ...func(*SignerOptions),
+ ) (url string, signedHeader http.Header, err error)
+}
+
+// PresignedHTTPRequest provides the URL and signed headers that are included
+// in the presigned URL.
+type PresignedHTTPRequest struct {
+ URL string
+ Method string
+ SignedHeader http.Header
+}
+
+// PresignHTTPRequestMiddlewareOptions is the options for the PresignHTTPRequestMiddleware middleware.
+type PresignHTTPRequestMiddlewareOptions struct {
+ CredentialsProvider aws.CredentialsProvider
+ Presigner HTTPPresigner
+ LogSigning bool
+}
+
+// PresignHTTPRequestMiddleware provides the Finalize middleware for creating a
+// presigned URL for an HTTP request.
+//
+// Will short circuit the middleware stack and not forward onto the next
+// Finalize handler.
+type PresignHTTPRequestMiddleware struct {
+ credentialsProvider aws.CredentialsProvider
+ presigner HTTPPresigner
+ logSigning bool
+}
+
+// NewPresignHTTPRequestMiddleware returns a new PresignHTTPRequestMiddleware
+// initialized with the presigner.
+func NewPresignHTTPRequestMiddleware(options PresignHTTPRequestMiddlewareOptions) *PresignHTTPRequestMiddleware {
+ return &PresignHTTPRequestMiddleware{
+ credentialsProvider: options.CredentialsProvider,
+ presigner: options.Presigner,
+ logSigning: options.LogSigning,
+ }
+}
+
+// ID provides the middleware ID.
+func (*PresignHTTPRequestMiddleware) ID() string { return "PresignHTTPRequest" }
+
+// HandleFinalize will take the provided input and create a presigned url for
+// the http request using the SigV4 presign authentication scheme.
+//
+// Since the signed request is not a valid HTTP request
+func (s *PresignHTTPRequestMiddleware) HandleFinalize(
+ ctx context.Context, in middleware.FinalizeInput, next middleware.FinalizeHandler,
+) (
+ out middleware.FinalizeOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyHTTP.Request)
+ if !ok {
+ return out, metadata, &SigningError{
+ Err: fmt.Errorf("unexpected request middleware type %T", in.Request),
+ }
+ }
+
+ httpReq := req.Build(ctx)
+ if !haveCredentialProvider(s.credentialsProvider) {
+ out.Result = &PresignedHTTPRequest{
+ URL: httpReq.URL.String(),
+ Method: httpReq.Method,
+ SignedHeader: http.Header{},
+ }
+
+ return out, metadata, nil
+ }
+
+ signingName := awsmiddleware.GetSigningName(ctx)
+ signingRegion := awsmiddleware.GetSigningRegion(ctx)
+ payloadHash := GetPayloadHash(ctx)
+ if len(payloadHash) == 0 {
+ return out, metadata, &SigningError{
+ Err: fmt.Errorf("computed payload hash missing from context"),
+ }
+ }
+
+ credentials, err := s.credentialsProvider.Retrieve(ctx)
+ if err != nil {
+ return out, metadata, &SigningError{
+ Err: fmt.Errorf("failed to retrieve credentials: %w", err),
+ }
+ }
+
+ u, h, err := s.presigner.PresignHTTP(ctx, credentials,
+ httpReq, payloadHash, signingName, signingRegion, sdk.NowTime(),
+ func(o *SignerOptions) {
+ o.Logger = middleware.GetLogger(ctx)
+ o.LogSigning = s.logSigning
+ })
+ if err != nil {
+ return out, metadata, &SigningError{
+ Err: fmt.Errorf("failed to sign http request, %w", err),
+ }
+ }
+
+ out.Result = &PresignedHTTPRequest{
+ URL: u,
+ Method: httpReq.Method,
+ SignedHeader: h,
+ }
+
+ return out, metadata, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/stream.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/stream.go
new file mode 100644
index 000000000000..66aa2bd6ab0f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/stream.go
@@ -0,0 +1,86 @@
+package v4
+
+import (
+ "context"
+ "crypto/sha256"
+ "encoding/hex"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ v4Internal "github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4"
+ "strings"
+ "time"
+)
+
+// EventStreamSigner is an AWS EventStream protocol signer.
+type EventStreamSigner interface {
+ GetSignature(ctx context.Context, headers, payload []byte, signingTime time.Time, optFns ...func(*StreamSignerOptions)) ([]byte, error)
+}
+
+// StreamSignerOptions is the configuration options for StreamSigner.
+type StreamSignerOptions struct{}
+
+// StreamSigner implements Signature Version 4 (SigV4) signing of event stream encoded payloads.
+type StreamSigner struct {
+ options StreamSignerOptions
+
+ credentials aws.Credentials
+ service string
+ region string
+
+ prevSignature []byte
+
+ signingKeyDeriver *v4Internal.SigningKeyDeriver
+}
+
+// NewStreamSigner returns a new AWS EventStream protocol signer.
+func NewStreamSigner(credentials aws.Credentials, service, region string, seedSignature []byte, optFns ...func(*StreamSignerOptions)) *StreamSigner {
+ o := StreamSignerOptions{}
+
+ for _, fn := range optFns {
+ fn(&o)
+ }
+
+ return &StreamSigner{
+ options: o,
+ credentials: credentials,
+ service: service,
+ region: region,
+ signingKeyDeriver: v4Internal.NewSigningKeyDeriver(),
+ prevSignature: seedSignature,
+ }
+}
+
+// GetSignature signs the provided header and payload bytes.
+func (s *StreamSigner) GetSignature(ctx context.Context, headers, payload []byte, signingTime time.Time, optFns ...func(*StreamSignerOptions)) ([]byte, error) {
+ options := s.options
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ prevSignature := s.prevSignature
+
+ st := v4Internal.NewSigningTime(signingTime)
+
+ sigKey := s.signingKeyDeriver.DeriveKey(s.credentials, s.service, s.region, st)
+
+ scope := v4Internal.BuildCredentialScope(st, s.region, s.service)
+
+ stringToSign := s.buildEventStreamStringToSign(headers, payload, prevSignature, scope, &st)
+
+ signature := v4Internal.HMACSHA256(sigKey, []byte(stringToSign))
+ s.prevSignature = signature
+
+ return signature, nil
+}
+
+func (s *StreamSigner) buildEventStreamStringToSign(headers, payload, previousSignature []byte, credentialScope string, signingTime *v4Internal.SigningTime) string {
+ hash := sha256.New()
+ return strings.Join([]string{
+ "AWS4-HMAC-SHA256-PAYLOAD",
+ signingTime.TimeFormat(),
+ credentialScope,
+ hex.EncodeToString(previousSignature),
+ hex.EncodeToString(makeHash(hash, headers)),
+ hex.EncodeToString(makeHash(hash, payload)),
+ }, "\n")
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/v4.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/v4.go
new file mode 100644
index 000000000000..1d1525ad86ff
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/signer/v4/v4.go
@@ -0,0 +1,534 @@
+// Package v4 implements signing for AWS V4 signer
+//
+// Provides request signing for request that need to be signed with
+// AWS V4 Signatures.
+//
+// Standalone Signer
+//
+// Generally using the signer outside of the SDK should not require any additional
+// The signer does this by taking advantage of the URL.EscapedPath method. If your request URI requires
+// additional escaping you many need to use the URL.Opaque to define what the raw URI should be sent
+// to the service as.
+//
+// The signer will first check the URL.Opaque field, and use its value if set.
+// The signer does require the URL.Opaque field to be set in the form of:
+//
+// "///"
+//
+// // e.g.
+// "//example.com/some/path"
+//
+// The leading "//" and hostname are required or the URL.Opaque escaping will
+// not work correctly.
+//
+// If URL.Opaque is not set the signer will fallback to the URL.EscapedPath()
+// method and using the returned value.
+//
+// AWS v4 signature validation requires that the canonical string's URI path
+// element must be the URI escaped form of the HTTP request's path.
+// http://docs.aws.amazon.com/general/latest/gr/sigv4-create-canonical-request.html
+//
+// The Go HTTP client will perform escaping automatically on the request. Some
+// of these escaping may cause signature validation errors because the HTTP
+// request differs from the URI path or query that the signature was generated.
+// https://golang.org/pkg/net/url/#URL.EscapedPath
+//
+// Because of this, it is recommended that when using the signer outside of the
+// SDK that explicitly escaping the request prior to being signed is preferable,
+// and will help prevent signature validation errors. This can be done by setting
+// the URL.Opaque or URL.RawPath. The SDK will use URL.Opaque first and then
+// call URL.EscapedPath() if Opaque is not set.
+//
+// Test `TestStandaloneSign` provides a complete example of using the signer
+// outside of the SDK and pre-escaping the URI path.
+package v4
+
+import (
+ "context"
+ "crypto/sha256"
+ "encoding/hex"
+ "fmt"
+ "hash"
+ "net/http"
+ "net/textproto"
+ "net/url"
+ "sort"
+ "strconv"
+ "strings"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ v4Internal "github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4"
+ "github.com/aws/smithy-go/encoding/httpbinding"
+ "github.com/aws/smithy-go/logging"
+)
+
+const (
+ signingAlgorithm = "AWS4-HMAC-SHA256"
+ authorizationHeader = "Authorization"
+)
+
+// HTTPSigner is an interface to a SigV4 signer that can sign HTTP requests
+type HTTPSigner interface {
+ SignHTTP(ctx context.Context, credentials aws.Credentials, r *http.Request, payloadHash string, service string, region string, signingTime time.Time, optFns ...func(*SignerOptions)) error
+}
+
+type keyDerivator interface {
+ DeriveKey(credential aws.Credentials, service, region string, signingTime v4Internal.SigningTime) []byte
+}
+
+// SignerOptions is the SigV4 Signer options.
+type SignerOptions struct {
+ // Disables the Signer's moving HTTP header key/value pairs from the HTTP
+ // request header to the request's query string. This is most commonly used
+ // with pre-signed requests preventing headers from being added to the
+ // request's query string.
+ DisableHeaderHoisting bool
+
+ // Disables the automatic escaping of the URI path of the request for the
+ // siganture's canonical string's path. For services that do not need additional
+ // escaping then use this to disable the signer escaping the path.
+ //
+ // S3 is an example of a service that does not need additional escaping.
+ //
+ // http://docs.aws.amazon.com/general/latest/gr/sigv4-create-canonical-request.html
+ DisableURIPathEscaping bool
+
+ // The logger to send log messages to.
+ Logger logging.Logger
+
+ // Enable logging of signed requests.
+ // This will enable logging of the canonical request, the string to sign, and for presigning the subsequent
+ // presigned URL.
+ LogSigning bool
+}
+
+// Signer applies AWS v4 signing to given request. Use this to sign requests
+// that need to be signed with AWS V4 Signatures.
+type Signer struct {
+ options SignerOptions
+ keyDerivator keyDerivator
+}
+
+// NewSigner returns a new SigV4 Signer
+func NewSigner(optFns ...func(signer *SignerOptions)) *Signer {
+ options := SignerOptions{}
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &Signer{options: options, keyDerivator: v4Internal.NewSigningKeyDeriver()}
+}
+
+type httpSigner struct {
+ Request *http.Request
+ ServiceName string
+ Region string
+ Time v4Internal.SigningTime
+ Credentials aws.Credentials
+ KeyDerivator keyDerivator
+ IsPreSign bool
+
+ PayloadHash string
+
+ DisableHeaderHoisting bool
+ DisableURIPathEscaping bool
+}
+
+func (s *httpSigner) Build() (signedRequest, error) {
+ req := s.Request
+
+ query := req.URL.Query()
+ headers := req.Header
+
+ s.setRequiredSigningFields(headers, query)
+
+ // Sort Each Query Key's Values
+ for key := range query {
+ sort.Strings(query[key])
+ }
+
+ v4Internal.SanitizeHostForHeader(req)
+
+ credentialScope := s.buildCredentialScope()
+ credentialStr := s.Credentials.AccessKeyID + "/" + credentialScope
+ if s.IsPreSign {
+ query.Set(v4Internal.AmzCredentialKey, credentialStr)
+ }
+
+ unsignedHeaders := headers
+ if s.IsPreSign && !s.DisableHeaderHoisting {
+ var urlValues url.Values
+ urlValues, unsignedHeaders = buildQuery(v4Internal.AllowedQueryHoisting, headers)
+ for k := range urlValues {
+ query[k] = urlValues[k]
+ }
+ }
+
+ host := req.URL.Host
+ if len(req.Host) > 0 {
+ host = req.Host
+ }
+
+ signedHeaders, signedHeadersStr, canonicalHeaderStr := s.buildCanonicalHeaders(host, v4Internal.IgnoredHeaders, unsignedHeaders, s.Request.ContentLength)
+
+ if s.IsPreSign {
+ query.Set(v4Internal.AmzSignedHeadersKey, signedHeadersStr)
+ }
+
+ var rawQuery strings.Builder
+ rawQuery.WriteString(strings.Replace(query.Encode(), "+", "%20", -1))
+
+ canonicalURI := v4Internal.GetURIPath(req.URL)
+ if !s.DisableURIPathEscaping {
+ canonicalURI = httpbinding.EscapePath(canonicalURI, false)
+ }
+
+ canonicalString := s.buildCanonicalString(
+ req.Method,
+ canonicalURI,
+ rawQuery.String(),
+ signedHeadersStr,
+ canonicalHeaderStr,
+ )
+
+ strToSign := s.buildStringToSign(credentialScope, canonicalString)
+ signingSignature, err := s.buildSignature(strToSign)
+ if err != nil {
+ return signedRequest{}, err
+ }
+
+ if s.IsPreSign {
+ rawQuery.WriteString("&X-Amz-Signature=")
+ rawQuery.WriteString(signingSignature)
+ } else {
+ headers[authorizationHeader] = append(headers[authorizationHeader][:0], buildAuthorizationHeader(credentialStr, signedHeadersStr, signingSignature))
+ }
+
+ req.URL.RawQuery = rawQuery.String()
+
+ return signedRequest{
+ Request: req,
+ SignedHeaders: signedHeaders,
+ CanonicalString: canonicalString,
+ StringToSign: strToSign,
+ PreSigned: s.IsPreSign,
+ }, nil
+}
+
+func buildAuthorizationHeader(credentialStr, signedHeadersStr, signingSignature string) string {
+ const credential = "Credential="
+ const signedHeaders = "SignedHeaders="
+ const signature = "Signature="
+ const commaSpace = ", "
+
+ var parts strings.Builder
+ parts.Grow(len(signingAlgorithm) + 1 +
+ len(credential) + len(credentialStr) + 2 +
+ len(signedHeaders) + len(signedHeadersStr) + 2 +
+ len(signature) + len(signingSignature),
+ )
+ parts.WriteString(signingAlgorithm)
+ parts.WriteRune(' ')
+ parts.WriteString(credential)
+ parts.WriteString(credentialStr)
+ parts.WriteString(commaSpace)
+ parts.WriteString(signedHeaders)
+ parts.WriteString(signedHeadersStr)
+ parts.WriteString(commaSpace)
+ parts.WriteString(signature)
+ parts.WriteString(signingSignature)
+ return parts.String()
+}
+
+// SignHTTP signs AWS v4 requests with the provided payload hash, service name, region the
+// request is made to, and time the request is signed at. The signTime allows
+// you to specify that a request is signed for the future, and cannot be
+// used until then.
+//
+// The payloadHash is the hex encoded SHA-256 hash of the request payload, and
+// must be provided. Even if the request has no payload (aka body). If the
+// request has no payload you should use the hex encoded SHA-256 of an empty
+// string as the payloadHash value.
+//
+// "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
+//
+// Some services such as Amazon S3 accept alternative values for the payload
+// hash, such as "UNSIGNED-PAYLOAD" for requests where the body will not be
+// included in the request signature.
+//
+// https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-header-based-auth.html
+//
+// Sign differs from Presign in that it will sign the request using HTTP
+// header values. This type of signing is intended for http.Request values that
+// will not be shared, or are shared in a way the header values on the request
+// will not be lost.
+//
+// The passed in request will be modified in place.
+func (s Signer) SignHTTP(ctx context.Context, credentials aws.Credentials, r *http.Request, payloadHash string, service string, region string, signingTime time.Time, optFns ...func(options *SignerOptions)) error {
+ options := s.options
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ signer := &httpSigner{
+ Request: r,
+ PayloadHash: payloadHash,
+ ServiceName: service,
+ Region: region,
+ Credentials: credentials,
+ Time: v4Internal.NewSigningTime(signingTime.UTC()),
+ DisableHeaderHoisting: options.DisableHeaderHoisting,
+ DisableURIPathEscaping: options.DisableURIPathEscaping,
+ KeyDerivator: s.keyDerivator,
+ }
+
+ signedRequest, err := signer.Build()
+ if err != nil {
+ return err
+ }
+
+ logSigningInfo(ctx, options, &signedRequest, false)
+
+ return nil
+}
+
+// PresignHTTP signs AWS v4 requests with the payload hash, service name, region
+// the request is made to, and time the request is signed at. The signTime
+// allows you to specify that a request is signed for the future, and cannot
+// be used until then.
+//
+// Returns the signed URL and the map of HTTP headers that were included in the
+// signature or an error if signing the request failed. For presigned requests
+// these headers and their values must be included on the HTTP request when it
+// is made. This is helpful to know what header values need to be shared with
+// the party the presigned request will be distributed to.
+//
+// The payloadHash is the hex encoded SHA-256 hash of the request payload, and
+// must be provided. Even if the request has no payload (aka body). If the
+// request has no payload you should use the hex encoded SHA-256 of an empty
+// string as the payloadHash value.
+//
+// "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
+//
+// Some services such as Amazon S3 accept alternative values for the payload
+// hash, such as "UNSIGNED-PAYLOAD" for requests where the body will not be
+// included in the request signature.
+//
+// https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-header-based-auth.html
+//
+// PresignHTTP differs from SignHTTP in that it will sign the request using
+// query string instead of header values. This allows you to share the
+// Presigned Request's URL with third parties, or distribute it throughout your
+// system with minimal dependencies.
+//
+// PresignHTTP will not set the expires time of the presigned request
+// automatically. To specify the expire duration for a request add the
+// "X-Amz-Expires" query parameter on the request with the value as the
+// duration in seconds the presigned URL should be considered valid for. This
+// parameter is not used by all AWS services, and is most notable used by
+// Amazon S3 APIs.
+//
+// expires := 20 * time.Minute
+// query := req.URL.Query()
+// query.Set("X-Amz-Expires", strconv.FormatInt(int64(expires/time.Second), 10)
+// req.URL.RawQuery = query.Encode()
+//
+// This method does not modify the provided request.
+func (s *Signer) PresignHTTP(
+ ctx context.Context, credentials aws.Credentials, r *http.Request,
+ payloadHash string, service string, region string, signingTime time.Time,
+ optFns ...func(*SignerOptions),
+) (signedURI string, signedHeaders http.Header, err error) {
+ options := s.options
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ signer := &httpSigner{
+ Request: r.Clone(r.Context()),
+ PayloadHash: payloadHash,
+ ServiceName: service,
+ Region: region,
+ Credentials: credentials,
+ Time: v4Internal.NewSigningTime(signingTime.UTC()),
+ IsPreSign: true,
+ DisableHeaderHoisting: options.DisableHeaderHoisting,
+ DisableURIPathEscaping: options.DisableURIPathEscaping,
+ KeyDerivator: s.keyDerivator,
+ }
+
+ signedRequest, err := signer.Build()
+ if err != nil {
+ return "", nil, err
+ }
+
+ logSigningInfo(ctx, options, &signedRequest, true)
+
+ signedHeaders = make(http.Header)
+
+ // For the signed headers we canonicalize the header keys in the returned map.
+ // This avoids situations where can standard library double headers like host header. For example the standard
+ // library will set the Host header, even if it is present in lower-case form.
+ for k, v := range signedRequest.SignedHeaders {
+ key := textproto.CanonicalMIMEHeaderKey(k)
+ signedHeaders[key] = append(signedHeaders[key], v...)
+ }
+
+ return signedRequest.Request.URL.String(), signedHeaders, nil
+}
+
+func (s *httpSigner) buildCredentialScope() string {
+ return v4Internal.BuildCredentialScope(s.Time, s.Region, s.ServiceName)
+}
+
+func buildQuery(r v4Internal.Rule, header http.Header) (url.Values, http.Header) {
+ query := url.Values{}
+ unsignedHeaders := http.Header{}
+ for k, h := range header {
+ if r.IsValid(k) {
+ query[k] = h
+ } else {
+ unsignedHeaders[k] = h
+ }
+ }
+
+ return query, unsignedHeaders
+}
+
+func (s *httpSigner) buildCanonicalHeaders(host string, rule v4Internal.Rule, header http.Header, length int64) (signed http.Header, signedHeaders, canonicalHeadersStr string) {
+ signed = make(http.Header)
+
+ var headers []string
+ const hostHeader = "host"
+ headers = append(headers, hostHeader)
+ signed[hostHeader] = append(signed[hostHeader], host)
+
+ if length > 0 {
+ const contentLengthHeader = "content-length"
+ headers = append(headers, contentLengthHeader)
+ signed[contentLengthHeader] = append(signed[contentLengthHeader], strconv.FormatInt(length, 10))
+ }
+
+ for k, v := range header {
+ if !rule.IsValid(k) {
+ continue // ignored header
+ }
+
+ lowerCaseKey := strings.ToLower(k)
+ if _, ok := signed[lowerCaseKey]; ok {
+ // include additional values
+ signed[lowerCaseKey] = append(signed[lowerCaseKey], v...)
+ continue
+ }
+
+ headers = append(headers, lowerCaseKey)
+ signed[lowerCaseKey] = v
+ }
+ sort.Strings(headers)
+
+ signedHeaders = strings.Join(headers, ";")
+
+ var canonicalHeaders strings.Builder
+ n := len(headers)
+ const colon = ':'
+ for i := 0; i < n; i++ {
+ if headers[i] == hostHeader {
+ canonicalHeaders.WriteString(hostHeader)
+ canonicalHeaders.WriteRune(colon)
+ canonicalHeaders.WriteString(v4Internal.StripExcessSpaces(host))
+ } else {
+ canonicalHeaders.WriteString(headers[i])
+ canonicalHeaders.WriteRune(colon)
+ canonicalHeaders.WriteString(strings.Join(signed[headers[i]], ","))
+ }
+ canonicalHeaders.WriteRune('\n')
+ }
+ canonicalHeadersStr = canonicalHeaders.String()
+
+ return signed, signedHeaders, canonicalHeadersStr
+}
+
+func (s *httpSigner) buildCanonicalString(method, uri, query, signedHeaders, canonicalHeaders string) string {
+ return strings.Join([]string{
+ method,
+ uri,
+ query,
+ canonicalHeaders,
+ signedHeaders,
+ s.PayloadHash,
+ }, "\n")
+}
+
+func (s *httpSigner) buildStringToSign(credentialScope, canonicalRequestString string) string {
+ return strings.Join([]string{
+ signingAlgorithm,
+ s.Time.TimeFormat(),
+ credentialScope,
+ hex.EncodeToString(makeHash(sha256.New(), []byte(canonicalRequestString))),
+ }, "\n")
+}
+
+func makeHash(hash hash.Hash, b []byte) []byte {
+ hash.Reset()
+ hash.Write(b)
+ return hash.Sum(nil)
+}
+
+func (s *httpSigner) buildSignature(strToSign string) (string, error) {
+ key := s.KeyDerivator.DeriveKey(s.Credentials, s.ServiceName, s.Region, s.Time)
+ return hex.EncodeToString(v4Internal.HMACSHA256(key, []byte(strToSign))), nil
+}
+
+func (s *httpSigner) setRequiredSigningFields(headers http.Header, query url.Values) {
+ amzDate := s.Time.TimeFormat()
+
+ if s.IsPreSign {
+ query.Set(v4Internal.AmzAlgorithmKey, signingAlgorithm)
+ if sessionToken := s.Credentials.SessionToken; len(sessionToken) > 0 {
+ query.Set("X-Amz-Security-Token", sessionToken)
+ }
+
+ query.Set(v4Internal.AmzDateKey, amzDate)
+ return
+ }
+
+ headers[v4Internal.AmzDateKey] = append(headers[v4Internal.AmzDateKey][:0], amzDate)
+
+ if len(s.Credentials.SessionToken) > 0 {
+ headers[v4Internal.AmzSecurityTokenKey] = append(headers[v4Internal.AmzSecurityTokenKey][:0], s.Credentials.SessionToken)
+ }
+}
+
+func logSigningInfo(ctx context.Context, options SignerOptions, request *signedRequest, isPresign bool) {
+ if !options.LogSigning {
+ return
+ }
+ signedURLMsg := ""
+ if isPresign {
+ signedURLMsg = fmt.Sprintf(logSignedURLMsg, request.Request.URL.String())
+ }
+ logger := logging.WithContext(ctx, options.Logger)
+ logger.Logf(logging.Debug, logSignInfoMsg, request.CanonicalString, request.StringToSign, signedURLMsg)
+}
+
+type signedRequest struct {
+ Request *http.Request
+ SignedHeaders http.Header
+ CanonicalString string
+ StringToSign string
+ PreSigned bool
+}
+
+const logSignInfoMsg = `Request Signature:
+---[ CANONICAL STRING ]-----------------------------
+%s
+---[ STRING TO SIGN ]--------------------------------
+%s%s
+-----------------------------------------------------`
+const logSignedURLMsg = `
+---[ SIGNED URL ]------------------------------------
+%s`
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/to_ptr.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/to_ptr.go
new file mode 100644
index 000000000000..28a193b8a22c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/to_ptr.go
@@ -0,0 +1,280 @@
+// Code generated by aws/generate.go DO NOT EDIT.
+
+package aws
+
+import (
+ "github.com/aws/smithy-go/ptr"
+ "time"
+)
+
+// Bool returns a pointer value for the bool value passed in.
+func Bool(v bool) *bool {
+ return ptr.Bool(v)
+}
+
+// BoolSlice returns a slice of bool pointers from the values
+// passed in.
+func BoolSlice(vs []bool) []*bool {
+ return ptr.BoolSlice(vs)
+}
+
+// BoolMap returns a map of bool pointers from the values
+// passed in.
+func BoolMap(vs map[string]bool) map[string]*bool {
+ return ptr.BoolMap(vs)
+}
+
+// Byte returns a pointer value for the byte value passed in.
+func Byte(v byte) *byte {
+ return ptr.Byte(v)
+}
+
+// ByteSlice returns a slice of byte pointers from the values
+// passed in.
+func ByteSlice(vs []byte) []*byte {
+ return ptr.ByteSlice(vs)
+}
+
+// ByteMap returns a map of byte pointers from the values
+// passed in.
+func ByteMap(vs map[string]byte) map[string]*byte {
+ return ptr.ByteMap(vs)
+}
+
+// String returns a pointer value for the string value passed in.
+func String(v string) *string {
+ return ptr.String(v)
+}
+
+// StringSlice returns a slice of string pointers from the values
+// passed in.
+func StringSlice(vs []string) []*string {
+ return ptr.StringSlice(vs)
+}
+
+// StringMap returns a map of string pointers from the values
+// passed in.
+func StringMap(vs map[string]string) map[string]*string {
+ return ptr.StringMap(vs)
+}
+
+// Int returns a pointer value for the int value passed in.
+func Int(v int) *int {
+ return ptr.Int(v)
+}
+
+// IntSlice returns a slice of int pointers from the values
+// passed in.
+func IntSlice(vs []int) []*int {
+ return ptr.IntSlice(vs)
+}
+
+// IntMap returns a map of int pointers from the values
+// passed in.
+func IntMap(vs map[string]int) map[string]*int {
+ return ptr.IntMap(vs)
+}
+
+// Int8 returns a pointer value for the int8 value passed in.
+func Int8(v int8) *int8 {
+ return ptr.Int8(v)
+}
+
+// Int8Slice returns a slice of int8 pointers from the values
+// passed in.
+func Int8Slice(vs []int8) []*int8 {
+ return ptr.Int8Slice(vs)
+}
+
+// Int8Map returns a map of int8 pointers from the values
+// passed in.
+func Int8Map(vs map[string]int8) map[string]*int8 {
+ return ptr.Int8Map(vs)
+}
+
+// Int16 returns a pointer value for the int16 value passed in.
+func Int16(v int16) *int16 {
+ return ptr.Int16(v)
+}
+
+// Int16Slice returns a slice of int16 pointers from the values
+// passed in.
+func Int16Slice(vs []int16) []*int16 {
+ return ptr.Int16Slice(vs)
+}
+
+// Int16Map returns a map of int16 pointers from the values
+// passed in.
+func Int16Map(vs map[string]int16) map[string]*int16 {
+ return ptr.Int16Map(vs)
+}
+
+// Int32 returns a pointer value for the int32 value passed in.
+func Int32(v int32) *int32 {
+ return ptr.Int32(v)
+}
+
+// Int32Slice returns a slice of int32 pointers from the values
+// passed in.
+func Int32Slice(vs []int32) []*int32 {
+ return ptr.Int32Slice(vs)
+}
+
+// Int32Map returns a map of int32 pointers from the values
+// passed in.
+func Int32Map(vs map[string]int32) map[string]*int32 {
+ return ptr.Int32Map(vs)
+}
+
+// Int64 returns a pointer value for the int64 value passed in.
+func Int64(v int64) *int64 {
+ return ptr.Int64(v)
+}
+
+// Int64Slice returns a slice of int64 pointers from the values
+// passed in.
+func Int64Slice(vs []int64) []*int64 {
+ return ptr.Int64Slice(vs)
+}
+
+// Int64Map returns a map of int64 pointers from the values
+// passed in.
+func Int64Map(vs map[string]int64) map[string]*int64 {
+ return ptr.Int64Map(vs)
+}
+
+// Uint returns a pointer value for the uint value passed in.
+func Uint(v uint) *uint {
+ return ptr.Uint(v)
+}
+
+// UintSlice returns a slice of uint pointers from the values
+// passed in.
+func UintSlice(vs []uint) []*uint {
+ return ptr.UintSlice(vs)
+}
+
+// UintMap returns a map of uint pointers from the values
+// passed in.
+func UintMap(vs map[string]uint) map[string]*uint {
+ return ptr.UintMap(vs)
+}
+
+// Uint8 returns a pointer value for the uint8 value passed in.
+func Uint8(v uint8) *uint8 {
+ return ptr.Uint8(v)
+}
+
+// Uint8Slice returns a slice of uint8 pointers from the values
+// passed in.
+func Uint8Slice(vs []uint8) []*uint8 {
+ return ptr.Uint8Slice(vs)
+}
+
+// Uint8Map returns a map of uint8 pointers from the values
+// passed in.
+func Uint8Map(vs map[string]uint8) map[string]*uint8 {
+ return ptr.Uint8Map(vs)
+}
+
+// Uint16 returns a pointer value for the uint16 value passed in.
+func Uint16(v uint16) *uint16 {
+ return ptr.Uint16(v)
+}
+
+// Uint16Slice returns a slice of uint16 pointers from the values
+// passed in.
+func Uint16Slice(vs []uint16) []*uint16 {
+ return ptr.Uint16Slice(vs)
+}
+
+// Uint16Map returns a map of uint16 pointers from the values
+// passed in.
+func Uint16Map(vs map[string]uint16) map[string]*uint16 {
+ return ptr.Uint16Map(vs)
+}
+
+// Uint32 returns a pointer value for the uint32 value passed in.
+func Uint32(v uint32) *uint32 {
+ return ptr.Uint32(v)
+}
+
+// Uint32Slice returns a slice of uint32 pointers from the values
+// passed in.
+func Uint32Slice(vs []uint32) []*uint32 {
+ return ptr.Uint32Slice(vs)
+}
+
+// Uint32Map returns a map of uint32 pointers from the values
+// passed in.
+func Uint32Map(vs map[string]uint32) map[string]*uint32 {
+ return ptr.Uint32Map(vs)
+}
+
+// Uint64 returns a pointer value for the uint64 value passed in.
+func Uint64(v uint64) *uint64 {
+ return ptr.Uint64(v)
+}
+
+// Uint64Slice returns a slice of uint64 pointers from the values
+// passed in.
+func Uint64Slice(vs []uint64) []*uint64 {
+ return ptr.Uint64Slice(vs)
+}
+
+// Uint64Map returns a map of uint64 pointers from the values
+// passed in.
+func Uint64Map(vs map[string]uint64) map[string]*uint64 {
+ return ptr.Uint64Map(vs)
+}
+
+// Float32 returns a pointer value for the float32 value passed in.
+func Float32(v float32) *float32 {
+ return ptr.Float32(v)
+}
+
+// Float32Slice returns a slice of float32 pointers from the values
+// passed in.
+func Float32Slice(vs []float32) []*float32 {
+ return ptr.Float32Slice(vs)
+}
+
+// Float32Map returns a map of float32 pointers from the values
+// passed in.
+func Float32Map(vs map[string]float32) map[string]*float32 {
+ return ptr.Float32Map(vs)
+}
+
+// Float64 returns a pointer value for the float64 value passed in.
+func Float64(v float64) *float64 {
+ return ptr.Float64(v)
+}
+
+// Float64Slice returns a slice of float64 pointers from the values
+// passed in.
+func Float64Slice(vs []float64) []*float64 {
+ return ptr.Float64Slice(vs)
+}
+
+// Float64Map returns a map of float64 pointers from the values
+// passed in.
+func Float64Map(vs map[string]float64) map[string]*float64 {
+ return ptr.Float64Map(vs)
+}
+
+// Time returns a pointer value for the time.Time value passed in.
+func Time(v time.Time) *time.Time {
+ return ptr.Time(v)
+}
+
+// TimeSlice returns a slice of time.Time pointers from the values
+// passed in.
+func TimeSlice(vs []time.Time) []*time.Time {
+ return ptr.TimeSlice(vs)
+}
+
+// TimeMap returns a map of time.Time pointers from the values
+// passed in.
+func TimeMap(vs map[string]time.Time) map[string]*time.Time {
+ return ptr.TimeMap(vs)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/client.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/client.go
new file mode 100644
index 000000000000..b207a5655d6e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/client.go
@@ -0,0 +1,301 @@
+package http
+
+import (
+ "crypto/tls"
+ "net"
+ "net/http"
+ "reflect"
+ "sync"
+ "time"
+)
+
+// Defaults for the HTTPTransportBuilder.
+var (
+ // Default connection pool options
+ DefaultHTTPTransportMaxIdleConns = 100
+ DefaultHTTPTransportMaxIdleConnsPerHost = 10
+
+ // Default connection timeouts
+ DefaultHTTPTransportIdleConnTimeout = 90 * time.Second
+ DefaultHTTPTransportTLSHandleshakeTimeout = 10 * time.Second
+ DefaultHTTPTransportExpectContinueTimeout = 1 * time.Second
+
+ // Default to TLS 1.2 for all HTTPS requests.
+ DefaultHTTPTransportTLSMinVersion uint16 = tls.VersionTLS12
+)
+
+// Timeouts for net.Dialer's network connection.
+var (
+ DefaultDialConnectTimeout = 30 * time.Second
+ DefaultDialKeepAliveTimeout = 30 * time.Second
+)
+
+// BuildableClient provides a HTTPClient implementation with options to
+// create copies of the HTTPClient when additional configuration is provided.
+//
+// The client's methods will not share the http.Transport value between copies
+// of the BuildableClient. Only exported member values of the Transport and
+// optional Dialer will be copied between copies of BuildableClient.
+type BuildableClient struct {
+ transport *http.Transport
+ dialer *net.Dialer
+
+ initOnce sync.Once
+
+ clientTimeout time.Duration
+ client *http.Client
+}
+
+// NewBuildableClient returns an initialized client for invoking HTTP
+// requests.
+func NewBuildableClient() *BuildableClient {
+ return &BuildableClient{}
+}
+
+// Do implements the HTTPClient interface's Do method to invoke a HTTP request,
+// and receive the response. Uses the BuildableClient's current
+// configuration to invoke the http.Request.
+//
+// If connection pooling is enabled (aka HTTP KeepAlive) the client will only
+// share pooled connections with its own instance. Copies of the
+// BuildableClient will have their own connection pools.
+//
+// Redirect (3xx) responses will not be followed, the HTTP response received
+// will returned instead.
+func (b *BuildableClient) Do(req *http.Request) (*http.Response, error) {
+ b.initOnce.Do(b.build)
+
+ return b.client.Do(req)
+}
+
+func (b *BuildableClient) build() {
+ b.client = wrapWithLimitedRedirect(&http.Client{
+ Timeout: b.clientTimeout,
+ Transport: b.GetTransport(),
+ })
+}
+
+func (b *BuildableClient) clone() *BuildableClient {
+ cpy := NewBuildableClient()
+ cpy.transport = b.GetTransport()
+ cpy.dialer = b.GetDialer()
+ cpy.clientTimeout = b.clientTimeout
+
+ return cpy
+}
+
+// WithTransportOptions copies the BuildableClient and returns it with the
+// http.Transport options applied.
+//
+// If a non (*http.Transport) was set as the round tripper, the round tripper
+// will be replaced with a default Transport value before invoking the option
+// functions.
+func (b *BuildableClient) WithTransportOptions(opts ...func(*http.Transport)) *BuildableClient {
+ cpy := b.clone()
+
+ tr := cpy.GetTransport()
+ for _, opt := range opts {
+ opt(tr)
+ }
+ cpy.transport = tr
+
+ return cpy
+}
+
+// WithDialerOptions copies the BuildableClient and returns it with the
+// net.Dialer options applied. Will set the client's http.Transport DialContext
+// member.
+func (b *BuildableClient) WithDialerOptions(opts ...func(*net.Dialer)) *BuildableClient {
+ cpy := b.clone()
+
+ dialer := cpy.GetDialer()
+ for _, opt := range opts {
+ opt(dialer)
+ }
+ cpy.dialer = dialer
+
+ tr := cpy.GetTransport()
+ tr.DialContext = cpy.dialer.DialContext
+ cpy.transport = tr
+
+ return cpy
+}
+
+// WithTimeout Sets the timeout used by the client for all requests.
+func (b *BuildableClient) WithTimeout(timeout time.Duration) *BuildableClient {
+ cpy := b.clone()
+ cpy.clientTimeout = timeout
+ return cpy
+}
+
+// GetTransport returns a copy of the client's HTTP Transport.
+func (b *BuildableClient) GetTransport() *http.Transport {
+ var tr *http.Transport
+ if b.transport != nil {
+ tr = b.transport.Clone()
+ } else {
+ tr = defaultHTTPTransport()
+ }
+
+ return tr
+}
+
+// GetDialer returns a copy of the client's network dialer.
+func (b *BuildableClient) GetDialer() *net.Dialer {
+ var dialer *net.Dialer
+ if b.dialer != nil {
+ dialer = shallowCopyStruct(b.dialer).(*net.Dialer)
+ } else {
+ dialer = defaultDialer()
+ }
+
+ return dialer
+}
+
+// GetTimeout returns a copy of the client's timeout to cancel requests with.
+func (b *BuildableClient) GetTimeout() time.Duration {
+ return b.clientTimeout
+}
+
+func defaultDialer() *net.Dialer {
+ return &net.Dialer{
+ Timeout: DefaultDialConnectTimeout,
+ KeepAlive: DefaultDialKeepAliveTimeout,
+ DualStack: true,
+ }
+}
+
+func defaultHTTPTransport() *http.Transport {
+ dialer := defaultDialer()
+
+ tr := &http.Transport{
+ Proxy: http.ProxyFromEnvironment,
+ DialContext: dialer.DialContext,
+ TLSHandshakeTimeout: DefaultHTTPTransportTLSHandleshakeTimeout,
+ MaxIdleConns: DefaultHTTPTransportMaxIdleConns,
+ MaxIdleConnsPerHost: DefaultHTTPTransportMaxIdleConnsPerHost,
+ IdleConnTimeout: DefaultHTTPTransportIdleConnTimeout,
+ ExpectContinueTimeout: DefaultHTTPTransportExpectContinueTimeout,
+ ForceAttemptHTTP2: true,
+ TLSClientConfig: &tls.Config{
+ MinVersion: DefaultHTTPTransportTLSMinVersion,
+ },
+ }
+
+ return tr
+}
+
+// shallowCopyStruct creates a shallow copy of the passed in source struct, and
+// returns that copy of the same struct type.
+func shallowCopyStruct(src interface{}) interface{} {
+ srcVal := reflect.ValueOf(src)
+ srcValType := srcVal.Type()
+
+ var returnAsPtr bool
+ if srcValType.Kind() == reflect.Ptr {
+ srcVal = srcVal.Elem()
+ srcValType = srcValType.Elem()
+ returnAsPtr = true
+ }
+ dstVal := reflect.New(srcValType).Elem()
+
+ for i := 0; i < srcValType.NumField(); i++ {
+ ft := srcValType.Field(i)
+ if len(ft.PkgPath) != 0 {
+ // unexported fields have a PkgPath
+ continue
+ }
+
+ dstVal.Field(i).Set(srcVal.Field(i))
+ }
+
+ if returnAsPtr {
+ dstVal = dstVal.Addr()
+ }
+
+ return dstVal.Interface()
+}
+
+// wrapWithLimitedRedirect updates the Client's Transport and CheckRedirect to
+// not follow any redirect other than 307 and 308. No other redirect will be
+// followed.
+//
+// If the client does not have a Transport defined will use a new SDK default
+// http.Transport configuration.
+func wrapWithLimitedRedirect(c *http.Client) *http.Client {
+ tr := c.Transport
+ if tr == nil {
+ tr = defaultHTTPTransport()
+ }
+
+ cc := *c
+ cc.CheckRedirect = limitedRedirect
+ cc.Transport = suppressBadHTTPRedirectTransport{
+ tr: tr,
+ }
+
+ return &cc
+}
+
+// limitedRedirect is a CheckRedirect that prevents the client from following
+// any non 307/308 HTTP status code redirects.
+//
+// The 307 and 308 redirects are allowed because the client must use the
+// original HTTP method for the redirected to location. Whereas 301 and 302
+// allow the client to switch to GET for the redirect.
+//
+// Suppresses all redirect requests with a URL of badHTTPRedirectLocation.
+func limitedRedirect(r *http.Request, via []*http.Request) error {
+ // Request.Response, in CheckRedirect is the response that is triggering
+ // the redirect.
+ resp := r.Response
+ if r.URL.String() == badHTTPRedirectLocation {
+ resp.Header.Del(badHTTPRedirectLocation)
+ return http.ErrUseLastResponse
+ }
+
+ switch resp.StatusCode {
+ case 307, 308:
+ // Only allow 307 and 308 redirects as they preserve the method.
+ return nil
+ }
+
+ return http.ErrUseLastResponse
+}
+
+// suppressBadHTTPRedirectTransport provides an http.RoundTripper
+// implementation that wraps another http.RoundTripper to prevent HTTP client
+// receiving 301 and 302 HTTP responses redirects without the required location
+// header.
+//
+// Clients using this utility must have a CheckRedirect, e.g. limitedRedirect,
+// that check for responses with having a URL of baseHTTPRedirectLocation, and
+// suppress the redirect.
+type suppressBadHTTPRedirectTransport struct {
+ tr http.RoundTripper
+}
+
+const badHTTPRedirectLocation = `https://amazonaws.com/badhttpredirectlocation`
+
+// RoundTrip backfills a stub location when a 301/302 response is received
+// without a location. This stub location is used by limitedRedirect to prevent
+// the HTTP client from failing attempting to use follow a redirect without a
+// location value.
+func (t suppressBadHTTPRedirectTransport) RoundTrip(r *http.Request) (*http.Response, error) {
+ resp, err := t.tr.RoundTrip(r)
+ if err != nil {
+ return resp, err
+ }
+
+ // S3 is the only known service to return 301 without location header.
+ // The Go standard library HTTP client will return an opaque error if it
+ // tries to follow a 301/302 response missing the location header.
+ switch resp.StatusCode {
+ case 301, 302:
+ if v := resp.Header.Get("Location"); len(v) == 0 {
+ resp.Header.Set("Location", badHTTPRedirectLocation)
+ }
+ }
+
+ return resp, err
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/content_type.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/content_type.go
new file mode 100644
index 000000000000..556f54a7f777
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/content_type.go
@@ -0,0 +1,42 @@
+package http
+
+import (
+ "context"
+ "fmt"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// removeContentTypeHeader is a build middleware that removes
+// content type header if content-length header is unset or
+// is set to zero,
+type removeContentTypeHeader struct {
+}
+
+// ID the name of the middleware.
+func (m *removeContentTypeHeader) ID() string {
+ return "RemoveContentTypeHeader"
+}
+
+// HandleBuild adds or appends the constructed user agent to the request.
+func (m *removeContentTypeHeader) HandleBuild(ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in)
+ }
+
+ // remove contentTypeHeader when content-length is zero
+ if req.ContentLength == 0 {
+ req.Header.Del("content-type")
+ }
+
+ return next.HandleBuild(ctx, in)
+}
+
+// RemoveContentTypeHeader removes content-type header if
+// content length is unset or equal to zero.
+func RemoveContentTypeHeader(stack *middleware.Stack) error {
+ return stack.Build.Add(&removeContentTypeHeader{}, middleware.After)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/response_error.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/response_error.go
new file mode 100644
index 000000000000..44651c9902df
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/response_error.go
@@ -0,0 +1,33 @@
+package http
+
+import (
+ "errors"
+ "fmt"
+
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// ResponseError provides the HTTP centric error type wrapping the underlying error
+// with the HTTP response value and the deserialized RequestID.
+type ResponseError struct {
+ *smithyhttp.ResponseError
+
+ // RequestID associated with response error
+ RequestID string
+}
+
+// ServiceRequestID returns the request id associated with Response Error
+func (e *ResponseError) ServiceRequestID() string { return e.RequestID }
+
+// Error returns the formatted error
+func (e *ResponseError) Error() string {
+ return fmt.Sprintf(
+ "https response error StatusCode: %d, RequestID: %s, %v",
+ e.Response.StatusCode, e.RequestID, e.Err)
+}
+
+// As populates target and returns true if the type of target is a error type that
+// the ResponseError embeds, (e.g.AWS HTTP ResponseError)
+func (e *ResponseError) As(target interface{}) bool {
+ return errors.As(e.ResponseError, target)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/response_error_middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/response_error_middleware.go
new file mode 100644
index 000000000000..8fd14cecd231
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/response_error_middleware.go
@@ -0,0 +1,54 @@
+package http
+
+import (
+ "context"
+
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// AddResponseErrorMiddleware adds response error wrapper middleware
+func AddResponseErrorMiddleware(stack *middleware.Stack) error {
+ // add error wrapper middleware before request id retriever middleware so that it can wrap the error response
+ // returned by operation deserializers
+ return stack.Deserialize.Insert(&responseErrorWrapper{}, "RequestIDRetriever", middleware.Before)
+}
+
+type responseErrorWrapper struct {
+}
+
+// ID returns the middleware identifier
+func (m *responseErrorWrapper) ID() string {
+ return "ResponseErrorWrapper"
+}
+
+func (m *responseErrorWrapper) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err == nil {
+ // Nothing to do when there is no error.
+ return out, metadata, err
+ }
+
+ resp, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ // No raw response to wrap with.
+ return out, metadata, err
+ }
+
+ // look for request id in metadata
+ reqID, _ := awsmiddleware.GetRequestIDMetadata(metadata)
+
+ // Wrap the returned smithy error with the request id retrieved from the metadata
+ err = &ResponseError{
+ ResponseError: &smithyhttp.ResponseError{
+ Response: resp,
+ Err: err,
+ },
+ RequestID: reqID,
+ }
+
+ return out, metadata, err
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/timeout_read_closer.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/timeout_read_closer.go
new file mode 100644
index 000000000000..993929bd9b7a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/transport/http/timeout_read_closer.go
@@ -0,0 +1,104 @@
+package http
+
+import (
+ "context"
+ "fmt"
+ "io"
+ "time"
+
+ "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+type readResult struct {
+ n int
+ err error
+}
+
+// ResponseTimeoutError is an error when the reads from the response are
+// delayed longer than the timeout the read was configured for.
+type ResponseTimeoutError struct {
+ TimeoutDur time.Duration
+}
+
+// Timeout returns that the error is was caused by a timeout, and can be
+// retried.
+func (*ResponseTimeoutError) Timeout() bool { return true }
+
+func (e *ResponseTimeoutError) Error() string {
+ return fmt.Sprintf("read on body reach timeout limit, %v", e.TimeoutDur)
+}
+
+// timeoutReadCloser will handle body reads that take too long.
+// We will return a ErrReadTimeout error if a timeout occurs.
+type timeoutReadCloser struct {
+ reader io.ReadCloser
+ duration time.Duration
+}
+
+// Read will spin off a goroutine to call the reader's Read method. We will
+// select on the timer's channel or the read's channel. Whoever completes first
+// will be returned.
+func (r *timeoutReadCloser) Read(b []byte) (int, error) {
+ timer := time.NewTimer(r.duration)
+ c := make(chan readResult, 1)
+
+ go func() {
+ n, err := r.reader.Read(b)
+ timer.Stop()
+ c <- readResult{n: n, err: err}
+ }()
+
+ select {
+ case data := <-c:
+ return data.n, data.err
+ case <-timer.C:
+ return 0, &ResponseTimeoutError{TimeoutDur: r.duration}
+ }
+}
+
+func (r *timeoutReadCloser) Close() error {
+ return r.reader.Close()
+}
+
+// AddResponseReadTimeoutMiddleware adds a middleware to the stack that wraps the
+// response body so that a read that takes too long will return an error.
+func AddResponseReadTimeoutMiddleware(stack *middleware.Stack, duration time.Duration) error {
+ return stack.Deserialize.Add(&readTimeout{duration: duration}, middleware.After)
+}
+
+// readTimeout wraps the response body with a timeoutReadCloser
+type readTimeout struct {
+ duration time.Duration
+}
+
+// ID returns the id of the middleware
+func (*readTimeout) ID() string {
+ return "ReadResponseTimeout"
+}
+
+// HandleDeserialize implements the DeserializeMiddleware interface
+func (m *readTimeout) HandleDeserialize(
+ ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler,
+) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ response.Body = &timeoutReadCloser{
+ reader: response.Body,
+ duration: m.duration,
+ }
+ out.RawResponse = response
+
+ return out, metadata, err
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/aws/types.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/types.go
new file mode 100644
index 000000000000..cc3ae811402d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/types.go
@@ -0,0 +1,42 @@
+package aws
+
+import (
+ "fmt"
+)
+
+// Ternary is an enum allowing an unknown or none state in addition to a bool's
+// true and false.
+type Ternary int
+
+func (t Ternary) String() string {
+ switch t {
+ case UnknownTernary:
+ return "unknown"
+ case FalseTernary:
+ return "false"
+ case TrueTernary:
+ return "true"
+ default:
+ return fmt.Sprintf("unknown value, %d", int(t))
+ }
+}
+
+// Bool returns true if the value is TrueTernary, false otherwise.
+func (t Ternary) Bool() bool {
+ return t == TrueTernary
+}
+
+// Enumerations for the values of the Ternary type.
+const (
+ UnknownTernary Ternary = iota
+ FalseTernary
+ TrueTernary
+)
+
+// BoolTernary returns a true or false Ternary value for the bool provided.
+func BoolTernary(v bool) Ternary {
+ if v {
+ return TrueTernary
+ }
+ return FalseTernary
+}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/version.go b/vendor/github.com/aws/aws-sdk-go-v2/aws/version.go
similarity index 72%
rename from vendor/github.com/aws/aws-sdk-go/aws/version.go
rename to vendor/github.com/aws/aws-sdk-go-v2/aws/version.go
index cc41ca0bcda8..5f729d45e1cd 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/version.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/aws/version.go
@@ -2,7 +2,7 @@
package aws
// SDKName is the name of this AWS SDK
-const SDKName = "aws-sdk-go"
+const SDKName = "aws-sdk-go-v2"
// SDKVersion is the version of this SDK
-const SDKVersion = "1.35.24"
+const SDKVersion = goModuleVersion
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/buildspec.yml b/vendor/github.com/aws/aws-sdk-go-v2/buildspec.yml
new file mode 100644
index 000000000000..b11df5082a4a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/buildspec.yml
@@ -0,0 +1,12 @@
+version: 0.2
+
+phases:
+ build:
+ commands:
+ - echo Build started on `date`
+ - export GOPATH=/go
+ - export SDK_CODEBUILD_ROOT=`pwd`
+ - make ci-test-no-generate
+ post_build:
+ commands:
+ - echo Build completed on `date`
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/config/CHANGELOG.md
new file mode 100644
index 000000000000..e6f94cbd6fd2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/CHANGELOG.md
@@ -0,0 +1,96 @@
+# v1.12.0 (2022-01-07)
+
+* **Feature**: Add load option for CredentialCache. Adds a new member to the LoadOptions struct, CredentialsCacheOptions. This member allows specifying a function that will be used to configure the CredentialsCache. The CredentialsCacheOptions will only be used if the configuration loader will wrap the underlying credential provider in the CredentialsCache.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.11.1 (2021-12-21)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.11.0 (2021-12-02)
+
+* **Feature**: Add support for specifying `EndpointResolverWithOptions` on `LoadOptions`, and associated `WithEndpointResolverWithOptions`.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.10.3 (2021-11-30)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.10.2 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.10.1 (2021-11-12)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.10.0 (2021-11-06)
+
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.9.0 (2021-10-21)
+
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.3 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.2 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.1 (2021-09-10)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.0 (2021-09-02)
+
+* **Feature**: Add support for S3 Multi-Region Access Point ARNs.
+
+# v1.7.0 (2021-08-27)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.1 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.0 (2021-08-04)
+
+* **Feature**: adds error handling for defered close calls
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.0 (2021-07-15)
+
+* **Feature**: Support has been added for EC2 IPv6-enabled Instance Metadata Service Endpoints.
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.1 (2021-07-01)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.0 (2021-06-25)
+
+* **Feature**: Adds configuration setting for enabling endpoint discovery.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.0 (2021-05-20)
+
+* **Feature**: SSO credentials can now be defined alongside other credential providers within the same configuration profile.
+* **Bug Fix**: Profile names were incorrectly normalized to lower-case, which could result in unexpected profile configurations.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.0 (2021-05-14)
+
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/config/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/config.go b/vendor/github.com/aws/aws-sdk-go-v2/config/config.go
new file mode 100644
index 000000000000..83fd1c952f5f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/config.go
@@ -0,0 +1,192 @@
+package config
+
+import (
+ "context"
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+// defaultLoaders are a slice of functions that will read external configuration
+// sources for configuration values. These values are read by the AWSConfigResolvers
+// using interfaces to extract specific information from the external configuration.
+var defaultLoaders = []loader{
+ loadEnvConfig,
+ loadSharedConfigIgnoreNotExist,
+}
+
+// defaultAWSConfigResolvers are a slice of functions that will resolve external
+// configuration values into AWS configuration values.
+//
+// This will setup the AWS configuration's Region,
+var defaultAWSConfigResolvers = []awsConfigResolver{
+ // Resolves the default configuration the SDK's aws.Config will be
+ // initialized with.
+ resolveDefaultAWSConfig,
+
+ // Sets the logger to be used. Could be user provided logger, and client
+ // logging mode.
+ resolveLogger,
+ resolveClientLogMode,
+
+ // Sets the HTTP client and configuration to use for making requests using
+ // the HTTP transport.
+ resolveHTTPClient,
+ resolveCustomCABundle,
+
+ // Sets the endpoint resolving behavior the API Clients will use for making
+ // requests to. Clients default to their own clients this allows overrides
+ // to be specified. The resolveEndpointResolver option is deprecated, but we still need to set it for
+ // backwards compatability on config construction.
+ resolveEndpointResolver,
+ resolveEndpointResolverWithOptions,
+
+ // Sets the retry behavior API clients will use within their retry attempt
+ // middleware. Defaults to unset, allowing API clients to define their own
+ // retry behavior.
+ resolveRetryer,
+
+ // Sets the region the API Clients should use for making requests to.
+ resolveRegion,
+ resolveEC2IMDSRegion,
+ resolveDefaultRegion,
+
+ // Sets the additional set of middleware stack mutators that will custom
+ // API client request pipeline middleware.
+ resolveAPIOptions,
+
+ // Sets the resolved credentials the API clients will use for
+ // authentication. Provides the SDK's default credential chain.
+ //
+ // Should probably be the last step in the resolve chain to ensure that all
+ // other configurations are resolved first in case downstream credentials
+ // implementations depend on or can be configured with earlier resolved
+ // configuration options.
+ resolveCredentials,
+}
+
+// A Config represents a generic configuration value or set of values. This type
+// will be used by the AWSConfigResolvers to extract
+//
+// General the Config type will use type assertion against the Provider interfaces
+// to extract specific data from the Config.
+type Config interface{}
+
+// A loader is used to load external configuration data and returns it as
+// a generic Config type.
+//
+// The loader should return an error if it fails to load the external configuration
+// or the configuration data is malformed, or required components missing.
+type loader func(context.Context, configs) (Config, error)
+
+// An awsConfigResolver will extract configuration data from the configs slice
+// using the provider interfaces to extract specific functionality. The extracted
+// configuration values will be written to the AWS Config value.
+//
+// The resolver should return an error if it it fails to extract the data, the
+// data is malformed, or incomplete.
+type awsConfigResolver func(ctx context.Context, cfg *aws.Config, configs configs) error
+
+// configs is a slice of Config values. These values will be used by the
+// AWSConfigResolvers to extract external configuration values to populate the
+// AWS Config type.
+//
+// Use AppendFromLoaders to add additional external Config values that are
+// loaded from external sources.
+//
+// Use ResolveAWSConfig after external Config values have been added or loaded
+// to extract the loaded configuration values into the AWS Config.
+type configs []Config
+
+// AppendFromLoaders iterates over the slice of loaders passed in calling each
+// loader function in order. The external config value returned by the loader
+// will be added to the returned configs slice.
+//
+// If a loader returns an error this method will stop iterating and return
+// that error.
+func (cs configs) AppendFromLoaders(ctx context.Context, loaders []loader) (configs, error) {
+ for _, fn := range loaders {
+ cfg, err := fn(ctx, cs)
+ if err != nil {
+ return nil, err
+ }
+
+ cs = append(cs, cfg)
+ }
+
+ return cs, nil
+}
+
+// ResolveAWSConfig returns a AWS configuration populated with values by calling
+// the resolvers slice passed in. Each resolver is called in order. Any resolver
+// may overwrite the AWS Configuration value of a previous resolver.
+//
+// If an resolver returns an error this method will return that error, and stop
+// iterating over the resolvers.
+func (cs configs) ResolveAWSConfig(ctx context.Context, resolvers []awsConfigResolver) (aws.Config, error) {
+ var cfg aws.Config
+
+ for _, fn := range resolvers {
+ if err := fn(ctx, &cfg, cs); err != nil {
+ // TODO provide better error?
+ return aws.Config{}, err
+ }
+ }
+
+ var sources []interface{}
+ for _, s := range cs {
+ sources = append(sources, s)
+ }
+ cfg.ConfigSources = sources
+
+ return cfg, nil
+}
+
+// ResolveConfig calls the provide function passing slice of configuration sources.
+// This implements the aws.ConfigResolver interface.
+func (cs configs) ResolveConfig(f func(configs []interface{}) error) error {
+ var cfgs []interface{}
+ for i := range cs {
+ cfgs = append(cfgs, cs[i])
+ }
+ return f(cfgs)
+}
+
+// LoadDefaultConfig reads the SDK's default external configurations, and
+// populates an AWS Config with the values from the external configurations.
+//
+// An optional variadic set of additional Config values can be provided as input
+// that will be prepended to the configs slice. Use this to add custom configuration.
+// The custom configurations must satisfy the respective providers for their data
+// or the custom data will be ignored by the resolvers and config loaders.
+//
+// cfg, err := config.LoadDefaultConfig( context.TODO(),
+// WithSharedConfigProfile("test-profile"),
+// )
+// if err != nil {
+// panic(fmt.Sprintf("failed loading config, %v", err))
+// }
+//
+//
+// The default configuration sources are:
+// * Environment Variables
+// * Shared Configuration and Shared Credentials files.
+func LoadDefaultConfig(ctx context.Context, optFns ...func(*LoadOptions) error) (cfg aws.Config, err error) {
+ var options LoadOptions
+ for _, optFn := range optFns {
+ optFn(&options)
+ }
+
+ // assign Load Options to configs
+ var cfgCpy = configs{options}
+
+ cfgCpy, err = cfgCpy.AppendFromLoaders(ctx, defaultLoaders)
+ if err != nil {
+ return aws.Config{}, err
+ }
+
+ cfg, err = cfgCpy.ResolveAWSConfig(ctx, defaultAWSConfigResolvers)
+ if err != nil {
+ return aws.Config{}, err
+ }
+
+ return cfg, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/config/doc.go
new file mode 100644
index 000000000000..31648ffb5747
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/doc.go
@@ -0,0 +1,20 @@
+// Package config provides utilities for loading configuration from multiple
+// sources that can be used to configure the SDK's API clients, and utilities.
+//
+// The config package will load configuration from environment variables, AWS
+// shared configuration file (~/.aws/config), and AWS shared credentials file
+// (~/.aws/credentials).
+//
+// Use the LoadDefaultConfig to load configuration from all the SDK's supported
+// sources, and resolve credentials using the SDK's default credential chain.
+//
+// LoadDefaultConfig allows for a variadic list of additional Config sources that can
+// provide one or more configuration values which can be used to programmatically control the resolution
+// of a specific value, or allow for broader range of additional configuration sources not supported by the SDK.
+// A Config source implements one or more provider interfaces defined in this package. Config sources passed in will
+// take precedence over the default environment and shared config sources used by the SDK. If one or more Config sources
+// implement the same provider interface, priority will be handled by the order in which the sources were passed in.
+//
+// A number of helpers (prefixed by ``With``) are provided in this package that implement their respective provider
+// interface. These helpers should be used for overriding configuration programmatically at runtime.
+package config
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/env_config.go b/vendor/github.com/aws/aws-sdk-go-v2/config/env_config.go
new file mode 100644
index 000000000000..c4ddb229700e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/env_config.go
@@ -0,0 +1,567 @@
+package config
+
+import (
+ "bytes"
+ "context"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/feature/ec2/imds"
+ "io"
+ "io/ioutil"
+ "os"
+ "strings"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+// CredentialsSourceName provides a name of the provider when config is
+// loaded from environment.
+const CredentialsSourceName = "EnvConfigCredentials"
+
+// Environment variables that will be read for configuration values.
+const (
+ awsAccessKeyIDEnvVar = "AWS_ACCESS_KEY_ID"
+ awsAccessKeyEnvVar = "AWS_ACCESS_KEY"
+
+ awsSecretAccessKeyEnvVar = "AWS_SECRET_ACCESS_KEY"
+ awsSecretKeyEnvVar = "AWS_SECRET_KEY"
+
+ awsSessionTokenEnvVar = "AWS_SESSION_TOKEN"
+
+ awsContainerCredentialsEndpointEnvVar = "AWS_CONTAINER_CREDENTIALS_FULL_URI"
+ awsContainerCredentialsRelativePathEnvVar = "AWS_CONTAINER_CREDENTIALS_RELATIVE_URI"
+ awsContainerPProviderAuthorizationEnvVar = "AWS_CONTAINER_AUTHORIZATION_TOKEN"
+
+ awsRegionEnvVar = "AWS_REGION"
+ awsDefaultRegionEnvVar = "AWS_DEFAULT_REGION"
+
+ awsProfileEnvVar = "AWS_PROFILE"
+ awsDefaultProfileEnvVar = "AWS_DEFAULT_PROFILE"
+
+ awsSharedCredentialsFileEnvVar = "AWS_SHARED_CREDENTIALS_FILE"
+
+ awsConfigFileEnvVar = "AWS_CONFIG_FILE"
+
+ awsCustomCABundleEnvVar = "AWS_CA_BUNDLE"
+
+ awsWebIdentityTokenFilePathEnvVar = "AWS_WEB_IDENTITY_TOKEN_FILE"
+
+ awsRoleARNEnvVar = "AWS_ROLE_ARN"
+ awsRoleSessionNameEnvVar = "AWS_ROLE_SESSION_NAME"
+
+ awsEnableEndpointDiscoveryEnvVar = "AWS_ENABLE_ENDPOINT_DISCOVERY"
+
+ awsS3UseARNRegionEnvVar = "AWS_S3_USE_ARN_REGION"
+
+ awsEc2MetadataServiceEndpointModeEnvVar = "AWS_EC2_METADATA_SERVICE_ENDPOINT_MODE"
+
+ awsEc2MetadataServiceEndpointEnvVar = "AWS_EC2_METADATA_SERVICE_ENDPOINT"
+
+ awsEc2MetadataDisabled = "AWS_EC2_METADATA_DISABLED"
+
+ awsS3DisableMultiRegionAccessPointEnvVar = "AWS_S3_DISABLE_MULTIREGION_ACCESS_POINTS"
+
+ awsUseDualStackEndpoint = "AWS_USE_DUALSTACK_ENDPOINT"
+
+ awsUseFIPSEndpoint = "AWS_USE_FIPS_ENDPOINT"
+)
+
+var (
+ credAccessEnvKeys = []string{
+ awsAccessKeyIDEnvVar,
+ awsAccessKeyEnvVar,
+ }
+ credSecretEnvKeys = []string{
+ awsSecretAccessKeyEnvVar,
+ awsSecretKeyEnvVar,
+ }
+ regionEnvKeys = []string{
+ awsRegionEnvVar,
+ awsDefaultRegionEnvVar,
+ }
+ profileEnvKeys = []string{
+ awsProfileEnvVar,
+ awsDefaultProfileEnvVar,
+ }
+)
+
+// EnvConfig is a collection of environment values the SDK will read
+// setup config from. All environment values are optional. But some values
+// such as credentials require multiple values to be complete or the values
+// will be ignored.
+type EnvConfig struct {
+ // Environment configuration values. If set both Access Key ID and Secret Access
+ // Key must be provided. Session Token and optionally also be provided, but is
+ // not required.
+ //
+ // # Access Key ID
+ // AWS_ACCESS_KEY_ID=AKID
+ // AWS_ACCESS_KEY=AKID # only read if AWS_ACCESS_KEY_ID is not set.
+ //
+ // # Secret Access Key
+ // AWS_SECRET_ACCESS_KEY=SECRET
+ // AWS_SECRET_KEY=SECRET # only read if AWS_SECRET_ACCESS_KEY is not set.
+ //
+ // # Session Token
+ // AWS_SESSION_TOKEN=TOKEN
+ Credentials aws.Credentials
+
+ // ContainerCredentialsEndpoint value is the HTTP enabled endpoint to retrieve credentials
+ // using the endpointcreds.Provider
+ ContainerCredentialsEndpoint string
+
+ // ContainerCredentialsRelativePath is the relative URI path that will be used when attempting to retrieve
+ // credentials from the container endpoint.
+ ContainerCredentialsRelativePath string
+
+ // ContainerAuthorizationToken is the authorization token that will be included in the HTTP Authorization
+ // header when attempting to retrieve credentials from the container credentials endpoint.
+ ContainerAuthorizationToken string
+
+ // Region value will instruct the SDK where to make service API requests to. If is
+ // not provided in the environment the region must be provided before a service
+ // client request is made.
+ //
+ // AWS_REGION=us-west-2
+ // AWS_DEFAULT_REGION=us-west-2
+ Region string
+
+ // Profile name the SDK should load use when loading shared configuration from the
+ // shared configuration files. If not provided "default" will be used as the
+ // profile name.
+ //
+ // AWS_PROFILE=my_profile
+ // AWS_DEFAULT_PROFILE=my_profile
+ SharedConfigProfile string
+
+ // Shared credentials file path can be set to instruct the SDK to use an alternate
+ // file for the shared credentials. If not set the file will be loaded from
+ // $HOME/.aws/credentials on Linux/Unix based systems, and
+ // %USERPROFILE%\.aws\credentials on Windows.
+ //
+ // AWS_SHARED_CREDENTIALS_FILE=$HOME/my_shared_credentials
+ SharedCredentialsFile string
+
+ // Shared config file path can be set to instruct the SDK to use an alternate
+ // file for the shared config. If not set the file will be loaded from
+ // $HOME/.aws/config on Linux/Unix based systems, and
+ // %USERPROFILE%\.aws\config on Windows.
+ //
+ // AWS_CONFIG_FILE=$HOME/my_shared_config
+ SharedConfigFile string
+
+ // Sets the path to a custom Credentials Authority (CA) Bundle PEM file
+ // that the SDK will use instead of the system's root CA bundle.
+ // Only use this if you want to configure the SDK to use a custom set
+ // of CAs.
+ //
+ // Enabling this option will attempt to merge the Transport
+ // into the SDK's HTTP client. If the client's Transport is
+ // not a http.Transport an error will be returned. If the
+ // Transport's TLS config is set this option will cause the
+ // SDK to overwrite the Transport's TLS config's RootCAs value.
+ //
+ // Setting a custom HTTPClient in the aws.Config options will override this setting.
+ // To use this option and custom HTTP client, the HTTP client needs to be provided
+ // when creating the config. Not the service client.
+ //
+ // AWS_CA_BUNDLE=$HOME/my_custom_ca_bundle
+ CustomCABundle string
+
+ // Enables endpoint discovery via environment variables.
+ //
+ // AWS_ENABLE_ENDPOINT_DISCOVERY=true
+ EnableEndpointDiscovery aws.EndpointDiscoveryEnableState
+
+ // Specifies the WebIdentity token the SDK should use to assume a role
+ // with.
+ //
+ // AWS_WEB_IDENTITY_TOKEN_FILE=file_path
+ WebIdentityTokenFilePath string
+
+ // Specifies the IAM role arn to use when assuming an role.
+ //
+ // AWS_ROLE_ARN=role_arn
+ RoleARN string
+
+ // Specifies the IAM role session name to use when assuming a role.
+ //
+ // AWS_ROLE_SESSION_NAME=session_name
+ RoleSessionName string
+
+ // Specifies if the S3 service should allow ARNs to direct the region
+ // the client's requests are sent to.
+ //
+ // AWS_S3_USE_ARN_REGION=true
+ S3UseARNRegion *bool
+
+ // Specifies if the EC2 IMDS service client is enabled.
+ //
+ // AWS_EC2_METADATA_DISABLED=true
+ EC2IMDSClientEnableState imds.ClientEnableState
+
+ // Specifies the EC2 Instance Metadata Service default endpoint selection mode (IPv4 or IPv6)
+ //
+ // AWS_EC2_METADATA_SERVICE_ENDPOINT_MODE=IPv6
+ EC2IMDSEndpointMode imds.EndpointModeState
+
+ // Specifies the EC2 Instance Metadata Service endpoint to use. If specified it overrides EC2IMDSEndpointMode.
+ //
+ // AWS_EC2_METADATA_SERVICE_ENDPOINT=http://fd00:ec2::254
+ EC2IMDSEndpoint string
+
+ // Specifies if the S3 service should disable multi-region access points
+ // support.
+ //
+ // AWS_S3_DISABLE_MULTIREGION_ACCESS_POINTS=true
+ S3DisableMultiRegionAccessPoints *bool
+
+ // Specifies that SDK clients must resolve a dual-stack endpoint for
+ // services.
+ //
+ // AWS_USE_DUALSTACK_ENDPOINT=true
+ UseDualStackEndpoint aws.DualStackEndpointState
+
+ // Specifies that SDK clients must resolve a FIPS endpoint for
+ // services.
+ //
+ // AWS_USE_FIPS_ENDPOINT=true
+ UseFIPSEndpoint aws.FIPSEndpointState
+}
+
+// loadEnvConfig reads configuration values from the OS's environment variables.
+// Returning the a Config typed EnvConfig to satisfy the ConfigLoader func type.
+func loadEnvConfig(ctx context.Context, cfgs configs) (Config, error) {
+ return NewEnvConfig()
+}
+
+// NewEnvConfig retrieves the SDK's environment configuration.
+// See `EnvConfig` for the values that will be retrieved.
+func NewEnvConfig() (EnvConfig, error) {
+ var cfg EnvConfig
+
+ creds := aws.Credentials{
+ Source: CredentialsSourceName,
+ }
+ setStringFromEnvVal(&creds.AccessKeyID, credAccessEnvKeys)
+ setStringFromEnvVal(&creds.SecretAccessKey, credSecretEnvKeys)
+ if creds.HasKeys() {
+ creds.SessionToken = os.Getenv(awsSessionTokenEnvVar)
+ cfg.Credentials = creds
+ }
+
+ cfg.ContainerCredentialsEndpoint = os.Getenv(awsContainerCredentialsEndpointEnvVar)
+ cfg.ContainerCredentialsRelativePath = os.Getenv(awsContainerCredentialsRelativePathEnvVar)
+ cfg.ContainerAuthorizationToken = os.Getenv(awsContainerPProviderAuthorizationEnvVar)
+
+ setStringFromEnvVal(&cfg.Region, regionEnvKeys)
+ setStringFromEnvVal(&cfg.SharedConfigProfile, profileEnvKeys)
+
+ cfg.SharedCredentialsFile = os.Getenv(awsSharedCredentialsFileEnvVar)
+ cfg.SharedConfigFile = os.Getenv(awsConfigFileEnvVar)
+
+ cfg.CustomCABundle = os.Getenv(awsCustomCABundleEnvVar)
+
+ cfg.WebIdentityTokenFilePath = os.Getenv(awsWebIdentityTokenFilePathEnvVar)
+
+ cfg.RoleARN = os.Getenv(awsRoleARNEnvVar)
+ cfg.RoleSessionName = os.Getenv(awsRoleSessionNameEnvVar)
+
+ if err := setEndpointDiscoveryTypeFromEnvVal(&cfg.EnableEndpointDiscovery, []string{awsEnableEndpointDiscoveryEnvVar}); err != nil {
+ return cfg, err
+ }
+
+ if err := setBoolPtrFromEnvVal(&cfg.S3UseARNRegion, []string{awsS3UseARNRegionEnvVar}); err != nil {
+ return cfg, err
+ }
+
+ setEC2IMDSClientEnableState(&cfg.EC2IMDSClientEnableState, []string{awsEc2MetadataDisabled})
+ if err := setEC2IMDSEndpointMode(&cfg.EC2IMDSEndpointMode, []string{awsEc2MetadataServiceEndpointModeEnvVar}); err != nil {
+ return cfg, err
+ }
+ cfg.EC2IMDSEndpoint = os.Getenv(awsEc2MetadataServiceEndpointEnvVar)
+
+ if err := setBoolPtrFromEnvVal(&cfg.S3DisableMultiRegionAccessPoints, []string{awsS3DisableMultiRegionAccessPointEnvVar}); err != nil {
+ return cfg, err
+ }
+
+ if err := setUseDualStackEndpointFromEnvVal(&cfg.UseDualStackEndpoint, []string{awsUseDualStackEndpoint}); err != nil {
+ return cfg, err
+ }
+
+ if err := setUseFIPSEndpointFromEnvVal(&cfg.UseFIPSEndpoint, []string{awsUseFIPSEndpoint}); err != nil {
+ return cfg, err
+ }
+
+ return cfg, nil
+}
+
+func setEC2IMDSClientEnableState(state *imds.ClientEnableState, keys []string) {
+ for _, k := range keys {
+ value := os.Getenv(k)
+ if len(value) == 0 {
+ continue
+ }
+ switch {
+ case strings.EqualFold(value, "true"):
+ *state = imds.ClientDisabled
+ case strings.EqualFold(value, "false"):
+ *state = imds.ClientEnabled
+ default:
+ continue
+ }
+ break
+ }
+}
+
+func setEC2IMDSEndpointMode(mode *imds.EndpointModeState, keys []string) error {
+ for _, k := range keys {
+ value := os.Getenv(k)
+ if len(value) == 0 {
+ continue
+ }
+ if err := mode.SetFromString(value); err != nil {
+ return fmt.Errorf("invalid value for environment variable, %s=%s, %v", k, value, err)
+ }
+ }
+ return nil
+}
+
+// GetRegion returns the AWS Region if set in the environment. Returns an empty
+// string if not set.
+func (c EnvConfig) getRegion(ctx context.Context) (string, bool, error) {
+ if len(c.Region) == 0 {
+ return "", false, nil
+ }
+ return c.Region, true, nil
+}
+
+// GetSharedConfigProfile returns the shared config profile if set in the
+// environment. Returns an empty string if not set.
+func (c EnvConfig) getSharedConfigProfile(ctx context.Context) (string, bool, error) {
+ if len(c.SharedConfigProfile) == 0 {
+ return "", false, nil
+ }
+
+ return c.SharedConfigProfile, true, nil
+}
+
+// getSharedConfigFiles returns a slice of filenames set in the environment.
+//
+// Will return the filenames in the order of:
+// * Shared Config
+func (c EnvConfig) getSharedConfigFiles(context.Context) ([]string, bool, error) {
+ var files []string
+ if v := c.SharedConfigFile; len(v) > 0 {
+ files = append(files, v)
+ }
+
+ if len(files) == 0 {
+ return nil, false, nil
+ }
+ return files, true, nil
+}
+
+// getSharedCredentialsFiles returns a slice of filenames set in the environment.
+//
+// Will return the filenames in the order of:
+// * Shared Credentials
+func (c EnvConfig) getSharedCredentialsFiles(context.Context) ([]string, bool, error) {
+ var files []string
+ if v := c.SharedCredentialsFile; len(v) > 0 {
+ files = append(files, v)
+ }
+ if len(files) == 0 {
+ return nil, false, nil
+ }
+ return files, true, nil
+}
+
+// GetCustomCABundle returns the custom CA bundle's PEM bytes if the file was
+func (c EnvConfig) getCustomCABundle(context.Context) (io.Reader, bool, error) {
+ if len(c.CustomCABundle) == 0 {
+ return nil, false, nil
+ }
+
+ b, err := ioutil.ReadFile(c.CustomCABundle)
+ if err != nil {
+ return nil, false, err
+ }
+ return bytes.NewReader(b), true, nil
+}
+
+// GetS3UseARNRegion returns whether to allow ARNs to direct the region
+// the S3 client's requests are sent to.
+func (c EnvConfig) GetS3UseARNRegion(ctx context.Context) (value, ok bool, err error) {
+ if c.S3UseARNRegion == nil {
+ return false, false, nil
+ }
+
+ return *c.S3UseARNRegion, true, nil
+}
+
+// GetS3DisableMultRegionAccessPoints returns whether to disable multi-region access point
+// support for the S3 client.
+func (c EnvConfig) GetS3DisableMultRegionAccessPoints(ctx context.Context) (value, ok bool, err error) {
+ if c.S3DisableMultiRegionAccessPoints == nil {
+ return false, false, nil
+ }
+
+ return *c.S3DisableMultiRegionAccessPoints, true, nil
+}
+
+// GetUseDualStackEndpoint returns whether the service's dual-stack endpoint should be
+// used for requests.
+func (c EnvConfig) GetUseDualStackEndpoint(ctx context.Context) (value aws.DualStackEndpointState, found bool, err error) {
+ if c.UseDualStackEndpoint == aws.DualStackEndpointStateUnset {
+ return aws.DualStackEndpointStateUnset, false, nil
+ }
+
+ return c.UseDualStackEndpoint, true, nil
+}
+
+// GetUseFIPSEndpoint returns whether the service's FIPS endpoint should be
+// used for requests.
+func (c EnvConfig) GetUseFIPSEndpoint(ctx context.Context) (value aws.FIPSEndpointState, found bool, err error) {
+ if c.UseFIPSEndpoint == aws.FIPSEndpointStateUnset {
+ return aws.FIPSEndpointStateUnset, false, nil
+ }
+
+ return c.UseFIPSEndpoint, true, nil
+}
+
+func setStringFromEnvVal(dst *string, keys []string) {
+ for _, k := range keys {
+ if v := os.Getenv(k); len(v) > 0 {
+ *dst = v
+ break
+ }
+ }
+}
+
+func setBoolPtrFromEnvVal(dst **bool, keys []string) error {
+ for _, k := range keys {
+ value := os.Getenv(k)
+ if len(value) == 0 {
+ continue
+ }
+
+ if *dst == nil {
+ *dst = new(bool)
+ }
+
+ switch {
+ case strings.EqualFold(value, "false"):
+ **dst = false
+ case strings.EqualFold(value, "true"):
+ **dst = true
+ default:
+ return fmt.Errorf(
+ "invalid value for environment variable, %s=%s, need true or false",
+ k, value)
+ }
+ break
+ }
+
+ return nil
+}
+
+func setEndpointDiscoveryTypeFromEnvVal(dst *aws.EndpointDiscoveryEnableState, keys []string) error {
+ for _, k := range keys {
+ value := os.Getenv(k)
+ if len(value) == 0 {
+ continue // skip if empty
+ }
+
+ switch {
+ case strings.EqualFold(value, endpointDiscoveryDisabled):
+ *dst = aws.EndpointDiscoveryDisabled
+ case strings.EqualFold(value, endpointDiscoveryEnabled):
+ *dst = aws.EndpointDiscoveryEnabled
+ case strings.EqualFold(value, endpointDiscoveryAuto):
+ *dst = aws.EndpointDiscoveryAuto
+ default:
+ return fmt.Errorf(
+ "invalid value for environment variable, %s=%s, need true, false or auto",
+ k, value)
+ }
+ }
+ return nil
+}
+
+func setUseDualStackEndpointFromEnvVal(dst *aws.DualStackEndpointState, keys []string) error {
+ for _, k := range keys {
+ value := os.Getenv(k)
+ if len(value) == 0 {
+ continue // skip if empty
+ }
+
+ switch {
+ case strings.EqualFold(value, "true"):
+ *dst = aws.DualStackEndpointStateEnabled
+ case strings.EqualFold(value, "false"):
+ *dst = aws.DualStackEndpointStateDisabled
+ default:
+ return fmt.Errorf(
+ "invalid value for environment variable, %s=%s, need true, false",
+ k, value)
+ }
+ }
+ return nil
+}
+
+func setUseFIPSEndpointFromEnvVal(dst *aws.FIPSEndpointState, keys []string) error {
+ for _, k := range keys {
+ value := os.Getenv(k)
+ if len(value) == 0 {
+ continue // skip if empty
+ }
+
+ switch {
+ case strings.EqualFold(value, "true"):
+ *dst = aws.FIPSEndpointStateEnabled
+ case strings.EqualFold(value, "false"):
+ *dst = aws.FIPSEndpointStateDisabled
+ default:
+ return fmt.Errorf(
+ "invalid value for environment variable, %s=%s, need true, false",
+ k, value)
+ }
+ }
+ return nil
+}
+
+// GetEnableEndpointDiscovery returns resolved value for EnableEndpointDiscovery env variable setting.
+func (c EnvConfig) GetEnableEndpointDiscovery(ctx context.Context) (value aws.EndpointDiscoveryEnableState, found bool, err error) {
+ if c.EnableEndpointDiscovery == aws.EndpointDiscoveryUnset {
+ return aws.EndpointDiscoveryUnset, false, nil
+ }
+
+ return c.EnableEndpointDiscovery, true, nil
+}
+
+// GetEC2IMDSClientEnableState implements a EC2IMDSClientEnableState options resolver interface.
+func (c EnvConfig) GetEC2IMDSClientEnableState() (imds.ClientEnableState, bool, error) {
+ if c.EC2IMDSClientEnableState == imds.ClientDefaultEnableState {
+ return imds.ClientDefaultEnableState, false, nil
+ }
+
+ return c.EC2IMDSClientEnableState, true, nil
+}
+
+// GetEC2IMDSEndpointMode implements a EC2IMDSEndpointMode option resolver interface.
+func (c EnvConfig) GetEC2IMDSEndpointMode() (imds.EndpointModeState, bool, error) {
+ if c.EC2IMDSEndpointMode == imds.EndpointModeStateUnset {
+ return imds.EndpointModeStateUnset, false, nil
+ }
+
+ return c.EC2IMDSEndpointMode, true, nil
+}
+
+// GetEC2IMDSEndpoint implements a EC2IMDSEndpoint option resolver interface.
+func (c EnvConfig) GetEC2IMDSEndpoint() (string, bool, error) {
+ if len(c.EC2IMDSEndpoint) == 0 {
+ return "", false, nil
+ }
+
+ return c.EC2IMDSEndpoint, true, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/generate.go b/vendor/github.com/aws/aws-sdk-go-v2/config/generate.go
new file mode 100644
index 000000000000..654a7a77fb7e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/generate.go
@@ -0,0 +1,4 @@
+package config
+
+//go:generate go run -tags codegen ./codegen -output=provider_assert_test.go
+//go:generate gofmt -s -w ./
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/config/go.mod
new file mode 100644
index 000000000000..e0edd953339e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/go.mod
@@ -0,0 +1,32 @@
+module github.com/aws/aws-sdk-go-v2/config
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/aws-sdk-go-v2/credentials v1.7.0
+ github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.9.0
+ github.com/aws/aws-sdk-go-v2/internal/ini v1.3.3
+ github.com/aws/aws-sdk-go-v2/service/sso v1.8.0
+ github.com/aws/aws-sdk-go-v2/service/sts v1.13.0
+ github.com/aws/smithy-go v1.9.1
+ github.com/google/go-cmp v0.5.6
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../
+
+replace github.com/aws/aws-sdk-go-v2/credentials => ../credentials/
+
+replace github.com/aws/aws-sdk-go-v2/feature/ec2/imds => ../feature/ec2/imds/
+
+replace github.com/aws/aws-sdk-go-v2/internal/configsources => ../internal/configsources/
+
+replace github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 => ../internal/endpoints/v2/
+
+replace github.com/aws/aws-sdk-go-v2/internal/ini => ../internal/ini/
+
+replace github.com/aws/aws-sdk-go-v2/service/internal/presigned-url => ../service/internal/presigned-url/
+
+replace github.com/aws/aws-sdk-go-v2/service/sso => ../service/sso/
+
+replace github.com/aws/aws-sdk-go-v2/service/sts => ../service/sts/
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/config/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/config/go_module_metadata.go
new file mode 100644
index 000000000000..9b5731ecb5cf
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package config
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.12.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/load_options.go b/vendor/github.com/aws/aws-sdk-go-v2/config/load_options.go
new file mode 100644
index 000000000000..a2756aeb376d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/load_options.go
@@ -0,0 +1,808 @@
+package config
+
+import (
+ "context"
+ "io"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/endpointcreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/processcreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/ssocreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/stscreds"
+ "github.com/aws/aws-sdk-go-v2/feature/ec2/imds"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+)
+
+// LoadOptionsFunc is a type alias for LoadOptions functional option
+type LoadOptionsFunc func(*LoadOptions) error
+
+// LoadOptions are discrete set of options that are valid for loading the configuration
+type LoadOptions struct {
+
+ // Region is the region to send requests to.
+ Region string
+
+ // Credentials object to use when signing requests.
+ Credentials aws.CredentialsProvider
+
+ // HTTPClient the SDK's API clients will use to invoke HTTP requests.
+ HTTPClient HTTPClient
+
+ // EndpointResolver that can be used to provide or override an endpoint for the given
+ // service and region.
+ //
+ // See the `aws.EndpointResolver` documentation on usage.
+ //
+ // Deprecated: See EndpointResolverWithOptions
+ EndpointResolver aws.EndpointResolver
+
+ // EndpointResolverWithOptions that can be used to provide or override an endpoint for the given
+ // service and region.
+ //
+ // See the `aws.EndpointResolverWithOptions` documentation on usage.
+ EndpointResolverWithOptions aws.EndpointResolverWithOptions
+
+ // Retryer is a function that provides a Retryer implementation. A Retryer guides how HTTP requests should be
+ // retried in case of recoverable failures.
+ Retryer func() aws.Retryer
+
+ // APIOptions provides the set of middleware mutations modify how the API
+ // client requests will be handled. This is useful for adding additional
+ // tracing data to a request, or changing behavior of the SDK's client.
+ APIOptions []func(*middleware.Stack) error
+
+ // Logger writer interface to write logging messages to.
+ Logger logging.Logger
+
+ // ClientLogMode is used to configure the events that will be sent to the configured logger.
+ // This can be used to configure the logging of signing, retries, request, and responses
+ // of the SDK clients.
+ //
+ // See the ClientLogMode type documentation for the complete set of logging modes and available
+ // configuration.
+ ClientLogMode *aws.ClientLogMode
+
+ // SharedConfigProfile is the profile to be used when loading the SharedConfig
+ SharedConfigProfile string
+
+ // SharedConfigFiles is the slice of custom shared config files to use when loading the SharedConfig.
+ // A non-default profile used within config file must have name defined with prefix 'profile '.
+ // eg [profile xyz] indicates a profile with name 'xyz'.
+ // To read more on the format of the config file, please refer the documentation at
+ // https://docs.aws.amazon.com/credref/latest/refdocs/file-format.html#file-format-config
+ //
+ // If duplicate profiles are provided within the same, or across multiple shared config files, the next parsed
+ // profile will override only the properties that conflict with the previously defined profile.
+ // Note that if duplicate profiles are provided within the SharedCredentialsFiles and SharedConfigFiles,
+ // the properties defined in shared credentials file take precedence.
+ SharedConfigFiles []string
+
+ // SharedCredentialsFile is the slice of custom shared credentials files to use when loading the SharedConfig.
+ // The profile name used within credentials file must not prefix 'profile '.
+ // eg [xyz] indicates a profile with name 'xyz'. Profile declared as [profile xyz] will be ignored.
+ // To read more on the format of the credentials file, please refer the documentation at
+ // https://docs.aws.amazon.com/credref/latest/refdocs/file-format.html#file-format-creds
+ //
+ // If duplicate profiles are provided with a same, or across multiple shared credentials files, the next parsed
+ // profile will override only properties that conflict with the previously defined profile.
+ // Note that if duplicate profiles are provided within the SharedCredentialsFiles and SharedConfigFiles,
+ // the properties defined in shared credentials file take precedence.
+ SharedCredentialsFiles []string
+
+ // CustomCABundle is CA bundle PEM bytes reader
+ CustomCABundle io.Reader
+
+ // DefaultRegion is the fall back region, used if a region was not resolved from other sources
+ DefaultRegion string
+
+ // UseEC2IMDSRegion indicates if SDK should retrieve the region
+ // from the EC2 Metadata service
+ UseEC2IMDSRegion *UseEC2IMDSRegion
+
+ // CredentialsCacheOptions is a function for setting the
+ // aws.CredentialsCacheOptions
+ CredentialsCacheOptions func(*aws.CredentialsCacheOptions)
+
+ // ProcessCredentialOptions is a function for setting
+ // the processcreds.Options
+ ProcessCredentialOptions func(*processcreds.Options)
+
+ // EC2RoleCredentialOptions is a function for setting
+ // the ec2rolecreds.Options
+ EC2RoleCredentialOptions func(*ec2rolecreds.Options)
+
+ // EndpointCredentialOptions is a function for setting
+ // the endpointcreds.Options
+ EndpointCredentialOptions func(*endpointcreds.Options)
+
+ // WebIdentityRoleCredentialOptions is a function for setting
+ // the stscreds.WebIdentityRoleOptions
+ WebIdentityRoleCredentialOptions func(*stscreds.WebIdentityRoleOptions)
+
+ // AssumeRoleCredentialOptions is a function for setting the
+ // stscreds.AssumeRoleOptions
+ AssumeRoleCredentialOptions func(*stscreds.AssumeRoleOptions)
+
+ // SSOProviderOptions is a function for setting
+ // the ssocreds.Options
+ SSOProviderOptions func(options *ssocreds.Options)
+
+ // LogConfigurationWarnings when set to true, enables logging
+ // configuration warnings
+ LogConfigurationWarnings *bool
+
+ // S3UseARNRegion specifies if the S3 service should allow ARNs to direct
+ // the region, the client's requests are sent to.
+ S3UseARNRegion *bool
+
+ // EnableEndpointDiscovery specifies if endpoint discovery is enable for
+ // the client.
+ EnableEndpointDiscovery aws.EndpointDiscoveryEnableState
+
+ // Specifies if the EC2 IMDS service client is enabled.
+ //
+ // AWS_EC2_METADATA_DISABLED=true
+ EC2IMDSClientEnableState imds.ClientEnableState
+
+ // Specifies the EC2 Instance Metadata Service default endpoint selection mode (IPv4 or IPv6)
+ EC2IMDSEndpointMode imds.EndpointModeState
+
+ // Specifies the EC2 Instance Metadata Service endpoint to use. If specified it overrides EC2IMDSEndpointMode.
+ EC2IMDSEndpoint string
+
+ // Specifies that SDK clients must resolve a dual-stack endpoint for
+ // services.
+ UseDualStackEndpoint aws.DualStackEndpointState
+
+ // Specifies that SDK clients must resolve a FIPS endpoint for
+ // services.
+ UseFIPSEndpoint aws.FIPSEndpointState
+}
+
+// getRegion returns Region from config's LoadOptions
+func (o LoadOptions) getRegion(ctx context.Context) (string, bool, error) {
+ if len(o.Region) == 0 {
+ return "", false, nil
+ }
+
+ return o.Region, true, nil
+}
+
+// WithRegion is a helper function to construct functional options
+// that sets Region on config's LoadOptions. Setting the region to
+// an empty string, will result in the region value being ignored.
+// If multiple WithRegion calls are made, the last call overrides
+// the previous call values.
+func WithRegion(v string) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.Region = v
+ return nil
+ }
+}
+
+// getDefaultRegion returns DefaultRegion from config's LoadOptions
+func (o LoadOptions) getDefaultRegion(ctx context.Context) (string, bool, error) {
+ if len(o.DefaultRegion) == 0 {
+ return "", false, nil
+ }
+
+ return o.DefaultRegion, true, nil
+}
+
+// WithDefaultRegion is a helper function to construct functional options
+// that sets a DefaultRegion on config's LoadOptions. Setting the default
+// region to an empty string, will result in the default region value
+// being ignored. If multiple WithDefaultRegion calls are made, the last
+// call overrides the previous call values. Note that both WithRegion and
+// WithEC2IMDSRegion call takes precedence over WithDefaultRegion call
+// when resolving region.
+func WithDefaultRegion(v string) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.DefaultRegion = v
+ return nil
+ }
+}
+
+// getSharedConfigProfile returns SharedConfigProfile from config's LoadOptions
+func (o LoadOptions) getSharedConfigProfile(ctx context.Context) (string, bool, error) {
+ if len(o.SharedConfigProfile) == 0 {
+ return "", false, nil
+ }
+
+ return o.SharedConfigProfile, true, nil
+}
+
+// WithSharedConfigProfile is a helper function to construct functional options
+// that sets SharedConfigProfile on config's LoadOptions. Setting the shared
+// config profile to an empty string, will result in the shared config profile
+// value being ignored.
+// If multiple WithSharedConfigProfile calls are made, the last call overrides
+// the previous call values.
+func WithSharedConfigProfile(v string) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.SharedConfigProfile = v
+ return nil
+ }
+}
+
+// getSharedConfigFiles returns SharedConfigFiles set on config's LoadOptions
+func (o LoadOptions) getSharedConfigFiles(ctx context.Context) ([]string, bool, error) {
+ if o.SharedConfigFiles == nil {
+ return nil, false, nil
+ }
+
+ return o.SharedConfigFiles, true, nil
+}
+
+// WithSharedConfigFiles is a helper function to construct functional options
+// that sets slice of SharedConfigFiles on config's LoadOptions.
+// Setting the shared config files to an nil string slice, will result in the
+// shared config files value being ignored.
+// If multiple WithSharedConfigFiles calls are made, the last call overrides
+// the previous call values.
+func WithSharedConfigFiles(v []string) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.SharedConfigFiles = v
+ return nil
+ }
+}
+
+// getSharedCredentialsFiles returns SharedCredentialsFiles set on config's LoadOptions
+func (o LoadOptions) getSharedCredentialsFiles(ctx context.Context) ([]string, bool, error) {
+ if o.SharedCredentialsFiles == nil {
+ return nil, false, nil
+ }
+
+ return o.SharedCredentialsFiles, true, nil
+}
+
+// WithSharedCredentialsFiles is a helper function to construct functional options
+// that sets slice of SharedCredentialsFiles on config's LoadOptions.
+// Setting the shared credentials files to an nil string slice, will result in the
+// shared credentials files value being ignored.
+// If multiple WithSharedCredentialsFiles calls are made, the last call overrides
+// the previous call values.
+func WithSharedCredentialsFiles(v []string) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.SharedCredentialsFiles = v
+ return nil
+ }
+}
+
+// getCustomCABundle returns CustomCABundle from LoadOptions
+func (o LoadOptions) getCustomCABundle(ctx context.Context) (io.Reader, bool, error) {
+ if o.CustomCABundle == nil {
+ return nil, false, nil
+ }
+
+ return o.CustomCABundle, true, nil
+}
+
+// WithCustomCABundle is a helper function to construct functional options
+// that sets CustomCABundle on config's LoadOptions. Setting the custom CA Bundle
+// to nil will result in custom CA Bundle value being ignored.
+// If multiple WithCustomCABundle calls are made, the last call overrides the
+// previous call values.
+func WithCustomCABundle(v io.Reader) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.CustomCABundle = v
+ return nil
+ }
+}
+
+// UseEC2IMDSRegion provides a regionProvider that retrieves the region
+// from the EC2 Metadata service.
+type UseEC2IMDSRegion struct {
+ // If unset will default to generic EC2 IMDS client.
+ Client *imds.Client
+}
+
+// getRegion attempts to retrieve the region from EC2 Metadata service.
+func (p *UseEC2IMDSRegion) getRegion(ctx context.Context) (string, bool, error) {
+ if ctx == nil {
+ ctx = context.Background()
+ }
+
+ client := p.Client
+ if client == nil {
+ client = imds.New(imds.Options{})
+ }
+
+ result, err := client.GetRegion(ctx, nil)
+ if err != nil {
+ return "", false, err
+ }
+ if len(result.Region) != 0 {
+ return result.Region, true, nil
+ }
+ return "", false, nil
+}
+
+// getEC2IMDSRegion returns the value of EC2 IMDS region.
+func (o LoadOptions) getEC2IMDSRegion(ctx context.Context) (string, bool, error) {
+ if o.UseEC2IMDSRegion == nil {
+ return "", false, nil
+ }
+
+ return o.UseEC2IMDSRegion.getRegion(ctx)
+}
+
+// WithEC2IMDSRegion is a helper function to construct functional options
+// that enables resolving EC2IMDS region. The function takes
+// in a UseEC2IMDSRegion functional option, and can be used to set the
+// EC2IMDS client which will be used to resolve EC2IMDSRegion.
+// If no functional option is provided, an EC2IMDS client is built and used
+// by the resolver. If multiple WithEC2IMDSRegion calls are made, the last
+// call overrides the previous call values. Note that the WithRegion calls takes
+// precedence over WithEC2IMDSRegion when resolving region.
+func WithEC2IMDSRegion(fnOpts ...func(o *UseEC2IMDSRegion)) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.UseEC2IMDSRegion = &UseEC2IMDSRegion{}
+
+ for _, fn := range fnOpts {
+ fn(o.UseEC2IMDSRegion)
+ }
+ return nil
+ }
+}
+
+// getCredentialsProvider returns the credentials value
+func (o LoadOptions) getCredentialsProvider(ctx context.Context) (aws.CredentialsProvider, bool, error) {
+ if o.Credentials == nil {
+ return nil, false, nil
+ }
+
+ return o.Credentials, true, nil
+}
+
+// WithCredentialsProvider is a helper function to construct functional options
+// that sets Credential provider value on config's LoadOptions. If credentials
+// provider is set to nil, the credentials provider value will be ignored.
+// If multiple WithCredentialsProvider calls are made, the last call overrides
+// the previous call values.
+func WithCredentialsProvider(v aws.CredentialsProvider) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.Credentials = v
+ return nil
+ }
+}
+
+// getCredentialsCacheOptionsProvider returns the wrapped function to set aws.CredentialsCacheOptions
+func (o LoadOptions) getCredentialsCacheOptions(ctx context.Context) (func(*aws.CredentialsCacheOptions), bool, error) {
+ if o.CredentialsCacheOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.CredentialsCacheOptions, true, nil
+}
+
+// WithCredentialsCacheOptions is a helper function to construct functional
+// options that sets a function to modify the aws.CredentialsCacheOptions the
+// aws.CredentialsCache will be configured with, if the CredentialsCache is used
+// by the configuration loader.
+//
+// If multiple WithCredentialsCacheOptions calls are made, the last call
+// overrides the previous call values.
+func WithCredentialsCacheOptions(v func(*aws.CredentialsCacheOptions)) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.CredentialsCacheOptions = v
+ return nil
+ }
+}
+
+// getProcessCredentialOptions returns the wrapped function to set processcreds.Options
+func (o LoadOptions) getProcessCredentialOptions(ctx context.Context) (func(*processcreds.Options), bool, error) {
+ if o.ProcessCredentialOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.ProcessCredentialOptions, true, nil
+}
+
+// WithProcessCredentialOptions is a helper function to construct functional options
+// that sets a function to use processcreds.Options on config's LoadOptions.
+// If process credential options is set to nil, the process credential value will
+// be ignored. If multiple WithProcessCredentialOptions calls are made, the last call
+// overrides the previous call values.
+func WithProcessCredentialOptions(v func(*processcreds.Options)) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.ProcessCredentialOptions = v
+ return nil
+ }
+}
+
+// getEC2RoleCredentialOptions returns the wrapped function to set the ec2rolecreds.Options
+func (o LoadOptions) getEC2RoleCredentialOptions(ctx context.Context) (func(*ec2rolecreds.Options), bool, error) {
+ if o.EC2RoleCredentialOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.EC2RoleCredentialOptions, true, nil
+}
+
+// WithEC2RoleCredentialOptions is a helper function to construct functional options
+// that sets a function to use ec2rolecreds.Options on config's LoadOptions. If
+// EC2 role credential options is set to nil, the EC2 role credential options value
+// will be ignored. If multiple WithEC2RoleCredentialOptions calls are made,
+// the last call overrides the previous call values.
+func WithEC2RoleCredentialOptions(v func(*ec2rolecreds.Options)) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.EC2RoleCredentialOptions = v
+ return nil
+ }
+}
+
+// getEndpointCredentialOptions returns the wrapped function to set endpointcreds.Options
+func (o LoadOptions) getEndpointCredentialOptions(context.Context) (func(*endpointcreds.Options), bool, error) {
+ if o.EndpointCredentialOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.EndpointCredentialOptions, true, nil
+}
+
+// WithEndpointCredentialOptions is a helper function to construct functional options
+// that sets a function to use endpointcreds.Options on config's LoadOptions. If
+// endpoint credential options is set to nil, the endpoint credential options
+// value will be ignored. If multiple WithEndpointCredentialOptions calls are made,
+// the last call overrides the previous call values.
+func WithEndpointCredentialOptions(v func(*endpointcreds.Options)) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.EndpointCredentialOptions = v
+ return nil
+ }
+}
+
+// getWebIdentityRoleCredentialOptions returns the wrapped function
+func (o LoadOptions) getWebIdentityRoleCredentialOptions(context.Context) (func(*stscreds.WebIdentityRoleOptions), bool, error) {
+ if o.WebIdentityRoleCredentialOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.WebIdentityRoleCredentialOptions, true, nil
+}
+
+// WithWebIdentityRoleCredentialOptions is a helper function to construct
+// functional options that sets a function to use stscreds.WebIdentityRoleOptions
+// on config's LoadOptions. If web identity role credentials options is set to nil,
+// the web identity role credentials value will be ignored. If multiple
+// WithWebIdentityRoleCredentialOptions calls are made, the last call
+// overrides the previous call values.
+func WithWebIdentityRoleCredentialOptions(v func(*stscreds.WebIdentityRoleOptions)) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.WebIdentityRoleCredentialOptions = v
+ return nil
+ }
+}
+
+// getAssumeRoleCredentialOptions returns AssumeRoleCredentialOptions from LoadOptions
+func (o LoadOptions) getAssumeRoleCredentialOptions(context.Context) (func(options *stscreds.AssumeRoleOptions), bool, error) {
+ if o.AssumeRoleCredentialOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.AssumeRoleCredentialOptions, true, nil
+}
+
+// WithAssumeRoleCredentialOptions is a helper function to construct
+// functional options that sets a function to use stscreds.AssumeRoleOptions
+// on config's LoadOptions. If assume role credentials options is set to nil,
+// the assume role credentials value will be ignored. If multiple
+// WithAssumeRoleCredentialOptions calls are made, the last call overrides
+// the previous call values.
+func WithAssumeRoleCredentialOptions(v func(*stscreds.AssumeRoleOptions)) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.AssumeRoleCredentialOptions = v
+ return nil
+ }
+}
+
+func (o LoadOptions) getHTTPClient(ctx context.Context) (HTTPClient, bool, error) {
+ if o.HTTPClient == nil {
+ return nil, false, nil
+ }
+
+ return o.HTTPClient, true, nil
+}
+
+// WithHTTPClient is a helper function to construct functional options
+// that sets HTTPClient on LoadOptions. If HTTPClient is set to nil,
+// the HTTPClient value will be ignored.
+// If multiple WithHTTPClient calls are made, the last call overrides
+// the previous call values.
+func WithHTTPClient(v HTTPClient) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.HTTPClient = v
+ return nil
+ }
+}
+
+func (o LoadOptions) getAPIOptions(ctx context.Context) ([]func(*middleware.Stack) error, bool, error) {
+ if o.APIOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.APIOptions, true, nil
+}
+
+// WithAPIOptions is a helper function to construct functional options
+// that sets APIOptions on LoadOptions. If APIOptions is set to nil, the
+// APIOptions value is ignored. If multiple WithAPIOptions calls are
+// made, the last call overrides the previous call values.
+func WithAPIOptions(v []func(*middleware.Stack) error) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ if v == nil {
+ return nil
+ }
+
+ o.APIOptions = append(o.APIOptions, v...)
+ return nil
+ }
+}
+
+func (o LoadOptions) getRetryer(ctx context.Context) (func() aws.Retryer, bool, error) {
+ if o.Retryer == nil {
+ return nil, false, nil
+ }
+
+ return o.Retryer, true, nil
+}
+
+// WithRetryer is a helper function to construct functional options
+// that sets Retryer on LoadOptions. If Retryer is set to nil, the
+// Retryer value is ignored. If multiple WithRetryer calls are
+// made, the last call overrides the previous call values.
+func WithRetryer(v func() aws.Retryer) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.Retryer = v
+ return nil
+ }
+}
+
+func (o LoadOptions) getEndpointResolver(ctx context.Context) (aws.EndpointResolver, bool, error) {
+ if o.EndpointResolver == nil {
+ return nil, false, nil
+ }
+
+ return o.EndpointResolver, true, nil
+}
+
+// WithEndpointResolver is a helper function to construct functional options
+// that sets the EndpointResolver on LoadOptions. If the EndpointResolver is set to nil,
+// the EndpointResolver value is ignored. If multiple WithEndpointResolver calls
+// are made, the last call overrides the previous call values.
+//
+// Deprecated: See WithEndpointResolverWithOptions
+func WithEndpointResolver(v aws.EndpointResolver) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.EndpointResolver = v
+ return nil
+ }
+}
+
+func (o LoadOptions) getEndpointResolverWithOptions(ctx context.Context) (aws.EndpointResolverWithOptions, bool, error) {
+ if o.EndpointResolverWithOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.EndpointResolverWithOptions, true, nil
+}
+
+// WithEndpointResolverWithOptions is a helper function to construct functional options
+// that sets the EndpointResolverWithOptions on LoadOptions. If the EndpointResolverWithOptions is set to nil,
+// the EndpointResolver value is ignored. If multiple WithEndpointResolver calls
+// are made, the last call overrides the previous call values.
+func WithEndpointResolverWithOptions(v aws.EndpointResolverWithOptions) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.EndpointResolverWithOptions = v
+ return nil
+ }
+}
+
+func (o LoadOptions) getLogger(ctx context.Context) (logging.Logger, bool, error) {
+ if o.Logger == nil {
+ return nil, false, nil
+ }
+
+ return o.Logger, true, nil
+}
+
+// WithLogger is a helper function to construct functional options
+// that sets Logger on LoadOptions. If Logger is set to nil, the
+// Logger value will be ignored. If multiple WithLogger calls are made,
+// the last call overrides the previous call values.
+func WithLogger(v logging.Logger) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.Logger = v
+ return nil
+ }
+}
+
+func (o LoadOptions) getClientLogMode(ctx context.Context) (aws.ClientLogMode, bool, error) {
+ if o.ClientLogMode == nil {
+ return 0, false, nil
+ }
+
+ return *o.ClientLogMode, true, nil
+}
+
+// WithClientLogMode is a helper function to construct functional options
+// that sets client log mode on LoadOptions. If client log mode is set to nil,
+// the client log mode value will be ignored. If multiple WithClientLogMode calls are made,
+// the last call overrides the previous call values.
+func WithClientLogMode(v aws.ClientLogMode) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.ClientLogMode = &v
+ return nil
+ }
+}
+
+func (o LoadOptions) getLogConfigurationWarnings(ctx context.Context) (v bool, found bool, err error) {
+ if o.LogConfigurationWarnings == nil {
+ return false, false, nil
+ }
+ return *o.LogConfigurationWarnings, true, nil
+}
+
+// WithLogConfigurationWarnings is a helper function to construct
+// functional options that can be used to set LogConfigurationWarnings
+// on LoadOptions.
+//
+// If multiple WithLogConfigurationWarnings calls are made, the last call
+// overrides the previous call values.
+func WithLogConfigurationWarnings(v bool) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.LogConfigurationWarnings = &v
+ return nil
+ }
+}
+
+// GetS3UseARNRegion returns whether to allow ARNs to direct the region
+// the S3 client's requests are sent to.
+func (o LoadOptions) GetS3UseARNRegion(ctx context.Context) (v bool, found bool, err error) {
+ if o.S3UseARNRegion == nil {
+ return false, false, nil
+ }
+ return *o.S3UseARNRegion, true, nil
+}
+
+// WithS3UseARNRegion is a helper function to construct functional options
+// that can be used to set S3UseARNRegion on LoadOptions.
+// If multiple WithS3UseARNRegion calls are made, the last call overrides
+// the previous call values.
+func WithS3UseARNRegion(v bool) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.S3UseARNRegion = &v
+ return nil
+ }
+}
+
+// GetEnableEndpointDiscovery returns if the EnableEndpointDiscovery flag is set.
+func (o LoadOptions) GetEnableEndpointDiscovery(ctx context.Context) (value aws.EndpointDiscoveryEnableState, ok bool, err error) {
+ if o.EnableEndpointDiscovery == aws.EndpointDiscoveryUnset {
+ return aws.EndpointDiscoveryUnset, false, nil
+ }
+ return o.EnableEndpointDiscovery, true, nil
+}
+
+// WithEndpointDiscovery is a helper function to construct functional options
+// that can be used to enable endpoint discovery on LoadOptions for supported clients.
+// If multiple WithEndpointDiscovery calls are made, the last call overrides
+// the previous call values.
+func WithEndpointDiscovery(v aws.EndpointDiscoveryEnableState) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.EnableEndpointDiscovery = v
+ return nil
+ }
+}
+
+// getSSOProviderOptions returns AssumeRoleCredentialOptions from LoadOptions
+func (o LoadOptions) getSSOProviderOptions(context.Context) (func(options *ssocreds.Options), bool, error) {
+ if o.SSOProviderOptions == nil {
+ return nil, false, nil
+ }
+
+ return o.SSOProviderOptions, true, nil
+}
+
+// WithSSOProviderOptions is a helper function to construct
+// functional options that sets a function to use ssocreds.Options
+// on config's LoadOptions. If the SSO credential provider options is set to nil,
+// the sso provider options value will be ignored. If multiple
+// WithSSOProviderOptions calls are made, the last call overrides
+// the previous call values.
+func WithSSOProviderOptions(v func(*ssocreds.Options)) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.SSOProviderOptions = v
+ return nil
+ }
+}
+
+// GetEC2IMDSClientEnableState implements a EC2IMDSClientEnableState options resolver interface.
+func (o LoadOptions) GetEC2IMDSClientEnableState() (imds.ClientEnableState, bool, error) {
+ if o.EC2IMDSClientEnableState == imds.ClientDefaultEnableState {
+ return imds.ClientDefaultEnableState, false, nil
+ }
+
+ return o.EC2IMDSClientEnableState, true, nil
+}
+
+// GetEC2IMDSEndpointMode implements a EC2IMDSEndpointMode option resolver interface.
+func (o LoadOptions) GetEC2IMDSEndpointMode() (imds.EndpointModeState, bool, error) {
+ if o.EC2IMDSEndpointMode == imds.EndpointModeStateUnset {
+ return imds.EndpointModeStateUnset, false, nil
+ }
+
+ return o.EC2IMDSEndpointMode, true, nil
+}
+
+// GetEC2IMDSEndpoint implements a EC2IMDSEndpoint option resolver interface.
+func (o LoadOptions) GetEC2IMDSEndpoint() (string, bool, error) {
+ if len(o.EC2IMDSEndpoint) == 0 {
+ return "", false, nil
+ }
+
+ return o.EC2IMDSEndpoint, true, nil
+}
+
+// WithEC2IMDSClientEnableState is a helper function to construct functional options that sets the EC2IMDSClientEnableState.
+func WithEC2IMDSClientEnableState(v imds.ClientEnableState) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.EC2IMDSClientEnableState = v
+ return nil
+ }
+}
+
+// WithEC2IMDSEndpointMode is a helper function to construct functional options that sets the EC2IMDSEndpointMode.
+func WithEC2IMDSEndpointMode(v imds.EndpointModeState) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.EC2IMDSEndpointMode = v
+ return nil
+ }
+}
+
+// WithEC2IMDSEndpoint is a helper function to construct functional options that sets the EC2IMDSEndpoint.
+func WithEC2IMDSEndpoint(v string) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.EC2IMDSEndpoint = v
+ return nil
+ }
+}
+
+// WithUseDualStackEndpoint is a helper function to construct
+// functional options that can be used to set UseDualStackEndpoint on LoadOptions.
+func WithUseDualStackEndpoint(v aws.DualStackEndpointState) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.UseDualStackEndpoint = v
+ return nil
+ }
+}
+
+// GetUseDualStackEndpoint returns whether the service's dual-stack endpoint should be
+// used for requests.
+func (o LoadOptions) GetUseDualStackEndpoint(ctx context.Context) (value aws.DualStackEndpointState, found bool, err error) {
+ if o.UseDualStackEndpoint == aws.DualStackEndpointStateUnset {
+ return aws.DualStackEndpointStateUnset, false, nil
+ }
+ return o.UseDualStackEndpoint, true, nil
+}
+
+// WithUseFIPSEndpoint is a helper function to construct
+// functional options that can be used to set UseFIPSEndpoint on LoadOptions.
+func WithUseFIPSEndpoint(v aws.FIPSEndpointState) LoadOptionsFunc {
+ return func(o *LoadOptions) error {
+ o.UseFIPSEndpoint = v
+ return nil
+ }
+}
+
+// GetUseFIPSEndpoint returns whether the service's FIPS endpoint should be
+// used for requests.
+func (o LoadOptions) GetUseFIPSEndpoint(ctx context.Context) (value aws.FIPSEndpointState, found bool, err error) {
+ if o.UseFIPSEndpoint == aws.FIPSEndpointStateUnset {
+ return aws.FIPSEndpointStateUnset, false, nil
+ }
+ return o.UseFIPSEndpoint, true, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/local.go b/vendor/github.com/aws/aws-sdk-go-v2/config/local.go
new file mode 100644
index 000000000000..b629137c8218
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/local.go
@@ -0,0 +1,51 @@
+package config
+
+import (
+ "fmt"
+ "net"
+ "net/url"
+)
+
+var lookupHostFn = net.LookupHost
+
+func isLoopbackHost(host string) (bool, error) {
+ ip := net.ParseIP(host)
+ if ip != nil {
+ return ip.IsLoopback(), nil
+ }
+
+ // Host is not an ip, perform lookup
+ addrs, err := lookupHostFn(host)
+ if err != nil {
+ return false, err
+ }
+ if len(addrs) == 0 {
+ return false, fmt.Errorf("no addrs found for host, %s", host)
+ }
+
+ for _, addr := range addrs {
+ if !net.ParseIP(addr).IsLoopback() {
+ return false, nil
+ }
+ }
+
+ return true, nil
+}
+
+func validateLocalURL(v string) error {
+ u, err := url.Parse(v)
+ if err != nil {
+ return err
+ }
+
+ host := u.Hostname()
+ if len(host) == 0 {
+ return fmt.Errorf("unable to parse host from local HTTP cred provider URL")
+ } else if isLoopback, err := isLoopbackHost(host); err != nil {
+ return fmt.Errorf("failed to resolve host %q, %v", host, err)
+ } else if !isLoopback {
+ return fmt.Errorf("invalid endpoint host, %q, only host resolving to loopback addresses are allowed", host)
+ }
+
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/provider.go b/vendor/github.com/aws/aws-sdk-go-v2/config/provider.go
new file mode 100644
index 000000000000..ac4c14036681
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/provider.go
@@ -0,0 +1,468 @@
+package config
+
+import (
+ "context"
+ "io"
+ "net/http"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/endpointcreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/processcreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/ssocreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/stscreds"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+)
+
+// sharedConfigProfileProvider provides access to the shared config profile
+// name external configuration value.
+type sharedConfigProfileProvider interface {
+ getSharedConfigProfile(ctx context.Context) (string, bool, error)
+}
+
+// getSharedConfigProfile searches the configs for a sharedConfigProfileProvider
+// and returns the value if found. Returns an error if a provider fails before a
+// value is found.
+func getSharedConfigProfile(ctx context.Context, configs configs) (value string, found bool, err error) {
+ for _, cfg := range configs {
+ if p, ok := cfg.(sharedConfigProfileProvider); ok {
+ value, found, err = p.getSharedConfigProfile(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// sharedConfigFilesProvider provides access to the shared config filesnames
+// external configuration value.
+type sharedConfigFilesProvider interface {
+ getSharedConfigFiles(ctx context.Context) ([]string, bool, error)
+}
+
+// getSharedConfigFiles searches the configs for a sharedConfigFilesProvider
+// and returns the value if found. Returns an error if a provider fails before a
+// value is found.
+func getSharedConfigFiles(ctx context.Context, configs configs) (value []string, found bool, err error) {
+ for _, cfg := range configs {
+ if p, ok := cfg.(sharedConfigFilesProvider); ok {
+ value, found, err = p.getSharedConfigFiles(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+
+ return
+}
+
+// sharedCredentialsFilesProvider provides access to the shared credentials filesnames
+// external configuration value.
+type sharedCredentialsFilesProvider interface {
+ getSharedCredentialsFiles(ctx context.Context) ([]string, bool, error)
+}
+
+// getSharedCredentialsFiles searches the configs for a sharedCredentialsFilesProvider
+// and returns the value if found. Returns an error if a provider fails before a
+// value is found.
+func getSharedCredentialsFiles(ctx context.Context, configs configs) (value []string, found bool, err error) {
+ for _, cfg := range configs {
+ if p, ok := cfg.(sharedCredentialsFilesProvider); ok {
+ value, found, err = p.getSharedCredentialsFiles(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+
+ return
+}
+
+// customCABundleProvider provides access to the custom CA bundle PEM bytes.
+type customCABundleProvider interface {
+ getCustomCABundle(ctx context.Context) (io.Reader, bool, error)
+}
+
+// getCustomCABundle searches the configs for a customCABundleProvider
+// and returns the value if found. Returns an error if a provider fails before a
+// value is found.
+func getCustomCABundle(ctx context.Context, configs configs) (value io.Reader, found bool, err error) {
+ for _, cfg := range configs {
+ if p, ok := cfg.(customCABundleProvider); ok {
+ value, found, err = p.getCustomCABundle(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+
+ return
+}
+
+// regionProvider provides access to the region external configuration value.
+type regionProvider interface {
+ getRegion(ctx context.Context) (string, bool, error)
+}
+
+// getRegion searches the configs for a regionProvider and returns the value
+// if found. Returns an error if a provider fails before a value is found.
+func getRegion(ctx context.Context, configs configs) (value string, found bool, err error) {
+ for _, cfg := range configs {
+ if p, ok := cfg.(regionProvider); ok {
+ value, found, err = p.getRegion(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// ec2IMDSRegionProvider provides access to the ec2 imds region
+// configuration value
+type ec2IMDSRegionProvider interface {
+ getEC2IMDSRegion(ctx context.Context) (string, bool, error)
+}
+
+// getEC2IMDSRegion searches the configs for a ec2IMDSRegionProvider and
+// returns the value if found. Returns an error if a provider fails before
+// a value is found.
+func getEC2IMDSRegion(ctx context.Context, configs configs) (region string, found bool, err error) {
+ for _, cfg := range configs {
+ if provider, ok := cfg.(ec2IMDSRegionProvider); ok {
+ region, found, err = provider.getEC2IMDSRegion(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// credentialsProviderProvider provides access to the credentials external
+// configuration value.
+type credentialsProviderProvider interface {
+ getCredentialsProvider(ctx context.Context) (aws.CredentialsProvider, bool, error)
+}
+
+// getCredentialsProvider searches the configs for a credentialsProviderProvider
+// and returns the value if found. Returns an error if a provider fails before a
+// value is found.
+func getCredentialsProvider(ctx context.Context, configs configs) (p aws.CredentialsProvider, found bool, err error) {
+ for _, cfg := range configs {
+ if provider, ok := cfg.(credentialsProviderProvider); ok {
+ p, found, err = provider.getCredentialsProvider(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// credentialsCacheOptionsProvider is an interface for retrieving a function for setting
+// the aws.CredentialsCacheOptions.
+type credentialsCacheOptionsProvider interface {
+ getCredentialsCacheOptions(ctx context.Context) (func(*aws.CredentialsCacheOptions), bool, error)
+}
+
+// getCredentialsCacheOptionsProvider is an interface for retrieving a function for setting
+// the aws.CredentialsCacheOptions.
+func getCredentialsCacheOptionsProvider(ctx context.Context, configs configs) (
+ f func(*aws.CredentialsCacheOptions), found bool, err error,
+) {
+ for _, config := range configs {
+ if p, ok := config.(credentialsCacheOptionsProvider); ok {
+ f, found, err = p.getCredentialsCacheOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// processCredentialOptions is an interface for retrieving a function for setting
+// the processcreds.Options.
+type processCredentialOptions interface {
+ getProcessCredentialOptions(ctx context.Context) (func(*processcreds.Options), bool, error)
+}
+
+// getProcessCredentialOptions searches the slice of configs and returns the first function found
+func getProcessCredentialOptions(ctx context.Context, configs configs) (f func(*processcreds.Options), found bool, err error) {
+ for _, config := range configs {
+ if p, ok := config.(processCredentialOptions); ok {
+ f, found, err = p.getProcessCredentialOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// ec2RoleCredentialOptionsProvider is an interface for retrieving a function
+// for setting the ec2rolecreds.Provider options.
+type ec2RoleCredentialOptionsProvider interface {
+ getEC2RoleCredentialOptions(ctx context.Context) (func(*ec2rolecreds.Options), bool, error)
+}
+
+// getEC2RoleCredentialProviderOptions searches the slice of configs and returns the first function found
+func getEC2RoleCredentialProviderOptions(ctx context.Context, configs configs) (f func(*ec2rolecreds.Options), found bool, err error) {
+ for _, config := range configs {
+ if p, ok := config.(ec2RoleCredentialOptionsProvider); ok {
+ f, found, err = p.getEC2RoleCredentialOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// defaultRegionProvider is an interface for retrieving a default region if a region was not resolved from other sources
+type defaultRegionProvider interface {
+ getDefaultRegion(ctx context.Context) (string, bool, error)
+}
+
+// getDefaultRegion searches the slice of configs and returns the first fallback region found
+func getDefaultRegion(ctx context.Context, configs configs) (value string, found bool, err error) {
+ for _, config := range configs {
+ if p, ok := config.(defaultRegionProvider); ok {
+ value, found, err = p.getDefaultRegion(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// endpointCredentialOptionsProvider is an interface for retrieving a function for setting
+// the endpointcreds.ProviderOptions.
+type endpointCredentialOptionsProvider interface {
+ getEndpointCredentialOptions(ctx context.Context) (func(*endpointcreds.Options), bool, error)
+}
+
+// getEndpointCredentialProviderOptions searches the slice of configs and returns the first function found
+func getEndpointCredentialProviderOptions(ctx context.Context, configs configs) (f func(*endpointcreds.Options), found bool, err error) {
+ for _, config := range configs {
+ if p, ok := config.(endpointCredentialOptionsProvider); ok {
+ f, found, err = p.getEndpointCredentialOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// webIdentityRoleCredentialOptionsProvider is an interface for retrieving a function for setting
+// the stscreds.WebIdentityRoleProvider.
+type webIdentityRoleCredentialOptionsProvider interface {
+ getWebIdentityRoleCredentialOptions(ctx context.Context) (func(*stscreds.WebIdentityRoleOptions), bool, error)
+}
+
+// getWebIdentityCredentialProviderOptions searches the slice of configs and returns the first function found
+func getWebIdentityCredentialProviderOptions(ctx context.Context, configs configs) (f func(*stscreds.WebIdentityRoleOptions), found bool, err error) {
+ for _, config := range configs {
+ if p, ok := config.(webIdentityRoleCredentialOptionsProvider); ok {
+ f, found, err = p.getWebIdentityRoleCredentialOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// assumeRoleCredentialOptionsProvider is an interface for retrieving a function for setting
+// the stscreds.AssumeRoleOptions.
+type assumeRoleCredentialOptionsProvider interface {
+ getAssumeRoleCredentialOptions(ctx context.Context) (func(*stscreds.AssumeRoleOptions), bool, error)
+}
+
+// getAssumeRoleCredentialProviderOptions searches the slice of configs and returns the first function found
+func getAssumeRoleCredentialProviderOptions(ctx context.Context, configs configs) (f func(*stscreds.AssumeRoleOptions), found bool, err error) {
+ for _, config := range configs {
+ if p, ok := config.(assumeRoleCredentialOptionsProvider); ok {
+ f, found, err = p.getAssumeRoleCredentialOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// HTTPClient is an HTTP client implementation
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// httpClientProvider is an interface for retrieving HTTPClient
+type httpClientProvider interface {
+ getHTTPClient(ctx context.Context) (HTTPClient, bool, error)
+}
+
+// getHTTPClient searches the slice of configs and returns the HTTPClient set on configs
+func getHTTPClient(ctx context.Context, configs configs) (client HTTPClient, found bool, err error) {
+ for _, config := range configs {
+ if p, ok := config.(httpClientProvider); ok {
+ client, found, err = p.getHTTPClient(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// apiOptionsProvider is an interface for retrieving APIOptions
+type apiOptionsProvider interface {
+ getAPIOptions(ctx context.Context) ([]func(*middleware.Stack) error, bool, error)
+}
+
+// getAPIOptions searches the slice of configs and returns the APIOptions set on configs
+func getAPIOptions(ctx context.Context, configs configs) (apiOptions []func(*middleware.Stack) error, found bool, err error) {
+ for _, config := range configs {
+ if p, ok := config.(apiOptionsProvider); ok {
+ // retrieve APIOptions from configs and set it on cfg
+ apiOptions, found, err = p.getAPIOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// endpointResolverProvider is an interface for retrieving an aws.EndpointResolver from a configuration source
+type endpointResolverProvider interface {
+ getEndpointResolver(ctx context.Context) (aws.EndpointResolver, bool, error)
+}
+
+// getEndpointResolver searches the provided config sources for a EndpointResolverFunc that can be used
+// to configure the aws.Config.EndpointResolver value.
+func getEndpointResolver(ctx context.Context, configs configs) (f aws.EndpointResolver, found bool, err error) {
+ for _, c := range configs {
+ if p, ok := c.(endpointResolverProvider); ok {
+ f, found, err = p.getEndpointResolver(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// endpointResolverWithOptionsProvider is an interface for retrieving an aws.EndpointResolverWithOptions from a configuration source
+type endpointResolverWithOptionsProvider interface {
+ getEndpointResolverWithOptions(ctx context.Context) (aws.EndpointResolverWithOptions, bool, error)
+}
+
+// getEndpointResolver searches the provided config sources for a EndpointResolverFunc that can be used
+// to configure the aws.Config.EndpointResolver value.
+func getEndpointResolverWithOptions(ctx context.Context, configs configs) (f aws.EndpointResolverWithOptions, found bool, err error) {
+ for _, c := range configs {
+ if p, ok := c.(endpointResolverWithOptionsProvider); ok {
+ f, found, err = p.getEndpointResolverWithOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// loggerProvider is an interface for retrieving a logging.Logger from a configuration source.
+type loggerProvider interface {
+ getLogger(ctx context.Context) (logging.Logger, bool, error)
+}
+
+// getLogger searches the provided config sources for a logging.Logger that can be used
+// to configure the aws.Config.Logger value.
+func getLogger(ctx context.Context, configs configs) (l logging.Logger, found bool, err error) {
+ for _, c := range configs {
+ if p, ok := c.(loggerProvider); ok {
+ l, found, err = p.getLogger(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// clientLogModeProvider is an interface for retrieving the aws.ClientLogMode from a configuration source.
+type clientLogModeProvider interface {
+ getClientLogMode(ctx context.Context) (aws.ClientLogMode, bool, error)
+}
+
+func getClientLogMode(ctx context.Context, configs configs) (m aws.ClientLogMode, found bool, err error) {
+ for _, c := range configs {
+ if p, ok := c.(clientLogModeProvider); ok {
+ m, found, err = p.getClientLogMode(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// retryProvider is an configuration provider for custom Retryer.
+type retryProvider interface {
+ getRetryer(ctx context.Context) (func() aws.Retryer, bool, error)
+}
+
+func getRetryer(ctx context.Context, configs configs) (v func() aws.Retryer, found bool, err error) {
+ for _, c := range configs {
+ if p, ok := c.(retryProvider); ok {
+ v, found, err = p.getRetryer(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// logConfigurationWarningsProvider is an configuration provider for
+// retrieving a boolean indicating whether configuration issues should
+// be logged when loading from config sources
+type logConfigurationWarningsProvider interface {
+ getLogConfigurationWarnings(ctx context.Context) (bool, bool, error)
+}
+
+func getLogConfigurationWarnings(ctx context.Context, configs configs) (v bool, found bool, err error) {
+ for _, c := range configs {
+ if p, ok := c.(logConfigurationWarningsProvider); ok {
+ v, found, err = p.getLogConfigurationWarnings(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// ssoCredentialOptionsProvider is an interface for retrieving a function for setting
+// the ssocreds.Options.
+type ssoCredentialOptionsProvider interface {
+ getSSOProviderOptions(context.Context) (func(*ssocreds.Options), bool, error)
+}
+
+func getSSOProviderOptions(ctx context.Context, configs configs) (v func(options *ssocreds.Options), found bool, err error) {
+ for _, c := range configs {
+ if p, ok := c.(ssoCredentialOptionsProvider); ok {
+ v, found, err = p.getSSOProviderOptions(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/resolve.go b/vendor/github.com/aws/aws-sdk-go-v2/config/resolve.go
new file mode 100644
index 000000000000..305a2a16a3b0
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/resolve.go
@@ -0,0 +1,243 @@
+package config
+
+import (
+ "context"
+ "crypto/tls"
+ "crypto/x509"
+ "fmt"
+ "io/ioutil"
+ "net/http"
+ "os"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awshttp "github.com/aws/aws-sdk-go-v2/aws/transport/http"
+ "github.com/aws/smithy-go/logging"
+)
+
+// resolveDefaultAWSConfig will write default configuration values into the cfg
+// value. It will write the default values, overwriting any previous value.
+//
+// This should be used as the first resolver in the slice of resolvers when
+// resolving external configuration.
+func resolveDefaultAWSConfig(ctx context.Context, cfg *aws.Config, cfgs configs) error {
+ *cfg = aws.Config{
+ Credentials: aws.AnonymousCredentials{},
+ Logger: logging.NewStandardLogger(os.Stderr),
+ }
+ return nil
+}
+
+// resolveCustomCABundle extracts the first instance of a custom CA bundle filename
+// from the external configurations. It will update the HTTP Client's builder
+// to be configured with the custom CA bundle.
+//
+// Config provider used:
+// * customCABundleProvider
+func resolveCustomCABundle(ctx context.Context, cfg *aws.Config, cfgs configs) error {
+ pemCerts, found, err := getCustomCABundle(ctx, cfgs)
+ if err != nil {
+ // TODO error handling, What is the best way to handle this?
+ // capture previous errors continue. error out if all errors
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ if cfg.HTTPClient == nil {
+ cfg.HTTPClient = awshttp.NewBuildableClient()
+ }
+
+ trOpts, ok := cfg.HTTPClient.(*awshttp.BuildableClient)
+ if !ok {
+ return fmt.Errorf("unable to add custom RootCAs HTTPClient, "+
+ "has no WithTransportOptions, %T", cfg.HTTPClient)
+ }
+
+ var appendErr error
+ client := trOpts.WithTransportOptions(func(tr *http.Transport) {
+ if tr.TLSClientConfig == nil {
+ tr.TLSClientConfig = &tls.Config{}
+ }
+ if tr.TLSClientConfig.RootCAs == nil {
+ tr.TLSClientConfig.RootCAs = x509.NewCertPool()
+ }
+
+ b, err := ioutil.ReadAll(pemCerts)
+ if err != nil {
+ appendErr = fmt.Errorf("failed to read custom CA bundle PEM file")
+ }
+
+ if !tr.TLSClientConfig.RootCAs.AppendCertsFromPEM(b) {
+ appendErr = fmt.Errorf("failed to load custom CA bundle PEM file")
+ }
+ })
+ if appendErr != nil {
+ return appendErr
+ }
+
+ cfg.HTTPClient = client
+ return err
+}
+
+// resolveRegion extracts the first instance of a Region from the configs slice.
+//
+// Config providers used:
+// * regionProvider
+func resolveRegion(ctx context.Context, cfg *aws.Config, configs configs) error {
+ v, found, err := getRegion(ctx, configs)
+ if err != nil {
+ // TODO error handling, What is the best way to handle this?
+ // capture previous errors continue. error out if all errors
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.Region = v
+ return nil
+}
+
+// resolveDefaultRegion extracts the first instance of a default region and sets `aws.Config.Region` to the default
+// region if region had not been resolved from other sources.
+func resolveDefaultRegion(ctx context.Context, cfg *aws.Config, configs configs) error {
+ if len(cfg.Region) > 0 {
+ return nil
+ }
+
+ v, found, err := getDefaultRegion(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.Region = v
+
+ return nil
+}
+
+// resolveHTTPClient extracts the first instance of a HTTPClient and sets `aws.Config.HTTPClient` to the HTTPClient instance
+// if one has not been resolved from other sources.
+func resolveHTTPClient(ctx context.Context, cfg *aws.Config, configs configs) error {
+ c, found, err := getHTTPClient(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.HTTPClient = c
+ return nil
+}
+
+// resolveAPIOptions extracts the first instance of APIOptions and sets `aws.Config.APIOptions` to the resolved API options
+// if one has not been resolved from other sources.
+func resolveAPIOptions(ctx context.Context, cfg *aws.Config, configs configs) error {
+ o, found, err := getAPIOptions(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.APIOptions = o
+
+ return nil
+}
+
+// resolveEndpointResolver extracts the first instance of a EndpointResolverFunc from the config slice
+// and sets the functions result on the aws.Config.EndpointResolver
+func resolveEndpointResolver(ctx context.Context, cfg *aws.Config, configs configs) error {
+ endpointResolver, found, err := getEndpointResolver(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.EndpointResolver = endpointResolver
+
+ return nil
+}
+
+// resolveEndpointResolver extracts the first instance of a EndpointResolverFunc from the config slice
+// and sets the functions result on the aws.Config.EndpointResolver
+func resolveEndpointResolverWithOptions(ctx context.Context, cfg *aws.Config, configs configs) error {
+ endpointResolver, found, err := getEndpointResolverWithOptions(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.EndpointResolverWithOptions = endpointResolver
+
+ return nil
+}
+
+func resolveLogger(ctx context.Context, cfg *aws.Config, configs configs) error {
+ logger, found, err := getLogger(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.Logger = logger
+
+ return nil
+}
+
+func resolveClientLogMode(ctx context.Context, cfg *aws.Config, configs configs) error {
+ mode, found, err := getClientLogMode(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.ClientLogMode = mode
+
+ return nil
+}
+
+func resolveRetryer(ctx context.Context, cfg *aws.Config, configs configs) error {
+ retryer, found, err := getRetryer(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.Retryer = retryer
+
+ return nil
+}
+
+func resolveEC2IMDSRegion(ctx context.Context, cfg *aws.Config, configs configs) error {
+ if len(cfg.Region) > 0 {
+ return nil
+ }
+
+ region, found, err := getEC2IMDSRegion(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if !found {
+ return nil
+ }
+
+ cfg.Region = region
+
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/resolve_credentials.go b/vendor/github.com/aws/aws-sdk-go-v2/config/resolve_credentials.go
new file mode 100644
index 000000000000..6bac0bb4dd8c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/resolve_credentials.go
@@ -0,0 +1,472 @@
+package config
+
+import (
+ "context"
+ "fmt"
+ "net/url"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/credentials"
+ "github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/endpointcreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/processcreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/ssocreds"
+ "github.com/aws/aws-sdk-go-v2/credentials/stscreds"
+ "github.com/aws/aws-sdk-go-v2/feature/ec2/imds"
+ "github.com/aws/aws-sdk-go-v2/service/sso"
+ "github.com/aws/aws-sdk-go-v2/service/sts"
+)
+
+const (
+ // valid credential source values
+ credSourceEc2Metadata = "Ec2InstanceMetadata"
+ credSourceEnvironment = "Environment"
+ credSourceECSContainer = "EcsContainer"
+)
+
+var (
+ ecsContainerEndpoint = "http://169.254.170.2" // not constant to allow for swapping during unit-testing
+)
+
+// resolveCredentials extracts a credential provider from slice of config sources.
+//
+// If an explict credential provider is not found the resolver will fallback to resolving
+// credentials by extracting a credential provider from EnvConfig and SharedConfig.
+func resolveCredentials(ctx context.Context, cfg *aws.Config, configs configs) error {
+ found, err := resolveCredentialProvider(ctx, cfg, configs)
+ if err != nil {
+ return err
+ }
+ if found {
+ return nil
+ }
+
+ err = resolveCredentialChain(ctx, cfg, configs)
+ if err != nil {
+ return err
+ }
+
+ return nil
+}
+
+// resolveCredentialProvider extracts the first instance of Credentials from the
+// config slices.
+//
+// The resolved CredentialProvider will be wrapped in a cache to ensure the
+// credentials are only refreshed when needed. This also protects the
+// credential provider to be used concurrently.
+//
+// Config providers used:
+// * credentialsProviderProvider
+func resolveCredentialProvider(ctx context.Context, cfg *aws.Config, configs configs) (bool, error) {
+ credProvider, found, err := getCredentialsProvider(ctx, configs)
+ if err != nil {
+ return false, err
+ }
+ if !found {
+ return false, nil
+ }
+
+ cfg.Credentials, err = wrapWithCredentialsCache(ctx, configs, credProvider)
+ if err != nil {
+ return false, err
+ }
+
+ return true, nil
+}
+
+// resolveCredentialChain resolves a credential provider chain using EnvConfig
+// and SharedConfig if present in the slice of provided configs.
+//
+// The resolved CredentialProvider will be wrapped in a cache to ensure the
+// credentials are only refreshed when needed. This also protects the
+// credential provider to be used concurrently.
+func resolveCredentialChain(ctx context.Context, cfg *aws.Config, configs configs) (err error) {
+ envConfig, sharedConfig, other := getAWSConfigSources(configs)
+
+ // When checking if a profile was specified programmatically we should only consider the "other"
+ // configuration sources that have been provided. This ensures we correctly honor the expected credential
+ // hierarchy.
+ _, sharedProfileSet, err := getSharedConfigProfile(ctx, other)
+ if err != nil {
+ return err
+ }
+
+ switch {
+ case sharedProfileSet:
+ err = resolveCredsFromProfile(ctx, cfg, envConfig, sharedConfig, other)
+ case envConfig.Credentials.HasKeys():
+ cfg.Credentials = credentials.StaticCredentialsProvider{Value: envConfig.Credentials}
+ case len(envConfig.WebIdentityTokenFilePath) > 0:
+ err = assumeWebIdentity(ctx, cfg, envConfig.WebIdentityTokenFilePath, envConfig.RoleARN, envConfig.RoleSessionName, configs)
+ default:
+ err = resolveCredsFromProfile(ctx, cfg, envConfig, sharedConfig, other)
+ }
+ if err != nil {
+ return err
+ }
+
+ // Wrap the resolved provider in a cache so the SDK will cache credentials.
+ cfg.Credentials, err = wrapWithCredentialsCache(ctx, configs, cfg.Credentials)
+ if err != nil {
+ return err
+ }
+
+ return nil
+}
+
+func resolveCredsFromProfile(ctx context.Context, cfg *aws.Config, envConfig *EnvConfig, sharedConfig *SharedConfig, configs configs) (err error) {
+
+ switch {
+ case sharedConfig.Source != nil:
+ // Assume IAM role with credentials source from a different profile.
+ err = resolveCredsFromProfile(ctx, cfg, envConfig, sharedConfig.Source, configs)
+
+ case sharedConfig.Credentials.HasKeys():
+ // Static Credentials from Shared Config/Credentials file.
+ cfg.Credentials = credentials.StaticCredentialsProvider{
+ Value: sharedConfig.Credentials,
+ }
+
+ case len(sharedConfig.CredentialSource) != 0:
+ err = resolveCredsFromSource(ctx, cfg, envConfig, sharedConfig, configs)
+
+ case len(sharedConfig.WebIdentityTokenFile) != 0:
+ // Credentials from Assume Web Identity token require an IAM Role, and
+ // that roll will be assumed. May be wrapped with another assume role
+ // via SourceProfile.
+ return assumeWebIdentity(ctx, cfg, sharedConfig.WebIdentityTokenFile, sharedConfig.RoleARN, sharedConfig.RoleSessionName, configs)
+
+ case sharedConfig.hasSSOConfiguration():
+ err = resolveSSOCredentials(ctx, cfg, sharedConfig, configs)
+
+ case len(sharedConfig.CredentialProcess) != 0:
+ // Get credentials from CredentialProcess
+ err = processCredentials(ctx, cfg, sharedConfig, configs)
+
+ case len(envConfig.ContainerCredentialsEndpoint) != 0:
+ err = resolveLocalHTTPCredProvider(ctx, cfg, envConfig.ContainerCredentialsEndpoint, envConfig.ContainerAuthorizationToken, configs)
+
+ case len(envConfig.ContainerCredentialsRelativePath) != 0:
+ err = resolveHTTPCredProvider(ctx, cfg, ecsContainerURI(envConfig.ContainerCredentialsRelativePath), envConfig.ContainerAuthorizationToken, configs)
+
+ default:
+ err = resolveEC2RoleCredentials(ctx, cfg, configs)
+ }
+ if err != nil {
+ return err
+ }
+
+ if len(sharedConfig.RoleARN) > 0 {
+ return credsFromAssumeRole(ctx, cfg, sharedConfig, configs)
+ }
+
+ return nil
+}
+
+func resolveSSOCredentials(ctx context.Context, cfg *aws.Config, sharedConfig *SharedConfig, configs configs) error {
+ if err := sharedConfig.validateSSOConfiguration(); err != nil {
+ return err
+ }
+
+ var options []func(*ssocreds.Options)
+ v, found, err := getSSOProviderOptions(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if found {
+ options = append(options, v)
+ }
+
+ cfgCopy := cfg.Copy()
+ cfgCopy.Region = sharedConfig.SSORegion
+
+ cfg.Credentials = ssocreds.New(sso.NewFromConfig(cfgCopy), sharedConfig.SSOAccountID, sharedConfig.SSORoleName, sharedConfig.SSOStartURL, options...)
+
+ return nil
+}
+
+func ecsContainerURI(path string) string {
+ return fmt.Sprintf("%s%s", ecsContainerEndpoint, path)
+}
+
+func processCredentials(ctx context.Context, cfg *aws.Config, sharedConfig *SharedConfig, configs configs) error {
+ var opts []func(*processcreds.Options)
+
+ options, found, err := getProcessCredentialOptions(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if found {
+ opts = append(opts, options)
+ }
+
+ cfg.Credentials = processcreds.NewProvider(sharedConfig.CredentialProcess, opts...)
+
+ return nil
+}
+
+func resolveLocalHTTPCredProvider(ctx context.Context, cfg *aws.Config, endpointURL, authToken string, configs configs) error {
+ var resolveErr error
+
+ parsed, err := url.Parse(endpointURL)
+ if err != nil {
+ resolveErr = fmt.Errorf("invalid URL, %w", err)
+ } else {
+ host := parsed.Hostname()
+ if len(host) == 0 {
+ resolveErr = fmt.Errorf("unable to parse host from local HTTP cred provider URL")
+ } else if isLoopback, loopbackErr := isLoopbackHost(host); loopbackErr != nil {
+ resolveErr = fmt.Errorf("failed to resolve host %q, %v", host, loopbackErr)
+ } else if !isLoopback {
+ resolveErr = fmt.Errorf("invalid endpoint host, %q, only loopback hosts are allowed", host)
+ }
+ }
+
+ if resolveErr != nil {
+ return resolveErr
+ }
+
+ return resolveHTTPCredProvider(ctx, cfg, endpointURL, authToken, configs)
+}
+
+func resolveHTTPCredProvider(ctx context.Context, cfg *aws.Config, url, authToken string, configs configs) error {
+ optFns := []func(*endpointcreds.Options){
+ func(options *endpointcreds.Options) {
+ if len(authToken) != 0 {
+ options.AuthorizationToken = authToken
+ }
+ options.APIOptions = cfg.APIOptions
+ if cfg.Retryer != nil {
+ options.Retryer = cfg.Retryer()
+ }
+ },
+ }
+
+ optFn, found, err := getEndpointCredentialProviderOptions(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if found {
+ optFns = append(optFns, optFn)
+ }
+
+ provider := endpointcreds.New(url, optFns...)
+
+ cfg.Credentials, err = wrapWithCredentialsCache(ctx, configs, provider, func(options *aws.CredentialsCacheOptions) {
+ options.ExpiryWindow = 5 * time.Minute
+ })
+ if err != nil {
+ return err
+ }
+
+ return nil
+}
+
+func resolveCredsFromSource(ctx context.Context, cfg *aws.Config, envConfig *EnvConfig, sharedCfg *SharedConfig, configs configs) (err error) {
+ switch sharedCfg.CredentialSource {
+ case credSourceEc2Metadata:
+ return resolveEC2RoleCredentials(ctx, cfg, configs)
+
+ case credSourceEnvironment:
+ cfg.Credentials = credentials.StaticCredentialsProvider{Value: envConfig.Credentials}
+
+ case credSourceECSContainer:
+ if len(envConfig.ContainerCredentialsRelativePath) == 0 {
+ return fmt.Errorf("EcsContainer was specified as the credential_source, but 'AWS_CONTAINER_CREDENTIALS_RELATIVE_URI' was not set")
+ }
+ return resolveHTTPCredProvider(ctx, cfg, ecsContainerURI(envConfig.ContainerCredentialsRelativePath), envConfig.ContainerAuthorizationToken, configs)
+
+ default:
+ return fmt.Errorf("credential_source values must be EcsContainer, Ec2InstanceMetadata, or Environment")
+ }
+
+ return nil
+}
+
+func resolveEC2RoleCredentials(ctx context.Context, cfg *aws.Config, configs configs) error {
+ optFns := make([]func(*ec2rolecreds.Options), 0, 2)
+
+ optFn, found, err := getEC2RoleCredentialProviderOptions(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if found {
+ optFns = append(optFns, optFn)
+ }
+
+ optFns = append(optFns, func(o *ec2rolecreds.Options) {
+ // Only define a client from config if not already defined.
+ if o.Client == nil {
+ o.Client = imds.NewFromConfig(*cfg)
+ }
+ })
+
+ provider := ec2rolecreds.New(optFns...)
+
+ cfg.Credentials, err = wrapWithCredentialsCache(ctx, configs, provider, func(options *aws.CredentialsCacheOptions) {
+ options.ExpiryWindow = 5 * time.Minute
+ })
+ if err != nil {
+ return err
+ }
+
+ return nil
+}
+
+func getAWSConfigSources(cfgs configs) (*EnvConfig, *SharedConfig, configs) {
+ var (
+ envConfig *EnvConfig
+ sharedConfig *SharedConfig
+ other configs
+ )
+
+ for i := range cfgs {
+ switch c := cfgs[i].(type) {
+ case EnvConfig:
+ if envConfig == nil {
+ envConfig = &c
+ }
+ case *EnvConfig:
+ if envConfig == nil {
+ envConfig = c
+ }
+ case SharedConfig:
+ if sharedConfig == nil {
+ sharedConfig = &c
+ }
+ case *SharedConfig:
+ if envConfig == nil {
+ sharedConfig = c
+ }
+ default:
+ other = append(other, c)
+ }
+ }
+
+ if envConfig == nil {
+ envConfig = &EnvConfig{}
+ }
+
+ if sharedConfig == nil {
+ sharedConfig = &SharedConfig{}
+ }
+
+ return envConfig, sharedConfig, other
+}
+
+// AssumeRoleTokenProviderNotSetError is an error returned when creating a
+// session when the MFAToken option is not set when shared config is configured
+// load assume a role with an MFA token.
+type AssumeRoleTokenProviderNotSetError struct{}
+
+// Error is the error message
+func (e AssumeRoleTokenProviderNotSetError) Error() string {
+ return fmt.Sprintf("assume role with MFA enabled, but AssumeRoleTokenProvider session option not set.")
+}
+
+func assumeWebIdentity(ctx context.Context, cfg *aws.Config, filepath string, roleARN, sessionName string, configs configs) error {
+ if len(filepath) == 0 {
+ return fmt.Errorf("token file path is not set")
+ }
+
+ if len(roleARN) == 0 {
+ return fmt.Errorf("role ARN is not set")
+ }
+
+ optFns := []func(*stscreds.WebIdentityRoleOptions){
+ func(options *stscreds.WebIdentityRoleOptions) {
+ options.RoleSessionName = sessionName
+ },
+ }
+
+ optFn, found, err := getWebIdentityCredentialProviderOptions(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if found {
+ optFns = append(optFns, optFn)
+ }
+
+ provider := stscreds.NewWebIdentityRoleProvider(sts.NewFromConfig(*cfg), roleARN, stscreds.IdentityTokenFile(filepath), optFns...)
+
+ cfg.Credentials = provider
+
+ return nil
+}
+
+func credsFromAssumeRole(ctx context.Context, cfg *aws.Config, sharedCfg *SharedConfig, configs configs) (err error) {
+ optFns := []func(*stscreds.AssumeRoleOptions){
+ func(options *stscreds.AssumeRoleOptions) {
+ options.RoleSessionName = sharedCfg.RoleSessionName
+ if sharedCfg.RoleDurationSeconds != nil {
+ if *sharedCfg.RoleDurationSeconds/time.Minute > 15 {
+ options.Duration = *sharedCfg.RoleDurationSeconds
+ }
+ }
+ // Assume role with external ID
+ if len(sharedCfg.ExternalID) > 0 {
+ options.ExternalID = aws.String(sharedCfg.ExternalID)
+ }
+
+ // Assume role with MFA
+ if len(sharedCfg.MFASerial) != 0 {
+ options.SerialNumber = aws.String(sharedCfg.MFASerial)
+ }
+ },
+ }
+
+ optFn, found, err := getAssumeRoleCredentialProviderOptions(ctx, configs)
+ if err != nil {
+ return err
+ }
+ if found {
+ optFns = append(optFns, optFn)
+ }
+
+ {
+ // Synthesize options early to validate configuration errors sooner to ensure a token provider
+ // is present if the SerialNumber was set.
+ var o stscreds.AssumeRoleOptions
+ for _, fn := range optFns {
+ fn(&o)
+ }
+ if o.TokenProvider == nil && o.SerialNumber != nil {
+ return AssumeRoleTokenProviderNotSetError{}
+ }
+ }
+
+ cfg.Credentials = stscreds.NewAssumeRoleProvider(sts.NewFromConfig(*cfg), sharedCfg.RoleARN, optFns...)
+
+ return nil
+}
+
+// wrapWithCredentialsCache will wrap provider with an aws.CredentialsCache
+// with the provided options if the provider is not already a
+// aws.CredentialsCache.
+func wrapWithCredentialsCache(
+ ctx context.Context,
+ cfgs configs,
+ provider aws.CredentialsProvider,
+ optFns ...func(options *aws.CredentialsCacheOptions),
+) (aws.CredentialsProvider, error) {
+ _, ok := provider.(*aws.CredentialsCache)
+ if ok {
+ return provider, nil
+ }
+
+ credCacheOptions, found, err := getCredentialsCacheOptionsProvider(ctx, cfgs)
+ if err != nil {
+ return nil, err
+ }
+
+ // force allocation of a new slice if the additional options are
+ // needed, to prevent overwriting the passed in slice of options.
+ optFns = optFns[:len(optFns):len(optFns)]
+ if found {
+ optFns = append(optFns, credCacheOptions)
+ }
+
+ return aws.NewCredentialsCache(provider, optFns...), nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/config/shared_config.go b/vendor/github.com/aws/aws-sdk-go-v2/config/shared_config.go
new file mode 100644
index 000000000000..b7222d0206bd
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/config/shared_config.go
@@ -0,0 +1,1310 @@
+package config
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/feature/ec2/imds"
+ "os"
+ "path/filepath"
+ "runtime"
+ "strings"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/internal/ini"
+ "github.com/aws/smithy-go/logging"
+)
+
+const (
+ // Prefix to use for filtering profiles
+ profilePrefix = `profile `
+
+ // string equivalent for boolean
+ endpointDiscoveryDisabled = `false`
+ endpointDiscoveryEnabled = `true`
+ endpointDiscoveryAuto = `auto`
+
+ // Static Credentials group
+ accessKeyIDKey = `aws_access_key_id` // group required
+ secretAccessKey = `aws_secret_access_key` // group required
+ sessionTokenKey = `aws_session_token` // optional
+
+ // Assume Role Credentials group
+ roleArnKey = `role_arn` // group required
+ sourceProfileKey = `source_profile` // group required
+ credentialSourceKey = `credential_source` // group required (or source_profile)
+ externalIDKey = `external_id` // optional
+ mfaSerialKey = `mfa_serial` // optional
+ roleSessionNameKey = `role_session_name` // optional
+ roleDurationSecondsKey = "duration_seconds" // optional
+
+ // AWS Single Sign-On (AWS SSO) group
+ ssoAccountIDKey = "sso_account_id"
+ ssoRegionKey = "sso_region"
+ ssoRoleNameKey = "sso_role_name"
+ ssoStartURL = "sso_start_url"
+
+ // Additional Config fields
+ regionKey = `region`
+
+ // endpoint discovery group
+ enableEndpointDiscoveryKey = `endpoint_discovery_enabled` // optional
+
+ // External Credential process
+ credentialProcessKey = `credential_process` // optional
+
+ // Web Identity Token File
+ webIdentityTokenFileKey = `web_identity_token_file` // optional
+
+ // S3 ARN Region Usage
+ s3UseARNRegionKey = "s3_use_arn_region"
+
+ ec2MetadataServiceEndpointModeKey = "ec2_metadata_service_endpoint_mode"
+
+ ec2MetadataServiceEndpointKey = "ec2_metadata_service_endpoint"
+
+ // Use DualStack Endpoint Resolution
+ useDualStackEndpoint = "use_dualstack_endpoint"
+
+ // DefaultSharedConfigProfile is the default profile to be used when
+ // loading configuration from the config files if another profile name
+ // is not provided.
+ DefaultSharedConfigProfile = `default`
+
+ // S3 Disable Multi-Region AccessPoints
+ s3DisableMultiRegionAccessPointsKey = `s3_disable_multiregion_access_points`
+
+ useFIPSEndpointKey = "use_fips_endpoint"
+)
+
+// defaultSharedConfigProfile allows for swapping the default profile for testing
+var defaultSharedConfigProfile = DefaultSharedConfigProfile
+
+// DefaultSharedCredentialsFilename returns the SDK's default file path
+// for the shared credentials file.
+//
+// Builds the shared config file path based on the OS's platform.
+//
+// - Linux/Unix: $HOME/.aws/credentials
+// - Windows: %USERPROFILE%\.aws\credentials
+func DefaultSharedCredentialsFilename() string {
+ return filepath.Join(userHomeDir(), ".aws", "credentials")
+}
+
+// DefaultSharedConfigFilename returns the SDK's default file path for
+// the shared config file.
+//
+// Builds the shared config file path based on the OS's platform.
+//
+// - Linux/Unix: $HOME/.aws/config
+// - Windows: %USERPROFILE%\.aws\config
+func DefaultSharedConfigFilename() string {
+ return filepath.Join(userHomeDir(), ".aws", "config")
+}
+
+// DefaultSharedConfigFiles is a slice of the default shared config files that
+// the will be used in order to load the SharedConfig.
+var DefaultSharedConfigFiles = []string{
+ DefaultSharedConfigFilename(),
+}
+
+// DefaultSharedCredentialsFiles is a slice of the default shared credentials files that
+// the will be used in order to load the SharedConfig.
+var DefaultSharedCredentialsFiles = []string{
+ DefaultSharedCredentialsFilename(),
+}
+
+// SharedConfig represents the configuration fields of the SDK config files.
+type SharedConfig struct {
+ Profile string
+
+ // Credentials values from the config file. Both aws_access_key_id
+ // and aws_secret_access_key must be provided together in the same file
+ // to be considered valid. The values will be ignored if not a complete group.
+ // aws_session_token is an optional field that can be provided if both of the
+ // other two fields are also provided.
+ //
+ // aws_access_key_id
+ // aws_secret_access_key
+ // aws_session_token
+ Credentials aws.Credentials
+
+ CredentialSource string
+ CredentialProcess string
+ WebIdentityTokenFile string
+
+ SSOAccountID string
+ SSORegion string
+ SSORoleName string
+ SSOStartURL string
+
+ RoleARN string
+ ExternalID string
+ MFASerial string
+ RoleSessionName string
+ RoleDurationSeconds *time.Duration
+
+ SourceProfileName string
+ Source *SharedConfig
+
+ // Region is the region the SDK should use for looking up AWS service endpoints
+ // and signing requests.
+ //
+ // region = us-west-2
+ Region string
+
+ // EnableEndpointDiscovery can be enabled or disabled in the shared config
+ // by setting endpoint_discovery_enabled to true, or false respectively.
+ //
+ // endpoint_discovery_enabled = true
+ EnableEndpointDiscovery aws.EndpointDiscoveryEnableState
+
+ // Specifies if the S3 service should allow ARNs to direct the region
+ // the client's requests are sent to.
+ //
+ // s3_use_arn_region=true
+ S3UseARNRegion *bool
+
+ // Specifies the EC2 Instance Metadata Service default endpoint selection mode (IPv4 or IPv6)
+ //
+ // ec2_metadata_service_endpoint_mode=IPv6
+ EC2IMDSEndpointMode imds.EndpointModeState
+
+ // Specifies the EC2 Instance Metadata Service endpoint to use. If specified it overrides EC2IMDSEndpointMode.
+ //
+ // ec2_metadata_service_endpoint=http://fd00:ec2::254
+ EC2IMDSEndpoint string
+
+ // Specifies if the S3 service should disable support for Multi-Region
+ // access-points
+ //
+ // s3_disable_multiregion_access_points=true
+ S3DisableMultiRegionAccessPoints *bool
+
+ // Specifies that SDK clients must resolve a dual-stack endpoint for
+ // services.
+ //
+ // use_dualstack_endpoint=true
+ UseDualStackEndpoint aws.DualStackEndpointState
+
+ // Specifies that SDK clients must resolve a FIPS endpoint for
+ // services.
+ //
+ // use_fips_endpoint=true
+ UseFIPSEndpoint aws.FIPSEndpointState
+}
+
+// GetS3UseARNRegion returns if the S3 service should allow ARNs to direct the region
+// the client's requests are sent to.
+func (c SharedConfig) GetS3UseARNRegion(ctx context.Context) (value, ok bool, err error) {
+ if c.S3UseARNRegion == nil {
+ return false, false, nil
+ }
+
+ return *c.S3UseARNRegion, true, nil
+}
+
+// GetEnableEndpointDiscovery returns if the enable_endpoint_discovery is set.
+func (c SharedConfig) GetEnableEndpointDiscovery(ctx context.Context) (value aws.EndpointDiscoveryEnableState, ok bool, err error) {
+ if c.EnableEndpointDiscovery == aws.EndpointDiscoveryUnset {
+ return aws.EndpointDiscoveryUnset, false, nil
+ }
+
+ return c.EnableEndpointDiscovery, true, nil
+}
+
+// GetS3DisableMultiRegionAccessPoints returns if the S3 service should disable support for Multi-Region
+// access-points.
+func (c SharedConfig) GetS3DisableMultiRegionAccessPoints(ctx context.Context) (value, ok bool, err error) {
+ if c.S3DisableMultiRegionAccessPoints == nil {
+ return false, false, nil
+ }
+
+ return *c.S3DisableMultiRegionAccessPoints, true, nil
+}
+
+// GetRegion returns the region for the profile if a region is set.
+func (c SharedConfig) getRegion(ctx context.Context) (string, bool, error) {
+ if len(c.Region) == 0 {
+ return "", false, nil
+ }
+ return c.Region, true, nil
+}
+
+// GetCredentialsProvider returns the credentials for a profile if they were set.
+func (c SharedConfig) getCredentialsProvider() (aws.Credentials, bool, error) {
+ return c.Credentials, true, nil
+}
+
+// GetEC2IMDSEndpointMode implements a EC2IMDSEndpointMode option resolver interface.
+func (c SharedConfig) GetEC2IMDSEndpointMode() (imds.EndpointModeState, bool, error) {
+ if c.EC2IMDSEndpointMode == imds.EndpointModeStateUnset {
+ return imds.EndpointModeStateUnset, false, nil
+ }
+
+ return c.EC2IMDSEndpointMode, true, nil
+}
+
+// GetEC2IMDSEndpoint implements a EC2IMDSEndpoint option resolver interface.
+func (c SharedConfig) GetEC2IMDSEndpoint() (string, bool, error) {
+ if len(c.EC2IMDSEndpoint) == 0 {
+ return "", false, nil
+ }
+
+ return c.EC2IMDSEndpoint, true, nil
+}
+
+// GetUseDualStackEndpoint returns whether the service's dual-stack endpoint should be
+// used for requests.
+func (c SharedConfig) GetUseDualStackEndpoint(ctx context.Context) (value aws.DualStackEndpointState, found bool, err error) {
+ if c.UseDualStackEndpoint == aws.DualStackEndpointStateUnset {
+ return aws.DualStackEndpointStateUnset, false, nil
+ }
+
+ return c.UseDualStackEndpoint, true, nil
+}
+
+// GetUseFIPSEndpoint returns whether the service's FIPS endpoint should be
+// used for requests.
+func (c SharedConfig) GetUseFIPSEndpoint(ctx context.Context) (value aws.FIPSEndpointState, found bool, err error) {
+ if c.UseFIPSEndpoint == aws.FIPSEndpointStateUnset {
+ return aws.FIPSEndpointStateUnset, false, nil
+ }
+
+ return c.UseFIPSEndpoint, true, nil
+}
+
+// loadSharedConfigIgnoreNotExist is an alias for loadSharedConfig with the
+// addition of ignoring when none of the files exist or when the profile
+// is not found in any of the files.
+func loadSharedConfigIgnoreNotExist(ctx context.Context, configs configs) (Config, error) {
+ cfg, err := loadSharedConfig(ctx, configs)
+ if err != nil {
+ if _, ok := err.(SharedConfigProfileNotExistError); ok {
+ return SharedConfig{}, nil
+ }
+ return nil, err
+ }
+
+ return cfg, nil
+}
+
+// loadSharedConfig uses the configs passed in to load the SharedConfig from file
+// The file names and profile name are sourced from the configs.
+//
+// If profile name is not provided DefaultSharedConfigProfile (default) will
+// be used.
+//
+// If shared config filenames are not provided DefaultSharedConfigFiles will
+// be used.
+//
+// Config providers used:
+// * sharedConfigProfileProvider
+// * sharedConfigFilesProvider
+func loadSharedConfig(ctx context.Context, configs configs) (Config, error) {
+ var profile string
+ var configFiles []string
+ var credentialsFiles []string
+ var ok bool
+ var err error
+
+ profile, ok, err = getSharedConfigProfile(ctx, configs)
+ if err != nil {
+ return nil, err
+ }
+ if !ok {
+ profile = defaultSharedConfigProfile
+ }
+
+ configFiles, ok, err = getSharedConfigFiles(ctx, configs)
+ if err != nil {
+ return nil, err
+ }
+
+ credentialsFiles, ok, err = getSharedCredentialsFiles(ctx, configs)
+ if err != nil {
+ return nil, err
+ }
+
+ // setup logger if log configuration warning is seti
+ var logger logging.Logger
+ logWarnings, found, err := getLogConfigurationWarnings(ctx, configs)
+ if err != nil {
+ return SharedConfig{}, err
+ }
+ if found && logWarnings {
+ logger, found, err = getLogger(ctx, configs)
+ if err != nil {
+ return SharedConfig{}, err
+ }
+ if !found {
+ logger = logging.NewStandardLogger(os.Stderr)
+ }
+ }
+
+ return LoadSharedConfigProfile(ctx, profile,
+ func(o *LoadSharedConfigOptions) {
+ o.Logger = logger
+ o.ConfigFiles = configFiles
+ o.CredentialsFiles = credentialsFiles
+ },
+ )
+}
+
+// LoadSharedConfigOptions struct contains optional values that can be used to load the config.
+type LoadSharedConfigOptions struct {
+
+ // CredentialsFiles are the shared credentials files
+ CredentialsFiles []string
+
+ // ConfigFiles are the shared config files
+ ConfigFiles []string
+
+ // Logger is the logger used to log shared config behavior
+ Logger logging.Logger
+}
+
+// LoadSharedConfigProfile retrieves the configuration from the list of files
+// using the profile provided. The order the files are listed will determine
+// precedence. Values in subsequent files will overwrite values defined in
+// earlier files.
+//
+// For example, given two files A and B. Both define credentials. If the order
+// of the files are A then B, B's credential values will be used instead of A's.
+//
+// If config files are not set, SDK will default to using a file at location `.aws/config` if present.
+// If credentials files are not set, SDK will default to using a file at location `.aws/credentials` if present.
+// No default files are set, if files set to an empty slice.
+//
+// You can read more about shared config and credentials file location at
+// https://docs.aws.amazon.com/credref/latest/refdocs/file-location.html#file-location
+//
+func LoadSharedConfigProfile(ctx context.Context, profile string, optFns ...func(*LoadSharedConfigOptions)) (SharedConfig, error) {
+ var option LoadSharedConfigOptions
+ for _, fn := range optFns {
+ fn(&option)
+ }
+
+ if option.ConfigFiles == nil {
+ option.ConfigFiles = DefaultSharedConfigFiles
+ }
+
+ if option.CredentialsFiles == nil {
+ option.CredentialsFiles = DefaultSharedCredentialsFiles
+ }
+
+ // load shared configuration sections from shared configuration INI options
+ configSections, err := loadIniFiles(option.ConfigFiles)
+ if err != nil {
+ return SharedConfig{}, err
+ }
+
+ // check for profile prefix and drop duplicates or invalid profiles
+ err = processConfigSections(ctx, configSections, option.Logger)
+ if err != nil {
+ return SharedConfig{}, err
+ }
+
+ // load shared credentials sections from shared credentials INI options
+ credentialsSections, err := loadIniFiles(option.CredentialsFiles)
+ if err != nil {
+ return SharedConfig{}, err
+ }
+
+ // check for profile prefix and drop duplicates or invalid profiles
+ err = processCredentialsSections(ctx, credentialsSections, option.Logger)
+ if err != nil {
+ return SharedConfig{}, err
+ }
+
+ err = mergeSections(configSections, credentialsSections)
+ if err != nil {
+ return SharedConfig{}, err
+ }
+
+ cfg := SharedConfig{}
+ profiles := map[string]struct{}{}
+ if err = cfg.setFromIniSections(profiles, profile, configSections, option.Logger); err != nil {
+ return SharedConfig{}, err
+ }
+
+ return cfg, nil
+}
+
+func processConfigSections(ctx context.Context, sections ini.Sections, logger logging.Logger) error {
+ for _, section := range sections.List() {
+ // drop profiles without prefix for config files
+ if !strings.HasPrefix(section, profilePrefix) && !strings.EqualFold(section, "default") {
+ // drop this section, as invalid profile name
+ sections.DeleteSection(section)
+
+ if logger != nil {
+ logger.Logf(logging.Debug,
+ "A profile defined with name `%v` is ignored. For use within a shared configuration file, "+
+ "a non-default profile must have `profile ` prefixed to the profile name.\n",
+ section,
+ )
+ }
+ }
+ }
+
+ // rename sections to remove `profile ` prefixing to match with credentials file.
+ // if default is already present, it will be dropped.
+ for _, section := range sections.List() {
+ if strings.HasPrefix(section, profilePrefix) {
+ v, ok := sections.GetSection(section)
+ if !ok {
+ return fmt.Errorf("error processing profiles within the shared configuration files")
+ }
+
+ // delete section with profile as prefix
+ sections.DeleteSection(section)
+
+ // set the value to non-prefixed name in sections.
+ section = strings.TrimPrefix(section, profilePrefix)
+ if sections.HasSection(section) {
+ oldSection, _ := sections.GetSection(section)
+ v.Logs = append(v.Logs,
+ fmt.Sprintf("A default profile prefixed with `profile ` found in %s, "+
+ "overrided non-prefixed default profile from %s", v.SourceFile, oldSection.SourceFile))
+ }
+
+ // assign non-prefixed name to section
+ v.Name = section
+ sections.SetSection(section, v)
+ }
+ }
+ return nil
+}
+
+func processCredentialsSections(ctx context.Context, sections ini.Sections, logger logging.Logger) error {
+ for _, section := range sections.List() {
+ // drop profiles with prefix for credential files
+ if strings.HasPrefix(section, profilePrefix) {
+ // drop this section, as invalid profile name
+ sections.DeleteSection(section)
+
+ if logger != nil {
+ logger.Logf(logging.Debug,
+ "The profile defined with name `%v` is ignored. A profile with the `profile ` prefix is invalid "+
+ "for the shared credentials file.\n",
+ section,
+ )
+ }
+ }
+ }
+ return nil
+}
+
+func loadIniFiles(filenames []string) (ini.Sections, error) {
+ mergedSections := ini.NewSections()
+
+ for _, filename := range filenames {
+ sections, err := ini.OpenFile(filename)
+ var v *ini.UnableToReadFile
+ if ok := errors.As(err, &v); ok {
+ // Skip files which can't be opened and read for whatever reason.
+ // We treat such files as empty, and do not fall back to other locations.
+ continue
+ } else if err != nil {
+ return ini.Sections{}, SharedConfigLoadError{Filename: filename, Err: err}
+ }
+
+ // mergeSections into mergedSections
+ err = mergeSections(mergedSections, sections)
+ if err != nil {
+ return ini.Sections{}, SharedConfigLoadError{Filename: filename, Err: err}
+ }
+ }
+
+ return mergedSections, nil
+}
+
+// mergeSections merges source section properties into destination section properties
+func mergeSections(dst, src ini.Sections) error {
+ for _, sectionName := range src.List() {
+ srcSection, _ := src.GetSection(sectionName)
+
+ if (!srcSection.Has(accessKeyIDKey) && srcSection.Has(secretAccessKey)) ||
+ (srcSection.Has(accessKeyIDKey) && !srcSection.Has(secretAccessKey)) {
+ srcSection.Errors = append(srcSection.Errors,
+ fmt.Errorf("partial credentials found for profile %v", sectionName))
+ }
+
+ if !dst.HasSection(sectionName) {
+ dst.SetSection(sectionName, srcSection)
+ continue
+ }
+
+ // merge with destination srcSection
+ dstSection, _ := dst.GetSection(sectionName)
+
+ // errors should be overriden if any
+ dstSection.Errors = srcSection.Errors
+
+ // Access key id update
+ if srcSection.Has(accessKeyIDKey) && srcSection.Has(secretAccessKey) {
+ accessKey := srcSection.String(accessKeyIDKey)
+ secretKey := srcSection.String(secretAccessKey)
+
+ if dstSection.Has(accessKeyIDKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding credentials value for aws access key id, "+
+ "and aws secret access key, defined in %v, with values found in a duplicate profile "+
+ "defined at file %v. \n",
+ sectionName, dstSection.SourceFile[accessKeyIDKey],
+ srcSection.SourceFile[accessKeyIDKey]))
+ }
+
+ // update access key
+ v, err := ini.NewStringValue(accessKey)
+ if err != nil {
+ return fmt.Errorf("error merging access key, %w", err)
+ }
+ dstSection.UpdateValue(accessKeyIDKey, v)
+
+ // update secret key
+ v, err = ini.NewStringValue(secretKey)
+ if err != nil {
+ return fmt.Errorf("error merging secret key, %w", err)
+ }
+ dstSection.UpdateValue(secretAccessKey, v)
+
+ // update session token
+ if srcSection.Has(sessionTokenKey) {
+ sessionKey := srcSection.String(sessionTokenKey)
+
+ val, e := ini.NewStringValue(sessionKey)
+ if e != nil {
+ return fmt.Errorf("error merging session key, %w", e)
+ }
+
+ if dstSection.Has(sessionTokenKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, sessionTokenKey, dstSection.SourceFile[sessionTokenKey],
+ sessionTokenKey, srcSection.SourceFile[sessionTokenKey]))
+ }
+
+ dstSection.UpdateValue(sessionTokenKey, val)
+ dstSection.UpdateSourceFile(sessionTokenKey, srcSection.SourceFile[sessionTokenKey])
+ }
+
+ // update source file to reflect where the static creds came from
+ dstSection.UpdateSourceFile(accessKeyIDKey, srcSection.SourceFile[accessKeyIDKey])
+ dstSection.UpdateSourceFile(secretAccessKey, srcSection.SourceFile[secretAccessKey])
+ }
+
+ if srcSection.Has(roleArnKey) {
+ key := srcSection.String(roleArnKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging roleArnKey, %w", err)
+ }
+
+ if dstSection.Has(roleArnKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, roleArnKey, dstSection.SourceFile[roleArnKey],
+ roleArnKey, srcSection.SourceFile[roleArnKey]))
+ }
+
+ dstSection.UpdateValue(roleArnKey, val)
+ dstSection.UpdateSourceFile(roleArnKey, srcSection.SourceFile[roleArnKey])
+ }
+
+ if srcSection.Has(sourceProfileKey) {
+ key := srcSection.String(sourceProfileKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging sourceProfileKey, %w", err)
+ }
+
+ if dstSection.Has(sourceProfileKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, sourceProfileKey, dstSection.SourceFile[sourceProfileKey],
+ sourceProfileKey, srcSection.SourceFile[sourceProfileKey]))
+ }
+
+ dstSection.UpdateValue(sourceProfileKey, val)
+ dstSection.UpdateSourceFile(sourceProfileKey, srcSection.SourceFile[sourceProfileKey])
+ }
+
+ if srcSection.Has(credentialSourceKey) {
+ key := srcSection.String(credentialSourceKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging credentialSourceKey, %w", err)
+ }
+
+ if dstSection.Has(credentialSourceKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, credentialSourceKey, dstSection.SourceFile[credentialSourceKey],
+ credentialSourceKey, srcSection.SourceFile[credentialSourceKey]))
+ }
+
+ dstSection.UpdateValue(credentialSourceKey, val)
+ dstSection.UpdateSourceFile(credentialSourceKey, srcSection.SourceFile[credentialSourceKey])
+ }
+
+ if srcSection.Has(externalIDKey) {
+ key := srcSection.String(externalIDKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging externalIDKey, %w", err)
+ }
+
+ if dstSection.Has(externalIDKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, externalIDKey, dstSection.SourceFile[externalIDKey],
+ externalIDKey, srcSection.SourceFile[externalIDKey]))
+ }
+
+ dstSection.UpdateValue(externalIDKey, val)
+ dstSection.UpdateSourceFile(externalIDKey, srcSection.SourceFile[externalIDKey])
+ }
+
+ if srcSection.Has(mfaSerialKey) {
+ key := srcSection.String(mfaSerialKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging mfaSerialKey, %w", err)
+ }
+
+ if dstSection.Has(mfaSerialKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, mfaSerialKey, dstSection.SourceFile[mfaSerialKey],
+ mfaSerialKey, srcSection.SourceFile[mfaSerialKey]))
+ }
+
+ dstSection.UpdateValue(mfaSerialKey, val)
+ dstSection.UpdateSourceFile(mfaSerialKey, srcSection.SourceFile[mfaSerialKey])
+ }
+
+ if srcSection.Has(roleSessionNameKey) {
+ key := srcSection.String(roleSessionNameKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging roleSessionNameKey, %w", err)
+ }
+
+ if dstSection.Has(roleSessionNameKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, roleSessionNameKey, dstSection.SourceFile[roleSessionNameKey],
+ roleSessionNameKey, srcSection.SourceFile[roleSessionNameKey]))
+ }
+
+ dstSection.UpdateValue(roleSessionNameKey, val)
+ dstSection.UpdateSourceFile(roleSessionNameKey, srcSection.SourceFile[roleSessionNameKey])
+ }
+
+ // role duration seconds key update
+ if srcSection.Has(roleDurationSecondsKey) {
+ roleDurationSeconds := srcSection.Int(roleDurationSecondsKey)
+ v, err := ini.NewIntValue(roleDurationSeconds)
+ if err != nil {
+ return fmt.Errorf("error merging role duration seconds key, %w", err)
+ }
+ dstSection.UpdateValue(roleDurationSecondsKey, v)
+
+ dstSection.UpdateSourceFile(roleDurationSecondsKey, srcSection.SourceFile[roleDurationSecondsKey])
+ }
+
+ if srcSection.Has(regionKey) {
+ key := srcSection.String(regionKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging regionKey, %w", err)
+ }
+
+ if dstSection.Has(regionKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, regionKey, dstSection.SourceFile[regionKey],
+ regionKey, srcSection.SourceFile[regionKey]))
+ }
+
+ dstSection.UpdateValue(regionKey, val)
+ dstSection.UpdateSourceFile(regionKey, srcSection.SourceFile[regionKey])
+ }
+
+ if srcSection.Has(enableEndpointDiscoveryKey) {
+ key := srcSection.String(enableEndpointDiscoveryKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging enableEndpointDiscoveryKey, %w", err)
+ }
+
+ if dstSection.Has(enableEndpointDiscoveryKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, enableEndpointDiscoveryKey, dstSection.SourceFile[enableEndpointDiscoveryKey],
+ enableEndpointDiscoveryKey, srcSection.SourceFile[enableEndpointDiscoveryKey]))
+ }
+
+ dstSection.UpdateValue(enableEndpointDiscoveryKey, val)
+ dstSection.UpdateSourceFile(enableEndpointDiscoveryKey, srcSection.SourceFile[enableEndpointDiscoveryKey])
+ }
+
+ if srcSection.Has(credentialProcessKey) {
+ key := srcSection.String(credentialProcessKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging credentialProcessKey, %w", err)
+ }
+
+ if dstSection.Has(credentialProcessKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, credentialProcessKey, dstSection.SourceFile[credentialProcessKey],
+ credentialProcessKey, srcSection.SourceFile[credentialProcessKey]))
+ }
+
+ dstSection.UpdateValue(credentialProcessKey, val)
+ dstSection.UpdateSourceFile(credentialProcessKey, srcSection.SourceFile[credentialProcessKey])
+ }
+
+ if srcSection.Has(webIdentityTokenFileKey) {
+ key := srcSection.String(webIdentityTokenFileKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging webIdentityTokenFileKey, %w", err)
+ }
+
+ if dstSection.Has(webIdentityTokenFileKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, webIdentityTokenFileKey, dstSection.SourceFile[webIdentityTokenFileKey],
+ webIdentityTokenFileKey, srcSection.SourceFile[webIdentityTokenFileKey]))
+ }
+
+ dstSection.UpdateValue(webIdentityTokenFileKey, val)
+ dstSection.UpdateSourceFile(webIdentityTokenFileKey, srcSection.SourceFile[webIdentityTokenFileKey])
+ }
+
+ if srcSection.Has(s3UseARNRegionKey) {
+ key := srcSection.String(s3UseARNRegionKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging s3UseARNRegionKey, %w", err)
+ }
+
+ if dstSection.Has(s3UseARNRegionKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, s3UseARNRegionKey, dstSection.SourceFile[s3UseARNRegionKey],
+ s3UseARNRegionKey, srcSection.SourceFile[s3UseARNRegionKey]))
+ }
+
+ dstSection.UpdateValue(s3UseARNRegionKey, val)
+ dstSection.UpdateSourceFile(s3UseARNRegionKey, srcSection.SourceFile[s3UseARNRegionKey])
+ }
+
+ if srcSection.Has(s3DisableMultiRegionAccessPointsKey) {
+ key := srcSection.String(s3DisableMultiRegionAccessPointsKey)
+ val, err := ini.NewStringValue(key)
+ if err != nil {
+ return fmt.Errorf("error merging s3DisableMultiRegionAccessPointsKey, %w", err)
+ }
+
+ if dstSection.Has(s3DisableMultiRegionAccessPointsKey) {
+ dstSection.Logs = append(dstSection.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, defined in %v "+
+ "with a %v value found in a duplicate profile defined at file %v. \n",
+ sectionName, s3DisableMultiRegionAccessPointsKey, dstSection.SourceFile[s3DisableMultiRegionAccessPointsKey],
+ s3DisableMultiRegionAccessPointsKey, srcSection.SourceFile[s3DisableMultiRegionAccessPointsKey]))
+ }
+
+ dstSection.UpdateValue(s3DisableMultiRegionAccessPointsKey, val)
+ dstSection.UpdateSourceFile(s3DisableMultiRegionAccessPointsKey, srcSection.SourceFile[s3DisableMultiRegionAccessPointsKey])
+ }
+
+ // set srcSection on dst srcSection
+ dst = dst.SetSection(sectionName, dstSection)
+ }
+
+ return nil
+}
+
+// Returns an error if all of the files fail to load. If at least one file is
+// successfully loaded and contains the profile, no error will be returned.
+func (c *SharedConfig) setFromIniSections(profiles map[string]struct{}, profile string,
+ sections ini.Sections, logger logging.Logger) error {
+ c.Profile = profile
+
+ section, ok := sections.GetSection(profile)
+ if !ok {
+ return SharedConfigProfileNotExistError{
+ Profile: profile,
+ }
+ }
+
+ // if logs are appended to the section, log them
+ if section.Logs != nil && logger != nil {
+ for _, log := range section.Logs {
+ logger.Logf(logging.Debug, log)
+ }
+ }
+
+ // set config from the provided ini section
+ err := c.setFromIniSection(profile, section)
+ if err != nil {
+ return fmt.Errorf("error fetching config from profile, %v, %w", profile, err)
+ }
+
+ if _, ok := profiles[profile]; ok {
+ // if this is the second instance of the profile the Assume Role
+ // options must be cleared because they are only valid for the
+ // first reference of a profile. The self linked instance of the
+ // profile only have credential provider options.
+ c.clearAssumeRoleOptions()
+ } else {
+ // First time a profile has been seen, It must either be a assume role
+ // credentials, or SSO. Assert if the credential type requires a role ARN,
+ // the ARN is also set, or validate that the SSO configuration is complete.
+ if err := c.validateCredentialsConfig(profile); err != nil {
+ return err
+ }
+ }
+
+ // if not top level profile and has credentials, return with credentials.
+ if len(profiles) != 0 && c.Credentials.HasKeys() {
+ return nil
+ }
+
+ profiles[profile] = struct{}{}
+
+ // validate no colliding credentials type are present
+ if err := c.validateCredentialType(); err != nil {
+ return err
+ }
+
+ // Link source profiles for assume roles
+ if len(c.SourceProfileName) != 0 {
+ // Linked profile via source_profile ignore credential provider
+ // options, the source profile must provide the credentials.
+ c.clearCredentialOptions()
+
+ srcCfg := &SharedConfig{}
+ err := srcCfg.setFromIniSections(profiles, c.SourceProfileName, sections, logger)
+ if err != nil {
+ // SourceProfileName that doesn't exist is an error in configuration.
+ if _, ok := err.(SharedConfigProfileNotExistError); ok {
+ err = SharedConfigAssumeRoleError{
+ RoleARN: c.RoleARN,
+ Profile: c.SourceProfileName,
+ Err: err,
+ }
+ }
+ return err
+ }
+
+ if !srcCfg.hasCredentials() {
+ return SharedConfigAssumeRoleError{
+ RoleARN: c.RoleARN,
+ Profile: c.SourceProfileName,
+ }
+ }
+
+ c.Source = srcCfg
+ }
+
+ return nil
+}
+
+// setFromIniSection loads the configuration from the profile section defined in
+// the provided ini file. A SharedConfig pointer type value is used so that
+// multiple config file loadings can be chained.
+//
+// Only loads complete logically grouped values, and will not set fields in cfg
+// for incomplete grouped values in the config. Such as credentials. For example
+// if a config file only includes aws_access_key_id but no aws_secret_access_key
+// the aws_access_key_id will be ignored.
+func (c *SharedConfig) setFromIniSection(profile string, section ini.Section) error {
+ if len(section.Name) == 0 {
+ sources := make([]string, 0)
+ for _, v := range section.SourceFile {
+ sources = append(sources, v)
+ }
+
+ return fmt.Errorf("parsing error : could not find profile section name after processing files: %v", sources)
+ }
+
+ if len(section.Errors) != 0 {
+ var errStatement string
+ for i, e := range section.Errors {
+ errStatement = fmt.Sprintf("%d, %v\n", i+1, e.Error())
+ }
+ return fmt.Errorf("Error using profile: \n %v", errStatement)
+ }
+
+ // Assume Role
+ updateString(&c.RoleARN, section, roleArnKey)
+ updateString(&c.ExternalID, section, externalIDKey)
+ updateString(&c.MFASerial, section, mfaSerialKey)
+ updateString(&c.RoleSessionName, section, roleSessionNameKey)
+ updateString(&c.SourceProfileName, section, sourceProfileKey)
+ updateString(&c.CredentialSource, section, credentialSourceKey)
+ updateString(&c.Region, section, regionKey)
+
+ // AWS Single Sign-On (AWS SSO)
+ updateString(&c.SSOAccountID, section, ssoAccountIDKey)
+ updateString(&c.SSORegion, section, ssoRegionKey)
+ updateString(&c.SSORoleName, section, ssoRoleNameKey)
+ updateString(&c.SSOStartURL, section, ssoStartURL)
+
+ if section.Has(roleDurationSecondsKey) {
+ d := time.Duration(section.Int(roleDurationSecondsKey)) * time.Second
+ c.RoleDurationSeconds = &d
+ }
+
+ updateString(&c.CredentialProcess, section, credentialProcessKey)
+ updateString(&c.WebIdentityTokenFile, section, webIdentityTokenFileKey)
+
+ updateEndpointDiscoveryType(&c.EnableEndpointDiscovery, section, enableEndpointDiscoveryKey)
+ updateBoolPtr(&c.S3UseARNRegion, section, s3UseARNRegionKey)
+ updateBoolPtr(&c.S3DisableMultiRegionAccessPoints, section, s3DisableMultiRegionAccessPointsKey)
+
+ if err := updateEC2MetadataServiceEndpointMode(&c.EC2IMDSEndpointMode, section, ec2MetadataServiceEndpointModeKey); err != nil {
+ return fmt.Errorf("failed to load %s from shared config, %v", ec2MetadataServiceEndpointModeKey, err)
+ }
+ updateString(&c.EC2IMDSEndpoint, section, ec2MetadataServiceEndpointKey)
+
+ updateUseDualStackEndpoint(&c.UseDualStackEndpoint, section, useDualStackEndpoint)
+ updateUseFIPSEndpoint(&c.UseFIPSEndpoint, section, useFIPSEndpointKey)
+
+ // Shared Credentials
+ creds := aws.Credentials{
+ AccessKeyID: section.String(accessKeyIDKey),
+ SecretAccessKey: section.String(secretAccessKey),
+ SessionToken: section.String(sessionTokenKey),
+ Source: fmt.Sprintf("SharedConfigCredentials: %s", section.SourceFile[accessKeyIDKey]),
+ }
+
+ if creds.HasKeys() {
+ c.Credentials = creds
+ }
+
+ return nil
+}
+
+func updateEC2MetadataServiceEndpointMode(endpointMode *imds.EndpointModeState, section ini.Section, key string) error {
+ if !section.Has(key) {
+ return nil
+ }
+ value := section.String(key)
+ return endpointMode.SetFromString(value)
+}
+
+func (c *SharedConfig) validateCredentialsConfig(profile string) error {
+ if err := c.validateCredentialsRequireARN(profile); err != nil {
+ return err
+ }
+
+ return nil
+}
+
+func (c *SharedConfig) validateCredentialsRequireARN(profile string) error {
+ var credSource string
+
+ switch {
+ case len(c.SourceProfileName) != 0:
+ credSource = sourceProfileKey
+ case len(c.CredentialSource) != 0:
+ credSource = credentialSourceKey
+ case len(c.WebIdentityTokenFile) != 0:
+ credSource = webIdentityTokenFileKey
+ }
+
+ if len(credSource) != 0 && len(c.RoleARN) == 0 {
+ return CredentialRequiresARNError{
+ Type: credSource,
+ Profile: profile,
+ }
+ }
+
+ return nil
+}
+
+func (c *SharedConfig) validateCredentialType() error {
+ // Only one or no credential type can be defined.
+ if !oneOrNone(
+ len(c.SourceProfileName) != 0,
+ len(c.CredentialSource) != 0,
+ len(c.CredentialProcess) != 0,
+ len(c.WebIdentityTokenFile) != 0,
+ ) {
+ return fmt.Errorf("only one credential type may be specified per profile: source profile, credential source, credential process, web identity token, or sso")
+ }
+
+ return nil
+}
+
+func (c *SharedConfig) validateSSOConfiguration() error {
+ if !c.hasSSOConfiguration() {
+ return nil
+ }
+
+ var missing []string
+ if len(c.SSOAccountID) == 0 {
+ missing = append(missing, ssoAccountIDKey)
+ }
+
+ if len(c.SSORegion) == 0 {
+ missing = append(missing, ssoRegionKey)
+ }
+
+ if len(c.SSORoleName) == 0 {
+ missing = append(missing, ssoRoleNameKey)
+ }
+
+ if len(c.SSOStartURL) == 0 {
+ missing = append(missing, ssoStartURL)
+ }
+
+ if len(missing) > 0 {
+ return fmt.Errorf("profile %q is configured to use SSO but is missing required configuration: %s",
+ c.Profile, strings.Join(missing, ", "))
+ }
+
+ return nil
+}
+
+func (c *SharedConfig) hasCredentials() bool {
+ switch {
+ case len(c.SourceProfileName) != 0:
+ case len(c.CredentialSource) != 0:
+ case len(c.CredentialProcess) != 0:
+ case len(c.WebIdentityTokenFile) != 0:
+ case c.hasSSOConfiguration():
+ case c.Credentials.HasKeys():
+ default:
+ return false
+ }
+
+ return true
+}
+
+func (c *SharedConfig) hasSSOConfiguration() bool {
+ switch {
+ case len(c.SSOAccountID) != 0:
+ case len(c.SSORegion) != 0:
+ case len(c.SSORoleName) != 0:
+ case len(c.SSOStartURL) != 0:
+ default:
+ return false
+ }
+ return true
+}
+
+func (c *SharedConfig) clearAssumeRoleOptions() {
+ c.RoleARN = ""
+ c.ExternalID = ""
+ c.MFASerial = ""
+ c.RoleSessionName = ""
+ c.SourceProfileName = ""
+}
+
+func (c *SharedConfig) clearCredentialOptions() {
+ c.CredentialSource = ""
+ c.CredentialProcess = ""
+ c.WebIdentityTokenFile = ""
+ c.Credentials = aws.Credentials{}
+ c.SSOAccountID = ""
+ c.SSORegion = ""
+ c.SSORoleName = ""
+ c.SSOStartURL = ""
+}
+
+// SharedConfigLoadError is an error for the shared config file failed to load.
+type SharedConfigLoadError struct {
+ Filename string
+ Err error
+}
+
+// Unwrap returns the underlying error that caused the failure.
+func (e SharedConfigLoadError) Unwrap() error {
+ return e.Err
+}
+
+func (e SharedConfigLoadError) Error() string {
+ return fmt.Sprintf("failed to load shared config file, %s, %v", e.Filename, e.Err)
+}
+
+// SharedConfigProfileNotExistError is an error for the shared config when
+// the profile was not find in the config file.
+type SharedConfigProfileNotExistError struct {
+ Filename []string
+ Profile string
+ Err error
+}
+
+// Unwrap returns the underlying error that caused the failure.
+func (e SharedConfigProfileNotExistError) Unwrap() error {
+ return e.Err
+}
+
+func (e SharedConfigProfileNotExistError) Error() string {
+ return fmt.Sprintf("failed to get shared config profile, %s", e.Profile)
+}
+
+// SharedConfigAssumeRoleError is an error for the shared config when the
+// profile contains assume role information, but that information is invalid
+// or not complete.
+type SharedConfigAssumeRoleError struct {
+ Profile string
+ RoleARN string
+ Err error
+}
+
+// Unwrap returns the underlying error that caused the failure.
+func (e SharedConfigAssumeRoleError) Unwrap() error {
+ return e.Err
+}
+
+func (e SharedConfigAssumeRoleError) Error() string {
+ return fmt.Sprintf("failed to load assume role %s, of profile %s, %v",
+ e.RoleARN, e.Profile, e.Err)
+}
+
+// CredentialRequiresARNError provides the error for shared config credentials
+// that are incorrectly configured in the shared config or credentials file.
+type CredentialRequiresARNError struct {
+ // type of credentials that were configured.
+ Type string
+
+ // Profile name the credentials were in.
+ Profile string
+}
+
+// Error satisfies the error interface.
+func (e CredentialRequiresARNError) Error() string {
+ return fmt.Sprintf(
+ "credential type %s requires role_arn, profile %s",
+ e.Type, e.Profile,
+ )
+}
+
+func userHomeDir() string {
+ if runtime.GOOS == "windows" { // Windows
+ return os.Getenv("USERPROFILE")
+ }
+
+ // *nix
+ return os.Getenv("HOME")
+}
+
+func oneOrNone(bs ...bool) bool {
+ var count int
+
+ for _, b := range bs {
+ if b {
+ count++
+ if count > 1 {
+ return false
+ }
+ }
+ }
+
+ return true
+}
+
+// updateString will only update the dst with the value in the section key, key
+// is present in the section.
+func updateString(dst *string, section ini.Section, key string) {
+ if !section.Has(key) {
+ return
+ }
+ *dst = section.String(key)
+}
+
+// updateBool will only update the dst with the value in the section key, key
+// is present in the section.
+func updateBool(dst *bool, section ini.Section, key string) {
+ if !section.Has(key) {
+ return
+ }
+ *dst = section.Bool(key)
+}
+
+// updateBoolPtr will only update the dst with the value in the section key,
+// key is present in the section.
+func updateBoolPtr(dst **bool, section ini.Section, key string) {
+ if !section.Has(key) {
+ return
+ }
+ *dst = new(bool)
+ **dst = section.Bool(key)
+}
+
+// updateEndpointDiscoveryType will only update the dst with the value in the section, if
+// a valid key and corresponding EndpointDiscoveryType is found.
+func updateEndpointDiscoveryType(dst *aws.EndpointDiscoveryEnableState, section ini.Section, key string) {
+ if !section.Has(key) {
+ return
+ }
+
+ value := section.String(key)
+ if len(value) == 0 {
+ return
+ }
+
+ switch {
+ case strings.EqualFold(value, endpointDiscoveryDisabled):
+ *dst = aws.EndpointDiscoveryDisabled
+ case strings.EqualFold(value, endpointDiscoveryEnabled):
+ *dst = aws.EndpointDiscoveryEnabled
+ case strings.EqualFold(value, endpointDiscoveryAuto):
+ *dst = aws.EndpointDiscoveryAuto
+ }
+}
+
+// updateEndpointDiscoveryType will only update the dst with the value in the section, if
+// a valid key and corresponding EndpointDiscoveryType is found.
+func updateUseDualStackEndpoint(dst *aws.DualStackEndpointState, section ini.Section, key string) {
+ if !section.Has(key) {
+ return
+ }
+
+ if section.Bool(key) {
+ *dst = aws.DualStackEndpointStateEnabled
+ } else {
+ *dst = aws.DualStackEndpointStateDisabled
+ }
+
+ return
+}
+
+// updateEndpointDiscoveryType will only update the dst with the value in the section, if
+// a valid key and corresponding EndpointDiscoveryType is found.
+func updateUseFIPSEndpoint(dst *aws.FIPSEndpointState, section ini.Section, key string) {
+ if !section.Has(key) {
+ return
+ }
+
+ if section.Bool(key) {
+ *dst = aws.FIPSEndpointStateEnabled
+ } else {
+ *dst = aws.FIPSEndpointStateDisabled
+ }
+
+ return
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/credentials/CHANGELOG.md
new file mode 100644
index 000000000000..67d384c2a88b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/CHANGELOG.md
@@ -0,0 +1,83 @@
+# v1.7.0 (2022-01-07)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.5 (2021-12-21)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.4 (2021-12-02)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.3 (2021-11-30)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.2 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.1 (2021-11-12)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.0 (2021-11-06)
+
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.0 (2021-10-21)
+
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.3 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.2 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.1 (2021-09-10)
+
+* **Documentation**: Fixes the AssumeRoleProvider's documentation for using custom TokenProviders.
+
+# v1.4.0 (2021-08-27)
+
+* **Feature**: Adds support for Tags and TransitiveTagKeys to stscreds.AssumeRoleProvider. Closes https://github.com/aws/aws-sdk-go-v2/issues/723
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.3 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.2 (2021-08-04)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.1 (2021-07-15)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.0 (2021-06-25)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Bug Fix**: Fixed example usages of aws.CredentialsCache ([#1275](https://github.com/aws/aws-sdk-go-v2/pull/1275))
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.1 (2021-05-20)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.0 (2021-05-14)
+
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/credentials/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/doc.go
new file mode 100644
index 000000000000..f6e2873ab906
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/doc.go
@@ -0,0 +1,4 @@
+/*
+Package credentials provides types for retrieving credentials from credentials sources.
+*/
+package credentials
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds/doc.go
new file mode 100644
index 000000000000..ae25c3a489c8
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds/doc.go
@@ -0,0 +1,58 @@
+// Package ec2rolecreds provides the credentials provider implementation for
+// retrieving AWS credentials from Amazon EC2 Instance Roles via Amazon EC2 IMDS.
+//
+// Concurrency and caching
+//
+// The Provider is not safe to be used concurrently, and does not provide any
+// caching of credentials retrieved. You should wrap the Provider with a
+// `aws.CredentialsCache` to provide concurrency safety, and caching of
+// credentials.
+//
+// Loading credentials with the SDK's AWS Config
+//
+// The EC2 Instance role credentials provider will automatically be the resolved
+// credential provider int he credential chain if no other credential provider is
+// resolved first.
+//
+// To explicitly instruct the SDK's credentials resolving to use the EC2 Instance
+// role for credentials, you specify a `credentials_source` property in the config
+// profile the SDK will load.
+//
+// [default]
+// credential_source = Ec2InstanceMetadata
+//
+// Loading credentials with the Provider directly
+//
+// Another way to use the EC2 Instance role credentials provider is to create it
+// directly and assign it as the credentials provider for an API client.
+//
+// The following example creates a credentials provider for a command, and wraps
+// it with the CredentialsCache before assigning the provider to the Amazon S3 API
+// client's Credentials option.
+//
+// provider := imds.New(imds.Options{})
+//
+// // Create the service client value configured for credentials.
+// svc := s3.New(s3.Options{
+// Credentials: aws.NewCredentialsCache(provider),
+// })
+//
+// If you need more control, you can set the configuration options on the
+// credentials provider using the imds.Options type to configure the EC2 IMDS
+// API Client and ExpiryWindow of the retrieved credentials.
+//
+// provider := imds.New(imds.Options{
+// // See imds.Options type's documentation for more options available.
+// Client: imds.New(Options{
+// HTTPClient: customHTTPClient,
+// }),
+//
+// // Modify how soon credentials expire prior to their original expiry time.
+// ExpiryWindow: 5 * time.Minute,
+// })
+//
+// EC2 IMDS API Client
+//
+// See the github.com/aws/aws-sdk-go-v2/feature/ec2/imds module for more details on
+// configuring the client, and options available.
+package ec2rolecreds
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds/provider.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds/provider.go
new file mode 100644
index 000000000000..901132a3253e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds/provider.go
@@ -0,0 +1,174 @@
+package ec2rolecreds
+
+import (
+ "bufio"
+ "context"
+ "encoding/json"
+ "fmt"
+ "path"
+ "strings"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/feature/ec2/imds"
+ "github.com/aws/smithy-go"
+)
+
+// ProviderName provides a name of EC2Role provider
+const ProviderName = "EC2RoleProvider"
+
+// GetMetadataAPIClient provides the interface for an EC2 IMDS API client for the
+// GetMetadata operation.
+type GetMetadataAPIClient interface {
+ GetMetadata(context.Context, *imds.GetMetadataInput, ...func(*imds.Options)) (*imds.GetMetadataOutput, error)
+}
+
+// A Provider retrieves credentials from the EC2 service, and keeps track if
+// those credentials are expired.
+//
+// The New function must be used to create the Provider.
+//
+// p := &ec2rolecreds.New(ec2rolecreds.Options{
+// Client: imds.New(imds.Options{}),
+//
+// // Expire the credentials 10 minutes before IAM states they should.
+// // Proactively refreshing the credentials.
+// ExpiryWindow: 10 * time.Minute
+// })
+type Provider struct {
+ options Options
+}
+
+// Options is a list of user settable options for setting the behavior of the Provider.
+type Options struct {
+ // The API client that will be used by the provider to make GetMetadata API
+ // calls to EC2 IMDS.
+ //
+ // If nil, the provider will default to the EC2 IMDS client.
+ Client GetMetadataAPIClient
+}
+
+// New returns an initialized Provider value configured to retrieve
+// credentials from EC2 Instance Metadata service.
+func New(optFns ...func(*Options)) *Provider {
+ options := Options{}
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ if options.Client == nil {
+ options.Client = imds.New(imds.Options{})
+ }
+
+ return &Provider{
+ options: options,
+ }
+}
+
+// Retrieve retrieves credentials from the EC2 service.
+// Error will be returned if the request fails, or unable to extract
+// the desired credentials.
+func (p *Provider) Retrieve(ctx context.Context) (aws.Credentials, error) {
+ credsList, err := requestCredList(ctx, p.options.Client)
+ if err != nil {
+ return aws.Credentials{Source: ProviderName}, err
+ }
+
+ if len(credsList) == 0 {
+ return aws.Credentials{Source: ProviderName},
+ fmt.Errorf("unexpected empty EC2 IMDS role list")
+ }
+ credsName := credsList[0]
+
+ roleCreds, err := requestCred(ctx, p.options.Client, credsName)
+ if err != nil {
+ return aws.Credentials{Source: ProviderName}, err
+ }
+
+ creds := aws.Credentials{
+ AccessKeyID: roleCreds.AccessKeyID,
+ SecretAccessKey: roleCreds.SecretAccessKey,
+ SessionToken: roleCreds.Token,
+ Source: ProviderName,
+
+ CanExpire: true,
+ Expires: roleCreds.Expiration,
+ }
+
+ return creds, nil
+}
+
+// A ec2RoleCredRespBody provides the shape for unmarshaling credential
+// request responses.
+type ec2RoleCredRespBody struct {
+ // Success State
+ Expiration time.Time
+ AccessKeyID string
+ SecretAccessKey string
+ Token string
+
+ // Error state
+ Code string
+ Message string
+}
+
+const iamSecurityCredsPath = "/iam/security-credentials/"
+
+// requestCredList requests a list of credentials from the EC2 service. If
+// there are no credentials, or there is an error making or receiving the
+// request
+func requestCredList(ctx context.Context, client GetMetadataAPIClient) ([]string, error) {
+ resp, err := client.GetMetadata(ctx, &imds.GetMetadataInput{
+ Path: iamSecurityCredsPath,
+ })
+ if err != nil {
+ return nil, fmt.Errorf("no EC2 IMDS role found, %w", err)
+ }
+ defer resp.Content.Close()
+
+ credsList := []string{}
+ s := bufio.NewScanner(resp.Content)
+ for s.Scan() {
+ credsList = append(credsList, s.Text())
+ }
+
+ if err := s.Err(); err != nil {
+ return nil, fmt.Errorf("failed to read EC2 IMDS role, %w", err)
+ }
+
+ return credsList, nil
+}
+
+// requestCred requests the credentials for a specific credentials from the EC2 service.
+//
+// If the credentials cannot be found, or there is an error reading the response
+// and error will be returned.
+func requestCred(ctx context.Context, client GetMetadataAPIClient, credsName string) (ec2RoleCredRespBody, error) {
+ resp, err := client.GetMetadata(ctx, &imds.GetMetadataInput{
+ Path: path.Join(iamSecurityCredsPath, credsName),
+ })
+ if err != nil {
+ return ec2RoleCredRespBody{},
+ fmt.Errorf("failed to get %s EC2 IMDS role credentials, %w",
+ credsName, err)
+ }
+ defer resp.Content.Close()
+
+ var respCreds ec2RoleCredRespBody
+ if err := json.NewDecoder(resp.Content).Decode(&respCreds); err != nil {
+ return ec2RoleCredRespBody{},
+ fmt.Errorf("failed to decode %s EC2 IMDS role credentials, %w",
+ credsName, err)
+ }
+
+ if !strings.EqualFold(respCreds.Code, "Success") {
+ // If an error code was returned something failed requesting the role.
+ return ec2RoleCredRespBody{},
+ fmt.Errorf("failed to get %s EC2 IMDS role credentials, %w",
+ credsName,
+ &smithy.GenericAPIError{Code: respCreds.Code, Message: respCreds.Message})
+ }
+
+ return respCreds, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client/client.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client/client.go
new file mode 100644
index 000000000000..60b8298f86fc
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client/client.go
@@ -0,0 +1,148 @@
+package client
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/retry"
+ awshttp "github.com/aws/aws-sdk-go-v2/aws/transport/http"
+ "github.com/aws/smithy-go"
+ smithymiddleware "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// ServiceID is the client identifer
+const ServiceID = "endpoint-credentials"
+
+// HTTPClient is a client for sending HTTP requests
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// Options is the endpoint client configurable options
+type Options struct {
+ // The endpoint to retrieve credentials from
+ Endpoint string
+
+ // The HTTP client to invoke API calls with. Defaults to client's default HTTP
+ // implementation if nil.
+ HTTPClient HTTPClient
+
+ // Retryer guides how HTTP requests should be retried in case of recoverable
+ // failures. When nil the API client will use a default retryer.
+ Retryer aws.Retryer
+
+ // Set of options to modify how the credentials operation is invoked.
+ APIOptions []func(*smithymiddleware.Stack) error
+}
+
+// Copy creates a copy of the API options.
+func (o Options) Copy() Options {
+ to := o
+ to.APIOptions = make([]func(*smithymiddleware.Stack) error, len(o.APIOptions))
+ copy(to.APIOptions, o.APIOptions)
+ return to
+}
+
+// Client is an client for retrieving AWS credentials from an endpoint
+type Client struct {
+ options Options
+}
+
+// New constructs a new Client from the given options
+func New(options Options, optFns ...func(*Options)) *Client {
+ options = options.Copy()
+
+ if options.HTTPClient == nil {
+ options.HTTPClient = awshttp.NewBuildableClient()
+ }
+
+ if options.Retryer == nil {
+ options.Retryer = retry.NewStandard()
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ client := &Client{
+ options: options,
+ }
+
+ return client
+}
+
+// GetCredentialsInput is the input to send with the endpoint service to receive credentials.
+type GetCredentialsInput struct {
+ AuthorizationToken string
+}
+
+// GetCredentials retrieves credentials from credential endpoint
+func (c *Client) GetCredentials(ctx context.Context, params *GetCredentialsInput, optFns ...func(*Options)) (*GetCredentialsOutput, error) {
+ stack := smithymiddleware.NewStack("GetCredentials", smithyhttp.NewStackRequest)
+ options := c.options.Copy()
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ stack.Serialize.Add(&serializeOpGetCredential{}, smithymiddleware.After)
+ stack.Build.Add(&buildEndpoint{Endpoint: options.Endpoint}, smithymiddleware.After)
+ stack.Deserialize.Add(&deserializeOpGetCredential{}, smithymiddleware.After)
+ retry.AddRetryMiddlewares(stack, retry.AddRetryMiddlewaresOptions{Retryer: options.Retryer})
+ middleware.AddSDKAgentKey(middleware.FeatureMetadata, ServiceID)
+ smithyhttp.AddErrorCloseResponseBodyMiddleware(stack)
+ smithyhttp.AddCloseResponseBodyMiddleware(stack)
+
+ for _, fn := range options.APIOptions {
+ if err := fn(stack); err != nil {
+ return nil, err
+ }
+ }
+
+ handler := smithymiddleware.DecorateHandler(smithyhttp.NewClientHandler(options.HTTPClient), stack)
+ result, _, err := handler.Handle(ctx, params)
+ if err != nil {
+ return nil, err
+ }
+
+ return result.(*GetCredentialsOutput), err
+}
+
+// GetCredentialsOutput is the response from the credential endpoint
+type GetCredentialsOutput struct {
+ Expiration *time.Time
+ AccessKeyID string
+ SecretAccessKey string
+ Token string
+}
+
+// EndpointError is an error returned from the endpoint service
+type EndpointError struct {
+ Code string `json:"code"`
+ Message string `json:"message"`
+ Fault smithy.ErrorFault `json:"-"`
+}
+
+// Error is the error mesage string
+func (e *EndpointError) Error() string {
+ return fmt.Sprintf("%s: %s", e.Code, e.Message)
+}
+
+// ErrorCode is the error code returned by the endpoint
+func (e *EndpointError) ErrorCode() string {
+ return e.Code
+}
+
+// ErrorMessage is the error message returned by the endpoint
+func (e *EndpointError) ErrorMessage() string {
+ return e.Message
+}
+
+// ErrorFault indicates error fault classification
+func (e *EndpointError) ErrorFault() smithy.ErrorFault {
+ return e.Fault
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client/middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client/middleware.go
new file mode 100644
index 000000000000..40747a53c18f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client/middleware.go
@@ -0,0 +1,120 @@
+package client
+
+import (
+ "context"
+ "encoding/json"
+ "fmt"
+ "net/url"
+
+ "github.com/aws/smithy-go"
+ smithymiddleware "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+type buildEndpoint struct {
+ Endpoint string
+}
+
+func (b *buildEndpoint) ID() string {
+ return "BuildEndpoint"
+}
+
+func (b *buildEndpoint) HandleBuild(ctx context.Context, in smithymiddleware.BuildInput, next smithymiddleware.BuildHandler) (
+ out smithymiddleware.BuildOutput, metadata smithymiddleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport, %T", in.Request)
+ }
+
+ if len(b.Endpoint) == 0 {
+ return out, metadata, fmt.Errorf("endpoint not provided")
+ }
+
+ parsed, err := url.Parse(b.Endpoint)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to parse endpoint, %w", err)
+ }
+
+ request.URL = parsed
+
+ return next.HandleBuild(ctx, in)
+}
+
+type serializeOpGetCredential struct{}
+
+func (s *serializeOpGetCredential) ID() string {
+ return "OperationSerializer"
+}
+
+func (s *serializeOpGetCredential) HandleSerialize(ctx context.Context, in smithymiddleware.SerializeInput, next smithymiddleware.SerializeHandler) (
+ out smithymiddleware.SerializeOutput, metadata smithymiddleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type, %T", in.Request)
+ }
+
+ params, ok := in.Parameters.(*GetCredentialsInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters, %T", in.Parameters)
+ }
+
+ const acceptHeader = "Accept"
+ request.Header[acceptHeader] = append(request.Header[acceptHeader][:0], "application/json")
+
+ if len(params.AuthorizationToken) > 0 {
+ const authHeader = "Authorization"
+ request.Header[authHeader] = append(request.Header[authHeader][:0], params.AuthorizationToken)
+ }
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type deserializeOpGetCredential struct{}
+
+func (d *deserializeOpGetCredential) ID() string {
+ return "OperationDeserializer"
+}
+
+func (d *deserializeOpGetCredential) HandleDeserialize(ctx context.Context, in smithymiddleware.DeserializeInput, next smithymiddleware.DeserializeHandler) (
+ out smithymiddleware.DeserializeOutput, metadata smithymiddleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, deserializeError(response)
+ }
+
+ var shape *GetCredentialsOutput
+ if err = json.NewDecoder(response.Body).Decode(&shape); err != nil {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("failed to deserialize json response, %w", err)}
+ }
+
+ out.Result = shape
+ return out, metadata, err
+}
+
+func deserializeError(response *smithyhttp.Response) error {
+ var errShape *EndpointError
+ err := json.NewDecoder(response.Body).Decode(&errShape)
+ if err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to decode error message, %w", err)}
+ }
+
+ if response.StatusCode >= 500 {
+ errShape.Fault = smithy.FaultServer
+ } else {
+ errShape.Fault = smithy.FaultClient
+ }
+
+ return errShape
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/provider.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/provider.go
new file mode 100644
index 000000000000..40cd7addb374
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/provider.go
@@ -0,0 +1,133 @@
+// Package endpointcreds provides support for retrieving credentials from an
+// arbitrary HTTP endpoint.
+//
+// The credentials endpoint Provider can receive both static and refreshable
+// credentials that will expire. Credentials are static when an "Expiration"
+// value is not provided in the endpoint's response.
+//
+// Static credentials will never expire once they have been retrieved. The format
+// of the static credentials response:
+// {
+// "AccessKeyId" : "MUA...",
+// "SecretAccessKey" : "/7PC5om....",
+// }
+//
+// Refreshable credentials will expire within the "ExpiryWindow" of the Expiration
+// value in the response. The format of the refreshable credentials response:
+// {
+// "AccessKeyId" : "MUA...",
+// "SecretAccessKey" : "/7PC5om....",
+// "Token" : "AQoDY....=",
+// "Expiration" : "2016-02-25T06:03:31Z"
+// }
+//
+// Errors should be returned in the following format and only returned with 400
+// or 500 HTTP status codes.
+// {
+// "code": "ErrorCode",
+// "message": "Helpful error message."
+// }
+package endpointcreds
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client"
+ "github.com/aws/smithy-go/middleware"
+)
+
+// ProviderName is the name of the credentials provider.
+const ProviderName = `CredentialsEndpointProvider`
+
+type getCredentialsAPIClient interface {
+ GetCredentials(context.Context, *client.GetCredentialsInput, ...func(*client.Options)) (*client.GetCredentialsOutput, error)
+}
+
+// Provider satisfies the aws.CredentialsProvider interface, and is a client to
+// retrieve credentials from an arbitrary endpoint.
+type Provider struct {
+ // The AWS Client to make HTTP requests to the endpoint with. The endpoint
+ // the request will be made to is provided by the aws.Config's
+ // EndpointResolver.
+ client getCredentialsAPIClient
+
+ options Options
+}
+
+// HTTPClient is a client for sending HTTP requests
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// Options is structure of configurable options for Provider
+type Options struct {
+ // Endpoint to retrieve credentials from. Required
+ Endpoint string
+
+ // HTTPClient to handle sending HTTP requests to the target endpoint.
+ HTTPClient HTTPClient
+
+ // Set of options to modify how the credentials operation is invoked.
+ APIOptions []func(*middleware.Stack) error
+
+ // The Retryer to be used for determining whether a failed requested should be retried
+ Retryer aws.Retryer
+
+ // Optional authorization token value if set will be used as the value of
+ // the Authorization header of the endpoint credential request.
+ AuthorizationToken string
+}
+
+// New returns a credentials Provider for retrieving AWS credentials
+// from arbitrary endpoint.
+func New(endpoint string, optFns ...func(*Options)) *Provider {
+ o := Options{
+ Endpoint: endpoint,
+ }
+
+ for _, fn := range optFns {
+ fn(&o)
+ }
+
+ p := &Provider{
+ client: client.New(client.Options{
+ HTTPClient: o.HTTPClient,
+ Endpoint: o.Endpoint,
+ APIOptions: o.APIOptions,
+ Retryer: o.Retryer,
+ }),
+ options: o,
+ }
+
+ return p
+}
+
+// Retrieve will attempt to request the credentials from the endpoint the Provider
+// was configured for. And error will be returned if the retrieval fails.
+func (p *Provider) Retrieve(ctx context.Context) (aws.Credentials, error) {
+ resp, err := p.getCredentials(ctx)
+ if err != nil {
+ return aws.Credentials{}, fmt.Errorf("failed to load credentials, %w", err)
+ }
+
+ creds := aws.Credentials{
+ AccessKeyID: resp.AccessKeyID,
+ SecretAccessKey: resp.SecretAccessKey,
+ SessionToken: resp.Token,
+ Source: ProviderName,
+ }
+
+ if resp.Expiration != nil {
+ creds.CanExpire = true
+ creds.Expires = *resp.Expiration
+ }
+
+ return creds, nil
+}
+
+func (p *Provider) getCredentials(ctx context.Context) (*client.GetCredentialsOutput, error) {
+ return p.client.GetCredentials(ctx, &client.GetCredentialsInput{AuthorizationToken: p.options.AuthorizationToken})
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/credentials/go.mod
new file mode 100644
index 000000000000..10e1629b0f3d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/go.mod
@@ -0,0 +1,26 @@
+module github.com/aws/aws-sdk-go-v2/credentials
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.9.0
+ github.com/aws/aws-sdk-go-v2/service/sso v1.8.0
+ github.com/aws/aws-sdk-go-v2/service/sts v1.13.0
+ github.com/aws/smithy-go v1.9.1
+ github.com/google/go-cmp v0.5.6
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../
+
+replace github.com/aws/aws-sdk-go-v2/feature/ec2/imds => ../feature/ec2/imds/
+
+replace github.com/aws/aws-sdk-go-v2/internal/configsources => ../internal/configsources/
+
+replace github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 => ../internal/endpoints/v2/
+
+replace github.com/aws/aws-sdk-go-v2/service/internal/presigned-url => ../service/internal/presigned-url/
+
+replace github.com/aws/aws-sdk-go-v2/service/sso => ../service/sso/
+
+replace github.com/aws/aws-sdk-go-v2/service/sts => ../service/sts/
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/credentials/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/go_module_metadata.go
new file mode 100644
index 000000000000..02da2c3bfc6c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package credentials
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.7.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/processcreds/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/processcreds/doc.go
new file mode 100644
index 000000000000..d56dd8260d78
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/processcreds/doc.go
@@ -0,0 +1,92 @@
+// Package processcreds is a credentials provider to retrieve credentials from a
+// external CLI invoked process.
+//
+// WARNING: The following describes a method of sourcing credentials from an external
+// process. This can potentially be dangerous, so proceed with caution. Other
+// credential providers should be preferred if at all possible. If using this
+// option, you should make sure that the config file is as locked down as possible
+// using security best practices for your operating system.
+//
+// Concurrency and caching
+//
+// The Provider is not safe to be used concurrently, and does not provide any
+// caching of credentials retrieved. You should wrap the Provider with a
+// `aws.CredentialsCache` to provide concurrency safety, and caching of
+// credentials.
+//
+// Loading credentials with the SDKs AWS Config
+//
+// You can use credentials from a AWS shared config `credential_process` in a
+// variety of ways.
+//
+// One way is to setup your shared config file, located in the default
+// location, with the `credential_process` key and the command you want to be
+// called. You also need to set the AWS_SDK_LOAD_CONFIG environment variable
+// (e.g., `export AWS_SDK_LOAD_CONFIG=1`) to use the shared config file.
+//
+// [default]
+// credential_process = /command/to/call
+//
+// Loading configuration using external will use the credential process to
+// retrieve credentials. NOTE: If there are credentials in the profile you are
+// using, the credential process will not be used.
+//
+// // Initialize a session to load credentials.
+// cfg, _ := config.LoadDefaultConfig(context.TODO())
+//
+// // Create S3 service client to use the credentials.
+// svc := s3.NewFromConfig(cfg)
+//
+// Loading credentials with the Provider directly
+//
+// Another way to use the credentials process provider is by using the
+// `NewProvider` constructor to create the provider and providing a it with a
+// command to be executed to retrieve credentials.
+//
+// The following example creates a credentials provider for a command, and wraps
+// it with the CredentialsCache before assigning the provider to the Amazon S3 API
+// client's Credentials option.
+//
+// // Create credentials using the Provider.
+// provider := processcreds.NewProvider("/path/to/command")
+//
+// // Create the service client value configured for credentials.
+// svc := s3.New(s3.Options{
+// Credentials: aws.NewCredentialsCache(provider),
+// })
+//
+// If you need more control, you can set any configurable options in the
+// credentials using one or more option functions.
+//
+// provider := processcreds.NewProvider("/path/to/command",
+// func(o *processcreds.Options) {
+// // Override the provider's default timeout
+// o.Timeout = 2 * time.Minute
+// })
+//
+// You can also use your own `exec.Cmd` value by satisfying a value that satisfies
+// the `NewCommandBuilder` interface and use the `NewProviderCommand` constructor.
+//
+// // Create an exec.Cmd
+// cmdBuilder := processcreds.NewCommandBuilderFunc(
+// func(ctx context.Context) (*exec.Cmd, error) {
+// cmd := exec.CommandContext(ctx,
+// "customCLICommand",
+// "-a", "argument",
+// )
+// cmd.Env = []string{
+// "ENV_VAR_FOO=value",
+// "ENV_VAR_BAR=other_value",
+// }
+//
+// return cmd, nil
+// },
+// )
+//
+// // Create credentials using your exec.Cmd and custom timeout
+// provider := processcreds.NewProviderCommand(cmdBuilder,
+// func(opt *processcreds.Provider) {
+// // optionally override the provider's default timeout
+// opt.Timeout = 1 * time.Second
+// })
+package processcreds
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/processcreds/provider.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/processcreds/provider.go
new file mode 100644
index 000000000000..3921da34cd7e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/processcreds/provider.go
@@ -0,0 +1,269 @@
+package processcreds
+
+import (
+ "bytes"
+ "context"
+ "encoding/json"
+ "fmt"
+ "io"
+ "os"
+ "os/exec"
+ "runtime"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/internal/sdkio"
+)
+
+const (
+ // ProviderName is the name this credentials provider will label any
+ // returned credentials Value with.
+ ProviderName = `ProcessProvider`
+
+ // DefaultTimeout default limit on time a process can run.
+ DefaultTimeout = time.Duration(1) * time.Minute
+)
+
+// ProviderError is an error indicating failure initializing or executing the
+// process credentials provider
+type ProviderError struct {
+ Err error
+}
+
+// Error returns the error message.
+func (e *ProviderError) Error() string {
+ return fmt.Sprintf("process provider error: %v", e.Err)
+}
+
+// Unwrap returns the underlying error the provider error wraps.
+func (e *ProviderError) Unwrap() error {
+ return e.Err
+}
+
+// Provider satisfies the credentials.Provider interface, and is a
+// client to retrieve credentials from a process.
+type Provider struct {
+ // Provides a constructor for exec.Cmd that are invoked by the provider for
+ // retrieving credentials. Use this to provide custom creation of exec.Cmd
+ // with things like environment variables, or other configuration.
+ //
+ // The provider defaults to the DefaultNewCommand function.
+ commandBuilder NewCommandBuilder
+
+ options Options
+}
+
+// Options is the configuration options for configuring the Provider.
+type Options struct {
+ // Timeout limits the time a process can run.
+ Timeout time.Duration
+}
+
+// NewCommandBuilder provides the interface for specifying how command will be
+// created that the Provider will use to retrieve credentials with.
+type NewCommandBuilder interface {
+ NewCommand(context.Context) (*exec.Cmd, error)
+}
+
+// NewCommandBuilderFunc provides a wrapper type around a function pointer to
+// satisfy the NewCommandBuilder interface.
+type NewCommandBuilderFunc func(context.Context) (*exec.Cmd, error)
+
+// NewCommand calls the underlying function pointer the builder was initialized with.
+func (fn NewCommandBuilderFunc) NewCommand(ctx context.Context) (*exec.Cmd, error) {
+ return fn(ctx)
+}
+
+// DefaultNewCommandBuilder provides the default NewCommandBuilder
+// implementation used by the provider. It takes a command and arguments to
+// invoke. The command will also be initialized with the current process
+// environment variables, stderr, and stdin pipes.
+type DefaultNewCommandBuilder struct {
+ Args []string
+}
+
+// NewCommand returns an initialized exec.Cmd with the builder's initialized
+// Args. The command is also initialized current process environment variables,
+// stderr, and stdin pipes.
+func (b DefaultNewCommandBuilder) NewCommand(ctx context.Context) (*exec.Cmd, error) {
+ var cmdArgs []string
+ if runtime.GOOS == "windows" {
+ cmdArgs = []string{"cmd.exe", "/C"}
+ } else {
+ cmdArgs = []string{"sh", "-c"}
+ }
+
+ if len(b.Args) == 0 {
+ return nil, &ProviderError{
+ Err: fmt.Errorf("failed to prepare command: command must not be empty"),
+ }
+ }
+
+ cmdArgs = append(cmdArgs, b.Args...)
+ cmd := exec.CommandContext(ctx, cmdArgs[0], cmdArgs[1:]...)
+ cmd.Env = os.Environ()
+
+ cmd.Stderr = os.Stderr // display stderr on console for MFA
+ cmd.Stdin = os.Stdin // enable stdin for MFA
+
+ return cmd, nil
+}
+
+// NewProvider returns a pointer to a new Credentials object wrapping the
+// Provider.
+//
+// The provider defaults to the DefaultNewCommandBuilder for creating command
+// the Provider will use to retrieve credentials with.
+func NewProvider(command string, options ...func(*Options)) *Provider {
+ var args []string
+
+ // Ensure that the command arguments are not set if the provided command is
+ // empty. This will error out when the command is executed since no
+ // arguments are specified.
+ if len(command) > 0 {
+ args = []string{command}
+ }
+
+ commanBuilder := DefaultNewCommandBuilder{
+ Args: args,
+ }
+ return NewProviderCommand(commanBuilder, options...)
+}
+
+// NewProviderCommand returns a pointer to a new Credentials object with the
+// specified command, and default timeout duration. Use this to provide custom
+// creation of exec.Cmd for options like environment variables, or other
+// configuration.
+func NewProviderCommand(builder NewCommandBuilder, options ...func(*Options)) *Provider {
+ p := &Provider{
+ commandBuilder: builder,
+ options: Options{
+ Timeout: DefaultTimeout,
+ },
+ }
+
+ for _, option := range options {
+ option(&p.options)
+ }
+
+ return p
+}
+
+type credentialProcessResponse struct {
+ Version int
+ AccessKeyID string `json:"AccessKeyId"`
+ SecretAccessKey string
+ SessionToken string
+ Expiration *time.Time
+}
+
+// Retrieve executes the credential process command and returns the
+// credentials, or error if the command fails.
+func (p *Provider) Retrieve(ctx context.Context) (aws.Credentials, error) {
+ out, err := p.executeCredentialProcess(ctx)
+ if err != nil {
+ return aws.Credentials{Source: ProviderName}, err
+ }
+
+ // Serialize and validate response
+ resp := &credentialProcessResponse{}
+ if err = json.Unmarshal(out, resp); err != nil {
+ return aws.Credentials{Source: ProviderName}, &ProviderError{
+ Err: fmt.Errorf("parse failed of process output: %s, error: %w", out, err),
+ }
+ }
+
+ if resp.Version != 1 {
+ return aws.Credentials{Source: ProviderName}, &ProviderError{
+ Err: fmt.Errorf("wrong version in process output (not 1)"),
+ }
+ }
+
+ if len(resp.AccessKeyID) == 0 {
+ return aws.Credentials{Source: ProviderName}, &ProviderError{
+ Err: fmt.Errorf("missing AccessKeyId in process output"),
+ }
+ }
+
+ if len(resp.SecretAccessKey) == 0 {
+ return aws.Credentials{Source: ProviderName}, &ProviderError{
+ Err: fmt.Errorf("missing SecretAccessKey in process output"),
+ }
+ }
+
+ creds := aws.Credentials{
+ Source: ProviderName,
+ AccessKeyID: resp.AccessKeyID,
+ SecretAccessKey: resp.SecretAccessKey,
+ SessionToken: resp.SessionToken,
+ }
+
+ // Handle expiration
+ if resp.Expiration != nil {
+ creds.CanExpire = true
+ creds.Expires = *resp.Expiration
+ }
+
+ return creds, nil
+}
+
+// executeCredentialProcess starts the credential process on the OS and
+// returns the results or an error.
+func (p *Provider) executeCredentialProcess(ctx context.Context) ([]byte, error) {
+ if p.options.Timeout >= 0 {
+ var cancelFunc func()
+ ctx, cancelFunc = context.WithTimeout(ctx, p.options.Timeout)
+ defer cancelFunc()
+ }
+
+ cmd, err := p.commandBuilder.NewCommand(ctx)
+ if err != nil {
+ return nil, err
+ }
+
+ // get creds json on process's stdout
+ output := bytes.NewBuffer(make([]byte, 0, int(8*sdkio.KibiByte)))
+ if cmd.Stdout != nil {
+ cmd.Stdout = io.MultiWriter(cmd.Stdout, output)
+ } else {
+ cmd.Stdout = output
+ }
+
+ execCh := make(chan error, 1)
+ go executeCommand(cmd, execCh)
+
+ select {
+ case execError := <-execCh:
+ if execError == nil {
+ break
+ }
+ select {
+ case <-ctx.Done():
+ return output.Bytes(), &ProviderError{
+ Err: fmt.Errorf("credential process timed out: %w", execError),
+ }
+ default:
+ return output.Bytes(), &ProviderError{
+ Err: fmt.Errorf("error in credential_process: %w", execError),
+ }
+ }
+ }
+
+ out := output.Bytes()
+ if runtime.GOOS == "windows" {
+ // windows adds slashes to quotes
+ out = bytes.ReplaceAll(out, []byte(`\"`), []byte(`"`))
+ }
+
+ return out, nil
+}
+
+func executeCommand(cmd *exec.Cmd, exec chan error) {
+ // Start the command
+ err := cmd.Start()
+ if err == nil {
+ err = cmd.Wait()
+ }
+
+ exec <- err
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/doc.go
new file mode 100644
index 000000000000..2f396c0a1180
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/doc.go
@@ -0,0 +1,63 @@
+// Package ssocreds provides a credential provider for retrieving temporary AWS credentials using an SSO access token.
+//
+// IMPORTANT: The provider in this package does not initiate or perform the AWS SSO login flow. The SDK provider
+// expects that you have already performed the SSO login flow using AWS CLI using the "aws sso login" command, or by
+// some other mechanism. The provider must find a valid non-expired access token for the AWS SSO user portal URL in
+// ~/.aws/sso/cache. If a cached token is not found, it is expired, or the file is malformed an error will be returned.
+//
+// Loading AWS SSO credentials with the AWS shared configuration file
+//
+// You can use configure AWS SSO credentials from the AWS shared configuration file by
+// providing the specifying the required keys in the profile:
+//
+// sso_account_id
+// sso_region
+// sso_role_name
+// sso_start_url
+//
+// For example, the following defines a profile "devsso" and specifies the AWS SSO parameters that defines the target
+// account, role, sign-on portal, and the region where the user portal is located. Note: all SSO arguments must be
+// provided, or an error will be returned.
+//
+// [profile devsso]
+// sso_start_url = https://my-sso-portal.awsapps.com/start
+// sso_role_name = SSOReadOnlyRole
+// sso_region = us-east-1
+// sso_account_id = 123456789012
+//
+// Using the config module, you can load the AWS SDK shared configuration, and specify that this profile be used to
+// retrieve credentials. For example:
+//
+// config, err := config.LoadDefaultConfig(context.TODO(), config.WithSharedConfigProfile("devsso"))
+// if err != nil {
+// return err
+// }
+//
+// Programmatically loading AWS SSO credentials directly
+//
+// You can programmatically construct the AWS SSO Provider in your application, and provide the necessary information
+// to load and retrieve temporary credentials using an access token from ~/.aws/sso/cache.
+//
+// client := sso.NewFromConfig(cfg)
+//
+// var provider aws.CredentialsProvider
+// provider = ssocreds.New(client, "123456789012", "SSOReadOnlyRole", "us-east-1", "https://my-sso-portal.awsapps.com/start")
+//
+// // Wrap the provider with aws.CredentialsCache to cache the credentials until their expire time
+// provider = aws.NewCredentialsCache(provider)
+//
+// credentials, err := provider.Retrieve(context.TODO())
+// if err != nil {
+// return err
+// }
+//
+// It is important that you wrap the Provider with aws.CredentialsCache if you are programmatically constructing the
+// provider directly. This prevents your application from accessing the cached access token and requesting new
+// credentials each time the credentials are used.
+//
+// Additional Resources
+//
+// Configuring the AWS CLI to use AWS Single Sign-On: https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-sso.html
+//
+// AWS Single Sign-On User Guide: https://docs.aws.amazon.com/singlesignon/latest/userguide/what-is.html
+package ssocreds
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/os.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/os.go
new file mode 100644
index 000000000000..d4df39a7a229
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/os.go
@@ -0,0 +1,10 @@
+//go:build !windows
+// +build !windows
+
+package ssocreds
+
+import "os"
+
+func getHomeDirectory() string {
+ return os.Getenv("HOME")
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/os_windows.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/os_windows.go
new file mode 100644
index 000000000000..eb48f61e5bc8
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/os_windows.go
@@ -0,0 +1,7 @@
+package ssocreds
+
+import "os"
+
+func getHomeDirectory() string {
+ return os.Getenv("USERPROFILE")
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/provider.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/provider.go
new file mode 100644
index 000000000000..279df7a1318a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/ssocreds/provider.go
@@ -0,0 +1,184 @@
+package ssocreds
+
+import (
+ "context"
+ "crypto/sha1"
+ "encoding/hex"
+ "encoding/json"
+ "fmt"
+ "io/ioutil"
+ "path/filepath"
+ "strings"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/internal/sdk"
+ "github.com/aws/aws-sdk-go-v2/service/sso"
+)
+
+// ProviderName is the name of the provider used to specify the source of credentials.
+const ProviderName = "SSOProvider"
+
+var defaultCacheLocation func() string
+
+func defaultCacheLocationImpl() string {
+ return filepath.Join(getHomeDirectory(), ".aws", "sso", "cache")
+}
+
+func init() {
+ defaultCacheLocation = defaultCacheLocationImpl
+}
+
+// GetRoleCredentialsAPIClient is a API client that implements the GetRoleCredentials operation.
+type GetRoleCredentialsAPIClient interface {
+ GetRoleCredentials(ctx context.Context, params *sso.GetRoleCredentialsInput, optFns ...func(*sso.Options)) (*sso.GetRoleCredentialsOutput, error)
+}
+
+// Options is the Provider options structure.
+type Options struct {
+ // The Client which is configured for the AWS Region where the AWS SSO user portal is located.
+ Client GetRoleCredentialsAPIClient
+
+ // The AWS account that is assigned to the user.
+ AccountID string
+
+ // The role name that is assigned to the user.
+ RoleName string
+
+ // The URL that points to the organization's AWS Single Sign-On (AWS SSO) user portal.
+ StartURL string
+}
+
+// Provider is an AWS credential provider that retrieves temporary AWS credentials by exchanging an SSO login token.
+type Provider struct {
+ options Options
+}
+
+// New returns a new AWS Single Sign-On (AWS SSO) credential provider. The provided client is expected to be configured
+// for the AWS Region where the AWS SSO user portal is located.
+func New(client GetRoleCredentialsAPIClient, accountID, roleName, startURL string, optFns ...func(options *Options)) *Provider {
+ options := Options{
+ Client: client,
+ AccountID: accountID,
+ RoleName: roleName,
+ StartURL: startURL,
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &Provider{
+ options: options,
+ }
+}
+
+// Retrieve retrieves temporary AWS credentials from the configured Amazon Single Sign-On (AWS SSO) user portal
+// by exchanging the accessToken present in ~/.aws/sso/cache.
+func (p *Provider) Retrieve(ctx context.Context) (aws.Credentials, error) {
+ tokenFile, err := loadTokenFile(p.options.StartURL)
+ if err != nil {
+ return aws.Credentials{}, err
+ }
+
+ output, err := p.options.Client.GetRoleCredentials(ctx, &sso.GetRoleCredentialsInput{
+ AccessToken: &tokenFile.AccessToken,
+ AccountId: &p.options.AccountID,
+ RoleName: &p.options.RoleName,
+ })
+ if err != nil {
+ return aws.Credentials{}, err
+ }
+
+ return aws.Credentials{
+ AccessKeyID: aws.ToString(output.RoleCredentials.AccessKeyId),
+ SecretAccessKey: aws.ToString(output.RoleCredentials.SecretAccessKey),
+ SessionToken: aws.ToString(output.RoleCredentials.SessionToken),
+ Expires: time.Unix(0, output.RoleCredentials.Expiration*int64(time.Millisecond)).UTC(),
+ CanExpire: true,
+ Source: ProviderName,
+ }, nil
+}
+
+func getCacheFileName(url string) (string, error) {
+ hash := sha1.New()
+ _, err := hash.Write([]byte(url))
+ if err != nil {
+ return "", err
+ }
+ return strings.ToLower(hex.EncodeToString(hash.Sum(nil))) + ".json", nil
+}
+
+type rfc3339 time.Time
+
+func (r *rfc3339) UnmarshalJSON(bytes []byte) error {
+ var value string
+
+ if err := json.Unmarshal(bytes, &value); err != nil {
+ return err
+ }
+
+ parse, err := time.Parse(time.RFC3339, value)
+ if err != nil {
+ return fmt.Errorf("expected RFC3339 timestamp: %w", err)
+ }
+
+ *r = rfc3339(parse)
+
+ return nil
+}
+
+type token struct {
+ AccessToken string `json:"accessToken"`
+ ExpiresAt rfc3339 `json:"expiresAt"`
+ Region string `json:"region,omitempty"`
+ StartURL string `json:"startUrl,omitempty"`
+}
+
+func (t token) Expired() bool {
+ return sdk.NowTime().Round(0).After(time.Time(t.ExpiresAt))
+}
+
+// InvalidTokenError is the error type that is returned if loaded token has expired or is otherwise invalid.
+// To refresh the SSO session run aws sso login with the corresponding profile.
+type InvalidTokenError struct {
+ Err error
+}
+
+func (i *InvalidTokenError) Unwrap() error {
+ return i.Err
+}
+
+func (i *InvalidTokenError) Error() string {
+ const msg = "the SSO session has expired or is invalid"
+ if i.Err == nil {
+ return msg
+ }
+ return msg + ": " + i.Err.Error()
+}
+
+func loadTokenFile(startURL string) (t token, err error) {
+ key, err := getCacheFileName(startURL)
+ if err != nil {
+ return token{}, &InvalidTokenError{Err: err}
+ }
+
+ fileBytes, err := ioutil.ReadFile(filepath.Join(defaultCacheLocation(), key))
+ if err != nil {
+ return token{}, &InvalidTokenError{Err: err}
+ }
+
+ if err := json.Unmarshal(fileBytes, &t); err != nil {
+ return token{}, &InvalidTokenError{Err: err}
+ }
+
+ if len(t.AccessToken) == 0 {
+ return token{}, &InvalidTokenError{}
+ }
+
+ if t.Expired() {
+ return token{}, &InvalidTokenError{Err: fmt.Errorf("access token is expired")}
+ }
+
+ return t, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/static_provider.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/static_provider.go
new file mode 100644
index 000000000000..d525cac09601
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/static_provider.go
@@ -0,0 +1,53 @@
+package credentials
+
+import (
+ "context"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+const (
+ // StaticCredentialsName provides a name of Static provider
+ StaticCredentialsName = "StaticCredentials"
+)
+
+// StaticCredentialsEmptyError is emitted when static credentials are empty.
+type StaticCredentialsEmptyError struct{}
+
+func (*StaticCredentialsEmptyError) Error() string {
+ return "static credentials are empty"
+}
+
+// A StaticCredentialsProvider is a set of credentials which are set, and will
+// never expire.
+type StaticCredentialsProvider struct {
+ Value aws.Credentials
+}
+
+// NewStaticCredentialsProvider return a StaticCredentialsProvider initialized with the AWS
+// credentials passed in.
+func NewStaticCredentialsProvider(key, secret, session string) StaticCredentialsProvider {
+ return StaticCredentialsProvider{
+ Value: aws.Credentials{
+ AccessKeyID: key,
+ SecretAccessKey: secret,
+ SessionToken: session,
+ },
+ }
+}
+
+// Retrieve returns the credentials or error if the credentials are invalid.
+func (s StaticCredentialsProvider) Retrieve(_ context.Context) (aws.Credentials, error) {
+ v := s.Value
+ if v.AccessKeyID == "" || v.SecretAccessKey == "" {
+ return aws.Credentials{
+ Source: StaticCredentialsName,
+ }, &StaticCredentialsEmptyError{}
+ }
+
+ if len(v.Source) == 0 {
+ v.Source = StaticCredentialsName
+ }
+
+ return v, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/stscreds/assume_role_provider.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/stscreds/assume_role_provider.go
new file mode 100644
index 000000000000..3cafa4811b59
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/stscreds/assume_role_provider.go
@@ -0,0 +1,302 @@
+// Package stscreds are credential Providers to retrieve STS AWS credentials.
+//
+// STS provides multiple ways to retrieve credentials which can be used when making
+// future AWS service API operation calls.
+//
+// The SDK will ensure that per instance of credentials.Credentials all requests
+// to refresh the credentials will be synchronized. But, the SDK is unable to
+// ensure synchronous usage of the AssumeRoleProvider if the value is shared
+// between multiple Credentials or service clients.
+//
+// Assume Role
+//
+// To assume an IAM role using STS with the SDK you can create a new Credentials
+// with the SDKs's stscreds package.
+//
+// // Initial credentials loaded from SDK's default credential chain. Such as
+// // the environment, shared credentials (~/.aws/credentials), or EC2 Instance
+// // Role. These credentials will be used to to make the STS Assume Role API.
+// cfg, err := config.LoadDefaultConfig(context.TODO())
+// if err != nil {
+// panic(err)
+// }
+//
+// // Create the credentials from AssumeRoleProvider to assume the role
+// // referenced by the "myRoleARN" ARN.
+// stsSvc := sts.NewFromConfig(cfg)
+// creds := stscreds.NewAssumeRoleProvider(stsSvc, "myRoleArn")
+//
+// cfg.Credentials = aws.NewCredentialsCache(creds)
+//
+// // Create service client value configured for credentials
+// // from assumed role.
+// svc := s3.NewFromConfig(cfg)
+//
+// Assume Role with custom MFA Token provider
+//
+// To assume an IAM role with a MFA token you can either specify a custom MFA
+// token provider or use the SDK's built in StdinTokenProvider that will prompt
+// the user for a token code each time the credentials need to to be refreshed.
+// Specifying a custom token provider allows you to control where the token
+// code is retrieved from, and how it is refreshed.
+//
+// With a custom token provider, the provider is responsible for refreshing the
+// token code when called.
+//
+// cfg, err := config.LoadDefaultConfig(context.TODO())
+// if err != nil {
+// panic(err)
+// }
+//
+// staticTokenProvider := func() (string, error) {
+// return someTokenCode, nil
+// }
+//
+// // Create the credentials from AssumeRoleProvider to assume the role
+// // referenced by the "myRoleARN" ARN using the MFA token code provided.
+// creds := stscreds.NewAssumeRoleProvider(sts.NewFromConfig(cfg), "myRoleArn", func(o *stscreds.AssumeRoleOptions) {
+// o.SerialNumber = aws.String("myTokenSerialNumber")
+// o.TokenProvider = staticTokenProvider
+// })
+//
+// cfg.Credentials = aws.NewCredentialsCache(creds)
+//
+// // Create service client value configured for credentials
+// // from assumed role.
+// svc := s3.NewFromConfig(cfg)
+//
+// Assume Role with MFA Token Provider
+//
+// To assume an IAM role with MFA for longer running tasks where the credentials
+// may need to be refreshed setting the TokenProvider field of AssumeRoleProvider
+// will allow the credential provider to prompt for new MFA token code when the
+// role's credentials need to be refreshed.
+//
+// The StdinTokenProvider function is available to prompt on stdin to retrieve
+// the MFA token code from the user. You can also implement custom prompts by
+// satisfying the TokenProvider function signature.
+//
+// Using StdinTokenProvider with multiple AssumeRoleProviders, or Credentials will
+// have undesirable results as the StdinTokenProvider will not be synchronized. A
+// single Credentials with an AssumeRoleProvider can be shared safely.
+//
+// cfg, err := config.LoadDefaultConfig(context.TODO())
+// if err != nil {
+// panic(err)
+// }
+//
+// // Create the credentials from AssumeRoleProvider to assume the role
+// // referenced by the "myRoleARN" ARN using the MFA token code provided.
+// creds := stscreds.NewAssumeRoleProvider(sts.NewFromConfig(cfg), "myRoleArn", func(o *stscreds.AssumeRoleOptions) {
+// o.SerialNumber = aws.String("myTokenSerialNumber")
+// o.TokenProvider = stscreds.StdinTokenProvider
+// })
+//
+// cfg.Credentials = aws.NewCredentialsCache(creds)
+//
+// // Create service client value configured for credentials
+// // from assumed role.
+// svc := s3.NewFromConfig(cfg)
+package stscreds
+
+import (
+ "context"
+ "fmt"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/service/sts"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+)
+
+// StdinTokenProvider will prompt on stdout and read from stdin for a string value.
+// An error is returned if reading from stdin fails.
+//
+// Use this function go read MFA tokens from stdin. The function makes no attempt
+// to make atomic prompts from stdin across multiple gorouties.
+//
+// Using StdinTokenProvider with multiple AssumeRoleProviders, or Credentials will
+// have undesirable results as the StdinTokenProvider will not be synchronized. A
+// single Credentials with an AssumeRoleProvider can be shared safely
+//
+// Will wait forever until something is provided on the stdin.
+func StdinTokenProvider() (string, error) {
+ var v string
+ fmt.Printf("Assume Role MFA token code: ")
+ _, err := fmt.Scanln(&v)
+
+ return v, err
+}
+
+// ProviderName provides a name of AssumeRole provider
+const ProviderName = "AssumeRoleProvider"
+
+// AssumeRoleAPIClient is a client capable of the STS AssumeRole operation.
+type AssumeRoleAPIClient interface {
+ AssumeRole(ctx context.Context, params *sts.AssumeRoleInput, optFns ...func(*sts.Options)) (*sts.AssumeRoleOutput, error)
+}
+
+// DefaultDuration is the default amount of time in minutes that the credentials
+// will be valid for.
+var DefaultDuration = time.Duration(15) * time.Minute
+
+// AssumeRoleProvider retrieves temporary credentials from the STS service, and
+// keeps track of their expiration time.
+//
+// This credential provider will be used by the SDKs default credential change
+// when shared configuration is enabled, and the shared config or shared credentials
+// file configure assume role. See Session docs for how to do this.
+//
+// AssumeRoleProvider does not provide any synchronization and it is not safe
+// to share this value across multiple Credentials, Sessions, or service clients
+// without also sharing the same Credentials instance.
+type AssumeRoleProvider struct {
+ options AssumeRoleOptions
+}
+
+// AssumeRoleOptions is the configurable options for AssumeRoleProvider
+type AssumeRoleOptions struct {
+ // Client implementation of the AssumeRole operation. Required
+ Client AssumeRoleAPIClient
+
+ // IAM Role ARN to be assumed. Required
+ RoleARN string
+
+ // Session name, if you wish to uniquely identify this session.
+ RoleSessionName string
+
+ // Expiry duration of the STS credentials. Defaults to 15 minutes if not set.
+ Duration time.Duration
+
+ // Optional ExternalID to pass along, defaults to nil if not set.
+ ExternalID *string
+
+ // The policy plain text must be 2048 bytes or shorter. However, an internal
+ // conversion compresses it into a packed binary format with a separate limit.
+ // The PackedPolicySize response element indicates by percentage how close to
+ // the upper size limit the policy is, with 100% equaling the maximum allowed
+ // size.
+ Policy *string
+
+ // The ARNs of IAM managed policies you want to use as managed session policies.
+ // The policies must exist in the same account as the role.
+ //
+ // This parameter is optional. You can provide up to 10 managed policy ARNs.
+ // However, the plain text that you use for both inline and managed session
+ // policies can't exceed 2,048 characters.
+ //
+ // An AWS conversion compresses the passed session policies and session tags
+ // into a packed binary format that has a separate limit. Your request can fail
+ // for this limit even if your plain text meets the other requirements. The
+ // PackedPolicySize response element indicates by percentage how close the policies
+ // and tags for your request are to the upper size limit.
+ //
+ // Passing policies to this operation returns new temporary credentials. The
+ // resulting session's permissions are the intersection of the role's identity-based
+ // policy and the session policies. You can use the role's temporary credentials
+ // in subsequent AWS API calls to access resources in the account that owns
+ // the role. You cannot use session policies to grant more permissions than
+ // those allowed by the identity-based policy of the role that is being assumed.
+ // For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide.
+ PolicyARNs []types.PolicyDescriptorType
+
+ // The identification number of the MFA device that is associated with the user
+ // who is making the AssumeRole call. Specify this value if the trust policy
+ // of the role being assumed includes a condition that requires MFA authentication.
+ // The value is either the serial number for a hardware device (such as GAHT12345678)
+ // or an Amazon Resource Name (ARN) for a virtual device (such as arn:aws:iam::123456789012:mfa/user).
+ SerialNumber *string
+
+ // Async method of providing MFA token code for assuming an IAM role with MFA.
+ // The value returned by the function will be used as the TokenCode in the Retrieve
+ // call. See StdinTokenProvider for a provider that prompts and reads from stdin.
+ //
+ // This token provider will be called when ever the assumed role's
+ // credentials need to be refreshed when SerialNumber is set.
+ TokenProvider func() (string, error)
+
+ // A list of session tags that you want to pass. Each session tag consists of a key
+ // name and an associated value. For more information about session tags, see
+ // Tagging STS Sessions
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+ // IAM User Guide. This parameter is optional. You can pass up to 50 session tags.
+ Tags []types.Tag
+
+ // A list of keys for session tags that you want to set as transitive. If you set a
+ // tag key as transitive, the corresponding key and value passes to subsequent
+ // sessions in a role chain. For more information, see Chaining Roles with Session
+ // Tags
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
+ // in the IAM User Guide. This parameter is optional.
+ TransitiveTagKeys []string
+}
+
+// NewAssumeRoleProvider constructs and returns a credentials provider that
+// will retrieve credentials by assuming a IAM role using STS.
+func NewAssumeRoleProvider(client AssumeRoleAPIClient, roleARN string, optFns ...func(*AssumeRoleOptions)) *AssumeRoleProvider {
+ o := AssumeRoleOptions{
+ Client: client,
+ RoleARN: roleARN,
+ }
+
+ for _, fn := range optFns {
+ fn(&o)
+ }
+
+ return &AssumeRoleProvider{
+ options: o,
+ }
+}
+
+// Retrieve generates a new set of temporary credentials using STS.
+func (p *AssumeRoleProvider) Retrieve(ctx context.Context) (aws.Credentials, error) {
+ // Apply defaults where parameters are not set.
+ if len(p.options.RoleSessionName) == 0 {
+ // Try to work out a role name that will hopefully end up unique.
+ p.options.RoleSessionName = fmt.Sprintf("aws-go-sdk-%d", time.Now().UTC().UnixNano())
+ }
+ if p.options.Duration == 0 {
+ // Expire as often as AWS permits.
+ p.options.Duration = DefaultDuration
+ }
+ input := &sts.AssumeRoleInput{
+ DurationSeconds: aws.Int32(int32(p.options.Duration / time.Second)),
+ PolicyArns: p.options.PolicyARNs,
+ RoleArn: aws.String(p.options.RoleARN),
+ RoleSessionName: aws.String(p.options.RoleSessionName),
+ ExternalId: p.options.ExternalID,
+ Tags: p.options.Tags,
+ TransitiveTagKeys: p.options.TransitiveTagKeys,
+ }
+ if p.options.Policy != nil {
+ input.Policy = p.options.Policy
+ }
+ if p.options.SerialNumber != nil {
+ if p.options.TokenProvider != nil {
+ input.SerialNumber = p.options.SerialNumber
+ code, err := p.options.TokenProvider()
+ if err != nil {
+ return aws.Credentials{}, err
+ }
+ input.TokenCode = aws.String(code)
+ } else {
+ return aws.Credentials{}, fmt.Errorf("assume role with MFA enabled, but TokenProvider is not set")
+ }
+ }
+
+ resp, err := p.options.Client.AssumeRole(ctx, input)
+ if err != nil {
+ return aws.Credentials{Source: ProviderName}, err
+ }
+
+ return aws.Credentials{
+ AccessKeyID: *resp.Credentials.AccessKeyId,
+ SecretAccessKey: *resp.Credentials.SecretAccessKey,
+ SessionToken: *resp.Credentials.SessionToken,
+ Source: ProviderName,
+
+ CanExpire: true,
+ Expires: *resp.Credentials.Expiration,
+ }, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/credentials/stscreds/web_identity_provider.go b/vendor/github.com/aws/aws-sdk-go-v2/credentials/stscreds/web_identity_provider.go
new file mode 100644
index 000000000000..7854a3228c0a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/credentials/stscreds/web_identity_provider.go
@@ -0,0 +1,127 @@
+package stscreds
+
+import (
+ "context"
+ "fmt"
+ "io/ioutil"
+ "strconv"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/aws/retry"
+ "github.com/aws/aws-sdk-go-v2/internal/sdk"
+ "github.com/aws/aws-sdk-go-v2/service/sts"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+)
+
+var invalidIdentityTokenExceptionCode = (&types.InvalidIdentityTokenException{}).ErrorCode()
+
+const (
+ // WebIdentityProviderName is the web identity provider name
+ WebIdentityProviderName = "WebIdentityCredentials"
+)
+
+// AssumeRoleWithWebIdentityAPIClient is a client capable of the STS AssumeRoleWithWebIdentity operation.
+type AssumeRoleWithWebIdentityAPIClient interface {
+ AssumeRoleWithWebIdentity(ctx context.Context, params *sts.AssumeRoleWithWebIdentityInput, optFns ...func(*sts.Options)) (*sts.AssumeRoleWithWebIdentityOutput, error)
+}
+
+// WebIdentityRoleProvider is used to retrieve credentials using
+// an OIDC token.
+type WebIdentityRoleProvider struct {
+ options WebIdentityRoleOptions
+}
+
+// WebIdentityRoleOptions is a structure of configurable options for WebIdentityRoleProvider
+type WebIdentityRoleOptions struct {
+ // Client implementation of the AssumeRoleWithWebIdentity operation. Required
+ Client AssumeRoleWithWebIdentityAPIClient
+
+ // JWT Token Provider. Required
+ TokenRetriever IdentityTokenRetriever
+
+ // IAM Role ARN to assume. Required
+ RoleARN string
+
+ // Session name, if you wish to uniquely identify this session.
+ RoleSessionName string
+
+ // The Amazon Resource Names (ARNs) of the IAM managed policies that you
+ // want to use as managed session policies. The policies must exist in the
+ // same account as the role.
+ PolicyARNs []types.PolicyDescriptorType
+}
+
+// IdentityTokenRetriever is an interface for retrieving a JWT
+type IdentityTokenRetriever interface {
+ GetIdentityToken() ([]byte, error)
+}
+
+// IdentityTokenFile is for retrieving an identity token from the given file name
+type IdentityTokenFile string
+
+// GetIdentityToken retrieves the JWT token from the file and returns the contents as a []byte
+func (j IdentityTokenFile) GetIdentityToken() ([]byte, error) {
+ b, err := ioutil.ReadFile(string(j))
+ if err != nil {
+ return nil, fmt.Errorf("unable to read file at %s: %v", string(j), err)
+ }
+
+ return b, nil
+}
+
+// NewWebIdentityRoleProvider will return a new WebIdentityRoleProvider with the
+// provided stsiface.ClientAPI
+func NewWebIdentityRoleProvider(client AssumeRoleWithWebIdentityAPIClient, roleARN string, tokenRetriever IdentityTokenRetriever, optFns ...func(*WebIdentityRoleOptions)) *WebIdentityRoleProvider {
+ o := WebIdentityRoleOptions{
+ Client: client,
+ RoleARN: roleARN,
+ TokenRetriever: tokenRetriever,
+ }
+
+ for _, fn := range optFns {
+ fn(&o)
+ }
+
+ return &WebIdentityRoleProvider{options: o}
+}
+
+// Retrieve will attempt to assume a role from a token which is located at
+// 'WebIdentityTokenFilePath' specified destination and if that is empty an
+// error will be returned.
+func (p *WebIdentityRoleProvider) Retrieve(ctx context.Context) (aws.Credentials, error) {
+ b, err := p.options.TokenRetriever.GetIdentityToken()
+ if err != nil {
+ return aws.Credentials{}, fmt.Errorf("failed to retrieve jwt from provide source, %w", err)
+ }
+
+ sessionName := p.options.RoleSessionName
+ if len(sessionName) == 0 {
+ // session name is used to uniquely identify a session. This simply
+ // uses unix time in nanoseconds to uniquely identify sessions.
+ sessionName = strconv.FormatInt(sdk.NowTime().UnixNano(), 10)
+ }
+ resp, err := p.options.Client.AssumeRoleWithWebIdentity(ctx, &sts.AssumeRoleWithWebIdentityInput{
+ PolicyArns: p.options.PolicyARNs,
+ RoleArn: &p.options.RoleARN,
+ RoleSessionName: &sessionName,
+ WebIdentityToken: aws.String(string(b)),
+ }, func(options *sts.Options) {
+ options.Retryer = retry.AddWithErrorCodes(options.Retryer, invalidIdentityTokenExceptionCode)
+ })
+ if err != nil {
+ return aws.Credentials{}, fmt.Errorf("failed to retrieve credentials, %w", err)
+ }
+
+ // InvalidIdentityToken error is a temporary error that can occur
+ // when assuming an Role with a JWT web identity token.
+
+ value := aws.Credentials{
+ AccessKeyID: aws.ToString(resp.Credentials.AccessKeyId),
+ SecretAccessKey: aws.ToString(resp.Credentials.SecretAccessKey),
+ SessionToken: aws.ToString(resp.Credentials.SessionToken),
+ Source: WebIdentityProviderName,
+ CanExpire: true,
+ Expires: *resp.Credentials.Expiration,
+ }
+ return value, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/doc.go
new file mode 100644
index 000000000000..81644bf8b7a0
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/doc.go
@@ -0,0 +1,58 @@
+// Package sdk is the official AWS SDK v2 for the Go programming language.
+//
+// aws-sdk-go-v2 is the the v2 of the AWS SDK for the Go programming language.
+//
+// Getting started
+//
+// The best way to get started working with the SDK is to use `go get` to add the
+// SDK and desired service clients to your Go dependencies explicitly.
+//
+// go get github.com/aws/aws-sdk-go-v2
+// go get github.com/aws/aws-sdk-go-v2/config
+// go get github.com/aws/aws-sdk-go-v2/service/dynamodb
+//
+// Hello AWS
+//
+// This example shows how you can use the v2 SDK to make an API request using the
+// SDK's Amazon DynamoDB client.
+//
+// package main
+//
+// import (
+// "context"
+// "fmt"
+// "log"
+//
+// "github.com/aws/aws-sdk-go-v2/aws"
+// "github.com/aws/aws-sdk-go-v2/config"
+// "github.com/aws/aws-sdk-go-v2/service/dynamodb"
+// )
+//
+// func main() {
+// // Using the SDK's default configuration, loading additional config
+// // and credentials values from the environment variables, shared
+// // credentials, and shared configuration files
+// cfg, err := config.LoadDefaultConfig(context.TODO(),
+// config.WithRegion("us-west-2"),
+// )
+// if err != nil {
+// log.Fatalf("unable to load SDK config, %v", err)
+// }
+//
+// // Using the Config value, create the DynamoDB client
+// svc := dynamodb.NewFromConfig(cfg)
+//
+// // Build the request with its input parameters
+// resp, err := svc.ListTables(context.TODO(), &dynamodb.ListTablesInput{
+// Limit: aws.Int32(5),
+// })
+// if err != nil {
+// log.Fatalf("failed to list tables, %v", err)
+// }
+//
+// fmt.Println("Tables:")
+// for _, tableName := range resp.TableNames {
+// fmt.Println(tableName)
+// }
+// }
+package sdk
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/CHANGELOG.md
new file mode 100644
index 000000000000..f03ea2cd7f5c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/CHANGELOG.md
@@ -0,0 +1,68 @@
+# v1.9.0 (2022-01-07)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.2 (2021-12-02)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.0 (2021-11-06)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.7.0 (2021-10-21)
+
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.0 (2021-10-11)
+
+* **Feature**: Respect passed in Context Deadline/Timeout. Updates the IMDS Client operations to not override the passed in Context's Deadline or Timeout options. If an Client operation is called with a Context with a Deadline or Timeout, the client will no longer override it with the client's default timeout.
+* **Bug Fix**: Fix IMDS client's response handling and operation timeout race. Fixes #1253
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.1 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.0 (2021-08-27)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.1 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.0 (2021-08-04)
+
+* **Feature**: adds error handling for defered close calls
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.0 (2021-07-15)
+
+* **Feature**: Support has been added for EC2 IPv6-enabled Instance Metadata Service Endpoints.
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.0 (2021-06-25)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.1 (2021-05-20)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.0 (2021-05-14)
+
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_client.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_client.go
new file mode 100644
index 000000000000..53f3d3c781ae
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_client.go
@@ -0,0 +1,318 @@
+package imds
+
+import (
+ "context"
+ "fmt"
+ "net"
+ "net/http"
+ "os"
+ "strings"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/aws/retry"
+ awshttp "github.com/aws/aws-sdk-go-v2/aws/transport/http"
+ internalconfig "github.com/aws/aws-sdk-go-v2/feature/ec2/imds/internal/config"
+ "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// ServiceID provides the unique name of this API client
+const ServiceID = "ec2imds"
+
+// Client provides the API client for interacting with the Amazon EC2 Instance
+// Metadata Service API.
+type Client struct {
+ options Options
+}
+
+// ClientEnableState provides an enumeration if the client is enabled,
+// disabled, or default behavior.
+type ClientEnableState = internalconfig.ClientEnableState
+
+// Enumeration values for ClientEnableState
+const (
+ ClientDefaultEnableState ClientEnableState = internalconfig.ClientDefaultEnableState // default behavior
+ ClientDisabled ClientEnableState = internalconfig.ClientDisabled // client disabled
+ ClientEnabled ClientEnableState = internalconfig.ClientEnabled // client enabled
+)
+
+// EndpointModeState is an enum configuration variable describing the client endpoint mode.
+// Not configurable directly, but used when using the NewFromConfig.
+type EndpointModeState = internalconfig.EndpointModeState
+
+// Enumeration values for EndpointModeState
+const (
+ EndpointModeStateUnset EndpointModeState = internalconfig.EndpointModeStateUnset
+ EndpointModeStateIPv4 EndpointModeState = internalconfig.EndpointModeStateIPv4
+ EndpointModeStateIPv6 EndpointModeState = internalconfig.EndpointModeStateIPv6
+)
+
+const (
+ disableClientEnvVar = "AWS_EC2_METADATA_DISABLED"
+
+ // Client endpoint options
+ endpointEnvVar = "AWS_EC2_METADATA_SERVICE_ENDPOINT"
+
+ defaultIPv4Endpoint = "http://169.254.169.254"
+ defaultIPv6Endpoint = "http://[fd00:ec2::254]"
+)
+
+// New returns an initialized Client based on the functional options. Provide
+// additional functional options to further configure the behavior of the client,
+// such as changing the client's endpoint or adding custom middleware behavior.
+func New(options Options, optFns ...func(*Options)) *Client {
+ options = options.Copy()
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ options.HTTPClient = resolveHTTPClient(options.HTTPClient)
+
+ if options.Retryer == nil {
+ options.Retryer = retry.NewStandard()
+ }
+ options.Retryer = retry.AddWithMaxBackoffDelay(options.Retryer, 1*time.Second)
+
+ if options.ClientEnableState == ClientDefaultEnableState {
+ if v := os.Getenv(disableClientEnvVar); strings.EqualFold(v, "true") {
+ options.ClientEnableState = ClientDisabled
+ }
+ }
+
+ if len(options.Endpoint) == 0 {
+ if v := os.Getenv(endpointEnvVar); len(v) != 0 {
+ options.Endpoint = v
+ }
+ }
+
+ client := &Client{
+ options: options,
+ }
+
+ if client.options.tokenProvider == nil && !client.options.disableAPIToken {
+ client.options.tokenProvider = newTokenProvider(client, defaultTokenTTL)
+ }
+
+ return client
+}
+
+// NewFromConfig returns an initialized Client based the AWS SDK config, and
+// functional options. Provide additional functional options to further
+// configure the behavior of the client, such as changing the client's endpoint
+// or adding custom middleware behavior.
+func NewFromConfig(cfg aws.Config, optFns ...func(*Options)) *Client {
+ opts := Options{
+ APIOptions: append([]func(*middleware.Stack) error{}, cfg.APIOptions...),
+ HTTPClient: cfg.HTTPClient,
+ }
+
+ if cfg.Retryer != nil {
+ opts.Retryer = cfg.Retryer()
+ }
+
+ resolveClientEnableState(cfg, &opts)
+ resolveEndpointConfig(cfg, &opts)
+ resolveEndpointModeConfig(cfg, &opts)
+
+ return New(opts, optFns...)
+}
+
+// Options provides the fields for configuring the API client's behavior.
+type Options struct {
+ // Set of options to modify how an operation is invoked. These apply to all
+ // operations invoked for this client. Use functional options on operation
+ // call to modify this list for per operation behavior.
+ APIOptions []func(*middleware.Stack) error
+
+ // The endpoint the client will use to retrieve EC2 instance metadata.
+ //
+ // Specifies the EC2 Instance Metadata Service endpoint to use. If specified it overrides EndpointMode.
+ //
+ // If unset, and the environment variable AWS_EC2_METADATA_SERVICE_ENDPOINT
+ // has a value the client will use the value of the environment variable as
+ // the endpoint for operation calls.
+ //
+ // AWS_EC2_METADATA_SERVICE_ENDPOINT=http://[::1]
+ Endpoint string
+
+ // The endpoint selection mode the client will use if no explicit endpoint is provided using the Endpoint field.
+ //
+ // Setting EndpointMode to EndpointModeStateIPv4 will configure the client to use the default EC2 IPv4 endpoint.
+ // Setting EndpointMode to EndpointModeStateIPv6 will configure the client to use the default EC2 IPv6 endpoint.
+ //
+ // By default if EndpointMode is not set (EndpointModeStateUnset) than the default endpoint selection mode EndpointModeStateIPv4.
+ EndpointMode EndpointModeState
+
+ // The HTTP client to invoke API calls with. Defaults to client's default
+ // HTTP implementation if nil.
+ HTTPClient HTTPClient
+
+ // Retryer guides how HTTP requests should be retried in case of recoverable
+ // failures. When nil the API client will use a default retryer.
+ Retryer aws.Retryer
+
+ // Changes if the EC2 Instance Metadata client is enabled or not. Client
+ // will default to enabled if not set to ClientDisabled. When the client is
+ // disabled it will return an error for all operation calls.
+ //
+ // If ClientEnableState value is ClientDefaultEnableState (default value),
+ // and the environment variable "AWS_EC2_METADATA_DISABLED" is set to
+ // "true", the client will be disabled.
+ //
+ // AWS_EC2_METADATA_DISABLED=true
+ ClientEnableState ClientEnableState
+
+ // Configures the events that will be sent to the configured logger.
+ ClientLogMode aws.ClientLogMode
+
+ // The logger writer interface to write logging messages to.
+ Logger logging.Logger
+
+ // provides the caching of API tokens used for operation calls. If unset,
+ // the API token will not be retrieved for the operation.
+ tokenProvider *tokenProvider
+
+ // option to disable the API token provider for testing.
+ disableAPIToken bool
+}
+
+// HTTPClient provides the interface for a client making HTTP requests with the
+// API.
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// Copy creates a copy of the API options.
+func (o Options) Copy() Options {
+ to := o
+ to.APIOptions = append([]func(*middleware.Stack) error{}, o.APIOptions...)
+ return to
+}
+
+// WithAPIOptions wraps the API middleware functions, as a functional option
+// for the API Client Options. Use this helper to add additional functional
+// options to the API client, or operation calls.
+func WithAPIOptions(optFns ...func(*middleware.Stack) error) func(*Options) {
+ return func(o *Options) {
+ o.APIOptions = append(o.APIOptions, optFns...)
+ }
+}
+
+func (c *Client) invokeOperation(
+ ctx context.Context, opID string, params interface{}, optFns []func(*Options),
+ stackFns ...func(*middleware.Stack, Options) error,
+) (
+ result interface{}, metadata middleware.Metadata, err error,
+) {
+ stack := middleware.NewStack(opID, smithyhttp.NewStackRequest)
+ options := c.options.Copy()
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ if options.ClientEnableState == ClientDisabled {
+ return nil, metadata, &smithy.OperationError{
+ ServiceID: ServiceID,
+ OperationName: opID,
+ Err: fmt.Errorf(
+ "access disabled to EC2 IMDS via client option, or %q environment variable",
+ disableClientEnvVar),
+ }
+ }
+
+ for _, fn := range stackFns {
+ if err := fn(stack, options); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ for _, fn := range options.APIOptions {
+ if err := fn(stack); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ handler := middleware.DecorateHandler(smithyhttp.NewClientHandler(options.HTTPClient), stack)
+ result, metadata, err = handler.Handle(ctx, params)
+ if err != nil {
+ return nil, metadata, &smithy.OperationError{
+ ServiceID: ServiceID,
+ OperationName: opID,
+ Err: err,
+ }
+ }
+
+ return result, metadata, err
+}
+
+const (
+ // HTTP client constants
+ defaultDialerTimeout = 250 * time.Millisecond
+ defaultResponseHeaderTimeout = 500 * time.Millisecond
+)
+
+func resolveHTTPClient(client HTTPClient) HTTPClient {
+ if client == nil {
+ client = awshttp.NewBuildableClient()
+ }
+
+ if c, ok := client.(*awshttp.BuildableClient); ok {
+ client = c.
+ WithDialerOptions(func(d *net.Dialer) {
+ // Use a custom Dial timeout for the EC2 Metadata service to account
+ // for the possibility the application might not be running in an
+ // environment with the service present. The client should fail fast in
+ // this case.
+ d.Timeout = defaultDialerTimeout
+ }).
+ WithTransportOptions(func(tr *http.Transport) {
+ // Use a custom Transport timeout for the EC2 Metadata service to
+ // account for the possibility that the application might be running in
+ // a container, and EC2Metadata service drops the connection after a
+ // single IP Hop. The client should fail fast in this case.
+ tr.ResponseHeaderTimeout = defaultResponseHeaderTimeout
+ })
+ }
+
+ return client
+}
+
+func resolveClientEnableState(cfg aws.Config, options *Options) error {
+ if options.ClientEnableState != ClientDefaultEnableState {
+ return nil
+ }
+ value, found, err := internalconfig.ResolveClientEnableState(cfg.ConfigSources)
+ if err != nil || !found {
+ return err
+ }
+ options.ClientEnableState = value
+ return nil
+}
+
+func resolveEndpointModeConfig(cfg aws.Config, options *Options) error {
+ if options.EndpointMode != EndpointModeStateUnset {
+ return nil
+ }
+ value, found, err := internalconfig.ResolveEndpointModeConfig(cfg.ConfigSources)
+ if err != nil || !found {
+ return err
+ }
+ options.EndpointMode = value
+ return nil
+}
+
+func resolveEndpointConfig(cfg aws.Config, options *Options) error {
+ if len(options.Endpoint) != 0 {
+ return nil
+ }
+ value, found, err := internalconfig.ResolveEndpointConfig(cfg.ConfigSources)
+ if err != nil || !found {
+ return err
+ }
+ options.Endpoint = value
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetDynamicData.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetDynamicData.go
new file mode 100644
index 000000000000..9e3bdb0e66e2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetDynamicData.go
@@ -0,0 +1,76 @@
+package imds
+
+import (
+ "context"
+ "fmt"
+ "io"
+
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+const getDynamicDataPath = "/latest/dynamic"
+
+// GetDynamicData uses the path provided to request information from the EC2
+// instance metadata service for dynamic data. The content will be returned
+// as a string, or error if the request failed.
+func (c *Client) GetDynamicData(ctx context.Context, params *GetDynamicDataInput, optFns ...func(*Options)) (*GetDynamicDataOutput, error) {
+ if params == nil {
+ params = &GetDynamicDataInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetDynamicData", params, optFns,
+ addGetDynamicDataMiddleware,
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetDynamicDataOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+// GetDynamicDataInput provides the input parameters for the GetDynamicData
+// operation.
+type GetDynamicDataInput struct {
+ // The relative dynamic data path to retrieve. Can be empty string to
+ // retrieve a response containing a new line separated list of dynamic data
+ // resources available.
+ //
+ // Must not include the dynamic data base path.
+ //
+ // May include leading slash. If Path includes trailing slash the trailing
+ // slash will be included in the request for the resource.
+ Path string
+}
+
+// GetDynamicDataOutput provides the output parameters for the GetDynamicData
+// operation.
+type GetDynamicDataOutput struct {
+ Content io.ReadCloser
+
+ ResultMetadata middleware.Metadata
+}
+
+func addGetDynamicDataMiddleware(stack *middleware.Stack, options Options) error {
+ return addAPIRequestMiddleware(stack,
+ options,
+ buildGetDynamicDataPath,
+ buildGetDynamicDataOutput)
+}
+
+func buildGetDynamicDataPath(params interface{}) (string, error) {
+ p, ok := params.(*GetDynamicDataInput)
+ if !ok {
+ return "", fmt.Errorf("unknown parameter type %T", params)
+ }
+
+ return appendURIPath(getDynamicDataPath, p.Path), nil
+}
+
+func buildGetDynamicDataOutput(resp *smithyhttp.Response) (interface{}, error) {
+ return &GetDynamicDataOutput{
+ Content: resp.Body,
+ }, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetIAMInfo.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetIAMInfo.go
new file mode 100644
index 000000000000..24845dccd6d5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetIAMInfo.go
@@ -0,0 +1,102 @@
+package imds
+
+import (
+ "context"
+ "encoding/json"
+ "fmt"
+ "io"
+ "strings"
+ "time"
+
+ "github.com/aws/smithy-go"
+ smithyio "github.com/aws/smithy-go/io"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+const getIAMInfoPath = getMetadataPath + "/iam/info"
+
+// GetIAMInfo retrieves an identity document describing an
+// instance. Error is returned if the request fails or is unable to parse
+// the response.
+func (c *Client) GetIAMInfo(
+ ctx context.Context, params *GetIAMInfoInput, optFns ...func(*Options),
+) (
+ *GetIAMInfoOutput, error,
+) {
+ if params == nil {
+ params = &GetIAMInfoInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetIAMInfo", params, optFns,
+ addGetIAMInfoMiddleware,
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetIAMInfoOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+// GetIAMInfoInput provides the input parameters for GetIAMInfo operation.
+type GetIAMInfoInput struct{}
+
+// GetIAMInfoOutput provides the output parameters for GetIAMInfo operation.
+type GetIAMInfoOutput struct {
+ IAMInfo
+
+ ResultMetadata middleware.Metadata
+}
+
+func addGetIAMInfoMiddleware(stack *middleware.Stack, options Options) error {
+ return addAPIRequestMiddleware(stack,
+ options,
+ buildGetIAMInfoPath,
+ buildGetIAMInfoOutput,
+ )
+}
+
+func buildGetIAMInfoPath(params interface{}) (string, error) {
+ return getIAMInfoPath, nil
+}
+
+func buildGetIAMInfoOutput(resp *smithyhttp.Response) (v interface{}, err error) {
+ defer func() {
+ closeErr := resp.Body.Close()
+ if err == nil {
+ err = closeErr
+ } else if closeErr != nil {
+ err = fmt.Errorf("response body close error: %v, original error: %w", closeErr, err)
+ }
+ }()
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(resp.Body, ringBuffer)
+
+ imdsResult := &GetIAMInfoOutput{}
+ if err = json.NewDecoder(body).Decode(&imdsResult.IAMInfo); err != nil {
+ return nil, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode instance identity document, %w", err),
+ Snapshot: ringBuffer.Bytes(),
+ }
+ }
+ // Any code other success is an error
+ if !strings.EqualFold(imdsResult.Code, "success") {
+ return nil, fmt.Errorf("failed to get EC2 IMDS IAM info, %s",
+ imdsResult.Code)
+ }
+
+ return imdsResult, nil
+}
+
+// IAMInfo provides the shape for unmarshaling an IAM info from the metadata
+// API.
+type IAMInfo struct {
+ Code string
+ LastUpdated time.Time
+ InstanceProfileArn string
+ InstanceProfileID string
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetInstanceIdentityDocument.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetInstanceIdentityDocument.go
new file mode 100644
index 000000000000..a87758ed302d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetInstanceIdentityDocument.go
@@ -0,0 +1,109 @@
+package imds
+
+import (
+ "context"
+ "encoding/json"
+ "fmt"
+ "io"
+ "time"
+
+ "github.com/aws/smithy-go"
+ smithyio "github.com/aws/smithy-go/io"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+const getInstanceIdentityDocumentPath = getDynamicDataPath + "/instance-identity/document"
+
+// GetInstanceIdentityDocument retrieves an identity document describing an
+// instance. Error is returned if the request fails or is unable to parse
+// the response.
+func (c *Client) GetInstanceIdentityDocument(
+ ctx context.Context, params *GetInstanceIdentityDocumentInput, optFns ...func(*Options),
+) (
+ *GetInstanceIdentityDocumentOutput, error,
+) {
+ if params == nil {
+ params = &GetInstanceIdentityDocumentInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetInstanceIdentityDocument", params, optFns,
+ addGetInstanceIdentityDocumentMiddleware,
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetInstanceIdentityDocumentOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+// GetInstanceIdentityDocumentInput provides the input parameters for
+// GetInstanceIdentityDocument operation.
+type GetInstanceIdentityDocumentInput struct{}
+
+// GetInstanceIdentityDocumentOutput provides the output parameters for
+// GetInstanceIdentityDocument operation.
+type GetInstanceIdentityDocumentOutput struct {
+ InstanceIdentityDocument
+
+ ResultMetadata middleware.Metadata
+}
+
+func addGetInstanceIdentityDocumentMiddleware(stack *middleware.Stack, options Options) error {
+ return addAPIRequestMiddleware(stack,
+ options,
+ buildGetInstanceIdentityDocumentPath,
+ buildGetInstanceIdentityDocumentOutput,
+ )
+}
+
+func buildGetInstanceIdentityDocumentPath(params interface{}) (string, error) {
+ return getInstanceIdentityDocumentPath, nil
+}
+
+func buildGetInstanceIdentityDocumentOutput(resp *smithyhttp.Response) (v interface{}, err error) {
+ defer func() {
+ closeErr := resp.Body.Close()
+ if err == nil {
+ err = closeErr
+ } else if closeErr != nil {
+ err = fmt.Errorf("response body close error: %v, original error: %w", closeErr, err)
+ }
+ }()
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(resp.Body, ringBuffer)
+
+ output := &GetInstanceIdentityDocumentOutput{}
+ if err = json.NewDecoder(body).Decode(&output.InstanceIdentityDocument); err != nil {
+ return nil, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode instance identity document, %w", err),
+ Snapshot: ringBuffer.Bytes(),
+ }
+ }
+
+ return output, nil
+}
+
+// InstanceIdentityDocument provides the shape for unmarshaling
+// an instance identity document
+type InstanceIdentityDocument struct {
+ DevpayProductCodes []string `json:"devpayProductCodes"`
+ MarketplaceProductCodes []string `json:"marketplaceProductCodes"`
+ AvailabilityZone string `json:"availabilityZone"`
+ PrivateIP string `json:"privateIp"`
+ Version string `json:"version"`
+ Region string `json:"region"`
+ InstanceID string `json:"instanceId"`
+ BillingProducts []string `json:"billingProducts"`
+ InstanceType string `json:"instanceType"`
+ AccountID string `json:"accountId"`
+ PendingTime time.Time `json:"pendingTime"`
+ ImageID string `json:"imageId"`
+ KernelID string `json:"kernelId"`
+ RamdiskID string `json:"ramdiskId"`
+ Architecture string `json:"architecture"`
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetMetadata.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetMetadata.go
new file mode 100644
index 000000000000..cb0ce4c0004d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetMetadata.go
@@ -0,0 +1,76 @@
+package imds
+
+import (
+ "context"
+ "fmt"
+ "io"
+
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+const getMetadataPath = "/latest/meta-data"
+
+// GetMetadata uses the path provided to request information from the Amazon
+// EC2 Instance Metadata Service. The content will be returned as a string, or
+// error if the request failed.
+func (c *Client) GetMetadata(ctx context.Context, params *GetMetadataInput, optFns ...func(*Options)) (*GetMetadataOutput, error) {
+ if params == nil {
+ params = &GetMetadataInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetMetadata", params, optFns,
+ addGetMetadataMiddleware,
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetMetadataOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+// GetMetadataInput provides the input parameters for the GetMetadata
+// operation.
+type GetMetadataInput struct {
+ // The relative metadata path to retrieve. Can be empty string to retrieve
+ // a response containing a new line separated list of metadata resources
+ // available.
+ //
+ // Must not include the metadata base path.
+ //
+ // May include leading slash. If Path includes trailing slash the trailing slash
+ // will be included in the request for the resource.
+ Path string
+}
+
+// GetMetadataOutput provides the output parameters for the GetMetadata
+// operation.
+type GetMetadataOutput struct {
+ Content io.ReadCloser
+
+ ResultMetadata middleware.Metadata
+}
+
+func addGetMetadataMiddleware(stack *middleware.Stack, options Options) error {
+ return addAPIRequestMiddleware(stack,
+ options,
+ buildGetMetadataPath,
+ buildGetMetadataOutput)
+}
+
+func buildGetMetadataPath(params interface{}) (string, error) {
+ p, ok := params.(*GetMetadataInput)
+ if !ok {
+ return "", fmt.Errorf("unknown parameter type %T", params)
+ }
+
+ return appendURIPath(getMetadataPath, p.Path), nil
+}
+
+func buildGetMetadataOutput(resp *smithyhttp.Response) (interface{}, error) {
+ return &GetMetadataOutput{
+ Content: resp.Body,
+ }, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetRegion.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetRegion.go
new file mode 100644
index 000000000000..7b9b48912af3
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetRegion.go
@@ -0,0 +1,72 @@
+package imds
+
+import (
+ "context"
+ "fmt"
+
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// GetRegion retrieves an identity document describing an
+// instance. Error is returned if the request fails or is unable to parse
+// the response.
+func (c *Client) GetRegion(
+ ctx context.Context, params *GetRegionInput, optFns ...func(*Options),
+) (
+ *GetRegionOutput, error,
+) {
+ if params == nil {
+ params = &GetRegionInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetRegion", params, optFns,
+ addGetRegionMiddleware,
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetRegionOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+// GetRegionInput provides the input parameters for GetRegion operation.
+type GetRegionInput struct{}
+
+// GetRegionOutput provides the output parameters for GetRegion operation.
+type GetRegionOutput struct {
+ Region string
+
+ ResultMetadata middleware.Metadata
+}
+
+func addGetRegionMiddleware(stack *middleware.Stack, options Options) error {
+ return addAPIRequestMiddleware(stack,
+ options,
+ buildGetInstanceIdentityDocumentPath,
+ buildGetRegionOutput,
+ )
+}
+
+func buildGetRegionOutput(resp *smithyhttp.Response) (interface{}, error) {
+ out, err := buildGetInstanceIdentityDocumentOutput(resp)
+ if err != nil {
+ return nil, err
+ }
+
+ result, ok := out.(*GetInstanceIdentityDocumentOutput)
+ if !ok {
+ return nil, fmt.Errorf("unexpected instance identity document type, %T", out)
+ }
+
+ region := result.Region
+ if len(region) == 0 {
+ return "", fmt.Errorf("instance metadata did not return a region value")
+ }
+
+ return &GetRegionOutput{
+ Region: region,
+ }, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetToken.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetToken.go
new file mode 100644
index 000000000000..841f802c1a36
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetToken.go
@@ -0,0 +1,118 @@
+package imds
+
+import (
+ "context"
+ "fmt"
+ "io"
+ "strconv"
+ "strings"
+ "time"
+
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+const getTokenPath = "/latest/api/token"
+const tokenTTLHeader = "X-Aws-Ec2-Metadata-Token-Ttl-Seconds"
+
+// getToken uses the duration to return a token for EC2 IMDS, or an error if
+// the request failed.
+func (c *Client) getToken(ctx context.Context, params *getTokenInput, optFns ...func(*Options)) (*getTokenOutput, error) {
+ if params == nil {
+ params = &getTokenInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "getToken", params, optFns,
+ addGetTokenMiddleware,
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*getTokenOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type getTokenInput struct {
+ TokenTTL time.Duration
+}
+
+type getTokenOutput struct {
+ Token string
+ TokenTTL time.Duration
+
+ ResultMetadata middleware.Metadata
+}
+
+func addGetTokenMiddleware(stack *middleware.Stack, options Options) error {
+ err := addRequestMiddleware(stack,
+ options,
+ "PUT",
+ buildGetTokenPath,
+ buildGetTokenOutput)
+ if err != nil {
+ return err
+ }
+
+ err = stack.Serialize.Add(&tokenTTLRequestHeader{}, middleware.After)
+ if err != nil {
+ return err
+ }
+
+ return nil
+}
+
+func buildGetTokenPath(interface{}) (string, error) {
+ return getTokenPath, nil
+}
+
+func buildGetTokenOutput(resp *smithyhttp.Response) (v interface{}, err error) {
+ defer func() {
+ closeErr := resp.Body.Close()
+ if err == nil {
+ err = closeErr
+ } else if closeErr != nil {
+ err = fmt.Errorf("response body close error: %v, original error: %w", closeErr, err)
+ }
+ }()
+
+ ttlHeader := resp.Header.Get(tokenTTLHeader)
+ tokenTTL, err := strconv.ParseInt(ttlHeader, 10, 64)
+ if err != nil {
+ return nil, fmt.Errorf("unable to parse API token, %w", err)
+ }
+
+ var token strings.Builder
+ if _, err = io.Copy(&token, resp.Body); err != nil {
+ return nil, fmt.Errorf("unable to read API token, %w", err)
+ }
+
+ return &getTokenOutput{
+ Token: token.String(),
+ TokenTTL: time.Duration(tokenTTL) * time.Second,
+ }, nil
+}
+
+type tokenTTLRequestHeader struct{}
+
+func (*tokenTTLRequestHeader) ID() string { return "tokenTTLRequestHeader" }
+func (*tokenTTLRequestHeader) HandleSerialize(
+ ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler,
+) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("expect HTTP transport, got %T", in.Request)
+ }
+
+ input, ok := in.Parameters.(*getTokenInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("expect getTokenInput, got %T", in.Parameters)
+ }
+
+ req.Header.Set(tokenTTLHeader, strconv.Itoa(int(input.TokenTTL/time.Second)))
+
+ return next.HandleSerialize(ctx, in)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetUserData.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetUserData.go
new file mode 100644
index 000000000000..88aa61e9ad95
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/api_op_GetUserData.go
@@ -0,0 +1,60 @@
+package imds
+
+import (
+ "context"
+ "io"
+
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+const getUserDataPath = "/latest/user-data"
+
+// GetUserData uses the path provided to request information from the EC2
+// instance metadata service for dynamic data. The content will be returned
+// as a string, or error if the request failed.
+func (c *Client) GetUserData(ctx context.Context, params *GetUserDataInput, optFns ...func(*Options)) (*GetUserDataOutput, error) {
+ if params == nil {
+ params = &GetUserDataInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetUserData", params, optFns,
+ addGetUserDataMiddleware,
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetUserDataOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+// GetUserDataInput provides the input parameters for the GetUserData
+// operation.
+type GetUserDataInput struct{}
+
+// GetUserDataOutput provides the output parameters for the GetUserData
+// operation.
+type GetUserDataOutput struct {
+ Content io.ReadCloser
+
+ ResultMetadata middleware.Metadata
+}
+
+func addGetUserDataMiddleware(stack *middleware.Stack, options Options) error {
+ return addAPIRequestMiddleware(stack,
+ options,
+ buildGetUserDataPath,
+ buildGetUserDataOutput)
+}
+
+func buildGetUserDataPath(params interface{}) (string, error) {
+ return getUserDataPath, nil
+}
+
+func buildGetUserDataOutput(resp *smithyhttp.Response) (interface{}, error) {
+ return &GetUserDataOutput{
+ Content: resp.Body,
+ }, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/doc.go
new file mode 100644
index 000000000000..bacdb5d21f26
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/doc.go
@@ -0,0 +1,11 @@
+// Package imds provides the API client for interacting with the Amazon EC2
+// Instance Metadata Service.
+//
+// All Client operation calls have a default timeout. If the operation is not
+// completed before this timeout expires, the operation will be canceled. This
+// timeout can be overridden by providing Context with a timeout or deadline
+// with calling the client's operations.
+//
+// See the EC2 IMDS user guide for more information on using the API.
+// https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-metadata.html
+package imds
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go.mod
new file mode 100644
index 000000000000..e21c587f3beb
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go.mod
@@ -0,0 +1,11 @@
+module github.com/aws/aws-sdk-go-v2/feature/ec2/imds
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/smithy-go v1.9.1
+ github.com/google/go-cmp v0.5.6
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../../../
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go_module_metadata.go
new file mode 100644
index 000000000000..46399cc8bbf3
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package imds
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.9.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/internal/config/resolvers.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/internal/config/resolvers.go
new file mode 100644
index 000000000000..d72fcb5626f6
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/internal/config/resolvers.go
@@ -0,0 +1,98 @@
+package config
+
+import (
+ "fmt"
+ "strings"
+)
+
+// ClientEnableState provides an enumeration if the client is enabled,
+// disabled, or default behavior.
+type ClientEnableState uint
+
+// Enumeration values for ClientEnableState
+const (
+ ClientDefaultEnableState ClientEnableState = iota
+ ClientDisabled
+ ClientEnabled
+)
+
+// EndpointModeState is the EC2 IMDS Endpoint Configuration Mode
+type EndpointModeState uint
+
+// Enumeration values for ClientEnableState
+const (
+ EndpointModeStateUnset EndpointModeState = iota
+ EndpointModeStateIPv4
+ EndpointModeStateIPv6
+)
+
+// SetFromString sets the EndpointModeState based on the provided string value. Unknown values will default to EndpointModeStateUnset
+func (e *EndpointModeState) SetFromString(v string) error {
+ v = strings.TrimSpace(v)
+
+ switch {
+ case len(v) == 0:
+ *e = EndpointModeStateUnset
+ case strings.EqualFold(v, "IPv6"):
+ *e = EndpointModeStateIPv6
+ case strings.EqualFold(v, "IPv4"):
+ *e = EndpointModeStateIPv4
+ default:
+ return fmt.Errorf("unknown EC2 IMDS endpoint mode, must be either IPv6 or IPv4")
+ }
+ return nil
+}
+
+// ClientEnableStateResolver is a config resolver interface for retrieving whether the IMDS client is disabled.
+type ClientEnableStateResolver interface {
+ GetEC2IMDSClientEnableState() (ClientEnableState, bool, error)
+}
+
+// EndpointModeResolver is a config resolver interface for retrieving the EndpointModeState configuration.
+type EndpointModeResolver interface {
+ GetEC2IMDSEndpointMode() (EndpointModeState, bool, error)
+}
+
+// EndpointResolver is a config resolver interface for retrieving the endpoint.
+type EndpointResolver interface {
+ GetEC2IMDSEndpoint() (string, bool, error)
+}
+
+// ResolveClientEnableState resolves the ClientEnableState from a list of configuration sources.
+func ResolveClientEnableState(sources []interface{}) (value ClientEnableState, found bool, err error) {
+ for _, source := range sources {
+ if resolver, ok := source.(ClientEnableStateResolver); ok {
+ value, found, err = resolver.GetEC2IMDSClientEnableState()
+ if err != nil || found {
+ return value, found, err
+ }
+ }
+ }
+ return value, found, err
+}
+
+// ResolveEndpointModeConfig resolves the EndpointModeState from a list of configuration sources.
+func ResolveEndpointModeConfig(sources []interface{}) (value EndpointModeState, found bool, err error) {
+ for _, source := range sources {
+ if resolver, ok := source.(EndpointModeResolver); ok {
+ value, found, err = resolver.GetEC2IMDSEndpointMode()
+ if err != nil || found {
+ return value, found, err
+ }
+ }
+ }
+ return value, found, err
+}
+
+// ResolveEndpointConfig resolves the endpoint from a list of configuration sources.
+func ResolveEndpointConfig(sources []interface{}) (value string, found bool, err error) {
+ for _, source := range sources {
+ if resolver, ok := source.(EndpointResolver); ok {
+ value, found, err = resolver.GetEC2IMDSEndpoint()
+ if err != nil || found {
+ return value, found, err
+ }
+ }
+ }
+ return value, found, err
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/request_middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/request_middleware.go
new file mode 100644
index 000000000000..605cbd13140f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/request_middleware.go
@@ -0,0 +1,266 @@
+package imds
+
+import (
+ "bytes"
+ "context"
+ "fmt"
+ "io/ioutil"
+ "net/url"
+ "path"
+ "time"
+
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/retry"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+func addAPIRequestMiddleware(stack *middleware.Stack,
+ options Options,
+ getPath func(interface{}) (string, error),
+ getOutput func(*smithyhttp.Response) (interface{}, error),
+) (err error) {
+ err = addRequestMiddleware(stack, options, "GET", getPath, getOutput)
+ if err != nil {
+ return err
+ }
+
+ // Token Serializer build and state management.
+ if !options.disableAPIToken {
+ err = stack.Finalize.Insert(options.tokenProvider, (*retry.Attempt)(nil).ID(), middleware.After)
+ if err != nil {
+ return err
+ }
+
+ err = stack.Deserialize.Insert(options.tokenProvider, "OperationDeserializer", middleware.Before)
+ if err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func addRequestMiddleware(stack *middleware.Stack,
+ options Options,
+ method string,
+ getPath func(interface{}) (string, error),
+ getOutput func(*smithyhttp.Response) (interface{}, error),
+) (err error) {
+ err = awsmiddleware.AddSDKAgentKey(awsmiddleware.FeatureMetadata, "ec2-imds")(stack)
+ if err != nil {
+ return err
+ }
+
+ // Operation timeout
+ err = stack.Initialize.Add(&operationTimeout{
+ DefaultTimeout: defaultOperationTimeout,
+ }, middleware.Before)
+ if err != nil {
+ return err
+ }
+
+ // Operation Serializer
+ err = stack.Serialize.Add(&serializeRequest{
+ GetPath: getPath,
+ Method: method,
+ }, middleware.After)
+ if err != nil {
+ return err
+ }
+
+ // Operation endpoint resolver
+ err = stack.Serialize.Insert(&resolveEndpoint{
+ Endpoint: options.Endpoint,
+ EndpointMode: options.EndpointMode,
+ }, "OperationSerializer", middleware.Before)
+ if err != nil {
+ return err
+ }
+
+ // Operation Deserializer
+ err = stack.Deserialize.Add(&deserializeResponse{
+ GetOutput: getOutput,
+ }, middleware.After)
+ if err != nil {
+ return err
+ }
+
+ // Retry support
+ return retry.AddRetryMiddlewares(stack, retry.AddRetryMiddlewaresOptions{
+ Retryer: options.Retryer,
+ LogRetryAttempts: options.ClientLogMode.IsRetries(),
+ })
+}
+
+type serializeRequest struct {
+ GetPath func(interface{}) (string, error)
+ Method string
+}
+
+func (*serializeRequest) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *serializeRequest) HandleSerialize(
+ ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler,
+) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in.Request)
+ }
+
+ reqPath, err := m.GetPath(in.Parameters)
+ if err != nil {
+ return out, metadata, fmt.Errorf("unable to get request URL path, %w", err)
+ }
+
+ request.Request.URL.Path = reqPath
+ request.Request.Method = m.Method
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type deserializeResponse struct {
+ GetOutput func(*smithyhttp.Response) (interface{}, error)
+}
+
+func (*deserializeResponse) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *deserializeResponse) HandleDeserialize(
+ ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler,
+) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ resp, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, fmt.Errorf(
+ "unexpected transport response type, %T, want %T", out.RawResponse, resp)
+ }
+ defer resp.Body.Close()
+
+ // read the full body so that any operation timeouts cleanup will not race
+ // the body being read.
+ body, err := ioutil.ReadAll(resp.Body)
+ if err != nil {
+ return out, metadata, fmt.Errorf("read response body failed, %w", err)
+ }
+ resp.Body = ioutil.NopCloser(bytes.NewReader(body))
+
+ // Anything that's not 200 |< 300 is error
+ if resp.StatusCode < 200 || resp.StatusCode >= 300 {
+ return out, metadata, &smithyhttp.ResponseError{
+ Response: resp,
+ Err: fmt.Errorf("request to EC2 IMDS failed"),
+ }
+ }
+
+ result, err := m.GetOutput(resp)
+ if err != nil {
+ return out, metadata, fmt.Errorf(
+ "unable to get deserialized result for response, %w", err,
+ )
+ }
+ out.Result = result
+
+ return out, metadata, err
+}
+
+type resolveEndpoint struct {
+ Endpoint string
+ EndpointMode EndpointModeState
+}
+
+func (*resolveEndpoint) ID() string {
+ return "ResolveEndpoint"
+}
+
+func (m *resolveEndpoint) HandleSerialize(
+ ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler,
+) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in.Request)
+ }
+
+ var endpoint string
+ if len(m.Endpoint) > 0 {
+ endpoint = m.Endpoint
+ } else {
+ switch m.EndpointMode {
+ case EndpointModeStateIPv6:
+ endpoint = defaultIPv6Endpoint
+ case EndpointModeStateIPv4:
+ fallthrough
+ case EndpointModeStateUnset:
+ endpoint = defaultIPv4Endpoint
+ default:
+ return out, metadata, fmt.Errorf("unsupported IMDS endpoint mode")
+ }
+ }
+
+ req.URL, err = url.Parse(endpoint)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to parse endpoint URL: %w", err)
+ }
+
+ return next.HandleSerialize(ctx, in)
+}
+
+const (
+ defaultOperationTimeout = 5 * time.Second
+)
+
+// operationTimeout adds a timeout on the middleware stack if the Context the
+// stack was called with does not have a deadline. The next middleware must
+// complete before the timeout, or the context will be canceled.
+//
+// If DefaultTimeout is zero, no default timeout will be used if the Context
+// does not have a timeout.
+//
+// The next middleware must also ensure that any resources that are also
+// canceled by the stack's context are completely consumed before returning.
+// Otherwise the timeout cleanup will race the resource being consumed
+// upstream.
+type operationTimeout struct {
+ DefaultTimeout time.Duration
+}
+
+func (*operationTimeout) ID() string { return "OperationTimeout" }
+
+func (m *operationTimeout) HandleInitialize(
+ ctx context.Context, input middleware.InitializeInput, next middleware.InitializeHandler,
+) (
+ output middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ if _, ok := ctx.Deadline(); !ok && m.DefaultTimeout != 0 {
+ var cancelFn func()
+ ctx, cancelFn = context.WithTimeout(ctx, m.DefaultTimeout)
+ defer cancelFn()
+ }
+
+ return next.HandleInitialize(ctx, input)
+}
+
+// appendURIPath joins a URI path component to the existing path with `/`
+// separators between the path components. If the path being added ends with a
+// trailing `/` that slash will be maintained.
+func appendURIPath(base, add string) string {
+ reqPath := path.Join(base, add)
+ if len(add) != 0 && add[len(add)-1] == '/' {
+ reqPath += "/"
+ }
+ return reqPath
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/token_provider.go b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/token_provider.go
new file mode 100644
index 000000000000..275fade488a1
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/feature/ec2/imds/token_provider.go
@@ -0,0 +1,237 @@
+package imds
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "net/http"
+ "sync"
+ "sync/atomic"
+ "time"
+
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+const (
+ // Headers for Token and TTL
+ tokenHeader = "x-aws-ec2-metadata-token"
+ defaultTokenTTL = 5 * time.Minute
+)
+
+type tokenProvider struct {
+ client *Client
+ tokenTTL time.Duration
+
+ token *apiToken
+ tokenMux sync.RWMutex
+
+ disabled uint32 // Atomic updated
+}
+
+func newTokenProvider(client *Client, ttl time.Duration) *tokenProvider {
+ return &tokenProvider{
+ client: client,
+ tokenTTL: ttl,
+ }
+}
+
+// apiToken provides the API token used by all operation calls for th EC2
+// Instance metadata service.
+type apiToken struct {
+ token string
+ expires time.Time
+}
+
+var timeNow = time.Now
+
+// Expired returns if the token is expired.
+func (t *apiToken) Expired() bool {
+ // Calling Round(0) on the current time will truncate the monotonic reading only. Ensures credential expiry
+ // time is always based on reported wall-clock time.
+ return timeNow().Round(0).After(t.expires)
+}
+
+func (t *tokenProvider) ID() string { return "APITokenProvider" }
+
+// HandleFinalize is the finalize stack middleware, that if the token provider is
+// enabled, will attempt to add the cached API token to the request. If the API
+// token is not cached, it will be retrieved in a separate API call, getToken.
+//
+// For retry attempts, handler must be added after attempt retryer.
+//
+// If request for getToken fails the token provider may be disabled from future
+// requests, depending on the response status code.
+func (t *tokenProvider) HandleFinalize(
+ ctx context.Context, input middleware.FinalizeInput, next middleware.FinalizeHandler,
+) (
+ out middleware.FinalizeOutput, metadata middleware.Metadata, err error,
+) {
+ if !t.enabled() {
+ // short-circuits to insecure data flow if token provider is disabled.
+ return next.HandleFinalize(ctx, input)
+ }
+
+ req, ok := input.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unexpected transport request type %T", input.Request)
+ }
+
+ tok, err := t.getToken(ctx)
+ if err != nil {
+ // If the error allows the token to downgrade to insecure flow allow that.
+ var bypassErr *bypassTokenRetrievalError
+ if errors.As(err, &bypassErr) {
+ return next.HandleFinalize(ctx, input)
+ }
+
+ return out, metadata, fmt.Errorf("failed to get API token, %w", err)
+ }
+
+ req.Header.Set(tokenHeader, tok.token)
+
+ return next.HandleFinalize(ctx, input)
+}
+
+// HandleDeserialize is the deserialize stack middleware for determining if the
+// operation the token provider is decorating failed because of a 401
+// unauthorized status code. If the operation failed for that reason the token
+// provider needs to be re-enabled so that it can start adding the API token to
+// operation calls.
+func (t *tokenProvider) HandleDeserialize(
+ ctx context.Context, input middleware.DeserializeInput, next middleware.DeserializeHandler,
+) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, input)
+ if err == nil {
+ return out, metadata, err
+ }
+
+ resp, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, fmt.Errorf("expect HTTP transport, got %T", out.RawResponse)
+ }
+
+ if resp.StatusCode == http.StatusUnauthorized { // unauthorized
+ err = &retryableError{Err: err}
+ t.enable()
+ }
+
+ return out, metadata, err
+}
+
+type retryableError struct {
+ Err error
+}
+
+func (*retryableError) RetryableError() bool { return true }
+
+func (e *retryableError) Error() string { return e.Err.Error() }
+
+func (t *tokenProvider) getToken(ctx context.Context) (tok *apiToken, err error) {
+ if !t.enabled() {
+ return nil, &bypassTokenRetrievalError{
+ Err: fmt.Errorf("cannot get API token, provider disabled"),
+ }
+ }
+
+ t.tokenMux.RLock()
+ tok = t.token
+ t.tokenMux.RUnlock()
+
+ if tok != nil && !tok.Expired() {
+ return tok, nil
+ }
+
+ tok, err = t.updateToken(ctx)
+ if err != nil {
+ return nil, fmt.Errorf("cannot get API token, %w", err)
+ }
+
+ return tok, nil
+}
+
+func (t *tokenProvider) updateToken(ctx context.Context) (*apiToken, error) {
+ t.tokenMux.Lock()
+ defer t.tokenMux.Unlock()
+
+ // Prevent multiple requests to update retrieving the token.
+ if t.token != nil && !t.token.Expired() {
+ tok := t.token
+ return tok, nil
+ }
+
+ result, err := t.client.getToken(ctx, &getTokenInput{
+ TokenTTL: t.tokenTTL,
+ })
+ if err != nil {
+ // change the disabled flag on token provider to true, when error is request timeout error.
+ var statusErr interface{ HTTPStatusCode() int }
+ if errors.As(err, &statusErr) {
+ switch statusErr.HTTPStatusCode() {
+
+ // Disable get token if failed because of 403, 404, or 405
+ case http.StatusForbidden,
+ http.StatusNotFound,
+ http.StatusMethodNotAllowed:
+
+ t.disable()
+
+ // 400 errors are terminal, and need to be upstreamed
+ case http.StatusBadRequest:
+ return nil, err
+ }
+ }
+
+ // Disable if request send failed or timed out getting response
+ var re *smithyhttp.RequestSendError
+ var ce *smithy.CanceledError
+ if errors.As(err, &re) || errors.As(err, &ce) {
+ atomic.StoreUint32(&t.disabled, 1)
+ }
+
+ // Token couldn't be retrieved, but bypass this, and allow the
+ // request to continue.
+ return nil, &bypassTokenRetrievalError{Err: err}
+ }
+
+ tok := &apiToken{
+ token: result.Token,
+ expires: timeNow().Add(result.TokenTTL),
+ }
+ t.token = tok
+
+ return tok, nil
+}
+
+type bypassTokenRetrievalError struct {
+ Err error
+}
+
+func (e *bypassTokenRetrievalError) Error() string {
+ return fmt.Sprintf("bypass token retrieval, %v", e.Err)
+}
+
+func (e *bypassTokenRetrievalError) Unwrap() error { return e.Err }
+
+// enabled returns if the token provider is current enabled or not.
+func (t *tokenProvider) enabled() bool {
+ return atomic.LoadUint32(&t.disabled) == 0
+}
+
+// disable disables the token provider and it will no longer attempt to inject
+// the token, nor request updates.
+func (t *tokenProvider) disable() {
+ atomic.StoreUint32(&t.disabled, 1)
+}
+
+// enable enables the token provide to start refreshing tokens, and adding them
+// to the pending request.
+func (t *tokenProvider) enable() {
+ t.tokenMux.Lock()
+ t.token = nil
+ t.tokenMux.Unlock()
+ atomic.StoreUint32(&t.disabled, 0)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/go.mod
new file mode 100644
index 000000000000..7aa19e456abc
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/go.mod
@@ -0,0 +1,9 @@
+module github.com/aws/aws-sdk-go-v2
+
+require (
+ github.com/aws/smithy-go v1.9.1
+ github.com/google/go-cmp v0.5.6
+ github.com/jmespath/go-jmespath v0.4.0
+)
+
+go 1.15
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/go.sum
new file mode 100644
index 000000000000..ce121d1d3182
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/go.sum
@@ -0,0 +1,20 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8 h1:obN1ZagJSUGI0Ek/LBmuj4SNLPfIny3KsKFopxRdj10=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/CHANGELOG.md
new file mode 100644
index 000000000000..724344fa6026
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/CHANGELOG.md
@@ -0,0 +1,50 @@
+# v1.1.3 (2022-01-07)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.2 (2021-12-02)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.0 (2021-11-06)
+
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.7 (2021-10-21)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.6 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.5 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.4 (2021-08-27)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.3 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.2 (2021-08-04)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.1 (2021-07-15)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.0 (2021-06-25)
+
+* **Release**: Release new modules
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/config.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/config.go
new file mode 100644
index 000000000000..cd4d19b89821
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/config.go
@@ -0,0 +1,65 @@
+package configsources
+
+import (
+ "context"
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+// EnableEndpointDiscoveryProvider is an interface for retrieving external configuration value
+// for Enable Endpoint Discovery
+type EnableEndpointDiscoveryProvider interface {
+ GetEnableEndpointDiscovery(ctx context.Context) (value aws.EndpointDiscoveryEnableState, found bool, err error)
+}
+
+// ResolveEnableEndpointDiscovery extracts the first instance of a EnableEndpointDiscoveryProvider from the config slice.
+// Additionally returns a aws.EndpointDiscoveryEnableState to indicate if the value was found in provided configs,
+// and error if one is encountered.
+func ResolveEnableEndpointDiscovery(ctx context.Context, configs []interface{}) (value aws.EndpointDiscoveryEnableState, found bool, err error) {
+ for _, cfg := range configs {
+ if p, ok := cfg.(EnableEndpointDiscoveryProvider); ok {
+ value, found, err = p.GetEnableEndpointDiscovery(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// UseDualStackEndpointProvider is an interface for retrieving external configuration values for UseDualStackEndpoint
+type UseDualStackEndpointProvider interface {
+ GetUseDualStackEndpoint(context.Context) (value aws.DualStackEndpointState, found bool, err error)
+}
+
+// ResolveUseDualStackEndpoint extracts the first instance of a UseDualStackEndpoint from the config slice.
+// Additionally returns a boolean to indicate if the value was found in provided configs, and error if one is encountered.
+func ResolveUseDualStackEndpoint(ctx context.Context, configs []interface{}) (value aws.DualStackEndpointState, found bool, err error) {
+ for _, cfg := range configs {
+ if p, ok := cfg.(UseDualStackEndpointProvider); ok {
+ value, found, err = p.GetUseDualStackEndpoint(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
+
+// UseFIPSEndpointProvider is an interface for retrieving external configuration values for UseFIPSEndpoint
+type UseFIPSEndpointProvider interface {
+ GetUseFIPSEndpoint(context.Context) (value aws.FIPSEndpointState, found bool, err error)
+}
+
+// ResolveUseFIPSEndpoint extracts the first instance of a UseFIPSEndpointProvider from the config slice.
+// Additionally, returns a boolean to indicate if the value was found in provided configs, and error if one is encountered.
+func ResolveUseFIPSEndpoint(ctx context.Context, configs []interface{}) (value aws.FIPSEndpointState, found bool, err error) {
+ for _, cfg := range configs {
+ if p, ok := cfg.(UseFIPSEndpointProvider); ok {
+ value, found, err = p.GetUseFIPSEndpoint(ctx)
+ if err != nil || found {
+ break
+ }
+ }
+ }
+ return
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go.mod
new file mode 100644
index 000000000000..2889b4dd1015
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go.mod
@@ -0,0 +1,7 @@
+module github.com/aws/aws-sdk-go-v2/internal/configsources
+
+go 1.15
+
+require github.com/aws/aws-sdk-go-v2 v1.12.0
+
+replace github.com/aws/aws-sdk-go-v2 => ../../
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go_module_metadata.go
new file mode 100644
index 000000000000..89d773f7f8f7
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/configsources/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package configsources
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.1.3"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/CHANGELOG.md
new file mode 100644
index 000000000000..c15bf127c6b6
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/CHANGELOG.md
@@ -0,0 +1,20 @@
+# v2.1.0 (2022-01-07)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v2.0.2 (2021-12-02)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v2.0.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v2.0.0 (2021-11-06)
+
+* **Release**: Endpoint Variant Model Support
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/endpoints.go
new file mode 100644
index 000000000000..32251a7e3cc1
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/endpoints.go
@@ -0,0 +1,302 @@
+package endpoints
+
+import (
+ "fmt"
+ "github.com/aws/smithy-go/logging"
+ "regexp"
+ "strings"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+)
+
+// DefaultKey is a compound map key of a variant and other values.
+type DefaultKey struct {
+ Variant EndpointVariant
+ ServiceVariant ServiceVariant
+}
+
+// EndpointKey is a compound map key of a region and associated variant value.
+type EndpointKey struct {
+ Region string
+ Variant EndpointVariant
+ ServiceVariant ServiceVariant
+}
+
+// EndpointVariant is a bit field to describe the endpoints attributes.
+type EndpointVariant uint64
+
+const (
+ // FIPSVariant indicates that the endpoint is FIPS capable.
+ FIPSVariant EndpointVariant = 1 << (64 - 1 - iota)
+
+ // DualStackVariant indicates that the endpoint is DualStack capable.
+ DualStackVariant
+)
+
+// ServiceVariant is a bit field to describe the service endpoint attributes.
+type ServiceVariant uint64
+
+const (
+ defaultProtocol = "https"
+ defaultSigner = "v4"
+)
+
+var (
+ protocolPriority = []string{"https", "http"}
+ signerPriority = []string{"v4", "s3v4"}
+)
+
+// Options provide configuration needed to direct how endpoints are resolved.
+type Options struct {
+ // Logger is a logging implementation that log events should be sent to.
+ Logger logging.Logger
+
+ // LogDeprecated indicates that deprecated endpoints should be logged to the provided logger.
+ LogDeprecated bool
+
+ // ResolvedRegion is the resolved region string. If provided (non-zero length) it takes priority
+ // over the region name passed to the ResolveEndpoint call.
+ ResolvedRegion string
+
+ // Disable usage of HTTPS (TLS / SSL)
+ DisableHTTPS bool
+
+ // Instruct the resolver to use a service endpoint that supports dual-stack.
+ // If a service does not have a dual-stack endpoint an error will be returned by the resolver.
+ UseDualStackEndpoint aws.DualStackEndpointState
+
+ // Instruct the resolver to use a service endpoint that supports FIPS.
+ // If a service does not have a FIPS endpoint an error will be returned by the resolver.
+ UseFIPSEndpoint aws.FIPSEndpointState
+
+ // ServiceVariant is a bitfield of service specified endpoint variant data.
+ ServiceVariant ServiceVariant
+}
+
+// GetEndpointVariant returns the EndpointVariant for the variant associated options.
+func (o Options) GetEndpointVariant() (v EndpointVariant) {
+ if o.UseDualStackEndpoint == aws.DualStackEndpointStateEnabled {
+ v |= DualStackVariant
+ }
+ if o.UseFIPSEndpoint == aws.FIPSEndpointStateEnabled {
+ v |= FIPSVariant
+ }
+ return v
+}
+
+// Partitions is a slice of partition
+type Partitions []Partition
+
+// ResolveEndpoint resolves a service endpoint for the given region and options.
+func (ps Partitions) ResolveEndpoint(region string, opts Options) (aws.Endpoint, error) {
+ if len(ps) == 0 {
+ return aws.Endpoint{}, fmt.Errorf("no partitions found")
+ }
+
+ if opts.Logger == nil {
+ opts.Logger = logging.Nop{}
+ }
+
+ if len(opts.ResolvedRegion) > 0 {
+ region = opts.ResolvedRegion
+ }
+
+ for i := 0; i < len(ps); i++ {
+ if !ps[i].canResolveEndpoint(region, opts) {
+ continue
+ }
+
+ return ps[i].ResolveEndpoint(region, opts)
+ }
+
+ // fallback to first partition format to use when resolving the endpoint.
+ return ps[0].ResolveEndpoint(region, opts)
+}
+
+// Partition is an AWS partition description for a service and its' region endpoints.
+type Partition struct {
+ ID string
+ RegionRegex *regexp.Regexp
+ PartitionEndpoint string
+ IsRegionalized bool
+ Defaults map[DefaultKey]Endpoint
+ Endpoints Endpoints
+}
+
+func (p Partition) canResolveEndpoint(region string, opts Options) bool {
+ _, ok := p.Endpoints[EndpointKey{
+ Region: region,
+ Variant: opts.GetEndpointVariant(),
+ }]
+ return ok || p.RegionRegex.MatchString(region)
+}
+
+// ResolveEndpoint resolves and service endpoint for the given region and options.
+func (p Partition) ResolveEndpoint(region string, options Options) (resolved aws.Endpoint, err error) {
+ if len(region) == 0 && len(p.PartitionEndpoint) != 0 {
+ region = p.PartitionEndpoint
+ }
+
+ endpoints := p.Endpoints
+
+ variant := options.GetEndpointVariant()
+ serviceVariant := options.ServiceVariant
+
+ defaults := p.Defaults[DefaultKey{
+ Variant: variant,
+ ServiceVariant: serviceVariant,
+ }]
+
+ return p.endpointForRegion(region, variant, serviceVariant, endpoints).resolve(p.ID, region, defaults, options)
+}
+
+func (p Partition) endpointForRegion(region string, variant EndpointVariant, serviceVariant ServiceVariant, endpoints Endpoints) Endpoint {
+ key := EndpointKey{
+ Region: region,
+ Variant: variant,
+ }
+
+ if e, ok := endpoints[key]; ok {
+ return e
+ }
+
+ if !p.IsRegionalized {
+ return endpoints[EndpointKey{
+ Region: p.PartitionEndpoint,
+ Variant: variant,
+ ServiceVariant: serviceVariant,
+ }]
+ }
+
+ // Unable to find any matching endpoint, return
+ // blank that will be used for generic endpoint creation.
+ return Endpoint{}
+}
+
+// Endpoints is a map of service config regions to endpoints
+type Endpoints map[EndpointKey]Endpoint
+
+// CredentialScope is the credential scope of a region and service
+type CredentialScope struct {
+ Region string
+ Service string
+}
+
+// Endpoint is a service endpoint description
+type Endpoint struct {
+ // True if the endpoint cannot be resolved for this partition/region/service
+ Unresolveable aws.Ternary
+
+ Hostname string
+ Protocols []string
+
+ CredentialScope CredentialScope
+
+ SignatureVersions []string
+
+ // Indicates that this endpoint is deprecated.
+ Deprecated aws.Ternary
+}
+
+// IsZero returns whether the endpoint structure is an empty (zero) value.
+func (e Endpoint) IsZero() bool {
+ switch {
+ case e.Unresolveable != aws.UnknownTernary:
+ return false
+ case len(e.Hostname) != 0:
+ return false
+ case len(e.Protocols) != 0:
+ return false
+ case e.CredentialScope != (CredentialScope{}):
+ return false
+ case len(e.SignatureVersions) != 0:
+ return false
+ }
+ return true
+}
+
+func (e Endpoint) resolve(partition, region string, def Endpoint, options Options) (aws.Endpoint, error) {
+ var merged Endpoint
+ merged.mergeIn(def)
+ merged.mergeIn(e)
+ e = merged
+
+ if e.IsZero() {
+ return aws.Endpoint{}, fmt.Errorf("unable to resolve endpoint for region: %v", region)
+ }
+
+ var u string
+ if e.Unresolveable != aws.TrueTernary {
+ // Only attempt to resolve the endpoint if it can be resolved.
+ hostname := strings.Replace(e.Hostname, "{region}", region, 1)
+
+ scheme := getEndpointScheme(e.Protocols, options.DisableHTTPS)
+ u = scheme + "://" + hostname
+ }
+
+ signingRegion := e.CredentialScope.Region
+ if len(signingRegion) == 0 {
+ signingRegion = region
+ }
+ signingName := e.CredentialScope.Service
+
+ if e.Deprecated == aws.TrueTernary && options.LogDeprecated {
+ options.Logger.Logf(logging.Warn, "endpoint identifier %q, url %q marked as deprecated", region, u)
+ }
+
+ return aws.Endpoint{
+ URL: u,
+ PartitionID: partition,
+ SigningRegion: signingRegion,
+ SigningName: signingName,
+ SigningMethod: getByPriority(e.SignatureVersions, signerPriority, defaultSigner),
+ }, nil
+}
+
+func (e *Endpoint) mergeIn(other Endpoint) {
+ if other.Unresolveable != aws.UnknownTernary {
+ e.Unresolveable = other.Unresolveable
+ }
+ if len(other.Hostname) > 0 {
+ e.Hostname = other.Hostname
+ }
+ if len(other.Protocols) > 0 {
+ e.Protocols = other.Protocols
+ }
+ if len(other.CredentialScope.Region) > 0 {
+ e.CredentialScope.Region = other.CredentialScope.Region
+ }
+ if len(other.CredentialScope.Service) > 0 {
+ e.CredentialScope.Service = other.CredentialScope.Service
+ }
+ if len(other.SignatureVersions) > 0 {
+ e.SignatureVersions = other.SignatureVersions
+ }
+ if other.Deprecated != aws.UnknownTernary {
+ e.Deprecated = other.Deprecated
+ }
+}
+
+func getEndpointScheme(protocols []string, disableHTTPS bool) string {
+ if disableHTTPS {
+ return "http"
+ }
+
+ return getByPriority(protocols, protocolPriority, defaultProtocol)
+}
+
+func getByPriority(s []string, p []string, def string) string {
+ if len(s) == 0 {
+ return def
+ }
+
+ for i := 0; i < len(p); i++ {
+ for j := 0; j < len(s); j++ {
+ if s[j] == p[i] {
+ return s[j]
+ }
+ }
+ }
+
+ return s[0]
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go.mod
new file mode 100644
index 000000000000..095abba3e7aa
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go.mod
@@ -0,0 +1,11 @@
+module github.com/aws/aws-sdk-go-v2/internal/endpoints/v2
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/smithy-go v1.9.1
+ github.com/google/go-cmp v0.5.6
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../../../
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go_module_metadata.go
new file mode 100644
index 000000000000..e8864e20890c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/endpoints/v2/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package endpoints
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "2.1.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/CHANGELOG.md
new file mode 100644
index 000000000000..c99ac6a57d58
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/CHANGELOG.md
@@ -0,0 +1,59 @@
+# v1.3.3 (2022-01-07)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.2 (2021-12-02)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.0 (2021-11-06)
+
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.5 (2021-10-21)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.4 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.3 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.2 (2021-08-27)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.1 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.0 (2021-08-04)
+
+* **Feature**: adds error handling for defered close calls
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.1 (2021-07-15)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.0 (2021-07-01)
+
+* **Feature**: Support for `:`, `=`, `[`, `]` being present in expression values.
+
+# v1.0.1 (2021-06-25)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.0.0 (2021-05-20)
+
+* **Release**: The `github.com/aws/aws-sdk-go-v2/internal/ini` package is now a Go Module.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ast.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ast.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/ast.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ast.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/comma_token.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/comma_token.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/comma_token.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/comma_token.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/comment_token.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/comment_token.go
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/dependency.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/dependency.go
new file mode 100644
index 000000000000..f5ebe52e1a55
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/dependency.go
@@ -0,0 +1,6 @@
+package ini
+
+import (
+ // internal/ini module was carved out of this module
+ _ "github.com/aws/aws-sdk-go-v2"
+)
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/doc.go
new file mode 100644
index 000000000000..1e55bbd07b91
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/doc.go
@@ -0,0 +1,42 @@
+// Package ini is an LL(1) parser for configuration files.
+//
+// Example:
+// sections, err := ini.OpenFile("/path/to/file")
+// if err != nil {
+// panic(err)
+// }
+//
+// profile := "foo"
+// section, ok := sections.GetSection(profile)
+// if !ok {
+// fmt.Printf("section %q could not be found", profile)
+// }
+//
+// Below is the BNF that describes this parser
+// Grammar:
+// stmt -> section | stmt'
+// stmt' -> epsilon | expr
+// expr -> value (stmt)* | equal_expr (stmt)*
+// equal_expr -> value ( ':' | '=' ) equal_expr'
+// equal_expr' -> number | string | quoted_string
+// quoted_string -> " quoted_string'
+// quoted_string' -> string quoted_string_end
+// quoted_string_end -> "
+//
+// section -> [ section'
+// section' -> section_value section_close
+// section_value -> number | string_subset | boolean | quoted_string_subset
+// quoted_string_subset -> " quoted_string_subset'
+// quoted_string_subset' -> string_subset quoted_string_end
+// quoted_string_subset -> "
+// section_close -> ]
+//
+// value -> number | string_subset | boolean
+// string -> ? UTF-8 Code-Points except '\n' (U+000A) and '\r\n' (U+000D U+000A) ?
+// string_subset -> ? Code-points excepted by grammar except ':' (U+003A), '=' (U+003D), '[' (U+005B), and ']' (U+005D) ?
+//
+// SkipState will skip (NL WS)+
+//
+// comment -> # comment' | ; comment'
+// comment' -> epsilon | value
+package ini
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/empty_token.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/empty_token.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/empty_token.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/empty_token.go
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/errors.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/errors.go
new file mode 100644
index 000000000000..0f278d55e6c4
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/errors.go
@@ -0,0 +1,22 @@
+package ini
+
+import "fmt"
+
+// UnableToReadFile is an error indicating that a ini file could not be read
+type UnableToReadFile struct {
+ Err error
+}
+
+// Error returns an error message and the underlying error message if present
+func (e *UnableToReadFile) Error() string {
+ base := "unable to read file"
+ if e.Err == nil {
+ return base
+ }
+ return fmt.Sprintf("%s: %v", base, e.Err)
+}
+
+// Unwrap returns the underlying error
+func (e *UnableToReadFile) Unwrap() error {
+ return e.Err
+}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/expression.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/expression.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/expression.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/expression.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/fuzz.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/fuzz.go
similarity index 90%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/fuzz.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/fuzz.go
index 8d462f77e24f..6e545b63bc41 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/fuzz.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/fuzz.go
@@ -1,3 +1,4 @@
+//go:build gofuzz
// +build gofuzz
package ini
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go.mod
new file mode 100644
index 000000000000..6f7277df9c8f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go.mod
@@ -0,0 +1,7 @@
+module github.com/aws/aws-sdk-go-v2/internal/ini
+
+go 1.15
+
+require github.com/aws/aws-sdk-go-v2 v1.12.0
+
+replace github.com/aws/aws-sdk-go-v2 => ../../
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go.sum
new file mode 100644
index 000000000000..f7bd9b5b534c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go.sum
@@ -0,0 +1,11 @@
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go_module_metadata.go
new file mode 100644
index 000000000000..3c78da6f2c34
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package ini
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.3.3"
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini.go
similarity index 57%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/ini.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini.go
index 3b0ca7afe3b2..f7406231318d 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini.go
@@ -1,33 +1,40 @@
package ini
import (
+ "fmt"
"io"
"os"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
)
// OpenFile takes a path to a given file, and will open and parse
// that file.
-func OpenFile(path string) (Sections, error) {
- f, err := os.Open(path)
- if err != nil {
- return Sections{}, awserr.New(ErrCodeUnableToReadFile, "unable to open file", err)
+func OpenFile(path string) (sections Sections, err error) {
+ f, oerr := os.Open(path)
+ if oerr != nil {
+ return Sections{}, &UnableToReadFile{Err: oerr}
}
- defer f.Close()
- return Parse(f)
+ defer func() {
+ closeErr := f.Close()
+ if err == nil {
+ err = closeErr
+ } else if closeErr != nil {
+ err = fmt.Errorf("close error: %v, original error: %w", closeErr, err)
+ }
+ }()
+
+ return Parse(f, path)
}
// Parse will parse the given file using the shared config
// visitor.
-func Parse(f io.Reader) (Sections, error) {
+func Parse(f io.Reader, path string) (Sections, error) {
tree, err := ParseAST(f)
if err != nil {
return Sections{}, err
}
- v := NewDefaultVisitor()
+ v := NewDefaultVisitor(path)
if err = Walk(tree, v); err != nil {
return Sections{}, err
}
@@ -42,7 +49,7 @@ func ParseBytes(b []byte) (Sections, error) {
return Sections{}, err
}
- v := NewDefaultVisitor()
+ v := NewDefaultVisitor("")
if err = Walk(tree, v); err != nil {
return Sections{}, err
}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_lexer.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini_lexer.go
similarity index 91%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/ini_lexer.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini_lexer.go
index 582c024ad158..abf1fb036262 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_lexer.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini_lexer.go
@@ -4,14 +4,6 @@ import (
"bytes"
"io"
"io/ioutil"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-const (
- // ErrCodeUnableToReadFile is used when a file is failed to be
- // opened or read from.
- ErrCodeUnableToReadFile = "FailedRead"
)
// TokenType represents the various different tokens types
@@ -59,7 +51,7 @@ type iniLexer struct{}
func (l *iniLexer) Tokenize(r io.Reader) ([]Token, error) {
b, err := ioutil.ReadAll(r)
if err != nil {
- return nil, awserr.New(ErrCodeUnableToReadFile, "unable to read file", err)
+ return nil, &UnableToReadFile{Err: err}
}
return l.tokenize(b)
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini_parser.go
similarity index 87%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini_parser.go
index 55fa73ebcf2a..12fc7d5aa495 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ini_parser.go
@@ -5,9 +5,12 @@ import (
"io"
)
+// ParseState represents the current state of the parser.
+type ParseState uint
+
// State enums for the parse table
const (
- InvalidState = iota
+ InvalidState ParseState = iota
// stmt -> value stmt'
StatementState
// stmt' -> MarkComplete | op stmt
@@ -36,8 +39,8 @@ const (
)
// parseTable is a state machine to dictate the grammar above.
-var parseTable = map[ASTKind]map[TokenType]int{
- ASTKindStart: map[TokenType]int{
+var parseTable = map[ASTKind]map[TokenType]ParseState{
+ ASTKindStart: {
TokenLit: StatementState,
TokenSep: OpenScopeState,
TokenWS: SkipTokenState,
@@ -45,7 +48,7 @@ var parseTable = map[ASTKind]map[TokenType]int{
TokenComment: CommentState,
TokenNone: TerminalState,
},
- ASTKindCommentStatement: map[TokenType]int{
+ ASTKindCommentStatement: {
TokenLit: StatementState,
TokenSep: OpenScopeState,
TokenWS: SkipTokenState,
@@ -53,7 +56,7 @@ var parseTable = map[ASTKind]map[TokenType]int{
TokenComment: CommentState,
TokenNone: MarkCompleteState,
},
- ASTKindExpr: map[TokenType]int{
+ ASTKindExpr: {
TokenOp: StatementPrimeState,
TokenLit: ValueState,
TokenSep: OpenScopeState,
@@ -62,13 +65,14 @@ var parseTable = map[ASTKind]map[TokenType]int{
TokenComment: CommentState,
TokenNone: MarkCompleteState,
},
- ASTKindEqualExpr: map[TokenType]int{
- TokenLit: ValueState,
- TokenWS: SkipTokenState,
- TokenNL: SkipState,
- TokenNone: SkipState,
+ ASTKindEqualExpr: {
+ TokenLit: ValueState,
+ TokenSep: ValueState,
+ TokenOp: ValueState,
+ TokenWS: SkipTokenState,
+ TokenNL: SkipState,
},
- ASTKindStatement: map[TokenType]int{
+ ASTKindStatement: {
TokenLit: SectionState,
TokenSep: CloseScopeState,
TokenWS: SkipTokenState,
@@ -76,9 +80,9 @@ var parseTable = map[ASTKind]map[TokenType]int{
TokenComment: CommentState,
TokenNone: MarkCompleteState,
},
- ASTKindExprStatement: map[TokenType]int{
+ ASTKindExprStatement: {
TokenLit: ValueState,
- TokenSep: OpenScopeState,
+ TokenSep: ValueState,
TokenOp: ValueState,
TokenWS: ValueState,
TokenNL: MarkCompleteState,
@@ -86,14 +90,14 @@ var parseTable = map[ASTKind]map[TokenType]int{
TokenNone: TerminalState,
TokenComma: SkipState,
},
- ASTKindSectionStatement: map[TokenType]int{
+ ASTKindSectionStatement: {
TokenLit: SectionState,
TokenOp: SectionState,
TokenSep: CloseScopeState,
TokenWS: SectionState,
TokenNL: SkipTokenState,
},
- ASTKindCompletedSectionStatement: map[TokenType]int{
+ ASTKindCompletedSectionStatement: {
TokenWS: SkipTokenState,
TokenNL: SkipTokenState,
TokenLit: StatementState,
@@ -101,7 +105,7 @@ var parseTable = map[ASTKind]map[TokenType]int{
TokenComment: CommentState,
TokenNone: MarkCompleteState,
},
- ASTKindSkipStatement: map[TokenType]int{
+ ASTKindSkipStatement: {
TokenLit: StatementState,
TokenSep: OpenScopeState,
TokenWS: SkipTokenState,
@@ -205,18 +209,6 @@ loop:
case ValueState:
// ValueState requires the previous state to either be an equal expression
// or an expression statement.
- //
- // This grammar occurs when the RHS is a number, word, or quoted string.
- // equal_expr -> lit op equal_expr'
- // equal_expr' -> number | string | quoted_string
- // quoted_string -> " quoted_string'
- // quoted_string' -> string quoted_string_end
- // quoted_string_end -> "
- //
- // otherwise
- // expr_stmt -> equal_expr (expr_stmt')*
- // expr_stmt' -> ws S | op S | MarkComplete
- // S -> equal_expr' expr_stmt'
switch k.Kind {
case ASTKindEqualExpr:
// assigning a value to some key
@@ -243,7 +235,7 @@ loop:
}
children[len(children)-1] = rhs
- k.SetChildren(children)
+ root.SetChildren(children)
stack.Push(k)
}
@@ -314,7 +306,7 @@ loop:
default:
return nil, NewParseError(
fmt.Sprintf("invalid state with ASTKind %v and TokenType %v",
- k, tok.Type()))
+ k.Kind, tok.Type()))
}
if len(tokens) > 0 {
@@ -327,7 +319,7 @@ loop:
return nil, NewParseError(fmt.Sprintf("incomplete ini expression"))
}
- // returns a sublist which excludes the start symbol
+ // returns a sublist which exludes the start symbol
return stack.List(), nil
}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/literal_tokens.go
similarity index 88%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/literal_tokens.go
index 24df543d38cc..bea83941ef14 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/literal_tokens.go
@@ -4,6 +4,7 @@ import (
"fmt"
"strconv"
"strings"
+ "unicode"
)
var (
@@ -18,7 +19,7 @@ var literalValues = [][]rune{
func isBoolValue(b []rune) bool {
for _, lv := range literalValues {
- if isLitValue(lv, b) {
+ if isCaselessLitValue(lv, b) {
return true
}
}
@@ -39,6 +40,21 @@ func isLitValue(want, have []rune) bool {
return true
}
+// isCaselessLitValue is a caseless value comparison, assumes want is already lower-cased for efficiency.
+func isCaselessLitValue(want, have []rune) bool {
+ if len(have) < len(want) {
+ return false
+ }
+
+ for i := 0; i < len(want); i++ {
+ if want[i] != unicode.ToLower(have[i]) {
+ return false
+ }
+ }
+
+ return true
+}
+
// isNumberValue will return whether not the leading characters in
// a byte slice is a number. A number is delimited by whitespace or
// the newline token.
@@ -177,7 +193,7 @@ func newValue(t ValueType, base int, raw []rune) (Value, error) {
case QuotedStringType:
v.str = string(raw[1 : len(raw)-1])
case BoolType:
- v.boolean = runeCompare(v.raw, runesTrue)
+ v.boolean = isCaselessLitValue(runesTrue, v.raw)
}
// issue 2253
@@ -193,6 +209,16 @@ func newValue(t ValueType, base int, raw []rune) (Value, error) {
return v, err
}
+// NewStringValue returns a Value type generated using a string input.
+func NewStringValue(str string) (Value, error) {
+ return newValue(StringType, 10, []rune(str))
+}
+
+// NewIntValue returns a Value type generated using an int64 input.
+func NewIntValue(i int64) (Value, error) {
+ return newValue(IntegerType, 10, []rune{rune(i)})
+}
+
// Append will append values and change the type to a string
// type.
func (v *Value) Append(tok Token) {
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/newline_token.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/newline_token.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/newline_token.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/newline_token.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/number_helper.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/number_helper.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/number_helper.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/number_helper.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/op_tokens.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/op_tokens.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/op_tokens.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/op_tokens.go
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/parse_error.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/parse_error.go
new file mode 100644
index 000000000000..30ae0b8f228f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/parse_error.go
@@ -0,0 +1,19 @@
+package ini
+
+// ParseError is an error which is returned during any part of
+// the parsing process.
+type ParseError struct {
+ msg string
+}
+
+// NewParseError will return a new ParseError where message
+// is the description of the error.
+func NewParseError(message string) *ParseError {
+ return &ParseError{
+ msg: message,
+ }
+}
+
+func (err *ParseError) Error() string {
+ return err.msg
+}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_stack.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/parse_stack.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/parse_stack.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/parse_stack.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/sep_tokens.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/sep_tokens.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/sep_tokens.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/sep_tokens.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/skipper.go
similarity index 91%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/skipper.go
index da7a4049cfae..07e90876a4a9 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/skipper.go
@@ -30,6 +30,7 @@ func (s *skipper) ShouldSkip(tok Token) bool {
s.Continue()
return false
}
+
s.prevTok = tok
return s.shouldSkip
}
@@ -40,6 +41,5 @@ func (s *skipper) Skip() {
func (s *skipper) Continue() {
s.shouldSkip = false
- // empty token is assigned as we return to default state, when should skip is false
s.prevTok = emptyToken
}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/statement.go
similarity index 93%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/statement.go
index 18f3fe893170..ba0af01b53b4 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/statement.go
@@ -15,7 +15,7 @@ func newExprStatement(ast AST) AST {
return newAST(ASTKindExprStatement, ast)
}
-// CommentStatement represents a comment in the ini definition.
+// CommentStatement represents a comment in the ini defintion.
//
// grammar:
// comment -> #comment' | ;comment'
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/value_util.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/value_util.go
similarity index 99%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/value_util.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/value_util.go
index 305999d29be0..b5480fdeb359 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/value_util.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/value_util.go
@@ -57,7 +57,7 @@ func getBoolValue(b []rune) (int, error) {
continue
}
- if isLitValue(lv, b) {
+ if isCaselessLitValue(lv, b) {
n = len(lv)
}
}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/visitor.go
similarity index 51%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/visitor.go
index 94841c32443c..a07a6373897c 100644
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/visitor.go
@@ -3,6 +3,7 @@ package ini
import (
"fmt"
"sort"
+ "strings"
)
// Visitor is an interface used by walkers that will
@@ -18,16 +19,25 @@ type Visitor interface {
// the Sections field which can be used to retrieve profile
// configuration.
type DefaultVisitor struct {
- scope string
+
+ // scope is the profile which is being visited
+ scope string
+
+ // path is the file path which the visitor is visiting
+ path string
+
+ // Sections defines list of the profile section
Sections Sections
}
-// NewDefaultVisitor return a DefaultVisitor
-func NewDefaultVisitor() *DefaultVisitor {
+// NewDefaultVisitor returns a DefaultVisitor. It takes in a filepath
+// which points to the file it is visiting.
+func NewDefaultVisitor(filepath string) *DefaultVisitor {
return &DefaultVisitor{
Sections: Sections{
container: map[string]Section{},
},
+ path: filepath,
}
}
@@ -37,6 +47,9 @@ func (v *DefaultVisitor) VisitExpr(expr AST) error {
if t.values == nil {
t.values = values{}
}
+ if t.SourceFile == nil {
+ t.SourceFile = make(map[string]string, 0)
+ }
switch expr.Kind {
case ASTKindExprStatement:
@@ -50,17 +63,34 @@ func (v *DefaultVisitor) VisitExpr(expr AST) error {
rhs := children[1]
- if rhs.Root.Type() != TokenLit {
+ // The right-hand value side the equality expression is allowed to contain '[', ']', ':', '=' in the values.
+ // If the token is not either a literal or one of the token types that identifies those four additional
+ // tokens then error.
+ if !(rhs.Root.Type() == TokenLit || rhs.Root.Type() == TokenOp || rhs.Root.Type() == TokenSep) {
return NewParseError("unexpected token type")
}
key := EqualExprKey(opExpr)
- v, err := newValue(rhs.Root.ValueType, rhs.Root.base, rhs.Root.Raw())
+ val, err := newValue(rhs.Root.ValueType, rhs.Root.base, rhs.Root.Raw())
if err != nil {
return err
}
- t.values[key] = v
+ // lower case key to standardize
+ k := strings.ToLower(key)
+
+ // identify if the section already had this key, append log on section
+ if t.Has(k) {
+ t.Logs = append(t.Logs,
+ fmt.Sprintf("For profile: %v, overriding %v value, "+
+ "with a %v value found in a duplicate profile defined later in the same file %v. \n",
+ t.Name, k, k, v.path))
+ }
+
+ // assign the value
+ t.values[k] = val
+ // update the source file path for region
+ t.SourceFile[k] = v.path
default:
return NewParseError(fmt.Sprintf("unsupported expression %v", expr))
}
@@ -82,7 +112,21 @@ func (v *DefaultVisitor) VisitStatement(stmt AST) error {
}
name := string(child.Root.Raw())
- v.Sections.container[name] = Section{}
+
+ // trim start and end space
+ name = strings.TrimSpace(name)
+
+ // if has prefix "profile " + [ws+] + "profile-name",
+ // we standardize by removing the [ws+] between prefix and profile-name.
+ if strings.HasPrefix(name, "profile ") {
+ names := strings.SplitN(name, " ", 2)
+ name = names[0] + " " + strings.TrimLeft(names[1], " ")
+ }
+
+ // attach profile name on section
+ if !v.Sections.HasSection(name) {
+ v.Sections.container[name] = NewSection(name)
+ }
v.scope = name
default:
return NewParseError(fmt.Sprintf("unsupported statement: %s", stmt.Kind))
@@ -97,6 +141,13 @@ type Sections struct {
container map[string]Section
}
+// NewSections returns empty ini Sections
+func NewSections() Sections {
+ return Sections{
+ container: make(map[string]Section, 0),
+ }
+}
+
// GetSection will return section p. If section p does not exist,
// false will be returned in the second parameter.
func (t Sections) GetSection(p string) (Section, bool) {
@@ -104,6 +155,24 @@ func (t Sections) GetSection(p string) (Section, bool) {
return v, ok
}
+// HasSection denotes if Sections consist of a section with
+// provided name.
+func (t Sections) HasSection(p string) bool {
+ _, ok := t.container[p]
+ return ok
+}
+
+// SetSection sets a section value for provided section name.
+func (t Sections) SetSection(p string, v Section) Sections {
+ t.container[p] = v
+ return t
+}
+
+// DeleteSection deletes a section entry/value for provided section name./
+func (t Sections) DeleteSection(p string) {
+ delete(t.container, p)
+}
+
// values represents a map of union values.
type values map[string]Value
@@ -124,8 +193,42 @@ func (t Sections) List() []string {
// Section contains a name and values. This represent
// a sectioned entry in a configuration file.
type Section struct {
- Name string
+ // Name is the Section profile name
+ Name string
+
+ // values are the values within parsed profile
values values
+
+ // Errors is the list of errors
+ Errors []error
+
+ // Logs is the list of logs
+ Logs []string
+
+ // SourceFile is the INI Source file from where this section
+ // was retrieved. They key is the property, value is the
+ // source file the property was retrieved from.
+ SourceFile map[string]string
+}
+
+// NewSection returns an initialize section for the name
+func NewSection(name string) Section {
+ return Section{
+ Name: name,
+ values: values{},
+ SourceFile: map[string]string{},
+ }
+}
+
+// UpdateSourceFile updates source file for a property to provided filepath.
+func (t Section) UpdateSourceFile(property string, filepath string) {
+ t.SourceFile[property] = filepath
+}
+
+// UpdateValue updates value for a provided key with provided value
+func (t Section) UpdateValue(k string, v Value) error {
+ t.values[k] = v
+ return nil
}
// Has will return whether or not an entry exists in a given section
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/walker.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/walker.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/walker.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/walker.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ws_token.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ws_token.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/ini/ws_token.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/ini/ws_token.go
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/rand/rand.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/rand/rand.go
new file mode 100644
index 000000000000..9791ea590b5f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/rand/rand.go
@@ -0,0 +1,33 @@
+package rand
+
+import (
+ "crypto/rand"
+ "fmt"
+ "io"
+ "math/big"
+)
+
+func init() {
+ Reader = rand.Reader
+}
+
+// Reader provides a random reader that can reset during testing.
+var Reader io.Reader
+
+var floatMaxBigInt = big.NewInt(1 << 53)
+
+// Float64 returns a float64 read from an io.Reader source. The returned float will be between [0.0, 1.0).
+func Float64(reader io.Reader) (float64, error) {
+ bi, err := rand.Int(reader, floatMaxBigInt)
+ if err != nil {
+ return 0, fmt.Errorf("failed to read random value, %v", err)
+ }
+
+ return float64(bi.Int64()) / (1 << 53), nil
+}
+
+// CryptoRandFloat64 returns a random float64 obtained from the crypto rand
+// source.
+func CryptoRandFloat64() (float64, error) {
+ return Float64(rand.Reader)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/sdk/interfaces.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/sdk/interfaces.go
new file mode 100644
index 000000000000..2b42cbe6421a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/sdk/interfaces.go
@@ -0,0 +1,9 @@
+package sdk
+
+// Invalidator provides access to a type's invalidate method to make it
+// invalidate it cache.
+//
+// e.g aws.SafeCredentialsProvider's Invalidate method.
+type Invalidator interface {
+ Invalidate()
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/sdk/time.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/sdk/time.go
new file mode 100644
index 000000000000..8e8dabad5488
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/sdk/time.go
@@ -0,0 +1,74 @@
+package sdk
+
+import (
+ "context"
+ "time"
+)
+
+func init() {
+ NowTime = time.Now
+ Sleep = time.Sleep
+ SleepWithContext = sleepWithContext
+}
+
+// NowTime is a value for getting the current time. This value can be overridden
+// for testing mocking out current time.
+var NowTime func() time.Time
+
+// Sleep is a value for sleeping for a duration. This value can be overridden
+// for testing and mocking out sleep duration.
+var Sleep func(time.Duration)
+
+// SleepWithContext will wait for the timer duration to expire, or the context
+// is canceled. Which ever happens first. If the context is canceled the Context's
+// error will be returned.
+//
+// This value can be overridden for testing and mocking out sleep duration.
+var SleepWithContext func(context.Context, time.Duration) error
+
+// sleepWithContext will wait for the timer duration to expire, or the context
+// is canceled. Which ever happens first. If the context is canceled the
+// Context's error will be returned.
+func sleepWithContext(ctx context.Context, dur time.Duration) error {
+ t := time.NewTimer(dur)
+ defer t.Stop()
+
+ select {
+ case <-t.C:
+ break
+ case <-ctx.Done():
+ return ctx.Err()
+ }
+
+ return nil
+}
+
+// noOpSleepWithContext does nothing, returns immediately.
+func noOpSleepWithContext(context.Context, time.Duration) error {
+ return nil
+}
+
+func noOpSleep(time.Duration) {}
+
+// TestingUseNopSleep is a utility for disabling sleep across the SDK for
+// testing.
+func TestingUseNopSleep() func() {
+ SleepWithContext = noOpSleepWithContext
+ Sleep = noOpSleep
+
+ return func() {
+ SleepWithContext = sleepWithContext
+ Sleep = time.Sleep
+ }
+}
+
+// TestingUseReferenceTime is a utility for swapping the time function across the SDK to return a specific reference time
+// for testing purposes.
+func TestingUseReferenceTime(referenceTime time.Time) func() {
+ NowTime = func() time.Time {
+ return referenceTime
+ }
+ return func() {
+ NowTime = time.Now
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkio/byte.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/sdkio/byte.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/sdkio/byte.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/sdkio/byte.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/strings/strings.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/strings/strings.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/strings/strings.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/strings/strings.go
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sync/singleflight/LICENSE b/vendor/github.com/aws/aws-sdk-go-v2/internal/sync/singleflight/LICENSE
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/sync/singleflight/LICENSE
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/sync/singleflight/LICENSE
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sync/singleflight/singleflight.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/sync/singleflight/singleflight.go
similarity index 100%
rename from vendor/github.com/aws/aws-sdk-go/internal/sync/singleflight/singleflight.go
rename to vendor/github.com/aws/aws-sdk-go-v2/internal/sync/singleflight/singleflight.go
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/internal/timeconv/duration.go b/vendor/github.com/aws/aws-sdk-go-v2/internal/timeconv/duration.go
new file mode 100644
index 000000000000..5d69db5f2497
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/internal/timeconv/duration.go
@@ -0,0 +1,13 @@
+package timeconv
+
+import "time"
+
+// FloatSecondsDur converts a fractional seconds to duration.
+func FloatSecondsDur(v float64) time.Duration {
+ return time.Duration(v * float64(time.Second))
+}
+
+// DurSecondsFloat converts a duration into fractional seconds.
+func DurSecondsFloat(d time.Duration) float64 {
+ return float64(d) / float64(time.Second)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/local-mod-replace.sh b/vendor/github.com/aws/aws-sdk-go-v2/local-mod-replace.sh
new file mode 100644
index 000000000000..8a2aea99e2f4
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/local-mod-replace.sh
@@ -0,0 +1,39 @@
+#1/usr/bin/env bash
+
+PROJECT_DIR=""
+SDK_SOURCE_DIR=$(cd `dirname $0` && pwd)
+
+usage() {
+ echo "Usage: $0 [-s SDK_SOURCE_DIR] [-d PROJECT_DIR]" 1>&2
+ exit 1
+}
+
+while getopts "hs:d:" options; do
+ case "${options}" in
+ s)
+ SDK_SOURCE_DIR=${OPTARG}
+ if [ "$SDK_SOURCE_DIR" == "" ]; then
+ echo "path to SDK source directory is required" || exit
+ usage
+ fi
+ ;;
+ d)
+ PROJECT_DIR=${OPTARG}
+ ;;
+ h)
+ usage
+ ;;
+ *)
+ usage
+ ;;
+ esac
+done
+
+if [ "$PROJECT_DIR" != "" ]; then
+ cd $PROJECT_DIR || exit
+fi
+
+go mod graph | awk '{print $1}' | cut -d '@' -f 1 | sort | uniq | grep "github.com/aws/aws-sdk-go-v2" | while read x; do
+ repPath=${x/github.com\/aws\/aws-sdk-go-v2/${SDK_SOURCE_DIR}}
+ echo -replace $x=$repPath
+done | xargs go mod edit
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/modman.toml b/vendor/github.com/aws/aws-sdk-go-v2/modman.toml
new file mode 100644
index 000000000000..353085ff295b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/modman.toml
@@ -0,0 +1,65 @@
+
+[dependencies]
+ "github.com/aws/smithy-go" = "v1.9.1"
+ "github.com/google/go-cmp" = "v0.5.6"
+ "github.com/jmespath/go-jmespath" = "v0.4.0"
+ "golang.org/x/net" = "v0.0.0-20211209124913-491a49abca63"
+
+[modules]
+
+ [modules."."]
+ metadata_package = "aws"
+
+ [modules."example/service/s3/listObjects"]
+ no_tag = true
+
+ [modules."example/service/s3/usingPrivateLink"]
+ no_tag = true
+
+ [modules."feature/ec2/imds/internal/configtesting"]
+ no_tag = true
+
+ [modules."internal/configsources/configtesting"]
+ no_tag = true
+
+ [modules."internal/protocoltest/awsrestjson"]
+ no_tag = true
+
+ [modules."internal/protocoltest/ec2query"]
+ no_tag = true
+
+ [modules."internal/protocoltest/jsonrpc"]
+ no_tag = true
+
+ [modules."internal/protocoltest/jsonrpc10"]
+ no_tag = true
+
+ [modules."internal/protocoltest/query"]
+ no_tag = true
+
+ [modules."internal/protocoltest/restxml"]
+ no_tag = true
+
+ [modules."internal/protocoltest/restxmlwithnamespace"]
+ no_tag = true
+
+ [modules."internal/repotools"]
+ no_tag = true
+
+ [modules."internal/repotools/changes"]
+ no_tag = true
+
+ [modules."service/internal/benchmark"]
+ no_tag = true
+
+ [modules."service/internal/integrationtest"]
+ no_tag = true
+
+ [modules."service/kinesis/internal/testing"]
+ no_tag = true
+
+ [modules."service/s3/internal/configtesting"]
+ no_tag = true
+
+ [modules."service/transcribestreaming/internal/testing"]
+ no_tag = true
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/CHANGELOG.md
new file mode 100644
index 000000000000..e30a6a7e8923
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/CHANGELOG.md
@@ -0,0 +1,87 @@
+# v1.13.0 (2022-01-07)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.12.0 (2021-12-21)
+
+* **Feature**: API Paginators now support specifying the initial starting token, and support stopping on empty string tokens.
+* **Feature**: Updated to latest service endpoints
+
+# v1.11.1 (2021-12-02)
+
+* **Bug Fix**: Fixes a bug that prevented aws.EndpointResolverWithOptions from being used by the service client. ([#1514](https://github.com/aws/aws-sdk-go-v2/pull/1514))
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.11.0 (2021-11-30)
+
+* **Feature**: API client updated
+
+# v1.10.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.10.0 (2021-11-12)
+
+* **Feature**: Service clients now support custom endpoints that have an initial URI path defined.
+* **Feature**: Waiters now have a `WaitForOutput` method, which can be used to retrieve the output of the successful wait operation. Thank you to [Andrew Haines](https://github.com/haines) for contributing this feature.
+
+# v1.9.0 (2021-11-06)
+
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Feature**: Updated service to latest API model.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.0 (2021-10-21)
+
+* **Feature**: API client updated
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.7.1 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.7.0 (2021-09-24)
+
+* **Feature**: API client updated
+
+# v1.6.0 (2021-09-17)
+
+* **Feature**: Updated API client and endpoints to latest revision.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.0 (2021-08-27)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.3 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.2 (2021-08-04)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.1 (2021-07-15)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.0 (2021-06-25)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.1 (2021-05-20)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.0 (2021-05-14)
+
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_client.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_client.go
new file mode 100644
index 000000000000..4e274f2714c8
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_client.go
@@ -0,0 +1,297 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/retry"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ awshttp "github.com/aws/aws-sdk-go-v2/aws/transport/http"
+ internalConfig "github.com/aws/aws-sdk-go-v2/internal/configsources"
+ smithy "github.com/aws/smithy-go"
+ smithydocument "github.com/aws/smithy-go/document"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "net/http"
+ "time"
+)
+
+const ServiceID = "ECR"
+const ServiceAPIVersion = "2015-09-21"
+
+// Client provides the API client to make operations call for Amazon EC2 Container
+// Registry.
+type Client struct {
+ options Options
+}
+
+// New returns an initialized Client based on the functional options. Provide
+// additional functional options to further configure the behavior of the client,
+// such as changing the client's endpoint or adding custom middleware behavior.
+func New(options Options, optFns ...func(*Options)) *Client {
+ options = options.Copy()
+
+ resolveDefaultLogger(&options)
+
+ resolveRetryer(&options)
+
+ resolveHTTPClient(&options)
+
+ resolveHTTPSignerV4(&options)
+
+ resolveDefaultEndpointConfiguration(&options)
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ client := &Client{
+ options: options,
+ }
+
+ return client
+}
+
+type Options struct {
+ // Set of options to modify how an operation is invoked. These apply to all
+ // operations invoked for this client. Use functional options on operation call to
+ // modify this list for per operation behavior.
+ APIOptions []func(*middleware.Stack) error
+
+ // Configures the events that will be sent to the configured logger.
+ ClientLogMode aws.ClientLogMode
+
+ // The credentials object to use when signing requests.
+ Credentials aws.CredentialsProvider
+
+ // The endpoint options to be used when attempting to resolve an endpoint.
+ EndpointOptions EndpointResolverOptions
+
+ // The service endpoint resolver.
+ EndpointResolver EndpointResolver
+
+ // Signature Version 4 (SigV4) Signer
+ HTTPSignerV4 HTTPSignerV4
+
+ // The logger writer interface to write logging messages to.
+ Logger logging.Logger
+
+ // The region to send requests to. (Required)
+ Region string
+
+ // Retryer guides how HTTP requests should be retried in case of recoverable
+ // failures. When nil the API client will use a default retryer.
+ Retryer aws.Retryer
+
+ // The HTTP client to invoke API calls with. Defaults to client's default HTTP
+ // implementation if nil.
+ HTTPClient HTTPClient
+}
+
+// WithAPIOptions returns a functional option for setting the Client's APIOptions
+// option.
+func WithAPIOptions(optFns ...func(*middleware.Stack) error) func(*Options) {
+ return func(o *Options) {
+ o.APIOptions = append(o.APIOptions, optFns...)
+ }
+}
+
+// WithEndpointResolver returns a functional option for setting the Client's
+// EndpointResolver option.
+func WithEndpointResolver(v EndpointResolver) func(*Options) {
+ return func(o *Options) {
+ o.EndpointResolver = v
+ }
+}
+
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// Copy creates a clone where the APIOptions list is deep copied.
+func (o Options) Copy() Options {
+ to := o
+ to.APIOptions = make([]func(*middleware.Stack) error, len(o.APIOptions))
+ copy(to.APIOptions, o.APIOptions)
+ return to
+}
+func (c *Client) invokeOperation(ctx context.Context, opID string, params interface{}, optFns []func(*Options), stackFns ...func(*middleware.Stack, Options) error) (result interface{}, metadata middleware.Metadata, err error) {
+ ctx = middleware.ClearStackValues(ctx)
+ stack := middleware.NewStack(opID, smithyhttp.NewStackRequest)
+ options := c.options.Copy()
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ finalizeClientEndpointResolverOptions(&options)
+
+ for _, fn := range stackFns {
+ if err := fn(stack, options); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ for _, fn := range options.APIOptions {
+ if err := fn(stack); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ handler := middleware.DecorateHandler(smithyhttp.NewClientHandler(options.HTTPClient), stack)
+ result, metadata, err = handler.Handle(ctx, params)
+ if err != nil {
+ err = &smithy.OperationError{
+ ServiceID: ServiceID,
+ OperationName: opID,
+ Err: err,
+ }
+ }
+ return result, metadata, err
+}
+
+type noSmithyDocumentSerde = smithydocument.NoSerde
+
+func resolveDefaultLogger(o *Options) {
+ if o.Logger != nil {
+ return
+ }
+ o.Logger = logging.Nop{}
+}
+
+func addSetLoggerMiddleware(stack *middleware.Stack, o Options) error {
+ return middleware.AddSetLoggerMiddleware(stack, o.Logger)
+}
+
+// NewFromConfig returns a new client from the provided config.
+func NewFromConfig(cfg aws.Config, optFns ...func(*Options)) *Client {
+ opts := Options{
+ Region: cfg.Region,
+ HTTPClient: cfg.HTTPClient,
+ Credentials: cfg.Credentials,
+ APIOptions: cfg.APIOptions,
+ Logger: cfg.Logger,
+ ClientLogMode: cfg.ClientLogMode,
+ }
+ resolveAWSRetryerProvider(cfg, &opts)
+ resolveAWSEndpointResolver(cfg, &opts)
+ resolveUseDualStackEndpoint(cfg, &opts)
+ resolveUseFIPSEndpoint(cfg, &opts)
+ return New(opts, optFns...)
+}
+
+func resolveHTTPClient(o *Options) {
+ if o.HTTPClient != nil {
+ return
+ }
+ o.HTTPClient = awshttp.NewBuildableClient()
+}
+
+func resolveRetryer(o *Options) {
+ if o.Retryer != nil {
+ return
+ }
+ o.Retryer = retry.NewStandard()
+}
+
+func resolveAWSRetryerProvider(cfg aws.Config, o *Options) {
+ if cfg.Retryer == nil {
+ return
+ }
+ o.Retryer = cfg.Retryer()
+}
+
+func resolveAWSEndpointResolver(cfg aws.Config, o *Options) {
+ if cfg.EndpointResolver == nil && cfg.EndpointResolverWithOptions == nil {
+ return
+ }
+ o.EndpointResolver = withEndpointResolver(cfg.EndpointResolver, cfg.EndpointResolverWithOptions, NewDefaultEndpointResolver())
+}
+
+func addClientUserAgent(stack *middleware.Stack) error {
+ return awsmiddleware.AddSDKAgentKeyValue(awsmiddleware.APIMetadata, "ecr", goModuleVersion)(stack)
+}
+
+func addHTTPSignerV4Middleware(stack *middleware.Stack, o Options) error {
+ mw := v4.NewSignHTTPRequestMiddleware(v4.SignHTTPRequestMiddlewareOptions{
+ CredentialsProvider: o.Credentials,
+ Signer: o.HTTPSignerV4,
+ LogSigning: o.ClientLogMode.IsSigning(),
+ })
+ return stack.Finalize.Add(mw, middleware.After)
+}
+
+type HTTPSignerV4 interface {
+ SignHTTP(ctx context.Context, credentials aws.Credentials, r *http.Request, payloadHash string, service string, region string, signingTime time.Time, optFns ...func(*v4.SignerOptions)) error
+}
+
+func resolveHTTPSignerV4(o *Options) {
+ if o.HTTPSignerV4 != nil {
+ return
+ }
+ o.HTTPSignerV4 = newDefaultV4Signer(*o)
+}
+
+func newDefaultV4Signer(o Options) *v4.Signer {
+ return v4.NewSigner(func(so *v4.SignerOptions) {
+ so.Logger = o.Logger
+ so.LogSigning = o.ClientLogMode.IsSigning()
+ })
+}
+
+func addRetryMiddlewares(stack *middleware.Stack, o Options) error {
+ mo := retry.AddRetryMiddlewaresOptions{
+ Retryer: o.Retryer,
+ LogRetryAttempts: o.ClientLogMode.IsRetries(),
+ }
+ return retry.AddRetryMiddlewares(stack, mo)
+}
+
+// resolves dual-stack endpoint configuration
+func resolveUseDualStackEndpoint(cfg aws.Config, o *Options) error {
+ if len(cfg.ConfigSources) == 0 {
+ return nil
+ }
+ value, found, err := internalConfig.ResolveUseDualStackEndpoint(context.Background(), cfg.ConfigSources)
+ if err != nil {
+ return err
+ }
+ if found {
+ o.EndpointOptions.UseDualStackEndpoint = value
+ }
+ return nil
+}
+
+// resolves FIPS endpoint configuration
+func resolveUseFIPSEndpoint(cfg aws.Config, o *Options) error {
+ if len(cfg.ConfigSources) == 0 {
+ return nil
+ }
+ value, found, err := internalConfig.ResolveUseFIPSEndpoint(context.Background(), cfg.ConfigSources)
+ if err != nil {
+ return err
+ }
+ if found {
+ o.EndpointOptions.UseFIPSEndpoint = value
+ }
+ return nil
+}
+
+func addRequestIDRetrieverMiddleware(stack *middleware.Stack) error {
+ return awsmiddleware.AddRequestIDRetrieverMiddleware(stack)
+}
+
+func addResponseErrorMiddleware(stack *middleware.Stack) error {
+ return awshttp.AddResponseErrorMiddleware(stack)
+}
+
+func addRequestResponseLogging(stack *middleware.Stack, o Options) error {
+ return stack.Deserialize.Add(&smithyhttp.RequestResponseLogger{
+ LogRequest: o.ClientLogMode.IsRequest(),
+ LogRequestWithBody: o.ClientLogMode.IsRequestWithBody(),
+ LogResponse: o.ClientLogMode.IsResponse(),
+ LogResponseWithBody: o.ClientLogMode.IsResponseWithBody(),
+ }, middleware.After)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchCheckLayerAvailability.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchCheckLayerAvailability.go
new file mode 100644
index 000000000000..cea7521f6890
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchCheckLayerAvailability.go
@@ -0,0 +1,140 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Checks the availability of one or more image layers in a repository. When an
+// image is pushed to a repository, each image layer is checked to verify if it has
+// been uploaded before. If it has been uploaded, then the image layer is skipped.
+// This operation is used by the Amazon ECR proxy and is not generally used by
+// customers for pulling and pushing images. In most cases, you should use the
+// docker CLI to pull, tag, and push images.
+func (c *Client) BatchCheckLayerAvailability(ctx context.Context, params *BatchCheckLayerAvailabilityInput, optFns ...func(*Options)) (*BatchCheckLayerAvailabilityOutput, error) {
+ if params == nil {
+ params = &BatchCheckLayerAvailabilityInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "BatchCheckLayerAvailability", params, optFns, c.addOperationBatchCheckLayerAvailabilityMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*BatchCheckLayerAvailabilityOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type BatchCheckLayerAvailabilityInput struct {
+
+ // The digests of the image layers to check.
+ //
+ // This member is required.
+ LayerDigests []string
+
+ // The name of the repository that is associated with the image layers to check.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the image layers to check. If you do not specify a registry, the default
+ // registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type BatchCheckLayerAvailabilityOutput struct {
+
+ // Any failures associated with the call.
+ Failures []types.LayerFailure
+
+ // A list of image layer objects corresponding to the image layer references in the
+ // request.
+ Layers []types.Layer
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationBatchCheckLayerAvailabilityMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpBatchCheckLayerAvailability{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpBatchCheckLayerAvailability{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpBatchCheckLayerAvailabilityValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opBatchCheckLayerAvailability(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opBatchCheckLayerAvailability(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "BatchCheckLayerAvailability",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchDeleteImage.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchDeleteImage.go
new file mode 100644
index 000000000000..80c9d5b5cf4f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchDeleteImage.go
@@ -0,0 +1,141 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes a list of specified images within a repository. Images are specified
+// with either an imageTag or imageDigest. You can remove a tag from an image by
+// specifying the image's tag in your request. When you remove the last tag from an
+// image, the image is deleted from your repository. You can completely delete an
+// image (and all of its tags) by specifying the image's digest in your request.
+func (c *Client) BatchDeleteImage(ctx context.Context, params *BatchDeleteImageInput, optFns ...func(*Options)) (*BatchDeleteImageOutput, error) {
+ if params == nil {
+ params = &BatchDeleteImageInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "BatchDeleteImage", params, optFns, c.addOperationBatchDeleteImageMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*BatchDeleteImageOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+// Deletes specified images within a specified repository. Images are specified
+// with either the imageTag or imageDigest.
+type BatchDeleteImageInput struct {
+
+ // A list of image ID references that correspond to images to delete. The format of
+ // the imageIds reference is imageTag=tag or imageDigest=digest.
+ //
+ // This member is required.
+ ImageIds []types.ImageIdentifier
+
+ // The repository that contains the image to delete.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the image to delete. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type BatchDeleteImageOutput struct {
+
+ // Any failures associated with the call.
+ Failures []types.ImageFailure
+
+ // The image IDs of the deleted images.
+ ImageIds []types.ImageIdentifier
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationBatchDeleteImageMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpBatchDeleteImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpBatchDeleteImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpBatchDeleteImageValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opBatchDeleteImage(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opBatchDeleteImage(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "BatchDeleteImage",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchGetImage.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchGetImage.go
new file mode 100644
index 000000000000..b2724f89a543
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchGetImage.go
@@ -0,0 +1,143 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Gets detailed information for an image. Images are specified with either an
+// imageTag or imageDigest. When an image is pulled, the BatchGetImage API is
+// called once to retrieve the image manifest.
+func (c *Client) BatchGetImage(ctx context.Context, params *BatchGetImageInput, optFns ...func(*Options)) (*BatchGetImageOutput, error) {
+ if params == nil {
+ params = &BatchGetImageInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "BatchGetImage", params, optFns, c.addOperationBatchGetImageMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*BatchGetImageOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type BatchGetImageInput struct {
+
+ // A list of image ID references that correspond to images to describe. The format
+ // of the imageIds reference is imageTag=tag or imageDigest=digest.
+ //
+ // This member is required.
+ ImageIds []types.ImageIdentifier
+
+ // The repository that contains the images to describe.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The accepted media types for the request. Valid values:
+ // application/vnd.docker.distribution.manifest.v1+json |
+ // application/vnd.docker.distribution.manifest.v2+json |
+ // application/vnd.oci.image.manifest.v1+json
+ AcceptedMediaTypes []string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the images to describe. If you do not specify a registry, the default registry
+ // is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type BatchGetImageOutput struct {
+
+ // Any failures associated with the call.
+ Failures []types.ImageFailure
+
+ // A list of image objects corresponding to the image references in the request.
+ Images []types.Image
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationBatchGetImageMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpBatchGetImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpBatchGetImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpBatchGetImageValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opBatchGetImage(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opBatchGetImage(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "BatchGetImage",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchGetRepositoryScanningConfiguration.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchGetRepositoryScanningConfiguration.go
new file mode 100644
index 000000000000..42adcbbc46af
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_BatchGetRepositoryScanningConfiguration.go
@@ -0,0 +1,124 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Gets the scanning configuration for one or more repositories.
+func (c *Client) BatchGetRepositoryScanningConfiguration(ctx context.Context, params *BatchGetRepositoryScanningConfigurationInput, optFns ...func(*Options)) (*BatchGetRepositoryScanningConfigurationOutput, error) {
+ if params == nil {
+ params = &BatchGetRepositoryScanningConfigurationInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "BatchGetRepositoryScanningConfiguration", params, optFns, c.addOperationBatchGetRepositoryScanningConfigurationMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*BatchGetRepositoryScanningConfigurationOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type BatchGetRepositoryScanningConfigurationInput struct {
+
+ // One or more repository names to get the scanning configuration for.
+ //
+ // This member is required.
+ RepositoryNames []string
+
+ noSmithyDocumentSerde
+}
+
+type BatchGetRepositoryScanningConfigurationOutput struct {
+
+ // Any failures associated with the call.
+ Failures []types.RepositoryScanningConfigurationFailure
+
+ // The scanning configuration for the requested repositories.
+ ScanningConfigurations []types.RepositoryScanningConfiguration
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationBatchGetRepositoryScanningConfigurationMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpBatchGetRepositoryScanningConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpBatchGetRepositoryScanningConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpBatchGetRepositoryScanningConfigurationValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opBatchGetRepositoryScanningConfiguration(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opBatchGetRepositoryScanningConfiguration(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "BatchGetRepositoryScanningConfiguration",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CompleteLayerUpload.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CompleteLayerUpload.go
new file mode 100644
index 000000000000..ac1fe8a370c3
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CompleteLayerUpload.go
@@ -0,0 +1,151 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Informs Amazon ECR that the image layer upload has completed for a specified
+// registry, repository name, and upload ID. You can optionally provide a sha256
+// digest of the image layer for data validation purposes. When an image is pushed,
+// the CompleteLayerUpload API is called once per each new image layer to verify
+// that the upload has completed. This operation is used by the Amazon ECR proxy
+// and is not generally used by customers for pulling and pushing images. In most
+// cases, you should use the docker CLI to pull, tag, and push images.
+func (c *Client) CompleteLayerUpload(ctx context.Context, params *CompleteLayerUploadInput, optFns ...func(*Options)) (*CompleteLayerUploadOutput, error) {
+ if params == nil {
+ params = &CompleteLayerUploadInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "CompleteLayerUpload", params, optFns, c.addOperationCompleteLayerUploadMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*CompleteLayerUploadOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type CompleteLayerUploadInput struct {
+
+ // The sha256 digest of the image layer.
+ //
+ // This member is required.
+ LayerDigests []string
+
+ // The name of the repository to associate with the image layer.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The upload ID from a previous InitiateLayerUpload operation to associate with
+ // the image layer.
+ //
+ // This member is required.
+ UploadId *string
+
+ // The Amazon Web Services account ID associated with the registry to which to
+ // upload layers. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type CompleteLayerUploadOutput struct {
+
+ // The sha256 digest of the image layer.
+ LayerDigest *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // The upload ID associated with the layer.
+ UploadId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationCompleteLayerUploadMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpCompleteLayerUpload{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpCompleteLayerUpload{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpCompleteLayerUploadValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCompleteLayerUpload(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opCompleteLayerUpload(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "CompleteLayerUpload",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CreatePullThroughCacheRule.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CreatePullThroughCacheRule.go
new file mode 100644
index 000000000000..6a67466e977d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CreatePullThroughCacheRule.go
@@ -0,0 +1,144 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "time"
+)
+
+// Creates a pull through cache rule. A pull through cache rule provides a way to
+// cache images from an external public registry in your Amazon ECR private
+// registry.
+func (c *Client) CreatePullThroughCacheRule(ctx context.Context, params *CreatePullThroughCacheRuleInput, optFns ...func(*Options)) (*CreatePullThroughCacheRuleOutput, error) {
+ if params == nil {
+ params = &CreatePullThroughCacheRuleInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "CreatePullThroughCacheRule", params, optFns, c.addOperationCreatePullThroughCacheRuleMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*CreatePullThroughCacheRuleOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type CreatePullThroughCacheRuleInput struct {
+
+ // The repository name prefix to use when caching images from the source registry.
+ //
+ // This member is required.
+ EcrRepositoryPrefix *string
+
+ // The registry URL of the upstream public registry to use as the source for the
+ // pull through cache rule.
+ //
+ // This member is required.
+ UpstreamRegistryUrl *string
+
+ // The Amazon Web Services account ID associated with the registry to create the
+ // pull through cache rule for. If you do not specify a registry, the default
+ // registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type CreatePullThroughCacheRuleOutput struct {
+
+ // The date and time, in JavaScript date format, when the pull through cache rule
+ // was created.
+ CreatedAt *time.Time
+
+ // The Amazon ECR repository prefix associated with the pull through cache rule.
+ EcrRepositoryPrefix *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The upstream registry URL associated with the pull through cache rule.
+ UpstreamRegistryUrl *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationCreatePullThroughCacheRuleMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpCreatePullThroughCacheRule{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpCreatePullThroughCacheRule{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpCreatePullThroughCacheRuleValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreatePullThroughCacheRule(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opCreatePullThroughCacheRule(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "CreatePullThroughCacheRule",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CreateRepository.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CreateRepository.go
new file mode 100644
index 000000000000..1f22e5c8217d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_CreateRepository.go
@@ -0,0 +1,150 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates a repository. For more information, see Amazon ECR repositories
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/Repositories.html) in
+// the Amazon Elastic Container Registry User Guide.
+func (c *Client) CreateRepository(ctx context.Context, params *CreateRepositoryInput, optFns ...func(*Options)) (*CreateRepositoryOutput, error) {
+ if params == nil {
+ params = &CreateRepositoryInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "CreateRepository", params, optFns, c.addOperationCreateRepositoryMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*CreateRepositoryOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type CreateRepositoryInput struct {
+
+ // The name to use for the repository. The repository name may be specified on its
+ // own (such as nginx-web-app) or it can be prepended with a namespace to group the
+ // repository into a category (such as project-a/nginx-web-app).
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The encryption configuration for the repository. This determines how the
+ // contents of your repository are encrypted at rest.
+ EncryptionConfiguration *types.EncryptionConfiguration
+
+ // The image scanning configuration for the repository. This determines whether
+ // images are scanned for known vulnerabilities after being pushed to the
+ // repository.
+ ImageScanningConfiguration *types.ImageScanningConfiguration
+
+ // The tag mutability setting for the repository. If this parameter is omitted, the
+ // default setting of MUTABLE will be used which will allow image tags to be
+ // overwritten. If IMMUTABLE is specified, all image tags within the repository
+ // will be immutable which will prevent them from being overwritten.
+ ImageTagMutability types.ImageTagMutability
+
+ // The Amazon Web Services account ID associated with the registry to create the
+ // repository. If you do not specify a registry, the default registry is assumed.
+ RegistryId *string
+
+ // The metadata that you apply to the repository to help you categorize and
+ // organize them. Each tag consists of a key and an optional value, both of which
+ // you define. Tag keys can have a maximum character length of 128 characters, and
+ // tag values can have a maximum length of 256 characters.
+ Tags []types.Tag
+
+ noSmithyDocumentSerde
+}
+
+type CreateRepositoryOutput struct {
+
+ // The repository that was created.
+ Repository *types.Repository
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationCreateRepositoryMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpCreateRepository{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpCreateRepository{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpCreateRepositoryValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateRepository(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opCreateRepository(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "CreateRepository",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteLifecyclePolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteLifecyclePolicy.go
new file mode 100644
index 000000000000..1f215085fff3
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteLifecyclePolicy.go
@@ -0,0 +1,135 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "time"
+)
+
+// Deletes the lifecycle policy associated with the specified repository.
+func (c *Client) DeleteLifecyclePolicy(ctx context.Context, params *DeleteLifecyclePolicyInput, optFns ...func(*Options)) (*DeleteLifecyclePolicyOutput, error) {
+ if params == nil {
+ params = &DeleteLifecyclePolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DeleteLifecyclePolicy", params, optFns, c.addOperationDeleteLifecyclePolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DeleteLifecyclePolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DeleteLifecyclePolicyInput struct {
+
+ // The name of the repository.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DeleteLifecyclePolicyOutput struct {
+
+ // The time stamp of the last time that the lifecycle policy was run.
+ LastEvaluatedAt *time.Time
+
+ // The JSON lifecycle policy text.
+ LifecyclePolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDeleteLifecyclePolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeleteLifecyclePolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeleteLifecyclePolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDeleteLifecyclePolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteLifecyclePolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDeleteLifecyclePolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DeleteLifecyclePolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeletePullThroughCacheRule.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeletePullThroughCacheRule.go
new file mode 100644
index 000000000000..1f4bd9701dde
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeletePullThroughCacheRule.go
@@ -0,0 +1,136 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "time"
+)
+
+// Deletes a pull through cache rule.
+func (c *Client) DeletePullThroughCacheRule(ctx context.Context, params *DeletePullThroughCacheRuleInput, optFns ...func(*Options)) (*DeletePullThroughCacheRuleOutput, error) {
+ if params == nil {
+ params = &DeletePullThroughCacheRuleInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DeletePullThroughCacheRule", params, optFns, c.addOperationDeletePullThroughCacheRuleMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DeletePullThroughCacheRuleOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DeletePullThroughCacheRuleInput struct {
+
+ // The Amazon ECR repository prefix associated with the pull through cache rule to
+ // delete.
+ //
+ // This member is required.
+ EcrRepositoryPrefix *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the pull through cache rule. If you do not specify a registry, the default
+ // registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DeletePullThroughCacheRuleOutput struct {
+
+ // The timestamp associated with the pull through cache rule.
+ CreatedAt *time.Time
+
+ // The Amazon ECR repository prefix associated with the request.
+ EcrRepositoryPrefix *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The upstream registry URL associated with the pull through cache rule.
+ UpstreamRegistryUrl *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDeletePullThroughCacheRuleMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeletePullThroughCacheRule{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeletePullThroughCacheRule{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDeletePullThroughCacheRuleValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeletePullThroughCacheRule(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDeletePullThroughCacheRule(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DeletePullThroughCacheRule",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRegistryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRegistryPolicy.go
new file mode 100644
index 000000000000..a9230f956e12
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRegistryPolicy.go
@@ -0,0 +1,114 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes the registry permissions policy.
+func (c *Client) DeleteRegistryPolicy(ctx context.Context, params *DeleteRegistryPolicyInput, optFns ...func(*Options)) (*DeleteRegistryPolicyOutput, error) {
+ if params == nil {
+ params = &DeleteRegistryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DeleteRegistryPolicy", params, optFns, c.addOperationDeleteRegistryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DeleteRegistryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DeleteRegistryPolicyInput struct {
+ noSmithyDocumentSerde
+}
+
+type DeleteRegistryPolicyOutput struct {
+
+ // The contents of the registry permissions policy that was deleted.
+ PolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDeleteRegistryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeleteRegistryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeleteRegistryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteRegistryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDeleteRegistryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DeleteRegistryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRepository.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRepository.go
new file mode 100644
index 000000000000..525834b915f2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRepository.go
@@ -0,0 +1,130 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes a repository. If the repository contains images, you must either delete
+// all images in the repository or use the force option to delete the repository.
+func (c *Client) DeleteRepository(ctx context.Context, params *DeleteRepositoryInput, optFns ...func(*Options)) (*DeleteRepositoryOutput, error) {
+ if params == nil {
+ params = &DeleteRepositoryInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DeleteRepository", params, optFns, c.addOperationDeleteRepositoryMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DeleteRepositoryOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DeleteRepositoryInput struct {
+
+ // The name of the repository to delete.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // If a repository contains images, forces the deletion.
+ Force bool
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository to delete. If you do not specify a registry, the default registry
+ // is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DeleteRepositoryOutput struct {
+
+ // The repository that was deleted.
+ Repository *types.Repository
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDeleteRepositoryMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeleteRepository{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeleteRepository{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDeleteRepositoryValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteRepository(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDeleteRepository(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DeleteRepository",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRepositoryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRepositoryPolicy.go
new file mode 100644
index 000000000000..dd23305f84b2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DeleteRepositoryPolicy.go
@@ -0,0 +1,132 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes the repository policy associated with the specified repository.
+func (c *Client) DeleteRepositoryPolicy(ctx context.Context, params *DeleteRepositoryPolicyInput, optFns ...func(*Options)) (*DeleteRepositoryPolicyOutput, error) {
+ if params == nil {
+ params = &DeleteRepositoryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DeleteRepositoryPolicy", params, optFns, c.addOperationDeleteRepositoryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DeleteRepositoryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DeleteRepositoryPolicyInput struct {
+
+ // The name of the repository that is associated with the repository policy to
+ // delete.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository policy to delete. If you do not specify a registry, the default
+ // registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DeleteRepositoryPolicyOutput struct {
+
+ // The JSON repository policy that was deleted from the repository.
+ PolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDeleteRepositoryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeleteRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeleteRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDeleteRepositoryPolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteRepositoryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDeleteRepositoryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DeleteRepositoryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImageReplicationStatus.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImageReplicationStatus.go
new file mode 100644
index 000000000000..0edd166a70f7
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImageReplicationStatus.go
@@ -0,0 +1,136 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns the replication status for a specified image.
+func (c *Client) DescribeImageReplicationStatus(ctx context.Context, params *DescribeImageReplicationStatusInput, optFns ...func(*Options)) (*DescribeImageReplicationStatusOutput, error) {
+ if params == nil {
+ params = &DescribeImageReplicationStatusInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeImageReplicationStatus", params, optFns, c.addOperationDescribeImageReplicationStatusMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeImageReplicationStatusOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeImageReplicationStatusInput struct {
+
+ // An object with identifying information for an image in an Amazon ECR repository.
+ //
+ // This member is required.
+ ImageId *types.ImageIdentifier
+
+ // The name of the repository that the image is in.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry. If you do not
+ // specify a registry, the default registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DescribeImageReplicationStatusOutput struct {
+
+ // An object with identifying information for an image in an Amazon ECR repository.
+ ImageId *types.ImageIdentifier
+
+ // The replication status details for the images in the specified repository.
+ ReplicationStatuses []types.ImageReplicationStatus
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeImageReplicationStatusMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeImageReplicationStatus{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeImageReplicationStatus{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDescribeImageReplicationStatusValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeImageReplicationStatus(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDescribeImageReplicationStatus(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DescribeImageReplicationStatus",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImageScanFindings.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImageScanFindings.go
new file mode 100644
index 000000000000..5908d7ed0a30
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImageScanFindings.go
@@ -0,0 +1,447 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithytime "github.com/aws/smithy-go/time"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ smithywaiter "github.com/aws/smithy-go/waiter"
+ "github.com/jmespath/go-jmespath"
+ "time"
+)
+
+// Returns the scan findings for the specified image.
+func (c *Client) DescribeImageScanFindings(ctx context.Context, params *DescribeImageScanFindingsInput, optFns ...func(*Options)) (*DescribeImageScanFindingsOutput, error) {
+ if params == nil {
+ params = &DescribeImageScanFindingsInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeImageScanFindings", params, optFns, c.addOperationDescribeImageScanFindingsMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeImageScanFindingsOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeImageScanFindingsInput struct {
+
+ // An object with identifying information for an image in an Amazon ECR repository.
+ //
+ // This member is required.
+ ImageId *types.ImageIdentifier
+
+ // The repository for the image for which to describe the scan findings.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The maximum number of image scan results returned by DescribeImageScanFindings
+ // in paginated output. When this parameter is used, DescribeImageScanFindings only
+ // returns maxResults results in a single page along with a nextToken response
+ // element. The remaining results of the initial request can be seen by sending
+ // another DescribeImageScanFindings request with the returned nextToken value.
+ // This value can be between 1 and 1000. If this parameter is not used, then
+ // DescribeImageScanFindings returns up to 100 results and a nextToken value, if
+ // applicable.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated DescribeImageScanFindings
+ // request where maxResults was used and the results exceeded the value of that
+ // parameter. Pagination continues from the end of the previous results that
+ // returned the nextToken value. This value is null when there are no more results
+ // to return.
+ NextToken *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository in which to describe the image scan findings for. If you do not
+ // specify a registry, the default registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DescribeImageScanFindingsOutput struct {
+
+ // An object with identifying information for an image in an Amazon ECR repository.
+ ImageId *types.ImageIdentifier
+
+ // The information contained in the image scan findings.
+ ImageScanFindings *types.ImageScanFindings
+
+ // The current state of the scan.
+ ImageScanStatus *types.ImageScanStatus
+
+ // The nextToken value to include in a future DescribeImageScanFindings request.
+ // When the results of a DescribeImageScanFindings request exceed maxResults, this
+ // value can be used to retrieve the next page of results. This value is null when
+ // there are no more results to return.
+ NextToken *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeImageScanFindingsMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeImageScanFindings{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeImageScanFindings{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDescribeImageScanFindingsValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeImageScanFindings(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// DescribeImageScanFindingsAPIClient is a client that implements the
+// DescribeImageScanFindings operation.
+type DescribeImageScanFindingsAPIClient interface {
+ DescribeImageScanFindings(context.Context, *DescribeImageScanFindingsInput, ...func(*Options)) (*DescribeImageScanFindingsOutput, error)
+}
+
+var _ DescribeImageScanFindingsAPIClient = (*Client)(nil)
+
+// DescribeImageScanFindingsPaginatorOptions is the paginator options for
+// DescribeImageScanFindings
+type DescribeImageScanFindingsPaginatorOptions struct {
+ // The maximum number of image scan results returned by DescribeImageScanFindings
+ // in paginated output. When this parameter is used, DescribeImageScanFindings only
+ // returns maxResults results in a single page along with a nextToken response
+ // element. The remaining results of the initial request can be seen by sending
+ // another DescribeImageScanFindings request with the returned nextToken value.
+ // This value can be between 1 and 1000. If this parameter is not used, then
+ // DescribeImageScanFindings returns up to 100 results and a nextToken value, if
+ // applicable.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// DescribeImageScanFindingsPaginator is a paginator for DescribeImageScanFindings
+type DescribeImageScanFindingsPaginator struct {
+ options DescribeImageScanFindingsPaginatorOptions
+ client DescribeImageScanFindingsAPIClient
+ params *DescribeImageScanFindingsInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewDescribeImageScanFindingsPaginator returns a new
+// DescribeImageScanFindingsPaginator
+func NewDescribeImageScanFindingsPaginator(client DescribeImageScanFindingsAPIClient, params *DescribeImageScanFindingsInput, optFns ...func(*DescribeImageScanFindingsPaginatorOptions)) *DescribeImageScanFindingsPaginator {
+ if params == nil {
+ params = &DescribeImageScanFindingsInput{}
+ }
+
+ options := DescribeImageScanFindingsPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &DescribeImageScanFindingsPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *DescribeImageScanFindingsPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next DescribeImageScanFindings page.
+func (p *DescribeImageScanFindingsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeImageScanFindingsOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.DescribeImageScanFindings(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+// ImageScanCompleteWaiterOptions are waiter options for ImageScanCompleteWaiter
+type ImageScanCompleteWaiterOptions struct {
+
+ // Set of options to modify how an operation is invoked. These apply to all
+ // operations invoked for this client. Use functional options on operation call to
+ // modify this list for per operation behavior.
+ APIOptions []func(*middleware.Stack) error
+
+ // MinDelay is the minimum amount of time to delay between retries. If unset,
+ // ImageScanCompleteWaiter will use default minimum delay of 5 seconds. Note that
+ // MinDelay must resolve to a value lesser than or equal to the MaxDelay.
+ MinDelay time.Duration
+
+ // MaxDelay is the maximum amount of time to delay between retries. If unset or set
+ // to zero, ImageScanCompleteWaiter will use default max delay of 120 seconds. Note
+ // that MaxDelay must resolve to value greater than or equal to the MinDelay.
+ MaxDelay time.Duration
+
+ // LogWaitAttempts is used to enable logging for waiter retry attempts
+ LogWaitAttempts bool
+
+ // Retryable is function that can be used to override the service defined
+ // waiter-behavior based on operation output, or returned error. This function is
+ // used by the waiter to decide if a state is retryable or a terminal state. By
+ // default service-modeled logic will populate this option. This option can thus be
+ // used to define a custom waiter state with fall-back to service-modeled waiter
+ // state mutators.The function returns an error in case of a failure state. In case
+ // of retry state, this function returns a bool value of true and nil error, while
+ // in case of success it returns a bool value of false and nil error.
+ Retryable func(context.Context, *DescribeImageScanFindingsInput, *DescribeImageScanFindingsOutput, error) (bool, error)
+}
+
+// ImageScanCompleteWaiter defines the waiters for ImageScanComplete
+type ImageScanCompleteWaiter struct {
+ client DescribeImageScanFindingsAPIClient
+
+ options ImageScanCompleteWaiterOptions
+}
+
+// NewImageScanCompleteWaiter constructs a ImageScanCompleteWaiter.
+func NewImageScanCompleteWaiter(client DescribeImageScanFindingsAPIClient, optFns ...func(*ImageScanCompleteWaiterOptions)) *ImageScanCompleteWaiter {
+ options := ImageScanCompleteWaiterOptions{}
+ options.MinDelay = 5 * time.Second
+ options.MaxDelay = 120 * time.Second
+ options.Retryable = imageScanCompleteStateRetryable
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+ return &ImageScanCompleteWaiter{
+ client: client,
+ options: options,
+ }
+}
+
+// Wait calls the waiter function for ImageScanComplete waiter. The maxWaitDur is
+// the maximum wait duration the waiter will wait. The maxWaitDur is required and
+// must be greater than zero.
+func (w *ImageScanCompleteWaiter) Wait(ctx context.Context, params *DescribeImageScanFindingsInput, maxWaitDur time.Duration, optFns ...func(*ImageScanCompleteWaiterOptions)) error {
+ _, err := w.WaitForOutput(ctx, params, maxWaitDur, optFns...)
+ return err
+}
+
+// WaitForOutput calls the waiter function for ImageScanComplete waiter and returns
+// the output of the successful operation. The maxWaitDur is the maximum wait
+// duration the waiter will wait. The maxWaitDur is required and must be greater
+// than zero.
+func (w *ImageScanCompleteWaiter) WaitForOutput(ctx context.Context, params *DescribeImageScanFindingsInput, maxWaitDur time.Duration, optFns ...func(*ImageScanCompleteWaiterOptions)) (*DescribeImageScanFindingsOutput, error) {
+ if maxWaitDur <= 0 {
+ return nil, fmt.Errorf("maximum wait time for waiter must be greater than zero")
+ }
+
+ options := w.options
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ if options.MaxDelay <= 0 {
+ options.MaxDelay = 120 * time.Second
+ }
+
+ if options.MinDelay > options.MaxDelay {
+ return nil, fmt.Errorf("minimum waiter delay %v must be lesser than or equal to maximum waiter delay of %v.", options.MinDelay, options.MaxDelay)
+ }
+
+ ctx, cancelFn := context.WithTimeout(ctx, maxWaitDur)
+ defer cancelFn()
+
+ logger := smithywaiter.Logger{}
+ remainingTime := maxWaitDur
+
+ var attempt int64
+ for {
+
+ attempt++
+ apiOptions := options.APIOptions
+ start := time.Now()
+
+ if options.LogWaitAttempts {
+ logger.Attempt = attempt
+ apiOptions = append([]func(*middleware.Stack) error{}, options.APIOptions...)
+ apiOptions = append(apiOptions, logger.AddLogger)
+ }
+
+ out, err := w.client.DescribeImageScanFindings(ctx, params, func(o *Options) {
+ o.APIOptions = append(o.APIOptions, apiOptions...)
+ })
+
+ retryable, err := options.Retryable(ctx, params, out, err)
+ if err != nil {
+ return nil, err
+ }
+ if !retryable {
+ return out, nil
+ }
+
+ remainingTime -= time.Since(start)
+ if remainingTime < options.MinDelay || remainingTime <= 0 {
+ break
+ }
+
+ // compute exponential backoff between waiter retries
+ delay, err := smithywaiter.ComputeDelay(
+ attempt, options.MinDelay, options.MaxDelay, remainingTime,
+ )
+ if err != nil {
+ return nil, fmt.Errorf("error computing waiter delay, %w", err)
+ }
+
+ remainingTime -= delay
+ // sleep for the delay amount before invoking a request
+ if err := smithytime.SleepWithContext(ctx, delay); err != nil {
+ return nil, fmt.Errorf("request cancelled while waiting, %w", err)
+ }
+ }
+ return nil, fmt.Errorf("exceeded max wait time for ImageScanComplete waiter")
+}
+
+func imageScanCompleteStateRetryable(ctx context.Context, input *DescribeImageScanFindingsInput, output *DescribeImageScanFindingsOutput, err error) (bool, error) {
+
+ if err == nil {
+ pathValue, err := jmespath.Search("imageScanStatus.status", output)
+ if err != nil {
+ return false, fmt.Errorf("error evaluating waiter state: %w", err)
+ }
+
+ expectedValue := "COMPLETE"
+ value, ok := pathValue.(types.ScanStatus)
+ if !ok {
+ return false, fmt.Errorf("waiter comparator expected types.ScanStatus value, got %T", pathValue)
+ }
+
+ if string(value) == expectedValue {
+ return false, nil
+ }
+ }
+
+ if err == nil {
+ pathValue, err := jmespath.Search("imageScanStatus.status", output)
+ if err != nil {
+ return false, fmt.Errorf("error evaluating waiter state: %w", err)
+ }
+
+ expectedValue := "FAILED"
+ value, ok := pathValue.(types.ScanStatus)
+ if !ok {
+ return false, fmt.Errorf("waiter comparator expected types.ScanStatus value, got %T", pathValue)
+ }
+
+ if string(value) == expectedValue {
+ return false, fmt.Errorf("waiter state transitioned to Failure")
+ }
+ }
+
+ return true, nil
+}
+
+func newServiceMetadataMiddleware_opDescribeImageScanFindings(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DescribeImageScanFindings",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImages.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImages.go
new file mode 100644
index 000000000000..f4b654290b86
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeImages.go
@@ -0,0 +1,257 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns metadata about the images in a repository. Beginning with Docker version
+// 1.9, the Docker client compresses image layers before pushing them to a V2
+// Docker registry. The output of the docker images command shows the uncompressed
+// image size, so it may return a larger image size than the image sizes returned
+// by DescribeImages.
+func (c *Client) DescribeImages(ctx context.Context, params *DescribeImagesInput, optFns ...func(*Options)) (*DescribeImagesOutput, error) {
+ if params == nil {
+ params = &DescribeImagesInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeImages", params, optFns, c.addOperationDescribeImagesMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeImagesOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeImagesInput struct {
+
+ // The repository that contains the images to describe.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The filter key and value with which to filter your DescribeImages results.
+ Filter *types.DescribeImagesFilter
+
+ // The list of image IDs for the requested repository.
+ ImageIds []types.ImageIdentifier
+
+ // The maximum number of repository results returned by DescribeImages in paginated
+ // output. When this parameter is used, DescribeImages only returns maxResults
+ // results in a single page along with a nextToken response element. The remaining
+ // results of the initial request can be seen by sending another DescribeImages
+ // request with the returned nextToken value. This value can be between 1 and 1000.
+ // If this parameter is not used, then DescribeImages returns up to 100 results and
+ // a nextToken value, if applicable. This option cannot be used when you specify
+ // images with imageIds.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated DescribeImages request
+ // where maxResults was used and the results exceeded the value of that parameter.
+ // Pagination continues from the end of the previous results that returned the
+ // nextToken value. This value is null when there are no more results to return.
+ // This option cannot be used when you specify images with imageIds.
+ NextToken *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository in which to describe images. If you do not specify a registry,
+ // the default registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DescribeImagesOutput struct {
+
+ // A list of ImageDetail objects that contain data about the image.
+ ImageDetails []types.ImageDetail
+
+ // The nextToken value to include in a future DescribeImages request. When the
+ // results of a DescribeImages request exceed maxResults, this value can be used to
+ // retrieve the next page of results. This value is null when there are no more
+ // results to return.
+ NextToken *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeImagesMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeImages{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeImages{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDescribeImagesValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeImages(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// DescribeImagesAPIClient is a client that implements the DescribeImages
+// operation.
+type DescribeImagesAPIClient interface {
+ DescribeImages(context.Context, *DescribeImagesInput, ...func(*Options)) (*DescribeImagesOutput, error)
+}
+
+var _ DescribeImagesAPIClient = (*Client)(nil)
+
+// DescribeImagesPaginatorOptions is the paginator options for DescribeImages
+type DescribeImagesPaginatorOptions struct {
+ // The maximum number of repository results returned by DescribeImages in paginated
+ // output. When this parameter is used, DescribeImages only returns maxResults
+ // results in a single page along with a nextToken response element. The remaining
+ // results of the initial request can be seen by sending another DescribeImages
+ // request with the returned nextToken value. This value can be between 1 and 1000.
+ // If this parameter is not used, then DescribeImages returns up to 100 results and
+ // a nextToken value, if applicable. This option cannot be used when you specify
+ // images with imageIds.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// DescribeImagesPaginator is a paginator for DescribeImages
+type DescribeImagesPaginator struct {
+ options DescribeImagesPaginatorOptions
+ client DescribeImagesAPIClient
+ params *DescribeImagesInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewDescribeImagesPaginator returns a new DescribeImagesPaginator
+func NewDescribeImagesPaginator(client DescribeImagesAPIClient, params *DescribeImagesInput, optFns ...func(*DescribeImagesPaginatorOptions)) *DescribeImagesPaginator {
+ if params == nil {
+ params = &DescribeImagesInput{}
+ }
+
+ options := DescribeImagesPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &DescribeImagesPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *DescribeImagesPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next DescribeImages page.
+func (p *DescribeImagesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeImagesOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.DescribeImages(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opDescribeImages(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DescribeImages",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribePullThroughCacheRules.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribePullThroughCacheRules.go
new file mode 100644
index 000000000000..2bfefbd7a932
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribePullThroughCacheRules.go
@@ -0,0 +1,249 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns the pull through cache rules for a registry.
+func (c *Client) DescribePullThroughCacheRules(ctx context.Context, params *DescribePullThroughCacheRulesInput, optFns ...func(*Options)) (*DescribePullThroughCacheRulesOutput, error) {
+ if params == nil {
+ params = &DescribePullThroughCacheRulesInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribePullThroughCacheRules", params, optFns, c.addOperationDescribePullThroughCacheRulesMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribePullThroughCacheRulesOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribePullThroughCacheRulesInput struct {
+
+ // The Amazon ECR repository prefixes associated with the pull through cache rules
+ // to return. If no repository prefix value is specified, all pull through cache
+ // rules are returned.
+ EcrRepositoryPrefixes []string
+
+ // The maximum number of pull through cache rules returned by
+ // DescribePullThroughCacheRulesRequest in paginated output. When this parameter is
+ // used, DescribePullThroughCacheRulesRequest only returns maxResults results in a
+ // single page along with a nextToken response element. The remaining results of
+ // the initial request can be seen by sending another
+ // DescribePullThroughCacheRulesRequest request with the returned nextToken value.
+ // This value can be between 1 and 1000. If this parameter is not used, then
+ // DescribePullThroughCacheRulesRequest returns up to 100 results and a nextToken
+ // value, if applicable.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated
+ // DescribePullThroughCacheRulesRequest request where maxResults was used and the
+ // results exceeded the value of that parameter. Pagination continues from the end
+ // of the previous results that returned the nextToken value. This value is null
+ // when there are no more results to return.
+ NextToken *string
+
+ // The Amazon Web Services account ID associated with the registry to return the
+ // pull through cache rules for. If you do not specify a registry, the default
+ // registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DescribePullThroughCacheRulesOutput struct {
+
+ // The nextToken value to include in a future DescribePullThroughCacheRulesRequest
+ // request. When the results of a DescribePullThroughCacheRulesRequest request
+ // exceed maxResults, this value can be used to retrieve the next page of results.
+ // This value is null when there are no more results to return.
+ NextToken *string
+
+ // The details of the pull through cache rules.
+ PullThroughCacheRules []types.PullThroughCacheRule
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribePullThroughCacheRulesMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribePullThroughCacheRules{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribePullThroughCacheRules{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribePullThroughCacheRules(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// DescribePullThroughCacheRulesAPIClient is a client that implements the
+// DescribePullThroughCacheRules operation.
+type DescribePullThroughCacheRulesAPIClient interface {
+ DescribePullThroughCacheRules(context.Context, *DescribePullThroughCacheRulesInput, ...func(*Options)) (*DescribePullThroughCacheRulesOutput, error)
+}
+
+var _ DescribePullThroughCacheRulesAPIClient = (*Client)(nil)
+
+// DescribePullThroughCacheRulesPaginatorOptions is the paginator options for
+// DescribePullThroughCacheRules
+type DescribePullThroughCacheRulesPaginatorOptions struct {
+ // The maximum number of pull through cache rules returned by
+ // DescribePullThroughCacheRulesRequest in paginated output. When this parameter is
+ // used, DescribePullThroughCacheRulesRequest only returns maxResults results in a
+ // single page along with a nextToken response element. The remaining results of
+ // the initial request can be seen by sending another
+ // DescribePullThroughCacheRulesRequest request with the returned nextToken value.
+ // This value can be between 1 and 1000. If this parameter is not used, then
+ // DescribePullThroughCacheRulesRequest returns up to 100 results and a nextToken
+ // value, if applicable.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// DescribePullThroughCacheRulesPaginator is a paginator for
+// DescribePullThroughCacheRules
+type DescribePullThroughCacheRulesPaginator struct {
+ options DescribePullThroughCacheRulesPaginatorOptions
+ client DescribePullThroughCacheRulesAPIClient
+ params *DescribePullThroughCacheRulesInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewDescribePullThroughCacheRulesPaginator returns a new
+// DescribePullThroughCacheRulesPaginator
+func NewDescribePullThroughCacheRulesPaginator(client DescribePullThroughCacheRulesAPIClient, params *DescribePullThroughCacheRulesInput, optFns ...func(*DescribePullThroughCacheRulesPaginatorOptions)) *DescribePullThroughCacheRulesPaginator {
+ if params == nil {
+ params = &DescribePullThroughCacheRulesInput{}
+ }
+
+ options := DescribePullThroughCacheRulesPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &DescribePullThroughCacheRulesPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *DescribePullThroughCacheRulesPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next DescribePullThroughCacheRules page.
+func (p *DescribePullThroughCacheRulesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribePullThroughCacheRulesOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.DescribePullThroughCacheRules(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opDescribePullThroughCacheRules(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DescribePullThroughCacheRules",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeRegistry.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeRegistry.go
new file mode 100644
index 000000000000..8d5f44222de1
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeRegistry.go
@@ -0,0 +1,117 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Describes the settings for a registry. The replication configuration for a
+// repository can be created or updated with the PutReplicationConfiguration API
+// action.
+func (c *Client) DescribeRegistry(ctx context.Context, params *DescribeRegistryInput, optFns ...func(*Options)) (*DescribeRegistryOutput, error) {
+ if params == nil {
+ params = &DescribeRegistryInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeRegistry", params, optFns, c.addOperationDescribeRegistryMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeRegistryOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeRegistryInput struct {
+ noSmithyDocumentSerde
+}
+
+type DescribeRegistryOutput struct {
+
+ // The ID of the registry.
+ RegistryId *string
+
+ // The replication configuration for the registry.
+ ReplicationConfiguration *types.ReplicationConfiguration
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeRegistryMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeRegistry{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeRegistry{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeRegistry(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDescribeRegistry(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DescribeRegistry",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeRepositories.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeRepositories.go
new file mode 100644
index 000000000000..cef08268c3e0
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_DescribeRepositories.go
@@ -0,0 +1,247 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Describes image repositories in a registry.
+func (c *Client) DescribeRepositories(ctx context.Context, params *DescribeRepositoriesInput, optFns ...func(*Options)) (*DescribeRepositoriesOutput, error) {
+ if params == nil {
+ params = &DescribeRepositoriesInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeRepositories", params, optFns, c.addOperationDescribeRepositoriesMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeRepositoriesOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeRepositoriesInput struct {
+
+ // The maximum number of repository results returned by DescribeRepositories in
+ // paginated output. When this parameter is used, DescribeRepositories only returns
+ // maxResults results in a single page along with a nextToken response element. The
+ // remaining results of the initial request can be seen by sending another
+ // DescribeRepositories request with the returned nextToken value. This value can
+ // be between 1 and 1000. If this parameter is not used, then DescribeRepositories
+ // returns up to 100 results and a nextToken value, if applicable. This option
+ // cannot be used when you specify repositories with repositoryNames.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated DescribeRepositories
+ // request where maxResults was used and the results exceeded the value of that
+ // parameter. Pagination continues from the end of the previous results that
+ // returned the nextToken value. This value is null when there are no more results
+ // to return. This option cannot be used when you specify repositories with
+ // repositoryNames. This token should be treated as an opaque identifier that is
+ // only used to retrieve the next items in a list and not for other programmatic
+ // purposes.
+ NextToken *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repositories to be described. If you do not specify a registry, the default
+ // registry is assumed.
+ RegistryId *string
+
+ // A list of repositories to describe. If this parameter is omitted, then all
+ // repositories in a registry are described.
+ RepositoryNames []string
+
+ noSmithyDocumentSerde
+}
+
+type DescribeRepositoriesOutput struct {
+
+ // The nextToken value to include in a future DescribeRepositories request. When
+ // the results of a DescribeRepositories request exceed maxResults, this value can
+ // be used to retrieve the next page of results. This value is null when there are
+ // no more results to return.
+ NextToken *string
+
+ // A list of repository objects corresponding to valid repositories.
+ Repositories []types.Repository
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeRepositoriesMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeRepositories{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeRepositories{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeRepositories(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// DescribeRepositoriesAPIClient is a client that implements the
+// DescribeRepositories operation.
+type DescribeRepositoriesAPIClient interface {
+ DescribeRepositories(context.Context, *DescribeRepositoriesInput, ...func(*Options)) (*DescribeRepositoriesOutput, error)
+}
+
+var _ DescribeRepositoriesAPIClient = (*Client)(nil)
+
+// DescribeRepositoriesPaginatorOptions is the paginator options for
+// DescribeRepositories
+type DescribeRepositoriesPaginatorOptions struct {
+ // The maximum number of repository results returned by DescribeRepositories in
+ // paginated output. When this parameter is used, DescribeRepositories only returns
+ // maxResults results in a single page along with a nextToken response element. The
+ // remaining results of the initial request can be seen by sending another
+ // DescribeRepositories request with the returned nextToken value. This value can
+ // be between 1 and 1000. If this parameter is not used, then DescribeRepositories
+ // returns up to 100 results and a nextToken value, if applicable. This option
+ // cannot be used when you specify repositories with repositoryNames.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// DescribeRepositoriesPaginator is a paginator for DescribeRepositories
+type DescribeRepositoriesPaginator struct {
+ options DescribeRepositoriesPaginatorOptions
+ client DescribeRepositoriesAPIClient
+ params *DescribeRepositoriesInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewDescribeRepositoriesPaginator returns a new DescribeRepositoriesPaginator
+func NewDescribeRepositoriesPaginator(client DescribeRepositoriesAPIClient, params *DescribeRepositoriesInput, optFns ...func(*DescribeRepositoriesPaginatorOptions)) *DescribeRepositoriesPaginator {
+ if params == nil {
+ params = &DescribeRepositoriesInput{}
+ }
+
+ options := DescribeRepositoriesPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &DescribeRepositoriesPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *DescribeRepositoriesPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next DescribeRepositories page.
+func (p *DescribeRepositoriesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeRepositoriesOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.DescribeRepositories(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opDescribeRepositories(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "DescribeRepositories",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetAuthorizationToken.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetAuthorizationToken.go
new file mode 100644
index 000000000000..4d6dfbbd66f8
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetAuthorizationToken.go
@@ -0,0 +1,132 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieves an authorization token. An authorization token represents your IAM
+// authentication credentials and can be used to access any Amazon ECR registry
+// that your IAM principal has access to. The authorization token is valid for 12
+// hours. The authorizationToken returned is a base64 encoded string that can be
+// decoded and used in a docker login command to authenticate to a registry. The
+// CLI offers an get-login-password command that simplifies the login process. For
+// more information, see Registry authentication
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/Registries.html#registry_auth)
+// in the Amazon Elastic Container Registry User Guide.
+func (c *Client) GetAuthorizationToken(ctx context.Context, params *GetAuthorizationTokenInput, optFns ...func(*Options)) (*GetAuthorizationTokenOutput, error) {
+ if params == nil {
+ params = &GetAuthorizationTokenInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetAuthorizationToken", params, optFns, c.addOperationGetAuthorizationTokenMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetAuthorizationTokenOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetAuthorizationTokenInput struct {
+
+ // A list of Amazon Web Services account IDs that are associated with the
+ // registries for which to get AuthorizationData objects. If you do not specify a
+ // registry, the default registry is assumed.
+ //
+ // Deprecated: This field is deprecated. The returned authorization token can be
+ // used to access any Amazon ECR registry that the IAM principal has access to,
+ // specifying a registry ID doesn't change the permissions scope of the
+ // authorization token.
+ RegistryIds []string
+
+ noSmithyDocumentSerde
+}
+
+type GetAuthorizationTokenOutput struct {
+
+ // A list of authorization token data objects that correspond to the registryIds
+ // values in the request.
+ AuthorizationData []types.AuthorizationData
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetAuthorizationTokenMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetAuthorizationToken{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetAuthorizationToken{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetAuthorizationToken(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetAuthorizationToken(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "GetAuthorizationToken",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetDownloadUrlForLayer.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetDownloadUrlForLayer.go
new file mode 100644
index 000000000000..82b584fe38b2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetDownloadUrlForLayer.go
@@ -0,0 +1,138 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieves the pre-signed Amazon S3 download URL corresponding to an image layer.
+// You can only get URLs for image layers that are referenced in an image. When an
+// image is pulled, the GetDownloadUrlForLayer API is called once per image layer
+// that is not already cached. This operation is used by the Amazon ECR proxy and
+// is not generally used by customers for pulling and pushing images. In most
+// cases, you should use the docker CLI to pull, tag, and push images.
+func (c *Client) GetDownloadUrlForLayer(ctx context.Context, params *GetDownloadUrlForLayerInput, optFns ...func(*Options)) (*GetDownloadUrlForLayerOutput, error) {
+ if params == nil {
+ params = &GetDownloadUrlForLayerInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetDownloadUrlForLayer", params, optFns, c.addOperationGetDownloadUrlForLayerMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetDownloadUrlForLayerOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetDownloadUrlForLayerInput struct {
+
+ // The digest of the image layer to download.
+ //
+ // This member is required.
+ LayerDigest *string
+
+ // The name of the repository that is associated with the image layer to download.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the image layer to download. If you do not specify a registry, the default
+ // registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type GetDownloadUrlForLayerOutput struct {
+
+ // The pre-signed Amazon S3 download URL for the requested layer.
+ DownloadUrl *string
+
+ // The digest of the image layer to download.
+ LayerDigest *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetDownloadUrlForLayerMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetDownloadUrlForLayer{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetDownloadUrlForLayer{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetDownloadUrlForLayerValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetDownloadUrlForLayer(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetDownloadUrlForLayer(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "GetDownloadUrlForLayer",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetLifecyclePolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetLifecyclePolicy.go
new file mode 100644
index 000000000000..76e8a061ce6b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetLifecyclePolicy.go
@@ -0,0 +1,135 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "time"
+)
+
+// Retrieves the lifecycle policy for the specified repository.
+func (c *Client) GetLifecyclePolicy(ctx context.Context, params *GetLifecyclePolicyInput, optFns ...func(*Options)) (*GetLifecyclePolicyOutput, error) {
+ if params == nil {
+ params = &GetLifecyclePolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetLifecyclePolicy", params, optFns, c.addOperationGetLifecyclePolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetLifecyclePolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetLifecyclePolicyInput struct {
+
+ // The name of the repository.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type GetLifecyclePolicyOutput struct {
+
+ // The time stamp of the last time that the lifecycle policy was run.
+ LastEvaluatedAt *time.Time
+
+ // The JSON lifecycle policy text.
+ LifecyclePolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetLifecyclePolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetLifecyclePolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetLifecyclePolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetLifecyclePolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetLifecyclePolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetLifecyclePolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "GetLifecyclePolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetLifecyclePolicyPreview.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetLifecyclePolicyPreview.go
new file mode 100644
index 000000000000..5114fd1b06bb
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetLifecyclePolicyPreview.go
@@ -0,0 +1,463 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithytime "github.com/aws/smithy-go/time"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ smithywaiter "github.com/aws/smithy-go/waiter"
+ "github.com/jmespath/go-jmespath"
+ "time"
+)
+
+// Retrieves the results of the lifecycle policy preview request for the specified
+// repository.
+func (c *Client) GetLifecyclePolicyPreview(ctx context.Context, params *GetLifecyclePolicyPreviewInput, optFns ...func(*Options)) (*GetLifecyclePolicyPreviewOutput, error) {
+ if params == nil {
+ params = &GetLifecyclePolicyPreviewInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetLifecyclePolicyPreview", params, optFns, c.addOperationGetLifecyclePolicyPreviewMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetLifecyclePolicyPreviewOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetLifecyclePolicyPreviewInput struct {
+
+ // The name of the repository.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // An optional parameter that filters results based on image tag status and all
+ // tags, if tagged.
+ Filter *types.LifecyclePolicyPreviewFilter
+
+ // The list of imageIDs to be included.
+ ImageIds []types.ImageIdentifier
+
+ // The maximum number of repository results returned by
+ // GetLifecyclePolicyPreviewRequest in
paginated output. When this parameter is
+ // used, GetLifecyclePolicyPreviewRequest only returns
maxResults results in a
+ // single page along with a nextToken
response element. The remaining results of
+ // the initial request can be seen by sending
another
+ // GetLifecyclePolicyPreviewRequest request with the returned nextToken
value.
+ // This value can be between 1 and 1000. If this
parameter is not used, then
+ // GetLifecyclePolicyPreviewRequest returns up to
100 results and a nextToken
+ // value, if
applicable. This option cannot be used when you specify images with
+ // imageIds.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated
+ // GetLifecyclePolicyPreviewRequest request where maxResults was used and the
+ // results exceeded the value of that parameter. Pagination continues from the end
+ // of the
previous results that returned the nextToken value. This value is
null
+ // when there are no more results to return. This option cannot be used when you
+ // specify images with imageIds.
+ NextToken *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type GetLifecyclePolicyPreviewOutput struct {
+
+ // The JSON lifecycle policy text.
+ LifecyclePolicyText *string
+
+ // The nextToken value to include in a future GetLifecyclePolicyPreview request.
+ // When the results of a GetLifecyclePolicyPreview request exceed maxResults, this
+ // value can be used to retrieve the next page of results. This value is null when
+ // there are no more results to return.
+ NextToken *string
+
+ // The results of the lifecycle policy preview request.
+ PreviewResults []types.LifecyclePolicyPreviewResult
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // The status of the lifecycle policy preview request.
+ Status types.LifecyclePolicyPreviewStatus
+
+ // The list of images that is returned as a result of the action.
+ Summary *types.LifecyclePolicyPreviewSummary
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetLifecyclePolicyPreviewMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetLifecyclePolicyPreview{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetLifecyclePolicyPreview{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetLifecyclePolicyPreviewValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetLifecyclePolicyPreview(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// GetLifecyclePolicyPreviewAPIClient is a client that implements the
+// GetLifecyclePolicyPreview operation.
+type GetLifecyclePolicyPreviewAPIClient interface {
+ GetLifecyclePolicyPreview(context.Context, *GetLifecyclePolicyPreviewInput, ...func(*Options)) (*GetLifecyclePolicyPreviewOutput, error)
+}
+
+var _ GetLifecyclePolicyPreviewAPIClient = (*Client)(nil)
+
+// GetLifecyclePolicyPreviewPaginatorOptions is the paginator options for
+// GetLifecyclePolicyPreview
+type GetLifecyclePolicyPreviewPaginatorOptions struct {
+ // The maximum number of repository results returned by
+ // GetLifecyclePolicyPreviewRequest in
paginated output. When this parameter is
+ // used, GetLifecyclePolicyPreviewRequest only returns
maxResults results in a
+ // single page along with a nextToken
response element. The remaining results of
+ // the initial request can be seen by sending
another
+ // GetLifecyclePolicyPreviewRequest request with the returned nextToken
value.
+ // This value can be between 1 and 1000. If this
parameter is not used, then
+ // GetLifecyclePolicyPreviewRequest returns up to
100 results and a nextToken
+ // value, if
applicable. This option cannot be used when you specify images with
+ // imageIds.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// GetLifecyclePolicyPreviewPaginator is a paginator for GetLifecyclePolicyPreview
+type GetLifecyclePolicyPreviewPaginator struct {
+ options GetLifecyclePolicyPreviewPaginatorOptions
+ client GetLifecyclePolicyPreviewAPIClient
+ params *GetLifecyclePolicyPreviewInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewGetLifecyclePolicyPreviewPaginator returns a new
+// GetLifecyclePolicyPreviewPaginator
+func NewGetLifecyclePolicyPreviewPaginator(client GetLifecyclePolicyPreviewAPIClient, params *GetLifecyclePolicyPreviewInput, optFns ...func(*GetLifecyclePolicyPreviewPaginatorOptions)) *GetLifecyclePolicyPreviewPaginator {
+ if params == nil {
+ params = &GetLifecyclePolicyPreviewInput{}
+ }
+
+ options := GetLifecyclePolicyPreviewPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &GetLifecyclePolicyPreviewPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *GetLifecyclePolicyPreviewPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next GetLifecyclePolicyPreview page.
+func (p *GetLifecyclePolicyPreviewPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*GetLifecyclePolicyPreviewOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.GetLifecyclePolicyPreview(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+// LifecyclePolicyPreviewCompleteWaiterOptions are waiter options for
+// LifecyclePolicyPreviewCompleteWaiter
+type LifecyclePolicyPreviewCompleteWaiterOptions struct {
+
+ // Set of options to modify how an operation is invoked. These apply to all
+ // operations invoked for this client. Use functional options on operation call to
+ // modify this list for per operation behavior.
+ APIOptions []func(*middleware.Stack) error
+
+ // MinDelay is the minimum amount of time to delay between retries. If unset,
+ // LifecyclePolicyPreviewCompleteWaiter will use default minimum delay of 5
+ // seconds. Note that MinDelay must resolve to a value lesser than or equal to the
+ // MaxDelay.
+ MinDelay time.Duration
+
+ // MaxDelay is the maximum amount of time to delay between retries. If unset or set
+ // to zero, LifecyclePolicyPreviewCompleteWaiter will use default max delay of 120
+ // seconds. Note that MaxDelay must resolve to value greater than or equal to the
+ // MinDelay.
+ MaxDelay time.Duration
+
+ // LogWaitAttempts is used to enable logging for waiter retry attempts
+ LogWaitAttempts bool
+
+ // Retryable is function that can be used to override the service defined
+ // waiter-behavior based on operation output, or returned error. This function is
+ // used by the waiter to decide if a state is retryable or a terminal state. By
+ // default service-modeled logic will populate this option. This option can thus be
+ // used to define a custom waiter state with fall-back to service-modeled waiter
+ // state mutators.The function returns an error in case of a failure state. In case
+ // of retry state, this function returns a bool value of true and nil error, while
+ // in case of success it returns a bool value of false and nil error.
+ Retryable func(context.Context, *GetLifecyclePolicyPreviewInput, *GetLifecyclePolicyPreviewOutput, error) (bool, error)
+}
+
+// LifecyclePolicyPreviewCompleteWaiter defines the waiters for
+// LifecyclePolicyPreviewComplete
+type LifecyclePolicyPreviewCompleteWaiter struct {
+ client GetLifecyclePolicyPreviewAPIClient
+
+ options LifecyclePolicyPreviewCompleteWaiterOptions
+}
+
+// NewLifecyclePolicyPreviewCompleteWaiter constructs a
+// LifecyclePolicyPreviewCompleteWaiter.
+func NewLifecyclePolicyPreviewCompleteWaiter(client GetLifecyclePolicyPreviewAPIClient, optFns ...func(*LifecyclePolicyPreviewCompleteWaiterOptions)) *LifecyclePolicyPreviewCompleteWaiter {
+ options := LifecyclePolicyPreviewCompleteWaiterOptions{}
+ options.MinDelay = 5 * time.Second
+ options.MaxDelay = 120 * time.Second
+ options.Retryable = lifecyclePolicyPreviewCompleteStateRetryable
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+ return &LifecyclePolicyPreviewCompleteWaiter{
+ client: client,
+ options: options,
+ }
+}
+
+// Wait calls the waiter function for LifecyclePolicyPreviewComplete waiter. The
+// maxWaitDur is the maximum wait duration the waiter will wait. The maxWaitDur is
+// required and must be greater than zero.
+func (w *LifecyclePolicyPreviewCompleteWaiter) Wait(ctx context.Context, params *GetLifecyclePolicyPreviewInput, maxWaitDur time.Duration, optFns ...func(*LifecyclePolicyPreviewCompleteWaiterOptions)) error {
+ _, err := w.WaitForOutput(ctx, params, maxWaitDur, optFns...)
+ return err
+}
+
+// WaitForOutput calls the waiter function for LifecyclePolicyPreviewComplete
+// waiter and returns the output of the successful operation. The maxWaitDur is the
+// maximum wait duration the waiter will wait. The maxWaitDur is required and must
+// be greater than zero.
+func (w *LifecyclePolicyPreviewCompleteWaiter) WaitForOutput(ctx context.Context, params *GetLifecyclePolicyPreviewInput, maxWaitDur time.Duration, optFns ...func(*LifecyclePolicyPreviewCompleteWaiterOptions)) (*GetLifecyclePolicyPreviewOutput, error) {
+ if maxWaitDur <= 0 {
+ return nil, fmt.Errorf("maximum wait time for waiter must be greater than zero")
+ }
+
+ options := w.options
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ if options.MaxDelay <= 0 {
+ options.MaxDelay = 120 * time.Second
+ }
+
+ if options.MinDelay > options.MaxDelay {
+ return nil, fmt.Errorf("minimum waiter delay %v must be lesser than or equal to maximum waiter delay of %v.", options.MinDelay, options.MaxDelay)
+ }
+
+ ctx, cancelFn := context.WithTimeout(ctx, maxWaitDur)
+ defer cancelFn()
+
+ logger := smithywaiter.Logger{}
+ remainingTime := maxWaitDur
+
+ var attempt int64
+ for {
+
+ attempt++
+ apiOptions := options.APIOptions
+ start := time.Now()
+
+ if options.LogWaitAttempts {
+ logger.Attempt = attempt
+ apiOptions = append([]func(*middleware.Stack) error{}, options.APIOptions...)
+ apiOptions = append(apiOptions, logger.AddLogger)
+ }
+
+ out, err := w.client.GetLifecyclePolicyPreview(ctx, params, func(o *Options) {
+ o.APIOptions = append(o.APIOptions, apiOptions...)
+ })
+
+ retryable, err := options.Retryable(ctx, params, out, err)
+ if err != nil {
+ return nil, err
+ }
+ if !retryable {
+ return out, nil
+ }
+
+ remainingTime -= time.Since(start)
+ if remainingTime < options.MinDelay || remainingTime <= 0 {
+ break
+ }
+
+ // compute exponential backoff between waiter retries
+ delay, err := smithywaiter.ComputeDelay(
+ attempt, options.MinDelay, options.MaxDelay, remainingTime,
+ )
+ if err != nil {
+ return nil, fmt.Errorf("error computing waiter delay, %w", err)
+ }
+
+ remainingTime -= delay
+ // sleep for the delay amount before invoking a request
+ if err := smithytime.SleepWithContext(ctx, delay); err != nil {
+ return nil, fmt.Errorf("request cancelled while waiting, %w", err)
+ }
+ }
+ return nil, fmt.Errorf("exceeded max wait time for LifecyclePolicyPreviewComplete waiter")
+}
+
+func lifecyclePolicyPreviewCompleteStateRetryable(ctx context.Context, input *GetLifecyclePolicyPreviewInput, output *GetLifecyclePolicyPreviewOutput, err error) (bool, error) {
+
+ if err == nil {
+ pathValue, err := jmespath.Search("status", output)
+ if err != nil {
+ return false, fmt.Errorf("error evaluating waiter state: %w", err)
+ }
+
+ expectedValue := "COMPLETE"
+ value, ok := pathValue.(types.LifecyclePolicyPreviewStatus)
+ if !ok {
+ return false, fmt.Errorf("waiter comparator expected types.LifecyclePolicyPreviewStatus value, got %T", pathValue)
+ }
+
+ if string(value) == expectedValue {
+ return false, nil
+ }
+ }
+
+ if err == nil {
+ pathValue, err := jmespath.Search("status", output)
+ if err != nil {
+ return false, fmt.Errorf("error evaluating waiter state: %w", err)
+ }
+
+ expectedValue := "FAILED"
+ value, ok := pathValue.(types.LifecyclePolicyPreviewStatus)
+ if !ok {
+ return false, fmt.Errorf("waiter comparator expected types.LifecyclePolicyPreviewStatus value, got %T", pathValue)
+ }
+
+ if string(value) == expectedValue {
+ return false, fmt.Errorf("waiter state transitioned to Failure")
+ }
+ }
+
+ return true, nil
+}
+
+func newServiceMetadataMiddleware_opGetLifecyclePolicyPreview(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "GetLifecyclePolicyPreview",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRegistryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRegistryPolicy.go
new file mode 100644
index 000000000000..b9086f937b2e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRegistryPolicy.go
@@ -0,0 +1,114 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieves the permissions policy for a registry.
+func (c *Client) GetRegistryPolicy(ctx context.Context, params *GetRegistryPolicyInput, optFns ...func(*Options)) (*GetRegistryPolicyOutput, error) {
+ if params == nil {
+ params = &GetRegistryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetRegistryPolicy", params, optFns, c.addOperationGetRegistryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetRegistryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetRegistryPolicyInput struct {
+ noSmithyDocumentSerde
+}
+
+type GetRegistryPolicyOutput struct {
+
+ // The JSON text of the permissions policy for a registry.
+ PolicyText *string
+
+ // The ID of the registry.
+ RegistryId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetRegistryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetRegistryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetRegistryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetRegistryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetRegistryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "GetRegistryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRegistryScanningConfiguration.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRegistryScanningConfiguration.go
new file mode 100644
index 000000000000..07f5e4dc3acc
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRegistryScanningConfiguration.go
@@ -0,0 +1,115 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieves the scanning configuration for a registry.
+func (c *Client) GetRegistryScanningConfiguration(ctx context.Context, params *GetRegistryScanningConfigurationInput, optFns ...func(*Options)) (*GetRegistryScanningConfigurationOutput, error) {
+ if params == nil {
+ params = &GetRegistryScanningConfigurationInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetRegistryScanningConfiguration", params, optFns, c.addOperationGetRegistryScanningConfigurationMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetRegistryScanningConfigurationOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetRegistryScanningConfigurationInput struct {
+ noSmithyDocumentSerde
+}
+
+type GetRegistryScanningConfigurationOutput struct {
+
+ // The ID of the registry.
+ RegistryId *string
+
+ // The scanning configuration for the registry.
+ ScanningConfiguration *types.RegistryScanningConfiguration
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetRegistryScanningConfigurationMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetRegistryScanningConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetRegistryScanningConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetRegistryScanningConfiguration(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetRegistryScanningConfiguration(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "GetRegistryScanningConfiguration",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRepositoryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRepositoryPolicy.go
new file mode 100644
index 000000000000..15a292ad6b3b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_GetRepositoryPolicy.go
@@ -0,0 +1,131 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieves the repository policy for the specified repository.
+func (c *Client) GetRepositoryPolicy(ctx context.Context, params *GetRepositoryPolicyInput, optFns ...func(*Options)) (*GetRepositoryPolicyOutput, error) {
+ if params == nil {
+ params = &GetRepositoryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetRepositoryPolicy", params, optFns, c.addOperationGetRepositoryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetRepositoryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetRepositoryPolicyInput struct {
+
+ // The name of the repository with the policy to retrieve.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type GetRepositoryPolicyOutput struct {
+
+ // The JSON repository policy text associated with the repository.
+ PolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetRepositoryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetRepositoryPolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetRepositoryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetRepositoryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "GetRepositoryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_InitiateLayerUpload.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_InitiateLayerUpload.go
new file mode 100644
index 000000000000..d700d833f1ee
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_InitiateLayerUpload.go
@@ -0,0 +1,135 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Notifies Amazon ECR that you intend to upload an image layer. When an image is
+// pushed, the InitiateLayerUpload API is called once per image layer that has not
+// already been uploaded. Whether or not an image layer has been uploaded is
+// determined by the BatchCheckLayerAvailability API action. This operation is used
+// by the Amazon ECR proxy and is not generally used by customers for pulling and
+// pushing images. In most cases, you should use the docker CLI to pull, tag, and
+// push images.
+func (c *Client) InitiateLayerUpload(ctx context.Context, params *InitiateLayerUploadInput, optFns ...func(*Options)) (*InitiateLayerUploadOutput, error) {
+ if params == nil {
+ params = &InitiateLayerUploadInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "InitiateLayerUpload", params, optFns, c.addOperationInitiateLayerUploadMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*InitiateLayerUploadOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type InitiateLayerUploadInput struct {
+
+ // The name of the repository to which you intend to upload layers.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry to which you
+ // intend to upload layers. If you do not specify a registry, the default registry
+ // is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type InitiateLayerUploadOutput struct {
+
+ // The size, in bytes, that Amazon ECR expects future layer part uploads to be.
+ PartSize *int64
+
+ // The upload ID for the layer upload. This parameter is passed to further
+ // UploadLayerPart and CompleteLayerUpload operations.
+ UploadId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationInitiateLayerUploadMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpInitiateLayerUpload{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpInitiateLayerUpload{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpInitiateLayerUploadValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opInitiateLayerUpload(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opInitiateLayerUpload(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "InitiateLayerUpload",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_ListImages.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_ListImages.go
new file mode 100644
index 000000000000..b3d096d5b764
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_ListImages.go
@@ -0,0 +1,253 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Lists all the image IDs for the specified repository. You can filter images
+// based on whether or not they are tagged by using the tagStatus filter and
+// specifying either TAGGED, UNTAGGED or ANY. For example, you can filter your
+// results to return only UNTAGGED images and then pipe that result to a
+// BatchDeleteImage operation to delete them. Or, you can filter your results to
+// return only TAGGED images to list all of the tags in your repository.
+func (c *Client) ListImages(ctx context.Context, params *ListImagesInput, optFns ...func(*Options)) (*ListImagesOutput, error) {
+ if params == nil {
+ params = &ListImagesInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "ListImages", params, optFns, c.addOperationListImagesMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*ListImagesOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type ListImagesInput struct {
+
+ // The repository with image IDs to be listed.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The filter key and value with which to filter your ListImages results.
+ Filter *types.ListImagesFilter
+
+ // The maximum number of image results returned by ListImages in paginated output.
+ // When this parameter is used, ListImages only returns maxResults results in a
+ // single page along with a nextToken response element. The remaining results of
+ // the initial request can be seen by sending another ListImages request with the
+ // returned nextToken value. This value can be between 1 and 1000. If this
+ // parameter is not used, then ListImages returns up to 100 results and a nextToken
+ // value, if applicable.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated ListImages request where
+ // maxResults was used and the results exceeded the value of that parameter.
+ // Pagination continues from the end of the previous results that returned the
+ // nextToken value. This value is null when there are no more results to return.
+ // This token should be treated as an opaque identifier that is only used to
+ // retrieve the next items in a list and not for other programmatic purposes.
+ NextToken *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository in which to list images. If you do not specify a registry, the
+ // default registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type ListImagesOutput struct {
+
+ // The list of image IDs for the requested repository.
+ ImageIds []types.ImageIdentifier
+
+ // The nextToken value to include in a future ListImages request. When the results
+ // of a ListImages request exceed maxResults, this value can be used to retrieve
+ // the next page of results. This value is null when there are no more results to
+ // return.
+ NextToken *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationListImagesMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpListImages{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpListImages{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpListImagesValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListImages(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// ListImagesAPIClient is a client that implements the ListImages operation.
+type ListImagesAPIClient interface {
+ ListImages(context.Context, *ListImagesInput, ...func(*Options)) (*ListImagesOutput, error)
+}
+
+var _ ListImagesAPIClient = (*Client)(nil)
+
+// ListImagesPaginatorOptions is the paginator options for ListImages
+type ListImagesPaginatorOptions struct {
+ // The maximum number of image results returned by ListImages in paginated output.
+ // When this parameter is used, ListImages only returns maxResults results in a
+ // single page along with a nextToken response element. The remaining results of
+ // the initial request can be seen by sending another ListImages request with the
+ // returned nextToken value. This value can be between 1 and 1000. If this
+ // parameter is not used, then ListImages returns up to 100 results and a nextToken
+ // value, if applicable.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// ListImagesPaginator is a paginator for ListImages
+type ListImagesPaginator struct {
+ options ListImagesPaginatorOptions
+ client ListImagesAPIClient
+ params *ListImagesInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewListImagesPaginator returns a new ListImagesPaginator
+func NewListImagesPaginator(client ListImagesAPIClient, params *ListImagesInput, optFns ...func(*ListImagesPaginatorOptions)) *ListImagesPaginator {
+ if params == nil {
+ params = &ListImagesInput{}
+ }
+
+ options := ListImagesPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &ListImagesPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *ListImagesPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next ListImages page.
+func (p *ListImagesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListImagesOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.ListImages(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opListImages(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "ListImages",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_ListTagsForResource.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_ListTagsForResource.go
new file mode 100644
index 000000000000..91a372fe51c5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_ListTagsForResource.go
@@ -0,0 +1,122 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// List the tags for an Amazon ECR resource.
+func (c *Client) ListTagsForResource(ctx context.Context, params *ListTagsForResourceInput, optFns ...func(*Options)) (*ListTagsForResourceOutput, error) {
+ if params == nil {
+ params = &ListTagsForResourceInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "ListTagsForResource", params, optFns, c.addOperationListTagsForResourceMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*ListTagsForResourceOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type ListTagsForResourceInput struct {
+
+ // The Amazon Resource Name (ARN) that identifies the resource for which to list
+ // the tags. Currently, the only supported resource is an Amazon ECR repository.
+ //
+ // This member is required.
+ ResourceArn *string
+
+ noSmithyDocumentSerde
+}
+
+type ListTagsForResourceOutput struct {
+
+ // The tags for the resource.
+ Tags []types.Tag
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationListTagsForResourceMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpListTagsForResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpListTagsForResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpListTagsForResourceValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListTagsForResource(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opListTagsForResource(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "ListTagsForResource",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImage.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImage.go
new file mode 100644
index 000000000000..631a9b408c57
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImage.go
@@ -0,0 +1,149 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates or updates the image manifest and tags associated with an image. When an
+// image is pushed and all new image layers have been uploaded, the PutImage API is
+// called once to create or update the image manifest and the tags associated with
+// the image. This operation is used by the Amazon ECR proxy and is not generally
+// used by customers for pulling and pushing images. In most cases, you should use
+// the docker CLI to pull, tag, and push images.
+func (c *Client) PutImage(ctx context.Context, params *PutImageInput, optFns ...func(*Options)) (*PutImageOutput, error) {
+ if params == nil {
+ params = &PutImageInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutImage", params, optFns, c.addOperationPutImageMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutImageOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutImageInput struct {
+
+ // The image manifest corresponding to the image to be uploaded.
+ //
+ // This member is required.
+ ImageManifest *string
+
+ // The name of the repository in which to put the image.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The image digest of the image manifest corresponding to the image.
+ ImageDigest *string
+
+ // The media type of the image manifest. If you push an image manifest that does
+ // not contain the mediaType field, you must specify the imageManifestMediaType in
+ // the request.
+ ImageManifestMediaType *string
+
+ // The tag to associate with the image. This parameter is required for images that
+ // use the Docker Image Manifest V2 Schema 2 or Open Container Initiative (OCI)
+ // formats.
+ ImageTag *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository in which to put the image. If you do not specify a registry, the
+ // default registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type PutImageOutput struct {
+
+ // Details of the image uploaded.
+ Image *types.Image
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutImageMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutImageValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutImage(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutImage(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "PutImage",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImageScanningConfiguration.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImageScanningConfiguration.go
new file mode 100644
index 000000000000..0d92e0b6ba24
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImageScanningConfiguration.go
@@ -0,0 +1,140 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Updates the image scanning configuration for the specified repository.
+func (c *Client) PutImageScanningConfiguration(ctx context.Context, params *PutImageScanningConfigurationInput, optFns ...func(*Options)) (*PutImageScanningConfigurationOutput, error) {
+ if params == nil {
+ params = &PutImageScanningConfigurationInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutImageScanningConfiguration", params, optFns, c.addOperationPutImageScanningConfigurationMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutImageScanningConfigurationOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutImageScanningConfigurationInput struct {
+
+ // The image scanning configuration for the repository. This setting determines
+ // whether images are scanned for known vulnerabilities after being pushed to the
+ // repository.
+ //
+ // This member is required.
+ ImageScanningConfiguration *types.ImageScanningConfiguration
+
+ // The name of the repository in which to update the image scanning configuration
+ // setting.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository in which to update the image scanning configuration setting. If
+ // you do not specify a registry, the default registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type PutImageScanningConfigurationOutput struct {
+
+ // The image scanning configuration setting for the repository.
+ ImageScanningConfiguration *types.ImageScanningConfiguration
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutImageScanningConfigurationMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutImageScanningConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutImageScanningConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutImageScanningConfigurationValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutImageScanningConfiguration(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutImageScanningConfiguration(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "PutImageScanningConfiguration",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImageTagMutability.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImageTagMutability.go
new file mode 100644
index 000000000000..5e42488a1ad0
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutImageTagMutability.go
@@ -0,0 +1,142 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Updates the image tag mutability settings for the specified repository. For more
+// information, see Image tag mutability
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/image-tag-mutability.html)
+// in the Amazon Elastic Container Registry User Guide.
+func (c *Client) PutImageTagMutability(ctx context.Context, params *PutImageTagMutabilityInput, optFns ...func(*Options)) (*PutImageTagMutabilityOutput, error) {
+ if params == nil {
+ params = &PutImageTagMutabilityInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutImageTagMutability", params, optFns, c.addOperationPutImageTagMutabilityMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutImageTagMutabilityOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutImageTagMutabilityInput struct {
+
+ // The tag mutability setting for the repository. If MUTABLE is specified, image
+ // tags can be overwritten. If IMMUTABLE is specified, all image tags within the
+ // repository will be immutable which will prevent them from being overwritten.
+ //
+ // This member is required.
+ ImageTagMutability types.ImageTagMutability
+
+ // The name of the repository in which to update the image tag mutability settings.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository in which to update the image tag mutability settings. If you do
+ // not specify a registry, the default registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type PutImageTagMutabilityOutput struct {
+
+ // The image tag mutability setting for the repository.
+ ImageTagMutability types.ImageTagMutability
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutImageTagMutabilityMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutImageTagMutability{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutImageTagMutability{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutImageTagMutabilityValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutImageTagMutability(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutImageTagMutability(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "PutImageTagMutability",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutLifecyclePolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutLifecyclePolicy.go
new file mode 100644
index 000000000000..782382eefe67
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutLifecyclePolicy.go
@@ -0,0 +1,138 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates or updates the lifecycle policy for the specified repository. For more
+// information, see Lifecycle policy template
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/LifecyclePolicies.html).
+func (c *Client) PutLifecyclePolicy(ctx context.Context, params *PutLifecyclePolicyInput, optFns ...func(*Options)) (*PutLifecyclePolicyOutput, error) {
+ if params == nil {
+ params = &PutLifecyclePolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutLifecyclePolicy", params, optFns, c.addOperationPutLifecyclePolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutLifecyclePolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutLifecyclePolicyInput struct {
+
+ // The JSON repository policy text to apply to the repository.
+ //
+ // This member is required.
+ LifecyclePolicyText *string
+
+ // The name of the repository to receive the policy.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository. If you do
not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type PutLifecyclePolicyOutput struct {
+
+ // The JSON repository policy text.
+ LifecyclePolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutLifecyclePolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutLifecyclePolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutLifecyclePolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutLifecyclePolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutLifecyclePolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutLifecyclePolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "PutLifecyclePolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutRegistryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutRegistryPolicy.go
new file mode 100644
index 000000000000..b253e0e0fcc5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutRegistryPolicy.go
@@ -0,0 +1,131 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates or updates the permissions policy for your registry. A registry policy
+// is used to specify permissions for another Amazon Web Services account and is
+// used when configuring cross-account replication. For more information, see
+// Registry permissions
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/registry-permissions.html)
+// in the Amazon Elastic Container Registry User Guide.
+func (c *Client) PutRegistryPolicy(ctx context.Context, params *PutRegistryPolicyInput, optFns ...func(*Options)) (*PutRegistryPolicyOutput, error) {
+ if params == nil {
+ params = &PutRegistryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutRegistryPolicy", params, optFns, c.addOperationPutRegistryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutRegistryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutRegistryPolicyInput struct {
+
+ // The JSON policy text to apply to your registry. The policy text follows the same
+ // format as IAM policy text. For more information, see Registry permissions
+ // (https://docs.aws.amazon.com/AmazonECR/latest/userguide/registry-permissions.html)
+ // in the Amazon Elastic Container Registry User Guide.
+ //
+ // This member is required.
+ PolicyText *string
+
+ noSmithyDocumentSerde
+}
+
+type PutRegistryPolicyOutput struct {
+
+ // The JSON policy text for your registry.
+ PolicyText *string
+
+ // The registry ID.
+ RegistryId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutRegistryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutRegistryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutRegistryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutRegistryPolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutRegistryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutRegistryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "PutRegistryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutRegistryScanningConfiguration.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutRegistryScanningConfiguration.go
new file mode 100644
index 000000000000..51a0d66ca59d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutRegistryScanningConfiguration.go
@@ -0,0 +1,128 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates or updates the scanning configuration for your private registry.
+func (c *Client) PutRegistryScanningConfiguration(ctx context.Context, params *PutRegistryScanningConfigurationInput, optFns ...func(*Options)) (*PutRegistryScanningConfigurationOutput, error) {
+ if params == nil {
+ params = &PutRegistryScanningConfigurationInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutRegistryScanningConfiguration", params, optFns, c.addOperationPutRegistryScanningConfigurationMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutRegistryScanningConfigurationOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutRegistryScanningConfigurationInput struct {
+
+ // The scanning rules to use for the registry. A scanning rule is used to determine
+ // which repository filters are used and at what frequency scanning will occur.
+ Rules []types.RegistryScanningRule
+
+ // The scanning type to set for the registry. By default, the BASIC scan type is
+ // used. When basic scanning is set, you may specify filters to determine which
+ // individual repositories, or all repositories, are scanned when new images are
+ // pushed. Alternatively, you can do manual scans of images with basic scanning.
+ // When the ENHANCED scan type is set, Amazon Inspector provides automated,
+ // continuous scanning of all repositories in your registry.
+ ScanType types.ScanType
+
+ noSmithyDocumentSerde
+}
+
+type PutRegistryScanningConfigurationOutput struct {
+
+ // The scanning configuration for your registry.
+ RegistryScanningConfiguration *types.RegistryScanningConfiguration
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutRegistryScanningConfigurationMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutRegistryScanningConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutRegistryScanningConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutRegistryScanningConfigurationValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutRegistryScanningConfiguration(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutRegistryScanningConfiguration(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "PutRegistryScanningConfiguration",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutReplicationConfiguration.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutReplicationConfiguration.go
new file mode 100644
index 000000000000..e8e84df6eb0a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_PutReplicationConfiguration.go
@@ -0,0 +1,131 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates or updates the replication configuration for a registry. The existing
+// replication configuration for a repository can be retrieved with the
+// DescribeRegistry API action. The first time the PutReplicationConfiguration API
+// is called, a service-linked IAM role is created in your account for the
+// replication process. For more information, see Using service-linked roles for
+// Amazon ECR
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/using-service-linked-roles.html)
+// in the Amazon Elastic Container Registry User Guide. When configuring
+// cross-account replication, the destination account must grant the source account
+// permission to replicate. This permission is controlled using a registry
+// permissions policy. For more information, see PutRegistryPolicy.
+func (c *Client) PutReplicationConfiguration(ctx context.Context, params *PutReplicationConfigurationInput, optFns ...func(*Options)) (*PutReplicationConfigurationOutput, error) {
+ if params == nil {
+ params = &PutReplicationConfigurationInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutReplicationConfiguration", params, optFns, c.addOperationPutReplicationConfigurationMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutReplicationConfigurationOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutReplicationConfigurationInput struct {
+
+ // An object representing the replication configuration for a registry.
+ //
+ // This member is required.
+ ReplicationConfiguration *types.ReplicationConfiguration
+
+ noSmithyDocumentSerde
+}
+
+type PutReplicationConfigurationOutput struct {
+
+ // The contents of the replication configuration for the registry.
+ ReplicationConfiguration *types.ReplicationConfiguration
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutReplicationConfigurationMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutReplicationConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutReplicationConfiguration{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutReplicationConfigurationValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutReplicationConfiguration(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutReplicationConfiguration(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "PutReplicationConfiguration",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_SetRepositoryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_SetRepositoryPolicy.go
new file mode 100644
index 000000000000..1078970c70c5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_SetRepositoryPolicy.go
@@ -0,0 +1,148 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Applies a repository policy to the specified repository to control access
+// permissions. For more information, see Amazon ECR Repository policies
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/repository-policies.html)
+// in the Amazon Elastic Container Registry User Guide.
+func (c *Client) SetRepositoryPolicy(ctx context.Context, params *SetRepositoryPolicyInput, optFns ...func(*Options)) (*SetRepositoryPolicyOutput, error) {
+ if params == nil {
+ params = &SetRepositoryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "SetRepositoryPolicy", params, optFns, c.addOperationSetRepositoryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*SetRepositoryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type SetRepositoryPolicyInput struct {
+
+ // The JSON repository policy text to apply to the repository. For more
+ // information, see Amazon ECR repository policies
+ // (https://docs.aws.amazon.com/AmazonECR/latest/userguide/repository-policy-examples.html)
+ // in the Amazon Elastic Container Registry User Guide.
+ //
+ // This member is required.
+ PolicyText *string
+
+ // The name of the repository to receive the policy.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // If the policy you are attempting to set on a repository policy would prevent you
+ // from setting another policy in the future, you must force the
+ // SetRepositoryPolicy operation. This is intended to prevent accidental repository
+ // lock outs.
+ Force bool
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type SetRepositoryPolicyOutput struct {
+
+ // The JSON repository policy text applied to the repository.
+ PolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationSetRepositoryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpSetRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpSetRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpSetRepositoryPolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opSetRepositoryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opSetRepositoryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "SetRepositoryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_StartImageScan.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_StartImageScan.go
new file mode 100644
index 000000000000..8a9785f49b41
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_StartImageScan.go
@@ -0,0 +1,144 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Starts an image vulnerability scan. An image scan can only be started once per
+// 24 hours on an individual image. This limit includes if an image was scanned on
+// initial push. For more information, see Image scanning
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/image-scanning.html) in
+// the Amazon Elastic Container Registry User Guide.
+func (c *Client) StartImageScan(ctx context.Context, params *StartImageScanInput, optFns ...func(*Options)) (*StartImageScanOutput, error) {
+ if params == nil {
+ params = &StartImageScanInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "StartImageScan", params, optFns, c.addOperationStartImageScanMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*StartImageScanOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type StartImageScanInput struct {
+
+ // An object with identifying information for an image in an Amazon ECR repository.
+ //
+ // This member is required.
+ ImageId *types.ImageIdentifier
+
+ // The name of the repository that contains the images to scan.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository in which to start an image scan request. If you do not specify a
+ // registry, the default registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type StartImageScanOutput struct {
+
+ // An object with identifying information for an image in an Amazon ECR repository.
+ ImageId *types.ImageIdentifier
+
+ // The current state of the scan.
+ ImageScanStatus *types.ImageScanStatus
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationStartImageScanMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpStartImageScan{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpStartImageScan{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpStartImageScanValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opStartImageScan(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opStartImageScan(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "StartImageScan",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_StartLifecyclePolicyPreview.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_StartLifecyclePolicyPreview.go
new file mode 100644
index 000000000000..1169ac4432a4
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_StartLifecyclePolicyPreview.go
@@ -0,0 +1,141 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Starts a preview of a lifecycle policy for the specified repository. This allows
+// you to see the results before associating the lifecycle policy with the
+// repository.
+func (c *Client) StartLifecyclePolicyPreview(ctx context.Context, params *StartLifecyclePolicyPreviewInput, optFns ...func(*Options)) (*StartLifecyclePolicyPreviewOutput, error) {
+ if params == nil {
+ params = &StartLifecyclePolicyPreviewInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "StartLifecyclePolicyPreview", params, optFns, c.addOperationStartLifecyclePolicyPreviewMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*StartLifecyclePolicyPreviewOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type StartLifecyclePolicyPreviewInput struct {
+
+ // The name of the repository to be evaluated.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The policy to be evaluated against. If you do not specify a policy, the current
+ // policy for the repository is used.
+ LifecyclePolicyText *string
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type StartLifecyclePolicyPreviewOutput struct {
+
+ // The JSON repository policy text.
+ LifecyclePolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // The status of the lifecycle policy preview request.
+ Status types.LifecyclePolicyPreviewStatus
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationStartLifecyclePolicyPreviewMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpStartLifecyclePolicyPreview{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpStartLifecyclePolicyPreview{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpStartLifecyclePolicyPreviewValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opStartLifecyclePolicyPreview(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opStartLifecyclePolicyPreview(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "StartLifecyclePolicyPreview",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_TagResource.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_TagResource.go
new file mode 100644
index 000000000000..d283acf67009
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_TagResource.go
@@ -0,0 +1,126 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Adds specified tags to a resource with the specified ARN. Existing tags on a
+// resource are not changed if they are not specified in the request parameters.
+func (c *Client) TagResource(ctx context.Context, params *TagResourceInput, optFns ...func(*Options)) (*TagResourceOutput, error) {
+ if params == nil {
+ params = &TagResourceInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "TagResource", params, optFns, c.addOperationTagResourceMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*TagResourceOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type TagResourceInput struct {
+
+ // The Amazon Resource Name (ARN) of the the resource to which to add tags.
+ // Currently, the only supported resource is an Amazon ECR repository.
+ //
+ // This member is required.
+ ResourceArn *string
+
+ // The tags to add to the resource. A tag is an array of key-value pairs. Tag keys
+ // can have a maximum character length of 128 characters, and tag values can have a
+ // maximum length of 256 characters.
+ //
+ // This member is required.
+ Tags []types.Tag
+
+ noSmithyDocumentSerde
+}
+
+type TagResourceOutput struct {
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationTagResourceMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpTagResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpTagResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpTagResourceValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opTagResource(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opTagResource(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "TagResource",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_UntagResource.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_UntagResource.go
new file mode 100644
index 000000000000..e42275bde19a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_UntagResource.go
@@ -0,0 +1,122 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes specified tags from a resource.
+func (c *Client) UntagResource(ctx context.Context, params *UntagResourceInput, optFns ...func(*Options)) (*UntagResourceOutput, error) {
+ if params == nil {
+ params = &UntagResourceInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "UntagResource", params, optFns, c.addOperationUntagResourceMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*UntagResourceOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type UntagResourceInput struct {
+
+ // The Amazon Resource Name (ARN) of the resource from which to remove tags.
+ // Currently, the only supported resource is an Amazon ECR repository.
+ //
+ // This member is required.
+ ResourceArn *string
+
+ // The keys of the tags to be removed.
+ //
+ // This member is required.
+ TagKeys []string
+
+ noSmithyDocumentSerde
+}
+
+type UntagResourceOutput struct {
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationUntagResourceMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpUntagResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpUntagResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpUntagResourceValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opUntagResource(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opUntagResource(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "UntagResource",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_UploadLayerPart.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_UploadLayerPart.go
new file mode 100644
index 000000000000..4acf7e5b0ccc
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/api_op_UploadLayerPart.go
@@ -0,0 +1,160 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Uploads an image layer part to Amazon ECR. When an image is pushed, each new
+// image layer is uploaded in parts. The maximum size of each image layer part can
+// be 20971520 bytes (or about 20MB). The UploadLayerPart API is called once per
+// each new image layer part. This operation is used by the Amazon ECR proxy and is
+// not generally used by customers for pulling and pushing images. In most cases,
+// you should use the docker CLI to pull, tag, and push images.
+func (c *Client) UploadLayerPart(ctx context.Context, params *UploadLayerPartInput, optFns ...func(*Options)) (*UploadLayerPartOutput, error) {
+ if params == nil {
+ params = &UploadLayerPartInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "UploadLayerPart", params, optFns, c.addOperationUploadLayerPartMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*UploadLayerPartOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type UploadLayerPartInput struct {
+
+ // The base64-encoded layer part payload.
+ //
+ // This member is required.
+ LayerPartBlob []byte
+
+ // The position of the first byte of the layer part witin the overall image layer.
+ //
+ // This member is required.
+ PartFirstByte *int64
+
+ // The position of the last byte of the layer part within the overall image layer.
+ //
+ // This member is required.
+ PartLastByte *int64
+
+ // The name of the repository to which you are uploading layer parts.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The upload ID from a previous InitiateLayerUpload operation to associate with
+ // the layer part upload.
+ //
+ // This member is required.
+ UploadId *string
+
+ // The Amazon Web Services account ID associated with the registry to which you are
+ // uploading layer parts. If you do not specify a registry, the default registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type UploadLayerPartOutput struct {
+
+ // The integer value of the last byte received in the request.
+ LastByteReceived *int64
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // The upload ID associated with the request.
+ UploadId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationUploadLayerPartMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpUploadLayerPart{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpUploadLayerPart{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpUploadLayerPartValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opUploadLayerPart(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opUploadLayerPart(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr",
+ OperationName: "UploadLayerPart",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/deserializers.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/deserializers.go
new file mode 100644
index 000000000000..2963e2b6762a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/deserializers.go
@@ -0,0 +1,13496 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "bytes"
+ "context"
+ "encoding/json"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/aws/protocol/restjson"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ smithy "github.com/aws/smithy-go"
+ smithyio "github.com/aws/smithy-go/io"
+ "github.com/aws/smithy-go/middleware"
+ "github.com/aws/smithy-go/ptr"
+ smithytime "github.com/aws/smithy-go/time"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "io"
+ "math"
+ "strings"
+)
+
+type awsAwsjson11_deserializeOpBatchCheckLayerAvailability struct {
+}
+
+func (*awsAwsjson11_deserializeOpBatchCheckLayerAvailability) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpBatchCheckLayerAvailability) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorBatchCheckLayerAvailability(response, &metadata)
+ }
+ output := &BatchCheckLayerAvailabilityOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentBatchCheckLayerAvailabilityOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorBatchCheckLayerAvailability(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpBatchDeleteImage struct {
+}
+
+func (*awsAwsjson11_deserializeOpBatchDeleteImage) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpBatchDeleteImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorBatchDeleteImage(response, &metadata)
+ }
+ output := &BatchDeleteImageOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentBatchDeleteImageOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorBatchDeleteImage(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpBatchGetImage struct {
+}
+
+func (*awsAwsjson11_deserializeOpBatchGetImage) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpBatchGetImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorBatchGetImage(response, &metadata)
+ }
+ output := &BatchGetImageOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentBatchGetImageOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorBatchGetImage(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpBatchGetRepositoryScanningConfiguration struct {
+}
+
+func (*awsAwsjson11_deserializeOpBatchGetRepositoryScanningConfiguration) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpBatchGetRepositoryScanningConfiguration) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorBatchGetRepositoryScanningConfiguration(response, &metadata)
+ }
+ output := &BatchGetRepositoryScanningConfigurationOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentBatchGetRepositoryScanningConfigurationOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorBatchGetRepositoryScanningConfiguration(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpCompleteLayerUpload struct {
+}
+
+func (*awsAwsjson11_deserializeOpCompleteLayerUpload) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpCompleteLayerUpload) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorCompleteLayerUpload(response, &metadata)
+ }
+ output := &CompleteLayerUploadOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentCompleteLayerUploadOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorCompleteLayerUpload(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("EmptyUploadException", errorCode):
+ return awsAwsjson11_deserializeErrorEmptyUploadException(response, errorBody)
+
+ case strings.EqualFold("InvalidLayerException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidLayerException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("KmsException", errorCode):
+ return awsAwsjson11_deserializeErrorKmsException(response, errorBody)
+
+ case strings.EqualFold("LayerAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorLayerAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("LayerPartTooSmallException", errorCode):
+ return awsAwsjson11_deserializeErrorLayerPartTooSmallException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UploadNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorUploadNotFoundException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpCreatePullThroughCacheRule struct {
+}
+
+func (*awsAwsjson11_deserializeOpCreatePullThroughCacheRule) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpCreatePullThroughCacheRule) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorCreatePullThroughCacheRule(response, &metadata)
+ }
+ output := &CreatePullThroughCacheRuleOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentCreatePullThroughCacheRuleOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorCreatePullThroughCacheRule(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LimitExceededException", errorCode):
+ return awsAwsjson11_deserializeErrorLimitExceededException(response, errorBody)
+
+ case strings.EqualFold("PullThroughCacheRuleAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorPullThroughCacheRuleAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedUpstreamRegistryException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedUpstreamRegistryException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpCreateRepository struct {
+}
+
+func (*awsAwsjson11_deserializeOpCreateRepository) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpCreateRepository) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorCreateRepository(response, &metadata)
+ }
+ output := &CreateRepositoryOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentCreateRepositoryOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorCreateRepository(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("InvalidTagParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidTagParameterException(response, errorBody)
+
+ case strings.EqualFold("KmsException", errorCode):
+ return awsAwsjson11_deserializeErrorKmsException(response, errorBody)
+
+ case strings.EqualFold("LimitExceededException", errorCode):
+ return awsAwsjson11_deserializeErrorLimitExceededException(response, errorBody)
+
+ case strings.EqualFold("RepositoryAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("TooManyTagsException", errorCode):
+ return awsAwsjson11_deserializeErrorTooManyTagsException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDeleteLifecyclePolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpDeleteLifecyclePolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDeleteLifecyclePolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDeleteLifecyclePolicy(response, &metadata)
+ }
+ output := &DeleteLifecyclePolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDeleteLifecyclePolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDeleteLifecyclePolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LifecyclePolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorLifecyclePolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDeletePullThroughCacheRule struct {
+}
+
+func (*awsAwsjson11_deserializeOpDeletePullThroughCacheRule) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDeletePullThroughCacheRule) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDeletePullThroughCacheRule(response, &metadata)
+ }
+ output := &DeletePullThroughCacheRuleOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDeletePullThroughCacheRuleOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDeletePullThroughCacheRule(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("PullThroughCacheRuleNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorPullThroughCacheRuleNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDeleteRegistryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpDeleteRegistryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDeleteRegistryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDeleteRegistryPolicy(response, &metadata)
+ }
+ output := &DeleteRegistryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDeleteRegistryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDeleteRegistryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RegistryPolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRegistryPolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDeleteRepository struct {
+}
+
+func (*awsAwsjson11_deserializeOpDeleteRepository) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDeleteRepository) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDeleteRepository(response, &metadata)
+ }
+ output := &DeleteRepositoryOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDeleteRepositoryOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDeleteRepository(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("KmsException", errorCode):
+ return awsAwsjson11_deserializeErrorKmsException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotEmptyException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotEmptyException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDeleteRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpDeleteRepositoryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDeleteRepositoryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDeleteRepositoryPolicy(response, &metadata)
+ }
+ output := &DeleteRepositoryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDeleteRepositoryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDeleteRepositoryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryPolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryPolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeImageReplicationStatus struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeImageReplicationStatus) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeImageReplicationStatus) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeImageReplicationStatus(response, &metadata)
+ }
+ output := &DescribeImageReplicationStatusOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeImageReplicationStatusOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeImageReplicationStatus(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("ImageNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorImageNotFoundException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeImages struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeImages) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeImages) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeImages(response, &metadata)
+ }
+ output := &DescribeImagesOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeImagesOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeImages(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("ImageNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorImageNotFoundException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeImageScanFindings struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeImageScanFindings) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeImageScanFindings) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeImageScanFindings(response, &metadata)
+ }
+ output := &DescribeImageScanFindingsOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeImageScanFindingsOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeImageScanFindings(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("ImageNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorImageNotFoundException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ScanNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorScanNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribePullThroughCacheRules struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribePullThroughCacheRules) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribePullThroughCacheRules) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribePullThroughCacheRules(response, &metadata)
+ }
+ output := &DescribePullThroughCacheRulesOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribePullThroughCacheRulesOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribePullThroughCacheRules(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("PullThroughCacheRuleNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorPullThroughCacheRuleNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeRegistry struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeRegistry) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeRegistry) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeRegistry(response, &metadata)
+ }
+ output := &DescribeRegistryOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeRegistryOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeRegistry(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeRepositories struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeRepositories) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeRepositories) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeRepositories(response, &metadata)
+ }
+ output := &DescribeRepositoriesOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeRepositoriesOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeRepositories(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetAuthorizationToken struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetAuthorizationToken) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetAuthorizationToken) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetAuthorizationToken(response, &metadata)
+ }
+ output := &GetAuthorizationTokenOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetAuthorizationTokenOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetAuthorizationToken(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetDownloadUrlForLayer struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetDownloadUrlForLayer) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetDownloadUrlForLayer) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetDownloadUrlForLayer(response, &metadata)
+ }
+ output := &GetDownloadUrlForLayerOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetDownloadUrlForLayerOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetDownloadUrlForLayer(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LayerInaccessibleException", errorCode):
+ return awsAwsjson11_deserializeErrorLayerInaccessibleException(response, errorBody)
+
+ case strings.EqualFold("LayersNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorLayersNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetLifecyclePolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetLifecyclePolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetLifecyclePolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetLifecyclePolicy(response, &metadata)
+ }
+ output := &GetLifecyclePolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetLifecyclePolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetLifecyclePolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LifecyclePolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorLifecyclePolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetLifecyclePolicyPreview struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetLifecyclePolicyPreview) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetLifecyclePolicyPreview) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetLifecyclePolicyPreview(response, &metadata)
+ }
+ output := &GetLifecyclePolicyPreviewOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetLifecyclePolicyPreviewOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetLifecyclePolicyPreview(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LifecyclePolicyPreviewNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorLifecyclePolicyPreviewNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetRegistryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetRegistryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetRegistryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetRegistryPolicy(response, &metadata)
+ }
+ output := &GetRegistryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetRegistryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetRegistryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RegistryPolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRegistryPolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetRegistryScanningConfiguration struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetRegistryScanningConfiguration) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetRegistryScanningConfiguration) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetRegistryScanningConfiguration(response, &metadata)
+ }
+ output := &GetRegistryScanningConfigurationOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetRegistryScanningConfigurationOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetRegistryScanningConfiguration(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetRepositoryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetRepositoryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetRepositoryPolicy(response, &metadata)
+ }
+ output := &GetRepositoryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetRepositoryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetRepositoryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryPolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryPolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpInitiateLayerUpload struct {
+}
+
+func (*awsAwsjson11_deserializeOpInitiateLayerUpload) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpInitiateLayerUpload) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorInitiateLayerUpload(response, &metadata)
+ }
+ output := &InitiateLayerUploadOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentInitiateLayerUploadOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorInitiateLayerUpload(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("KmsException", errorCode):
+ return awsAwsjson11_deserializeErrorKmsException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpListImages struct {
+}
+
+func (*awsAwsjson11_deserializeOpListImages) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpListImages) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorListImages(response, &metadata)
+ }
+ output := &ListImagesOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentListImagesOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorListImages(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpListTagsForResource struct {
+}
+
+func (*awsAwsjson11_deserializeOpListTagsForResource) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpListTagsForResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorListTagsForResource(response, &metadata)
+ }
+ output := &ListTagsForResourceOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentListTagsForResourceOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorListTagsForResource(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutImage struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutImage) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutImage(response, &metadata)
+ }
+ output := &PutImageOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutImageOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutImage(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("ImageAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorImageAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("ImageDigestDoesNotMatchException", errorCode):
+ return awsAwsjson11_deserializeErrorImageDigestDoesNotMatchException(response, errorBody)
+
+ case strings.EqualFold("ImageTagAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorImageTagAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("KmsException", errorCode):
+ return awsAwsjson11_deserializeErrorKmsException(response, errorBody)
+
+ case strings.EqualFold("LayersNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorLayersNotFoundException(response, errorBody)
+
+ case strings.EqualFold("LimitExceededException", errorCode):
+ return awsAwsjson11_deserializeErrorLimitExceededException(response, errorBody)
+
+ case strings.EqualFold("ReferencedImagesNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorReferencedImagesNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutImageScanningConfiguration struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutImageScanningConfiguration) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutImageScanningConfiguration) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutImageScanningConfiguration(response, &metadata)
+ }
+ output := &PutImageScanningConfigurationOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutImageScanningConfigurationOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutImageScanningConfiguration(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutImageTagMutability struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutImageTagMutability) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutImageTagMutability) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutImageTagMutability(response, &metadata)
+ }
+ output := &PutImageTagMutabilityOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutImageTagMutabilityOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutImageTagMutability(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutLifecyclePolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutLifecyclePolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutLifecyclePolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutLifecyclePolicy(response, &metadata)
+ }
+ output := &PutLifecyclePolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutLifecyclePolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutLifecyclePolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutRegistryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutRegistryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutRegistryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutRegistryPolicy(response, &metadata)
+ }
+ output := &PutRegistryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutRegistryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutRegistryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutRegistryScanningConfiguration struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutRegistryScanningConfiguration) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutRegistryScanningConfiguration) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutRegistryScanningConfiguration(response, &metadata)
+ }
+ output := &PutRegistryScanningConfigurationOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutRegistryScanningConfigurationOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutRegistryScanningConfiguration(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutReplicationConfiguration struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutReplicationConfiguration) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutReplicationConfiguration) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutReplicationConfiguration(response, &metadata)
+ }
+ output := &PutReplicationConfigurationOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutReplicationConfigurationOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutReplicationConfiguration(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpSetRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpSetRepositoryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpSetRepositoryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorSetRepositoryPolicy(response, &metadata)
+ }
+ output := &SetRepositoryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentSetRepositoryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorSetRepositoryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpStartImageScan struct {
+}
+
+func (*awsAwsjson11_deserializeOpStartImageScan) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpStartImageScan) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorStartImageScan(response, &metadata)
+ }
+ output := &StartImageScanOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentStartImageScanOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorStartImageScan(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("ImageNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorImageNotFoundException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LimitExceededException", errorCode):
+ return awsAwsjson11_deserializeErrorLimitExceededException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedImageTypeException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedImageTypeException(response, errorBody)
+
+ case strings.EqualFold("ValidationException", errorCode):
+ return awsAwsjson11_deserializeErrorValidationException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpStartLifecyclePolicyPreview struct {
+}
+
+func (*awsAwsjson11_deserializeOpStartLifecyclePolicyPreview) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpStartLifecyclePolicyPreview) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorStartLifecyclePolicyPreview(response, &metadata)
+ }
+ output := &StartLifecyclePolicyPreviewOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentStartLifecyclePolicyPreviewOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorStartLifecyclePolicyPreview(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LifecyclePolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorLifecyclePolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("LifecyclePolicyPreviewInProgressException", errorCode):
+ return awsAwsjson11_deserializeErrorLifecyclePolicyPreviewInProgressException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpTagResource struct {
+}
+
+func (*awsAwsjson11_deserializeOpTagResource) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpTagResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorTagResource(response, &metadata)
+ }
+ output := &TagResourceOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentTagResourceOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorTagResource(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("InvalidTagParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidTagParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("TooManyTagsException", errorCode):
+ return awsAwsjson11_deserializeErrorTooManyTagsException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpUntagResource struct {
+}
+
+func (*awsAwsjson11_deserializeOpUntagResource) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpUntagResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorUntagResource(response, &metadata)
+ }
+ output := &UntagResourceOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentUntagResourceOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorUntagResource(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("InvalidTagParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidTagParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("TooManyTagsException", errorCode):
+ return awsAwsjson11_deserializeErrorTooManyTagsException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpUploadLayerPart struct {
+}
+
+func (*awsAwsjson11_deserializeOpUploadLayerPart) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpUploadLayerPart) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorUploadLayerPart(response, &metadata)
+ }
+ output := &UploadLayerPartOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentUploadLayerPartOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorUploadLayerPart(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidLayerPartException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidLayerPartException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("KmsException", errorCode):
+ return awsAwsjson11_deserializeErrorKmsException(response, errorBody)
+
+ case strings.EqualFold("LimitExceededException", errorCode):
+ return awsAwsjson11_deserializeErrorLimitExceededException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UploadNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorUploadNotFoundException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+func awsAwsjson11_deserializeErrorEmptyUploadException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.EmptyUploadException{}
+ err := awsAwsjson11_deserializeDocumentEmptyUploadException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorImageAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ImageAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentImageAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorImageDigestDoesNotMatchException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ImageDigestDoesNotMatchException{}
+ err := awsAwsjson11_deserializeDocumentImageDigestDoesNotMatchException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorImageNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ImageNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentImageNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorImageTagAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ImageTagAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentImageTagAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorInvalidLayerException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.InvalidLayerException{}
+ err := awsAwsjson11_deserializeDocumentInvalidLayerException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorInvalidLayerPartException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.InvalidLayerPartException{}
+ err := awsAwsjson11_deserializeDocumentInvalidLayerPartException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorInvalidParameterException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.InvalidParameterException{}
+ err := awsAwsjson11_deserializeDocumentInvalidParameterException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorInvalidTagParameterException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.InvalidTagParameterException{}
+ err := awsAwsjson11_deserializeDocumentInvalidTagParameterException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorKmsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.KmsException{}
+ err := awsAwsjson11_deserializeDocumentKmsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLayerAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LayerAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentLayerAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLayerInaccessibleException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LayerInaccessibleException{}
+ err := awsAwsjson11_deserializeDocumentLayerInaccessibleException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLayerPartTooSmallException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LayerPartTooSmallException{}
+ err := awsAwsjson11_deserializeDocumentLayerPartTooSmallException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLayersNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LayersNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentLayersNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLifecyclePolicyNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LifecyclePolicyNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentLifecyclePolicyNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLifecyclePolicyPreviewInProgressException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LifecyclePolicyPreviewInProgressException{}
+ err := awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewInProgressException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLifecyclePolicyPreviewNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LifecyclePolicyPreviewNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLimitExceededException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LimitExceededException{}
+ err := awsAwsjson11_deserializeDocumentLimitExceededException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorPullThroughCacheRuleAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.PullThroughCacheRuleAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentPullThroughCacheRuleAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorPullThroughCacheRuleNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.PullThroughCacheRuleNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentPullThroughCacheRuleNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorReferencedImagesNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ReferencedImagesNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentReferencedImagesNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRegistryPolicyNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RegistryPolicyNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentRegistryPolicyNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRepositoryAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RepositoryAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentRepositoryAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRepositoryNotEmptyException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RepositoryNotEmptyException{}
+ err := awsAwsjson11_deserializeDocumentRepositoryNotEmptyException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRepositoryNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RepositoryNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentRepositoryNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRepositoryPolicyNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RepositoryPolicyNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentRepositoryPolicyNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorScanNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ScanNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentScanNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorServerException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ServerException{}
+ err := awsAwsjson11_deserializeDocumentServerException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorTooManyTagsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.TooManyTagsException{}
+ err := awsAwsjson11_deserializeDocumentTooManyTagsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorUnsupportedImageTypeException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.UnsupportedImageTypeException{}
+ err := awsAwsjson11_deserializeDocumentUnsupportedImageTypeException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorUnsupportedUpstreamRegistryException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.UnsupportedUpstreamRegistryException{}
+ err := awsAwsjson11_deserializeDocumentUnsupportedUpstreamRegistryException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorUploadNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.UploadNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentUploadNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorValidationException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ValidationException{}
+ err := awsAwsjson11_deserializeDocumentValidationException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeDocumentAttribute(v **types.Attribute, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Attribute
+ if *v == nil {
+ sv = &types.Attribute{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "key":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected AttributeKey to be of type string, got %T instead", value)
+ }
+ sv.Key = ptr.String(jtv)
+ }
+
+ case "value":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected AttributeValue to be of type string, got %T instead", value)
+ }
+ sv.Value = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentAttributeList(v *[]types.Attribute, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Attribute
+ if *v == nil {
+ cv = []types.Attribute{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Attribute
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentAttribute(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentAuthorizationData(v **types.AuthorizationData, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.AuthorizationData
+ if *v == nil {
+ sv = &types.AuthorizationData{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "authorizationToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Base64 to be of type string, got %T instead", value)
+ }
+ sv.AuthorizationToken = ptr.String(jtv)
+ }
+
+ case "expiresAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.ExpiresAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected ExpirationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "proxyEndpoint":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ProxyEndpoint to be of type string, got %T instead", value)
+ }
+ sv.ProxyEndpoint = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentAuthorizationDataList(v *[]types.AuthorizationData, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.AuthorizationData
+ if *v == nil {
+ cv = []types.AuthorizationData{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.AuthorizationData
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentAuthorizationData(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentAwsEcrContainerImageDetails(v **types.AwsEcrContainerImageDetails, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.AwsEcrContainerImageDetails
+ if *v == nil {
+ sv = &types.AwsEcrContainerImageDetails{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "architecture":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Arch to be of type string, got %T instead", value)
+ }
+ sv.Architecture = ptr.String(jtv)
+ }
+
+ case "author":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Author to be of type string, got %T instead", value)
+ }
+ sv.Author = ptr.String(jtv)
+ }
+
+ case "imageHash":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageDigest to be of type string, got %T instead", value)
+ }
+ sv.ImageHash = ptr.String(jtv)
+ }
+
+ case "imageTags":
+ if err := awsAwsjson11_deserializeDocumentImageTagsList(&sv.ImageTags, value); err != nil {
+ return err
+ }
+
+ case "platform":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Platform to be of type string, got %T instead", value)
+ }
+ sv.Platform = ptr.String(jtv)
+ }
+
+ case "pushedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.PushedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected Date to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "registry":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.Registry = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentCvssScore(v **types.CvssScore, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.CvssScore
+ if *v == nil {
+ sv = &types.CvssScore{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "baseScore":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.BaseScore = f64
+
+ case string:
+ var f64 float64
+ switch {
+ case strings.EqualFold(jtv, "NaN"):
+ f64 = math.NaN()
+
+ case strings.EqualFold(jtv, "Infinity"):
+ f64 = math.Inf(1)
+
+ case strings.EqualFold(jtv, "-Infinity"):
+ f64 = math.Inf(-1)
+
+ default:
+ return fmt.Errorf("unknown JSON number value: %s", jtv)
+
+ }
+ sv.BaseScore = f64
+
+ default:
+ return fmt.Errorf("expected BaseScore to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "scoringVector":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScoringVector to be of type string, got %T instead", value)
+ }
+ sv.ScoringVector = ptr.String(jtv)
+ }
+
+ case "source":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Source to be of type string, got %T instead", value)
+ }
+ sv.Source = ptr.String(jtv)
+ }
+
+ case "version":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Version to be of type string, got %T instead", value)
+ }
+ sv.Version = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentCvssScoreAdjustment(v **types.CvssScoreAdjustment, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.CvssScoreAdjustment
+ if *v == nil {
+ sv = &types.CvssScoreAdjustment{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "metric":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Metric to be of type string, got %T instead", value)
+ }
+ sv.Metric = ptr.String(jtv)
+ }
+
+ case "reason":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Reason to be of type string, got %T instead", value)
+ }
+ sv.Reason = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentCvssScoreAdjustmentList(v *[]types.CvssScoreAdjustment, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.CvssScoreAdjustment
+ if *v == nil {
+ cv = []types.CvssScoreAdjustment{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.CvssScoreAdjustment
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentCvssScoreAdjustment(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentCvssScoreDetails(v **types.CvssScoreDetails, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.CvssScoreDetails
+ if *v == nil {
+ sv = &types.CvssScoreDetails{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "adjustments":
+ if err := awsAwsjson11_deserializeDocumentCvssScoreAdjustmentList(&sv.Adjustments, value); err != nil {
+ return err
+ }
+
+ case "score":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.Score = f64
+
+ case string:
+ var f64 float64
+ switch {
+ case strings.EqualFold(jtv, "NaN"):
+ f64 = math.NaN()
+
+ case strings.EqualFold(jtv, "Infinity"):
+ f64 = math.Inf(1)
+
+ case strings.EqualFold(jtv, "-Infinity"):
+ f64 = math.Inf(-1)
+
+ default:
+ return fmt.Errorf("unknown JSON number value: %s", jtv)
+
+ }
+ sv.Score = f64
+
+ default:
+ return fmt.Errorf("expected Score to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "scoreSource":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Source to be of type string, got %T instead", value)
+ }
+ sv.ScoreSource = ptr.String(jtv)
+ }
+
+ case "scoringVector":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScoringVector to be of type string, got %T instead", value)
+ }
+ sv.ScoringVector = ptr.String(jtv)
+ }
+
+ case "version":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Version to be of type string, got %T instead", value)
+ }
+ sv.Version = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentCvssScoreList(v *[]types.CvssScore, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.CvssScore
+ if *v == nil {
+ cv = []types.CvssScore{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.CvssScore
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentCvssScore(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentEmptyUploadException(v **types.EmptyUploadException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.EmptyUploadException
+ if *v == nil {
+ sv = &types.EmptyUploadException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentEncryptionConfiguration(v **types.EncryptionConfiguration, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.EncryptionConfiguration
+ if *v == nil {
+ sv = &types.EncryptionConfiguration{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "encryptionType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected EncryptionType to be of type string, got %T instead", value)
+ }
+ sv.EncryptionType = types.EncryptionType(jtv)
+ }
+
+ case "kmsKey":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected KmsKey to be of type string, got %T instead", value)
+ }
+ sv.KmsKey = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentEnhancedImageScanFinding(v **types.EnhancedImageScanFinding, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.EnhancedImageScanFinding
+ if *v == nil {
+ sv = &types.EnhancedImageScanFinding{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "awsAccountId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.AwsAccountId = ptr.String(jtv)
+ }
+
+ case "description":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected FindingDescription to be of type string, got %T instead", value)
+ }
+ sv.Description = ptr.String(jtv)
+ }
+
+ case "findingArn":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected FindingArn to be of type string, got %T instead", value)
+ }
+ sv.FindingArn = ptr.String(jtv)
+ }
+
+ case "firstObservedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.FirstObservedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected Date to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "lastObservedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.LastObservedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected Date to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "packageVulnerabilityDetails":
+ if err := awsAwsjson11_deserializeDocumentPackageVulnerabilityDetails(&sv.PackageVulnerabilityDetails, value); err != nil {
+ return err
+ }
+
+ case "remediation":
+ if err := awsAwsjson11_deserializeDocumentRemediation(&sv.Remediation, value); err != nil {
+ return err
+ }
+
+ case "resources":
+ if err := awsAwsjson11_deserializeDocumentResourceList(&sv.Resources, value); err != nil {
+ return err
+ }
+
+ case "score":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.Score = f64
+
+ case string:
+ var f64 float64
+ switch {
+ case strings.EqualFold(jtv, "NaN"):
+ f64 = math.NaN()
+
+ case strings.EqualFold(jtv, "Infinity"):
+ f64 = math.Inf(1)
+
+ case strings.EqualFold(jtv, "-Infinity"):
+ f64 = math.Inf(-1)
+
+ default:
+ return fmt.Errorf("unknown JSON number value: %s", jtv)
+
+ }
+ sv.Score = f64
+
+ default:
+ return fmt.Errorf("expected Score to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "scoreDetails":
+ if err := awsAwsjson11_deserializeDocumentScoreDetails(&sv.ScoreDetails, value); err != nil {
+ return err
+ }
+
+ case "severity":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Severity to be of type string, got %T instead", value)
+ }
+ sv.Severity = ptr.String(jtv)
+ }
+
+ case "status":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Status to be of type string, got %T instead", value)
+ }
+ sv.Status = ptr.String(jtv)
+ }
+
+ case "title":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Title to be of type string, got %T instead", value)
+ }
+ sv.Title = ptr.String(jtv)
+ }
+
+ case "type":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Type to be of type string, got %T instead", value)
+ }
+ sv.Type = ptr.String(jtv)
+ }
+
+ case "updatedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.UpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected Date to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentEnhancedImageScanFindingList(v *[]types.EnhancedImageScanFinding, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.EnhancedImageScanFinding
+ if *v == nil {
+ cv = []types.EnhancedImageScanFinding{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.EnhancedImageScanFinding
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentEnhancedImageScanFinding(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentFindingSeverityCounts(v *map[string]int32, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var mv map[string]int32
+ if *v == nil {
+ mv = map[string]int32{}
+ } else {
+ mv = *v
+ }
+
+ for key, value := range shape {
+ var parsedVal int32
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected SeverityCount to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ parsedVal = int32(i64)
+ }
+ mv[key] = parsedVal
+
+ }
+ *v = mv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImage(v **types.Image, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Image
+ if *v == nil {
+ sv = &types.Image{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageId":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&sv.ImageId, value); err != nil {
+ return err
+ }
+
+ case "imageManifest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageManifest to be of type string, got %T instead", value)
+ }
+ sv.ImageManifest = ptr.String(jtv)
+ }
+
+ case "imageManifestMediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.ImageManifestMediaType = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageAlreadyExistsException(v **types.ImageAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageAlreadyExistsException
+ if *v == nil {
+ sv = &types.ImageAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageDetail(v **types.ImageDetail, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageDetail
+ if *v == nil {
+ sv = &types.ImageDetail{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "artifactMediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.ArtifactMediaType = ptr.String(jtv)
+ }
+
+ case "imageDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageDigest to be of type string, got %T instead", value)
+ }
+ sv.ImageDigest = ptr.String(jtv)
+ }
+
+ case "imageManifestMediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.ImageManifestMediaType = ptr.String(jtv)
+ }
+
+ case "imagePushedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.ImagePushedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected PushTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "imageScanFindingsSummary":
+ if err := awsAwsjson11_deserializeDocumentImageScanFindingsSummary(&sv.ImageScanFindingsSummary, value); err != nil {
+ return err
+ }
+
+ case "imageScanStatus":
+ if err := awsAwsjson11_deserializeDocumentImageScanStatus(&sv.ImageScanStatus, value); err != nil {
+ return err
+ }
+
+ case "imageSizeInBytes":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected ImageSizeInBytes to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.ImageSizeInBytes = ptr.Int64(i64)
+ }
+
+ case "imageTags":
+ if err := awsAwsjson11_deserializeDocumentImageTagList(&sv.ImageTags, value); err != nil {
+ return err
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageDetailList(v *[]types.ImageDetail, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageDetail
+ if *v == nil {
+ cv = []types.ImageDetail{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageDetail
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageDetail(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageDigestDoesNotMatchException(v **types.ImageDigestDoesNotMatchException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageDigestDoesNotMatchException
+ if *v == nil {
+ sv = &types.ImageDigestDoesNotMatchException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageFailure(v **types.ImageFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageFailure
+ if *v == nil {
+ sv = &types.ImageFailure{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failureCode":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageFailureCode to be of type string, got %T instead", value)
+ }
+ sv.FailureCode = types.ImageFailureCode(jtv)
+ }
+
+ case "failureReason":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageFailureReason to be of type string, got %T instead", value)
+ }
+ sv.FailureReason = ptr.String(jtv)
+ }
+
+ case "imageId":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&sv.ImageId, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageFailureList(v *[]types.ImageFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageFailure
+ if *v == nil {
+ cv = []types.ImageFailure{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageFailure
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageFailure(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageIdentifier(v **types.ImageIdentifier, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageIdentifier
+ if *v == nil {
+ sv = &types.ImageIdentifier{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageDigest to be of type string, got %T instead", value)
+ }
+ sv.ImageDigest = ptr.String(jtv)
+ }
+
+ case "imageTag":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageTag to be of type string, got %T instead", value)
+ }
+ sv.ImageTag = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageIdentifierList(v *[]types.ImageIdentifier, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageIdentifier
+ if *v == nil {
+ cv = []types.ImageIdentifier{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageIdentifier
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageList(v *[]types.Image, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Image
+ if *v == nil {
+ cv = []types.Image{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Image
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImage(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageNotFoundException(v **types.ImageNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageNotFoundException
+ if *v == nil {
+ sv = &types.ImageNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageReplicationStatus(v **types.ImageReplicationStatus, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageReplicationStatus
+ if *v == nil {
+ sv = &types.ImageReplicationStatus{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failureCode":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ReplicationError to be of type string, got %T instead", value)
+ }
+ sv.FailureCode = ptr.String(jtv)
+ }
+
+ case "region":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Region to be of type string, got %T instead", value)
+ }
+ sv.Region = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "status":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ReplicationStatus to be of type string, got %T instead", value)
+ }
+ sv.Status = types.ReplicationStatus(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageReplicationStatusList(v *[]types.ImageReplicationStatus, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageReplicationStatus
+ if *v == nil {
+ cv = []types.ImageReplicationStatus{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageReplicationStatus
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageReplicationStatus(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageScanFinding(v **types.ImageScanFinding, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageScanFinding
+ if *v == nil {
+ sv = &types.ImageScanFinding{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "attributes":
+ if err := awsAwsjson11_deserializeDocumentAttributeList(&sv.Attributes, value); err != nil {
+ return err
+ }
+
+ case "description":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected FindingDescription to be of type string, got %T instead", value)
+ }
+ sv.Description = ptr.String(jtv)
+ }
+
+ case "name":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected FindingName to be of type string, got %T instead", value)
+ }
+ sv.Name = ptr.String(jtv)
+ }
+
+ case "severity":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected FindingSeverity to be of type string, got %T instead", value)
+ }
+ sv.Severity = types.FindingSeverity(jtv)
+ }
+
+ case "uri":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.Uri = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageScanFindingList(v *[]types.ImageScanFinding, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageScanFinding
+ if *v == nil {
+ cv = []types.ImageScanFinding{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageScanFinding
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageScanFinding(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageScanFindings(v **types.ImageScanFindings, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageScanFindings
+ if *v == nil {
+ sv = &types.ImageScanFindings{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "enhancedFindings":
+ if err := awsAwsjson11_deserializeDocumentEnhancedImageScanFindingList(&sv.EnhancedFindings, value); err != nil {
+ return err
+ }
+
+ case "findings":
+ if err := awsAwsjson11_deserializeDocumentImageScanFindingList(&sv.Findings, value); err != nil {
+ return err
+ }
+
+ case "findingSeverityCounts":
+ if err := awsAwsjson11_deserializeDocumentFindingSeverityCounts(&sv.FindingSeverityCounts, value); err != nil {
+ return err
+ }
+
+ case "imageScanCompletedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.ImageScanCompletedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected ScanTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "vulnerabilitySourceUpdatedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.VulnerabilitySourceUpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected VulnerabilitySourceUpdateTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageScanFindingsSummary(v **types.ImageScanFindingsSummary, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageScanFindingsSummary
+ if *v == nil {
+ sv = &types.ImageScanFindingsSummary{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "findingSeverityCounts":
+ if err := awsAwsjson11_deserializeDocumentFindingSeverityCounts(&sv.FindingSeverityCounts, value); err != nil {
+ return err
+ }
+
+ case "imageScanCompletedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.ImageScanCompletedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected ScanTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "vulnerabilitySourceUpdatedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.VulnerabilitySourceUpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected VulnerabilitySourceUpdateTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageScanningConfiguration(v **types.ImageScanningConfiguration, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageScanningConfiguration
+ if *v == nil {
+ sv = &types.ImageScanningConfiguration{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "scanOnPush":
+ if value != nil {
+ jtv, ok := value.(bool)
+ if !ok {
+ return fmt.Errorf("expected ScanOnPushFlag to be of type *bool, got %T instead", value)
+ }
+ sv.ScanOnPush = jtv
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageScanStatus(v **types.ImageScanStatus, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageScanStatus
+ if *v == nil {
+ sv = &types.ImageScanStatus{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "description":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanStatusDescription to be of type string, got %T instead", value)
+ }
+ sv.Description = ptr.String(jtv)
+ }
+
+ case "status":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanStatus to be of type string, got %T instead", value)
+ }
+ sv.Status = types.ScanStatus(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageTagAlreadyExistsException(v **types.ImageTagAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageTagAlreadyExistsException
+ if *v == nil {
+ sv = &types.ImageTagAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageTagList(v *[]string, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []string
+ if *v == nil {
+ cv = []string{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col string
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageTag to be of type string, got %T instead", value)
+ }
+ col = jtv
+ }
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageTagsList(v *[]string, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []string
+ if *v == nil {
+ cv = []string{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col string
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageTag to be of type string, got %T instead", value)
+ }
+ col = jtv
+ }
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentInvalidLayerException(v **types.InvalidLayerException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidLayerException
+ if *v == nil {
+ sv = &types.InvalidLayerException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentInvalidLayerPartException(v **types.InvalidLayerPartException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidLayerPartException
+ if *v == nil {
+ sv = &types.InvalidLayerPartException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lastValidByteReceived":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected PartSize to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.LastValidByteReceived = ptr.Int64(i64)
+ }
+
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "uploadId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UploadId to be of type string, got %T instead", value)
+ }
+ sv.UploadId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentInvalidParameterException(v **types.InvalidParameterException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidParameterException
+ if *v == nil {
+ sv = &types.InvalidParameterException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentInvalidTagParameterException(v **types.InvalidTagParameterException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidTagParameterException
+ if *v == nil {
+ sv = &types.InvalidTagParameterException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentKmsException(v **types.KmsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.KmsException
+ if *v == nil {
+ sv = &types.KmsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "kmsError":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected KmsError to be of type string, got %T instead", value)
+ }
+ sv.KmsError = ptr.String(jtv)
+ }
+
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayer(v **types.Layer, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Layer
+ if *v == nil {
+ sv = &types.Layer{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "layerAvailability":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerAvailability to be of type string, got %T instead", value)
+ }
+ sv.LayerAvailability = types.LayerAvailability(jtv)
+ }
+
+ case "layerDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerDigest to be of type string, got %T instead", value)
+ }
+ sv.LayerDigest = ptr.String(jtv)
+ }
+
+ case "layerSize":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected LayerSizeInBytes to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.LayerSize = ptr.Int64(i64)
+ }
+
+ case "mediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.MediaType = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerAlreadyExistsException(v **types.LayerAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayerAlreadyExistsException
+ if *v == nil {
+ sv = &types.LayerAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerFailure(v **types.LayerFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayerFailure
+ if *v == nil {
+ sv = &types.LayerFailure{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failureCode":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerFailureCode to be of type string, got %T instead", value)
+ }
+ sv.FailureCode = types.LayerFailureCode(jtv)
+ }
+
+ case "failureReason":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerFailureReason to be of type string, got %T instead", value)
+ }
+ sv.FailureReason = ptr.String(jtv)
+ }
+
+ case "layerDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected BatchedOperationLayerDigest to be of type string, got %T instead", value)
+ }
+ sv.LayerDigest = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerFailureList(v *[]types.LayerFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.LayerFailure
+ if *v == nil {
+ cv = []types.LayerFailure{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.LayerFailure
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentLayerFailure(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerInaccessibleException(v **types.LayerInaccessibleException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayerInaccessibleException
+ if *v == nil {
+ sv = &types.LayerInaccessibleException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerList(v *[]types.Layer, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Layer
+ if *v == nil {
+ cv = []types.Layer{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Layer
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentLayer(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerPartTooSmallException(v **types.LayerPartTooSmallException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayerPartTooSmallException
+ if *v == nil {
+ sv = &types.LayerPartTooSmallException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayersNotFoundException(v **types.LayersNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayersNotFoundException
+ if *v == nil {
+ sv = &types.LayersNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLifecyclePolicyNotFoundException(v **types.LifecyclePolicyNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LifecyclePolicyNotFoundException
+ if *v == nil {
+ sv = &types.LifecyclePolicyNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewInProgressException(v **types.LifecyclePolicyPreviewInProgressException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LifecyclePolicyPreviewInProgressException
+ if *v == nil {
+ sv = &types.LifecyclePolicyPreviewInProgressException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewNotFoundException(v **types.LifecyclePolicyPreviewNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LifecyclePolicyPreviewNotFoundException
+ if *v == nil {
+ sv = &types.LifecyclePolicyPreviewNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewResult(v **types.LifecyclePolicyPreviewResult, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LifecyclePolicyPreviewResult
+ if *v == nil {
+ sv = &types.LifecyclePolicyPreviewResult{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "action":
+ if err := awsAwsjson11_deserializeDocumentLifecyclePolicyRuleAction(&sv.Action, value); err != nil {
+ return err
+ }
+
+ case "appliedRulePriority":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected LifecyclePolicyRulePriority to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.AppliedRulePriority = ptr.Int32(int32(i64))
+ }
+
+ case "imageDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageDigest to be of type string, got %T instead", value)
+ }
+ sv.ImageDigest = ptr.String(jtv)
+ }
+
+ case "imagePushedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.ImagePushedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected PushTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "imageTags":
+ if err := awsAwsjson11_deserializeDocumentImageTagList(&sv.ImageTags, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewResultList(v *[]types.LifecyclePolicyPreviewResult, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.LifecyclePolicyPreviewResult
+ if *v == nil {
+ cv = []types.LifecyclePolicyPreviewResult{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.LifecyclePolicyPreviewResult
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewResult(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewSummary(v **types.LifecyclePolicyPreviewSummary, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LifecyclePolicyPreviewSummary
+ if *v == nil {
+ sv = &types.LifecyclePolicyPreviewSummary{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "expiringImageTotalCount":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected ImageCount to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.ExpiringImageTotalCount = ptr.Int32(int32(i64))
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLifecyclePolicyRuleAction(v **types.LifecyclePolicyRuleAction, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LifecyclePolicyRuleAction
+ if *v == nil {
+ sv = &types.LifecyclePolicyRuleAction{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "type":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageActionType to be of type string, got %T instead", value)
+ }
+ sv.Type = types.ImageActionType(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLimitExceededException(v **types.LimitExceededException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LimitExceededException
+ if *v == nil {
+ sv = &types.LimitExceededException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentPackageVulnerabilityDetails(v **types.PackageVulnerabilityDetails, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.PackageVulnerabilityDetails
+ if *v == nil {
+ sv = &types.PackageVulnerabilityDetails{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "cvss":
+ if err := awsAwsjson11_deserializeDocumentCvssScoreList(&sv.Cvss, value); err != nil {
+ return err
+ }
+
+ case "referenceUrls":
+ if err := awsAwsjson11_deserializeDocumentReferenceUrlsList(&sv.ReferenceUrls, value); err != nil {
+ return err
+ }
+
+ case "relatedVulnerabilities":
+ if err := awsAwsjson11_deserializeDocumentRelatedVulnerabilitiesList(&sv.RelatedVulnerabilities, value); err != nil {
+ return err
+ }
+
+ case "source":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Source to be of type string, got %T instead", value)
+ }
+ sv.Source = ptr.String(jtv)
+ }
+
+ case "sourceUrl":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.SourceUrl = ptr.String(jtv)
+ }
+
+ case "vendorCreatedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.VendorCreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected Date to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "vendorSeverity":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Severity to be of type string, got %T instead", value)
+ }
+ sv.VendorSeverity = ptr.String(jtv)
+ }
+
+ case "vendorUpdatedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.VendorUpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected Date to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "vulnerabilityId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected VulnerabilityId to be of type string, got %T instead", value)
+ }
+ sv.VulnerabilityId = ptr.String(jtv)
+ }
+
+ case "vulnerablePackages":
+ if err := awsAwsjson11_deserializeDocumentVulnerablePackagesList(&sv.VulnerablePackages, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentPullThroughCacheRule(v **types.PullThroughCacheRule, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.PullThroughCacheRule
+ if *v == nil {
+ sv = &types.PullThroughCacheRule{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "createdAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected CreationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "ecrRepositoryPrefix":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected PullThroughCacheRuleRepositoryPrefix to be of type string, got %T instead", value)
+ }
+ sv.EcrRepositoryPrefix = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "upstreamRegistryUrl":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.UpstreamRegistryUrl = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentPullThroughCacheRuleAlreadyExistsException(v **types.PullThroughCacheRuleAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.PullThroughCacheRuleAlreadyExistsException
+ if *v == nil {
+ sv = &types.PullThroughCacheRuleAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentPullThroughCacheRuleList(v *[]types.PullThroughCacheRule, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.PullThroughCacheRule
+ if *v == nil {
+ cv = []types.PullThroughCacheRule{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.PullThroughCacheRule
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentPullThroughCacheRule(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentPullThroughCacheRuleNotFoundException(v **types.PullThroughCacheRuleNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.PullThroughCacheRuleNotFoundException
+ if *v == nil {
+ sv = &types.PullThroughCacheRuleNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRecommendation(v **types.Recommendation, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Recommendation
+ if *v == nil {
+ sv = &types.Recommendation{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "text":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RecommendationText to be of type string, got %T instead", value)
+ }
+ sv.Text = ptr.String(jtv)
+ }
+
+ case "url":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.Url = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReferencedImagesNotFoundException(v **types.ReferencedImagesNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ReferencedImagesNotFoundException
+ if *v == nil {
+ sv = &types.ReferencedImagesNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReferenceUrlsList(v *[]string, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []string
+ if *v == nil {
+ cv = []string{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col string
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ col = jtv
+ }
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryPolicyNotFoundException(v **types.RegistryPolicyNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RegistryPolicyNotFoundException
+ if *v == nil {
+ sv = &types.RegistryPolicyNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryScanningConfiguration(v **types.RegistryScanningConfiguration, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RegistryScanningConfiguration
+ if *v == nil {
+ sv = &types.RegistryScanningConfiguration{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "rules":
+ if err := awsAwsjson11_deserializeDocumentRegistryScanningRuleList(&sv.Rules, value); err != nil {
+ return err
+ }
+
+ case "scanType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanType to be of type string, got %T instead", value)
+ }
+ sv.ScanType = types.ScanType(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryScanningRule(v **types.RegistryScanningRule, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RegistryScanningRule
+ if *v == nil {
+ sv = &types.RegistryScanningRule{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "repositoryFilters":
+ if err := awsAwsjson11_deserializeDocumentScanningRepositoryFilterList(&sv.RepositoryFilters, value); err != nil {
+ return err
+ }
+
+ case "scanFrequency":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanFrequency to be of type string, got %T instead", value)
+ }
+ sv.ScanFrequency = types.ScanFrequency(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryScanningRuleList(v *[]types.RegistryScanningRule, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.RegistryScanningRule
+ if *v == nil {
+ cv = []types.RegistryScanningRule{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.RegistryScanningRule
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentRegistryScanningRule(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRelatedVulnerabilitiesList(v *[]string, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []string
+ if *v == nil {
+ cv = []string{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col string
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RelatedVulnerability to be of type string, got %T instead", value)
+ }
+ col = jtv
+ }
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRemediation(v **types.Remediation, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Remediation
+ if *v == nil {
+ sv = &types.Remediation{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "recommendation":
+ if err := awsAwsjson11_deserializeDocumentRecommendation(&sv.Recommendation, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReplicationConfiguration(v **types.ReplicationConfiguration, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ReplicationConfiguration
+ if *v == nil {
+ sv = &types.ReplicationConfiguration{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "rules":
+ if err := awsAwsjson11_deserializeDocumentReplicationRuleList(&sv.Rules, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReplicationDestination(v **types.ReplicationDestination, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ReplicationDestination
+ if *v == nil {
+ sv = &types.ReplicationDestination{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "region":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Region to be of type string, got %T instead", value)
+ }
+ sv.Region = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReplicationDestinationList(v *[]types.ReplicationDestination, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ReplicationDestination
+ if *v == nil {
+ cv = []types.ReplicationDestination{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ReplicationDestination
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentReplicationDestination(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReplicationRule(v **types.ReplicationRule, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ReplicationRule
+ if *v == nil {
+ sv = &types.ReplicationRule{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "destinations":
+ if err := awsAwsjson11_deserializeDocumentReplicationDestinationList(&sv.Destinations, value); err != nil {
+ return err
+ }
+
+ case "repositoryFilters":
+ if err := awsAwsjson11_deserializeDocumentRepositoryFilterList(&sv.RepositoryFilters, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReplicationRuleList(v *[]types.ReplicationRule, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ReplicationRule
+ if *v == nil {
+ cv = []types.ReplicationRule{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ReplicationRule
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentReplicationRule(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepository(v **types.Repository, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Repository
+ if *v == nil {
+ sv = &types.Repository{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "createdAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected CreationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "encryptionConfiguration":
+ if err := awsAwsjson11_deserializeDocumentEncryptionConfiguration(&sv.EncryptionConfiguration, value); err != nil {
+ return err
+ }
+
+ case "imageScanningConfiguration":
+ if err := awsAwsjson11_deserializeDocumentImageScanningConfiguration(&sv.ImageScanningConfiguration, value); err != nil {
+ return err
+ }
+
+ case "imageTagMutability":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageTagMutability to be of type string, got %T instead", value)
+ }
+ sv.ImageTagMutability = types.ImageTagMutability(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryArn":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Arn to be of type string, got %T instead", value)
+ }
+ sv.RepositoryArn = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "repositoryUri":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.RepositoryUri = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryAlreadyExistsException(v **types.RepositoryAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryAlreadyExistsException
+ if *v == nil {
+ sv = &types.RepositoryAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryFilter(v **types.RepositoryFilter, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryFilter
+ if *v == nil {
+ sv = &types.RepositoryFilter{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "filter":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryFilterValue to be of type string, got %T instead", value)
+ }
+ sv.Filter = ptr.String(jtv)
+ }
+
+ case "filterType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryFilterType to be of type string, got %T instead", value)
+ }
+ sv.FilterType = types.RepositoryFilterType(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryFilterList(v *[]types.RepositoryFilter, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.RepositoryFilter
+ if *v == nil {
+ cv = []types.RepositoryFilter{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.RepositoryFilter
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentRepositoryFilter(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryList(v *[]types.Repository, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Repository
+ if *v == nil {
+ cv = []types.Repository{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Repository
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentRepository(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryNotEmptyException(v **types.RepositoryNotEmptyException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryNotEmptyException
+ if *v == nil {
+ sv = &types.RepositoryNotEmptyException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryNotFoundException(v **types.RepositoryNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryNotFoundException
+ if *v == nil {
+ sv = &types.RepositoryNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryPolicyNotFoundException(v **types.RepositoryPolicyNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryPolicyNotFoundException
+ if *v == nil {
+ sv = &types.RepositoryPolicyNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryScanningConfiguration(v **types.RepositoryScanningConfiguration, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryScanningConfiguration
+ if *v == nil {
+ sv = &types.RepositoryScanningConfiguration{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "appliedScanFilters":
+ if err := awsAwsjson11_deserializeDocumentScanningRepositoryFilterList(&sv.AppliedScanFilters, value); err != nil {
+ return err
+ }
+
+ case "repositoryArn":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Arn to be of type string, got %T instead", value)
+ }
+ sv.RepositoryArn = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "scanFrequency":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanFrequency to be of type string, got %T instead", value)
+ }
+ sv.ScanFrequency = types.ScanFrequency(jtv)
+ }
+
+ case "scanOnPush":
+ if value != nil {
+ jtv, ok := value.(bool)
+ if !ok {
+ return fmt.Errorf("expected ScanOnPushFlag to be of type *bool, got %T instead", value)
+ }
+ sv.ScanOnPush = jtv
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryScanningConfigurationFailure(v **types.RepositoryScanningConfigurationFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryScanningConfigurationFailure
+ if *v == nil {
+ sv = &types.RepositoryScanningConfigurationFailure{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failureCode":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanningConfigurationFailureCode to be of type string, got %T instead", value)
+ }
+ sv.FailureCode = types.ScanningConfigurationFailureCode(jtv)
+ }
+
+ case "failureReason":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanningConfigurationFailureReason to be of type string, got %T instead", value)
+ }
+ sv.FailureReason = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryScanningConfigurationFailureList(v *[]types.RepositoryScanningConfigurationFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.RepositoryScanningConfigurationFailure
+ if *v == nil {
+ cv = []types.RepositoryScanningConfigurationFailure{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.RepositoryScanningConfigurationFailure
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentRepositoryScanningConfigurationFailure(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryScanningConfigurationList(v *[]types.RepositoryScanningConfiguration, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.RepositoryScanningConfiguration
+ if *v == nil {
+ cv = []types.RepositoryScanningConfiguration{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.RepositoryScanningConfiguration
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentRepositoryScanningConfiguration(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentResource(v **types.Resource, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Resource
+ if *v == nil {
+ sv = &types.Resource{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "details":
+ if err := awsAwsjson11_deserializeDocumentResourceDetails(&sv.Details, value); err != nil {
+ return err
+ }
+
+ case "id":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ResourceId to be of type string, got %T instead", value)
+ }
+ sv.Id = ptr.String(jtv)
+ }
+
+ case "tags":
+ if err := awsAwsjson11_deserializeDocumentTags(&sv.Tags, value); err != nil {
+ return err
+ }
+
+ case "type":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Type to be of type string, got %T instead", value)
+ }
+ sv.Type = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentResourceDetails(v **types.ResourceDetails, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ResourceDetails
+ if *v == nil {
+ sv = &types.ResourceDetails{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "awsEcrContainerImage":
+ if err := awsAwsjson11_deserializeDocumentAwsEcrContainerImageDetails(&sv.AwsEcrContainerImage, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentResourceList(v *[]types.Resource, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Resource
+ if *v == nil {
+ cv = []types.Resource{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Resource
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentResource(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentScanningRepositoryFilter(v **types.ScanningRepositoryFilter, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ScanningRepositoryFilter
+ if *v == nil {
+ sv = &types.ScanningRepositoryFilter{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "filter":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanningRepositoryFilterValue to be of type string, got %T instead", value)
+ }
+ sv.Filter = ptr.String(jtv)
+ }
+
+ case "filterType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ScanningRepositoryFilterType to be of type string, got %T instead", value)
+ }
+ sv.FilterType = types.ScanningRepositoryFilterType(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentScanningRepositoryFilterList(v *[]types.ScanningRepositoryFilter, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ScanningRepositoryFilter
+ if *v == nil {
+ cv = []types.ScanningRepositoryFilter{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ScanningRepositoryFilter
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentScanningRepositoryFilter(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentScanNotFoundException(v **types.ScanNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ScanNotFoundException
+ if *v == nil {
+ sv = &types.ScanNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentScoreDetails(v **types.ScoreDetails, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ScoreDetails
+ if *v == nil {
+ sv = &types.ScoreDetails{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "cvss":
+ if err := awsAwsjson11_deserializeDocumentCvssScoreDetails(&sv.Cvss, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentServerException(v **types.ServerException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ServerException
+ if *v == nil {
+ sv = &types.ServerException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentTag(v **types.Tag, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Tag
+ if *v == nil {
+ sv = &types.Tag{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "Key":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected TagKey to be of type string, got %T instead", value)
+ }
+ sv.Key = ptr.String(jtv)
+ }
+
+ case "Value":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected TagValue to be of type string, got %T instead", value)
+ }
+ sv.Value = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentTagList(v *[]types.Tag, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Tag
+ if *v == nil {
+ cv = []types.Tag{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Tag
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentTag(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentTags(v *map[string]string, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var mv map[string]string
+ if *v == nil {
+ mv = map[string]string{}
+ } else {
+ mv = *v
+ }
+
+ for key, value := range shape {
+ var parsedVal string
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected TagValue to be of type string, got %T instead", value)
+ }
+ parsedVal = jtv
+ }
+ mv[key] = parsedVal
+
+ }
+ *v = mv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentTooManyTagsException(v **types.TooManyTagsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.TooManyTagsException
+ if *v == nil {
+ sv = &types.TooManyTagsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentUnsupportedImageTypeException(v **types.UnsupportedImageTypeException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.UnsupportedImageTypeException
+ if *v == nil {
+ sv = &types.UnsupportedImageTypeException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentUnsupportedUpstreamRegistryException(v **types.UnsupportedUpstreamRegistryException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.UnsupportedUpstreamRegistryException
+ if *v == nil {
+ sv = &types.UnsupportedUpstreamRegistryException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentUploadNotFoundException(v **types.UploadNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.UploadNotFoundException
+ if *v == nil {
+ sv = &types.UploadNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentValidationException(v **types.ValidationException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ValidationException
+ if *v == nil {
+ sv = &types.ValidationException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentVulnerablePackage(v **types.VulnerablePackage, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.VulnerablePackage
+ if *v == nil {
+ sv = &types.VulnerablePackage{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "arch":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Arch to be of type string, got %T instead", value)
+ }
+ sv.Arch = ptr.String(jtv)
+ }
+
+ case "epoch":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected Epoch to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.Epoch = ptr.Int32(int32(i64))
+ }
+
+ case "filePath":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected FilePath to be of type string, got %T instead", value)
+ }
+ sv.FilePath = ptr.String(jtv)
+ }
+
+ case "name":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected VulnerablePackageName to be of type string, got %T instead", value)
+ }
+ sv.Name = ptr.String(jtv)
+ }
+
+ case "packageManager":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected PackageManager to be of type string, got %T instead", value)
+ }
+ sv.PackageManager = ptr.String(jtv)
+ }
+
+ case "release":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Release to be of type string, got %T instead", value)
+ }
+ sv.Release = ptr.String(jtv)
+ }
+
+ case "sourceLayerHash":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected SourceLayerHash to be of type string, got %T instead", value)
+ }
+ sv.SourceLayerHash = ptr.String(jtv)
+ }
+
+ case "version":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Version to be of type string, got %T instead", value)
+ }
+ sv.Version = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentVulnerablePackagesList(v *[]types.VulnerablePackage, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.VulnerablePackage
+ if *v == nil {
+ cv = []types.VulnerablePackage{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.VulnerablePackage
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentVulnerablePackage(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentBatchCheckLayerAvailabilityOutput(v **BatchCheckLayerAvailabilityOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *BatchCheckLayerAvailabilityOutput
+ if *v == nil {
+ sv = &BatchCheckLayerAvailabilityOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failures":
+ if err := awsAwsjson11_deserializeDocumentLayerFailureList(&sv.Failures, value); err != nil {
+ return err
+ }
+
+ case "layers":
+ if err := awsAwsjson11_deserializeDocumentLayerList(&sv.Layers, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentBatchDeleteImageOutput(v **BatchDeleteImageOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *BatchDeleteImageOutput
+ if *v == nil {
+ sv = &BatchDeleteImageOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failures":
+ if err := awsAwsjson11_deserializeDocumentImageFailureList(&sv.Failures, value); err != nil {
+ return err
+ }
+
+ case "imageIds":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifierList(&sv.ImageIds, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentBatchGetImageOutput(v **BatchGetImageOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *BatchGetImageOutput
+ if *v == nil {
+ sv = &BatchGetImageOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failures":
+ if err := awsAwsjson11_deserializeDocumentImageFailureList(&sv.Failures, value); err != nil {
+ return err
+ }
+
+ case "images":
+ if err := awsAwsjson11_deserializeDocumentImageList(&sv.Images, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentBatchGetRepositoryScanningConfigurationOutput(v **BatchGetRepositoryScanningConfigurationOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *BatchGetRepositoryScanningConfigurationOutput
+ if *v == nil {
+ sv = &BatchGetRepositoryScanningConfigurationOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failures":
+ if err := awsAwsjson11_deserializeDocumentRepositoryScanningConfigurationFailureList(&sv.Failures, value); err != nil {
+ return err
+ }
+
+ case "scanningConfigurations":
+ if err := awsAwsjson11_deserializeDocumentRepositoryScanningConfigurationList(&sv.ScanningConfigurations, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentCompleteLayerUploadOutput(v **CompleteLayerUploadOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *CompleteLayerUploadOutput
+ if *v == nil {
+ sv = &CompleteLayerUploadOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "layerDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerDigest to be of type string, got %T instead", value)
+ }
+ sv.LayerDigest = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "uploadId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UploadId to be of type string, got %T instead", value)
+ }
+ sv.UploadId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentCreatePullThroughCacheRuleOutput(v **CreatePullThroughCacheRuleOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *CreatePullThroughCacheRuleOutput
+ if *v == nil {
+ sv = &CreatePullThroughCacheRuleOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "createdAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected CreationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "ecrRepositoryPrefix":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected PullThroughCacheRuleRepositoryPrefix to be of type string, got %T instead", value)
+ }
+ sv.EcrRepositoryPrefix = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "upstreamRegistryUrl":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.UpstreamRegistryUrl = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentCreateRepositoryOutput(v **CreateRepositoryOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *CreateRepositoryOutput
+ if *v == nil {
+ sv = &CreateRepositoryOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "repository":
+ if err := awsAwsjson11_deserializeDocumentRepository(&sv.Repository, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDeleteLifecyclePolicyOutput(v **DeleteLifecyclePolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DeleteLifecyclePolicyOutput
+ if *v == nil {
+ sv = &DeleteLifecyclePolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lastEvaluatedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.LastEvaluatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected EvaluationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "lifecyclePolicyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LifecyclePolicyText to be of type string, got %T instead", value)
+ }
+ sv.LifecyclePolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDeletePullThroughCacheRuleOutput(v **DeletePullThroughCacheRuleOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DeletePullThroughCacheRuleOutput
+ if *v == nil {
+ sv = &DeletePullThroughCacheRuleOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "createdAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected CreationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "ecrRepositoryPrefix":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected PullThroughCacheRuleRepositoryPrefix to be of type string, got %T instead", value)
+ }
+ sv.EcrRepositoryPrefix = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "upstreamRegistryUrl":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.UpstreamRegistryUrl = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDeleteRegistryPolicyOutput(v **DeleteRegistryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DeleteRegistryPolicyOutput
+ if *v == nil {
+ sv = &DeleteRegistryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDeleteRepositoryOutput(v **DeleteRepositoryOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DeleteRepositoryOutput
+ if *v == nil {
+ sv = &DeleteRepositoryOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "repository":
+ if err := awsAwsjson11_deserializeDocumentRepository(&sv.Repository, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDeleteRepositoryPolicyOutput(v **DeleteRepositoryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DeleteRepositoryPolicyOutput
+ if *v == nil {
+ sv = &DeleteRepositoryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeImageReplicationStatusOutput(v **DescribeImageReplicationStatusOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeImageReplicationStatusOutput
+ if *v == nil {
+ sv = &DescribeImageReplicationStatusOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageId":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&sv.ImageId, value); err != nil {
+ return err
+ }
+
+ case "replicationStatuses":
+ if err := awsAwsjson11_deserializeDocumentImageReplicationStatusList(&sv.ReplicationStatuses, value); err != nil {
+ return err
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeImageScanFindingsOutput(v **DescribeImageScanFindingsOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeImageScanFindingsOutput
+ if *v == nil {
+ sv = &DescribeImageScanFindingsOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageId":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&sv.ImageId, value); err != nil {
+ return err
+ }
+
+ case "imageScanFindings":
+ if err := awsAwsjson11_deserializeDocumentImageScanFindings(&sv.ImageScanFindings, value); err != nil {
+ return err
+ }
+
+ case "imageScanStatus":
+ if err := awsAwsjson11_deserializeDocumentImageScanStatus(&sv.ImageScanStatus, value); err != nil {
+ return err
+ }
+
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeImagesOutput(v **DescribeImagesOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeImagesOutput
+ if *v == nil {
+ sv = &DescribeImagesOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageDetails":
+ if err := awsAwsjson11_deserializeDocumentImageDetailList(&sv.ImageDetails, value); err != nil {
+ return err
+ }
+
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribePullThroughCacheRulesOutput(v **DescribePullThroughCacheRulesOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribePullThroughCacheRulesOutput
+ if *v == nil {
+ sv = &DescribePullThroughCacheRulesOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ case "pullThroughCacheRules":
+ if err := awsAwsjson11_deserializeDocumentPullThroughCacheRuleList(&sv.PullThroughCacheRules, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeRegistryOutput(v **DescribeRegistryOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeRegistryOutput
+ if *v == nil {
+ sv = &DescribeRegistryOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "replicationConfiguration":
+ if err := awsAwsjson11_deserializeDocumentReplicationConfiguration(&sv.ReplicationConfiguration, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeRepositoriesOutput(v **DescribeRepositoriesOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeRepositoriesOutput
+ if *v == nil {
+ sv = &DescribeRepositoriesOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ case "repositories":
+ if err := awsAwsjson11_deserializeDocumentRepositoryList(&sv.Repositories, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetAuthorizationTokenOutput(v **GetAuthorizationTokenOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetAuthorizationTokenOutput
+ if *v == nil {
+ sv = &GetAuthorizationTokenOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "authorizationData":
+ if err := awsAwsjson11_deserializeDocumentAuthorizationDataList(&sv.AuthorizationData, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetDownloadUrlForLayerOutput(v **GetDownloadUrlForLayerOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetDownloadUrlForLayerOutput
+ if *v == nil {
+ sv = &GetDownloadUrlForLayerOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "downloadUrl":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.DownloadUrl = ptr.String(jtv)
+ }
+
+ case "layerDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerDigest to be of type string, got %T instead", value)
+ }
+ sv.LayerDigest = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetLifecyclePolicyOutput(v **GetLifecyclePolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetLifecyclePolicyOutput
+ if *v == nil {
+ sv = &GetLifecyclePolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lastEvaluatedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.LastEvaluatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected EvaluationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "lifecyclePolicyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LifecyclePolicyText to be of type string, got %T instead", value)
+ }
+ sv.LifecyclePolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetLifecyclePolicyPreviewOutput(v **GetLifecyclePolicyPreviewOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetLifecyclePolicyPreviewOutput
+ if *v == nil {
+ sv = &GetLifecyclePolicyPreviewOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lifecyclePolicyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LifecyclePolicyText to be of type string, got %T instead", value)
+ }
+ sv.LifecyclePolicyText = ptr.String(jtv)
+ }
+
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ case "previewResults":
+ if err := awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewResultList(&sv.PreviewResults, value); err != nil {
+ return err
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "status":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LifecyclePolicyPreviewStatus to be of type string, got %T instead", value)
+ }
+ sv.Status = types.LifecyclePolicyPreviewStatus(jtv)
+ }
+
+ case "summary":
+ if err := awsAwsjson11_deserializeDocumentLifecyclePolicyPreviewSummary(&sv.Summary, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetRegistryPolicyOutput(v **GetRegistryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetRegistryPolicyOutput
+ if *v == nil {
+ sv = &GetRegistryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetRegistryScanningConfigurationOutput(v **GetRegistryScanningConfigurationOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetRegistryScanningConfigurationOutput
+ if *v == nil {
+ sv = &GetRegistryScanningConfigurationOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "scanningConfiguration":
+ if err := awsAwsjson11_deserializeDocumentRegistryScanningConfiguration(&sv.ScanningConfiguration, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetRepositoryPolicyOutput(v **GetRepositoryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetRepositoryPolicyOutput
+ if *v == nil {
+ sv = &GetRepositoryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentInitiateLayerUploadOutput(v **InitiateLayerUploadOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *InitiateLayerUploadOutput
+ if *v == nil {
+ sv = &InitiateLayerUploadOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "partSize":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected PartSize to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.PartSize = ptr.Int64(i64)
+ }
+
+ case "uploadId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UploadId to be of type string, got %T instead", value)
+ }
+ sv.UploadId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentListImagesOutput(v **ListImagesOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *ListImagesOutput
+ if *v == nil {
+ sv = &ListImagesOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageIds":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifierList(&sv.ImageIds, value); err != nil {
+ return err
+ }
+
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentListTagsForResourceOutput(v **ListTagsForResourceOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *ListTagsForResourceOutput
+ if *v == nil {
+ sv = &ListTagsForResourceOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "tags":
+ if err := awsAwsjson11_deserializeDocumentTagList(&sv.Tags, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutImageOutput(v **PutImageOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutImageOutput
+ if *v == nil {
+ sv = &PutImageOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "image":
+ if err := awsAwsjson11_deserializeDocumentImage(&sv.Image, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutImageScanningConfigurationOutput(v **PutImageScanningConfigurationOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutImageScanningConfigurationOutput
+ if *v == nil {
+ sv = &PutImageScanningConfigurationOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageScanningConfiguration":
+ if err := awsAwsjson11_deserializeDocumentImageScanningConfiguration(&sv.ImageScanningConfiguration, value); err != nil {
+ return err
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutImageTagMutabilityOutput(v **PutImageTagMutabilityOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutImageTagMutabilityOutput
+ if *v == nil {
+ sv = &PutImageTagMutabilityOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageTagMutability":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageTagMutability to be of type string, got %T instead", value)
+ }
+ sv.ImageTagMutability = types.ImageTagMutability(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutLifecyclePolicyOutput(v **PutLifecyclePolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutLifecyclePolicyOutput
+ if *v == nil {
+ sv = &PutLifecyclePolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lifecyclePolicyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LifecyclePolicyText to be of type string, got %T instead", value)
+ }
+ sv.LifecyclePolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutRegistryPolicyOutput(v **PutRegistryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutRegistryPolicyOutput
+ if *v == nil {
+ sv = &PutRegistryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutRegistryScanningConfigurationOutput(v **PutRegistryScanningConfigurationOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutRegistryScanningConfigurationOutput
+ if *v == nil {
+ sv = &PutRegistryScanningConfigurationOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "registryScanningConfiguration":
+ if err := awsAwsjson11_deserializeDocumentRegistryScanningConfiguration(&sv.RegistryScanningConfiguration, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutReplicationConfigurationOutput(v **PutReplicationConfigurationOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutReplicationConfigurationOutput
+ if *v == nil {
+ sv = &PutReplicationConfigurationOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "replicationConfiguration":
+ if err := awsAwsjson11_deserializeDocumentReplicationConfiguration(&sv.ReplicationConfiguration, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentSetRepositoryPolicyOutput(v **SetRepositoryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *SetRepositoryPolicyOutput
+ if *v == nil {
+ sv = &SetRepositoryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentStartImageScanOutput(v **StartImageScanOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *StartImageScanOutput
+ if *v == nil {
+ sv = &StartImageScanOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageId":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&sv.ImageId, value); err != nil {
+ return err
+ }
+
+ case "imageScanStatus":
+ if err := awsAwsjson11_deserializeDocumentImageScanStatus(&sv.ImageScanStatus, value); err != nil {
+ return err
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentStartLifecyclePolicyPreviewOutput(v **StartLifecyclePolicyPreviewOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *StartLifecyclePolicyPreviewOutput
+ if *v == nil {
+ sv = &StartLifecyclePolicyPreviewOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lifecyclePolicyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LifecyclePolicyText to be of type string, got %T instead", value)
+ }
+ sv.LifecyclePolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "status":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LifecyclePolicyPreviewStatus to be of type string, got %T instead", value)
+ }
+ sv.Status = types.LifecyclePolicyPreviewStatus(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentTagResourceOutput(v **TagResourceOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *TagResourceOutput
+ if *v == nil {
+ sv = &TagResourceOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentUntagResourceOutput(v **UntagResourceOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *UntagResourceOutput
+ if *v == nil {
+ sv = &UntagResourceOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentUploadLayerPartOutput(v **UploadLayerPartOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *UploadLayerPartOutput
+ if *v == nil {
+ sv = &UploadLayerPartOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lastByteReceived":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected PartSize to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.LastByteReceived = ptr.Int64(i64)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "uploadId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UploadId to be of type string, got %T instead", value)
+ }
+ sv.UploadId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/doc.go
new file mode 100644
index 000000000000..602df615b1e8
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/doc.go
@@ -0,0 +1,16 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+// Package ecr provides the API client, operations, and parameter types for Amazon
+// EC2 Container Registry.
+//
+// Amazon Elastic Container Registry Amazon Elastic Container Registry (Amazon ECR)
+// is a managed container image registry service. Customers can use the familiar
+// Docker CLI, or their preferred client, to push, pull, and manage images. Amazon
+// ECR provides a secure, scalable, and reliable registry for your Docker or Open
+// Container Initiative (OCI) images. Amazon ECR supports private repositories with
+// resource-based permissions using IAM so that specific users or Amazon EC2
+// instances can access repositories and images. Amazon ECR has service endpoints
+// in each supported Region. For more information, see Amazon ECR endpoints
+// (https://docs.aws.amazon.com/general/latest/gr/ecr.html) in the Amazon Web
+// Services General Reference.
+package ecr
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/endpoints.go
new file mode 100644
index 000000000000..e255bc9d5244
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/endpoints.go
@@ -0,0 +1,200 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ internalendpoints "github.com/aws/aws-sdk-go-v2/service/ecr/internal/endpoints"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "net/url"
+ "strings"
+)
+
+// EndpointResolverOptions is the service endpoint resolver options
+type EndpointResolverOptions = internalendpoints.Options
+
+// EndpointResolver interface for resolving service endpoints.
+type EndpointResolver interface {
+ ResolveEndpoint(region string, options EndpointResolverOptions) (aws.Endpoint, error)
+}
+
+var _ EndpointResolver = &internalendpoints.Resolver{}
+
+// NewDefaultEndpointResolver constructs a new service endpoint resolver
+func NewDefaultEndpointResolver() *internalendpoints.Resolver {
+ return internalendpoints.New()
+}
+
+// EndpointResolverFunc is a helper utility that wraps a function so it satisfies
+// the EndpointResolver interface. This is useful when you want to add additional
+// endpoint resolving logic, or stub out specific endpoints with custom values.
+type EndpointResolverFunc func(region string, options EndpointResolverOptions) (aws.Endpoint, error)
+
+func (fn EndpointResolverFunc) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error) {
+ return fn(region, options)
+}
+
+func resolveDefaultEndpointConfiguration(o *Options) {
+ if o.EndpointResolver != nil {
+ return
+ }
+ o.EndpointResolver = NewDefaultEndpointResolver()
+}
+
+// EndpointResolverFromURL returns an EndpointResolver configured using the
+// provided endpoint url. By default, the resolved endpoint resolver uses the
+// client region as signing region, and the endpoint source is set to
+// EndpointSourceCustom.You can provide functional options to configure endpoint
+// values for the resolved endpoint.
+func EndpointResolverFromURL(url string, optFns ...func(*aws.Endpoint)) EndpointResolver {
+ e := aws.Endpoint{URL: url, Source: aws.EndpointSourceCustom}
+ for _, fn := range optFns {
+ fn(&e)
+ }
+
+ return EndpointResolverFunc(
+ func(region string, options EndpointResolverOptions) (aws.Endpoint, error) {
+ if len(e.SigningRegion) == 0 {
+ e.SigningRegion = region
+ }
+ return e, nil
+ },
+ )
+}
+
+type ResolveEndpoint struct {
+ Resolver EndpointResolver
+ Options EndpointResolverOptions
+}
+
+func (*ResolveEndpoint) ID() string {
+ return "ResolveEndpoint"
+}
+
+func (m *ResolveEndpoint) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in.Request)
+ }
+
+ if m.Resolver == nil {
+ return out, metadata, fmt.Errorf("expected endpoint resolver to not be nil")
+ }
+
+ eo := m.Options
+ eo.Logger = middleware.GetLogger(ctx)
+
+ var endpoint aws.Endpoint
+ endpoint, err = m.Resolver.ResolveEndpoint(awsmiddleware.GetRegion(ctx), eo)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to resolve service endpoint, %w", err)
+ }
+
+ req.URL, err = url.Parse(endpoint.URL)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to parse endpoint URL: %w", err)
+ }
+
+ if len(awsmiddleware.GetSigningName(ctx)) == 0 {
+ signingName := endpoint.SigningName
+ if len(signingName) == 0 {
+ signingName = "ecr"
+ }
+ ctx = awsmiddleware.SetSigningName(ctx, signingName)
+ }
+ ctx = awsmiddleware.SetEndpointSource(ctx, endpoint.Source)
+ ctx = smithyhttp.SetHostnameImmutable(ctx, endpoint.HostnameImmutable)
+ ctx = awsmiddleware.SetSigningRegion(ctx, endpoint.SigningRegion)
+ ctx = awsmiddleware.SetPartitionID(ctx, endpoint.PartitionID)
+ return next.HandleSerialize(ctx, in)
+}
+func addResolveEndpointMiddleware(stack *middleware.Stack, o Options) error {
+ return stack.Serialize.Insert(&ResolveEndpoint{
+ Resolver: o.EndpointResolver,
+ Options: o.EndpointOptions,
+ }, "OperationSerializer", middleware.Before)
+}
+
+func removeResolveEndpointMiddleware(stack *middleware.Stack) error {
+ _, err := stack.Serialize.Remove((&ResolveEndpoint{}).ID())
+ return err
+}
+
+type wrappedEndpointResolver struct {
+ awsResolver aws.EndpointResolverWithOptions
+ resolver EndpointResolver
+}
+
+func (w *wrappedEndpointResolver) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error) {
+ if w.awsResolver == nil {
+ goto fallback
+ }
+ endpoint, err = w.awsResolver.ResolveEndpoint(ServiceID, region, options)
+ if err == nil {
+ return endpoint, nil
+ }
+
+ if nf := (&aws.EndpointNotFoundError{}); !errors.As(err, &nf) {
+ return endpoint, err
+ }
+
+fallback:
+ if w.resolver == nil {
+ return endpoint, fmt.Errorf("default endpoint resolver provided was nil")
+ }
+ return w.resolver.ResolveEndpoint(region, options)
+}
+
+type awsEndpointResolverAdaptor func(service, region string) (aws.Endpoint, error)
+
+func (a awsEndpointResolverAdaptor) ResolveEndpoint(service, region string, options ...interface{}) (aws.Endpoint, error) {
+ return a(service, region)
+}
+
+var _ aws.EndpointResolverWithOptions = awsEndpointResolverAdaptor(nil)
+
+// withEndpointResolver returns an EndpointResolver that first delegates endpoint resolution to the awsResolver.
+// If awsResolver returns aws.EndpointNotFoundError error, the resolver will use the the provided
+// fallbackResolver for resolution.
+//
+// fallbackResolver must not be nil
+func withEndpointResolver(awsResolver aws.EndpointResolver, awsResolverWithOptions aws.EndpointResolverWithOptions, fallbackResolver EndpointResolver) EndpointResolver {
+ var resolver aws.EndpointResolverWithOptions
+
+ if awsResolverWithOptions != nil {
+ resolver = awsResolverWithOptions
+ } else if awsResolver != nil {
+ resolver = awsEndpointResolverAdaptor(awsResolver.ResolveEndpoint)
+ }
+
+ return &wrappedEndpointResolver{
+ awsResolver: resolver,
+ resolver: fallbackResolver,
+ }
+}
+
+func finalizeClientEndpointResolverOptions(options *Options) {
+ options.EndpointOptions.LogDeprecated = options.ClientLogMode.IsDeprecatedUsage()
+
+ if len(options.EndpointOptions.ResolvedRegion) == 0 {
+ const fipsInfix = "-fips-"
+ const fipsPrefix = "fips-"
+ const fipsSuffix = "-fips"
+
+ if strings.Contains(options.Region, fipsInfix) ||
+ strings.Contains(options.Region, fipsPrefix) ||
+ strings.Contains(options.Region, fipsSuffix) {
+ options.EndpointOptions.ResolvedRegion = strings.ReplaceAll(strings.ReplaceAll(strings.ReplaceAll(
+ options.Region, fipsInfix, "-"), fipsPrefix, ""), fipsSuffix, "")
+ options.EndpointOptions.UseFIPSEndpoint = aws.FIPSEndpointStateEnabled
+ }
+ }
+
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/generated.json b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/generated.json
new file mode 100644
index 000000000000..5f7cddbfa22a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/generated.json
@@ -0,0 +1,68 @@
+{
+ "dependencies": {
+ "github.com/aws/aws-sdk-go-v2": "v1.4.0",
+ "github.com/aws/aws-sdk-go-v2/internal/configsources": "v0.0.0-00010101000000-000000000000",
+ "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2": "v2.0.0-00010101000000-000000000000",
+ "github.com/aws/smithy-go": "v1.4.0",
+ "github.com/jmespath/go-jmespath": "v0.4.0"
+ },
+ "files": [
+ "api_client.go",
+ "api_op_BatchCheckLayerAvailability.go",
+ "api_op_BatchDeleteImage.go",
+ "api_op_BatchGetImage.go",
+ "api_op_BatchGetRepositoryScanningConfiguration.go",
+ "api_op_CompleteLayerUpload.go",
+ "api_op_CreatePullThroughCacheRule.go",
+ "api_op_CreateRepository.go",
+ "api_op_DeleteLifecyclePolicy.go",
+ "api_op_DeletePullThroughCacheRule.go",
+ "api_op_DeleteRegistryPolicy.go",
+ "api_op_DeleteRepository.go",
+ "api_op_DeleteRepositoryPolicy.go",
+ "api_op_DescribeImageReplicationStatus.go",
+ "api_op_DescribeImageScanFindings.go",
+ "api_op_DescribeImages.go",
+ "api_op_DescribePullThroughCacheRules.go",
+ "api_op_DescribeRegistry.go",
+ "api_op_DescribeRepositories.go",
+ "api_op_GetAuthorizationToken.go",
+ "api_op_GetDownloadUrlForLayer.go",
+ "api_op_GetLifecyclePolicy.go",
+ "api_op_GetLifecyclePolicyPreview.go",
+ "api_op_GetRegistryPolicy.go",
+ "api_op_GetRegistryScanningConfiguration.go",
+ "api_op_GetRepositoryPolicy.go",
+ "api_op_InitiateLayerUpload.go",
+ "api_op_ListImages.go",
+ "api_op_ListTagsForResource.go",
+ "api_op_PutImage.go",
+ "api_op_PutImageScanningConfiguration.go",
+ "api_op_PutImageTagMutability.go",
+ "api_op_PutLifecyclePolicy.go",
+ "api_op_PutRegistryPolicy.go",
+ "api_op_PutRegistryScanningConfiguration.go",
+ "api_op_PutReplicationConfiguration.go",
+ "api_op_SetRepositoryPolicy.go",
+ "api_op_StartImageScan.go",
+ "api_op_StartLifecyclePolicyPreview.go",
+ "api_op_TagResource.go",
+ "api_op_UntagResource.go",
+ "api_op_UploadLayerPart.go",
+ "deserializers.go",
+ "doc.go",
+ "endpoints.go",
+ "generated.json",
+ "internal/endpoints/endpoints.go",
+ "internal/endpoints/endpoints_test.go",
+ "protocol_test.go",
+ "serializers.go",
+ "types/enums.go",
+ "types/errors.go",
+ "types/types.go",
+ "validators.go"
+ ],
+ "go": "1.15",
+ "module": "github.com/aws/aws-sdk-go-v2/service/ecr",
+ "unstable": false
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go.mod
new file mode 100644
index 000000000000..fa9259d6f467
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go.mod
@@ -0,0 +1,17 @@
+module github.com/aws/aws-sdk-go-v2/service/ecr
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3
+ github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0
+ github.com/aws/smithy-go v1.9.1
+ github.com/jmespath/go-jmespath v0.4.0
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../../
+
+replace github.com/aws/aws-sdk-go-v2/internal/configsources => ../../internal/configsources/
+
+replace github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 => ../../internal/endpoints/v2/
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go.sum
new file mode 100644
index 000000000000..ce121d1d3182
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go.sum
@@ -0,0 +1,20 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8 h1:obN1ZagJSUGI0Ek/LBmuj4SNLPfIny3KsKFopxRdj10=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go_module_metadata.go
new file mode 100644
index 000000000000..949d6dbbdc38
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package ecr
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.13.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/internal/endpoints/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/internal/endpoints/endpoints.go
new file mode 100644
index 000000000000..c74ddafcd578
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/internal/endpoints/endpoints.go
@@ -0,0 +1,762 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package endpoints
+
+import (
+ "github.com/aws/aws-sdk-go-v2/aws"
+ endpoints "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2"
+ "github.com/aws/smithy-go/logging"
+ "regexp"
+)
+
+// Options is the endpoint resolver configuration options
+type Options struct {
+ // Logger is a logging implementation that log events should be sent to.
+ Logger logging.Logger
+
+ // LogDeprecated indicates that deprecated endpoints should be logged to the
+ // provided logger.
+ LogDeprecated bool
+
+ // ResolvedRegion is used to override the region to be resolved, rather then the
+ // using the value passed to the ResolveEndpoint method. This value is used by the
+ // SDK to translate regions like fips-us-east-1 or us-east-1-fips to an alternative
+ // name. You must not set this value directly in your application.
+ ResolvedRegion string
+
+ // DisableHTTPS informs the resolver to return an endpoint that does not use the
+ // HTTPS scheme.
+ DisableHTTPS bool
+
+ // UseDualStackEndpoint specifies the resolver must resolve a dual-stack endpoint.
+ UseDualStackEndpoint aws.DualStackEndpointState
+
+ // UseFIPSEndpoint specifies the resolver must resolve a FIPS endpoint.
+ UseFIPSEndpoint aws.FIPSEndpointState
+}
+
+func (o Options) GetResolvedRegion() string {
+ return o.ResolvedRegion
+}
+
+func (o Options) GetDisableHTTPS() bool {
+ return o.DisableHTTPS
+}
+
+func (o Options) GetUseDualStackEndpoint() aws.DualStackEndpointState {
+ return o.UseDualStackEndpoint
+}
+
+func (o Options) GetUseFIPSEndpoint() aws.FIPSEndpointState {
+ return o.UseFIPSEndpoint
+}
+
+func transformToSharedOptions(options Options) endpoints.Options {
+ return endpoints.Options{
+ Logger: options.Logger,
+ LogDeprecated: options.LogDeprecated,
+ ResolvedRegion: options.ResolvedRegion,
+ DisableHTTPS: options.DisableHTTPS,
+ UseDualStackEndpoint: options.UseDualStackEndpoint,
+ UseFIPSEndpoint: options.UseFIPSEndpoint,
+ }
+}
+
+// Resolver ECR endpoint resolver
+type Resolver struct {
+ partitions endpoints.Partitions
+}
+
+// ResolveEndpoint resolves the service endpoint for the given region and options
+func (r *Resolver) ResolveEndpoint(region string, options Options) (endpoint aws.Endpoint, err error) {
+ if len(region) == 0 {
+ return endpoint, &aws.MissingRegionError{}
+ }
+
+ opt := transformToSharedOptions(options)
+ return r.partitions.ResolveEndpoint(region, opt)
+}
+
+// New returns a new Resolver
+func New() *Resolver {
+ return &Resolver{
+ partitions: defaultPartitions,
+ }
+}
+
+var partitionRegexp = struct {
+ Aws *regexp.Regexp
+ AwsCn *regexp.Regexp
+ AwsIso *regexp.Regexp
+ AwsIsoB *regexp.Regexp
+ AwsUsGov *regexp.Regexp
+}{
+
+ Aws: regexp.MustCompile("^(us|eu|ap|sa|ca|me|af)\\-\\w+\\-\\d+$"),
+ AwsCn: regexp.MustCompile("^cn\\-\\w+\\-\\d+$"),
+ AwsIso: regexp.MustCompile("^us\\-iso\\-\\w+\\-\\d+$"),
+ AwsIsoB: regexp.MustCompile("^us\\-isob\\-\\w+\\-\\d+$"),
+ AwsUsGov: regexp.MustCompile("^us\\-gov\\-\\w+\\-\\d+$"),
+}
+
+var defaultPartitions = endpoints.Partitions{
+ {
+ ID: "aws",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-fips.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.Aws,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "af-south-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.af-south-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "af-south-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ap-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-northeast-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ap-northeast-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-northeast-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-northeast-2",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ap-northeast-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-northeast-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-northeast-3",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ap-northeast-3.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-northeast-3",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-south-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ap-south-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-south-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-southeast-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ap-southeast-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-southeast-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-southeast-2",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ap-southeast-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-southeast-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-southeast-3",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ap-southeast-3.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-southeast-3",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ca-central-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.ca-central-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ca-central-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-east-1",
+ }: endpoints.Endpoint{
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-east-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-east-2",
+ }: endpoints.Endpoint{
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-east-2",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-east-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-west-1",
+ }: endpoints.Endpoint{
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-west-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-west-2",
+ }: endpoints.Endpoint{
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-west-2",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "eu-central-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.eu-central-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-central-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-north-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.eu-north-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-north-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-south-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.eu-south-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-south-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.eu-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-west-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-west-2",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.eu-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-west-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-west-3",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.eu-west-3.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-west-3",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "fips-dkr-us-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-dkr-us-east-2",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-east-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-dkr-us-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-dkr-us-west-2",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-us-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-us-east-2",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-east-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-us-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-us-west-2",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "me-south-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.me-south-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "me-south-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "sa-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.sa-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "sa-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-2",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-east-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-2",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-east-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-2",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-2",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-2",
+ },
+ },
+ },
+ },
+ {
+ ID: "aws-cn",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr.{region}.api.amazonwebservices.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "api.ecr-fips.{region}.amazonaws.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-fips.{region}.api.amazonwebservices.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr.{region}.amazonaws.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsCn,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "cn-north-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.cn-north-1.amazonaws.com.cn",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "cn-north-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "cn-northwest-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.cn-northwest-1.amazonaws.com.cn",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "cn-northwest-1",
+ },
+ },
+ },
+ },
+ {
+ ID: "aws-iso",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "api.ecr-fips.{region}.c2s.ic.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr.{region}.c2s.ic.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsIso,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "us-iso-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-iso-east-1.c2s.ic.gov",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-iso-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-iso-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-iso-west-1.c2s.ic.gov",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-iso-west-1",
+ },
+ },
+ },
+ },
+ {
+ ID: "aws-iso-b",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "api.ecr-fips.{region}.sc2s.sgov.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr.{region}.sc2s.sgov.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsIsoB,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "us-isob-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-isob-east-1.sc2s.sgov.gov",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-isob-east-1",
+ },
+ },
+ },
+ },
+ {
+ ID: "aws-us-gov",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-fips.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsUsGov,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "dkr-us-gov-east-1",
+ }: endpoints.Endpoint{
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-gov-east-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-gov-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-gov-west-1",
+ }: endpoints.Endpoint{
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "dkr-us-gov-west-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-gov-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-dkr-us-gov-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-gov-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-dkr-us-gov-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-gov-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-us-gov-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-gov-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "fips-us-gov-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "ecr-fips.us-gov-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "us-gov-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-gov-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-gov-east-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-gov-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-gov-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "api.ecr.us-gov-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-west-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-gov-west-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "ecr-fips.us-gov-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-west-1",
+ },
+ },
+ },
+ },
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/serializers.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/serializers.go
new file mode 100644
index 000000000000..e513d0312fd2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/serializers.go
@@ -0,0 +1,3570 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "bytes"
+ "context"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/encoding/httpbinding"
+ smithyjson "github.com/aws/smithy-go/encoding/json"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "path"
+)
+
+type awsAwsjson11_serializeOpBatchCheckLayerAvailability struct {
+}
+
+func (*awsAwsjson11_serializeOpBatchCheckLayerAvailability) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpBatchCheckLayerAvailability) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*BatchCheckLayerAvailabilityInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.BatchCheckLayerAvailability")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentBatchCheckLayerAvailabilityInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpBatchDeleteImage struct {
+}
+
+func (*awsAwsjson11_serializeOpBatchDeleteImage) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpBatchDeleteImage) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*BatchDeleteImageInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.BatchDeleteImage")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentBatchDeleteImageInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpBatchGetImage struct {
+}
+
+func (*awsAwsjson11_serializeOpBatchGetImage) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpBatchGetImage) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*BatchGetImageInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.BatchGetImage")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentBatchGetImageInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpBatchGetRepositoryScanningConfiguration struct {
+}
+
+func (*awsAwsjson11_serializeOpBatchGetRepositoryScanningConfiguration) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpBatchGetRepositoryScanningConfiguration) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*BatchGetRepositoryScanningConfigurationInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.BatchGetRepositoryScanningConfiguration")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentBatchGetRepositoryScanningConfigurationInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpCompleteLayerUpload struct {
+}
+
+func (*awsAwsjson11_serializeOpCompleteLayerUpload) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpCompleteLayerUpload) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*CompleteLayerUploadInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.CompleteLayerUpload")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentCompleteLayerUploadInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpCreatePullThroughCacheRule struct {
+}
+
+func (*awsAwsjson11_serializeOpCreatePullThroughCacheRule) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpCreatePullThroughCacheRule) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*CreatePullThroughCacheRuleInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.CreatePullThroughCacheRule")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentCreatePullThroughCacheRuleInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpCreateRepository struct {
+}
+
+func (*awsAwsjson11_serializeOpCreateRepository) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpCreateRepository) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*CreateRepositoryInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.CreateRepository")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentCreateRepositoryInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDeleteLifecyclePolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpDeleteLifecyclePolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDeleteLifecyclePolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DeleteLifecyclePolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DeleteLifecyclePolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDeleteLifecyclePolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDeletePullThroughCacheRule struct {
+}
+
+func (*awsAwsjson11_serializeOpDeletePullThroughCacheRule) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDeletePullThroughCacheRule) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DeletePullThroughCacheRuleInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DeletePullThroughCacheRule")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDeletePullThroughCacheRuleInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDeleteRegistryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpDeleteRegistryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDeleteRegistryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DeleteRegistryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DeleteRegistryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDeleteRegistryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDeleteRepository struct {
+}
+
+func (*awsAwsjson11_serializeOpDeleteRepository) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDeleteRepository) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DeleteRepositoryInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DeleteRepository")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDeleteRepositoryInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDeleteRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpDeleteRepositoryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDeleteRepositoryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DeleteRepositoryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DeleteRepositoryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDeleteRepositoryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeImageReplicationStatus struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeImageReplicationStatus) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeImageReplicationStatus) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeImageReplicationStatusInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DescribeImageReplicationStatus")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeImageReplicationStatusInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeImages struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeImages) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeImages) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeImagesInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DescribeImages")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeImagesInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeImageScanFindings struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeImageScanFindings) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeImageScanFindings) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeImageScanFindingsInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DescribeImageScanFindings")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeImageScanFindingsInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribePullThroughCacheRules struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribePullThroughCacheRules) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribePullThroughCacheRules) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribePullThroughCacheRulesInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DescribePullThroughCacheRules")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribePullThroughCacheRulesInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeRegistry struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeRegistry) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeRegistry) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeRegistryInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DescribeRegistry")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeRegistryInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeRepositories struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeRepositories) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeRepositories) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeRepositoriesInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.DescribeRepositories")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeRepositoriesInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetAuthorizationToken struct {
+}
+
+func (*awsAwsjson11_serializeOpGetAuthorizationToken) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetAuthorizationToken) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetAuthorizationTokenInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.GetAuthorizationToken")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetAuthorizationTokenInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetDownloadUrlForLayer struct {
+}
+
+func (*awsAwsjson11_serializeOpGetDownloadUrlForLayer) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetDownloadUrlForLayer) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetDownloadUrlForLayerInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.GetDownloadUrlForLayer")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetDownloadUrlForLayerInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetLifecyclePolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpGetLifecyclePolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetLifecyclePolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetLifecyclePolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.GetLifecyclePolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetLifecyclePolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetLifecyclePolicyPreview struct {
+}
+
+func (*awsAwsjson11_serializeOpGetLifecyclePolicyPreview) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetLifecyclePolicyPreview) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetLifecyclePolicyPreviewInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.GetLifecyclePolicyPreview")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetLifecyclePolicyPreviewInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetRegistryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpGetRegistryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetRegistryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetRegistryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.GetRegistryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetRegistryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetRegistryScanningConfiguration struct {
+}
+
+func (*awsAwsjson11_serializeOpGetRegistryScanningConfiguration) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetRegistryScanningConfiguration) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetRegistryScanningConfigurationInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.GetRegistryScanningConfiguration")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetRegistryScanningConfigurationInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpGetRepositoryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetRepositoryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetRepositoryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.GetRepositoryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetRepositoryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpInitiateLayerUpload struct {
+}
+
+func (*awsAwsjson11_serializeOpInitiateLayerUpload) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpInitiateLayerUpload) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*InitiateLayerUploadInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.InitiateLayerUpload")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentInitiateLayerUploadInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpListImages struct {
+}
+
+func (*awsAwsjson11_serializeOpListImages) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpListImages) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*ListImagesInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.ListImages")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentListImagesInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpListTagsForResource struct {
+}
+
+func (*awsAwsjson11_serializeOpListTagsForResource) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpListTagsForResource) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*ListTagsForResourceInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.ListTagsForResource")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentListTagsForResourceInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutImage struct {
+}
+
+func (*awsAwsjson11_serializeOpPutImage) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutImage) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutImageInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.PutImage")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutImageInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutImageScanningConfiguration struct {
+}
+
+func (*awsAwsjson11_serializeOpPutImageScanningConfiguration) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutImageScanningConfiguration) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutImageScanningConfigurationInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.PutImageScanningConfiguration")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutImageScanningConfigurationInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutImageTagMutability struct {
+}
+
+func (*awsAwsjson11_serializeOpPutImageTagMutability) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutImageTagMutability) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutImageTagMutabilityInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.PutImageTagMutability")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutImageTagMutabilityInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutLifecyclePolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpPutLifecyclePolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutLifecyclePolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutLifecyclePolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.PutLifecyclePolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutLifecyclePolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutRegistryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpPutRegistryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutRegistryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutRegistryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.PutRegistryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutRegistryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutRegistryScanningConfiguration struct {
+}
+
+func (*awsAwsjson11_serializeOpPutRegistryScanningConfiguration) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutRegistryScanningConfiguration) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutRegistryScanningConfigurationInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.PutRegistryScanningConfiguration")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutRegistryScanningConfigurationInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutReplicationConfiguration struct {
+}
+
+func (*awsAwsjson11_serializeOpPutReplicationConfiguration) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutReplicationConfiguration) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutReplicationConfigurationInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.PutReplicationConfiguration")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutReplicationConfigurationInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpSetRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpSetRepositoryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpSetRepositoryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*SetRepositoryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.SetRepositoryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentSetRepositoryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpStartImageScan struct {
+}
+
+func (*awsAwsjson11_serializeOpStartImageScan) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpStartImageScan) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*StartImageScanInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.StartImageScan")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentStartImageScanInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpStartLifecyclePolicyPreview struct {
+}
+
+func (*awsAwsjson11_serializeOpStartLifecyclePolicyPreview) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpStartLifecyclePolicyPreview) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*StartLifecyclePolicyPreviewInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.StartLifecyclePolicyPreview")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentStartLifecyclePolicyPreviewInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpTagResource struct {
+}
+
+func (*awsAwsjson11_serializeOpTagResource) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpTagResource) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*TagResourceInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.TagResource")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentTagResourceInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpUntagResource struct {
+}
+
+func (*awsAwsjson11_serializeOpUntagResource) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpUntagResource) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*UntagResourceInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.UntagResource")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentUntagResourceInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpUploadLayerPart struct {
+}
+
+func (*awsAwsjson11_serializeOpUploadLayerPart) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpUploadLayerPart) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*UploadLayerPartInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("AmazonEC2ContainerRegistry_V20150921.UploadLayerPart")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentUploadLayerPartInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+func awsAwsjson11_serializeDocumentBatchedOperationLayerDigestList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentDescribeImagesFilter(v *types.DescribeImagesFilter, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if len(v.TagStatus) > 0 {
+ ok := object.Key("tagStatus")
+ ok.String(string(v.TagStatus))
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentEncryptionConfiguration(v *types.EncryptionConfiguration, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if len(v.EncryptionType) > 0 {
+ ok := object.Key("encryptionType")
+ ok.String(string(v.EncryptionType))
+ }
+
+ if v.KmsKey != nil {
+ ok := object.Key("kmsKey")
+ ok.String(*v.KmsKey)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentGetAuthorizationTokenRegistryIdList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentImageIdentifier(v *types.ImageIdentifier, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageDigest != nil {
+ ok := object.Key("imageDigest")
+ ok.String(*v.ImageDigest)
+ }
+
+ if v.ImageTag != nil {
+ ok := object.Key("imageTag")
+ ok.String(*v.ImageTag)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentImageIdentifierList(v []types.ImageIdentifier, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentImageIdentifier(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentImageScanningConfiguration(v *types.ImageScanningConfiguration, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ScanOnPush {
+ ok := object.Key("scanOnPush")
+ ok.Boolean(v.ScanOnPush)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentLayerDigestList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentLifecyclePolicyPreviewFilter(v *types.LifecyclePolicyPreviewFilter, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if len(v.TagStatus) > 0 {
+ ok := object.Key("tagStatus")
+ ok.String(string(v.TagStatus))
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentListImagesFilter(v *types.ListImagesFilter, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if len(v.TagStatus) > 0 {
+ ok := object.Key("tagStatus")
+ ok.String(string(v.TagStatus))
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentMediaTypeList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentPullThroughCacheRuleRepositoryPrefixList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentRegistryScanningRule(v *types.RegistryScanningRule, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RepositoryFilters != nil {
+ ok := object.Key("repositoryFilters")
+ if err := awsAwsjson11_serializeDocumentScanningRepositoryFilterList(v.RepositoryFilters, ok); err != nil {
+ return err
+ }
+ }
+
+ if len(v.ScanFrequency) > 0 {
+ ok := object.Key("scanFrequency")
+ ok.String(string(v.ScanFrequency))
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentRegistryScanningRuleList(v []types.RegistryScanningRule, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentRegistryScanningRule(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentReplicationConfiguration(v *types.ReplicationConfiguration, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Rules != nil {
+ ok := object.Key("rules")
+ if err := awsAwsjson11_serializeDocumentReplicationRuleList(v.Rules, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentReplicationDestination(v *types.ReplicationDestination, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Region != nil {
+ ok := object.Key("region")
+ ok.String(*v.Region)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentReplicationDestinationList(v []types.ReplicationDestination, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentReplicationDestination(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentReplicationRule(v *types.ReplicationRule, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Destinations != nil {
+ ok := object.Key("destinations")
+ if err := awsAwsjson11_serializeDocumentReplicationDestinationList(v.Destinations, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RepositoryFilters != nil {
+ ok := object.Key("repositoryFilters")
+ if err := awsAwsjson11_serializeDocumentRepositoryFilterList(v.RepositoryFilters, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentReplicationRuleList(v []types.ReplicationRule, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentReplicationRule(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentRepositoryFilter(v *types.RepositoryFilter, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Filter != nil {
+ ok := object.Key("filter")
+ ok.String(*v.Filter)
+ }
+
+ if len(v.FilterType) > 0 {
+ ok := object.Key("filterType")
+ ok.String(string(v.FilterType))
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentRepositoryFilterList(v []types.RepositoryFilter, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentRepositoryFilter(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentRepositoryNameList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentScanningConfigurationRepositoryNameList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentScanningRepositoryFilter(v *types.ScanningRepositoryFilter, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Filter != nil {
+ ok := object.Key("filter")
+ ok.String(*v.Filter)
+ }
+
+ if len(v.FilterType) > 0 {
+ ok := object.Key("filterType")
+ ok.String(string(v.FilterType))
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentScanningRepositoryFilterList(v []types.ScanningRepositoryFilter, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentScanningRepositoryFilter(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentTag(v *types.Tag, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Key != nil {
+ ok := object.Key("Key")
+ ok.String(*v.Key)
+ }
+
+ if v.Value != nil {
+ ok := object.Key("Value")
+ ok.String(*v.Value)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentTagKeyList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentTagList(v []types.Tag, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentTag(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentBatchCheckLayerAvailabilityInput(v *BatchCheckLayerAvailabilityInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LayerDigests != nil {
+ ok := object.Key("layerDigests")
+ if err := awsAwsjson11_serializeDocumentBatchedOperationLayerDigestList(v.LayerDigests, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentBatchDeleteImageInput(v *BatchDeleteImageInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageIds != nil {
+ ok := object.Key("imageIds")
+ if err := awsAwsjson11_serializeDocumentImageIdentifierList(v.ImageIds, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentBatchGetImageInput(v *BatchGetImageInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.AcceptedMediaTypes != nil {
+ ok := object.Key("acceptedMediaTypes")
+ if err := awsAwsjson11_serializeDocumentMediaTypeList(v.AcceptedMediaTypes, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.ImageIds != nil {
+ ok := object.Key("imageIds")
+ if err := awsAwsjson11_serializeDocumentImageIdentifierList(v.ImageIds, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentBatchGetRepositoryScanningConfigurationInput(v *BatchGetRepositoryScanningConfigurationInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RepositoryNames != nil {
+ ok := object.Key("repositoryNames")
+ if err := awsAwsjson11_serializeDocumentScanningConfigurationRepositoryNameList(v.RepositoryNames, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentCompleteLayerUploadInput(v *CompleteLayerUploadInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LayerDigests != nil {
+ ok := object.Key("layerDigests")
+ if err := awsAwsjson11_serializeDocumentLayerDigestList(v.LayerDigests, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ if v.UploadId != nil {
+ ok := object.Key("uploadId")
+ ok.String(*v.UploadId)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentCreatePullThroughCacheRuleInput(v *CreatePullThroughCacheRuleInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.EcrRepositoryPrefix != nil {
+ ok := object.Key("ecrRepositoryPrefix")
+ ok.String(*v.EcrRepositoryPrefix)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.UpstreamRegistryUrl != nil {
+ ok := object.Key("upstreamRegistryUrl")
+ ok.String(*v.UpstreamRegistryUrl)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentCreateRepositoryInput(v *CreateRepositoryInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.EncryptionConfiguration != nil {
+ ok := object.Key("encryptionConfiguration")
+ if err := awsAwsjson11_serializeDocumentEncryptionConfiguration(v.EncryptionConfiguration, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.ImageScanningConfiguration != nil {
+ ok := object.Key("imageScanningConfiguration")
+ if err := awsAwsjson11_serializeDocumentImageScanningConfiguration(v.ImageScanningConfiguration, ok); err != nil {
+ return err
+ }
+ }
+
+ if len(v.ImageTagMutability) > 0 {
+ ok := object.Key("imageTagMutability")
+ ok.String(string(v.ImageTagMutability))
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ if v.Tags != nil {
+ ok := object.Key("tags")
+ if err := awsAwsjson11_serializeDocumentTagList(v.Tags, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDeleteLifecyclePolicyInput(v *DeleteLifecyclePolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDeletePullThroughCacheRuleInput(v *DeletePullThroughCacheRuleInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.EcrRepositoryPrefix != nil {
+ ok := object.Key("ecrRepositoryPrefix")
+ ok.String(*v.EcrRepositoryPrefix)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDeleteRegistryPolicyInput(v *DeleteRegistryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDeleteRepositoryInput(v *DeleteRepositoryInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Force {
+ ok := object.Key("force")
+ ok.Boolean(v.Force)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDeleteRepositoryPolicyInput(v *DeleteRepositoryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeImageReplicationStatusInput(v *DescribeImageReplicationStatusInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageId != nil {
+ ok := object.Key("imageId")
+ if err := awsAwsjson11_serializeDocumentImageIdentifier(v.ImageId, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeImageScanFindingsInput(v *DescribeImageScanFindingsInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageId != nil {
+ ok := object.Key("imageId")
+ if err := awsAwsjson11_serializeDocumentImageIdentifier(v.ImageId, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeImagesInput(v *DescribeImagesInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Filter != nil {
+ ok := object.Key("filter")
+ if err := awsAwsjson11_serializeDocumentDescribeImagesFilter(v.Filter, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.ImageIds != nil {
+ ok := object.Key("imageIds")
+ if err := awsAwsjson11_serializeDocumentImageIdentifierList(v.ImageIds, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribePullThroughCacheRulesInput(v *DescribePullThroughCacheRulesInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.EcrRepositoryPrefixes != nil {
+ ok := object.Key("ecrRepositoryPrefixes")
+ if err := awsAwsjson11_serializeDocumentPullThroughCacheRuleRepositoryPrefixList(v.EcrRepositoryPrefixes, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeRegistryInput(v *DescribeRegistryInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeRepositoriesInput(v *DescribeRepositoriesInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryNames != nil {
+ ok := object.Key("repositoryNames")
+ if err := awsAwsjson11_serializeDocumentRepositoryNameList(v.RepositoryNames, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetAuthorizationTokenInput(v *GetAuthorizationTokenInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryIds != nil {
+ ok := object.Key("registryIds")
+ if err := awsAwsjson11_serializeDocumentGetAuthorizationTokenRegistryIdList(v.RegistryIds, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetDownloadUrlForLayerInput(v *GetDownloadUrlForLayerInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LayerDigest != nil {
+ ok := object.Key("layerDigest")
+ ok.String(*v.LayerDigest)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetLifecyclePolicyInput(v *GetLifecyclePolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetLifecyclePolicyPreviewInput(v *GetLifecyclePolicyPreviewInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Filter != nil {
+ ok := object.Key("filter")
+ if err := awsAwsjson11_serializeDocumentLifecyclePolicyPreviewFilter(v.Filter, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.ImageIds != nil {
+ ok := object.Key("imageIds")
+ if err := awsAwsjson11_serializeDocumentImageIdentifierList(v.ImageIds, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetRegistryPolicyInput(v *GetRegistryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetRegistryScanningConfigurationInput(v *GetRegistryScanningConfigurationInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetRepositoryPolicyInput(v *GetRepositoryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentInitiateLayerUploadInput(v *InitiateLayerUploadInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentListImagesInput(v *ListImagesInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Filter != nil {
+ ok := object.Key("filter")
+ if err := awsAwsjson11_serializeDocumentListImagesFilter(v.Filter, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentListTagsForResourceInput(v *ListTagsForResourceInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ResourceArn != nil {
+ ok := object.Key("resourceArn")
+ ok.String(*v.ResourceArn)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutImageInput(v *PutImageInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageDigest != nil {
+ ok := object.Key("imageDigest")
+ ok.String(*v.ImageDigest)
+ }
+
+ if v.ImageManifest != nil {
+ ok := object.Key("imageManifest")
+ ok.String(*v.ImageManifest)
+ }
+
+ if v.ImageManifestMediaType != nil {
+ ok := object.Key("imageManifestMediaType")
+ ok.String(*v.ImageManifestMediaType)
+ }
+
+ if v.ImageTag != nil {
+ ok := object.Key("imageTag")
+ ok.String(*v.ImageTag)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutImageScanningConfigurationInput(v *PutImageScanningConfigurationInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageScanningConfiguration != nil {
+ ok := object.Key("imageScanningConfiguration")
+ if err := awsAwsjson11_serializeDocumentImageScanningConfiguration(v.ImageScanningConfiguration, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutImageTagMutabilityInput(v *PutImageTagMutabilityInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if len(v.ImageTagMutability) > 0 {
+ ok := object.Key("imageTagMutability")
+ ok.String(string(v.ImageTagMutability))
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutLifecyclePolicyInput(v *PutLifecyclePolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LifecyclePolicyText != nil {
+ ok := object.Key("lifecyclePolicyText")
+ ok.String(*v.LifecyclePolicyText)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutRegistryPolicyInput(v *PutRegistryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.PolicyText != nil {
+ ok := object.Key("policyText")
+ ok.String(*v.PolicyText)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutRegistryScanningConfigurationInput(v *PutRegistryScanningConfigurationInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Rules != nil {
+ ok := object.Key("rules")
+ if err := awsAwsjson11_serializeDocumentRegistryScanningRuleList(v.Rules, ok); err != nil {
+ return err
+ }
+ }
+
+ if len(v.ScanType) > 0 {
+ ok := object.Key("scanType")
+ ok.String(string(v.ScanType))
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutReplicationConfigurationInput(v *PutReplicationConfigurationInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ReplicationConfiguration != nil {
+ ok := object.Key("replicationConfiguration")
+ if err := awsAwsjson11_serializeDocumentReplicationConfiguration(v.ReplicationConfiguration, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentSetRepositoryPolicyInput(v *SetRepositoryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Force {
+ ok := object.Key("force")
+ ok.Boolean(v.Force)
+ }
+
+ if v.PolicyText != nil {
+ ok := object.Key("policyText")
+ ok.String(*v.PolicyText)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentStartImageScanInput(v *StartImageScanInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageId != nil {
+ ok := object.Key("imageId")
+ if err := awsAwsjson11_serializeDocumentImageIdentifier(v.ImageId, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentStartLifecyclePolicyPreviewInput(v *StartLifecyclePolicyPreviewInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LifecyclePolicyText != nil {
+ ok := object.Key("lifecyclePolicyText")
+ ok.String(*v.LifecyclePolicyText)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentTagResourceInput(v *TagResourceInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ResourceArn != nil {
+ ok := object.Key("resourceArn")
+ ok.String(*v.ResourceArn)
+ }
+
+ if v.Tags != nil {
+ ok := object.Key("tags")
+ if err := awsAwsjson11_serializeDocumentTagList(v.Tags, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentUntagResourceInput(v *UntagResourceInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ResourceArn != nil {
+ ok := object.Key("resourceArn")
+ ok.String(*v.ResourceArn)
+ }
+
+ if v.TagKeys != nil {
+ ok := object.Key("tagKeys")
+ if err := awsAwsjson11_serializeDocumentTagKeyList(v.TagKeys, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentUploadLayerPartInput(v *UploadLayerPartInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LayerPartBlob != nil {
+ ok := object.Key("layerPartBlob")
+ ok.Base64EncodeBytes(v.LayerPartBlob)
+ }
+
+ if v.PartFirstByte != nil {
+ ok := object.Key("partFirstByte")
+ ok.Long(*v.PartFirstByte)
+ }
+
+ if v.PartLastByte != nil {
+ ok := object.Key("partLastByte")
+ ok.Long(*v.PartLastByte)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ if v.UploadId != nil {
+ ok := object.Key("uploadId")
+ ok.String(*v.UploadId)
+ }
+
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/enums.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/enums.go
new file mode 100644
index 000000000000..9356aabf1bb0
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/enums.go
@@ -0,0 +1,324 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+type EncryptionType string
+
+// Enum values for EncryptionType
+const (
+ EncryptionTypeAes256 EncryptionType = "AES256"
+ EncryptionTypeKms EncryptionType = "KMS"
+)
+
+// Values returns all known values for EncryptionType. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (EncryptionType) Values() []EncryptionType {
+ return []EncryptionType{
+ "AES256",
+ "KMS",
+ }
+}
+
+type FindingSeverity string
+
+// Enum values for FindingSeverity
+const (
+ FindingSeverityInformational FindingSeverity = "INFORMATIONAL"
+ FindingSeverityLow FindingSeverity = "LOW"
+ FindingSeverityMedium FindingSeverity = "MEDIUM"
+ FindingSeverityHigh FindingSeverity = "HIGH"
+ FindingSeverityCritical FindingSeverity = "CRITICAL"
+ FindingSeverityUndefined FindingSeverity = "UNDEFINED"
+)
+
+// Values returns all known values for FindingSeverity. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (FindingSeverity) Values() []FindingSeverity {
+ return []FindingSeverity{
+ "INFORMATIONAL",
+ "LOW",
+ "MEDIUM",
+ "HIGH",
+ "CRITICAL",
+ "UNDEFINED",
+ }
+}
+
+type ImageActionType string
+
+// Enum values for ImageActionType
+const (
+ ImageActionTypeExpire ImageActionType = "EXPIRE"
+)
+
+// Values returns all known values for ImageActionType. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (ImageActionType) Values() []ImageActionType {
+ return []ImageActionType{
+ "EXPIRE",
+ }
+}
+
+type ImageFailureCode string
+
+// Enum values for ImageFailureCode
+const (
+ ImageFailureCodeInvalidImageDigest ImageFailureCode = "InvalidImageDigest"
+ ImageFailureCodeInvalidImageTag ImageFailureCode = "InvalidImageTag"
+ ImageFailureCodeImageTagDoesNotMatchDigest ImageFailureCode = "ImageTagDoesNotMatchDigest"
+ ImageFailureCodeImageNotFound ImageFailureCode = "ImageNotFound"
+ ImageFailureCodeMissingDigestAndTag ImageFailureCode = "MissingDigestAndTag"
+ ImageFailureCodeImageReferencedByManifestList ImageFailureCode = "ImageReferencedByManifestList"
+ ImageFailureCodeKmsError ImageFailureCode = "KmsError"
+)
+
+// Values returns all known values for ImageFailureCode. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (ImageFailureCode) Values() []ImageFailureCode {
+ return []ImageFailureCode{
+ "InvalidImageDigest",
+ "InvalidImageTag",
+ "ImageTagDoesNotMatchDigest",
+ "ImageNotFound",
+ "MissingDigestAndTag",
+ "ImageReferencedByManifestList",
+ "KmsError",
+ }
+}
+
+type ImageTagMutability string
+
+// Enum values for ImageTagMutability
+const (
+ ImageTagMutabilityMutable ImageTagMutability = "MUTABLE"
+ ImageTagMutabilityImmutable ImageTagMutability = "IMMUTABLE"
+)
+
+// Values returns all known values for ImageTagMutability. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (ImageTagMutability) Values() []ImageTagMutability {
+ return []ImageTagMutability{
+ "MUTABLE",
+ "IMMUTABLE",
+ }
+}
+
+type LayerAvailability string
+
+// Enum values for LayerAvailability
+const (
+ LayerAvailabilityAvailable LayerAvailability = "AVAILABLE"
+ LayerAvailabilityUnavailable LayerAvailability = "UNAVAILABLE"
+)
+
+// Values returns all known values for LayerAvailability. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (LayerAvailability) Values() []LayerAvailability {
+ return []LayerAvailability{
+ "AVAILABLE",
+ "UNAVAILABLE",
+ }
+}
+
+type LayerFailureCode string
+
+// Enum values for LayerFailureCode
+const (
+ LayerFailureCodeInvalidLayerDigest LayerFailureCode = "InvalidLayerDigest"
+ LayerFailureCodeMissingLayerDigest LayerFailureCode = "MissingLayerDigest"
+)
+
+// Values returns all known values for LayerFailureCode. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (LayerFailureCode) Values() []LayerFailureCode {
+ return []LayerFailureCode{
+ "InvalidLayerDigest",
+ "MissingLayerDigest",
+ }
+}
+
+type LifecyclePolicyPreviewStatus string
+
+// Enum values for LifecyclePolicyPreviewStatus
+const (
+ LifecyclePolicyPreviewStatusInProgress LifecyclePolicyPreviewStatus = "IN_PROGRESS"
+ LifecyclePolicyPreviewStatusComplete LifecyclePolicyPreviewStatus = "COMPLETE"
+ LifecyclePolicyPreviewStatusExpired LifecyclePolicyPreviewStatus = "EXPIRED"
+ LifecyclePolicyPreviewStatusFailed LifecyclePolicyPreviewStatus = "FAILED"
+)
+
+// Values returns all known values for LifecyclePolicyPreviewStatus. Note that this
+// can be expanded in the future, and so it is only as up to date as the client.
+// The ordering of this slice is not guaranteed to be stable across updates.
+func (LifecyclePolicyPreviewStatus) Values() []LifecyclePolicyPreviewStatus {
+ return []LifecyclePolicyPreviewStatus{
+ "IN_PROGRESS",
+ "COMPLETE",
+ "EXPIRED",
+ "FAILED",
+ }
+}
+
+type ReplicationStatus string
+
+// Enum values for ReplicationStatus
+const (
+ ReplicationStatusInProgress ReplicationStatus = "IN_PROGRESS"
+ ReplicationStatusComplete ReplicationStatus = "COMPLETE"
+ ReplicationStatusFailed ReplicationStatus = "FAILED"
+)
+
+// Values returns all known values for ReplicationStatus. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (ReplicationStatus) Values() []ReplicationStatus {
+ return []ReplicationStatus{
+ "IN_PROGRESS",
+ "COMPLETE",
+ "FAILED",
+ }
+}
+
+type RepositoryFilterType string
+
+// Enum values for RepositoryFilterType
+const (
+ RepositoryFilterTypePrefixMatch RepositoryFilterType = "PREFIX_MATCH"
+)
+
+// Values returns all known values for RepositoryFilterType. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (RepositoryFilterType) Values() []RepositoryFilterType {
+ return []RepositoryFilterType{
+ "PREFIX_MATCH",
+ }
+}
+
+type ScanFrequency string
+
+// Enum values for ScanFrequency
+const (
+ ScanFrequencyScanOnPush ScanFrequency = "SCAN_ON_PUSH"
+ ScanFrequencyContinuousScan ScanFrequency = "CONTINUOUS_SCAN"
+ ScanFrequencyManual ScanFrequency = "MANUAL"
+)
+
+// Values returns all known values for ScanFrequency. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (ScanFrequency) Values() []ScanFrequency {
+ return []ScanFrequency{
+ "SCAN_ON_PUSH",
+ "CONTINUOUS_SCAN",
+ "MANUAL",
+ }
+}
+
+type ScanningConfigurationFailureCode string
+
+// Enum values for ScanningConfigurationFailureCode
+const (
+ ScanningConfigurationFailureCodeRepositoryNotFound ScanningConfigurationFailureCode = "REPOSITORY_NOT_FOUND"
+)
+
+// Values returns all known values for ScanningConfigurationFailureCode. Note that
+// this can be expanded in the future, and so it is only as up to date as the
+// client. The ordering of this slice is not guaranteed to be stable across
+// updates.
+func (ScanningConfigurationFailureCode) Values() []ScanningConfigurationFailureCode {
+ return []ScanningConfigurationFailureCode{
+ "REPOSITORY_NOT_FOUND",
+ }
+}
+
+type ScanningRepositoryFilterType string
+
+// Enum values for ScanningRepositoryFilterType
+const (
+ ScanningRepositoryFilterTypeWildcard ScanningRepositoryFilterType = "WILDCARD"
+)
+
+// Values returns all known values for ScanningRepositoryFilterType. Note that this
+// can be expanded in the future, and so it is only as up to date as the client.
+// The ordering of this slice is not guaranteed to be stable across updates.
+func (ScanningRepositoryFilterType) Values() []ScanningRepositoryFilterType {
+ return []ScanningRepositoryFilterType{
+ "WILDCARD",
+ }
+}
+
+type ScanStatus string
+
+// Enum values for ScanStatus
+const (
+ ScanStatusInProgress ScanStatus = "IN_PROGRESS"
+ ScanStatusComplete ScanStatus = "COMPLETE"
+ ScanStatusFailed ScanStatus = "FAILED"
+ ScanStatusUnsupportedImage ScanStatus = "UNSUPPORTED_IMAGE"
+ ScanStatusActive ScanStatus = "ACTIVE"
+ ScanStatusPending ScanStatus = "PENDING"
+ ScanStatusScanEligibilityExpired ScanStatus = "SCAN_ELIGIBILITY_EXPIRED"
+ ScanStatusFindingsUnavailable ScanStatus = "FINDINGS_UNAVAILABLE"
+)
+
+// Values returns all known values for ScanStatus. Note that this can be expanded
+// in the future, and so it is only as up to date as the client. The ordering of
+// this slice is not guaranteed to be stable across updates.
+func (ScanStatus) Values() []ScanStatus {
+ return []ScanStatus{
+ "IN_PROGRESS",
+ "COMPLETE",
+ "FAILED",
+ "UNSUPPORTED_IMAGE",
+ "ACTIVE",
+ "PENDING",
+ "SCAN_ELIGIBILITY_EXPIRED",
+ "FINDINGS_UNAVAILABLE",
+ }
+}
+
+type ScanType string
+
+// Enum values for ScanType
+const (
+ ScanTypeBasic ScanType = "BASIC"
+ ScanTypeEnhanced ScanType = "ENHANCED"
+)
+
+// Values returns all known values for ScanType. Note that this can be expanded in
+// the future, and so it is only as up to date as the client. The ordering of this
+// slice is not guaranteed to be stable across updates.
+func (ScanType) Values() []ScanType {
+ return []ScanType{
+ "BASIC",
+ "ENHANCED",
+ }
+}
+
+type TagStatus string
+
+// Enum values for TagStatus
+const (
+ TagStatusTagged TagStatus = "TAGGED"
+ TagStatusUntagged TagStatus = "UNTAGGED"
+ TagStatusAny TagStatus = "ANY"
+)
+
+// Values returns all known values for TagStatus. Note that this can be expanded in
+// the future, and so it is only as up to date as the client. The ordering of this
+// slice is not guaranteed to be stable across updates.
+func (TagStatus) Values() []TagStatus {
+ return []TagStatus{
+ "TAGGED",
+ "UNTAGGED",
+ "ANY",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/errors.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/errors.go
new file mode 100644
index 000000000000..944907efd141
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/errors.go
@@ -0,0 +1,697 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+import (
+ "fmt"
+ smithy "github.com/aws/smithy-go"
+)
+
+// The specified layer upload does not contain any layer parts.
+type EmptyUploadException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *EmptyUploadException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *EmptyUploadException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *EmptyUploadException) ErrorCode() string { return "EmptyUploadException" }
+func (e *EmptyUploadException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified image has already been pushed, and there were no changes to the
+// manifest or image tag after the last push.
+type ImageAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ImageAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ImageAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ImageAlreadyExistsException) ErrorCode() string { return "ImageAlreadyExistsException" }
+func (e *ImageAlreadyExistsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified image digest does not match the digest that Amazon ECR calculated
+// for the image.
+type ImageDigestDoesNotMatchException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ImageDigestDoesNotMatchException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ImageDigestDoesNotMatchException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ImageDigestDoesNotMatchException) ErrorCode() string {
+ return "ImageDigestDoesNotMatchException"
+}
+func (e *ImageDigestDoesNotMatchException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The image requested does not exist in the specified repository.
+type ImageNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ImageNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ImageNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ImageNotFoundException) ErrorCode() string { return "ImageNotFoundException" }
+func (e *ImageNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified image is tagged with a tag that already exists. The repository is
+// configured for tag immutability.
+type ImageTagAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ImageTagAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ImageTagAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ImageTagAlreadyExistsException) ErrorCode() string { return "ImageTagAlreadyExistsException" }
+func (e *ImageTagAlreadyExistsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The layer digest calculation performed by Amazon ECR upon receipt of the image
+// layer does not match the digest specified.
+type InvalidLayerException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidLayerException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidLayerException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidLayerException) ErrorCode() string { return "InvalidLayerException" }
+func (e *InvalidLayerException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The layer part size is not valid, or the first byte specified is not consecutive
+// to the last byte of a previous layer part upload.
+type InvalidLayerPartException struct {
+ Message *string
+
+ RegistryId *string
+ RepositoryName *string
+ UploadId *string
+ LastValidByteReceived *int64
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidLayerPartException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidLayerPartException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidLayerPartException) ErrorCode() string { return "InvalidLayerPartException" }
+func (e *InvalidLayerPartException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified parameter is invalid. Review the available parameters for the API
+// request.
+type InvalidParameterException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidParameterException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidParameterException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidParameterException) ErrorCode() string { return "InvalidParameterException" }
+func (e *InvalidParameterException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// An invalid parameter has been specified. Tag keys can have a maximum character
+// length of 128 characters, and tag values can have a maximum length of 256
+// characters.
+type InvalidTagParameterException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidTagParameterException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidTagParameterException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidTagParameterException) ErrorCode() string { return "InvalidTagParameterException" }
+func (e *InvalidTagParameterException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The operation failed due to a KMS exception.
+type KmsException struct {
+ Message *string
+
+ KmsError *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *KmsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *KmsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *KmsException) ErrorCode() string { return "KmsException" }
+func (e *KmsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The image layer already exists in the associated repository.
+type LayerAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LayerAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LayerAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LayerAlreadyExistsException) ErrorCode() string { return "LayerAlreadyExistsException" }
+func (e *LayerAlreadyExistsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified layer is not available because it is not associated with an image.
+// Unassociated image layers may be cleaned up at any time.
+type LayerInaccessibleException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LayerInaccessibleException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LayerInaccessibleException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LayerInaccessibleException) ErrorCode() string { return "LayerInaccessibleException" }
+func (e *LayerInaccessibleException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// Layer parts must be at least 5 MiB in size.
+type LayerPartTooSmallException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LayerPartTooSmallException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LayerPartTooSmallException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LayerPartTooSmallException) ErrorCode() string { return "LayerPartTooSmallException" }
+func (e *LayerPartTooSmallException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified layers could not be found, or the specified layer is not valid for
+// this repository.
+type LayersNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LayersNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LayersNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LayersNotFoundException) ErrorCode() string { return "LayersNotFoundException" }
+func (e *LayersNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The lifecycle policy could not be found, and no policy is set to the repository.
+type LifecyclePolicyNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LifecyclePolicyNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LifecyclePolicyNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LifecyclePolicyNotFoundException) ErrorCode() string {
+ return "LifecyclePolicyNotFoundException"
+}
+func (e *LifecyclePolicyNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The previous lifecycle policy preview request has not completed. Wait and try
+// again.
+type LifecyclePolicyPreviewInProgressException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LifecyclePolicyPreviewInProgressException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LifecyclePolicyPreviewInProgressException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LifecyclePolicyPreviewInProgressException) ErrorCode() string {
+ return "LifecyclePolicyPreviewInProgressException"
+}
+func (e *LifecyclePolicyPreviewInProgressException) ErrorFault() smithy.ErrorFault {
+ return smithy.FaultClient
+}
+
+// There is no dry run for this repository.
+type LifecyclePolicyPreviewNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LifecyclePolicyPreviewNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LifecyclePolicyPreviewNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LifecyclePolicyPreviewNotFoundException) ErrorCode() string {
+ return "LifecyclePolicyPreviewNotFoundException"
+}
+func (e *LifecyclePolicyPreviewNotFoundException) ErrorFault() smithy.ErrorFault {
+ return smithy.FaultClient
+}
+
+// The operation did not succeed because it would have exceeded a service limit for
+// your account. For more information, see Amazon ECR service quotas
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html) in
+// the Amazon Elastic Container Registry User Guide.
+type LimitExceededException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LimitExceededException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LimitExceededException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LimitExceededException) ErrorCode() string { return "LimitExceededException" }
+func (e *LimitExceededException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// A pull through cache rule with these settings already exists for the private
+// registry.
+type PullThroughCacheRuleAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *PullThroughCacheRuleAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *PullThroughCacheRuleAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *PullThroughCacheRuleAlreadyExistsException) ErrorCode() string {
+ return "PullThroughCacheRuleAlreadyExistsException"
+}
+func (e *PullThroughCacheRuleAlreadyExistsException) ErrorFault() smithy.ErrorFault {
+ return smithy.FaultClient
+}
+
+// The pull through cache rule was not found. Specify a valid pull through cache
+// rule and try again.
+type PullThroughCacheRuleNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *PullThroughCacheRuleNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *PullThroughCacheRuleNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *PullThroughCacheRuleNotFoundException) ErrorCode() string {
+ return "PullThroughCacheRuleNotFoundException"
+}
+func (e *PullThroughCacheRuleNotFoundException) ErrorFault() smithy.ErrorFault {
+ return smithy.FaultClient
+}
+
+// The manifest list is referencing an image that does not exist.
+type ReferencedImagesNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ReferencedImagesNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ReferencedImagesNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ReferencedImagesNotFoundException) ErrorCode() string {
+ return "ReferencedImagesNotFoundException"
+}
+func (e *ReferencedImagesNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The registry doesn't have an associated registry policy.
+type RegistryPolicyNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RegistryPolicyNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RegistryPolicyNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RegistryPolicyNotFoundException) ErrorCode() string {
+ return "RegistryPolicyNotFoundException"
+}
+func (e *RegistryPolicyNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified repository already exists in the specified registry.
+type RepositoryAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RepositoryAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RepositoryAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RepositoryAlreadyExistsException) ErrorCode() string {
+ return "RepositoryAlreadyExistsException"
+}
+func (e *RepositoryAlreadyExistsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified repository contains images. To delete a repository that contains
+// images, you must force the deletion with the force parameter.
+type RepositoryNotEmptyException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RepositoryNotEmptyException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RepositoryNotEmptyException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RepositoryNotEmptyException) ErrorCode() string { return "RepositoryNotEmptyException" }
+func (e *RepositoryNotEmptyException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified repository could not be found. Check the spelling of the specified
+// repository and ensure that you are performing operations on the correct
+// registry.
+type RepositoryNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RepositoryNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RepositoryNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RepositoryNotFoundException) ErrorCode() string { return "RepositoryNotFoundException" }
+func (e *RepositoryNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified repository and registry combination does not have an associated
+// repository policy.
+type RepositoryPolicyNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RepositoryPolicyNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RepositoryPolicyNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RepositoryPolicyNotFoundException) ErrorCode() string {
+ return "RepositoryPolicyNotFoundException"
+}
+func (e *RepositoryPolicyNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified image scan could not be found. Ensure that image scanning is
+// enabled on the repository and try again.
+type ScanNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ScanNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ScanNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ScanNotFoundException) ErrorCode() string { return "ScanNotFoundException" }
+func (e *ScanNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// These errors are usually caused by a server-side issue.
+type ServerException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ServerException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ServerException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ServerException) ErrorCode() string { return "ServerException" }
+func (e *ServerException) ErrorFault() smithy.ErrorFault { return smithy.FaultServer }
+
+// The list of tags on the repository is over the limit. The maximum number of tags
+// that can be applied to a repository is 50.
+type TooManyTagsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *TooManyTagsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *TooManyTagsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *TooManyTagsException) ErrorCode() string { return "TooManyTagsException" }
+func (e *TooManyTagsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The image is of a type that cannot be scanned.
+type UnsupportedImageTypeException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *UnsupportedImageTypeException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *UnsupportedImageTypeException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *UnsupportedImageTypeException) ErrorCode() string { return "UnsupportedImageTypeException" }
+func (e *UnsupportedImageTypeException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified upstream registry isn't supported.
+type UnsupportedUpstreamRegistryException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *UnsupportedUpstreamRegistryException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *UnsupportedUpstreamRegistryException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *UnsupportedUpstreamRegistryException) ErrorCode() string {
+ return "UnsupportedUpstreamRegistryException"
+}
+func (e *UnsupportedUpstreamRegistryException) ErrorFault() smithy.ErrorFault {
+ return smithy.FaultClient
+}
+
+// The upload could not be found, or the specified upload ID is not valid for this
+// repository.
+type UploadNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *UploadNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *UploadNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *UploadNotFoundException) ErrorCode() string { return "UploadNotFoundException" }
+func (e *UploadNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// There was an exception validating this request.
+type ValidationException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ValidationException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ValidationException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ValidationException) ErrorCode() string { return "ValidationException" }
+func (e *ValidationException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/types.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/types.go
new file mode 100644
index 000000000000..2e79d0731cce
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/types/types.go
@@ -0,0 +1,867 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+import (
+ smithydocument "github.com/aws/smithy-go/document"
+ "time"
+)
+
+// This data type is used in the ImageScanFinding data type.
+type Attribute struct {
+
+ // The attribute key.
+ //
+ // This member is required.
+ Key *string
+
+ // The value assigned to the attribute key.
+ Value *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing authorization data for an Amazon ECR registry.
+type AuthorizationData struct {
+
+ // A base64-encoded string that contains authorization data for the specified
+ // Amazon ECR registry. When the string is decoded, it is presented in the format
+ // user:password for private registry authentication using docker login.
+ AuthorizationToken *string
+
+ // The Unix time in seconds and milliseconds when the authorization token expires.
+ // Authorization tokens are valid for 12 hours.
+ ExpiresAt *time.Time
+
+ // The registry URL to use for this authorization token in a docker login command.
+ // The Amazon ECR registry URL format is
+ // https://aws_account_id.dkr.ecr.region.amazonaws.com. For example,
+ // https://012345678910.dkr.ecr.us-east-1.amazonaws.com..
+ ProxyEndpoint *string
+
+ noSmithyDocumentSerde
+}
+
+// The image details of the Amazon ECR container image.
+type AwsEcrContainerImageDetails struct {
+
+ // The architecture of the Amazon ECR container image.
+ Architecture *string
+
+ // The image author of the Amazon ECR container image.
+ Author *string
+
+ // The image hash of the Amazon ECR container image.
+ ImageHash *string
+
+ // The image tags attached to the Amazon ECR container image.
+ ImageTags []string
+
+ // The platform of the Amazon ECR container image.
+ Platform *string
+
+ // The date and time the Amazon ECR container image was pushed.
+ PushedAt *time.Time
+
+ // The registry the Amazon ECR container image belongs to.
+ Registry *string
+
+ // The name of the repository the Amazon ECR container image resides in.
+ RepositoryName *string
+
+ noSmithyDocumentSerde
+}
+
+// The CVSS score for a finding.
+type CvssScore struct {
+
+ // The base CVSS score used for the finding.
+ BaseScore float64
+
+ // The vector string of the CVSS score.
+ ScoringVector *string
+
+ // The source of the CVSS score.
+ Source *string
+
+ // The version of CVSS used for the score.
+ Version *string
+
+ noSmithyDocumentSerde
+}
+
+// Details on adjustments Amazon Inspector made to the CVSS score for a finding.
+type CvssScoreAdjustment struct {
+
+ // The metric used to adjust the CVSS score.
+ Metric *string
+
+ // The reason the CVSS score has been adjustment.
+ Reason *string
+
+ noSmithyDocumentSerde
+}
+
+// Information about the CVSS score.
+type CvssScoreDetails struct {
+
+ // An object that contains details about adjustment Amazon Inspector made to the
+ // CVSS score.
+ Adjustments []CvssScoreAdjustment
+
+ // The CVSS score.
+ Score float64
+
+ // The source for the CVSS score.
+ ScoreSource *string
+
+ // The vector for the CVSS score.
+ ScoringVector *string
+
+ // The CVSS version used in scoring.
+ Version *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing a filter on a DescribeImages operation.
+type DescribeImagesFilter struct {
+
+ // The tag status with which to filter your DescribeImages results. You can filter
+ // results based on whether they are TAGGED or UNTAGGED.
+ TagStatus TagStatus
+
+ noSmithyDocumentSerde
+}
+
+// The encryption configuration for the repository. This determines how the
+// contents of your repository are encrypted at rest. By default, when no
+// encryption configuration is set or the AES256 encryption type is used, Amazon
+// ECR uses server-side encryption with Amazon S3-managed encryption keys which
+// encrypts your data at rest using an AES-256 encryption algorithm. This does not
+// require any action on your part. For more control over the encryption of the
+// contents of your repository, you can use server-side encryption with Key
+// Management Service key stored in Key Management Service (KMS) to encrypt your
+// images. For more information, see Amazon ECR encryption at rest
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/encryption-at-rest.html)
+// in the Amazon Elastic Container Registry User Guide.
+type EncryptionConfiguration struct {
+
+ // The encryption type to use. If you use the KMS encryption type, the contents of
+ // the repository will be encrypted using server-side encryption with Key
+ // Management Service key stored in KMS. When you use KMS to encrypt your data, you
+ // can either use the default Amazon Web Services managed KMS key for Amazon ECR,
+ // or specify your own KMS key, which you already created. For more information,
+ // see Protecting data using server-side encryption with an KMS key stored in Key
+ // Management Service (SSE-KMS)
+ // (https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingKMSEncryption.html) in the
+ // Amazon Simple Storage Service Console Developer Guide. If you use the AES256
+ // encryption type, Amazon ECR uses server-side encryption with Amazon S3-managed
+ // encryption keys which encrypts the images in the repository using an AES-256
+ // encryption algorithm. For more information, see Protecting data using
+ // server-side encryption with Amazon S3-managed encryption keys (SSE-S3)
+ // (https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html)
+ // in the Amazon Simple Storage Service Console Developer Guide.
+ //
+ // This member is required.
+ EncryptionType EncryptionType
+
+ // If you use the KMS encryption type, specify the KMS key to use for encryption.
+ // The alias, key ID, or full ARN of the KMS key can be specified. The key must
+ // exist in the same Region as the repository. If no key is specified, the default
+ // Amazon Web Services managed KMS key for Amazon ECR will be used.
+ KmsKey *string
+
+ noSmithyDocumentSerde
+}
+
+// The details of an enhanced image scan. This is returned when enhanced scanning
+// is enabled for your private registry.
+type EnhancedImageScanFinding struct {
+
+ // The Amazon Web Services account ID associated with the image.
+ AwsAccountId *string
+
+ // The description of the finding.
+ Description *string
+
+ // The Amazon Resource Number (ARN) of the finding.
+ FindingArn *string
+
+ // The date and time that the finding was first observed.
+ FirstObservedAt *time.Time
+
+ // The date and time that the finding was last observed.
+ LastObservedAt *time.Time
+
+ // An object that contains the details of a package vulnerability finding.
+ PackageVulnerabilityDetails *PackageVulnerabilityDetails
+
+ // An object that contains the details about how to remediate a finding.
+ Remediation *Remediation
+
+ // Contains information on the resources involved in a finding.
+ Resources []Resource
+
+ // The Amazon Inspector score given to the finding.
+ Score float64
+
+ // An object that contains details of the Amazon Inspector score.
+ ScoreDetails *ScoreDetails
+
+ // The severity of the finding.
+ Severity *string
+
+ // The status of the finding.
+ Status *string
+
+ // The title of the finding.
+ Title *string
+
+ // The type of the finding.
+ Type *string
+
+ // The date and time the finding was last updated at.
+ UpdatedAt *time.Time
+
+ noSmithyDocumentSerde
+}
+
+// An object representing an Amazon ECR image.
+type Image struct {
+
+ // An object containing the image tag and image digest associated with an image.
+ ImageId *ImageIdentifier
+
+ // The image manifest associated with the image.
+ ImageManifest *string
+
+ // The manifest media type of the image.
+ ImageManifestMediaType *string
+
+ // The Amazon Web Services account ID associated with the registry containing the
+ // image.
+ RegistryId *string
+
+ // The name of the repository associated with the image.
+ RepositoryName *string
+
+ noSmithyDocumentSerde
+}
+
+// An object that describes an image returned by a DescribeImages operation.
+type ImageDetail struct {
+
+ // The artifact media type of the image.
+ ArtifactMediaType *string
+
+ // The sha256 digest of the image manifest.
+ ImageDigest *string
+
+ // The media type of the image manifest.
+ ImageManifestMediaType *string
+
+ // The date and time, expressed in standard JavaScript date format, at which the
+ // current image was pushed to the repository.
+ ImagePushedAt *time.Time
+
+ // A summary of the last completed image scan.
+ ImageScanFindingsSummary *ImageScanFindingsSummary
+
+ // The current state of the scan.
+ ImageScanStatus *ImageScanStatus
+
+ // The size, in bytes, of the image in the repository. If the image is a manifest
+ // list, this will be the max size of all manifests in the list. Beginning with
+ // Docker version 1.9, the Docker client compresses image layers before pushing
+ // them to a V2 Docker registry. The output of the docker images command shows the
+ // uncompressed image size, so it may return a larger image size than the image
+ // sizes returned by DescribeImages.
+ ImageSizeInBytes *int64
+
+ // The list of tags associated with this image.
+ ImageTags []string
+
+ // The Amazon Web Services account ID associated with the registry to which this
+ // image belongs.
+ RegistryId *string
+
+ // The name of the repository to which this image belongs.
+ RepositoryName *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing an Amazon ECR image failure.
+type ImageFailure struct {
+
+ // The code associated with the failure.
+ FailureCode ImageFailureCode
+
+ // The reason for the failure.
+ FailureReason *string
+
+ // The image ID associated with the failure.
+ ImageId *ImageIdentifier
+
+ noSmithyDocumentSerde
+}
+
+// An object with identifying information for an image in an Amazon ECR repository.
+type ImageIdentifier struct {
+
+ // The sha256 digest of the image manifest.
+ ImageDigest *string
+
+ // The tag used for the image.
+ ImageTag *string
+
+ noSmithyDocumentSerde
+}
+
+// The status of the replication process for an image.
+type ImageReplicationStatus struct {
+
+ // The failure code for a replication that has failed.
+ FailureCode *string
+
+ // The destination Region for the image replication.
+ Region *string
+
+ // The Amazon Web Services account ID associated with the registry to which the
+ // image belongs.
+ RegistryId *string
+
+ // The image replication status.
+ Status ReplicationStatus
+
+ noSmithyDocumentSerde
+}
+
+// Contains information about an image scan finding.
+type ImageScanFinding struct {
+
+ // A collection of attributes of the host from which the finding is generated.
+ Attributes []Attribute
+
+ // The description of the finding.
+ Description *string
+
+ // The name associated with the finding, usually a CVE number.
+ Name *string
+
+ // The finding severity.
+ Severity FindingSeverity
+
+ // A link containing additional details about the security vulnerability.
+ Uri *string
+
+ noSmithyDocumentSerde
+}
+
+// The details of an image scan.
+type ImageScanFindings struct {
+
+ // Details about the enhanced scan findings from Amazon Inspector.
+ EnhancedFindings []EnhancedImageScanFinding
+
+ // The image vulnerability counts, sorted by severity.
+ FindingSeverityCounts map[string]int32
+
+ // The findings from the image scan.
+ Findings []ImageScanFinding
+
+ // The time of the last completed image scan.
+ ImageScanCompletedAt *time.Time
+
+ // The time when the vulnerability data was last scanned.
+ VulnerabilitySourceUpdatedAt *time.Time
+
+ noSmithyDocumentSerde
+}
+
+// A summary of the last completed image scan.
+type ImageScanFindingsSummary struct {
+
+ // The image vulnerability counts, sorted by severity.
+ FindingSeverityCounts map[string]int32
+
+ // The time of the last completed image scan.
+ ImageScanCompletedAt *time.Time
+
+ // The time when the vulnerability data was last scanned.
+ VulnerabilitySourceUpdatedAt *time.Time
+
+ noSmithyDocumentSerde
+}
+
+// The image scanning configuration for a repository.
+type ImageScanningConfiguration struct {
+
+ // The setting that determines whether images are scanned after being pushed to a
+ // repository. If set to true, images will be scanned after being pushed. If this
+ // parameter is not specified, it will default to false and images will not be
+ // scanned unless a scan is manually started with the API_StartImageScan
+ // (https://docs.aws.amazon.com/AmazonECR/latest/APIReference/API_StartImageScan.html)
+ // API.
+ ScanOnPush bool
+
+ noSmithyDocumentSerde
+}
+
+// The current status of an image scan.
+type ImageScanStatus struct {
+
+ // The description of the image scan status.
+ Description *string
+
+ // The current state of an image scan.
+ Status ScanStatus
+
+ noSmithyDocumentSerde
+}
+
+// An object representing an Amazon ECR image layer.
+type Layer struct {
+
+ // The availability status of the image layer.
+ LayerAvailability LayerAvailability
+
+ // The sha256 digest of the image layer.
+ LayerDigest *string
+
+ // The size, in bytes, of the image layer.
+ LayerSize *int64
+
+ // The media type of the layer, such as
+ // application/vnd.docker.image.rootfs.diff.tar.gzip or
+ // application/vnd.oci.image.layer.v1.tar+gzip.
+ MediaType *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing an Amazon ECR image layer failure.
+type LayerFailure struct {
+
+ // The failure code associated with the failure.
+ FailureCode LayerFailureCode
+
+ // The reason for the failure.
+ FailureReason *string
+
+ // The layer digest associated with the failure.
+ LayerDigest *string
+
+ noSmithyDocumentSerde
+}
+
+// The filter for the lifecycle policy preview.
+type LifecyclePolicyPreviewFilter struct {
+
+ // The tag status of the image.
+ TagStatus TagStatus
+
+ noSmithyDocumentSerde
+}
+
+// The result of the lifecycle policy preview.
+type LifecyclePolicyPreviewResult struct {
+
+ // The type of action to be taken.
+ Action *LifecyclePolicyRuleAction
+
+ // The priority of the applied rule.
+ AppliedRulePriority *int32
+
+ // The sha256 digest of the image manifest.
+ ImageDigest *string
+
+ // The date and time, expressed in standard JavaScript date format, at which the
+ // current image was pushed to the repository.
+ ImagePushedAt *time.Time
+
+ // The list of tags associated with this image.
+ ImageTags []string
+
+ noSmithyDocumentSerde
+}
+
+// The summary of the lifecycle policy preview request.
+type LifecyclePolicyPreviewSummary struct {
+
+ // The number of expiring images.
+ ExpiringImageTotalCount *int32
+
+ noSmithyDocumentSerde
+}
+
+// The type of action to be taken.
+type LifecyclePolicyRuleAction struct {
+
+ // The type of action to be taken.
+ Type ImageActionType
+
+ noSmithyDocumentSerde
+}
+
+// An object representing a filter on a ListImages operation.
+type ListImagesFilter struct {
+
+ // The tag status with which to filter your ListImages results. You can filter
+ // results based on whether they are TAGGED or UNTAGGED.
+ TagStatus TagStatus
+
+ noSmithyDocumentSerde
+}
+
+// Information about a package vulnerability finding.
+type PackageVulnerabilityDetails struct {
+
+ // An object that contains details about the CVSS score of a finding.
+ Cvss []CvssScore
+
+ // One or more URLs that contain details about this vulnerability type.
+ ReferenceUrls []string
+
+ // One or more vulnerabilities related to the one identified in this finding.
+ RelatedVulnerabilities []string
+
+ // The source of the vulnerability information.
+ Source *string
+
+ // A URL to the source of the vulnerability information.
+ SourceUrl *string
+
+ // The date and time that this vulnerability was first added to the vendor's
+ // database.
+ VendorCreatedAt *time.Time
+
+ // The severity the vendor has given to this vulnerability type.
+ VendorSeverity *string
+
+ // The date and time the vendor last updated this vulnerability in their database.
+ VendorUpdatedAt *time.Time
+
+ // The ID given to this vulnerability.
+ VulnerabilityId *string
+
+ // The packages impacted by this vulnerability.
+ VulnerablePackages []VulnerablePackage
+
+ noSmithyDocumentSerde
+}
+
+// The details of a pull through cache rule.
+type PullThroughCacheRule struct {
+
+ // The date and time the pull through cache was created.
+ CreatedAt *time.Time
+
+ // The Amazon ECR repository prefix associated with the pull through cache rule.
+ EcrRepositoryPrefix *string
+
+ // The Amazon Web Services account ID associated with the registry the pull through
+ // cache rule is associated with.
+ RegistryId *string
+
+ // The upstream registry URL associated with the pull through cache rule.
+ UpstreamRegistryUrl *string
+
+ noSmithyDocumentSerde
+}
+
+// Details about the recommended course of action to remediate the finding.
+type Recommendation struct {
+
+ // The recommended course of action to remediate the finding.
+ Text *string
+
+ // The URL address to the CVE remediation recommendations.
+ Url *string
+
+ noSmithyDocumentSerde
+}
+
+// The scanning configuration for a private registry.
+type RegistryScanningConfiguration struct {
+
+ // The scanning rules associated with the registry.
+ Rules []RegistryScanningRule
+
+ // The type of scanning configured for the registry.
+ ScanType ScanType
+
+ noSmithyDocumentSerde
+}
+
+// The details of a scanning rule for a private registry.
+type RegistryScanningRule struct {
+
+ // The repository filters associated with the scanning configuration for a private
+ // registry.
+ //
+ // This member is required.
+ RepositoryFilters []ScanningRepositoryFilter
+
+ // The frequency that scans are performed at for a private registry.
+ //
+ // This member is required.
+ ScanFrequency ScanFrequency
+
+ noSmithyDocumentSerde
+}
+
+// Information on how to remediate a finding.
+type Remediation struct {
+
+ // An object that contains information about the recommended course of action to
+ // remediate the finding.
+ Recommendation *Recommendation
+
+ noSmithyDocumentSerde
+}
+
+// The replication configuration for a registry.
+type ReplicationConfiguration struct {
+
+ // An array of objects representing the replication destinations and repository
+ // filters for a replication configuration.
+ //
+ // This member is required.
+ Rules []ReplicationRule
+
+ noSmithyDocumentSerde
+}
+
+// An array of objects representing the destination for a replication rule.
+type ReplicationDestination struct {
+
+ // The Region to replicate to.
+ //
+ // This member is required.
+ Region *string
+
+ // The Amazon Web Services account ID of the Amazon ECR private registry to
+ // replicate to. When configuring cross-Region replication within your own
+ // registry, specify your own account ID.
+ //
+ // This member is required.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+// An array of objects representing the replication destinations and repository
+// filters for a replication configuration.
+type ReplicationRule struct {
+
+ // An array of objects representing the destination for a replication rule.
+ //
+ // This member is required.
+ Destinations []ReplicationDestination
+
+ // An array of objects representing the filters for a replication rule. Specifying
+ // a repository filter for a replication rule provides a method for controlling
+ // which repositories in a private registry are replicated.
+ RepositoryFilters []RepositoryFilter
+
+ noSmithyDocumentSerde
+}
+
+// An object representing a repository.
+type Repository struct {
+
+ // The date and time, in JavaScript date format, when the repository was created.
+ CreatedAt *time.Time
+
+ // The encryption configuration for the repository. This determines how the
+ // contents of your repository are encrypted at rest.
+ EncryptionConfiguration *EncryptionConfiguration
+
+ // The image scanning configuration for a repository.
+ ImageScanningConfiguration *ImageScanningConfiguration
+
+ // The tag mutability setting for the repository.
+ ImageTagMutability ImageTagMutability
+
+ // The Amazon Web Services account ID associated with the registry that contains
+ // the repository.
+ RegistryId *string
+
+ // The Amazon Resource Name (ARN) that identifies the repository. The ARN contains
+ // the arn:aws:ecr namespace, followed by the region of the repository, Amazon Web
+ // Services account ID of the repository owner, repository namespace, and
+ // repository name. For example, arn:aws:ecr:region:012345678910:repository/test.
+ RepositoryArn *string
+
+ // The name of the repository.
+ RepositoryName *string
+
+ // The URI for the repository. You can use this URI for container image push and
+ // pull operations.
+ RepositoryUri *string
+
+ noSmithyDocumentSerde
+}
+
+// The filter settings used with image replication. Specifying a repository filter
+// to a replication rule provides a method for controlling which repositories in a
+// private registry are replicated. If no repository filter is specified, all
+// images in the repository are replicated.
+type RepositoryFilter struct {
+
+ // The repository filter details. When the PREFIX_MATCH filter type is specified,
+ // this value is required and should be the repository name prefix to configure
+ // replication for.
+ //
+ // This member is required.
+ Filter *string
+
+ // The repository filter type. The only supported value is PREFIX_MATCH, which is a
+ // repository name prefix specified with the filter parameter.
+ //
+ // This member is required.
+ FilterType RepositoryFilterType
+
+ noSmithyDocumentSerde
+}
+
+// The details of the scanning configuration for a repository.
+type RepositoryScanningConfiguration struct {
+
+ // The scan filters applied to the repository.
+ AppliedScanFilters []ScanningRepositoryFilter
+
+ // The ARN of the repository.
+ RepositoryArn *string
+
+ // The name of the repository.
+ RepositoryName *string
+
+ // The scan frequency for the repository.
+ ScanFrequency ScanFrequency
+
+ // Whether or not scan on push is configured for the repository.
+ ScanOnPush bool
+
+ noSmithyDocumentSerde
+}
+
+// The details about any failures associated with the scanning configuration of a
+// repository.
+type RepositoryScanningConfigurationFailure struct {
+
+ // The failure code.
+ FailureCode ScanningConfigurationFailureCode
+
+ // The reason for the failure.
+ FailureReason *string
+
+ // The name of the repository.
+ RepositoryName *string
+
+ noSmithyDocumentSerde
+}
+
+// Details about the resource involved in a finding.
+type Resource struct {
+
+ // An object that contains details about the resource involved in a finding.
+ Details *ResourceDetails
+
+ // The ID of the resource.
+ Id *string
+
+ // The tags attached to the resource.
+ Tags map[string]string
+
+ // The type of resource.
+ Type *string
+
+ noSmithyDocumentSerde
+}
+
+// Contains details about the resource involved in the finding.
+type ResourceDetails struct {
+
+ // An object that contains details about the Amazon ECR container image involved in
+ // the finding.
+ AwsEcrContainerImage *AwsEcrContainerImageDetails
+
+ noSmithyDocumentSerde
+}
+
+// The details of a scanning repository filter.
+type ScanningRepositoryFilter struct {
+
+ // The filter to use when scanning.
+ //
+ // This member is required.
+ Filter *string
+
+ // The type associated with the filter.
+ //
+ // This member is required.
+ FilterType ScanningRepositoryFilterType
+
+ noSmithyDocumentSerde
+}
+
+// Information about the Amazon Inspector score given to a finding.
+type ScoreDetails struct {
+
+ // An object that contains details about the CVSS score given to a finding.
+ Cvss *CvssScoreDetails
+
+ noSmithyDocumentSerde
+}
+
+// The metadata that you apply to a resource to help you categorize and organize
+// them. Each tag consists of a key and an optional value, both of which you
+// define. Tag keys can have a maximum character length of 128 characters, and tag
+// values can have a maximum length of 256 characters.
+type Tag struct {
+
+ // One part of a key-value pair that make up a tag. A key is a general label that
+ // acts like a category for more specific tag values.
+ Key *string
+
+ // The optional part of a key-value pair that make up a tag. A value acts as a
+ // descriptor within a tag category (key).
+ Value *string
+
+ noSmithyDocumentSerde
+}
+
+// Information on the vulnerable package identified by a finding.
+type VulnerablePackage struct {
+
+ // The architecture of the vulnerable package.
+ Arch *string
+
+ // The epoch of the vulnerable package.
+ Epoch *int32
+
+ // The file path of the vulnerable package.
+ FilePath *string
+
+ // The name of the vulnerable package.
+ Name *string
+
+ // The package manager of the vulnerable package.
+ PackageManager *string
+
+ // The release of the vulnerable package.
+ Release *string
+
+ // The source layer hash of the vulnerable package.
+ SourceLayerHash *string
+
+ // The version of the vulnerable package.
+ Version *string
+
+ noSmithyDocumentSerde
+}
+
+type noSmithyDocumentSerde = smithydocument.NoSerde
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/validators.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/validators.go
new file mode 100644
index 000000000000..9baf8c8cffe5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecr/validators.go
@@ -0,0 +1,1630 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecr
+
+import (
+ "context"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/service/ecr/types"
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/middleware"
+)
+
+type validateOpBatchCheckLayerAvailability struct {
+}
+
+func (*validateOpBatchCheckLayerAvailability) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpBatchCheckLayerAvailability) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*BatchCheckLayerAvailabilityInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpBatchCheckLayerAvailabilityInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpBatchDeleteImage struct {
+}
+
+func (*validateOpBatchDeleteImage) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpBatchDeleteImage) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*BatchDeleteImageInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpBatchDeleteImageInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpBatchGetImage struct {
+}
+
+func (*validateOpBatchGetImage) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpBatchGetImage) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*BatchGetImageInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpBatchGetImageInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpBatchGetRepositoryScanningConfiguration struct {
+}
+
+func (*validateOpBatchGetRepositoryScanningConfiguration) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpBatchGetRepositoryScanningConfiguration) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*BatchGetRepositoryScanningConfigurationInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpBatchGetRepositoryScanningConfigurationInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpCompleteLayerUpload struct {
+}
+
+func (*validateOpCompleteLayerUpload) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpCompleteLayerUpload) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*CompleteLayerUploadInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpCompleteLayerUploadInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpCreatePullThroughCacheRule struct {
+}
+
+func (*validateOpCreatePullThroughCacheRule) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpCreatePullThroughCacheRule) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*CreatePullThroughCacheRuleInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpCreatePullThroughCacheRuleInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpCreateRepository struct {
+}
+
+func (*validateOpCreateRepository) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpCreateRepository) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*CreateRepositoryInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpCreateRepositoryInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDeleteLifecyclePolicy struct {
+}
+
+func (*validateOpDeleteLifecyclePolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDeleteLifecyclePolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DeleteLifecyclePolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDeleteLifecyclePolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDeletePullThroughCacheRule struct {
+}
+
+func (*validateOpDeletePullThroughCacheRule) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDeletePullThroughCacheRule) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DeletePullThroughCacheRuleInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDeletePullThroughCacheRuleInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDeleteRepository struct {
+}
+
+func (*validateOpDeleteRepository) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDeleteRepository) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DeleteRepositoryInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDeleteRepositoryInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDeleteRepositoryPolicy struct {
+}
+
+func (*validateOpDeleteRepositoryPolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDeleteRepositoryPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DeleteRepositoryPolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDeleteRepositoryPolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDescribeImageReplicationStatus struct {
+}
+
+func (*validateOpDescribeImageReplicationStatus) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDescribeImageReplicationStatus) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DescribeImageReplicationStatusInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDescribeImageReplicationStatusInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDescribeImageScanFindings struct {
+}
+
+func (*validateOpDescribeImageScanFindings) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDescribeImageScanFindings) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DescribeImageScanFindingsInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDescribeImageScanFindingsInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDescribeImages struct {
+}
+
+func (*validateOpDescribeImages) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDescribeImages) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DescribeImagesInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDescribeImagesInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpGetDownloadUrlForLayer struct {
+}
+
+func (*validateOpGetDownloadUrlForLayer) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetDownloadUrlForLayer) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetDownloadUrlForLayerInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetDownloadUrlForLayerInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpGetLifecyclePolicy struct {
+}
+
+func (*validateOpGetLifecyclePolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetLifecyclePolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetLifecyclePolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetLifecyclePolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpGetLifecyclePolicyPreview struct {
+}
+
+func (*validateOpGetLifecyclePolicyPreview) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetLifecyclePolicyPreview) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetLifecyclePolicyPreviewInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetLifecyclePolicyPreviewInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpGetRepositoryPolicy struct {
+}
+
+func (*validateOpGetRepositoryPolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetRepositoryPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetRepositoryPolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetRepositoryPolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpInitiateLayerUpload struct {
+}
+
+func (*validateOpInitiateLayerUpload) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpInitiateLayerUpload) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*InitiateLayerUploadInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpInitiateLayerUploadInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpListImages struct {
+}
+
+func (*validateOpListImages) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpListImages) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*ListImagesInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpListImagesInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpListTagsForResource struct {
+}
+
+func (*validateOpListTagsForResource) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpListTagsForResource) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*ListTagsForResourceInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpListTagsForResourceInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutImage struct {
+}
+
+func (*validateOpPutImage) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutImage) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutImageInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutImageInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutImageScanningConfiguration struct {
+}
+
+func (*validateOpPutImageScanningConfiguration) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutImageScanningConfiguration) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutImageScanningConfigurationInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutImageScanningConfigurationInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutImageTagMutability struct {
+}
+
+func (*validateOpPutImageTagMutability) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutImageTagMutability) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutImageTagMutabilityInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutImageTagMutabilityInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutLifecyclePolicy struct {
+}
+
+func (*validateOpPutLifecyclePolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutLifecyclePolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutLifecyclePolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutLifecyclePolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutRegistryPolicy struct {
+}
+
+func (*validateOpPutRegistryPolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutRegistryPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutRegistryPolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutRegistryPolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutRegistryScanningConfiguration struct {
+}
+
+func (*validateOpPutRegistryScanningConfiguration) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutRegistryScanningConfiguration) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutRegistryScanningConfigurationInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutRegistryScanningConfigurationInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutReplicationConfiguration struct {
+}
+
+func (*validateOpPutReplicationConfiguration) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutReplicationConfiguration) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutReplicationConfigurationInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutReplicationConfigurationInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpSetRepositoryPolicy struct {
+}
+
+func (*validateOpSetRepositoryPolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpSetRepositoryPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*SetRepositoryPolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpSetRepositoryPolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpStartImageScan struct {
+}
+
+func (*validateOpStartImageScan) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpStartImageScan) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*StartImageScanInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpStartImageScanInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpStartLifecyclePolicyPreview struct {
+}
+
+func (*validateOpStartLifecyclePolicyPreview) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpStartLifecyclePolicyPreview) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*StartLifecyclePolicyPreviewInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpStartLifecyclePolicyPreviewInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpTagResource struct {
+}
+
+func (*validateOpTagResource) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpTagResource) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*TagResourceInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpTagResourceInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpUntagResource struct {
+}
+
+func (*validateOpUntagResource) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpUntagResource) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*UntagResourceInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpUntagResourceInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpUploadLayerPart struct {
+}
+
+func (*validateOpUploadLayerPart) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpUploadLayerPart) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*UploadLayerPartInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpUploadLayerPartInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+func addOpBatchCheckLayerAvailabilityValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpBatchCheckLayerAvailability{}, middleware.After)
+}
+
+func addOpBatchDeleteImageValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpBatchDeleteImage{}, middleware.After)
+}
+
+func addOpBatchGetImageValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpBatchGetImage{}, middleware.After)
+}
+
+func addOpBatchGetRepositoryScanningConfigurationValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpBatchGetRepositoryScanningConfiguration{}, middleware.After)
+}
+
+func addOpCompleteLayerUploadValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpCompleteLayerUpload{}, middleware.After)
+}
+
+func addOpCreatePullThroughCacheRuleValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpCreatePullThroughCacheRule{}, middleware.After)
+}
+
+func addOpCreateRepositoryValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpCreateRepository{}, middleware.After)
+}
+
+func addOpDeleteLifecyclePolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDeleteLifecyclePolicy{}, middleware.After)
+}
+
+func addOpDeletePullThroughCacheRuleValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDeletePullThroughCacheRule{}, middleware.After)
+}
+
+func addOpDeleteRepositoryValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDeleteRepository{}, middleware.After)
+}
+
+func addOpDeleteRepositoryPolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDeleteRepositoryPolicy{}, middleware.After)
+}
+
+func addOpDescribeImageReplicationStatusValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDescribeImageReplicationStatus{}, middleware.After)
+}
+
+func addOpDescribeImageScanFindingsValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDescribeImageScanFindings{}, middleware.After)
+}
+
+func addOpDescribeImagesValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDescribeImages{}, middleware.After)
+}
+
+func addOpGetDownloadUrlForLayerValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetDownloadUrlForLayer{}, middleware.After)
+}
+
+func addOpGetLifecyclePolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetLifecyclePolicy{}, middleware.After)
+}
+
+func addOpGetLifecyclePolicyPreviewValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetLifecyclePolicyPreview{}, middleware.After)
+}
+
+func addOpGetRepositoryPolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetRepositoryPolicy{}, middleware.After)
+}
+
+func addOpInitiateLayerUploadValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpInitiateLayerUpload{}, middleware.After)
+}
+
+func addOpListImagesValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpListImages{}, middleware.After)
+}
+
+func addOpListTagsForResourceValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpListTagsForResource{}, middleware.After)
+}
+
+func addOpPutImageValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutImage{}, middleware.After)
+}
+
+func addOpPutImageScanningConfigurationValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutImageScanningConfiguration{}, middleware.After)
+}
+
+func addOpPutImageTagMutabilityValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutImageTagMutability{}, middleware.After)
+}
+
+func addOpPutLifecyclePolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutLifecyclePolicy{}, middleware.After)
+}
+
+func addOpPutRegistryPolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutRegistryPolicy{}, middleware.After)
+}
+
+func addOpPutRegistryScanningConfigurationValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutRegistryScanningConfiguration{}, middleware.After)
+}
+
+func addOpPutReplicationConfigurationValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutReplicationConfiguration{}, middleware.After)
+}
+
+func addOpSetRepositoryPolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpSetRepositoryPolicy{}, middleware.After)
+}
+
+func addOpStartImageScanValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpStartImageScan{}, middleware.After)
+}
+
+func addOpStartLifecyclePolicyPreviewValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpStartLifecyclePolicyPreview{}, middleware.After)
+}
+
+func addOpTagResourceValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpTagResource{}, middleware.After)
+}
+
+func addOpUntagResourceValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpUntagResource{}, middleware.After)
+}
+
+func addOpUploadLayerPartValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpUploadLayerPart{}, middleware.After)
+}
+
+func validateEncryptionConfiguration(v *types.EncryptionConfiguration) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "EncryptionConfiguration"}
+ if len(v.EncryptionType) == 0 {
+ invalidParams.Add(smithy.NewErrParamRequired("EncryptionType"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateRegistryScanningRule(v *types.RegistryScanningRule) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "RegistryScanningRule"}
+ if len(v.ScanFrequency) == 0 {
+ invalidParams.Add(smithy.NewErrParamRequired("ScanFrequency"))
+ }
+ if v.RepositoryFilters == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryFilters"))
+ } else if v.RepositoryFilters != nil {
+ if err := validateScanningRepositoryFilterList(v.RepositoryFilters); err != nil {
+ invalidParams.AddNested("RepositoryFilters", err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateRegistryScanningRuleList(v []types.RegistryScanningRule) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "RegistryScanningRuleList"}
+ for i := range v {
+ if err := validateRegistryScanningRule(&v[i]); err != nil {
+ invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateReplicationConfiguration(v *types.ReplicationConfiguration) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ReplicationConfiguration"}
+ if v.Rules == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Rules"))
+ } else if v.Rules != nil {
+ if err := validateReplicationRuleList(v.Rules); err != nil {
+ invalidParams.AddNested("Rules", err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateReplicationDestination(v *types.ReplicationDestination) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ReplicationDestination"}
+ if v.Region == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Region"))
+ }
+ if v.RegistryId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RegistryId"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateReplicationDestinationList(v []types.ReplicationDestination) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ReplicationDestinationList"}
+ for i := range v {
+ if err := validateReplicationDestination(&v[i]); err != nil {
+ invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateReplicationRule(v *types.ReplicationRule) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ReplicationRule"}
+ if v.Destinations == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Destinations"))
+ } else if v.Destinations != nil {
+ if err := validateReplicationDestinationList(v.Destinations); err != nil {
+ invalidParams.AddNested("Destinations", err.(smithy.InvalidParamsError))
+ }
+ }
+ if v.RepositoryFilters != nil {
+ if err := validateRepositoryFilterList(v.RepositoryFilters); err != nil {
+ invalidParams.AddNested("RepositoryFilters", err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateReplicationRuleList(v []types.ReplicationRule) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ReplicationRuleList"}
+ for i := range v {
+ if err := validateReplicationRule(&v[i]); err != nil {
+ invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateRepositoryFilter(v *types.RepositoryFilter) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "RepositoryFilter"}
+ if v.Filter == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Filter"))
+ }
+ if len(v.FilterType) == 0 {
+ invalidParams.Add(smithy.NewErrParamRequired("FilterType"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateRepositoryFilterList(v []types.RepositoryFilter) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "RepositoryFilterList"}
+ for i := range v {
+ if err := validateRepositoryFilter(&v[i]); err != nil {
+ invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateScanningRepositoryFilter(v *types.ScanningRepositoryFilter) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ScanningRepositoryFilter"}
+ if v.Filter == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Filter"))
+ }
+ if len(v.FilterType) == 0 {
+ invalidParams.Add(smithy.NewErrParamRequired("FilterType"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateScanningRepositoryFilterList(v []types.ScanningRepositoryFilter) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ScanningRepositoryFilterList"}
+ for i := range v {
+ if err := validateScanningRepositoryFilter(&v[i]); err != nil {
+ invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpBatchCheckLayerAvailabilityInput(v *BatchCheckLayerAvailabilityInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "BatchCheckLayerAvailabilityInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.LayerDigests == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("LayerDigests"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpBatchDeleteImageInput(v *BatchDeleteImageInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "BatchDeleteImageInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageIds == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageIds"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpBatchGetImageInput(v *BatchGetImageInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "BatchGetImageInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageIds == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageIds"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpBatchGetRepositoryScanningConfigurationInput(v *BatchGetRepositoryScanningConfigurationInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "BatchGetRepositoryScanningConfigurationInput"}
+ if v.RepositoryNames == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryNames"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpCompleteLayerUploadInput(v *CompleteLayerUploadInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "CompleteLayerUploadInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.UploadId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("UploadId"))
+ }
+ if v.LayerDigests == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("LayerDigests"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpCreatePullThroughCacheRuleInput(v *CreatePullThroughCacheRuleInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "CreatePullThroughCacheRuleInput"}
+ if v.EcrRepositoryPrefix == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("EcrRepositoryPrefix"))
+ }
+ if v.UpstreamRegistryUrl == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("UpstreamRegistryUrl"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpCreateRepositoryInput(v *CreateRepositoryInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "CreateRepositoryInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.EncryptionConfiguration != nil {
+ if err := validateEncryptionConfiguration(v.EncryptionConfiguration); err != nil {
+ invalidParams.AddNested("EncryptionConfiguration", err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDeleteLifecyclePolicyInput(v *DeleteLifecyclePolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DeleteLifecyclePolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDeletePullThroughCacheRuleInput(v *DeletePullThroughCacheRuleInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DeletePullThroughCacheRuleInput"}
+ if v.EcrRepositoryPrefix == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("EcrRepositoryPrefix"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDeleteRepositoryInput(v *DeleteRepositoryInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DeleteRepositoryInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDeleteRepositoryPolicyInput(v *DeleteRepositoryPolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DeleteRepositoryPolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDescribeImageReplicationStatusInput(v *DescribeImageReplicationStatusInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DescribeImageReplicationStatusInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageId"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDescribeImageScanFindingsInput(v *DescribeImageScanFindingsInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DescribeImageScanFindingsInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageId"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDescribeImagesInput(v *DescribeImagesInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DescribeImagesInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpGetDownloadUrlForLayerInput(v *GetDownloadUrlForLayerInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetDownloadUrlForLayerInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.LayerDigest == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("LayerDigest"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpGetLifecyclePolicyInput(v *GetLifecyclePolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetLifecyclePolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpGetLifecyclePolicyPreviewInput(v *GetLifecyclePolicyPreviewInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetLifecyclePolicyPreviewInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpGetRepositoryPolicyInput(v *GetRepositoryPolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetRepositoryPolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpInitiateLayerUploadInput(v *InitiateLayerUploadInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "InitiateLayerUploadInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpListImagesInput(v *ListImagesInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ListImagesInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpListTagsForResourceInput(v *ListTagsForResourceInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ListTagsForResourceInput"}
+ if v.ResourceArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ResourceArn"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutImageInput(v *PutImageInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutImageInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageManifest == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageManifest"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutImageScanningConfigurationInput(v *PutImageScanningConfigurationInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutImageScanningConfigurationInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageScanningConfiguration == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageScanningConfiguration"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutImageTagMutabilityInput(v *PutImageTagMutabilityInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutImageTagMutabilityInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if len(v.ImageTagMutability) == 0 {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageTagMutability"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutLifecyclePolicyInput(v *PutLifecyclePolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutLifecyclePolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.LifecyclePolicyText == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("LifecyclePolicyText"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutRegistryPolicyInput(v *PutRegistryPolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutRegistryPolicyInput"}
+ if v.PolicyText == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("PolicyText"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutRegistryScanningConfigurationInput(v *PutRegistryScanningConfigurationInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutRegistryScanningConfigurationInput"}
+ if v.Rules != nil {
+ if err := validateRegistryScanningRuleList(v.Rules); err != nil {
+ invalidParams.AddNested("Rules", err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutReplicationConfigurationInput(v *PutReplicationConfigurationInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutReplicationConfigurationInput"}
+ if v.ReplicationConfiguration == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ReplicationConfiguration"))
+ } else if v.ReplicationConfiguration != nil {
+ if err := validateReplicationConfiguration(v.ReplicationConfiguration); err != nil {
+ invalidParams.AddNested("ReplicationConfiguration", err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpSetRepositoryPolicyInput(v *SetRepositoryPolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "SetRepositoryPolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.PolicyText == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("PolicyText"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpStartImageScanInput(v *StartImageScanInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "StartImageScanInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageId"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpStartLifecyclePolicyPreviewInput(v *StartLifecyclePolicyPreviewInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "StartLifecyclePolicyPreviewInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpTagResourceInput(v *TagResourceInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "TagResourceInput"}
+ if v.ResourceArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ResourceArn"))
+ }
+ if v.Tags == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Tags"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpUntagResourceInput(v *UntagResourceInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "UntagResourceInput"}
+ if v.ResourceArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ResourceArn"))
+ }
+ if v.TagKeys == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("TagKeys"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpUploadLayerPartInput(v *UploadLayerPartInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "UploadLayerPartInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.UploadId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("UploadId"))
+ }
+ if v.PartFirstByte == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("PartFirstByte"))
+ }
+ if v.PartLastByte == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("PartLastByte"))
+ }
+ if v.LayerPartBlob == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("LayerPartBlob"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/CHANGELOG.md
new file mode 100644
index 000000000000..dd1c701c604d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/CHANGELOG.md
@@ -0,0 +1,75 @@
+# v1.10.0 (2022-01-07)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.9.0 (2021-12-21)
+
+* **Feature**: API Paginators now support specifying the initial starting token, and support stopping on empty string tokens.
+
+# v1.8.2 (2021-12-02)
+
+* **Bug Fix**: Fixes a bug that prevented aws.EndpointResolverWithOptions from being used by the service client. ([#1514](https://github.com/aws/aws-sdk-go-v2/pull/1514))
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.0 (2021-11-12)
+
+* **Feature**: Service clients now support custom endpoints that have an initial URI path defined.
+
+# v1.7.0 (2021-11-06)
+
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.0 (2021-10-21)
+
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.2 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.1 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.0 (2021-08-27)
+
+* **Feature**: Updated API model to latest revision.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.3 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.2 (2021-08-04)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.1 (2021-07-15)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.0 (2021-06-25)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.1 (2021-05-20)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.0 (2021-05-14)
+
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_client.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_client.go
new file mode 100644
index 000000000000..d8e2f569ba5b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_client.go
@@ -0,0 +1,297 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/retry"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ awshttp "github.com/aws/aws-sdk-go-v2/aws/transport/http"
+ internalConfig "github.com/aws/aws-sdk-go-v2/internal/configsources"
+ smithy "github.com/aws/smithy-go"
+ smithydocument "github.com/aws/smithy-go/document"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "net/http"
+ "time"
+)
+
+const ServiceID = "ECR PUBLIC"
+const ServiceAPIVersion = "2020-10-30"
+
+// Client provides the API client to make operations call for Amazon Elastic
+// Container Registry Public.
+type Client struct {
+ options Options
+}
+
+// New returns an initialized Client based on the functional options. Provide
+// additional functional options to further configure the behavior of the client,
+// such as changing the client's endpoint or adding custom middleware behavior.
+func New(options Options, optFns ...func(*Options)) *Client {
+ options = options.Copy()
+
+ resolveDefaultLogger(&options)
+
+ resolveRetryer(&options)
+
+ resolveHTTPClient(&options)
+
+ resolveHTTPSignerV4(&options)
+
+ resolveDefaultEndpointConfiguration(&options)
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ client := &Client{
+ options: options,
+ }
+
+ return client
+}
+
+type Options struct {
+ // Set of options to modify how an operation is invoked. These apply to all
+ // operations invoked for this client. Use functional options on operation call to
+ // modify this list for per operation behavior.
+ APIOptions []func(*middleware.Stack) error
+
+ // Configures the events that will be sent to the configured logger.
+ ClientLogMode aws.ClientLogMode
+
+ // The credentials object to use when signing requests.
+ Credentials aws.CredentialsProvider
+
+ // The endpoint options to be used when attempting to resolve an endpoint.
+ EndpointOptions EndpointResolverOptions
+
+ // The service endpoint resolver.
+ EndpointResolver EndpointResolver
+
+ // Signature Version 4 (SigV4) Signer
+ HTTPSignerV4 HTTPSignerV4
+
+ // The logger writer interface to write logging messages to.
+ Logger logging.Logger
+
+ // The region to send requests to. (Required)
+ Region string
+
+ // Retryer guides how HTTP requests should be retried in case of recoverable
+ // failures. When nil the API client will use a default retryer.
+ Retryer aws.Retryer
+
+ // The HTTP client to invoke API calls with. Defaults to client's default HTTP
+ // implementation if nil.
+ HTTPClient HTTPClient
+}
+
+// WithAPIOptions returns a functional option for setting the Client's APIOptions
+// option.
+func WithAPIOptions(optFns ...func(*middleware.Stack) error) func(*Options) {
+ return func(o *Options) {
+ o.APIOptions = append(o.APIOptions, optFns...)
+ }
+}
+
+// WithEndpointResolver returns a functional option for setting the Client's
+// EndpointResolver option.
+func WithEndpointResolver(v EndpointResolver) func(*Options) {
+ return func(o *Options) {
+ o.EndpointResolver = v
+ }
+}
+
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// Copy creates a clone where the APIOptions list is deep copied.
+func (o Options) Copy() Options {
+ to := o
+ to.APIOptions = make([]func(*middleware.Stack) error, len(o.APIOptions))
+ copy(to.APIOptions, o.APIOptions)
+ return to
+}
+func (c *Client) invokeOperation(ctx context.Context, opID string, params interface{}, optFns []func(*Options), stackFns ...func(*middleware.Stack, Options) error) (result interface{}, metadata middleware.Metadata, err error) {
+ ctx = middleware.ClearStackValues(ctx)
+ stack := middleware.NewStack(opID, smithyhttp.NewStackRequest)
+ options := c.options.Copy()
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ finalizeClientEndpointResolverOptions(&options)
+
+ for _, fn := range stackFns {
+ if err := fn(stack, options); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ for _, fn := range options.APIOptions {
+ if err := fn(stack); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ handler := middleware.DecorateHandler(smithyhttp.NewClientHandler(options.HTTPClient), stack)
+ result, metadata, err = handler.Handle(ctx, params)
+ if err != nil {
+ err = &smithy.OperationError{
+ ServiceID: ServiceID,
+ OperationName: opID,
+ Err: err,
+ }
+ }
+ return result, metadata, err
+}
+
+type noSmithyDocumentSerde = smithydocument.NoSerde
+
+func resolveDefaultLogger(o *Options) {
+ if o.Logger != nil {
+ return
+ }
+ o.Logger = logging.Nop{}
+}
+
+func addSetLoggerMiddleware(stack *middleware.Stack, o Options) error {
+ return middleware.AddSetLoggerMiddleware(stack, o.Logger)
+}
+
+// NewFromConfig returns a new client from the provided config.
+func NewFromConfig(cfg aws.Config, optFns ...func(*Options)) *Client {
+ opts := Options{
+ Region: cfg.Region,
+ HTTPClient: cfg.HTTPClient,
+ Credentials: cfg.Credentials,
+ APIOptions: cfg.APIOptions,
+ Logger: cfg.Logger,
+ ClientLogMode: cfg.ClientLogMode,
+ }
+ resolveAWSRetryerProvider(cfg, &opts)
+ resolveAWSEndpointResolver(cfg, &opts)
+ resolveUseDualStackEndpoint(cfg, &opts)
+ resolveUseFIPSEndpoint(cfg, &opts)
+ return New(opts, optFns...)
+}
+
+func resolveHTTPClient(o *Options) {
+ if o.HTTPClient != nil {
+ return
+ }
+ o.HTTPClient = awshttp.NewBuildableClient()
+}
+
+func resolveRetryer(o *Options) {
+ if o.Retryer != nil {
+ return
+ }
+ o.Retryer = retry.NewStandard()
+}
+
+func resolveAWSRetryerProvider(cfg aws.Config, o *Options) {
+ if cfg.Retryer == nil {
+ return
+ }
+ o.Retryer = cfg.Retryer()
+}
+
+func resolveAWSEndpointResolver(cfg aws.Config, o *Options) {
+ if cfg.EndpointResolver == nil && cfg.EndpointResolverWithOptions == nil {
+ return
+ }
+ o.EndpointResolver = withEndpointResolver(cfg.EndpointResolver, cfg.EndpointResolverWithOptions, NewDefaultEndpointResolver())
+}
+
+func addClientUserAgent(stack *middleware.Stack) error {
+ return awsmiddleware.AddSDKAgentKeyValue(awsmiddleware.APIMetadata, "ecrpublic", goModuleVersion)(stack)
+}
+
+func addHTTPSignerV4Middleware(stack *middleware.Stack, o Options) error {
+ mw := v4.NewSignHTTPRequestMiddleware(v4.SignHTTPRequestMiddlewareOptions{
+ CredentialsProvider: o.Credentials,
+ Signer: o.HTTPSignerV4,
+ LogSigning: o.ClientLogMode.IsSigning(),
+ })
+ return stack.Finalize.Add(mw, middleware.After)
+}
+
+type HTTPSignerV4 interface {
+ SignHTTP(ctx context.Context, credentials aws.Credentials, r *http.Request, payloadHash string, service string, region string, signingTime time.Time, optFns ...func(*v4.SignerOptions)) error
+}
+
+func resolveHTTPSignerV4(o *Options) {
+ if o.HTTPSignerV4 != nil {
+ return
+ }
+ o.HTTPSignerV4 = newDefaultV4Signer(*o)
+}
+
+func newDefaultV4Signer(o Options) *v4.Signer {
+ return v4.NewSigner(func(so *v4.SignerOptions) {
+ so.Logger = o.Logger
+ so.LogSigning = o.ClientLogMode.IsSigning()
+ })
+}
+
+func addRetryMiddlewares(stack *middleware.Stack, o Options) error {
+ mo := retry.AddRetryMiddlewaresOptions{
+ Retryer: o.Retryer,
+ LogRetryAttempts: o.ClientLogMode.IsRetries(),
+ }
+ return retry.AddRetryMiddlewares(stack, mo)
+}
+
+// resolves dual-stack endpoint configuration
+func resolveUseDualStackEndpoint(cfg aws.Config, o *Options) error {
+ if len(cfg.ConfigSources) == 0 {
+ return nil
+ }
+ value, found, err := internalConfig.ResolveUseDualStackEndpoint(context.Background(), cfg.ConfigSources)
+ if err != nil {
+ return err
+ }
+ if found {
+ o.EndpointOptions.UseDualStackEndpoint = value
+ }
+ return nil
+}
+
+// resolves FIPS endpoint configuration
+func resolveUseFIPSEndpoint(cfg aws.Config, o *Options) error {
+ if len(cfg.ConfigSources) == 0 {
+ return nil
+ }
+ value, found, err := internalConfig.ResolveUseFIPSEndpoint(context.Background(), cfg.ConfigSources)
+ if err != nil {
+ return err
+ }
+ if found {
+ o.EndpointOptions.UseFIPSEndpoint = value
+ }
+ return nil
+}
+
+func addRequestIDRetrieverMiddleware(stack *middleware.Stack) error {
+ return awsmiddleware.AddRequestIDRetrieverMiddleware(stack)
+}
+
+func addResponseErrorMiddleware(stack *middleware.Stack) error {
+ return awshttp.AddResponseErrorMiddleware(stack)
+}
+
+func addRequestResponseLogging(stack *middleware.Stack, o Options) error {
+ return stack.Deserialize.Add(&smithyhttp.RequestResponseLogger{
+ LogRequest: o.ClientLogMode.IsRequest(),
+ LogRequestWithBody: o.ClientLogMode.IsRequestWithBody(),
+ LogResponse: o.ClientLogMode.IsResponse(),
+ LogResponseWithBody: o.ClientLogMode.IsResponseWithBody(),
+ }, middleware.After)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_BatchCheckLayerAvailability.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_BatchCheckLayerAvailability.go
new file mode 100644
index 000000000000..682599a03668
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_BatchCheckLayerAvailability.go
@@ -0,0 +1,140 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Checks the availability of one or more image layers within a repository in a
+// public registry. When an image is pushed to a repository, each image layer is
+// checked to verify if it has been uploaded before. If it has been uploaded, then
+// the image layer is skipped. This operation is used by the Amazon ECR proxy and
+// is not generally used by customers for pulling and pushing images. In most
+// cases, you should use the docker CLI to pull, tag, and push images.
+func (c *Client) BatchCheckLayerAvailability(ctx context.Context, params *BatchCheckLayerAvailabilityInput, optFns ...func(*Options)) (*BatchCheckLayerAvailabilityOutput, error) {
+ if params == nil {
+ params = &BatchCheckLayerAvailabilityInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "BatchCheckLayerAvailability", params, optFns, c.addOperationBatchCheckLayerAvailabilityMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*BatchCheckLayerAvailabilityOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type BatchCheckLayerAvailabilityInput struct {
+
+ // The digests of the image layers to check.
+ //
+ // This member is required.
+ LayerDigests []string
+
+ // The name of the repository that is associated with the image layers to check.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The AWS account ID associated with the public registry that contains the image
+ // layers to check. If you do not specify a registry, the default public registry
+ // is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type BatchCheckLayerAvailabilityOutput struct {
+
+ // Any failures associated with the call.
+ Failures []types.LayerFailure
+
+ // A list of image layer objects corresponding to the image layer references in the
+ // request.
+ Layers []types.Layer
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationBatchCheckLayerAvailabilityMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpBatchCheckLayerAvailability{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpBatchCheckLayerAvailability{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpBatchCheckLayerAvailabilityValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opBatchCheckLayerAvailability(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opBatchCheckLayerAvailability(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "BatchCheckLayerAvailability",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_BatchDeleteImage.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_BatchDeleteImage.go
new file mode 100644
index 000000000000..b208c9520061
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_BatchDeleteImage.go
@@ -0,0 +1,140 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes a list of specified images within a repository in a public registry.
+// Images are specified with either an imageTag or imageDigest. You can remove a
+// tag from an image by specifying the image's tag in your request. When you remove
+// the last tag from an image, the image is deleted from your repository. You can
+// completely delete an image (and all of its tags) by specifying the image's
+// digest in your request.
+func (c *Client) BatchDeleteImage(ctx context.Context, params *BatchDeleteImageInput, optFns ...func(*Options)) (*BatchDeleteImageOutput, error) {
+ if params == nil {
+ params = &BatchDeleteImageInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "BatchDeleteImage", params, optFns, c.addOperationBatchDeleteImageMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*BatchDeleteImageOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type BatchDeleteImageInput struct {
+
+ // A list of image ID references that correspond to images to delete. The format of
+ // the imageIds reference is imageTag=tag or imageDigest=digest.
+ //
+ // This member is required.
+ ImageIds []types.ImageIdentifier
+
+ // The repository in a public registry that contains the image to delete.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The AWS account ID associated with the registry that contains the image to
+ // delete. If you do not specify a registry, the default public registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type BatchDeleteImageOutput struct {
+
+ // Any failures associated with the call.
+ Failures []types.ImageFailure
+
+ // The image IDs of the deleted images.
+ ImageIds []types.ImageIdentifier
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationBatchDeleteImageMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpBatchDeleteImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpBatchDeleteImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpBatchDeleteImageValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opBatchDeleteImage(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opBatchDeleteImage(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "BatchDeleteImage",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_CompleteLayerUpload.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_CompleteLayerUpload.go
new file mode 100644
index 000000000000..206e55f525a0
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_CompleteLayerUpload.go
@@ -0,0 +1,151 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Informs Amazon ECR that the image layer upload has completed for a specified
+// public registry, repository name, and upload ID. You can optionally provide a
+// sha256 digest of the image layer for data validation purposes. When an image is
+// pushed, the CompleteLayerUpload API is called once per each new image layer to
+// verify that the upload has completed. This operation is used by the Amazon ECR
+// proxy and is not generally used by customers for pulling and pushing images. In
+// most cases, you should use the docker CLI to pull, tag, and push images.
+func (c *Client) CompleteLayerUpload(ctx context.Context, params *CompleteLayerUploadInput, optFns ...func(*Options)) (*CompleteLayerUploadOutput, error) {
+ if params == nil {
+ params = &CompleteLayerUploadInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "CompleteLayerUpload", params, optFns, c.addOperationCompleteLayerUploadMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*CompleteLayerUploadOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type CompleteLayerUploadInput struct {
+
+ // The sha256 digest of the image layer.
+ //
+ // This member is required.
+ LayerDigests []string
+
+ // The name of the repository in a public registry to associate with the image
+ // layer.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The upload ID from a previous InitiateLayerUpload operation to associate with
+ // the image layer.
+ //
+ // This member is required.
+ UploadId *string
+
+ // The AWS account ID associated with the registry to which to upload layers. If
+ // you do not specify a registry, the default public registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type CompleteLayerUploadOutput struct {
+
+ // The sha256 digest of the image layer.
+ LayerDigest *string
+
+ // The public registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // The upload ID associated with the layer.
+ UploadId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationCompleteLayerUploadMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpCompleteLayerUpload{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpCompleteLayerUpload{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpCompleteLayerUploadValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCompleteLayerUpload(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opCompleteLayerUpload(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "CompleteLayerUpload",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_CreateRepository.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_CreateRepository.go
new file mode 100644
index 000000000000..82a2a7e5f481
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_CreateRepository.go
@@ -0,0 +1,141 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates a repository in a public registry. For more information, see Amazon ECR
+// repositories
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/Repositories.html) in
+// the Amazon Elastic Container Registry User Guide.
+func (c *Client) CreateRepository(ctx context.Context, params *CreateRepositoryInput, optFns ...func(*Options)) (*CreateRepositoryOutput, error) {
+ if params == nil {
+ params = &CreateRepositoryInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "CreateRepository", params, optFns, c.addOperationCreateRepositoryMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*CreateRepositoryOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type CreateRepositoryInput struct {
+
+ // The name to use for the repository. This appears publicly in the Amazon ECR
+ // Public Gallery. The repository name may be specified on its own (such as
+ // nginx-web-app) or it can be prepended with a namespace to group the repository
+ // into a category (such as project-a/nginx-web-app).
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The details about the repository that are publicly visible in the Amazon ECR
+ // Public Gallery.
+ CatalogData *types.RepositoryCatalogDataInput
+
+ // The metadata that you apply to the repository to help you categorize and
+ // organize them. Each tag consists of a key and an optional value, both of which
+ // you define. Tag keys can have a maximum character length of 128 characters, and
+ // tag values can have a maximum length of 256 characters.
+ Tags []types.Tag
+
+ noSmithyDocumentSerde
+}
+
+type CreateRepositoryOutput struct {
+
+ // The catalog data for a repository. This data is publicly visible in the Amazon
+ // ECR Public Gallery.
+ CatalogData *types.RepositoryCatalogData
+
+ // The repository that was created.
+ Repository *types.Repository
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationCreateRepositoryMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpCreateRepository{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpCreateRepository{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpCreateRepositoryValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateRepository(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opCreateRepository(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "CreateRepository",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DeleteRepository.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DeleteRepository.go
new file mode 100644
index 000000000000..30503d3b7902
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DeleteRepository.go
@@ -0,0 +1,131 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes a repository in a public registry. If the repository contains images,
+// you must either delete all images in the repository or use the force option
+// which deletes all images on your behalf before deleting the repository.
+func (c *Client) DeleteRepository(ctx context.Context, params *DeleteRepositoryInput, optFns ...func(*Options)) (*DeleteRepositoryOutput, error) {
+ if params == nil {
+ params = &DeleteRepositoryInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DeleteRepository", params, optFns, c.addOperationDeleteRepositoryMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DeleteRepositoryOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DeleteRepositoryInput struct {
+
+ // The name of the repository to delete.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // If a repository contains images, forces the deletion.
+ Force bool
+
+ // The AWS account ID associated with the public registry that contains the
+ // repository to delete. If you do not specify a registry, the default public
+ // registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DeleteRepositoryOutput struct {
+
+ // The repository that was deleted.
+ Repository *types.Repository
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDeleteRepositoryMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeleteRepository{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeleteRepository{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDeleteRepositoryValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteRepository(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDeleteRepository(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "DeleteRepository",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DeleteRepositoryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DeleteRepositoryPolicy.go
new file mode 100644
index 000000000000..b6ce507b7129
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DeleteRepositoryPolicy.go
@@ -0,0 +1,132 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes the repository policy associated with the specified repository.
+func (c *Client) DeleteRepositoryPolicy(ctx context.Context, params *DeleteRepositoryPolicyInput, optFns ...func(*Options)) (*DeleteRepositoryPolicyOutput, error) {
+ if params == nil {
+ params = &DeleteRepositoryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DeleteRepositoryPolicy", params, optFns, c.addOperationDeleteRepositoryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DeleteRepositoryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DeleteRepositoryPolicyInput struct {
+
+ // The name of the repository that is associated with the repository policy to
+ // delete.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The AWS account ID associated with the public registry that contains the
+ // repository policy to delete. If you do not specify a registry, the default
+ // public registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DeleteRepositoryPolicyOutput struct {
+
+ // The JSON repository policy that was deleted from the repository.
+ PolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDeleteRepositoryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeleteRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeleteRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDeleteRepositoryPolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteRepositoryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDeleteRepositoryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "DeleteRepositoryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeImageTags.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeImageTags.go
new file mode 100644
index 000000000000..e59efd5ac401
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeImageTags.go
@@ -0,0 +1,247 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns the image tag details for a repository in a public registry.
+func (c *Client) DescribeImageTags(ctx context.Context, params *DescribeImageTagsInput, optFns ...func(*Options)) (*DescribeImageTagsOutput, error) {
+ if params == nil {
+ params = &DescribeImageTagsInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeImageTags", params, optFns, c.addOperationDescribeImageTagsMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeImageTagsOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeImageTagsInput struct {
+
+ // The name of the repository that contains the image tag details to describe.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The maximum number of repository results returned by DescribeImageTags in
+ // paginated output. When this parameter is used, DescribeImageTags only returns
+ // maxResults results in a single page along with a nextToken response element. The
+ // remaining results of the initial request can be seen by sending another
+ // DescribeImageTags request with the returned nextToken value. This value can be
+ // between 1 and 1000. If this parameter is not used, then DescribeImageTags
+ // returns up to 100 results and a nextToken value, if applicable. This option
+ // cannot be used when you specify images with imageIds.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated DescribeImageTags request
+ // where maxResults was used and the results exceeded the value of that parameter.
+ // Pagination continues from the end of the previous results that returned the
+ // nextToken value. This value is null when there are no more results to return.
+ // This option cannot be used when you specify images with imageIds.
+ NextToken *string
+
+ // The AWS account ID associated with the public registry that contains the
+ // repository in which to describe images. If you do not specify a registry, the
+ // default public registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DescribeImageTagsOutput struct {
+
+ // The image tag details for the images in the requested repository.
+ ImageTagDetails []types.ImageTagDetail
+
+ // The nextToken value to include in a future DescribeImageTags request. When the
+ // results of a DescribeImageTags request exceed maxResults, this value can be used
+ // to retrieve the next page of results. This value is null when there are no more
+ // results to return.
+ NextToken *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeImageTagsMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeImageTags{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeImageTags{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDescribeImageTagsValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeImageTags(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// DescribeImageTagsAPIClient is a client that implements the DescribeImageTags
+// operation.
+type DescribeImageTagsAPIClient interface {
+ DescribeImageTags(context.Context, *DescribeImageTagsInput, ...func(*Options)) (*DescribeImageTagsOutput, error)
+}
+
+var _ DescribeImageTagsAPIClient = (*Client)(nil)
+
+// DescribeImageTagsPaginatorOptions is the paginator options for DescribeImageTags
+type DescribeImageTagsPaginatorOptions struct {
+ // The maximum number of repository results returned by DescribeImageTags in
+ // paginated output. When this parameter is used, DescribeImageTags only returns
+ // maxResults results in a single page along with a nextToken response element. The
+ // remaining results of the initial request can be seen by sending another
+ // DescribeImageTags request with the returned nextToken value. This value can be
+ // between 1 and 1000. If this parameter is not used, then DescribeImageTags
+ // returns up to 100 results and a nextToken value, if applicable. This option
+ // cannot be used when you specify images with imageIds.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// DescribeImageTagsPaginator is a paginator for DescribeImageTags
+type DescribeImageTagsPaginator struct {
+ options DescribeImageTagsPaginatorOptions
+ client DescribeImageTagsAPIClient
+ params *DescribeImageTagsInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewDescribeImageTagsPaginator returns a new DescribeImageTagsPaginator
+func NewDescribeImageTagsPaginator(client DescribeImageTagsAPIClient, params *DescribeImageTagsInput, optFns ...func(*DescribeImageTagsPaginatorOptions)) *DescribeImageTagsPaginator {
+ if params == nil {
+ params = &DescribeImageTagsInput{}
+ }
+
+ options := DescribeImageTagsPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &DescribeImageTagsPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *DescribeImageTagsPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next DescribeImageTags page.
+func (p *DescribeImageTagsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeImageTagsOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.DescribeImageTags(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opDescribeImageTags(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "DescribeImageTags",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeImages.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeImages.go
new file mode 100644
index 000000000000..6d6df97a2263
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeImages.go
@@ -0,0 +1,254 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns metadata about the images in a repository in a public registry.
+// Beginning with Docker version 1.9, the Docker client compresses image layers
+// before pushing them to a V2 Docker registry. The output of the docker images
+// command shows the uncompressed image size, so it may return a larger image size
+// than the image sizes returned by DescribeImages.
+func (c *Client) DescribeImages(ctx context.Context, params *DescribeImagesInput, optFns ...func(*Options)) (*DescribeImagesOutput, error) {
+ if params == nil {
+ params = &DescribeImagesInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeImages", params, optFns, c.addOperationDescribeImagesMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeImagesOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeImagesInput struct {
+
+ // The repository that contains the images to describe.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The list of image IDs for the requested repository.
+ ImageIds []types.ImageIdentifier
+
+ // The maximum number of repository results returned by DescribeImages in paginated
+ // output. When this parameter is used, DescribeImages only returns maxResults
+ // results in a single page along with a nextToken response element. The remaining
+ // results of the initial request can be seen by sending another DescribeImages
+ // request with the returned nextToken value. This value can be between 1 and 1000.
+ // If this parameter is not used, then DescribeImages returns up to 100 results and
+ // a nextToken value, if applicable. This option cannot be used when you specify
+ // images with imageIds.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated DescribeImages request
+ // where maxResults was used and the results exceeded the value of that parameter.
+ // Pagination continues from the end of the previous results that returned the
+ // nextToken value. This value is null when there are no more results to return.
+ // This option cannot be used when you specify images with imageIds.
+ NextToken *string
+
+ // The AWS account ID associated with the public registry that contains the
+ // repository in which to describe images. If you do not specify a registry, the
+ // default public registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type DescribeImagesOutput struct {
+
+ // A list of ImageDetail objects that contain data about the image.
+ ImageDetails []types.ImageDetail
+
+ // The nextToken value to include in a future DescribeImages request. When the
+ // results of a DescribeImages request exceed maxResults, this value can be used to
+ // retrieve the next page of results. This value is null when there are no more
+ // results to return.
+ NextToken *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeImagesMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeImages{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeImages{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDescribeImagesValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeImages(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// DescribeImagesAPIClient is a client that implements the DescribeImages
+// operation.
+type DescribeImagesAPIClient interface {
+ DescribeImages(context.Context, *DescribeImagesInput, ...func(*Options)) (*DescribeImagesOutput, error)
+}
+
+var _ DescribeImagesAPIClient = (*Client)(nil)
+
+// DescribeImagesPaginatorOptions is the paginator options for DescribeImages
+type DescribeImagesPaginatorOptions struct {
+ // The maximum number of repository results returned by DescribeImages in paginated
+ // output. When this parameter is used, DescribeImages only returns maxResults
+ // results in a single page along with a nextToken response element. The remaining
+ // results of the initial request can be seen by sending another DescribeImages
+ // request with the returned nextToken value. This value can be between 1 and 1000.
+ // If this parameter is not used, then DescribeImages returns up to 100 results and
+ // a nextToken value, if applicable. This option cannot be used when you specify
+ // images with imageIds.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// DescribeImagesPaginator is a paginator for DescribeImages
+type DescribeImagesPaginator struct {
+ options DescribeImagesPaginatorOptions
+ client DescribeImagesAPIClient
+ params *DescribeImagesInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewDescribeImagesPaginator returns a new DescribeImagesPaginator
+func NewDescribeImagesPaginator(client DescribeImagesAPIClient, params *DescribeImagesInput, optFns ...func(*DescribeImagesPaginatorOptions)) *DescribeImagesPaginator {
+ if params == nil {
+ params = &DescribeImagesInput{}
+ }
+
+ options := DescribeImagesPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &DescribeImagesPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *DescribeImagesPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next DescribeImages page.
+func (p *DescribeImagesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeImagesOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.DescribeImages(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opDescribeImages(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "DescribeImages",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeRegistries.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeRegistries.go
new file mode 100644
index 000000000000..e9297dfe9a89
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeRegistries.go
@@ -0,0 +1,237 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns details for a public registry.
+func (c *Client) DescribeRegistries(ctx context.Context, params *DescribeRegistriesInput, optFns ...func(*Options)) (*DescribeRegistriesOutput, error) {
+ if params == nil {
+ params = &DescribeRegistriesInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeRegistries", params, optFns, c.addOperationDescribeRegistriesMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeRegistriesOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeRegistriesInput struct {
+
+ // The maximum number of repository results returned by DescribeRegistries in
+ // paginated output. When this parameter is used, DescribeRegistries only returns
+ // maxResults results in a single page along with a nextToken response element. The
+ // remaining results of the initial request can be seen by sending another
+ // DescribeRegistries request with the returned nextToken value. This value can be
+ // between 1 and 1000. If this parameter is not used, then DescribeRegistries
+ // returns up to 100 results and a nextToken value, if applicable.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated DescribeRegistries
+ // request where maxResults was used and the results exceeded the value of that
+ // parameter. Pagination continues from the end of the previous results that
+ // returned the nextToken value. This value is null when there are no more results
+ // to return. This token should be treated as an opaque identifier that is only
+ // used to retrieve the next items in a list and not for other programmatic
+ // purposes.
+ NextToken *string
+
+ noSmithyDocumentSerde
+}
+
+type DescribeRegistriesOutput struct {
+
+ // An object containing the details for a public registry.
+ //
+ // This member is required.
+ Registries []types.Registry
+
+ // The nextToken value to include in a future DescribeRepositories request. When
+ // the results of a DescribeRepositories request exceed maxResults, this value can
+ // be used to retrieve the next page of results. This value is null when there are
+ // no more results to return.
+ NextToken *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeRegistriesMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeRegistries{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeRegistries{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeRegistries(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// DescribeRegistriesAPIClient is a client that implements the DescribeRegistries
+// operation.
+type DescribeRegistriesAPIClient interface {
+ DescribeRegistries(context.Context, *DescribeRegistriesInput, ...func(*Options)) (*DescribeRegistriesOutput, error)
+}
+
+var _ DescribeRegistriesAPIClient = (*Client)(nil)
+
+// DescribeRegistriesPaginatorOptions is the paginator options for
+// DescribeRegistries
+type DescribeRegistriesPaginatorOptions struct {
+ // The maximum number of repository results returned by DescribeRegistries in
+ // paginated output. When this parameter is used, DescribeRegistries only returns
+ // maxResults results in a single page along with a nextToken response element. The
+ // remaining results of the initial request can be seen by sending another
+ // DescribeRegistries request with the returned nextToken value. This value can be
+ // between 1 and 1000. If this parameter is not used, then DescribeRegistries
+ // returns up to 100 results and a nextToken value, if applicable.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// DescribeRegistriesPaginator is a paginator for DescribeRegistries
+type DescribeRegistriesPaginator struct {
+ options DescribeRegistriesPaginatorOptions
+ client DescribeRegistriesAPIClient
+ params *DescribeRegistriesInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewDescribeRegistriesPaginator returns a new DescribeRegistriesPaginator
+func NewDescribeRegistriesPaginator(client DescribeRegistriesAPIClient, params *DescribeRegistriesInput, optFns ...func(*DescribeRegistriesPaginatorOptions)) *DescribeRegistriesPaginator {
+ if params == nil {
+ params = &DescribeRegistriesInput{}
+ }
+
+ options := DescribeRegistriesPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &DescribeRegistriesPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *DescribeRegistriesPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next DescribeRegistries page.
+func (p *DescribeRegistriesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeRegistriesOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.DescribeRegistries(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opDescribeRegistries(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "DescribeRegistries",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeRepositories.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeRepositories.go
new file mode 100644
index 000000000000..6f446f513def
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_DescribeRepositories.go
@@ -0,0 +1,247 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Describes repositories in a public registry.
+func (c *Client) DescribeRepositories(ctx context.Context, params *DescribeRepositoriesInput, optFns ...func(*Options)) (*DescribeRepositoriesOutput, error) {
+ if params == nil {
+ params = &DescribeRepositoriesInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DescribeRepositories", params, optFns, c.addOperationDescribeRepositoriesMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DescribeRepositoriesOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DescribeRepositoriesInput struct {
+
+ // The maximum number of repository results returned by DescribeRepositories in
+ // paginated output. When this parameter is used, DescribeRepositories only returns
+ // maxResults results in a single page along with a nextToken response element. The
+ // remaining results of the initial request can be seen by sending another
+ // DescribeRepositories request with the returned nextToken value. This value can
+ // be between 1 and 1000. If this parameter is not used, then DescribeRepositories
+ // returns up to 100 results and a nextToken value, if applicable. This option
+ // cannot be used when you specify repositories with repositoryNames.
+ MaxResults *int32
+
+ // The nextToken value returned from a previous paginated DescribeRepositories
+ // request where maxResults was used and the results exceeded the value of that
+ // parameter. Pagination continues from the end of the previous results that
+ // returned the nextToken value. This value is null when there are no more results
+ // to return. This option cannot be used when you specify repositories with
+ // repositoryNames. This token should be treated as an opaque identifier that is
+ // only used to retrieve the next items in a list and not for other programmatic
+ // purposes.
+ NextToken *string
+
+ // The AWS account ID associated with the registry that contains the repositories
+ // to be described. If you do not specify a registry, the default public registry
+ // is assumed.
+ RegistryId *string
+
+ // A list of repositories to describe. If this parameter is omitted, then all
+ // repositories in a registry are described.
+ RepositoryNames []string
+
+ noSmithyDocumentSerde
+}
+
+type DescribeRepositoriesOutput struct {
+
+ // The nextToken value to include in a future DescribeRepositories request. When
+ // the results of a DescribeRepositories request exceed maxResults, this value can
+ // be used to retrieve the next page of results. This value is null when there are
+ // no more results to return.
+ NextToken *string
+
+ // A list of repository objects corresponding to valid repositories.
+ Repositories []types.Repository
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDescribeRepositoriesMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeRepositories{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeRepositories{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeRepositories(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// DescribeRepositoriesAPIClient is a client that implements the
+// DescribeRepositories operation.
+type DescribeRepositoriesAPIClient interface {
+ DescribeRepositories(context.Context, *DescribeRepositoriesInput, ...func(*Options)) (*DescribeRepositoriesOutput, error)
+}
+
+var _ DescribeRepositoriesAPIClient = (*Client)(nil)
+
+// DescribeRepositoriesPaginatorOptions is the paginator options for
+// DescribeRepositories
+type DescribeRepositoriesPaginatorOptions struct {
+ // The maximum number of repository results returned by DescribeRepositories in
+ // paginated output. When this parameter is used, DescribeRepositories only returns
+ // maxResults results in a single page along with a nextToken response element. The
+ // remaining results of the initial request can be seen by sending another
+ // DescribeRepositories request with the returned nextToken value. This value can
+ // be between 1 and 1000. If this parameter is not used, then DescribeRepositories
+ // returns up to 100 results and a nextToken value, if applicable. This option
+ // cannot be used when you specify repositories with repositoryNames.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// DescribeRepositoriesPaginator is a paginator for DescribeRepositories
+type DescribeRepositoriesPaginator struct {
+ options DescribeRepositoriesPaginatorOptions
+ client DescribeRepositoriesAPIClient
+ params *DescribeRepositoriesInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewDescribeRepositoriesPaginator returns a new DescribeRepositoriesPaginator
+func NewDescribeRepositoriesPaginator(client DescribeRepositoriesAPIClient, params *DescribeRepositoriesInput, optFns ...func(*DescribeRepositoriesPaginatorOptions)) *DescribeRepositoriesPaginator {
+ if params == nil {
+ params = &DescribeRepositoriesInput{}
+ }
+
+ options := DescribeRepositoriesPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &DescribeRepositoriesPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *DescribeRepositoriesPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next DescribeRepositories page.
+func (p *DescribeRepositoriesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*DescribeRepositoriesOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.DescribeRepositories(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opDescribeRepositories(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "DescribeRepositories",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetAuthorizationToken.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetAuthorizationToken.go
new file mode 100644
index 000000000000..adbe13a0c73f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetAuthorizationToken.go
@@ -0,0 +1,116 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieves an authorization token. An authorization token represents your IAM
+// authentication credentials and can be used to access any Amazon ECR registry
+// that your IAM principal has access to. The authorization token is valid for 12
+// hours. This API requires the ecr-public:GetAuthorizationToken and
+// sts:GetServiceBearerToken permissions.
+func (c *Client) GetAuthorizationToken(ctx context.Context, params *GetAuthorizationTokenInput, optFns ...func(*Options)) (*GetAuthorizationTokenOutput, error) {
+ if params == nil {
+ params = &GetAuthorizationTokenInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetAuthorizationToken", params, optFns, c.addOperationGetAuthorizationTokenMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetAuthorizationTokenOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetAuthorizationTokenInput struct {
+ noSmithyDocumentSerde
+}
+
+type GetAuthorizationTokenOutput struct {
+
+ // An authorization token data object that corresponds to a public registry.
+ AuthorizationData *types.AuthorizationData
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetAuthorizationTokenMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetAuthorizationToken{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetAuthorizationToken{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetAuthorizationToken(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetAuthorizationToken(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "GetAuthorizationToken",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRegistryCatalogData.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRegistryCatalogData.go
new file mode 100644
index 000000000000..88cd5b4bc9a5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRegistryCatalogData.go
@@ -0,0 +1,114 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieves catalog metadata for a public registry.
+func (c *Client) GetRegistryCatalogData(ctx context.Context, params *GetRegistryCatalogDataInput, optFns ...func(*Options)) (*GetRegistryCatalogDataOutput, error) {
+ if params == nil {
+ params = &GetRegistryCatalogDataInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetRegistryCatalogData", params, optFns, c.addOperationGetRegistryCatalogDataMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetRegistryCatalogDataOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetRegistryCatalogDataInput struct {
+ noSmithyDocumentSerde
+}
+
+type GetRegistryCatalogDataOutput struct {
+
+ // The catalog metadata for the public registry.
+ //
+ // This member is required.
+ RegistryCatalogData *types.RegistryCatalogData
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetRegistryCatalogDataMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetRegistryCatalogData{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetRegistryCatalogData{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetRegistryCatalogData(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetRegistryCatalogData(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "GetRegistryCatalogData",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRepositoryCatalogData.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRepositoryCatalogData.go
new file mode 100644
index 000000000000..5c7173fe335e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRepositoryCatalogData.go
@@ -0,0 +1,127 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieve catalog metadata for a repository in a public registry. This metadata
+// is displayed publicly in the Amazon ECR Public Gallery.
+func (c *Client) GetRepositoryCatalogData(ctx context.Context, params *GetRepositoryCatalogDataInput, optFns ...func(*Options)) (*GetRepositoryCatalogDataOutput, error) {
+ if params == nil {
+ params = &GetRepositoryCatalogDataInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetRepositoryCatalogData", params, optFns, c.addOperationGetRepositoryCatalogDataMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetRepositoryCatalogDataOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetRepositoryCatalogDataInput struct {
+
+ // The name of the repository to retrieve the catalog metadata for.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The AWS account ID associated with the registry that contains the repositories
+ // to be described. If you do not specify a registry, the default public registry
+ // is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type GetRepositoryCatalogDataOutput struct {
+
+ // The catalog metadata for the repository.
+ CatalogData *types.RepositoryCatalogData
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetRepositoryCatalogDataMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetRepositoryCatalogData{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetRepositoryCatalogData{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetRepositoryCatalogDataValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetRepositoryCatalogData(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetRepositoryCatalogData(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "GetRepositoryCatalogData",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRepositoryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRepositoryPolicy.go
new file mode 100644
index 000000000000..80584f924852
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_GetRepositoryPolicy.go
@@ -0,0 +1,132 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Retrieves the repository policy for the specified repository.
+func (c *Client) GetRepositoryPolicy(ctx context.Context, params *GetRepositoryPolicyInput, optFns ...func(*Options)) (*GetRepositoryPolicyOutput, error) {
+ if params == nil {
+ params = &GetRepositoryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetRepositoryPolicy", params, optFns, c.addOperationGetRepositoryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetRepositoryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetRepositoryPolicyInput struct {
+
+ // The name of the repository with the policy to retrieve.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The AWS account ID associated with the public registry that contains the
+ // repository. If you do not specify a registry, the default public registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type GetRepositoryPolicyOutput struct {
+
+ // The repository policy text associated with the repository. The policy text will
+ // be in JSON format.
+ PolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetRepositoryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetRepositoryPolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetRepositoryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetRepositoryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "GetRepositoryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_InitiateLayerUpload.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_InitiateLayerUpload.go
new file mode 100644
index 000000000000..1b4576d78da0
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_InitiateLayerUpload.go
@@ -0,0 +1,135 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Notifies Amazon ECR that you intend to upload an image layer. When an image is
+// pushed, the InitiateLayerUpload API is called once per image layer that has not
+// already been uploaded. Whether or not an image layer has been uploaded is
+// determined by the BatchCheckLayerAvailability API action. This operation is used
+// by the Amazon ECR proxy and is not generally used by customers for pulling and
+// pushing images. In most cases, you should use the docker CLI to pull, tag, and
+// push images.
+func (c *Client) InitiateLayerUpload(ctx context.Context, params *InitiateLayerUploadInput, optFns ...func(*Options)) (*InitiateLayerUploadOutput, error) {
+ if params == nil {
+ params = &InitiateLayerUploadInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "InitiateLayerUpload", params, optFns, c.addOperationInitiateLayerUploadMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*InitiateLayerUploadOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type InitiateLayerUploadInput struct {
+
+ // The name of the repository to which you intend to upload layers.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The AWS account ID associated with the registry to which you intend to upload
+ // layers. If you do not specify a registry, the default public registry is
+ // assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type InitiateLayerUploadOutput struct {
+
+ // The size, in bytes, that Amazon ECR expects future layer part uploads to be.
+ PartSize *int64
+
+ // The upload ID for the layer upload. This parameter is passed to further
+ // UploadLayerPart and CompleteLayerUpload operations.
+ UploadId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationInitiateLayerUploadMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpInitiateLayerUpload{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpInitiateLayerUpload{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpInitiateLayerUploadValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opInitiateLayerUpload(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opInitiateLayerUpload(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "InitiateLayerUpload",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_ListTagsForResource.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_ListTagsForResource.go
new file mode 100644
index 000000000000..6db00627999d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_ListTagsForResource.go
@@ -0,0 +1,122 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// List the tags for an Amazon ECR Public resource.
+func (c *Client) ListTagsForResource(ctx context.Context, params *ListTagsForResourceInput, optFns ...func(*Options)) (*ListTagsForResourceOutput, error) {
+ if params == nil {
+ params = &ListTagsForResourceInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "ListTagsForResource", params, optFns, c.addOperationListTagsForResourceMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*ListTagsForResourceOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type ListTagsForResourceInput struct {
+
+ // The Amazon Resource Name (ARN) that identifies the resource for which to list
+ // the tags. Currently, the supported resource is an Amazon ECR Public repository.
+ //
+ // This member is required.
+ ResourceArn *string
+
+ noSmithyDocumentSerde
+}
+
+type ListTagsForResourceOutput struct {
+
+ // The tags for the resource.
+ Tags []types.Tag
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationListTagsForResourceMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpListTagsForResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpListTagsForResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpListTagsForResourceValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListTagsForResource(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opListTagsForResource(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "ListTagsForResource",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutImage.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutImage.go
new file mode 100644
index 000000000000..3a2cbdbd869c
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutImage.go
@@ -0,0 +1,149 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates or updates the image manifest and tags associated with an image. When an
+// image is pushed and all new image layers have been uploaded, the PutImage API is
+// called once to create or update the image manifest and the tags associated with
+// the image. This operation is used by the Amazon ECR proxy and is not generally
+// used by customers for pulling and pushing images. In most cases, you should use
+// the docker CLI to pull, tag, and push images.
+func (c *Client) PutImage(ctx context.Context, params *PutImageInput, optFns ...func(*Options)) (*PutImageOutput, error) {
+ if params == nil {
+ params = &PutImageInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutImage", params, optFns, c.addOperationPutImageMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutImageOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutImageInput struct {
+
+ // The image manifest corresponding to the image to be uploaded.
+ //
+ // This member is required.
+ ImageManifest *string
+
+ // The name of the repository in which to put the image.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The image digest of the image manifest corresponding to the image.
+ ImageDigest *string
+
+ // The media type of the image manifest. If you push an image manifest that does
+ // not contain the mediaType field, you must specify the imageManifestMediaType in
+ // the request.
+ ImageManifestMediaType *string
+
+ // The tag to associate with the image. This parameter is required for images that
+ // use the Docker Image Manifest V2 Schema 2 or Open Container Initiative (OCI)
+ // formats.
+ ImageTag *string
+
+ // The AWS account ID associated with the public registry that contains the
+ // repository in which to put the image. If you do not specify a registry, the
+ // default public registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type PutImageOutput struct {
+
+ // Details of the image uploaded.
+ Image *types.Image
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutImageMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutImage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutImageValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutImage(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutImage(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "PutImage",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutRegistryCatalogData.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutRegistryCatalogData.go
new file mode 100644
index 000000000000..994364a53b28
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutRegistryCatalogData.go
@@ -0,0 +1,120 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Create or updates the catalog data for a public registry.
+func (c *Client) PutRegistryCatalogData(ctx context.Context, params *PutRegistryCatalogDataInput, optFns ...func(*Options)) (*PutRegistryCatalogDataOutput, error) {
+ if params == nil {
+ params = &PutRegistryCatalogDataInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutRegistryCatalogData", params, optFns, c.addOperationPutRegistryCatalogDataMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutRegistryCatalogDataOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutRegistryCatalogDataInput struct {
+
+ // The display name for a public registry. The display name is shown as the
+ // repository author in the Amazon ECR Public Gallery. The registry display name is
+ // only publicly visible in the Amazon ECR Public Gallery for verified accounts.
+ DisplayName *string
+
+ noSmithyDocumentSerde
+}
+
+type PutRegistryCatalogDataOutput struct {
+
+ // The catalog data for the public registry.
+ //
+ // This member is required.
+ RegistryCatalogData *types.RegistryCatalogData
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutRegistryCatalogDataMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutRegistryCatalogData{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutRegistryCatalogData{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutRegistryCatalogData(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutRegistryCatalogData(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "PutRegistryCatalogData",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutRepositoryCatalogData.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutRepositoryCatalogData.go
new file mode 100644
index 000000000000..4510287f32e2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_PutRepositoryCatalogData.go
@@ -0,0 +1,131 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Creates or updates the catalog data for a repository in a public registry.
+func (c *Client) PutRepositoryCatalogData(ctx context.Context, params *PutRepositoryCatalogDataInput, optFns ...func(*Options)) (*PutRepositoryCatalogDataOutput, error) {
+ if params == nil {
+ params = &PutRepositoryCatalogDataInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "PutRepositoryCatalogData", params, optFns, c.addOperationPutRepositoryCatalogDataMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*PutRepositoryCatalogDataOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type PutRepositoryCatalogDataInput struct {
+
+ // An object containing the catalog data for a repository. This data is publicly
+ // visible in the Amazon ECR Public Gallery.
+ //
+ // This member is required.
+ CatalogData *types.RepositoryCatalogDataInput
+
+ // The name of the repository to create or update the catalog data for.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The AWS account ID associated with the public registry the repository is in. If
+ // you do not specify a registry, the default public registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type PutRepositoryCatalogDataOutput struct {
+
+ // The catalog data for the repository.
+ CatalogData *types.RepositoryCatalogData
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationPutRepositoryCatalogDataMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpPutRepositoryCatalogData{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpPutRepositoryCatalogData{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpPutRepositoryCatalogDataValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutRepositoryCatalogData(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opPutRepositoryCatalogData(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "PutRepositoryCatalogData",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_SetRepositoryPolicy.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_SetRepositoryPolicy.go
new file mode 100644
index 000000000000..46fdd68ad53d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_SetRepositoryPolicy.go
@@ -0,0 +1,147 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Applies a repository policy to the specified public repository to control access
+// permissions. For more information, see Amazon ECR Repository Policies
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/repository-policies.html)
+// in the Amazon Elastic Container Registry User Guide.
+func (c *Client) SetRepositoryPolicy(ctx context.Context, params *SetRepositoryPolicyInput, optFns ...func(*Options)) (*SetRepositoryPolicyOutput, error) {
+ if params == nil {
+ params = &SetRepositoryPolicyInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "SetRepositoryPolicy", params, optFns, c.addOperationSetRepositoryPolicyMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*SetRepositoryPolicyOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type SetRepositoryPolicyInput struct {
+
+ // The JSON repository policy text to apply to the repository. For more
+ // information, see Amazon ECR Repository Policies
+ // (https://docs.aws.amazon.com/AmazonECR/latest/userguide/repository-policy-examples.html)
+ // in the Amazon Elastic Container Registry User Guide.
+ //
+ // This member is required.
+ PolicyText *string
+
+ // The name of the repository to receive the policy.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // If the policy you are attempting to set on a repository policy would prevent you
+ // from setting another policy in the future, you must force the
+ // SetRepositoryPolicy operation. This is intended to prevent accidental repository
+ // lock outs.
+ Force bool
+
+ // The AWS account ID associated with the registry that contains the repository. If
+ // you do not specify a registry, the default public registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type SetRepositoryPolicyOutput struct {
+
+ // The JSON repository policy text applied to the repository.
+ PolicyText *string
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationSetRepositoryPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpSetRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpSetRepositoryPolicy{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpSetRepositoryPolicyValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opSetRepositoryPolicy(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opSetRepositoryPolicy(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "SetRepositoryPolicy",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_TagResource.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_TagResource.go
new file mode 100644
index 000000000000..0e7044006e9e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_TagResource.go
@@ -0,0 +1,128 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Associates the specified tags to a resource with the specified resourceArn. If
+// existing tags on a resource are not specified in the request parameters, they
+// are not changed. When a resource is deleted, the tags associated with that
+// resource are deleted as well.
+func (c *Client) TagResource(ctx context.Context, params *TagResourceInput, optFns ...func(*Options)) (*TagResourceOutput, error) {
+ if params == nil {
+ params = &TagResourceInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "TagResource", params, optFns, c.addOperationTagResourceMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*TagResourceOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type TagResourceInput struct {
+
+ // The Amazon Resource Name (ARN) of the resource to which to add tags. Currently,
+ // the supported resource is an Amazon ECR Public repository.
+ //
+ // This member is required.
+ ResourceArn *string
+
+ // The tags to add to the resource. A tag is an array of key-value pairs. Tag keys
+ // can have a maximum character length of 128 characters, and tag values can have a
+ // maximum length of 256 characters.
+ //
+ // This member is required.
+ Tags []types.Tag
+
+ noSmithyDocumentSerde
+}
+
+type TagResourceOutput struct {
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationTagResourceMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpTagResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpTagResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpTagResourceValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opTagResource(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opTagResource(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "TagResource",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_UntagResource.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_UntagResource.go
new file mode 100644
index 000000000000..8f042d4c8485
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_UntagResource.go
@@ -0,0 +1,122 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Deletes specified tags from a resource.
+func (c *Client) UntagResource(ctx context.Context, params *UntagResourceInput, optFns ...func(*Options)) (*UntagResourceOutput, error) {
+ if params == nil {
+ params = &UntagResourceInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "UntagResource", params, optFns, c.addOperationUntagResourceMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*UntagResourceOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type UntagResourceInput struct {
+
+ // The Amazon Resource Name (ARN) of the resource from which to delete tags.
+ // Currently, the supported resource is an Amazon ECR Public repository.
+ //
+ // This member is required.
+ ResourceArn *string
+
+ // The keys of the tags to be removed.
+ //
+ // This member is required.
+ TagKeys []string
+
+ noSmithyDocumentSerde
+}
+
+type UntagResourceOutput struct {
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationUntagResourceMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpUntagResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpUntagResource{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpUntagResourceValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opUntagResource(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opUntagResource(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "UntagResource",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_UploadLayerPart.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_UploadLayerPart.go
new file mode 100644
index 000000000000..ce3fa0a4ad1f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/api_op_UploadLayerPart.go
@@ -0,0 +1,159 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Uploads an image layer part to Amazon ECR. When an image is pushed, each new
+// image layer is uploaded in parts. The maximum size of each image layer part can
+// be 20971520 bytes (or about 20MB). The UploadLayerPart API is called once per
+// each new image layer part. This operation is used by the Amazon ECR proxy and is
+// not generally used by customers for pulling and pushing images. In most cases,
+// you should use the docker CLI to pull, tag, and push images.
+func (c *Client) UploadLayerPart(ctx context.Context, params *UploadLayerPartInput, optFns ...func(*Options)) (*UploadLayerPartOutput, error) {
+ if params == nil {
+ params = &UploadLayerPartInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "UploadLayerPart", params, optFns, c.addOperationUploadLayerPartMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*UploadLayerPartOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type UploadLayerPartInput struct {
+
+ // The base64-encoded layer part payload.
+ //
+ // This member is required.
+ LayerPartBlob []byte
+
+ // The position of the first byte of the layer part witin the overall image layer.
+ //
+ // This member is required.
+ PartFirstByte *int64
+
+ // The position of the last byte of the layer part within the overall image layer.
+ //
+ // This member is required.
+ PartLastByte *int64
+
+ // The name of the repository to which you are uploading layer parts.
+ //
+ // This member is required.
+ RepositoryName *string
+
+ // The upload ID from a previous InitiateLayerUpload operation to associate with
+ // the layer part upload.
+ //
+ // This member is required.
+ UploadId *string
+
+ // The AWS account ID associated with the registry to which you are uploading layer
+ // parts. If you do not specify a registry, the default public registry is assumed.
+ RegistryId *string
+
+ noSmithyDocumentSerde
+}
+
+type UploadLayerPartOutput struct {
+
+ // The integer value of the last byte received in the request.
+ LastByteReceived *int64
+
+ // The registry ID associated with the request.
+ RegistryId *string
+
+ // The repository name associated with the request.
+ RepositoryName *string
+
+ // The upload ID associated with the request.
+ UploadId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationUploadLayerPartMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsjson11_serializeOpUploadLayerPart{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpUploadLayerPart{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpUploadLayerPartValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opUploadLayerPart(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opUploadLayerPart(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "ecr-public",
+ OperationName: "UploadLayerPart",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/deserializers.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/deserializers.go
new file mode 100644
index 000000000000..2a9ac62046fe
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/deserializers.go
@@ -0,0 +1,7053 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "bytes"
+ "context"
+ "encoding/json"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/aws/protocol/restjson"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ smithy "github.com/aws/smithy-go"
+ smithyio "github.com/aws/smithy-go/io"
+ "github.com/aws/smithy-go/middleware"
+ "github.com/aws/smithy-go/ptr"
+ smithytime "github.com/aws/smithy-go/time"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "io"
+ "strings"
+)
+
+type awsAwsjson11_deserializeOpBatchCheckLayerAvailability struct {
+}
+
+func (*awsAwsjson11_deserializeOpBatchCheckLayerAvailability) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpBatchCheckLayerAvailability) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorBatchCheckLayerAvailability(response, &metadata)
+ }
+ output := &BatchCheckLayerAvailabilityOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentBatchCheckLayerAvailabilityOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorBatchCheckLayerAvailability(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RegistryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRegistryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpBatchDeleteImage struct {
+}
+
+func (*awsAwsjson11_deserializeOpBatchDeleteImage) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpBatchDeleteImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorBatchDeleteImage(response, &metadata)
+ }
+ output := &BatchDeleteImageOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentBatchDeleteImageOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorBatchDeleteImage(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpCompleteLayerUpload struct {
+}
+
+func (*awsAwsjson11_deserializeOpCompleteLayerUpload) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpCompleteLayerUpload) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorCompleteLayerUpload(response, &metadata)
+ }
+ output := &CompleteLayerUploadOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentCompleteLayerUploadOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorCompleteLayerUpload(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("EmptyUploadException", errorCode):
+ return awsAwsjson11_deserializeErrorEmptyUploadException(response, errorBody)
+
+ case strings.EqualFold("InvalidLayerException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidLayerException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LayerAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorLayerAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("LayerPartTooSmallException", errorCode):
+ return awsAwsjson11_deserializeErrorLayerPartTooSmallException(response, errorBody)
+
+ case strings.EqualFold("RegistryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRegistryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedCommandException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedCommandException(response, errorBody)
+
+ case strings.EqualFold("UploadNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorUploadNotFoundException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpCreateRepository struct {
+}
+
+func (*awsAwsjson11_deserializeOpCreateRepository) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpCreateRepository) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorCreateRepository(response, &metadata)
+ }
+ output := &CreateRepositoryOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentCreateRepositoryOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorCreateRepository(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("InvalidTagParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidTagParameterException(response, errorBody)
+
+ case strings.EqualFold("LimitExceededException", errorCode):
+ return awsAwsjson11_deserializeErrorLimitExceededException(response, errorBody)
+
+ case strings.EqualFold("RepositoryAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("TooManyTagsException", errorCode):
+ return awsAwsjson11_deserializeErrorTooManyTagsException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDeleteRepository struct {
+}
+
+func (*awsAwsjson11_deserializeOpDeleteRepository) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDeleteRepository) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDeleteRepository(response, &metadata)
+ }
+ output := &DeleteRepositoryOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDeleteRepositoryOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDeleteRepository(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotEmptyException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotEmptyException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDeleteRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpDeleteRepositoryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDeleteRepositoryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDeleteRepositoryPolicy(response, &metadata)
+ }
+ output := &DeleteRepositoryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDeleteRepositoryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDeleteRepositoryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryPolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryPolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeImages struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeImages) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeImages) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeImages(response, &metadata)
+ }
+ output := &DescribeImagesOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeImagesOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeImages(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("ImageNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorImageNotFoundException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeImageTags struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeImageTags) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeImageTags) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeImageTags(response, &metadata)
+ }
+ output := &DescribeImageTagsOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeImageTagsOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeImageTags(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeRegistries struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeRegistries) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeRegistries) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeRegistries(response, &metadata)
+ }
+ output := &DescribeRegistriesOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeRegistriesOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeRegistries(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedCommandException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedCommandException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpDescribeRepositories struct {
+}
+
+func (*awsAwsjson11_deserializeOpDescribeRepositories) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpDescribeRepositories) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorDescribeRepositories(response, &metadata)
+ }
+ output := &DescribeRepositoriesOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentDescribeRepositoriesOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorDescribeRepositories(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetAuthorizationToken struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetAuthorizationToken) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetAuthorizationToken) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetAuthorizationToken(response, &metadata)
+ }
+ output := &GetAuthorizationTokenOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetAuthorizationTokenOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetAuthorizationToken(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetRegistryCatalogData struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetRegistryCatalogData) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetRegistryCatalogData) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetRegistryCatalogData(response, &metadata)
+ }
+ output := &GetRegistryCatalogDataOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetRegistryCatalogDataOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetRegistryCatalogData(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedCommandException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedCommandException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetRepositoryCatalogData struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetRepositoryCatalogData) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetRepositoryCatalogData) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetRepositoryCatalogData(response, &metadata)
+ }
+ output := &GetRepositoryCatalogDataOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetRepositoryCatalogDataOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetRepositoryCatalogData(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpGetRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpGetRepositoryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpGetRepositoryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorGetRepositoryPolicy(response, &metadata)
+ }
+ output := &GetRepositoryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentGetRepositoryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorGetRepositoryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryPolicyNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryPolicyNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpInitiateLayerUpload struct {
+}
+
+func (*awsAwsjson11_deserializeOpInitiateLayerUpload) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpInitiateLayerUpload) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorInitiateLayerUpload(response, &metadata)
+ }
+ output := &InitiateLayerUploadOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentInitiateLayerUploadOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorInitiateLayerUpload(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RegistryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRegistryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedCommandException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedCommandException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpListTagsForResource struct {
+}
+
+func (*awsAwsjson11_deserializeOpListTagsForResource) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpListTagsForResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorListTagsForResource(response, &metadata)
+ }
+ output := &ListTagsForResourceOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentListTagsForResourceOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorListTagsForResource(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutImage struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutImage) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutImage(response, &metadata)
+ }
+ output := &PutImageOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutImageOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutImage(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("ImageAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorImageAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("ImageDigestDoesNotMatchException", errorCode):
+ return awsAwsjson11_deserializeErrorImageDigestDoesNotMatchException(response, errorBody)
+
+ case strings.EqualFold("ImageTagAlreadyExistsException", errorCode):
+ return awsAwsjson11_deserializeErrorImageTagAlreadyExistsException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LayersNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorLayersNotFoundException(response, errorBody)
+
+ case strings.EqualFold("LimitExceededException", errorCode):
+ return awsAwsjson11_deserializeErrorLimitExceededException(response, errorBody)
+
+ case strings.EqualFold("ReferencedImagesNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorReferencedImagesNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RegistryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRegistryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedCommandException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedCommandException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutRegistryCatalogData struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutRegistryCatalogData) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutRegistryCatalogData) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutRegistryCatalogData(response, &metadata)
+ }
+ output := &PutRegistryCatalogDataOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutRegistryCatalogDataOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutRegistryCatalogData(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedCommandException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedCommandException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpPutRepositoryCatalogData struct {
+}
+
+func (*awsAwsjson11_deserializeOpPutRepositoryCatalogData) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpPutRepositoryCatalogData) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorPutRepositoryCatalogData(response, &metadata)
+ }
+ output := &PutRepositoryCatalogDataOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentPutRepositoryCatalogDataOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorPutRepositoryCatalogData(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpSetRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_deserializeOpSetRepositoryPolicy) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpSetRepositoryPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorSetRepositoryPolicy(response, &metadata)
+ }
+ output := &SetRepositoryPolicyOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentSetRepositoryPolicyOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorSetRepositoryPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpTagResource struct {
+}
+
+func (*awsAwsjson11_deserializeOpTagResource) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpTagResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorTagResource(response, &metadata)
+ }
+ output := &TagResourceOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentTagResourceOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorTagResource(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("InvalidTagParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidTagParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("TooManyTagsException", errorCode):
+ return awsAwsjson11_deserializeErrorTooManyTagsException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpUntagResource struct {
+}
+
+func (*awsAwsjson11_deserializeOpUntagResource) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpUntagResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorUntagResource(response, &metadata)
+ }
+ output := &UntagResourceOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentUntagResourceOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorUntagResource(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("InvalidTagParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidTagParameterException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("TooManyTagsException", errorCode):
+ return awsAwsjson11_deserializeErrorTooManyTagsException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsjson11_deserializeOpUploadLayerPart struct {
+}
+
+func (*awsAwsjson11_deserializeOpUploadLayerPart) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsjson11_deserializeOpUploadLayerPart) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsjson11_deserializeOpErrorUploadLayerPart(response, &metadata)
+ }
+ output := &UploadLayerPartOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsAwsjson11_deserializeOpDocumentUploadLayerPartOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsjson11_deserializeOpErrorUploadLayerPart(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidLayerPartException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidLayerPartException(response, errorBody)
+
+ case strings.EqualFold("InvalidParameterException", errorCode):
+ return awsAwsjson11_deserializeErrorInvalidParameterException(response, errorBody)
+
+ case strings.EqualFold("LimitExceededException", errorCode):
+ return awsAwsjson11_deserializeErrorLimitExceededException(response, errorBody)
+
+ case strings.EqualFold("RegistryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRegistryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("RepositoryNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorRepositoryNotFoundException(response, errorBody)
+
+ case strings.EqualFold("ServerException", errorCode):
+ return awsAwsjson11_deserializeErrorServerException(response, errorBody)
+
+ case strings.EqualFold("UnsupportedCommandException", errorCode):
+ return awsAwsjson11_deserializeErrorUnsupportedCommandException(response, errorBody)
+
+ case strings.EqualFold("UploadNotFoundException", errorCode):
+ return awsAwsjson11_deserializeErrorUploadNotFoundException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+func awsAwsjson11_deserializeErrorEmptyUploadException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.EmptyUploadException{}
+ err := awsAwsjson11_deserializeDocumentEmptyUploadException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorImageAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ImageAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentImageAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorImageDigestDoesNotMatchException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ImageDigestDoesNotMatchException{}
+ err := awsAwsjson11_deserializeDocumentImageDigestDoesNotMatchException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorImageNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ImageNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentImageNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorImageTagAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ImageTagAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentImageTagAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorInvalidLayerException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.InvalidLayerException{}
+ err := awsAwsjson11_deserializeDocumentInvalidLayerException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorInvalidLayerPartException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.InvalidLayerPartException{}
+ err := awsAwsjson11_deserializeDocumentInvalidLayerPartException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorInvalidParameterException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.InvalidParameterException{}
+ err := awsAwsjson11_deserializeDocumentInvalidParameterException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorInvalidTagParameterException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.InvalidTagParameterException{}
+ err := awsAwsjson11_deserializeDocumentInvalidTagParameterException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLayerAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LayerAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentLayerAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLayerPartTooSmallException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LayerPartTooSmallException{}
+ err := awsAwsjson11_deserializeDocumentLayerPartTooSmallException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLayersNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LayersNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentLayersNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorLimitExceededException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.LimitExceededException{}
+ err := awsAwsjson11_deserializeDocumentLimitExceededException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorReferencedImagesNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ReferencedImagesNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentReferencedImagesNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRegistryNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RegistryNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentRegistryNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRepositoryAlreadyExistsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RepositoryAlreadyExistsException{}
+ err := awsAwsjson11_deserializeDocumentRepositoryAlreadyExistsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRepositoryNotEmptyException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RepositoryNotEmptyException{}
+ err := awsAwsjson11_deserializeDocumentRepositoryNotEmptyException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRepositoryNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RepositoryNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentRepositoryNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorRepositoryPolicyNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.RepositoryPolicyNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentRepositoryPolicyNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorServerException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.ServerException{}
+ err := awsAwsjson11_deserializeDocumentServerException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorTooManyTagsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.TooManyTagsException{}
+ err := awsAwsjson11_deserializeDocumentTooManyTagsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorUnsupportedCommandException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.UnsupportedCommandException{}
+ err := awsAwsjson11_deserializeDocumentUnsupportedCommandException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeErrorUploadNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ output := &types.UploadNotFoundException{}
+ err := awsAwsjson11_deserializeDocumentUploadNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ return output
+}
+
+func awsAwsjson11_deserializeDocumentArchitectureList(v *[]string, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []string
+ if *v == nil {
+ cv = []string{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col string
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Architecture to be of type string, got %T instead", value)
+ }
+ col = jtv
+ }
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentAuthorizationData(v **types.AuthorizationData, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.AuthorizationData
+ if *v == nil {
+ sv = &types.AuthorizationData{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "authorizationToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Base64 to be of type string, got %T instead", value)
+ }
+ sv.AuthorizationToken = ptr.String(jtv)
+ }
+
+ case "expiresAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.ExpiresAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected ExpirationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentEmptyUploadException(v **types.EmptyUploadException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.EmptyUploadException
+ if *v == nil {
+ sv = &types.EmptyUploadException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImage(v **types.Image, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Image
+ if *v == nil {
+ sv = &types.Image{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageId":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&sv.ImageId, value); err != nil {
+ return err
+ }
+
+ case "imageManifest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageManifest to be of type string, got %T instead", value)
+ }
+ sv.ImageManifest = ptr.String(jtv)
+ }
+
+ case "imageManifestMediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.ImageManifestMediaType = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryIdOrAlias to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageAlreadyExistsException(v **types.ImageAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageAlreadyExistsException
+ if *v == nil {
+ sv = &types.ImageAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageDetail(v **types.ImageDetail, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageDetail
+ if *v == nil {
+ sv = &types.ImageDetail{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "artifactMediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.ArtifactMediaType = ptr.String(jtv)
+ }
+
+ case "imageDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageDigest to be of type string, got %T instead", value)
+ }
+ sv.ImageDigest = ptr.String(jtv)
+ }
+
+ case "imageManifestMediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.ImageManifestMediaType = ptr.String(jtv)
+ }
+
+ case "imagePushedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.ImagePushedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected PushTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "imageSizeInBytes":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected ImageSizeInBytes to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.ImageSizeInBytes = ptr.Int64(i64)
+ }
+
+ case "imageTags":
+ if err := awsAwsjson11_deserializeDocumentImageTagList(&sv.ImageTags, value); err != nil {
+ return err
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageDetailList(v *[]types.ImageDetail, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageDetail
+ if *v == nil {
+ cv = []types.ImageDetail{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageDetail
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageDetail(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageDigestDoesNotMatchException(v **types.ImageDigestDoesNotMatchException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageDigestDoesNotMatchException
+ if *v == nil {
+ sv = &types.ImageDigestDoesNotMatchException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageFailure(v **types.ImageFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageFailure
+ if *v == nil {
+ sv = &types.ImageFailure{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failureCode":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageFailureCode to be of type string, got %T instead", value)
+ }
+ sv.FailureCode = types.ImageFailureCode(jtv)
+ }
+
+ case "failureReason":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageFailureReason to be of type string, got %T instead", value)
+ }
+ sv.FailureReason = ptr.String(jtv)
+ }
+
+ case "imageId":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&sv.ImageId, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageFailureList(v *[]types.ImageFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageFailure
+ if *v == nil {
+ cv = []types.ImageFailure{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageFailure
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageFailure(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageIdentifier(v **types.ImageIdentifier, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageIdentifier
+ if *v == nil {
+ sv = &types.ImageIdentifier{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageDigest to be of type string, got %T instead", value)
+ }
+ sv.ImageDigest = ptr.String(jtv)
+ }
+
+ case "imageTag":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageTag to be of type string, got %T instead", value)
+ }
+ sv.ImageTag = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageIdentifierList(v *[]types.ImageIdentifier, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageIdentifier
+ if *v == nil {
+ cv = []types.ImageIdentifier{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageIdentifier
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageIdentifier(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageNotFoundException(v **types.ImageNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageNotFoundException
+ if *v == nil {
+ sv = &types.ImageNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageTagAlreadyExistsException(v **types.ImageTagAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageTagAlreadyExistsException
+ if *v == nil {
+ sv = &types.ImageTagAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageTagDetail(v **types.ImageTagDetail, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ImageTagDetail
+ if *v == nil {
+ sv = &types.ImageTagDetail{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "createdAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected CreationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "imageDetail":
+ if err := awsAwsjson11_deserializeDocumentReferencedImageDetail(&sv.ImageDetail, value); err != nil {
+ return err
+ }
+
+ case "imageTag":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageTag to be of type string, got %T instead", value)
+ }
+ sv.ImageTag = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageTagDetailList(v *[]types.ImageTagDetail, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.ImageTagDetail
+ if *v == nil {
+ cv = []types.ImageTagDetail{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.ImageTagDetail
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentImageTagDetail(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentImageTagList(v *[]string, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []string
+ if *v == nil {
+ cv = []string{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col string
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageTag to be of type string, got %T instead", value)
+ }
+ col = jtv
+ }
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentInvalidLayerException(v **types.InvalidLayerException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidLayerException
+ if *v == nil {
+ sv = &types.InvalidLayerException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentInvalidLayerPartException(v **types.InvalidLayerPartException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidLayerPartException
+ if *v == nil {
+ sv = &types.InvalidLayerPartException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lastValidByteReceived":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected PartSize to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.LastValidByteReceived = ptr.Int64(i64)
+ }
+
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "uploadId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UploadId to be of type string, got %T instead", value)
+ }
+ sv.UploadId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentInvalidParameterException(v **types.InvalidParameterException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidParameterException
+ if *v == nil {
+ sv = &types.InvalidParameterException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentInvalidTagParameterException(v **types.InvalidTagParameterException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidTagParameterException
+ if *v == nil {
+ sv = &types.InvalidTagParameterException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayer(v **types.Layer, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Layer
+ if *v == nil {
+ sv = &types.Layer{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "layerAvailability":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerAvailability to be of type string, got %T instead", value)
+ }
+ sv.LayerAvailability = types.LayerAvailability(jtv)
+ }
+
+ case "layerDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerDigest to be of type string, got %T instead", value)
+ }
+ sv.LayerDigest = ptr.String(jtv)
+ }
+
+ case "layerSize":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected LayerSizeInBytes to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.LayerSize = ptr.Int64(i64)
+ }
+
+ case "mediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.MediaType = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerAlreadyExistsException(v **types.LayerAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayerAlreadyExistsException
+ if *v == nil {
+ sv = &types.LayerAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerFailure(v **types.LayerFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayerFailure
+ if *v == nil {
+ sv = &types.LayerFailure{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failureCode":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerFailureCode to be of type string, got %T instead", value)
+ }
+ sv.FailureCode = types.LayerFailureCode(jtv)
+ }
+
+ case "failureReason":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerFailureReason to be of type string, got %T instead", value)
+ }
+ sv.FailureReason = ptr.String(jtv)
+ }
+
+ case "layerDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected BatchedOperationLayerDigest to be of type string, got %T instead", value)
+ }
+ sv.LayerDigest = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerFailureList(v *[]types.LayerFailure, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.LayerFailure
+ if *v == nil {
+ cv = []types.LayerFailure{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.LayerFailure
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentLayerFailure(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerList(v *[]types.Layer, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Layer
+ if *v == nil {
+ cv = []types.Layer{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Layer
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentLayer(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayerPartTooSmallException(v **types.LayerPartTooSmallException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayerPartTooSmallException
+ if *v == nil {
+ sv = &types.LayerPartTooSmallException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLayersNotFoundException(v **types.LayersNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LayersNotFoundException
+ if *v == nil {
+ sv = &types.LayersNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentLimitExceededException(v **types.LimitExceededException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.LimitExceededException
+ if *v == nil {
+ sv = &types.LimitExceededException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentOperatingSystemList(v *[]string, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []string
+ if *v == nil {
+ cv = []string{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col string
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected OperatingSystem to be of type string, got %T instead", value)
+ }
+ col = jtv
+ }
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReferencedImageDetail(v **types.ReferencedImageDetail, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ReferencedImageDetail
+ if *v == nil {
+ sv = &types.ReferencedImageDetail{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "artifactMediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.ArtifactMediaType = ptr.String(jtv)
+ }
+
+ case "imageDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ImageDigest to be of type string, got %T instead", value)
+ }
+ sv.ImageDigest = ptr.String(jtv)
+ }
+
+ case "imageManifestMediaType":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected MediaType to be of type string, got %T instead", value)
+ }
+ sv.ImageManifestMediaType = ptr.String(jtv)
+ }
+
+ case "imagePushedAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.ImagePushedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected PushTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "imageSizeInBytes":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected ImageSizeInBytes to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.ImageSizeInBytes = ptr.Int64(i64)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentReferencedImagesNotFoundException(v **types.ReferencedImagesNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ReferencedImagesNotFoundException
+ if *v == nil {
+ sv = &types.ReferencedImagesNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistry(v **types.Registry, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Registry
+ if *v == nil {
+ sv = &types.Registry{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "aliases":
+ if err := awsAwsjson11_deserializeDocumentRegistryAliasList(&sv.Aliases, value); err != nil {
+ return err
+ }
+
+ case "registryArn":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Arn to be of type string, got %T instead", value)
+ }
+ sv.RegistryArn = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "registryUri":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.RegistryUri = ptr.String(jtv)
+ }
+
+ case "verified":
+ if value != nil {
+ jtv, ok := value.(bool)
+ if !ok {
+ return fmt.Errorf("expected RegistryVerified to be of type *bool, got %T instead", value)
+ }
+ sv.Verified = ptr.Bool(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryAlias(v **types.RegistryAlias, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RegistryAlias
+ if *v == nil {
+ sv = &types.RegistryAlias{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "defaultRegistryAlias":
+ if value != nil {
+ jtv, ok := value.(bool)
+ if !ok {
+ return fmt.Errorf("expected DefaultRegistryAliasFlag to be of type *bool, got %T instead", value)
+ }
+ sv.DefaultRegistryAlias = jtv
+ }
+
+ case "name":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryAliasName to be of type string, got %T instead", value)
+ }
+ sv.Name = ptr.String(jtv)
+ }
+
+ case "primaryRegistryAlias":
+ if value != nil {
+ jtv, ok := value.(bool)
+ if !ok {
+ return fmt.Errorf("expected PrimaryRegistryAliasFlag to be of type *bool, got %T instead", value)
+ }
+ sv.PrimaryRegistryAlias = jtv
+ }
+
+ case "status":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryAliasStatus to be of type string, got %T instead", value)
+ }
+ sv.Status = types.RegistryAliasStatus(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryAliasList(v *[]types.RegistryAlias, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.RegistryAlias
+ if *v == nil {
+ cv = []types.RegistryAlias{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.RegistryAlias
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentRegistryAlias(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryCatalogData(v **types.RegistryCatalogData, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RegistryCatalogData
+ if *v == nil {
+ sv = &types.RegistryCatalogData{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "displayName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryDisplayName to be of type string, got %T instead", value)
+ }
+ sv.DisplayName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryList(v *[]types.Registry, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Registry
+ if *v == nil {
+ cv = []types.Registry{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Registry
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentRegistry(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRegistryNotFoundException(v **types.RegistryNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RegistryNotFoundException
+ if *v == nil {
+ sv = &types.RegistryNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepository(v **types.Repository, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Repository
+ if *v == nil {
+ sv = &types.Repository{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "createdAt":
+ if value != nil {
+ switch jtv := value.(type) {
+ case json.Number:
+ f64, err := jtv.Float64()
+ if err != nil {
+ return err
+ }
+ sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64))
+
+ default:
+ return fmt.Errorf("expected CreationTimestamp to be a JSON Number, got %T instead", value)
+
+ }
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryArn":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Arn to be of type string, got %T instead", value)
+ }
+ sv.RepositoryArn = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "repositoryUri":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected Url to be of type string, got %T instead", value)
+ }
+ sv.RepositoryUri = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryAlreadyExistsException(v **types.RepositoryAlreadyExistsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryAlreadyExistsException
+ if *v == nil {
+ sv = &types.RepositoryAlreadyExistsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryCatalogData(v **types.RepositoryCatalogData, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryCatalogData
+ if *v == nil {
+ sv = &types.RepositoryCatalogData{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "aboutText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected AboutText to be of type string, got %T instead", value)
+ }
+ sv.AboutText = ptr.String(jtv)
+ }
+
+ case "architectures":
+ if err := awsAwsjson11_deserializeDocumentArchitectureList(&sv.Architectures, value); err != nil {
+ return err
+ }
+
+ case "description":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryDescription to be of type string, got %T instead", value)
+ }
+ sv.Description = ptr.String(jtv)
+ }
+
+ case "logoUrl":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ResourceUrl to be of type string, got %T instead", value)
+ }
+ sv.LogoUrl = ptr.String(jtv)
+ }
+
+ case "marketplaceCertified":
+ if value != nil {
+ jtv, ok := value.(bool)
+ if !ok {
+ return fmt.Errorf("expected MarketplaceCertified to be of type *bool, got %T instead", value)
+ }
+ sv.MarketplaceCertified = ptr.Bool(jtv)
+ }
+
+ case "operatingSystems":
+ if err := awsAwsjson11_deserializeDocumentOperatingSystemList(&sv.OperatingSystems, value); err != nil {
+ return err
+ }
+
+ case "usageText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UsageText to be of type string, got %T instead", value)
+ }
+ sv.UsageText = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryList(v *[]types.Repository, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Repository
+ if *v == nil {
+ cv = []types.Repository{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Repository
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentRepository(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryNotEmptyException(v **types.RepositoryNotEmptyException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryNotEmptyException
+ if *v == nil {
+ sv = &types.RepositoryNotEmptyException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryNotFoundException(v **types.RepositoryNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryNotFoundException
+ if *v == nil {
+ sv = &types.RepositoryNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentRepositoryPolicyNotFoundException(v **types.RepositoryPolicyNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RepositoryPolicyNotFoundException
+ if *v == nil {
+ sv = &types.RepositoryPolicyNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentServerException(v **types.ServerException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ServerException
+ if *v == nil {
+ sv = &types.ServerException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentTag(v **types.Tag, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.Tag
+ if *v == nil {
+ sv = &types.Tag{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "Key":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected TagKey to be of type string, got %T instead", value)
+ }
+ sv.Key = ptr.String(jtv)
+ }
+
+ case "Value":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected TagValue to be of type string, got %T instead", value)
+ }
+ sv.Value = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentTagList(v *[]types.Tag, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.Tag
+ if *v == nil {
+ cv = []types.Tag{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.Tag
+ destAddr := &col
+ if err := awsAwsjson11_deserializeDocumentTag(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentTooManyTagsException(v **types.TooManyTagsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.TooManyTagsException
+ if *v == nil {
+ sv = &types.TooManyTagsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentUnsupportedCommandException(v **types.UnsupportedCommandException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.UnsupportedCommandException
+ if *v == nil {
+ sv = &types.UnsupportedCommandException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeDocumentUploadNotFoundException(v **types.UploadNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.UploadNotFoundException
+ if *v == nil {
+ sv = &types.UploadNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ExceptionMessage to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentBatchCheckLayerAvailabilityOutput(v **BatchCheckLayerAvailabilityOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *BatchCheckLayerAvailabilityOutput
+ if *v == nil {
+ sv = &BatchCheckLayerAvailabilityOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failures":
+ if err := awsAwsjson11_deserializeDocumentLayerFailureList(&sv.Failures, value); err != nil {
+ return err
+ }
+
+ case "layers":
+ if err := awsAwsjson11_deserializeDocumentLayerList(&sv.Layers, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentBatchDeleteImageOutput(v **BatchDeleteImageOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *BatchDeleteImageOutput
+ if *v == nil {
+ sv = &BatchDeleteImageOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "failures":
+ if err := awsAwsjson11_deserializeDocumentImageFailureList(&sv.Failures, value); err != nil {
+ return err
+ }
+
+ case "imageIds":
+ if err := awsAwsjson11_deserializeDocumentImageIdentifierList(&sv.ImageIds, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentCompleteLayerUploadOutput(v **CompleteLayerUploadOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *CompleteLayerUploadOutput
+ if *v == nil {
+ sv = &CompleteLayerUploadOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "layerDigest":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected LayerDigest to be of type string, got %T instead", value)
+ }
+ sv.LayerDigest = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "uploadId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UploadId to be of type string, got %T instead", value)
+ }
+ sv.UploadId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentCreateRepositoryOutput(v **CreateRepositoryOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *CreateRepositoryOutput
+ if *v == nil {
+ sv = &CreateRepositoryOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "catalogData":
+ if err := awsAwsjson11_deserializeDocumentRepositoryCatalogData(&sv.CatalogData, value); err != nil {
+ return err
+ }
+
+ case "repository":
+ if err := awsAwsjson11_deserializeDocumentRepository(&sv.Repository, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDeleteRepositoryOutput(v **DeleteRepositoryOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DeleteRepositoryOutput
+ if *v == nil {
+ sv = &DeleteRepositoryOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "repository":
+ if err := awsAwsjson11_deserializeDocumentRepository(&sv.Repository, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDeleteRepositoryPolicyOutput(v **DeleteRepositoryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DeleteRepositoryPolicyOutput
+ if *v == nil {
+ sv = &DeleteRepositoryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeImagesOutput(v **DescribeImagesOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeImagesOutput
+ if *v == nil {
+ sv = &DescribeImagesOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageDetails":
+ if err := awsAwsjson11_deserializeDocumentImageDetailList(&sv.ImageDetails, value); err != nil {
+ return err
+ }
+
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeImageTagsOutput(v **DescribeImageTagsOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeImageTagsOutput
+ if *v == nil {
+ sv = &DescribeImageTagsOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "imageTagDetails":
+ if err := awsAwsjson11_deserializeDocumentImageTagDetailList(&sv.ImageTagDetails, value); err != nil {
+ return err
+ }
+
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeRegistriesOutput(v **DescribeRegistriesOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeRegistriesOutput
+ if *v == nil {
+ sv = &DescribeRegistriesOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ case "registries":
+ if err := awsAwsjson11_deserializeDocumentRegistryList(&sv.Registries, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentDescribeRepositoriesOutput(v **DescribeRepositoriesOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *DescribeRepositoriesOutput
+ if *v == nil {
+ sv = &DescribeRepositoriesOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextToken to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ case "repositories":
+ if err := awsAwsjson11_deserializeDocumentRepositoryList(&sv.Repositories, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetAuthorizationTokenOutput(v **GetAuthorizationTokenOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetAuthorizationTokenOutput
+ if *v == nil {
+ sv = &GetAuthorizationTokenOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "authorizationData":
+ if err := awsAwsjson11_deserializeDocumentAuthorizationData(&sv.AuthorizationData, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetRegistryCatalogDataOutput(v **GetRegistryCatalogDataOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetRegistryCatalogDataOutput
+ if *v == nil {
+ sv = &GetRegistryCatalogDataOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "registryCatalogData":
+ if err := awsAwsjson11_deserializeDocumentRegistryCatalogData(&sv.RegistryCatalogData, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetRepositoryCatalogDataOutput(v **GetRepositoryCatalogDataOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetRepositoryCatalogDataOutput
+ if *v == nil {
+ sv = &GetRepositoryCatalogDataOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "catalogData":
+ if err := awsAwsjson11_deserializeDocumentRepositoryCatalogData(&sv.CatalogData, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentGetRepositoryPolicyOutput(v **GetRepositoryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetRepositoryPolicyOutput
+ if *v == nil {
+ sv = &GetRepositoryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentInitiateLayerUploadOutput(v **InitiateLayerUploadOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *InitiateLayerUploadOutput
+ if *v == nil {
+ sv = &InitiateLayerUploadOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "partSize":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected PartSize to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.PartSize = ptr.Int64(i64)
+ }
+
+ case "uploadId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UploadId to be of type string, got %T instead", value)
+ }
+ sv.UploadId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentListTagsForResourceOutput(v **ListTagsForResourceOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *ListTagsForResourceOutput
+ if *v == nil {
+ sv = &ListTagsForResourceOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "tags":
+ if err := awsAwsjson11_deserializeDocumentTagList(&sv.Tags, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutImageOutput(v **PutImageOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutImageOutput
+ if *v == nil {
+ sv = &PutImageOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "image":
+ if err := awsAwsjson11_deserializeDocumentImage(&sv.Image, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutRegistryCatalogDataOutput(v **PutRegistryCatalogDataOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutRegistryCatalogDataOutput
+ if *v == nil {
+ sv = &PutRegistryCatalogDataOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "registryCatalogData":
+ if err := awsAwsjson11_deserializeDocumentRegistryCatalogData(&sv.RegistryCatalogData, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentPutRepositoryCatalogDataOutput(v **PutRepositoryCatalogDataOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *PutRepositoryCatalogDataOutput
+ if *v == nil {
+ sv = &PutRepositoryCatalogDataOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "catalogData":
+ if err := awsAwsjson11_deserializeDocumentRepositoryCatalogData(&sv.CatalogData, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentSetRepositoryPolicyOutput(v **SetRepositoryPolicyOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *SetRepositoryPolicyOutput
+ if *v == nil {
+ sv = &SetRepositoryPolicyOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "policyText":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryPolicyText to be of type string, got %T instead", value)
+ }
+ sv.PolicyText = ptr.String(jtv)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentTagResourceOutput(v **TagResourceOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *TagResourceOutput
+ if *v == nil {
+ sv = &TagResourceOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentUntagResourceOutput(v **UntagResourceOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *UntagResourceOutput
+ if *v == nil {
+ sv = &UntagResourceOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsjson11_deserializeOpDocumentUploadLayerPartOutput(v **UploadLayerPartOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *UploadLayerPartOutput
+ if *v == nil {
+ sv = &UploadLayerPartOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "lastByteReceived":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected PartSize to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.LastByteReceived = ptr.Int64(i64)
+ }
+
+ case "registryId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RegistryId to be of type string, got %T instead", value)
+ }
+ sv.RegistryId = ptr.String(jtv)
+ }
+
+ case "repositoryName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RepositoryName to be of type string, got %T instead", value)
+ }
+ sv.RepositoryName = ptr.String(jtv)
+ }
+
+ case "uploadId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected UploadId to be of type string, got %T instead", value)
+ }
+ sv.UploadId = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/doc.go
new file mode 100644
index 000000000000..a17297a0965f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/doc.go
@@ -0,0 +1,15 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+// Package ecrpublic provides the API client, operations, and parameter types for
+// Amazon Elastic Container Registry Public.
+//
+// Amazon Elastic Container Registry Public Amazon Elastic Container Registry
+// (Amazon ECR) is a managed container image registry service. Amazon ECR provides
+// both public and private registries to host your container images. You can use
+// the familiar Docker CLI, or their preferred client, to push, pull, and manage
+// images. Amazon ECR provides a secure, scalable, and reliable registry for your
+// Docker or Open Container Initiative (OCI) images. Amazon ECR supports public
+// repositories with this API. For information about the Amazon ECR API for private
+// repositories, see Amazon Elastic Container Registry API Reference
+// (https://docs.aws.amazon.com/AmazonECR/latest/APIReference/Welcome.html).
+package ecrpublic
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/endpoints.go
new file mode 100644
index 000000000000..071eca69cbb5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/endpoints.go
@@ -0,0 +1,200 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ internalendpoints "github.com/aws/aws-sdk-go-v2/service/ecrpublic/internal/endpoints"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "net/url"
+ "strings"
+)
+
+// EndpointResolverOptions is the service endpoint resolver options
+type EndpointResolverOptions = internalendpoints.Options
+
+// EndpointResolver interface for resolving service endpoints.
+type EndpointResolver interface {
+ ResolveEndpoint(region string, options EndpointResolverOptions) (aws.Endpoint, error)
+}
+
+var _ EndpointResolver = &internalendpoints.Resolver{}
+
+// NewDefaultEndpointResolver constructs a new service endpoint resolver
+func NewDefaultEndpointResolver() *internalendpoints.Resolver {
+ return internalendpoints.New()
+}
+
+// EndpointResolverFunc is a helper utility that wraps a function so it satisfies
+// the EndpointResolver interface. This is useful when you want to add additional
+// endpoint resolving logic, or stub out specific endpoints with custom values.
+type EndpointResolverFunc func(region string, options EndpointResolverOptions) (aws.Endpoint, error)
+
+func (fn EndpointResolverFunc) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error) {
+ return fn(region, options)
+}
+
+func resolveDefaultEndpointConfiguration(o *Options) {
+ if o.EndpointResolver != nil {
+ return
+ }
+ o.EndpointResolver = NewDefaultEndpointResolver()
+}
+
+// EndpointResolverFromURL returns an EndpointResolver configured using the
+// provided endpoint url. By default, the resolved endpoint resolver uses the
+// client region as signing region, and the endpoint source is set to
+// EndpointSourceCustom.You can provide functional options to configure endpoint
+// values for the resolved endpoint.
+func EndpointResolverFromURL(url string, optFns ...func(*aws.Endpoint)) EndpointResolver {
+ e := aws.Endpoint{URL: url, Source: aws.EndpointSourceCustom}
+ for _, fn := range optFns {
+ fn(&e)
+ }
+
+ return EndpointResolverFunc(
+ func(region string, options EndpointResolverOptions) (aws.Endpoint, error) {
+ if len(e.SigningRegion) == 0 {
+ e.SigningRegion = region
+ }
+ return e, nil
+ },
+ )
+}
+
+type ResolveEndpoint struct {
+ Resolver EndpointResolver
+ Options EndpointResolverOptions
+}
+
+func (*ResolveEndpoint) ID() string {
+ return "ResolveEndpoint"
+}
+
+func (m *ResolveEndpoint) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in.Request)
+ }
+
+ if m.Resolver == nil {
+ return out, metadata, fmt.Errorf("expected endpoint resolver to not be nil")
+ }
+
+ eo := m.Options
+ eo.Logger = middleware.GetLogger(ctx)
+
+ var endpoint aws.Endpoint
+ endpoint, err = m.Resolver.ResolveEndpoint(awsmiddleware.GetRegion(ctx), eo)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to resolve service endpoint, %w", err)
+ }
+
+ req.URL, err = url.Parse(endpoint.URL)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to parse endpoint URL: %w", err)
+ }
+
+ if len(awsmiddleware.GetSigningName(ctx)) == 0 {
+ signingName := endpoint.SigningName
+ if len(signingName) == 0 {
+ signingName = "ecr-public"
+ }
+ ctx = awsmiddleware.SetSigningName(ctx, signingName)
+ }
+ ctx = awsmiddleware.SetEndpointSource(ctx, endpoint.Source)
+ ctx = smithyhttp.SetHostnameImmutable(ctx, endpoint.HostnameImmutable)
+ ctx = awsmiddleware.SetSigningRegion(ctx, endpoint.SigningRegion)
+ ctx = awsmiddleware.SetPartitionID(ctx, endpoint.PartitionID)
+ return next.HandleSerialize(ctx, in)
+}
+func addResolveEndpointMiddleware(stack *middleware.Stack, o Options) error {
+ return stack.Serialize.Insert(&ResolveEndpoint{
+ Resolver: o.EndpointResolver,
+ Options: o.EndpointOptions,
+ }, "OperationSerializer", middleware.Before)
+}
+
+func removeResolveEndpointMiddleware(stack *middleware.Stack) error {
+ _, err := stack.Serialize.Remove((&ResolveEndpoint{}).ID())
+ return err
+}
+
+type wrappedEndpointResolver struct {
+ awsResolver aws.EndpointResolverWithOptions
+ resolver EndpointResolver
+}
+
+func (w *wrappedEndpointResolver) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error) {
+ if w.awsResolver == nil {
+ goto fallback
+ }
+ endpoint, err = w.awsResolver.ResolveEndpoint(ServiceID, region, options)
+ if err == nil {
+ return endpoint, nil
+ }
+
+ if nf := (&aws.EndpointNotFoundError{}); !errors.As(err, &nf) {
+ return endpoint, err
+ }
+
+fallback:
+ if w.resolver == nil {
+ return endpoint, fmt.Errorf("default endpoint resolver provided was nil")
+ }
+ return w.resolver.ResolveEndpoint(region, options)
+}
+
+type awsEndpointResolverAdaptor func(service, region string) (aws.Endpoint, error)
+
+func (a awsEndpointResolverAdaptor) ResolveEndpoint(service, region string, options ...interface{}) (aws.Endpoint, error) {
+ return a(service, region)
+}
+
+var _ aws.EndpointResolverWithOptions = awsEndpointResolverAdaptor(nil)
+
+// withEndpointResolver returns an EndpointResolver that first delegates endpoint resolution to the awsResolver.
+// If awsResolver returns aws.EndpointNotFoundError error, the resolver will use the the provided
+// fallbackResolver for resolution.
+//
+// fallbackResolver must not be nil
+func withEndpointResolver(awsResolver aws.EndpointResolver, awsResolverWithOptions aws.EndpointResolverWithOptions, fallbackResolver EndpointResolver) EndpointResolver {
+ var resolver aws.EndpointResolverWithOptions
+
+ if awsResolverWithOptions != nil {
+ resolver = awsResolverWithOptions
+ } else if awsResolver != nil {
+ resolver = awsEndpointResolverAdaptor(awsResolver.ResolveEndpoint)
+ }
+
+ return &wrappedEndpointResolver{
+ awsResolver: resolver,
+ resolver: fallbackResolver,
+ }
+}
+
+func finalizeClientEndpointResolverOptions(options *Options) {
+ options.EndpointOptions.LogDeprecated = options.ClientLogMode.IsDeprecatedUsage()
+
+ if len(options.EndpointOptions.ResolvedRegion) == 0 {
+ const fipsInfix = "-fips-"
+ const fipsPrefix = "fips-"
+ const fipsSuffix = "-fips"
+
+ if strings.Contains(options.Region, fipsInfix) ||
+ strings.Contains(options.Region, fipsPrefix) ||
+ strings.Contains(options.Region, fipsSuffix) {
+ options.EndpointOptions.ResolvedRegion = strings.ReplaceAll(strings.ReplaceAll(strings.ReplaceAll(
+ options.Region, fipsInfix, "-"), fipsPrefix, ""), fipsSuffix, "")
+ options.EndpointOptions.UseFIPSEndpoint = aws.FIPSEndpointStateEnabled
+ }
+ }
+
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/generated.json b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/generated.json
new file mode 100644
index 000000000000..aa7e6d2e2f45
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/generated.json
@@ -0,0 +1,49 @@
+{
+ "dependencies": {
+ "github.com/aws/aws-sdk-go-v2": "v1.4.0",
+ "github.com/aws/aws-sdk-go-v2/internal/configsources": "v0.0.0-00010101000000-000000000000",
+ "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2": "v2.0.0-00010101000000-000000000000",
+ "github.com/aws/smithy-go": "v1.4.0"
+ },
+ "files": [
+ "api_client.go",
+ "api_op_BatchCheckLayerAvailability.go",
+ "api_op_BatchDeleteImage.go",
+ "api_op_CompleteLayerUpload.go",
+ "api_op_CreateRepository.go",
+ "api_op_DeleteRepository.go",
+ "api_op_DeleteRepositoryPolicy.go",
+ "api_op_DescribeImageTags.go",
+ "api_op_DescribeImages.go",
+ "api_op_DescribeRegistries.go",
+ "api_op_DescribeRepositories.go",
+ "api_op_GetAuthorizationToken.go",
+ "api_op_GetRegistryCatalogData.go",
+ "api_op_GetRepositoryCatalogData.go",
+ "api_op_GetRepositoryPolicy.go",
+ "api_op_InitiateLayerUpload.go",
+ "api_op_ListTagsForResource.go",
+ "api_op_PutImage.go",
+ "api_op_PutRegistryCatalogData.go",
+ "api_op_PutRepositoryCatalogData.go",
+ "api_op_SetRepositoryPolicy.go",
+ "api_op_TagResource.go",
+ "api_op_UntagResource.go",
+ "api_op_UploadLayerPart.go",
+ "deserializers.go",
+ "doc.go",
+ "endpoints.go",
+ "generated.json",
+ "internal/endpoints/endpoints.go",
+ "internal/endpoints/endpoints_test.go",
+ "protocol_test.go",
+ "serializers.go",
+ "types/enums.go",
+ "types/errors.go",
+ "types/types.go",
+ "validators.go"
+ ],
+ "go": "1.15",
+ "module": "github.com/aws/aws-sdk-go-v2/service/ecrpublic",
+ "unstable": false
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go.mod
new file mode 100644
index 000000000000..27ec0af37579
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go.mod
@@ -0,0 +1,16 @@
+module github.com/aws/aws-sdk-go-v2/service/ecrpublic
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3
+ github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0
+ github.com/aws/smithy-go v1.9.1
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../../
+
+replace github.com/aws/aws-sdk-go-v2/internal/configsources => ../../internal/configsources/
+
+replace github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 => ../../internal/endpoints/v2/
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go_module_metadata.go
new file mode 100644
index 000000000000..052e3c9c2ef7
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package ecrpublic
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.10.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/internal/endpoints/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/internal/endpoints/endpoints.go
new file mode 100644
index 000000000000..356bda290289
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/internal/endpoints/endpoints.go
@@ -0,0 +1,250 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package endpoints
+
+import (
+ "github.com/aws/aws-sdk-go-v2/aws"
+ endpoints "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2"
+ "github.com/aws/smithy-go/logging"
+ "regexp"
+)
+
+// Options is the endpoint resolver configuration options
+type Options struct {
+ // Logger is a logging implementation that log events should be sent to.
+ Logger logging.Logger
+
+ // LogDeprecated indicates that deprecated endpoints should be logged to the
+ // provided logger.
+ LogDeprecated bool
+
+ // ResolvedRegion is used to override the region to be resolved, rather then the
+ // using the value passed to the ResolveEndpoint method. This value is used by the
+ // SDK to translate regions like fips-us-east-1 or us-east-1-fips to an alternative
+ // name. You must not set this value directly in your application.
+ ResolvedRegion string
+
+ // DisableHTTPS informs the resolver to return an endpoint that does not use the
+ // HTTPS scheme.
+ DisableHTTPS bool
+
+ // UseDualStackEndpoint specifies the resolver must resolve a dual-stack endpoint.
+ UseDualStackEndpoint aws.DualStackEndpointState
+
+ // UseFIPSEndpoint specifies the resolver must resolve a FIPS endpoint.
+ UseFIPSEndpoint aws.FIPSEndpointState
+}
+
+func (o Options) GetResolvedRegion() string {
+ return o.ResolvedRegion
+}
+
+func (o Options) GetDisableHTTPS() bool {
+ return o.DisableHTTPS
+}
+
+func (o Options) GetUseDualStackEndpoint() aws.DualStackEndpointState {
+ return o.UseDualStackEndpoint
+}
+
+func (o Options) GetUseFIPSEndpoint() aws.FIPSEndpointState {
+ return o.UseFIPSEndpoint
+}
+
+func transformToSharedOptions(options Options) endpoints.Options {
+ return endpoints.Options{
+ Logger: options.Logger,
+ LogDeprecated: options.LogDeprecated,
+ ResolvedRegion: options.ResolvedRegion,
+ DisableHTTPS: options.DisableHTTPS,
+ UseDualStackEndpoint: options.UseDualStackEndpoint,
+ UseFIPSEndpoint: options.UseFIPSEndpoint,
+ }
+}
+
+// Resolver ECR PUBLIC endpoint resolver
+type Resolver struct {
+ partitions endpoints.Partitions
+}
+
+// ResolveEndpoint resolves the service endpoint for the given region and options
+func (r *Resolver) ResolveEndpoint(region string, options Options) (endpoint aws.Endpoint, err error) {
+ if len(region) == 0 {
+ return endpoint, &aws.MissingRegionError{}
+ }
+
+ opt := transformToSharedOptions(options)
+ return r.partitions.ResolveEndpoint(region, opt)
+}
+
+// New returns a new Resolver
+func New() *Resolver {
+ return &Resolver{
+ partitions: defaultPartitions,
+ }
+}
+
+var partitionRegexp = struct {
+ Aws *regexp.Regexp
+ AwsCn *regexp.Regexp
+ AwsIso *regexp.Regexp
+ AwsIsoB *regexp.Regexp
+ AwsUsGov *regexp.Regexp
+}{
+
+ Aws: regexp.MustCompile("^(us|eu|ap|sa|ca|me|af)\\-\\w+\\-\\d+$"),
+ AwsCn: regexp.MustCompile("^cn\\-\\w+\\-\\d+$"),
+ AwsIso: regexp.MustCompile("^us\\-iso\\-\\w+\\-\\d+$"),
+ AwsIsoB: regexp.MustCompile("^us\\-isob\\-\\w+\\-\\d+$"),
+ AwsUsGov: regexp.MustCompile("^us\\-gov\\-\\w+\\-\\d+$"),
+}
+
+var defaultPartitions = endpoints.Partitions{
+ {
+ ID: "aws",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-public.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "api.ecr-public-fips.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-public-fips.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr-public.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.Aws,
+ IsRegionalized: true,
+ },
+ {
+ ID: "aws-cn",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-public.{region}.api.amazonwebservices.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "api.ecr-public-fips.{region}.amazonaws.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-public-fips.{region}.api.amazonwebservices.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr-public.{region}.amazonaws.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsCn,
+ IsRegionalized: true,
+ },
+ {
+ ID: "aws-iso",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "api.ecr-public-fips.{region}.c2s.ic.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr-public.{region}.c2s.ic.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsIso,
+ IsRegionalized: true,
+ },
+ {
+ ID: "aws-iso-b",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "api.ecr-public-fips.{region}.sc2s.sgov.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr-public.{region}.sc2s.sgov.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsIsoB,
+ IsRegionalized: true,
+ },
+ {
+ ID: "aws-us-gov",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-public.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "api.ecr-public-fips.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "api.ecr-public-fips.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "api.ecr-public.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsUsGov,
+ IsRegionalized: true,
+ },
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/serializers.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/serializers.go
new file mode 100644
index 000000000000..4fd9a7dc3142
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/serializers.go
@@ -0,0 +1,1948 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "bytes"
+ "context"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic/types"
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/encoding/httpbinding"
+ smithyjson "github.com/aws/smithy-go/encoding/json"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "path"
+)
+
+type awsAwsjson11_serializeOpBatchCheckLayerAvailability struct {
+}
+
+func (*awsAwsjson11_serializeOpBatchCheckLayerAvailability) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpBatchCheckLayerAvailability) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*BatchCheckLayerAvailabilityInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.BatchCheckLayerAvailability")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentBatchCheckLayerAvailabilityInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpBatchDeleteImage struct {
+}
+
+func (*awsAwsjson11_serializeOpBatchDeleteImage) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpBatchDeleteImage) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*BatchDeleteImageInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.BatchDeleteImage")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentBatchDeleteImageInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpCompleteLayerUpload struct {
+}
+
+func (*awsAwsjson11_serializeOpCompleteLayerUpload) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpCompleteLayerUpload) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*CompleteLayerUploadInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.CompleteLayerUpload")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentCompleteLayerUploadInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpCreateRepository struct {
+}
+
+func (*awsAwsjson11_serializeOpCreateRepository) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpCreateRepository) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*CreateRepositoryInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.CreateRepository")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentCreateRepositoryInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDeleteRepository struct {
+}
+
+func (*awsAwsjson11_serializeOpDeleteRepository) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDeleteRepository) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DeleteRepositoryInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.DeleteRepository")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDeleteRepositoryInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDeleteRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpDeleteRepositoryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDeleteRepositoryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DeleteRepositoryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.DeleteRepositoryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDeleteRepositoryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeImages struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeImages) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeImages) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeImagesInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.DescribeImages")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeImagesInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeImageTags struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeImageTags) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeImageTags) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeImageTagsInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.DescribeImageTags")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeImageTagsInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeRegistries struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeRegistries) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeRegistries) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeRegistriesInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.DescribeRegistries")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeRegistriesInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpDescribeRepositories struct {
+}
+
+func (*awsAwsjson11_serializeOpDescribeRepositories) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpDescribeRepositories) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DescribeRepositoriesInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.DescribeRepositories")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentDescribeRepositoriesInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetAuthorizationToken struct {
+}
+
+func (*awsAwsjson11_serializeOpGetAuthorizationToken) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetAuthorizationToken) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetAuthorizationTokenInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.GetAuthorizationToken")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetAuthorizationTokenInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetRegistryCatalogData struct {
+}
+
+func (*awsAwsjson11_serializeOpGetRegistryCatalogData) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetRegistryCatalogData) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetRegistryCatalogDataInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.GetRegistryCatalogData")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetRegistryCatalogDataInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetRepositoryCatalogData struct {
+}
+
+func (*awsAwsjson11_serializeOpGetRepositoryCatalogData) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetRepositoryCatalogData) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetRepositoryCatalogDataInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.GetRepositoryCatalogData")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetRepositoryCatalogDataInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpGetRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpGetRepositoryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpGetRepositoryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetRepositoryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.GetRepositoryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentGetRepositoryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpInitiateLayerUpload struct {
+}
+
+func (*awsAwsjson11_serializeOpInitiateLayerUpload) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpInitiateLayerUpload) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*InitiateLayerUploadInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.InitiateLayerUpload")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentInitiateLayerUploadInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpListTagsForResource struct {
+}
+
+func (*awsAwsjson11_serializeOpListTagsForResource) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpListTagsForResource) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*ListTagsForResourceInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.ListTagsForResource")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentListTagsForResourceInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutImage struct {
+}
+
+func (*awsAwsjson11_serializeOpPutImage) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutImage) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutImageInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.PutImage")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutImageInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutRegistryCatalogData struct {
+}
+
+func (*awsAwsjson11_serializeOpPutRegistryCatalogData) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutRegistryCatalogData) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutRegistryCatalogDataInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.PutRegistryCatalogData")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutRegistryCatalogDataInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpPutRepositoryCatalogData struct {
+}
+
+func (*awsAwsjson11_serializeOpPutRepositoryCatalogData) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpPutRepositoryCatalogData) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*PutRepositoryCatalogDataInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.PutRepositoryCatalogData")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentPutRepositoryCatalogDataInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpSetRepositoryPolicy struct {
+}
+
+func (*awsAwsjson11_serializeOpSetRepositoryPolicy) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpSetRepositoryPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*SetRepositoryPolicyInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.SetRepositoryPolicy")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentSetRepositoryPolicyInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpTagResource struct {
+}
+
+func (*awsAwsjson11_serializeOpTagResource) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpTagResource) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*TagResourceInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.TagResource")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentTagResourceInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpUntagResource struct {
+}
+
+func (*awsAwsjson11_serializeOpUntagResource) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpUntagResource) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*UntagResourceInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.UntagResource")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentUntagResourceInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsjson11_serializeOpUploadLayerPart struct {
+}
+
+func (*awsAwsjson11_serializeOpUploadLayerPart) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsjson11_serializeOpUploadLayerPart) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*UploadLayerPartInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1")
+ httpBindingEncoder.SetHeader("X-Amz-Target").String("SpencerFrontendService.UploadLayerPart")
+
+ jsonEncoder := smithyjson.NewEncoder()
+ if err := awsAwsjson11_serializeOpDocumentUploadLayerPartInput(input, jsonEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+func awsAwsjson11_serializeDocumentArchitectureList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentBatchedOperationLayerDigestList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentImageIdentifier(v *types.ImageIdentifier, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageDigest != nil {
+ ok := object.Key("imageDigest")
+ ok.String(*v.ImageDigest)
+ }
+
+ if v.ImageTag != nil {
+ ok := object.Key("imageTag")
+ ok.String(*v.ImageTag)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentImageIdentifierList(v []types.ImageIdentifier, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentImageIdentifier(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentLayerDigestList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentOperatingSystemList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentRepositoryCatalogDataInput(v *types.RepositoryCatalogDataInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.AboutText != nil {
+ ok := object.Key("aboutText")
+ ok.String(*v.AboutText)
+ }
+
+ if v.Architectures != nil {
+ ok := object.Key("architectures")
+ if err := awsAwsjson11_serializeDocumentArchitectureList(v.Architectures, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.Description != nil {
+ ok := object.Key("description")
+ ok.String(*v.Description)
+ }
+
+ if v.LogoImageBlob != nil {
+ ok := object.Key("logoImageBlob")
+ ok.Base64EncodeBytes(v.LogoImageBlob)
+ }
+
+ if v.OperatingSystems != nil {
+ ok := object.Key("operatingSystems")
+ if err := awsAwsjson11_serializeDocumentOperatingSystemList(v.OperatingSystems, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.UsageText != nil {
+ ok := object.Key("usageText")
+ ok.String(*v.UsageText)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentRepositoryNameList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentTag(v *types.Tag, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Key != nil {
+ ok := object.Key("Key")
+ ok.String(*v.Key)
+ }
+
+ if v.Value != nil {
+ ok := object.Key("Value")
+ ok.String(*v.Value)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentTagKeyList(v []string, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeDocumentTagList(v []types.Tag, value smithyjson.Value) error {
+ array := value.Array()
+ defer array.Close()
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsjson11_serializeDocumentTag(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentBatchCheckLayerAvailabilityInput(v *BatchCheckLayerAvailabilityInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LayerDigests != nil {
+ ok := object.Key("layerDigests")
+ if err := awsAwsjson11_serializeDocumentBatchedOperationLayerDigestList(v.LayerDigests, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentBatchDeleteImageInput(v *BatchDeleteImageInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageIds != nil {
+ ok := object.Key("imageIds")
+ if err := awsAwsjson11_serializeDocumentImageIdentifierList(v.ImageIds, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentCompleteLayerUploadInput(v *CompleteLayerUploadInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LayerDigests != nil {
+ ok := object.Key("layerDigests")
+ if err := awsAwsjson11_serializeDocumentLayerDigestList(v.LayerDigests, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ if v.UploadId != nil {
+ ok := object.Key("uploadId")
+ ok.String(*v.UploadId)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentCreateRepositoryInput(v *CreateRepositoryInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.CatalogData != nil {
+ ok := object.Key("catalogData")
+ if err := awsAwsjson11_serializeDocumentRepositoryCatalogDataInput(v.CatalogData, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ if v.Tags != nil {
+ ok := object.Key("tags")
+ if err := awsAwsjson11_serializeDocumentTagList(v.Tags, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDeleteRepositoryInput(v *DeleteRepositoryInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Force {
+ ok := object.Key("force")
+ ok.Boolean(v.Force)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDeleteRepositoryPolicyInput(v *DeleteRepositoryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeImagesInput(v *DescribeImagesInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageIds != nil {
+ ok := object.Key("imageIds")
+ if err := awsAwsjson11_serializeDocumentImageIdentifierList(v.ImageIds, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeImageTagsInput(v *DescribeImageTagsInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeRegistriesInput(v *DescribeRegistriesInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentDescribeRepositoriesInput(v *DescribeRepositoriesInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.MaxResults != nil {
+ ok := object.Key("maxResults")
+ ok.Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ ok := object.Key("nextToken")
+ ok.String(*v.NextToken)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryNames != nil {
+ ok := object.Key("repositoryNames")
+ if err := awsAwsjson11_serializeDocumentRepositoryNameList(v.RepositoryNames, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetAuthorizationTokenInput(v *GetAuthorizationTokenInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetRegistryCatalogDataInput(v *GetRegistryCatalogDataInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetRepositoryCatalogDataInput(v *GetRepositoryCatalogDataInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentGetRepositoryPolicyInput(v *GetRepositoryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentInitiateLayerUploadInput(v *InitiateLayerUploadInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentListTagsForResourceInput(v *ListTagsForResourceInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ResourceArn != nil {
+ ok := object.Key("resourceArn")
+ ok.String(*v.ResourceArn)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutImageInput(v *PutImageInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ImageDigest != nil {
+ ok := object.Key("imageDigest")
+ ok.String(*v.ImageDigest)
+ }
+
+ if v.ImageManifest != nil {
+ ok := object.Key("imageManifest")
+ ok.String(*v.ImageManifest)
+ }
+
+ if v.ImageManifestMediaType != nil {
+ ok := object.Key("imageManifestMediaType")
+ ok.String(*v.ImageManifestMediaType)
+ }
+
+ if v.ImageTag != nil {
+ ok := object.Key("imageTag")
+ ok.String(*v.ImageTag)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutRegistryCatalogDataInput(v *PutRegistryCatalogDataInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.DisplayName != nil {
+ ok := object.Key("displayName")
+ ok.String(*v.DisplayName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentPutRepositoryCatalogDataInput(v *PutRepositoryCatalogDataInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.CatalogData != nil {
+ ok := object.Key("catalogData")
+ if err := awsAwsjson11_serializeDocumentRepositoryCatalogDataInput(v.CatalogData, ok); err != nil {
+ return err
+ }
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentSetRepositoryPolicyInput(v *SetRepositoryPolicyInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.Force {
+ ok := object.Key("force")
+ ok.Boolean(v.Force)
+ }
+
+ if v.PolicyText != nil {
+ ok := object.Key("policyText")
+ ok.String(*v.PolicyText)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentTagResourceInput(v *TagResourceInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ResourceArn != nil {
+ ok := object.Key("resourceArn")
+ ok.String(*v.ResourceArn)
+ }
+
+ if v.Tags != nil {
+ ok := object.Key("tags")
+ if err := awsAwsjson11_serializeDocumentTagList(v.Tags, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentUntagResourceInput(v *UntagResourceInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.ResourceArn != nil {
+ ok := object.Key("resourceArn")
+ ok.String(*v.ResourceArn)
+ }
+
+ if v.TagKeys != nil {
+ ok := object.Key("tagKeys")
+ if err := awsAwsjson11_serializeDocumentTagKeyList(v.TagKeys, ok); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsjson11_serializeOpDocumentUploadLayerPartInput(v *UploadLayerPartInput, value smithyjson.Value) error {
+ object := value.Object()
+ defer object.Close()
+
+ if v.LayerPartBlob != nil {
+ ok := object.Key("layerPartBlob")
+ ok.Base64EncodeBytes(v.LayerPartBlob)
+ }
+
+ if v.PartFirstByte != nil {
+ ok := object.Key("partFirstByte")
+ ok.Long(*v.PartFirstByte)
+ }
+
+ if v.PartLastByte != nil {
+ ok := object.Key("partLastByte")
+ ok.Long(*v.PartLastByte)
+ }
+
+ if v.RegistryId != nil {
+ ok := object.Key("registryId")
+ ok.String(*v.RegistryId)
+ }
+
+ if v.RepositoryName != nil {
+ ok := object.Key("repositoryName")
+ ok.String(*v.RepositoryName)
+ }
+
+ if v.UploadId != nil {
+ ok := object.Key("uploadId")
+ ok.String(*v.UploadId)
+ }
+
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/enums.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/enums.go
new file mode 100644
index 000000000000..d80a0524475b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/enums.go
@@ -0,0 +1,87 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+type ImageFailureCode string
+
+// Enum values for ImageFailureCode
+const (
+ ImageFailureCodeInvalidImageDigest ImageFailureCode = "InvalidImageDigest"
+ ImageFailureCodeInvalidImageTag ImageFailureCode = "InvalidImageTag"
+ ImageFailureCodeImageTagDoesNotMatchDigest ImageFailureCode = "ImageTagDoesNotMatchDigest"
+ ImageFailureCodeImageNotFound ImageFailureCode = "ImageNotFound"
+ ImageFailureCodeMissingDigestAndTag ImageFailureCode = "MissingDigestAndTag"
+ ImageFailureCodeImageReferencedByManifestList ImageFailureCode = "ImageReferencedByManifestList"
+ ImageFailureCodeKmsError ImageFailureCode = "KmsError"
+)
+
+// Values returns all known values for ImageFailureCode. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (ImageFailureCode) Values() []ImageFailureCode {
+ return []ImageFailureCode{
+ "InvalidImageDigest",
+ "InvalidImageTag",
+ "ImageTagDoesNotMatchDigest",
+ "ImageNotFound",
+ "MissingDigestAndTag",
+ "ImageReferencedByManifestList",
+ "KmsError",
+ }
+}
+
+type LayerAvailability string
+
+// Enum values for LayerAvailability
+const (
+ LayerAvailabilityAvailable LayerAvailability = "AVAILABLE"
+ LayerAvailabilityUnavailable LayerAvailability = "UNAVAILABLE"
+)
+
+// Values returns all known values for LayerAvailability. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (LayerAvailability) Values() []LayerAvailability {
+ return []LayerAvailability{
+ "AVAILABLE",
+ "UNAVAILABLE",
+ }
+}
+
+type LayerFailureCode string
+
+// Enum values for LayerFailureCode
+const (
+ LayerFailureCodeInvalidLayerDigest LayerFailureCode = "InvalidLayerDigest"
+ LayerFailureCodeMissingLayerDigest LayerFailureCode = "MissingLayerDigest"
+)
+
+// Values returns all known values for LayerFailureCode. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (LayerFailureCode) Values() []LayerFailureCode {
+ return []LayerFailureCode{
+ "InvalidLayerDigest",
+ "MissingLayerDigest",
+ }
+}
+
+type RegistryAliasStatus string
+
+// Enum values for RegistryAliasStatus
+const (
+ RegistryAliasStatusActive RegistryAliasStatus = "ACTIVE"
+ RegistryAliasStatusPending RegistryAliasStatus = "PENDING"
+ RegistryAliasStatusRejected RegistryAliasStatus = "REJECTED"
+)
+
+// Values returns all known values for RegistryAliasStatus. Note that this can be
+// expanded in the future, and so it is only as up to date as the client. The
+// ordering of this slice is not guaranteed to be stable across updates.
+func (RegistryAliasStatus) Values() []RegistryAliasStatus {
+ return []RegistryAliasStatus{
+ "ACTIVE",
+ "PENDING",
+ "REJECTED",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/errors.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/errors.go
new file mode 100644
index 000000000000..485ac0c1df23
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/errors.go
@@ -0,0 +1,476 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+import (
+ "fmt"
+ smithy "github.com/aws/smithy-go"
+)
+
+// The specified layer upload does not contain any layer parts.
+type EmptyUploadException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *EmptyUploadException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *EmptyUploadException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *EmptyUploadException) ErrorCode() string { return "EmptyUploadException" }
+func (e *EmptyUploadException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified image has already been pushed, and there were no changes to the
+// manifest or image tag after the last push.
+type ImageAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ImageAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ImageAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ImageAlreadyExistsException) ErrorCode() string { return "ImageAlreadyExistsException" }
+func (e *ImageAlreadyExistsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified image digest does not match the digest that Amazon ECR calculated
+// for the image.
+type ImageDigestDoesNotMatchException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ImageDigestDoesNotMatchException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ImageDigestDoesNotMatchException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ImageDigestDoesNotMatchException) ErrorCode() string {
+ return "ImageDigestDoesNotMatchException"
+}
+func (e *ImageDigestDoesNotMatchException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The image requested does not exist in the specified repository.
+type ImageNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ImageNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ImageNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ImageNotFoundException) ErrorCode() string { return "ImageNotFoundException" }
+func (e *ImageNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified image is tagged with a tag that already exists. The repository is
+// configured for tag immutability.
+type ImageTagAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ImageTagAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ImageTagAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ImageTagAlreadyExistsException) ErrorCode() string { return "ImageTagAlreadyExistsException" }
+func (e *ImageTagAlreadyExistsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The layer digest calculation performed by Amazon ECR upon receipt of the image
+// layer does not match the digest specified.
+type InvalidLayerException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidLayerException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidLayerException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidLayerException) ErrorCode() string { return "InvalidLayerException" }
+func (e *InvalidLayerException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The layer part size is not valid, or the first byte specified is not consecutive
+// to the last byte of a previous layer part upload.
+type InvalidLayerPartException struct {
+ Message *string
+
+ RegistryId *string
+ RepositoryName *string
+ UploadId *string
+ LastValidByteReceived *int64
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidLayerPartException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidLayerPartException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidLayerPartException) ErrorCode() string { return "InvalidLayerPartException" }
+func (e *InvalidLayerPartException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified parameter is invalid. Review the available parameters for the API
+// request.
+type InvalidParameterException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidParameterException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidParameterException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidParameterException) ErrorCode() string { return "InvalidParameterException" }
+func (e *InvalidParameterException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// An invalid parameter has been specified. Tag keys can have a maximum character
+// length of 128 characters, and tag values can have a maximum length of 256
+// characters.
+type InvalidTagParameterException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidTagParameterException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidTagParameterException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidTagParameterException) ErrorCode() string { return "InvalidTagParameterException" }
+func (e *InvalidTagParameterException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The image layer already exists in the associated repository.
+type LayerAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LayerAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LayerAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LayerAlreadyExistsException) ErrorCode() string { return "LayerAlreadyExistsException" }
+func (e *LayerAlreadyExistsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// Layer parts must be at least 5 MiB in size.
+type LayerPartTooSmallException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LayerPartTooSmallException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LayerPartTooSmallException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LayerPartTooSmallException) ErrorCode() string { return "LayerPartTooSmallException" }
+func (e *LayerPartTooSmallException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified layers could not be found, or the specified layer is not valid for
+// this repository.
+type LayersNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LayersNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LayersNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LayersNotFoundException) ErrorCode() string { return "LayersNotFoundException" }
+func (e *LayersNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The operation did not succeed because it would have exceeded a service limit for
+// your account. For more information, see Amazon ECR Service Quotas
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html) in
+// the Amazon Elastic Container Registry User Guide.
+type LimitExceededException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *LimitExceededException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *LimitExceededException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *LimitExceededException) ErrorCode() string { return "LimitExceededException" }
+func (e *LimitExceededException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The manifest list is referencing an image that does not exist.
+type ReferencedImagesNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ReferencedImagesNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ReferencedImagesNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ReferencedImagesNotFoundException) ErrorCode() string {
+ return "ReferencedImagesNotFoundException"
+}
+func (e *ReferencedImagesNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The registry does not exist.
+type RegistryNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RegistryNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RegistryNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RegistryNotFoundException) ErrorCode() string { return "RegistryNotFoundException" }
+func (e *RegistryNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified repository already exists in the specified registry.
+type RepositoryAlreadyExistsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RepositoryAlreadyExistsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RepositoryAlreadyExistsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RepositoryAlreadyExistsException) ErrorCode() string {
+ return "RepositoryAlreadyExistsException"
+}
+func (e *RepositoryAlreadyExistsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified repository contains images. To delete a repository that contains
+// images, you must force the deletion with the force parameter.
+type RepositoryNotEmptyException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RepositoryNotEmptyException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RepositoryNotEmptyException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RepositoryNotEmptyException) ErrorCode() string { return "RepositoryNotEmptyException" }
+func (e *RepositoryNotEmptyException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified repository could not be found. Check the spelling of the specified
+// repository and ensure that you are performing operations on the correct
+// registry.
+type RepositoryNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RepositoryNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RepositoryNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RepositoryNotFoundException) ErrorCode() string { return "RepositoryNotFoundException" }
+func (e *RepositoryNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified repository and registry combination does not have an associated
+// repository policy.
+type RepositoryPolicyNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RepositoryPolicyNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RepositoryPolicyNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RepositoryPolicyNotFoundException) ErrorCode() string {
+ return "RepositoryPolicyNotFoundException"
+}
+func (e *RepositoryPolicyNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// These errors are usually caused by a server-side issue.
+type ServerException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ServerException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ServerException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ServerException) ErrorCode() string { return "ServerException" }
+func (e *ServerException) ErrorFault() smithy.ErrorFault { return smithy.FaultServer }
+
+// The list of tags on the repository is over the limit. The maximum number of tags
+// that can be applied to a repository is 50.
+type TooManyTagsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *TooManyTagsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *TooManyTagsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *TooManyTagsException) ErrorCode() string { return "TooManyTagsException" }
+func (e *TooManyTagsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The action is not supported in this Region.
+type UnsupportedCommandException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *UnsupportedCommandException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *UnsupportedCommandException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *UnsupportedCommandException) ErrorCode() string { return "UnsupportedCommandException" }
+func (e *UnsupportedCommandException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The upload could not be found, or the specified upload ID is not valid for this
+// repository.
+type UploadNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *UploadNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *UploadNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *UploadNotFoundException) ErrorCode() string { return "UploadNotFoundException" }
+func (e *UploadNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/types.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/types.go
new file mode 100644
index 000000000000..731ea603df3a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/types/types.go
@@ -0,0 +1,405 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+import (
+ smithydocument "github.com/aws/smithy-go/document"
+ "time"
+)
+
+// An authorization token data object that corresponds to a public registry.
+type AuthorizationData struct {
+
+ // A base64-encoded string that contains authorization data for a public Amazon ECR
+ // registry. When the string is decoded, it is presented in the format
+ // user:password for public registry authentication using docker login.
+ AuthorizationToken *string
+
+ // The Unix time in seconds and milliseconds when the authorization token expires.
+ // Authorization tokens are valid for 12 hours.
+ ExpiresAt *time.Time
+
+ noSmithyDocumentSerde
+}
+
+// An object representing an Amazon ECR image.
+type Image struct {
+
+ // An object containing the image tag and image digest associated with an image.
+ ImageId *ImageIdentifier
+
+ // The image manifest associated with the image.
+ ImageManifest *string
+
+ // The manifest media type of the image.
+ ImageManifestMediaType *string
+
+ // The AWS account ID associated with the registry containing the image.
+ RegistryId *string
+
+ // The name of the repository associated with the image.
+ RepositoryName *string
+
+ noSmithyDocumentSerde
+}
+
+// An object that describes an image returned by a DescribeImages operation.
+type ImageDetail struct {
+
+ // The artifact media type of the image.
+ ArtifactMediaType *string
+
+ // The sha256 digest of the image manifest.
+ ImageDigest *string
+
+ // The media type of the image manifest.
+ ImageManifestMediaType *string
+
+ // The date and time, expressed in standard JavaScript date format, at which the
+ // current image was pushed to the repository.
+ ImagePushedAt *time.Time
+
+ // The size, in bytes, of the image in the repository. If the image is a manifest
+ // list, this will be the max size of all manifests in the list. Beginning with
+ // Docker version 1.9, the Docker client compresses image layers before pushing
+ // them to a V2 Docker registry. The output of the docker images command shows the
+ // uncompressed image size, so it may return a larger image size than the image
+ // sizes returned by DescribeImages.
+ ImageSizeInBytes *int64
+
+ // The list of tags associated with this image.
+ ImageTags []string
+
+ // The AWS account ID associated with the public registry to which this image
+ // belongs.
+ RegistryId *string
+
+ // The name of the repository to which this image belongs.
+ RepositoryName *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing an Amazon ECR image failure.
+type ImageFailure struct {
+
+ // The code associated with the failure.
+ FailureCode ImageFailureCode
+
+ // The reason for the failure.
+ FailureReason *string
+
+ // The image ID associated with the failure.
+ ImageId *ImageIdentifier
+
+ noSmithyDocumentSerde
+}
+
+// An object with identifying information for an Amazon ECR image.
+type ImageIdentifier struct {
+
+ // The sha256 digest of the image manifest.
+ ImageDigest *string
+
+ // The tag used for the image.
+ ImageTag *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing the image tag details for an image.
+type ImageTagDetail struct {
+
+ // The time stamp indicating when the image tag was created.
+ CreatedAt *time.Time
+
+ // An object that describes the details of an image.
+ ImageDetail *ReferencedImageDetail
+
+ // The tag associated with the image.
+ ImageTag *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing an Amazon ECR image layer.
+type Layer struct {
+
+ // The availability status of the image layer.
+ LayerAvailability LayerAvailability
+
+ // The sha256 digest of the image layer.
+ LayerDigest *string
+
+ // The size, in bytes, of the image layer.
+ LayerSize *int64
+
+ // The media type of the layer, such as
+ // application/vnd.docker.image.rootfs.diff.tar.gzip or
+ // application/vnd.oci.image.layer.v1.tar+gzip.
+ MediaType *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing an Amazon ECR image layer failure.
+type LayerFailure struct {
+
+ // The failure code associated with the failure.
+ FailureCode LayerFailureCode
+
+ // The reason for the failure.
+ FailureReason *string
+
+ // The layer digest associated with the failure.
+ LayerDigest *string
+
+ noSmithyDocumentSerde
+}
+
+// An object that describes the image tag details returned by a DescribeImageTags
+// action.
+type ReferencedImageDetail struct {
+
+ // The artifact media type of the image.
+ ArtifactMediaType *string
+
+ // The sha256 digest of the image manifest.
+ ImageDigest *string
+
+ // The media type of the image manifest.
+ ImageManifestMediaType *string
+
+ // The date and time, expressed in standard JavaScript date format, at which the
+ // current image tag was pushed to the repository.
+ ImagePushedAt *time.Time
+
+ // The size, in bytes, of the image in the repository. If the image is a manifest
+ // list, this will be the max size of all manifests in the list. Beginning with
+ // Docker version 1.9, the Docker client compresses image layers before pushing
+ // them to a V2 Docker registry. The output of the docker images command shows the
+ // uncompressed image size, so it may return a larger image size than the image
+ // sizes returned by DescribeImages.
+ ImageSizeInBytes *int64
+
+ noSmithyDocumentSerde
+}
+
+// The details of a public registry.
+type Registry struct {
+
+ // An array of objects representing the aliases for a public registry.
+ //
+ // This member is required.
+ Aliases []RegistryAlias
+
+ // The Amazon Resource Name (ARN) of the public registry.
+ //
+ // This member is required.
+ RegistryArn *string
+
+ // The AWS account ID associated with the registry. If you do not specify a
+ // registry, the default public registry is assumed.
+ //
+ // This member is required.
+ RegistryId *string
+
+ // The URI of a public registry. The URI contains a universal prefix and the
+ // registry alias.
+ //
+ // This member is required.
+ RegistryUri *string
+
+ // Whether the account is verified. This indicates whether the account is an AWS
+ // Marketplace vendor. If an account is verified, each public repository will
+ // received a verified account badge on the Amazon ECR Public Gallery.
+ //
+ // This member is required.
+ Verified *bool
+
+ noSmithyDocumentSerde
+}
+
+// An object representing the aliases for a public registry. A public registry is
+// given an alias upon creation but a custom alias can be set using the Amazon ECR
+// console. For more information, see Registries
+// (https://docs.aws.amazon.com/AmazonECR/latest/userguide/Registries.html) in the
+// Amazon Elastic Container Registry User Guide.
+type RegistryAlias struct {
+
+ // Whether or not the registry alias is the default alias for the registry. When
+ // the first public repository is created, your public registry is assigned a
+ // default registry alias.
+ //
+ // This member is required.
+ DefaultRegistryAlias bool
+
+ // The name of the registry alias.
+ //
+ // This member is required.
+ Name *string
+
+ // Whether or not the registry alias is the primary alias for the registry. If
+ // true, the alias is the primary registry alias and is displayed in both the
+ // repository URL and the image URI used in the docker pull commands on the Amazon
+ // ECR Public Gallery. A registry alias that is not the primary registry alias can
+ // be used in the repository URI in a docker pull command.
+ //
+ // This member is required.
+ PrimaryRegistryAlias bool
+
+ // The status of the registry alias.
+ //
+ // This member is required.
+ Status RegistryAliasStatus
+
+ noSmithyDocumentSerde
+}
+
+// The metadata for a public registry.
+type RegistryCatalogData struct {
+
+ // The display name for a public registry. This appears on the Amazon ECR Public
+ // Gallery. Only accounts that have the verified account badge can have a registry
+ // display name.
+ DisplayName *string
+
+ noSmithyDocumentSerde
+}
+
+// An object representing a repository.
+type Repository struct {
+
+ // The date and time, in JavaScript date format, when the repository was created.
+ CreatedAt *time.Time
+
+ // The AWS account ID associated with the public registry that contains the
+ // repository.
+ RegistryId *string
+
+ // The Amazon Resource Name (ARN) that identifies the repository. The ARN contains
+ // the arn:aws:ecr namespace, followed by the region of the repository, AWS account
+ // ID of the repository owner, repository namespace, and repository name. For
+ // example, arn:aws:ecr:region:012345678910:repository/test.
+ RepositoryArn *string
+
+ // The name of the repository.
+ RepositoryName *string
+
+ // The URI for the repository. You can use this URI for container image push and
+ // pull operations.
+ RepositoryUri *string
+
+ noSmithyDocumentSerde
+}
+
+// The catalog data for a repository. This data is publicly visible in the Amazon
+// ECR Public Gallery.
+type RepositoryCatalogData struct {
+
+ // The longform description of the contents of the repository. This text appears in
+ // the repository details on the Amazon ECR Public Gallery.
+ AboutText *string
+
+ // The architecture tags that are associated with the repository. Only supported
+ // operating system tags appear publicly in the Amazon ECR Public Gallery. For more
+ // information, see RepositoryCatalogDataInput.
+ Architectures []string
+
+ // The short description of the repository.
+ Description *string
+
+ // The URL containing the logo associated with the repository.
+ LogoUrl *string
+
+ // Whether or not the repository is certified by AWS Marketplace.
+ MarketplaceCertified *bool
+
+ // The operating system tags that are associated with the repository. Only
+ // supported operating system tags appear publicly in the Amazon ECR Public
+ // Gallery. For more information, see RepositoryCatalogDataInput.
+ OperatingSystems []string
+
+ // The longform usage details of the contents of the repository. The usage text
+ // provides context for users of the repository.
+ UsageText *string
+
+ noSmithyDocumentSerde
+}
+
+// An object containing the catalog data for a repository. This data is publicly
+// visible in the Amazon ECR Public Gallery.
+type RepositoryCatalogDataInput struct {
+
+ // A detailed description of the contents of the repository. It is publicly visible
+ // in the Amazon ECR Public Gallery. The text must be in markdown format.
+ AboutText *string
+
+ // The system architecture that the images in the repository are compatible with.
+ // On the Amazon ECR Public Gallery, the following supported architectures will
+ // appear as badges on the repository and are used as search filters.
+ //
+ // * Linux
+ //
+ // *
+ // Windows
+ //
+ // If an unsupported tag is added to your repository catalog data, it will
+ // be associated with the repository and can be retrieved using the API but will
+ // not be discoverable in the Amazon ECR Public Gallery.
+ Architectures []string
+
+ // A short description of the contents of the repository. This text appears in both
+ // the image details and also when searching for repositories on the Amazon ECR
+ // Public Gallery.
+ Description *string
+
+ // The base64-encoded repository logo payload. The repository logo is only publicly
+ // visible in the Amazon ECR Public Gallery for verified accounts.
+ LogoImageBlob []byte
+
+ // The operating systems that the images in the repository are compatible with. On
+ // the Amazon ECR Public Gallery, the following supported operating systems will
+ // appear as badges on the repository and are used as search filters.
+ //
+ // * ARM
+ //
+ // * ARM
+ // 64
+ //
+ // * x86
+ //
+ // * x86-64
+ //
+ // If an unsupported tag is added to your repository catalog
+ // data, it will be associated with the repository and can be retrieved using the
+ // API but will not be discoverable in the Amazon ECR Public Gallery.
+ OperatingSystems []string
+
+ // Detailed information on how to use the contents of the repository. It is
+ // publicly visible in the Amazon ECR Public Gallery. The usage text provides
+ // context, support information, and additional usage details for users of the
+ // repository. The text must be in markdown format.
+ UsageText *string
+
+ noSmithyDocumentSerde
+}
+
+// The metadata that you apply to a resource to help you categorize and organize
+// them. Each tag consists of a key and an optional value, both of which you
+// define. Tag keys can have a maximum character length of 128 characters, and tag
+// values can have a maximum length of 256 characters.
+type Tag struct {
+
+ // One part of a key-value pair that make up a tag. A key is a general label that
+ // acts like a category for more specific tag values.
+ Key *string
+
+ // The optional part of a key-value pair that make up a tag. A value acts as a
+ // descriptor within a tag category (key).
+ Value *string
+
+ noSmithyDocumentSerde
+}
+
+type noSmithyDocumentSerde = smithydocument.NoSerde
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/validators.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/validators.go
new file mode 100644
index 000000000000..76d60ad712bb
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ecrpublic/validators.go
@@ -0,0 +1,751 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package ecrpublic
+
+import (
+ "context"
+ "fmt"
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/middleware"
+)
+
+type validateOpBatchCheckLayerAvailability struct {
+}
+
+func (*validateOpBatchCheckLayerAvailability) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpBatchCheckLayerAvailability) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*BatchCheckLayerAvailabilityInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpBatchCheckLayerAvailabilityInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpBatchDeleteImage struct {
+}
+
+func (*validateOpBatchDeleteImage) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpBatchDeleteImage) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*BatchDeleteImageInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpBatchDeleteImageInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpCompleteLayerUpload struct {
+}
+
+func (*validateOpCompleteLayerUpload) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpCompleteLayerUpload) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*CompleteLayerUploadInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpCompleteLayerUploadInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpCreateRepository struct {
+}
+
+func (*validateOpCreateRepository) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpCreateRepository) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*CreateRepositoryInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpCreateRepositoryInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDeleteRepository struct {
+}
+
+func (*validateOpDeleteRepository) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDeleteRepository) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DeleteRepositoryInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDeleteRepositoryInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDeleteRepositoryPolicy struct {
+}
+
+func (*validateOpDeleteRepositoryPolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDeleteRepositoryPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DeleteRepositoryPolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDeleteRepositoryPolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDescribeImages struct {
+}
+
+func (*validateOpDescribeImages) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDescribeImages) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DescribeImagesInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDescribeImagesInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDescribeImageTags struct {
+}
+
+func (*validateOpDescribeImageTags) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDescribeImageTags) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DescribeImageTagsInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDescribeImageTagsInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpGetRepositoryCatalogData struct {
+}
+
+func (*validateOpGetRepositoryCatalogData) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetRepositoryCatalogData) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetRepositoryCatalogDataInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetRepositoryCatalogDataInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpGetRepositoryPolicy struct {
+}
+
+func (*validateOpGetRepositoryPolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetRepositoryPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetRepositoryPolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetRepositoryPolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpInitiateLayerUpload struct {
+}
+
+func (*validateOpInitiateLayerUpload) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpInitiateLayerUpload) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*InitiateLayerUploadInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpInitiateLayerUploadInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpListTagsForResource struct {
+}
+
+func (*validateOpListTagsForResource) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpListTagsForResource) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*ListTagsForResourceInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpListTagsForResourceInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutImage struct {
+}
+
+func (*validateOpPutImage) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutImage) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutImageInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutImageInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpPutRepositoryCatalogData struct {
+}
+
+func (*validateOpPutRepositoryCatalogData) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpPutRepositoryCatalogData) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*PutRepositoryCatalogDataInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpPutRepositoryCatalogDataInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpSetRepositoryPolicy struct {
+}
+
+func (*validateOpSetRepositoryPolicy) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpSetRepositoryPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*SetRepositoryPolicyInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpSetRepositoryPolicyInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpTagResource struct {
+}
+
+func (*validateOpTagResource) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpTagResource) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*TagResourceInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpTagResourceInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpUntagResource struct {
+}
+
+func (*validateOpUntagResource) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpUntagResource) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*UntagResourceInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpUntagResourceInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpUploadLayerPart struct {
+}
+
+func (*validateOpUploadLayerPart) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpUploadLayerPart) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*UploadLayerPartInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpUploadLayerPartInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+func addOpBatchCheckLayerAvailabilityValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpBatchCheckLayerAvailability{}, middleware.After)
+}
+
+func addOpBatchDeleteImageValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpBatchDeleteImage{}, middleware.After)
+}
+
+func addOpCompleteLayerUploadValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpCompleteLayerUpload{}, middleware.After)
+}
+
+func addOpCreateRepositoryValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpCreateRepository{}, middleware.After)
+}
+
+func addOpDeleteRepositoryValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDeleteRepository{}, middleware.After)
+}
+
+func addOpDeleteRepositoryPolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDeleteRepositoryPolicy{}, middleware.After)
+}
+
+func addOpDescribeImagesValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDescribeImages{}, middleware.After)
+}
+
+func addOpDescribeImageTagsValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDescribeImageTags{}, middleware.After)
+}
+
+func addOpGetRepositoryCatalogDataValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetRepositoryCatalogData{}, middleware.After)
+}
+
+func addOpGetRepositoryPolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetRepositoryPolicy{}, middleware.After)
+}
+
+func addOpInitiateLayerUploadValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpInitiateLayerUpload{}, middleware.After)
+}
+
+func addOpListTagsForResourceValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpListTagsForResource{}, middleware.After)
+}
+
+func addOpPutImageValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutImage{}, middleware.After)
+}
+
+func addOpPutRepositoryCatalogDataValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpPutRepositoryCatalogData{}, middleware.After)
+}
+
+func addOpSetRepositoryPolicyValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpSetRepositoryPolicy{}, middleware.After)
+}
+
+func addOpTagResourceValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpTagResource{}, middleware.After)
+}
+
+func addOpUntagResourceValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpUntagResource{}, middleware.After)
+}
+
+func addOpUploadLayerPartValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpUploadLayerPart{}, middleware.After)
+}
+
+func validateOpBatchCheckLayerAvailabilityInput(v *BatchCheckLayerAvailabilityInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "BatchCheckLayerAvailabilityInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.LayerDigests == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("LayerDigests"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpBatchDeleteImageInput(v *BatchDeleteImageInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "BatchDeleteImageInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageIds == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageIds"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpCompleteLayerUploadInput(v *CompleteLayerUploadInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "CompleteLayerUploadInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.UploadId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("UploadId"))
+ }
+ if v.LayerDigests == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("LayerDigests"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpCreateRepositoryInput(v *CreateRepositoryInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "CreateRepositoryInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDeleteRepositoryInput(v *DeleteRepositoryInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DeleteRepositoryInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDeleteRepositoryPolicyInput(v *DeleteRepositoryPolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DeleteRepositoryPolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDescribeImagesInput(v *DescribeImagesInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DescribeImagesInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDescribeImageTagsInput(v *DescribeImageTagsInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DescribeImageTagsInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpGetRepositoryCatalogDataInput(v *GetRepositoryCatalogDataInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetRepositoryCatalogDataInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpGetRepositoryPolicyInput(v *GetRepositoryPolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetRepositoryPolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpInitiateLayerUploadInput(v *InitiateLayerUploadInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "InitiateLayerUploadInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpListTagsForResourceInput(v *ListTagsForResourceInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ListTagsForResourceInput"}
+ if v.ResourceArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ResourceArn"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutImageInput(v *PutImageInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutImageInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.ImageManifest == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ImageManifest"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpPutRepositoryCatalogDataInput(v *PutRepositoryCatalogDataInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "PutRepositoryCatalogDataInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.CatalogData == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("CatalogData"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpSetRepositoryPolicyInput(v *SetRepositoryPolicyInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "SetRepositoryPolicyInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.PolicyText == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("PolicyText"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpTagResourceInput(v *TagResourceInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "TagResourceInput"}
+ if v.ResourceArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ResourceArn"))
+ }
+ if v.Tags == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Tags"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpUntagResourceInput(v *UntagResourceInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "UntagResourceInput"}
+ if v.ResourceArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("ResourceArn"))
+ }
+ if v.TagKeys == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("TagKeys"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpUploadLayerPartInput(v *UploadLayerPartInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "UploadLayerPartInput"}
+ if v.RepositoryName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RepositoryName"))
+ }
+ if v.UploadId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("UploadId"))
+ }
+ if v.PartFirstByte == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("PartFirstByte"))
+ }
+ if v.PartLastByte == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("PartLastByte"))
+ }
+ if v.LayerPartBlob == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("LayerPartBlob"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/CHANGELOG.md
new file mode 100644
index 000000000000..e17b71a8740f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/CHANGELOG.md
@@ -0,0 +1,64 @@
+# v1.6.0 (2022-01-07)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.2 (2021-12-02)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.0 (2021-11-06)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.0 (2021-10-21)
+
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.2 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.1 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.0 (2021-08-27)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.3 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.2 (2021-08-04)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.1 (2021-07-15)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.0 (2021-06-25)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.1 (2021-05-20)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.1.0 (2021-05-14)
+
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/context.go b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/context.go
new file mode 100644
index 000000000000..cc919701a06f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/context.go
@@ -0,0 +1,48 @@
+package presignedurl
+
+import (
+ "context"
+
+ "github.com/aws/smithy-go/middleware"
+)
+
+// WithIsPresigning adds the isPresigning sentinel value to a context to signal
+// that the middleware stack is using the presign flow.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func WithIsPresigning(ctx context.Context) context.Context {
+ return middleware.WithStackValue(ctx, isPresigningKey{}, true)
+}
+
+// GetIsPresigning returns if the context contains the isPresigning sentinel
+// value for presigning flows.
+//
+// Scoped to stack values. Use github.com/aws/smithy-go/middleware#ClearStackValues
+// to clear all stack values.
+func GetIsPresigning(ctx context.Context) bool {
+ v, _ := middleware.GetStackValue(ctx, isPresigningKey{}).(bool)
+ return v
+}
+
+type isPresigningKey struct{}
+
+// AddAsIsPresigingMiddleware adds a middleware to the head of the stack that
+// will update the stack's context to be flagged as being invoked for the
+// purpose of presigning.
+func AddAsIsPresigingMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(asIsPresigningMiddleware{}, middleware.Before)
+}
+
+type asIsPresigningMiddleware struct{}
+
+func (asIsPresigningMiddleware) ID() string { return "AsIsPresigningMiddleware" }
+
+func (asIsPresigningMiddleware) HandleInitialize(
+ ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler,
+) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ ctx = WithIsPresigning(ctx)
+ return next.HandleInitialize(ctx, in)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/doc.go
new file mode 100644
index 000000000000..1b85375cf806
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/doc.go
@@ -0,0 +1,3 @@
+// Package presignedurl provides the customizations for API clients to fill in
+// presigned URLs into input parameters.
+package presignedurl
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go.mod
new file mode 100644
index 000000000000..b9ecca59e069
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go.mod
@@ -0,0 +1,11 @@
+module github.com/aws/aws-sdk-go-v2/service/internal/presigned-url
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/smithy-go v1.9.1
+ github.com/google/go-cmp v0.5.6
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../../../
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go_module_metadata.go
new file mode 100644
index 000000000000..234dc7259424
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package presignedurl
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.6.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/middleware.go b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/middleware.go
new file mode 100644
index 000000000000..1e2f5c8122a0
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/internal/presigned-url/middleware.go
@@ -0,0 +1,110 @@
+package presignedurl
+
+import (
+ "context"
+ "fmt"
+
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ v4 "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+
+ "github.com/aws/smithy-go/middleware"
+)
+
+// URLPresigner provides the interface to presign the input parameters in to a
+// presigned URL.
+type URLPresigner interface {
+ // PresignURL presigns a URL.
+ PresignURL(ctx context.Context, srcRegion string, params interface{}) (*v4.PresignedHTTPRequest, error)
+}
+
+// ParameterAccessor provides an collection of accessor to for retrieving and
+// setting the values needed to PresignedURL generation
+type ParameterAccessor struct {
+ // GetPresignedURL accessor points to a function that retrieves a presigned url if present
+ GetPresignedURL func(interface{}) (string, bool, error)
+
+ // GetSourceRegion accessor points to a function that retrieves source region for presigned url
+ GetSourceRegion func(interface{}) (string, bool, error)
+
+ // CopyInput accessor points to a function that takes in an input, and returns a copy.
+ CopyInput func(interface{}) (interface{}, error)
+
+ // SetDestinationRegion accessor points to a function that sets destination region on api input struct
+ SetDestinationRegion func(interface{}, string) error
+
+ // SetPresignedURL accessor points to a function that sets presigned url on api input struct
+ SetPresignedURL func(interface{}, string) error
+}
+
+// Options provides the set of options needed by the presigned URL middleware.
+type Options struct {
+ // Accessor are the parameter accessors used by this middleware
+ Accessor ParameterAccessor
+
+ // Presigner is the URLPresigner used by the middleware
+ Presigner URLPresigner
+}
+
+// AddMiddleware adds the Presign URL middleware to the middleware stack.
+func AddMiddleware(stack *middleware.Stack, opts Options) error {
+ return stack.Initialize.Add(&presign{options: opts}, middleware.Before)
+}
+
+// RemoveMiddleware removes the Presign URL middleware from the stack.
+func RemoveMiddleware(stack *middleware.Stack) error {
+ _, err := stack.Initialize.Remove((*presign)(nil).ID())
+ return err
+}
+
+type presign struct {
+ options Options
+}
+
+func (m *presign) ID() string { return "Presign" }
+
+func (m *presign) HandleInitialize(
+ ctx context.Context, input middleware.InitializeInput, next middleware.InitializeHandler,
+) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ // If PresignedURL is already set ignore middleware.
+ if _, ok, err := m.options.Accessor.GetPresignedURL(input.Parameters); err != nil {
+ return out, metadata, fmt.Errorf("presign middleware failed, %w", err)
+ } else if ok {
+ return next.HandleInitialize(ctx, input)
+ }
+
+ // If have source region is not set ignore middleware.
+ srcRegion, ok, err := m.options.Accessor.GetSourceRegion(input.Parameters)
+ if err != nil {
+ return out, metadata, fmt.Errorf("presign middleware failed, %w", err)
+ } else if !ok || len(srcRegion) == 0 {
+ return next.HandleInitialize(ctx, input)
+ }
+
+ // Create a copy of the original input so the destination region value can
+ // be added. This ensures that value does not leak into the original
+ // request parameters.
+ paramCpy, err := m.options.Accessor.CopyInput(input.Parameters)
+ if err != nil {
+ return out, metadata, fmt.Errorf("unable to create presigned URL, %w", err)
+ }
+
+ // Destination region is the API client's configured region.
+ dstRegion := awsmiddleware.GetRegion(ctx)
+ if err = m.options.Accessor.SetDestinationRegion(paramCpy, dstRegion); err != nil {
+ return out, metadata, fmt.Errorf("presign middleware failed, %w", err)
+ }
+
+ presignedReq, err := m.options.Presigner.PresignURL(ctx, srcRegion, paramCpy)
+ if err != nil {
+ return out, metadata, fmt.Errorf("unable to create presigned URL, %w", err)
+ }
+
+ // Update the original input with the presigned URL value.
+ if err = m.options.Accessor.SetPresignedURL(input.Parameters, presignedReq.URL); err != nil {
+ return out, metadata, fmt.Errorf("presign middleware failed, %w", err)
+ }
+
+ return next.HandleInitialize(ctx, input)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/CHANGELOG.md
new file mode 100644
index 000000000000..72354eb1c4cd
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/CHANGELOG.md
@@ -0,0 +1,71 @@
+# v1.8.0 (2022-01-07)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.7.0 (2021-12-21)
+
+* **Feature**: API Paginators now support specifying the initial starting token, and support stopping on empty string tokens.
+
+# v1.6.2 (2021-12-02)
+
+* **Bug Fix**: Fixes a bug that prevented aws.EndpointResolverWithOptions from being used by the service client. ([#1514](https://github.com/aws/aws-sdk-go-v2/pull/1514))
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.0 (2021-11-06)
+
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Feature**: Updated service to latest API model.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.0 (2021-10-21)
+
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.2 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.1 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.0 (2021-08-27)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.3 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.2 (2021-08-04)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.1 (2021-07-15)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.3.0 (2021-06-25)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.1 (2021-05-20)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.2.0 (2021-05-14)
+
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_client.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_client.go
new file mode 100644
index 000000000000..4fed68b6f9d6
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_client.go
@@ -0,0 +1,296 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "context"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/retry"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ awshttp "github.com/aws/aws-sdk-go-v2/aws/transport/http"
+ internalConfig "github.com/aws/aws-sdk-go-v2/internal/configsources"
+ smithy "github.com/aws/smithy-go"
+ smithydocument "github.com/aws/smithy-go/document"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "net/http"
+ "time"
+)
+
+const ServiceID = "SSO"
+const ServiceAPIVersion = "2019-06-10"
+
+// Client provides the API client to make operations call for AWS Single Sign-On.
+type Client struct {
+ options Options
+}
+
+// New returns an initialized Client based on the functional options. Provide
+// additional functional options to further configure the behavior of the client,
+// such as changing the client's endpoint or adding custom middleware behavior.
+func New(options Options, optFns ...func(*Options)) *Client {
+ options = options.Copy()
+
+ resolveDefaultLogger(&options)
+
+ resolveRetryer(&options)
+
+ resolveHTTPClient(&options)
+
+ resolveHTTPSignerV4(&options)
+
+ resolveDefaultEndpointConfiguration(&options)
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ client := &Client{
+ options: options,
+ }
+
+ return client
+}
+
+type Options struct {
+ // Set of options to modify how an operation is invoked. These apply to all
+ // operations invoked for this client. Use functional options on operation call to
+ // modify this list for per operation behavior.
+ APIOptions []func(*middleware.Stack) error
+
+ // Configures the events that will be sent to the configured logger.
+ ClientLogMode aws.ClientLogMode
+
+ // The credentials object to use when signing requests.
+ Credentials aws.CredentialsProvider
+
+ // The endpoint options to be used when attempting to resolve an endpoint.
+ EndpointOptions EndpointResolverOptions
+
+ // The service endpoint resolver.
+ EndpointResolver EndpointResolver
+
+ // Signature Version 4 (SigV4) Signer
+ HTTPSignerV4 HTTPSignerV4
+
+ // The logger writer interface to write logging messages to.
+ Logger logging.Logger
+
+ // The region to send requests to. (Required)
+ Region string
+
+ // Retryer guides how HTTP requests should be retried in case of recoverable
+ // failures. When nil the API client will use a default retryer.
+ Retryer aws.Retryer
+
+ // The HTTP client to invoke API calls with. Defaults to client's default HTTP
+ // implementation if nil.
+ HTTPClient HTTPClient
+}
+
+// WithAPIOptions returns a functional option for setting the Client's APIOptions
+// option.
+func WithAPIOptions(optFns ...func(*middleware.Stack) error) func(*Options) {
+ return func(o *Options) {
+ o.APIOptions = append(o.APIOptions, optFns...)
+ }
+}
+
+// WithEndpointResolver returns a functional option for setting the Client's
+// EndpointResolver option.
+func WithEndpointResolver(v EndpointResolver) func(*Options) {
+ return func(o *Options) {
+ o.EndpointResolver = v
+ }
+}
+
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// Copy creates a clone where the APIOptions list is deep copied.
+func (o Options) Copy() Options {
+ to := o
+ to.APIOptions = make([]func(*middleware.Stack) error, len(o.APIOptions))
+ copy(to.APIOptions, o.APIOptions)
+ return to
+}
+func (c *Client) invokeOperation(ctx context.Context, opID string, params interface{}, optFns []func(*Options), stackFns ...func(*middleware.Stack, Options) error) (result interface{}, metadata middleware.Metadata, err error) {
+ ctx = middleware.ClearStackValues(ctx)
+ stack := middleware.NewStack(opID, smithyhttp.NewStackRequest)
+ options := c.options.Copy()
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ finalizeClientEndpointResolverOptions(&options)
+
+ for _, fn := range stackFns {
+ if err := fn(stack, options); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ for _, fn := range options.APIOptions {
+ if err := fn(stack); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ handler := middleware.DecorateHandler(smithyhttp.NewClientHandler(options.HTTPClient), stack)
+ result, metadata, err = handler.Handle(ctx, params)
+ if err != nil {
+ err = &smithy.OperationError{
+ ServiceID: ServiceID,
+ OperationName: opID,
+ Err: err,
+ }
+ }
+ return result, metadata, err
+}
+
+type noSmithyDocumentSerde = smithydocument.NoSerde
+
+func resolveDefaultLogger(o *Options) {
+ if o.Logger != nil {
+ return
+ }
+ o.Logger = logging.Nop{}
+}
+
+func addSetLoggerMiddleware(stack *middleware.Stack, o Options) error {
+ return middleware.AddSetLoggerMiddleware(stack, o.Logger)
+}
+
+// NewFromConfig returns a new client from the provided config.
+func NewFromConfig(cfg aws.Config, optFns ...func(*Options)) *Client {
+ opts := Options{
+ Region: cfg.Region,
+ HTTPClient: cfg.HTTPClient,
+ Credentials: cfg.Credentials,
+ APIOptions: cfg.APIOptions,
+ Logger: cfg.Logger,
+ ClientLogMode: cfg.ClientLogMode,
+ }
+ resolveAWSRetryerProvider(cfg, &opts)
+ resolveAWSEndpointResolver(cfg, &opts)
+ resolveUseDualStackEndpoint(cfg, &opts)
+ resolveUseFIPSEndpoint(cfg, &opts)
+ return New(opts, optFns...)
+}
+
+func resolveHTTPClient(o *Options) {
+ if o.HTTPClient != nil {
+ return
+ }
+ o.HTTPClient = awshttp.NewBuildableClient()
+}
+
+func resolveRetryer(o *Options) {
+ if o.Retryer != nil {
+ return
+ }
+ o.Retryer = retry.NewStandard()
+}
+
+func resolveAWSRetryerProvider(cfg aws.Config, o *Options) {
+ if cfg.Retryer == nil {
+ return
+ }
+ o.Retryer = cfg.Retryer()
+}
+
+func resolveAWSEndpointResolver(cfg aws.Config, o *Options) {
+ if cfg.EndpointResolver == nil && cfg.EndpointResolverWithOptions == nil {
+ return
+ }
+ o.EndpointResolver = withEndpointResolver(cfg.EndpointResolver, cfg.EndpointResolverWithOptions, NewDefaultEndpointResolver())
+}
+
+func addClientUserAgent(stack *middleware.Stack) error {
+ return awsmiddleware.AddSDKAgentKeyValue(awsmiddleware.APIMetadata, "sso", goModuleVersion)(stack)
+}
+
+func addHTTPSignerV4Middleware(stack *middleware.Stack, o Options) error {
+ mw := v4.NewSignHTTPRequestMiddleware(v4.SignHTTPRequestMiddlewareOptions{
+ CredentialsProvider: o.Credentials,
+ Signer: o.HTTPSignerV4,
+ LogSigning: o.ClientLogMode.IsSigning(),
+ })
+ return stack.Finalize.Add(mw, middleware.After)
+}
+
+type HTTPSignerV4 interface {
+ SignHTTP(ctx context.Context, credentials aws.Credentials, r *http.Request, payloadHash string, service string, region string, signingTime time.Time, optFns ...func(*v4.SignerOptions)) error
+}
+
+func resolveHTTPSignerV4(o *Options) {
+ if o.HTTPSignerV4 != nil {
+ return
+ }
+ o.HTTPSignerV4 = newDefaultV4Signer(*o)
+}
+
+func newDefaultV4Signer(o Options) *v4.Signer {
+ return v4.NewSigner(func(so *v4.SignerOptions) {
+ so.Logger = o.Logger
+ so.LogSigning = o.ClientLogMode.IsSigning()
+ })
+}
+
+func addRetryMiddlewares(stack *middleware.Stack, o Options) error {
+ mo := retry.AddRetryMiddlewaresOptions{
+ Retryer: o.Retryer,
+ LogRetryAttempts: o.ClientLogMode.IsRetries(),
+ }
+ return retry.AddRetryMiddlewares(stack, mo)
+}
+
+// resolves dual-stack endpoint configuration
+func resolveUseDualStackEndpoint(cfg aws.Config, o *Options) error {
+ if len(cfg.ConfigSources) == 0 {
+ return nil
+ }
+ value, found, err := internalConfig.ResolveUseDualStackEndpoint(context.Background(), cfg.ConfigSources)
+ if err != nil {
+ return err
+ }
+ if found {
+ o.EndpointOptions.UseDualStackEndpoint = value
+ }
+ return nil
+}
+
+// resolves FIPS endpoint configuration
+func resolveUseFIPSEndpoint(cfg aws.Config, o *Options) error {
+ if len(cfg.ConfigSources) == 0 {
+ return nil
+ }
+ value, found, err := internalConfig.ResolveUseFIPSEndpoint(context.Background(), cfg.ConfigSources)
+ if err != nil {
+ return err
+ }
+ if found {
+ o.EndpointOptions.UseFIPSEndpoint = value
+ }
+ return nil
+}
+
+func addRequestIDRetrieverMiddleware(stack *middleware.Stack) error {
+ return awsmiddleware.AddRequestIDRetrieverMiddleware(stack)
+}
+
+func addResponseErrorMiddleware(stack *middleware.Stack) error {
+ return awshttp.AddResponseErrorMiddleware(stack)
+}
+
+func addRequestResponseLogging(stack *middleware.Stack, o Options) error {
+ return stack.Deserialize.Add(&smithyhttp.RequestResponseLogger{
+ LogRequest: o.ClientLogMode.IsRequest(),
+ LogRequestWithBody: o.ClientLogMode.IsRequestWithBody(),
+ LogResponse: o.ClientLogMode.IsResponse(),
+ LogResponseWithBody: o.ClientLogMode.IsResponseWithBody(),
+ }, middleware.After)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_GetRoleCredentials.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_GetRoleCredentials.go
new file mode 100644
index 000000000000..85556599f83a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_GetRoleCredentials.go
@@ -0,0 +1,127 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/service/sso/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns the STS short-term credentials for a given role name that is assigned to
+// the user.
+func (c *Client) GetRoleCredentials(ctx context.Context, params *GetRoleCredentialsInput, optFns ...func(*Options)) (*GetRoleCredentialsOutput, error) {
+ if params == nil {
+ params = &GetRoleCredentialsInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetRoleCredentials", params, optFns, c.addOperationGetRoleCredentialsMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetRoleCredentialsOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetRoleCredentialsInput struct {
+
+ // The token issued by the CreateToken API call. For more information, see
+ // CreateToken
+ // (https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html)
+ // in the AWS SSO OIDC API Reference Guide.
+ //
+ // This member is required.
+ AccessToken *string
+
+ // The identifier for the AWS account that is assigned to the user.
+ //
+ // This member is required.
+ AccountId *string
+
+ // The friendly name of the role that is assigned to the user.
+ //
+ // This member is required.
+ RoleName *string
+
+ noSmithyDocumentSerde
+}
+
+type GetRoleCredentialsOutput struct {
+
+ // The credentials for the role that is assigned to the user.
+ RoleCredentials *types.RoleCredentials
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetRoleCredentialsMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsRestjson1_serializeOpGetRoleCredentials{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsRestjson1_deserializeOpGetRoleCredentials{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetRoleCredentialsValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetRoleCredentials(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetRoleCredentials(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ OperationName: "GetRoleCredentials",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_ListAccountRoles.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_ListAccountRoles.go
new file mode 100644
index 000000000000..1923c4a9d6bd
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_ListAccountRoles.go
@@ -0,0 +1,223 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/service/sso/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Lists all roles that are assigned to the user for a given AWS account.
+func (c *Client) ListAccountRoles(ctx context.Context, params *ListAccountRolesInput, optFns ...func(*Options)) (*ListAccountRolesOutput, error) {
+ if params == nil {
+ params = &ListAccountRolesInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "ListAccountRoles", params, optFns, c.addOperationListAccountRolesMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*ListAccountRolesOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type ListAccountRolesInput struct {
+
+ // The token issued by the CreateToken API call. For more information, see
+ // CreateToken
+ // (https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html)
+ // in the AWS SSO OIDC API Reference Guide.
+ //
+ // This member is required.
+ AccessToken *string
+
+ // The identifier for the AWS account that is assigned to the user.
+ //
+ // This member is required.
+ AccountId *string
+
+ // The number of items that clients can request per page.
+ MaxResults *int32
+
+ // The page token from the previous response output when you request subsequent
+ // pages.
+ NextToken *string
+
+ noSmithyDocumentSerde
+}
+
+type ListAccountRolesOutput struct {
+
+ // The page token client that is used to retrieve the list of accounts.
+ NextToken *string
+
+ // A paginated response with the list of roles and the next token if more results
+ // are available.
+ RoleList []types.RoleInfo
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationListAccountRolesMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsRestjson1_serializeOpListAccountRoles{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsRestjson1_deserializeOpListAccountRoles{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpListAccountRolesValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListAccountRoles(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// ListAccountRolesAPIClient is a client that implements the ListAccountRoles
+// operation.
+type ListAccountRolesAPIClient interface {
+ ListAccountRoles(context.Context, *ListAccountRolesInput, ...func(*Options)) (*ListAccountRolesOutput, error)
+}
+
+var _ ListAccountRolesAPIClient = (*Client)(nil)
+
+// ListAccountRolesPaginatorOptions is the paginator options for ListAccountRoles
+type ListAccountRolesPaginatorOptions struct {
+ // The number of items that clients can request per page.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// ListAccountRolesPaginator is a paginator for ListAccountRoles
+type ListAccountRolesPaginator struct {
+ options ListAccountRolesPaginatorOptions
+ client ListAccountRolesAPIClient
+ params *ListAccountRolesInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewListAccountRolesPaginator returns a new ListAccountRolesPaginator
+func NewListAccountRolesPaginator(client ListAccountRolesAPIClient, params *ListAccountRolesInput, optFns ...func(*ListAccountRolesPaginatorOptions)) *ListAccountRolesPaginator {
+ if params == nil {
+ params = &ListAccountRolesInput{}
+ }
+
+ options := ListAccountRolesPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &ListAccountRolesPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *ListAccountRolesPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next ListAccountRoles page.
+func (p *ListAccountRolesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListAccountRolesOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.ListAccountRoles(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opListAccountRoles(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ OperationName: "ListAccountRoles",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_ListAccounts.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_ListAccounts.go
new file mode 100644
index 000000000000..c76f6ca38d1d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_ListAccounts.go
@@ -0,0 +1,220 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "context"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/service/sso/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Lists all AWS accounts assigned to the user. These AWS accounts are assigned by
+// the administrator of the account. For more information, see Assign User Access
+// (https://docs.aws.amazon.com/singlesignon/latest/userguide/useraccess.html#assignusers)
+// in the AWS SSO User Guide. This operation returns a paginated response.
+func (c *Client) ListAccounts(ctx context.Context, params *ListAccountsInput, optFns ...func(*Options)) (*ListAccountsOutput, error) {
+ if params == nil {
+ params = &ListAccountsInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "ListAccounts", params, optFns, c.addOperationListAccountsMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*ListAccountsOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type ListAccountsInput struct {
+
+ // The token issued by the CreateToken API call. For more information, see
+ // CreateToken
+ // (https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html)
+ // in the AWS SSO OIDC API Reference Guide.
+ //
+ // This member is required.
+ AccessToken *string
+
+ // This is the number of items clients can request per page.
+ MaxResults *int32
+
+ // (Optional) When requesting subsequent pages, this is the page token from the
+ // previous response output.
+ NextToken *string
+
+ noSmithyDocumentSerde
+}
+
+type ListAccountsOutput struct {
+
+ // A paginated response with the list of account information and the next token if
+ // more results are available.
+ AccountList []types.AccountInfo
+
+ // The page token client that is used to retrieve the list of accounts.
+ NextToken *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationListAccountsMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsRestjson1_serializeOpListAccounts{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsRestjson1_deserializeOpListAccounts{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpListAccountsValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListAccounts(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+// ListAccountsAPIClient is a client that implements the ListAccounts operation.
+type ListAccountsAPIClient interface {
+ ListAccounts(context.Context, *ListAccountsInput, ...func(*Options)) (*ListAccountsOutput, error)
+}
+
+var _ ListAccountsAPIClient = (*Client)(nil)
+
+// ListAccountsPaginatorOptions is the paginator options for ListAccounts
+type ListAccountsPaginatorOptions struct {
+ // This is the number of items clients can request per page.
+ Limit int32
+
+ // Set to true if pagination should stop if the service returns a pagination token
+ // that matches the most recent token provided to the service.
+ StopOnDuplicateToken bool
+}
+
+// ListAccountsPaginator is a paginator for ListAccounts
+type ListAccountsPaginator struct {
+ options ListAccountsPaginatorOptions
+ client ListAccountsAPIClient
+ params *ListAccountsInput
+ nextToken *string
+ firstPage bool
+}
+
+// NewListAccountsPaginator returns a new ListAccountsPaginator
+func NewListAccountsPaginator(client ListAccountsAPIClient, params *ListAccountsInput, optFns ...func(*ListAccountsPaginatorOptions)) *ListAccountsPaginator {
+ if params == nil {
+ params = &ListAccountsInput{}
+ }
+
+ options := ListAccountsPaginatorOptions{}
+ if params.MaxResults != nil {
+ options.Limit = *params.MaxResults
+ }
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ return &ListAccountsPaginator{
+ options: options,
+ client: client,
+ params: params,
+ firstPage: true,
+ nextToken: params.NextToken,
+ }
+}
+
+// HasMorePages returns a boolean indicating whether more pages are available
+func (p *ListAccountsPaginator) HasMorePages() bool {
+ return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0)
+}
+
+// NextPage retrieves the next ListAccounts page.
+func (p *ListAccountsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListAccountsOutput, error) {
+ if !p.HasMorePages() {
+ return nil, fmt.Errorf("no more pages available")
+ }
+
+ params := *p.params
+ params.NextToken = p.nextToken
+
+ var limit *int32
+ if p.options.Limit > 0 {
+ limit = &p.options.Limit
+ }
+ params.MaxResults = limit
+
+ result, err := p.client.ListAccounts(ctx, ¶ms, optFns...)
+ if err != nil {
+ return nil, err
+ }
+ p.firstPage = false
+
+ prevToken := p.nextToken
+ p.nextToken = result.NextToken
+
+ if p.options.StopOnDuplicateToken &&
+ prevToken != nil &&
+ p.nextToken != nil &&
+ *prevToken == *p.nextToken {
+ p.nextToken = nil
+ }
+
+ return result, nil
+}
+
+func newServiceMetadataMiddleware_opListAccounts(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ OperationName: "ListAccounts",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_Logout.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_Logout.go
new file mode 100644
index 000000000000..cbc72877d9b5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/api_op_Logout.go
@@ -0,0 +1,111 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Removes the client- and server-side session that is associated with the user.
+func (c *Client) Logout(ctx context.Context, params *LogoutInput, optFns ...func(*Options)) (*LogoutOutput, error) {
+ if params == nil {
+ params = &LogoutInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "Logout", params, optFns, c.addOperationLogoutMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*LogoutOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type LogoutInput struct {
+
+ // The token issued by the CreateToken API call. For more information, see
+ // CreateToken
+ // (https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html)
+ // in the AWS SSO OIDC API Reference Guide.
+ //
+ // This member is required.
+ AccessToken *string
+
+ noSmithyDocumentSerde
+}
+
+type LogoutOutput struct {
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationLogoutMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsRestjson1_serializeOpLogout{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsRestjson1_deserializeOpLogout{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpLogoutValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opLogout(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opLogout(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ OperationName: "Logout",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/deserializers.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/deserializers.go
new file mode 100644
index 000000000000..6a1851da2510
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/deserializers.go
@@ -0,0 +1,1151 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "bytes"
+ "context"
+ "encoding/json"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/aws/protocol/restjson"
+ "github.com/aws/aws-sdk-go-v2/service/sso/types"
+ smithy "github.com/aws/smithy-go"
+ smithyio "github.com/aws/smithy-go/io"
+ "github.com/aws/smithy-go/middleware"
+ "github.com/aws/smithy-go/ptr"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "io"
+ "io/ioutil"
+ "strings"
+)
+
+type awsRestjson1_deserializeOpGetRoleCredentials struct {
+}
+
+func (*awsRestjson1_deserializeOpGetRoleCredentials) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsRestjson1_deserializeOpGetRoleCredentials) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsRestjson1_deserializeOpErrorGetRoleCredentials(response, &metadata)
+ }
+ output := &GetRoleCredentialsOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsRestjson1_deserializeOpDocumentGetRoleCredentialsOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return out, metadata, err
+}
+
+func awsRestjson1_deserializeOpErrorGetRoleCredentials(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidRequestException", errorCode):
+ return awsRestjson1_deserializeErrorInvalidRequestException(response, errorBody)
+
+ case strings.EqualFold("ResourceNotFoundException", errorCode):
+ return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody)
+
+ case strings.EqualFold("TooManyRequestsException", errorCode):
+ return awsRestjson1_deserializeErrorTooManyRequestsException(response, errorBody)
+
+ case strings.EqualFold("UnauthorizedException", errorCode):
+ return awsRestjson1_deserializeErrorUnauthorizedException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+func awsRestjson1_deserializeOpDocumentGetRoleCredentialsOutput(v **GetRoleCredentialsOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *GetRoleCredentialsOutput
+ if *v == nil {
+ sv = &GetRoleCredentialsOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "roleCredentials":
+ if err := awsRestjson1_deserializeDocumentRoleCredentials(&sv.RoleCredentials, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+type awsRestjson1_deserializeOpListAccountRoles struct {
+}
+
+func (*awsRestjson1_deserializeOpListAccountRoles) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsRestjson1_deserializeOpListAccountRoles) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsRestjson1_deserializeOpErrorListAccountRoles(response, &metadata)
+ }
+ output := &ListAccountRolesOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsRestjson1_deserializeOpDocumentListAccountRolesOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return out, metadata, err
+}
+
+func awsRestjson1_deserializeOpErrorListAccountRoles(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidRequestException", errorCode):
+ return awsRestjson1_deserializeErrorInvalidRequestException(response, errorBody)
+
+ case strings.EqualFold("ResourceNotFoundException", errorCode):
+ return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody)
+
+ case strings.EqualFold("TooManyRequestsException", errorCode):
+ return awsRestjson1_deserializeErrorTooManyRequestsException(response, errorBody)
+
+ case strings.EqualFold("UnauthorizedException", errorCode):
+ return awsRestjson1_deserializeErrorUnauthorizedException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+func awsRestjson1_deserializeOpDocumentListAccountRolesOutput(v **ListAccountRolesOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *ListAccountRolesOutput
+ if *v == nil {
+ sv = &ListAccountRolesOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextTokenType to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ case "roleList":
+ if err := awsRestjson1_deserializeDocumentRoleListType(&sv.RoleList, value); err != nil {
+ return err
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+type awsRestjson1_deserializeOpListAccounts struct {
+}
+
+func (*awsRestjson1_deserializeOpListAccounts) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsRestjson1_deserializeOpListAccounts) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsRestjson1_deserializeOpErrorListAccounts(response, &metadata)
+ }
+ output := &ListAccountsOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(response.Body, ringBuffer)
+
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ err = awsRestjson1_deserializeOpDocumentListAccountsOutput(&output, shape)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return out, metadata, err
+}
+
+func awsRestjson1_deserializeOpErrorListAccounts(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidRequestException", errorCode):
+ return awsRestjson1_deserializeErrorInvalidRequestException(response, errorBody)
+
+ case strings.EqualFold("ResourceNotFoundException", errorCode):
+ return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody)
+
+ case strings.EqualFold("TooManyRequestsException", errorCode):
+ return awsRestjson1_deserializeErrorTooManyRequestsException(response, errorBody)
+
+ case strings.EqualFold("UnauthorizedException", errorCode):
+ return awsRestjson1_deserializeErrorUnauthorizedException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+func awsRestjson1_deserializeOpDocumentListAccountsOutput(v **ListAccountsOutput, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *ListAccountsOutput
+ if *v == nil {
+ sv = &ListAccountsOutput{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "accountList":
+ if err := awsRestjson1_deserializeDocumentAccountListType(&sv.AccountList, value); err != nil {
+ return err
+ }
+
+ case "nextToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected NextTokenType to be of type string, got %T instead", value)
+ }
+ sv.NextToken = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+type awsRestjson1_deserializeOpLogout struct {
+}
+
+func (*awsRestjson1_deserializeOpLogout) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsRestjson1_deserializeOpLogout) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsRestjson1_deserializeOpErrorLogout(response, &metadata)
+ }
+ output := &LogoutOutput{}
+ out.Result = output
+
+ if _, err = io.Copy(ioutil.Discard, response.Body); err != nil {
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to discard response body, %w", err),
+ }
+ }
+
+ return out, metadata, err
+}
+
+func awsRestjson1_deserializeOpErrorLogout(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ code := response.Header.Get("X-Amzn-ErrorType")
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ code, message, err := restjson.GetErrorInfo(decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+ if len(code) != 0 {
+ errorCode = restjson.SanitizeErrorCode(code)
+ }
+ if len(message) != 0 {
+ errorMessage = message
+ }
+
+ switch {
+ case strings.EqualFold("InvalidRequestException", errorCode):
+ return awsRestjson1_deserializeErrorInvalidRequestException(response, errorBody)
+
+ case strings.EqualFold("TooManyRequestsException", errorCode):
+ return awsRestjson1_deserializeErrorTooManyRequestsException(response, errorBody)
+
+ case strings.EqualFold("UnauthorizedException", errorCode):
+ return awsRestjson1_deserializeErrorUnauthorizedException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+func awsRestjson1_deserializeErrorInvalidRequestException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.InvalidRequestException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ err := awsRestjson1_deserializeDocumentInvalidRequestException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+
+ return output
+}
+
+func awsRestjson1_deserializeErrorResourceNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.ResourceNotFoundException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ err := awsRestjson1_deserializeDocumentResourceNotFoundException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+
+ return output
+}
+
+func awsRestjson1_deserializeErrorTooManyRequestsException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.TooManyRequestsException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ err := awsRestjson1_deserializeDocumentTooManyRequestsException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+
+ return output
+}
+
+func awsRestjson1_deserializeErrorUnauthorizedException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.UnauthorizedException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+
+ body := io.TeeReader(errorBody, ringBuffer)
+ decoder := json.NewDecoder(body)
+ decoder.UseNumber()
+ var shape interface{}
+ if err := decoder.Decode(&shape); err != nil && err != io.EOF {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ err := awsRestjson1_deserializeDocumentUnauthorizedException(&output, shape)
+
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return err
+ }
+
+ errorBody.Seek(0, io.SeekStart)
+
+ return output
+}
+
+func awsRestjson1_deserializeDocumentAccountInfo(v **types.AccountInfo, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.AccountInfo
+ if *v == nil {
+ sv = &types.AccountInfo{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "accountId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected AccountIdType to be of type string, got %T instead", value)
+ }
+ sv.AccountId = ptr.String(jtv)
+ }
+
+ case "accountName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected AccountNameType to be of type string, got %T instead", value)
+ }
+ sv.AccountName = ptr.String(jtv)
+ }
+
+ case "emailAddress":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected EmailAddressType to be of type string, got %T instead", value)
+ }
+ sv.EmailAddress = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsRestjson1_deserializeDocumentAccountListType(v *[]types.AccountInfo, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.AccountInfo
+ if *v == nil {
+ cv = []types.AccountInfo{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.AccountInfo
+ destAddr := &col
+ if err := awsRestjson1_deserializeDocumentAccountInfo(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsRestjson1_deserializeDocumentInvalidRequestException(v **types.InvalidRequestException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.InvalidRequestException
+ if *v == nil {
+ sv = &types.InvalidRequestException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ErrorDescription to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsRestjson1_deserializeDocumentResourceNotFoundException(v **types.ResourceNotFoundException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.ResourceNotFoundException
+ if *v == nil {
+ sv = &types.ResourceNotFoundException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ErrorDescription to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsRestjson1_deserializeDocumentRoleCredentials(v **types.RoleCredentials, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RoleCredentials
+ if *v == nil {
+ sv = &types.RoleCredentials{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "accessKeyId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected AccessKeyType to be of type string, got %T instead", value)
+ }
+ sv.AccessKeyId = ptr.String(jtv)
+ }
+
+ case "expiration":
+ if value != nil {
+ jtv, ok := value.(json.Number)
+ if !ok {
+ return fmt.Errorf("expected ExpirationTimestampType to be json.Number, got %T instead", value)
+ }
+ i64, err := jtv.Int64()
+ if err != nil {
+ return err
+ }
+ sv.Expiration = i64
+ }
+
+ case "secretAccessKey":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected SecretAccessKeyType to be of type string, got %T instead", value)
+ }
+ sv.SecretAccessKey = ptr.String(jtv)
+ }
+
+ case "sessionToken":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected SessionTokenType to be of type string, got %T instead", value)
+ }
+ sv.SessionToken = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsRestjson1_deserializeDocumentRoleInfo(v **types.RoleInfo, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.RoleInfo
+ if *v == nil {
+ sv = &types.RoleInfo{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "accountId":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected AccountIdType to be of type string, got %T instead", value)
+ }
+ sv.AccountId = ptr.String(jtv)
+ }
+
+ case "roleName":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected RoleNameType to be of type string, got %T instead", value)
+ }
+ sv.RoleName = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsRestjson1_deserializeDocumentRoleListType(v *[]types.RoleInfo, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.([]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var cv []types.RoleInfo
+ if *v == nil {
+ cv = []types.RoleInfo{}
+ } else {
+ cv = *v
+ }
+
+ for _, value := range shape {
+ var col types.RoleInfo
+ destAddr := &col
+ if err := awsRestjson1_deserializeDocumentRoleInfo(&destAddr, value); err != nil {
+ return err
+ }
+ col = *destAddr
+ cv = append(cv, col)
+
+ }
+ *v = cv
+ return nil
+}
+
+func awsRestjson1_deserializeDocumentTooManyRequestsException(v **types.TooManyRequestsException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.TooManyRequestsException
+ if *v == nil {
+ sv = &types.TooManyRequestsException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ErrorDescription to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
+
+func awsRestjson1_deserializeDocumentUnauthorizedException(v **types.UnauthorizedException, value interface{}) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ if value == nil {
+ return nil
+ }
+
+ shape, ok := value.(map[string]interface{})
+ if !ok {
+ return fmt.Errorf("unexpected JSON type %v", value)
+ }
+
+ var sv *types.UnauthorizedException
+ if *v == nil {
+ sv = &types.UnauthorizedException{}
+ } else {
+ sv = *v
+ }
+
+ for key, value := range shape {
+ switch key {
+ case "message":
+ if value != nil {
+ jtv, ok := value.(string)
+ if !ok {
+ return fmt.Errorf("expected ErrorDescription to be of type string, got %T instead", value)
+ }
+ sv.Message = ptr.String(jtv)
+ }
+
+ default:
+ _, _ = key, value
+
+ }
+ }
+ *v = sv
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/doc.go
new file mode 100644
index 000000000000..c5d03d8e4a3a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/doc.go
@@ -0,0 +1,20 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+// Package sso provides the API client, operations, and parameter types for AWS
+// Single Sign-On.
+//
+// AWS Single Sign-On Portal is a web service that makes it easy for you to assign
+// user access to AWS SSO resources such as the user portal. Users can get AWS
+// account applications and roles assigned to them and get federated into the
+// application. For general information about AWS SSO, see What is AWS Single
+// Sign-On?
+// (https://docs.aws.amazon.com/singlesignon/latest/userguide/what-is.html) in the
+// AWS SSO User Guide. This API reference guide describes the AWS SSO Portal
+// operations that you can call programatically and includes detailed information
+// on data types and errors. AWS provides SDKs that consist of libraries and sample
+// code for various programming languages and platforms, such as Java, Ruby, .Net,
+// iOS, or Android. The SDKs provide a convenient way to create programmatic access
+// to AWS SSO and other AWS services. For more information about the AWS SDKs,
+// including how to download and install them, see Tools for Amazon Web Services
+// (http://aws.amazon.com/tools/).
+package sso
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/endpoints.go
new file mode 100644
index 000000000000..43c06f11afea
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/endpoints.go
@@ -0,0 +1,200 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ internalendpoints "github.com/aws/aws-sdk-go-v2/service/sso/internal/endpoints"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "net/url"
+ "strings"
+)
+
+// EndpointResolverOptions is the service endpoint resolver options
+type EndpointResolverOptions = internalendpoints.Options
+
+// EndpointResolver interface for resolving service endpoints.
+type EndpointResolver interface {
+ ResolveEndpoint(region string, options EndpointResolverOptions) (aws.Endpoint, error)
+}
+
+var _ EndpointResolver = &internalendpoints.Resolver{}
+
+// NewDefaultEndpointResolver constructs a new service endpoint resolver
+func NewDefaultEndpointResolver() *internalendpoints.Resolver {
+ return internalendpoints.New()
+}
+
+// EndpointResolverFunc is a helper utility that wraps a function so it satisfies
+// the EndpointResolver interface. This is useful when you want to add additional
+// endpoint resolving logic, or stub out specific endpoints with custom values.
+type EndpointResolverFunc func(region string, options EndpointResolverOptions) (aws.Endpoint, error)
+
+func (fn EndpointResolverFunc) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error) {
+ return fn(region, options)
+}
+
+func resolveDefaultEndpointConfiguration(o *Options) {
+ if o.EndpointResolver != nil {
+ return
+ }
+ o.EndpointResolver = NewDefaultEndpointResolver()
+}
+
+// EndpointResolverFromURL returns an EndpointResolver configured using the
+// provided endpoint url. By default, the resolved endpoint resolver uses the
+// client region as signing region, and the endpoint source is set to
+// EndpointSourceCustom.You can provide functional options to configure endpoint
+// values for the resolved endpoint.
+func EndpointResolverFromURL(url string, optFns ...func(*aws.Endpoint)) EndpointResolver {
+ e := aws.Endpoint{URL: url, Source: aws.EndpointSourceCustom}
+ for _, fn := range optFns {
+ fn(&e)
+ }
+
+ return EndpointResolverFunc(
+ func(region string, options EndpointResolverOptions) (aws.Endpoint, error) {
+ if len(e.SigningRegion) == 0 {
+ e.SigningRegion = region
+ }
+ return e, nil
+ },
+ )
+}
+
+type ResolveEndpoint struct {
+ Resolver EndpointResolver
+ Options EndpointResolverOptions
+}
+
+func (*ResolveEndpoint) ID() string {
+ return "ResolveEndpoint"
+}
+
+func (m *ResolveEndpoint) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in.Request)
+ }
+
+ if m.Resolver == nil {
+ return out, metadata, fmt.Errorf("expected endpoint resolver to not be nil")
+ }
+
+ eo := m.Options
+ eo.Logger = middleware.GetLogger(ctx)
+
+ var endpoint aws.Endpoint
+ endpoint, err = m.Resolver.ResolveEndpoint(awsmiddleware.GetRegion(ctx), eo)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to resolve service endpoint, %w", err)
+ }
+
+ req.URL, err = url.Parse(endpoint.URL)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to parse endpoint URL: %w", err)
+ }
+
+ if len(awsmiddleware.GetSigningName(ctx)) == 0 {
+ signingName := endpoint.SigningName
+ if len(signingName) == 0 {
+ signingName = "awsssoportal"
+ }
+ ctx = awsmiddleware.SetSigningName(ctx, signingName)
+ }
+ ctx = awsmiddleware.SetEndpointSource(ctx, endpoint.Source)
+ ctx = smithyhttp.SetHostnameImmutable(ctx, endpoint.HostnameImmutable)
+ ctx = awsmiddleware.SetSigningRegion(ctx, endpoint.SigningRegion)
+ ctx = awsmiddleware.SetPartitionID(ctx, endpoint.PartitionID)
+ return next.HandleSerialize(ctx, in)
+}
+func addResolveEndpointMiddleware(stack *middleware.Stack, o Options) error {
+ return stack.Serialize.Insert(&ResolveEndpoint{
+ Resolver: o.EndpointResolver,
+ Options: o.EndpointOptions,
+ }, "OperationSerializer", middleware.Before)
+}
+
+func removeResolveEndpointMiddleware(stack *middleware.Stack) error {
+ _, err := stack.Serialize.Remove((&ResolveEndpoint{}).ID())
+ return err
+}
+
+type wrappedEndpointResolver struct {
+ awsResolver aws.EndpointResolverWithOptions
+ resolver EndpointResolver
+}
+
+func (w *wrappedEndpointResolver) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error) {
+ if w.awsResolver == nil {
+ goto fallback
+ }
+ endpoint, err = w.awsResolver.ResolveEndpoint(ServiceID, region, options)
+ if err == nil {
+ return endpoint, nil
+ }
+
+ if nf := (&aws.EndpointNotFoundError{}); !errors.As(err, &nf) {
+ return endpoint, err
+ }
+
+fallback:
+ if w.resolver == nil {
+ return endpoint, fmt.Errorf("default endpoint resolver provided was nil")
+ }
+ return w.resolver.ResolveEndpoint(region, options)
+}
+
+type awsEndpointResolverAdaptor func(service, region string) (aws.Endpoint, error)
+
+func (a awsEndpointResolverAdaptor) ResolveEndpoint(service, region string, options ...interface{}) (aws.Endpoint, error) {
+ return a(service, region)
+}
+
+var _ aws.EndpointResolverWithOptions = awsEndpointResolverAdaptor(nil)
+
+// withEndpointResolver returns an EndpointResolver that first delegates endpoint resolution to the awsResolver.
+// If awsResolver returns aws.EndpointNotFoundError error, the resolver will use the the provided
+// fallbackResolver for resolution.
+//
+// fallbackResolver must not be nil
+func withEndpointResolver(awsResolver aws.EndpointResolver, awsResolverWithOptions aws.EndpointResolverWithOptions, fallbackResolver EndpointResolver) EndpointResolver {
+ var resolver aws.EndpointResolverWithOptions
+
+ if awsResolverWithOptions != nil {
+ resolver = awsResolverWithOptions
+ } else if awsResolver != nil {
+ resolver = awsEndpointResolverAdaptor(awsResolver.ResolveEndpoint)
+ }
+
+ return &wrappedEndpointResolver{
+ awsResolver: resolver,
+ resolver: fallbackResolver,
+ }
+}
+
+func finalizeClientEndpointResolverOptions(options *Options) {
+ options.EndpointOptions.LogDeprecated = options.ClientLogMode.IsDeprecatedUsage()
+
+ if len(options.EndpointOptions.ResolvedRegion) == 0 {
+ const fipsInfix = "-fips-"
+ const fipsPrefix = "fips-"
+ const fipsSuffix = "-fips"
+
+ if strings.Contains(options.Region, fipsInfix) ||
+ strings.Contains(options.Region, fipsPrefix) ||
+ strings.Contains(options.Region, fipsSuffix) {
+ options.EndpointOptions.ResolvedRegion = strings.ReplaceAll(strings.ReplaceAll(strings.ReplaceAll(
+ options.Region, fipsInfix, "-"), fipsPrefix, ""), fipsSuffix, "")
+ options.EndpointOptions.UseFIPSEndpoint = aws.FIPSEndpointStateEnabled
+ }
+ }
+
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/generated.json b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/generated.json
new file mode 100644
index 000000000000..912295209c54
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/generated.json
@@ -0,0 +1,29 @@
+{
+ "dependencies": {
+ "github.com/aws/aws-sdk-go-v2": "v1.4.0",
+ "github.com/aws/aws-sdk-go-v2/internal/configsources": "v0.0.0-00010101000000-000000000000",
+ "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2": "v2.0.0-00010101000000-000000000000",
+ "github.com/aws/smithy-go": "v1.4.0"
+ },
+ "files": [
+ "api_client.go",
+ "api_op_GetRoleCredentials.go",
+ "api_op_ListAccountRoles.go",
+ "api_op_ListAccounts.go",
+ "api_op_Logout.go",
+ "deserializers.go",
+ "doc.go",
+ "endpoints.go",
+ "generated.json",
+ "internal/endpoints/endpoints.go",
+ "internal/endpoints/endpoints_test.go",
+ "protocol_test.go",
+ "serializers.go",
+ "types/errors.go",
+ "types/types.go",
+ "validators.go"
+ ],
+ "go": "1.15",
+ "module": "github.com/aws/aws-sdk-go-v2/service/sso",
+ "unstable": false
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go.mod
new file mode 100644
index 000000000000..8005b62ce8e2
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go.mod
@@ -0,0 +1,16 @@
+module github.com/aws/aws-sdk-go-v2/service/sso
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3
+ github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0
+ github.com/aws/smithy-go v1.9.1
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../../
+
+replace github.com/aws/aws-sdk-go-v2/internal/configsources => ../../internal/configsources/
+
+replace github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 => ../../internal/endpoints/v2/
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go_module_metadata.go
new file mode 100644
index 000000000000..bbf7714787e9
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package sso
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.8.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/internal/endpoints/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/internal/endpoints/endpoints.go
new file mode 100644
index 000000000000..712a3c10b15a
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/internal/endpoints/endpoints.go
@@ -0,0 +1,382 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package endpoints
+
+import (
+ "github.com/aws/aws-sdk-go-v2/aws"
+ endpoints "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2"
+ "github.com/aws/smithy-go/logging"
+ "regexp"
+)
+
+// Options is the endpoint resolver configuration options
+type Options struct {
+ // Logger is a logging implementation that log events should be sent to.
+ Logger logging.Logger
+
+ // LogDeprecated indicates that deprecated endpoints should be logged to the
+ // provided logger.
+ LogDeprecated bool
+
+ // ResolvedRegion is used to override the region to be resolved, rather then the
+ // using the value passed to the ResolveEndpoint method. This value is used by the
+ // SDK to translate regions like fips-us-east-1 or us-east-1-fips to an alternative
+ // name. You must not set this value directly in your application.
+ ResolvedRegion string
+
+ // DisableHTTPS informs the resolver to return an endpoint that does not use the
+ // HTTPS scheme.
+ DisableHTTPS bool
+
+ // UseDualStackEndpoint specifies the resolver must resolve a dual-stack endpoint.
+ UseDualStackEndpoint aws.DualStackEndpointState
+
+ // UseFIPSEndpoint specifies the resolver must resolve a FIPS endpoint.
+ UseFIPSEndpoint aws.FIPSEndpointState
+}
+
+func (o Options) GetResolvedRegion() string {
+ return o.ResolvedRegion
+}
+
+func (o Options) GetDisableHTTPS() bool {
+ return o.DisableHTTPS
+}
+
+func (o Options) GetUseDualStackEndpoint() aws.DualStackEndpointState {
+ return o.UseDualStackEndpoint
+}
+
+func (o Options) GetUseFIPSEndpoint() aws.FIPSEndpointState {
+ return o.UseFIPSEndpoint
+}
+
+func transformToSharedOptions(options Options) endpoints.Options {
+ return endpoints.Options{
+ Logger: options.Logger,
+ LogDeprecated: options.LogDeprecated,
+ ResolvedRegion: options.ResolvedRegion,
+ DisableHTTPS: options.DisableHTTPS,
+ UseDualStackEndpoint: options.UseDualStackEndpoint,
+ UseFIPSEndpoint: options.UseFIPSEndpoint,
+ }
+}
+
+// Resolver SSO endpoint resolver
+type Resolver struct {
+ partitions endpoints.Partitions
+}
+
+// ResolveEndpoint resolves the service endpoint for the given region and options
+func (r *Resolver) ResolveEndpoint(region string, options Options) (endpoint aws.Endpoint, err error) {
+ if len(region) == 0 {
+ return endpoint, &aws.MissingRegionError{}
+ }
+
+ opt := transformToSharedOptions(options)
+ return r.partitions.ResolveEndpoint(region, opt)
+}
+
+// New returns a new Resolver
+func New() *Resolver {
+ return &Resolver{
+ partitions: defaultPartitions,
+ }
+}
+
+var partitionRegexp = struct {
+ Aws *regexp.Regexp
+ AwsCn *regexp.Regexp
+ AwsIso *regexp.Regexp
+ AwsIsoB *regexp.Regexp
+ AwsUsGov *regexp.Regexp
+}{
+
+ Aws: regexp.MustCompile("^(us|eu|ap|sa|ca|me|af)\\-\\w+\\-\\d+$"),
+ AwsCn: regexp.MustCompile("^cn\\-\\w+\\-\\d+$"),
+ AwsIso: regexp.MustCompile("^us\\-iso\\-\\w+\\-\\d+$"),
+ AwsIsoB: regexp.MustCompile("^us\\-isob\\-\\w+\\-\\d+$"),
+ AwsUsGov: regexp.MustCompile("^us\\-gov\\-\\w+\\-\\d+$"),
+}
+
+var defaultPartitions = endpoints.Partitions{
+ {
+ ID: "aws",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "portal.sso.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "portal.sso-fips.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "portal.sso-fips.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "portal.sso.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.Aws,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "ap-northeast-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.ap-northeast-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-northeast-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-northeast-2",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.ap-northeast-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-northeast-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-south-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.ap-south-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-south-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-southeast-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.ap-southeast-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-southeast-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ap-southeast-2",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.ap-southeast-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ap-southeast-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ca-central-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.ca-central-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "ca-central-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-central-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.eu-central-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-central-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-north-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.eu-north-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-north-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.eu-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-west-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-west-2",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.eu-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-west-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "eu-west-3",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.eu-west-3.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "eu-west-3",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "sa-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.sa-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "sa-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.us-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-2",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.us-east-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-2",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-2",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.us-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-2",
+ },
+ },
+ },
+ },
+ {
+ ID: "aws-cn",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "portal.sso.{region}.api.amazonwebservices.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "portal.sso-fips.{region}.amazonaws.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "portal.sso-fips.{region}.api.amazonwebservices.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "portal.sso.{region}.amazonaws.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsCn,
+ IsRegionalized: true,
+ },
+ {
+ ID: "aws-iso",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "portal.sso-fips.{region}.c2s.ic.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "portal.sso.{region}.c2s.ic.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsIso,
+ IsRegionalized: true,
+ },
+ {
+ ID: "aws-iso-b",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "portal.sso-fips.{region}.sc2s.sgov.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "portal.sso.{region}.sc2s.sgov.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsIsoB,
+ IsRegionalized: true,
+ },
+ {
+ ID: "aws-us-gov",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "portal.sso.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "portal.sso-fips.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "portal.sso-fips.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "portal.sso.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsUsGov,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "us-gov-west-1",
+ }: endpoints.Endpoint{
+ Hostname: "portal.sso.us-gov-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-west-1",
+ },
+ },
+ },
+ },
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/serializers.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/serializers.go
new file mode 100644
index 000000000000..29e320811942
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/serializers.go
@@ -0,0 +1,256 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "context"
+ "fmt"
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/encoding/httpbinding"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+type awsRestjson1_serializeOpGetRoleCredentials struct {
+}
+
+func (*awsRestjson1_serializeOpGetRoleCredentials) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsRestjson1_serializeOpGetRoleCredentials) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetRoleCredentialsInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ opPath, opQuery := httpbinding.SplitURI("/federation/credentials")
+ request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath)
+ request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery)
+ request.Method = "GET"
+ restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if err := awsRestjson1_serializeOpHttpBindingsGetRoleCredentialsInput(input, restEncoder); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = restEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+func awsRestjson1_serializeOpHttpBindingsGetRoleCredentialsInput(v *GetRoleCredentialsInput, encoder *httpbinding.Encoder) error {
+ if v == nil {
+ return fmt.Errorf("unsupported serialization of nil %T", v)
+ }
+
+ if v.AccessToken != nil && len(*v.AccessToken) > 0 {
+ locationName := "X-Amz-Sso_bearer_token"
+ encoder.SetHeader(locationName).String(*v.AccessToken)
+ }
+
+ if v.AccountId != nil {
+ encoder.SetQuery("account_id").String(*v.AccountId)
+ }
+
+ if v.RoleName != nil {
+ encoder.SetQuery("role_name").String(*v.RoleName)
+ }
+
+ return nil
+}
+
+type awsRestjson1_serializeOpListAccountRoles struct {
+}
+
+func (*awsRestjson1_serializeOpListAccountRoles) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsRestjson1_serializeOpListAccountRoles) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*ListAccountRolesInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ opPath, opQuery := httpbinding.SplitURI("/assignment/roles")
+ request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath)
+ request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery)
+ request.Method = "GET"
+ restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if err := awsRestjson1_serializeOpHttpBindingsListAccountRolesInput(input, restEncoder); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = restEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+func awsRestjson1_serializeOpHttpBindingsListAccountRolesInput(v *ListAccountRolesInput, encoder *httpbinding.Encoder) error {
+ if v == nil {
+ return fmt.Errorf("unsupported serialization of nil %T", v)
+ }
+
+ if v.AccessToken != nil && len(*v.AccessToken) > 0 {
+ locationName := "X-Amz-Sso_bearer_token"
+ encoder.SetHeader(locationName).String(*v.AccessToken)
+ }
+
+ if v.AccountId != nil {
+ encoder.SetQuery("account_id").String(*v.AccountId)
+ }
+
+ if v.MaxResults != nil {
+ encoder.SetQuery("max_result").Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ encoder.SetQuery("next_token").String(*v.NextToken)
+ }
+
+ return nil
+}
+
+type awsRestjson1_serializeOpListAccounts struct {
+}
+
+func (*awsRestjson1_serializeOpListAccounts) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsRestjson1_serializeOpListAccounts) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*ListAccountsInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ opPath, opQuery := httpbinding.SplitURI("/assignment/accounts")
+ request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath)
+ request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery)
+ request.Method = "GET"
+ restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if err := awsRestjson1_serializeOpHttpBindingsListAccountsInput(input, restEncoder); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = restEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+func awsRestjson1_serializeOpHttpBindingsListAccountsInput(v *ListAccountsInput, encoder *httpbinding.Encoder) error {
+ if v == nil {
+ return fmt.Errorf("unsupported serialization of nil %T", v)
+ }
+
+ if v.AccessToken != nil && len(*v.AccessToken) > 0 {
+ locationName := "X-Amz-Sso_bearer_token"
+ encoder.SetHeader(locationName).String(*v.AccessToken)
+ }
+
+ if v.MaxResults != nil {
+ encoder.SetQuery("max_result").Integer(*v.MaxResults)
+ }
+
+ if v.NextToken != nil {
+ encoder.SetQuery("next_token").String(*v.NextToken)
+ }
+
+ return nil
+}
+
+type awsRestjson1_serializeOpLogout struct {
+}
+
+func (*awsRestjson1_serializeOpLogout) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsRestjson1_serializeOpLogout) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*LogoutInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ opPath, opQuery := httpbinding.SplitURI("/logout")
+ request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath)
+ request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery)
+ request.Method = "POST"
+ restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if err := awsRestjson1_serializeOpHttpBindingsLogoutInput(input, restEncoder); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = restEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+func awsRestjson1_serializeOpHttpBindingsLogoutInput(v *LogoutInput, encoder *httpbinding.Encoder) error {
+ if v == nil {
+ return fmt.Errorf("unsupported serialization of nil %T", v)
+ }
+
+ if v.AccessToken != nil && len(*v.AccessToken) > 0 {
+ locationName := "X-Amz-Sso_bearer_token"
+ encoder.SetHeader(locationName).String(*v.AccessToken)
+ }
+
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/types/errors.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/types/errors.go
new file mode 100644
index 000000000000..1401d585cfed
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/types/errors.go
@@ -0,0 +1,87 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+import (
+ "fmt"
+ smithy "github.com/aws/smithy-go"
+)
+
+// Indicates that a problem occurred with the input to the request. For example, a
+// required parameter might be missing or out of range.
+type InvalidRequestException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidRequestException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidRequestException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidRequestException) ErrorCode() string { return "InvalidRequestException" }
+func (e *InvalidRequestException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The specified resource doesn't exist.
+type ResourceNotFoundException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ResourceNotFoundException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ResourceNotFoundException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ResourceNotFoundException) ErrorCode() string { return "ResourceNotFoundException" }
+func (e *ResourceNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// Indicates that the request is being made too frequently and is more than what
+// the server can handle.
+type TooManyRequestsException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *TooManyRequestsException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *TooManyRequestsException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *TooManyRequestsException) ErrorCode() string { return "TooManyRequestsException" }
+func (e *TooManyRequestsException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// Indicates that the request is not authorized. This can happen due to an invalid
+// access token in the request.
+type UnauthorizedException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *UnauthorizedException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *UnauthorizedException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *UnauthorizedException) ErrorCode() string { return "UnauthorizedException" }
+func (e *UnauthorizedException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/types/types.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/types/types.go
new file mode 100644
index 000000000000..051056b75985
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/types/types.go
@@ -0,0 +1,64 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+import (
+ smithydocument "github.com/aws/smithy-go/document"
+)
+
+// Provides information about your AWS account.
+type AccountInfo struct {
+
+ // The identifier of the AWS account that is assigned to the user.
+ AccountId *string
+
+ // The display name of the AWS account that is assigned to the user.
+ AccountName *string
+
+ // The email address of the AWS account that is assigned to the user.
+ EmailAddress *string
+
+ noSmithyDocumentSerde
+}
+
+// Provides information about the role credentials that are assigned to the user.
+type RoleCredentials struct {
+
+ // The identifier used for the temporary security credentials. For more
+ // information, see Using Temporary Security Credentials to Request Access to AWS
+ // Resources
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_use-resources.html)
+ // in the AWS IAM User Guide.
+ AccessKeyId *string
+
+ // The date on which temporary security credentials expire.
+ Expiration int64
+
+ // The key that is used to sign the request. For more information, see Using
+ // Temporary Security Credentials to Request Access to AWS Resources
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_use-resources.html)
+ // in the AWS IAM User Guide.
+ SecretAccessKey *string
+
+ // The token used for temporary credentials. For more information, see Using
+ // Temporary Security Credentials to Request Access to AWS Resources
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_use-resources.html)
+ // in the AWS IAM User Guide.
+ SessionToken *string
+
+ noSmithyDocumentSerde
+}
+
+// Provides information about the role that is assigned to the user.
+type RoleInfo struct {
+
+ // The identifier of the AWS account assigned to the user.
+ AccountId *string
+
+ // The friendly name of the role that is assigned to the user.
+ RoleName *string
+
+ noSmithyDocumentSerde
+}
+
+type noSmithyDocumentSerde = smithydocument.NoSerde
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sso/validators.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/validators.go
new file mode 100644
index 000000000000..f6bf461f74ba
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sso/validators.go
@@ -0,0 +1,175 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sso
+
+import (
+ "context"
+ "fmt"
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/middleware"
+)
+
+type validateOpGetRoleCredentials struct {
+}
+
+func (*validateOpGetRoleCredentials) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetRoleCredentials) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetRoleCredentialsInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetRoleCredentialsInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpListAccountRoles struct {
+}
+
+func (*validateOpListAccountRoles) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpListAccountRoles) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*ListAccountRolesInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpListAccountRolesInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpListAccounts struct {
+}
+
+func (*validateOpListAccounts) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpListAccounts) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*ListAccountsInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpListAccountsInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpLogout struct {
+}
+
+func (*validateOpLogout) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpLogout) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*LogoutInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpLogoutInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+func addOpGetRoleCredentialsValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetRoleCredentials{}, middleware.After)
+}
+
+func addOpListAccountRolesValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpListAccountRoles{}, middleware.After)
+}
+
+func addOpListAccountsValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpListAccounts{}, middleware.After)
+}
+
+func addOpLogoutValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpLogout{}, middleware.After)
+}
+
+func validateOpGetRoleCredentialsInput(v *GetRoleCredentialsInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetRoleCredentialsInput"}
+ if v.RoleName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RoleName"))
+ }
+ if v.AccountId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("AccountId"))
+ }
+ if v.AccessToken == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("AccessToken"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpListAccountRolesInput(v *ListAccountRolesInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ListAccountRolesInput"}
+ if v.AccessToken == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("AccessToken"))
+ }
+ if v.AccountId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("AccountId"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpListAccountsInput(v *ListAccountsInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "ListAccountsInput"}
+ if v.AccessToken == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("AccessToken"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpLogoutInput(v *LogoutInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "LogoutInput"}
+ if v.AccessToken == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("AccessToken"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/CHANGELOG.md
new file mode 100644
index 000000000000..42c6e11a8887
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/CHANGELOG.md
@@ -0,0 +1,82 @@
+# v1.13.0 (2022-01-07)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.12.0 (2021-12-21)
+
+* **Feature**: Updated to latest service endpoints
+
+# v1.11.1 (2021-12-02)
+
+* **Bug Fix**: Fixes a bug that prevented aws.EndpointResolverWithOptions from being used by the service client. ([#1514](https://github.com/aws/aws-sdk-go-v2/pull/1514))
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.11.0 (2021-11-30)
+
+* **Feature**: API client updated
+
+# v1.10.1 (2021-11-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.10.0 (2021-11-12)
+
+* **Feature**: Service clients now support custom endpoints that have an initial URI path defined.
+
+# v1.9.0 (2021-11-06)
+
+* **Feature**: The SDK now supports configuration of FIPS and DualStack endpoints using environment variables, shared configuration, or programmatically.
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.8.0 (2021-10-21)
+
+* **Feature**: API client updated
+* **Feature**: Updated to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.7.2 (2021-10-11)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.7.1 (2021-09-17)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.7.0 (2021-08-27)
+
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.2 (2021-08-19)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.1 (2021-08-04)
+
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version.
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.6.0 (2021-07-15)
+
+* **Feature**: The ErrorCode method on generated service error types has been corrected to match the API model.
+* **Documentation**: Updated service model to latest revision.
+* **Dependency Update**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.5.0 (2021-06-25)
+
+* **Feature**: API client updated
+* **Feature**: Updated `github.com/aws/smithy-go` to latest version
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.1 (2021-05-20)
+
+* **Dependency Update**: Updated to the latest SDK module versions
+
+# v1.4.0 (2021-05-14)
+
+* **Feature**: Constant has been added to modules to enable runtime version inspection for reporting.
+* **Dependency Update**: Updated to the latest SDK module versions
+
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/LICENSE.txt b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/LICENSE.txt
new file mode 100644
index 000000000000..d64569567334
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/LICENSE.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_client.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_client.go
new file mode 100644
index 000000000000..6614d01b0076
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_client.go
@@ -0,0 +1,397 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/protocol/query"
+ "github.com/aws/aws-sdk-go-v2/aws/retry"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ awshttp "github.com/aws/aws-sdk-go-v2/aws/transport/http"
+ internalConfig "github.com/aws/aws-sdk-go-v2/internal/configsources"
+ presignedurlcust "github.com/aws/aws-sdk-go-v2/service/internal/presigned-url"
+ smithy "github.com/aws/smithy-go"
+ smithydocument "github.com/aws/smithy-go/document"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "net/http"
+ "time"
+)
+
+const ServiceID = "STS"
+const ServiceAPIVersion = "2011-06-15"
+
+// Client provides the API client to make operations call for AWS Security Token
+// Service.
+type Client struct {
+ options Options
+}
+
+// New returns an initialized Client based on the functional options. Provide
+// additional functional options to further configure the behavior of the client,
+// such as changing the client's endpoint or adding custom middleware behavior.
+func New(options Options, optFns ...func(*Options)) *Client {
+ options = options.Copy()
+
+ resolveDefaultLogger(&options)
+
+ resolveRetryer(&options)
+
+ resolveHTTPClient(&options)
+
+ resolveHTTPSignerV4(&options)
+
+ resolveDefaultEndpointConfiguration(&options)
+
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ client := &Client{
+ options: options,
+ }
+
+ return client
+}
+
+type Options struct {
+ // Set of options to modify how an operation is invoked. These apply to all
+ // operations invoked for this client. Use functional options on operation call to
+ // modify this list for per operation behavior.
+ APIOptions []func(*middleware.Stack) error
+
+ // Configures the events that will be sent to the configured logger.
+ ClientLogMode aws.ClientLogMode
+
+ // The credentials object to use when signing requests.
+ Credentials aws.CredentialsProvider
+
+ // The endpoint options to be used when attempting to resolve an endpoint.
+ EndpointOptions EndpointResolverOptions
+
+ // The service endpoint resolver.
+ EndpointResolver EndpointResolver
+
+ // Signature Version 4 (SigV4) Signer
+ HTTPSignerV4 HTTPSignerV4
+
+ // The logger writer interface to write logging messages to.
+ Logger logging.Logger
+
+ // The region to send requests to. (Required)
+ Region string
+
+ // Retryer guides how HTTP requests should be retried in case of recoverable
+ // failures. When nil the API client will use a default retryer.
+ Retryer aws.Retryer
+
+ // The HTTP client to invoke API calls with. Defaults to client's default HTTP
+ // implementation if nil.
+ HTTPClient HTTPClient
+}
+
+// WithAPIOptions returns a functional option for setting the Client's APIOptions
+// option.
+func WithAPIOptions(optFns ...func(*middleware.Stack) error) func(*Options) {
+ return func(o *Options) {
+ o.APIOptions = append(o.APIOptions, optFns...)
+ }
+}
+
+// WithEndpointResolver returns a functional option for setting the Client's
+// EndpointResolver option.
+func WithEndpointResolver(v EndpointResolver) func(*Options) {
+ return func(o *Options) {
+ o.EndpointResolver = v
+ }
+}
+
+type HTTPClient interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// Copy creates a clone where the APIOptions list is deep copied.
+func (o Options) Copy() Options {
+ to := o
+ to.APIOptions = make([]func(*middleware.Stack) error, len(o.APIOptions))
+ copy(to.APIOptions, o.APIOptions)
+ return to
+}
+func (c *Client) invokeOperation(ctx context.Context, opID string, params interface{}, optFns []func(*Options), stackFns ...func(*middleware.Stack, Options) error) (result interface{}, metadata middleware.Metadata, err error) {
+ ctx = middleware.ClearStackValues(ctx)
+ stack := middleware.NewStack(opID, smithyhttp.NewStackRequest)
+ options := c.options.Copy()
+ for _, fn := range optFns {
+ fn(&options)
+ }
+
+ finalizeClientEndpointResolverOptions(&options)
+
+ for _, fn := range stackFns {
+ if err := fn(stack, options); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ for _, fn := range options.APIOptions {
+ if err := fn(stack); err != nil {
+ return nil, metadata, err
+ }
+ }
+
+ handler := middleware.DecorateHandler(smithyhttp.NewClientHandler(options.HTTPClient), stack)
+ result, metadata, err = handler.Handle(ctx, params)
+ if err != nil {
+ err = &smithy.OperationError{
+ ServiceID: ServiceID,
+ OperationName: opID,
+ Err: err,
+ }
+ }
+ return result, metadata, err
+}
+
+type noSmithyDocumentSerde = smithydocument.NoSerde
+
+func resolveDefaultLogger(o *Options) {
+ if o.Logger != nil {
+ return
+ }
+ o.Logger = logging.Nop{}
+}
+
+func addSetLoggerMiddleware(stack *middleware.Stack, o Options) error {
+ return middleware.AddSetLoggerMiddleware(stack, o.Logger)
+}
+
+// NewFromConfig returns a new client from the provided config.
+func NewFromConfig(cfg aws.Config, optFns ...func(*Options)) *Client {
+ opts := Options{
+ Region: cfg.Region,
+ HTTPClient: cfg.HTTPClient,
+ Credentials: cfg.Credentials,
+ APIOptions: cfg.APIOptions,
+ Logger: cfg.Logger,
+ ClientLogMode: cfg.ClientLogMode,
+ }
+ resolveAWSRetryerProvider(cfg, &opts)
+ resolveAWSEndpointResolver(cfg, &opts)
+ resolveUseDualStackEndpoint(cfg, &opts)
+ resolveUseFIPSEndpoint(cfg, &opts)
+ return New(opts, optFns...)
+}
+
+func resolveHTTPClient(o *Options) {
+ if o.HTTPClient != nil {
+ return
+ }
+ o.HTTPClient = awshttp.NewBuildableClient()
+}
+
+func resolveRetryer(o *Options) {
+ if o.Retryer != nil {
+ return
+ }
+ o.Retryer = retry.NewStandard()
+}
+
+func resolveAWSRetryerProvider(cfg aws.Config, o *Options) {
+ if cfg.Retryer == nil {
+ return
+ }
+ o.Retryer = cfg.Retryer()
+}
+
+func resolveAWSEndpointResolver(cfg aws.Config, o *Options) {
+ if cfg.EndpointResolver == nil && cfg.EndpointResolverWithOptions == nil {
+ return
+ }
+ o.EndpointResolver = withEndpointResolver(cfg.EndpointResolver, cfg.EndpointResolverWithOptions, NewDefaultEndpointResolver())
+}
+
+func addClientUserAgent(stack *middleware.Stack) error {
+ return awsmiddleware.AddSDKAgentKeyValue(awsmiddleware.APIMetadata, "sts", goModuleVersion)(stack)
+}
+
+func addHTTPSignerV4Middleware(stack *middleware.Stack, o Options) error {
+ mw := v4.NewSignHTTPRequestMiddleware(v4.SignHTTPRequestMiddlewareOptions{
+ CredentialsProvider: o.Credentials,
+ Signer: o.HTTPSignerV4,
+ LogSigning: o.ClientLogMode.IsSigning(),
+ })
+ return stack.Finalize.Add(mw, middleware.After)
+}
+
+type HTTPSignerV4 interface {
+ SignHTTP(ctx context.Context, credentials aws.Credentials, r *http.Request, payloadHash string, service string, region string, signingTime time.Time, optFns ...func(*v4.SignerOptions)) error
+}
+
+func resolveHTTPSignerV4(o *Options) {
+ if o.HTTPSignerV4 != nil {
+ return
+ }
+ o.HTTPSignerV4 = newDefaultV4Signer(*o)
+}
+
+func newDefaultV4Signer(o Options) *v4.Signer {
+ return v4.NewSigner(func(so *v4.SignerOptions) {
+ so.Logger = o.Logger
+ so.LogSigning = o.ClientLogMode.IsSigning()
+ })
+}
+
+func addRetryMiddlewares(stack *middleware.Stack, o Options) error {
+ mo := retry.AddRetryMiddlewaresOptions{
+ Retryer: o.Retryer,
+ LogRetryAttempts: o.ClientLogMode.IsRetries(),
+ }
+ return retry.AddRetryMiddlewares(stack, mo)
+}
+
+// resolves dual-stack endpoint configuration
+func resolveUseDualStackEndpoint(cfg aws.Config, o *Options) error {
+ if len(cfg.ConfigSources) == 0 {
+ return nil
+ }
+ value, found, err := internalConfig.ResolveUseDualStackEndpoint(context.Background(), cfg.ConfigSources)
+ if err != nil {
+ return err
+ }
+ if found {
+ o.EndpointOptions.UseDualStackEndpoint = value
+ }
+ return nil
+}
+
+// resolves FIPS endpoint configuration
+func resolveUseFIPSEndpoint(cfg aws.Config, o *Options) error {
+ if len(cfg.ConfigSources) == 0 {
+ return nil
+ }
+ value, found, err := internalConfig.ResolveUseFIPSEndpoint(context.Background(), cfg.ConfigSources)
+ if err != nil {
+ return err
+ }
+ if found {
+ o.EndpointOptions.UseFIPSEndpoint = value
+ }
+ return nil
+}
+
+func addRequestIDRetrieverMiddleware(stack *middleware.Stack) error {
+ return awsmiddleware.AddRequestIDRetrieverMiddleware(stack)
+}
+
+func addResponseErrorMiddleware(stack *middleware.Stack) error {
+ return awshttp.AddResponseErrorMiddleware(stack)
+}
+
+// HTTPPresignerV4 represents presigner interface used by presign url client
+type HTTPPresignerV4 interface {
+ PresignHTTP(
+ ctx context.Context, credentials aws.Credentials, r *http.Request,
+ payloadHash string, service string, region string, signingTime time.Time,
+ optFns ...func(*v4.SignerOptions),
+ ) (url string, signedHeader http.Header, err error)
+}
+
+// PresignOptions represents the presign client options
+type PresignOptions struct {
+
+ // ClientOptions are list of functional options to mutate client options used by
+ // the presign client.
+ ClientOptions []func(*Options)
+
+ // Presigner is the presigner used by the presign url client
+ Presigner HTTPPresignerV4
+}
+
+func (o PresignOptions) copy() PresignOptions {
+ clientOptions := make([]func(*Options), len(o.ClientOptions))
+ copy(clientOptions, o.ClientOptions)
+ o.ClientOptions = clientOptions
+ return o
+}
+
+// WithPresignClientFromClientOptions is a helper utility to retrieve a function
+// that takes PresignOption as input
+func WithPresignClientFromClientOptions(optFns ...func(*Options)) func(*PresignOptions) {
+ return withPresignClientFromClientOptions(optFns).options
+}
+
+type withPresignClientFromClientOptions []func(*Options)
+
+func (w withPresignClientFromClientOptions) options(o *PresignOptions) {
+ o.ClientOptions = append(o.ClientOptions, w...)
+}
+
+// PresignClient represents the presign url client
+type PresignClient struct {
+ client *Client
+ options PresignOptions
+}
+
+// NewPresignClient generates a presign client using provided API Client and
+// presign options
+func NewPresignClient(c *Client, optFns ...func(*PresignOptions)) *PresignClient {
+ var options PresignOptions
+ for _, fn := range optFns {
+ fn(&options)
+ }
+ if len(options.ClientOptions) != 0 {
+ c = New(c.options, options.ClientOptions...)
+ }
+
+ if options.Presigner == nil {
+ options.Presigner = newDefaultV4Signer(c.options)
+ }
+
+ return &PresignClient{
+ client: c,
+ options: options,
+ }
+}
+
+func withNopHTTPClientAPIOption(o *Options) {
+ o.HTTPClient = smithyhttp.NopClient{}
+}
+
+type presignConverter PresignOptions
+
+func (c presignConverter) convertToPresignMiddleware(stack *middleware.Stack, options Options) (err error) {
+ stack.Finalize.Clear()
+ stack.Deserialize.Clear()
+ stack.Build.Remove((*awsmiddleware.ClientRequestID)(nil).ID())
+ stack.Build.Remove("UserAgent")
+ pmw := v4.NewPresignHTTPRequestMiddleware(v4.PresignHTTPRequestMiddlewareOptions{
+ CredentialsProvider: options.Credentials,
+ Presigner: c.Presigner,
+ LogSigning: options.ClientLogMode.IsSigning(),
+ })
+ err = stack.Finalize.Add(pmw, middleware.After)
+ if err != nil {
+ return err
+ }
+ // convert request to a GET request
+ err = query.AddAsGetRequestMiddleware(stack)
+ if err != nil {
+ return err
+ }
+ err = presignedurlcust.AddAsIsPresigingMiddleware(stack)
+ if err != nil {
+ return err
+ }
+ return nil
+}
+
+func addRequestResponseLogging(stack *middleware.Stack, o Options) error {
+ return stack.Deserialize.Add(&smithyhttp.RequestResponseLogger{
+ LogRequest: o.ClientLogMode.IsRequest(),
+ LogRequestWithBody: o.ClientLogMode.IsRequestWithBody(),
+ LogResponse: o.ClientLogMode.IsResponse(),
+ LogResponseWithBody: o.ClientLogMode.IsResponseWithBody(),
+ }, middleware.After)
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRole.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRole.go
new file mode 100644
index 000000000000..a0cdc90775a4
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRole.go
@@ -0,0 +1,417 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns a set of temporary security credentials that you can use to access
+// Amazon Web Services resources that you might not normally have access to. These
+// temporary credentials consist of an access key ID, a secret access key, and a
+// security token. Typically, you use AssumeRole within your account or for
+// cross-account access. For a comparison of AssumeRole with other API operations
+// that produce temporary credentials, see Requesting Temporary Security
+// Credentials
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
+// and Comparing the Amazon Web Services STS API operations
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
+// in the IAM User Guide. Permissions The temporary security credentials created by
+// AssumeRole can be used to make API calls to any Amazon Web Services service with
+// the following exception: You cannot call the Amazon Web Services STS
+// GetFederationToken or GetSessionToken API operations. (Optional) You can pass
+// inline or managed session policies
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+// to this operation. You can pass a single JSON policy document to use as an
+// inline session policy. You can also specify up to 10 managed policies to use as
+// managed session policies. The plaintext that you use for both inline and managed
+// session policies can't exceed 2,048 characters. Passing policies to this
+// operation returns new temporary credentials. The resulting session's permissions
+// are the intersection of the role's identity-based policy and the session
+// policies. You can use the role's temporary credentials in subsequent Amazon Web
+// Services API calls to access resources in the account that owns the role. You
+// cannot use session policies to grant more permissions than those allowed by the
+// identity-based policy of the role that is being assumed. For more information,
+// see Session Policies
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+// in the IAM User Guide. When you create a role, you create two policies: A role
+// trust policy that specifies who can assume the role and a permissions policy
+// that specifies what can be done with the role. You specify the trusted principal
+// who is allowed to assume the role in the role trust policy. To assume a role
+// from a different account, your Amazon Web Services account must be trusted by
+// the role. The trust relationship is defined in the role's trust policy when the
+// role is created. That trust policy states which accounts are allowed to delegate
+// that access to users in the account. A user who wants to access a role in a
+// different account must also have permissions that are delegated from the user
+// account administrator. The administrator must attach a policy that allows the
+// user to call AssumeRole for the ARN of the role in the other account. To allow a
+// user to assume a role in the same account, you can do either of the
+// following:
+//
+// * Attach a policy to the user that allows the user to call
+// AssumeRole (as long as the role's trust policy trusts the account).
+//
+// * Add the
+// user as a principal directly in the role's trust policy.
+//
+// You can do either
+// because the role’s trust policy acts as an IAM resource-based policy. When a
+// resource-based policy grants access to a principal in the same account, no
+// additional identity-based policy is required. For more information about trust
+// policies and resource-based policies, see IAM Policies
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html) in the
+// IAM User Guide. Tags (Optional) You can pass tag key-value pairs to your
+// session. These tags are called session tags. For more information about session
+// tags, see Passing Session Tags in STS
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+// IAM User Guide. An administrator must grant you the permissions necessary to
+// pass session tags. The administrator can also create granular permissions to
+// allow you to pass only specific session tags. For more information, see
+// Tutorial: Using Tags for Attribute-Based Access Control
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html)
+// in the IAM User Guide. You can set the session tags as transitive. Transitive
+// tags persist during role chaining. For more information, see Chaining Roles with
+// Session Tags
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
+// in the IAM User Guide. Using MFA with AssumeRole (Optional) You can include
+// multi-factor authentication (MFA) information when you call AssumeRole. This is
+// useful for cross-account scenarios to ensure that the user that assumes the role
+// has been authenticated with an Amazon Web Services MFA device. In that scenario,
+// the trust policy of the role being assumed includes a condition that tests for
+// MFA authentication. If the caller does not include valid MFA information, the
+// request to assume the role is denied. The condition in a trust policy that tests
+// for MFA authentication might look like the following example. "Condition":
+// {"Bool": {"aws:MultiFactorAuthPresent": true}} For more information, see
+// Configuring MFA-Protected API Access
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/MFAProtectedAPI.html) in the
+// IAM User Guide guide. To use MFA with AssumeRole, you pass values for the
+// SerialNumber and TokenCode parameters. The SerialNumber value identifies the
+// user's hardware or virtual MFA device. The TokenCode is the time-based one-time
+// password (TOTP) that the MFA device produces.
+func (c *Client) AssumeRole(ctx context.Context, params *AssumeRoleInput, optFns ...func(*Options)) (*AssumeRoleOutput, error) {
+ if params == nil {
+ params = &AssumeRoleInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "AssumeRole", params, optFns, c.addOperationAssumeRoleMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*AssumeRoleOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type AssumeRoleInput struct {
+
+ // The Amazon Resource Name (ARN) of the role to assume.
+ //
+ // This member is required.
+ RoleArn *string
+
+ // An identifier for the assumed role session. Use the role session name to
+ // uniquely identify a session when the same role is assumed by different
+ // principals or for different reasons. In cross-account scenarios, the role
+ // session name is visible to, and can be logged by the account that owns the role.
+ // The role session name is also used in the ARN of the assumed role principal.
+ // This means that subsequent cross-account API requests that use the temporary
+ // security credentials will expose the role session name to the external account
+ // in their CloudTrail logs. The regex used to validate this parameter is a string
+ // of characters consisting of upper- and lower-case alphanumeric characters with
+ // no spaces. You can also include underscores or any of the following characters:
+ // =,.@-
+ //
+ // This member is required.
+ RoleSessionName *string
+
+ // The duration, in seconds, of the role session. The value specified can range
+ // from 900 seconds (15 minutes) up to the maximum session duration set for the
+ // role. The maximum session duration setting can have a value from 1 hour to 12
+ // hours. If you specify a value higher than this setting or the administrator
+ // setting (whichever is lower), the operation fails. For example, if you specify a
+ // session duration of 12 hours, but your administrator set the maximum session
+ // duration to 6 hours, your operation fails. Role chaining limits your Amazon Web
+ // Services CLI or Amazon Web Services API role session to a maximum of one hour.
+ // When you use the AssumeRole API operation to assume a role, you can specify the
+ // duration of your role session with the DurationSeconds parameter. You can
+ // specify a parameter value of up to 43200 seconds (12 hours), depending on the
+ // maximum session duration setting for your role. However, if you assume a role
+ // using role chaining and provide a DurationSeconds parameter value greater than
+ // one hour, the operation fails. To learn how to view the maximum value for your
+ // role, see View the Maximum Session Duration Setting for a Role
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
+ // in the IAM User Guide. By default, the value is set to 3600 seconds. The
+ // DurationSeconds parameter is separate from the duration of a console session
+ // that you might request using the returned credentials. The request to the
+ // federation endpoint for a console sign-in token takes a SessionDuration
+ // parameter that specifies the maximum length of the console session. For more
+ // information, see Creating a URL that Enables Federated Users to Access the
+ // Amazon Web Services Management Console
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html)
+ // in the IAM User Guide.
+ DurationSeconds *int32
+
+ // A unique identifier that might be required when you assume a role in another
+ // account. If the administrator of the account to which the role belongs provided
+ // you with an external ID, then provide that value in the ExternalId parameter.
+ // This value can be any string, such as a passphrase or account number. A
+ // cross-account role is usually set up to trust everyone in an account. Therefore,
+ // the administrator of the trusting account might send an external ID to the
+ // administrator of the trusted account. That way, only someone with the ID can
+ // assume the role, rather than everyone in the account. For more information about
+ // the external ID, see How to Use an External ID When Granting Access to Your
+ // Amazon Web Services Resources to a Third Party
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-user_externalid.html)
+ // in the IAM User Guide. The regex used to validate this parameter is a string of
+ // characters consisting of upper- and lower-case alphanumeric characters with no
+ // spaces. You can also include underscores or any of the following characters:
+ // =,.@:/-
+ ExternalId *string
+
+ // An IAM policy in JSON format that you want to use as an inline session policy.
+ // This parameter is optional. Passing policies to this operation returns new
+ // temporary credentials. The resulting session's permissions are the intersection
+ // of the role's identity-based policy and the session policies. You can use the
+ // role's temporary credentials in subsequent Amazon Web Services API calls to
+ // access resources in the account that owns the role. You cannot use session
+ // policies to grant more permissions than those allowed by the identity-based
+ // policy of the role that is being assumed. For more information, see Session
+ // Policies
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide. The plaintext that you use for both inline and managed
+ // session policies can't exceed 2,048 characters. The JSON policy characters can
+ // be any ASCII character from the space character to the end of the valid
+ // character list (\u0020 through \u00FF). It can also include the tab (\u0009),
+ // linefeed (\u000A), and carriage return (\u000D) characters. An Amazon Web
+ // Services conversion compresses the passed session policies and session tags into
+ // a packed binary format that has a separate limit. Your request can fail for this
+ // limit even if your plaintext meets the other requirements. The PackedPolicySize
+ // response element indicates by percentage how close the policies and tags for
+ // your request are to the upper size limit.
+ Policy *string
+
+ // The Amazon Resource Names (ARNs) of the IAM managed policies that you want to
+ // use as managed session policies. The policies must exist in the same account as
+ // the role. This parameter is optional. You can provide up to 10 managed policy
+ // ARNs. However, the plaintext that you use for both inline and managed session
+ // policies can't exceed 2,048 characters. For more information about ARNs, see
+ // Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces
+ // (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) in
+ // the Amazon Web Services General Reference. An Amazon Web Services conversion
+ // compresses the passed session policies and session tags into a packed binary
+ // format that has a separate limit. Your request can fail for this limit even if
+ // your plaintext meets the other requirements. The PackedPolicySize response
+ // element indicates by percentage how close the policies and tags for your request
+ // are to the upper size limit. Passing policies to this operation returns new
+ // temporary credentials. The resulting session's permissions are the intersection
+ // of the role's identity-based policy and the session policies. You can use the
+ // role's temporary credentials in subsequent Amazon Web Services API calls to
+ // access resources in the account that owns the role. You cannot use session
+ // policies to grant more permissions than those allowed by the identity-based
+ // policy of the role that is being assumed. For more information, see Session
+ // Policies
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide.
+ PolicyArns []types.PolicyDescriptorType
+
+ // The identification number of the MFA device that is associated with the user who
+ // is making the AssumeRole call. Specify this value if the trust policy of the
+ // role being assumed includes a condition that requires MFA authentication. The
+ // value is either the serial number for a hardware device (such as GAHT12345678)
+ // or an Amazon Resource Name (ARN) for a virtual device (such as
+ // arn:aws:iam::123456789012:mfa/user). The regex used to validate this parameter
+ // is a string of characters consisting of upper- and lower-case alphanumeric
+ // characters with no spaces. You can also include underscores or any of the
+ // following characters: =,.@-
+ SerialNumber *string
+
+ // The source identity specified by the principal that is calling the AssumeRole
+ // operation. You can require users to specify a source identity when they assume a
+ // role. You do this by using the sts:SourceIdentity condition key in a role trust
+ // policy. You can use source identity information in CloudTrail logs to determine
+ // who took actions with a role. You can use the aws:SourceIdentity condition key
+ // to further control access to Amazon Web Services resources based on the value of
+ // source identity. For more information about using source identity, see Monitor
+ // and control actions taken with assumed roles
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_monitor.html)
+ // in the IAM User Guide. The regex used to validate this parameter is a string of
+ // characters consisting of upper- and lower-case alphanumeric characters with no
+ // spaces. You can also include underscores or any of the following characters:
+ // =,.@-. You cannot use a value that begins with the text aws:. This prefix is
+ // reserved for Amazon Web Services internal use.
+ SourceIdentity *string
+
+ // A list of session tags that you want to pass. Each session tag consists of a key
+ // name and an associated value. For more information about session tags, see
+ // Tagging Amazon Web Services STS Sessions
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+ // IAM User Guide. This parameter is optional. You can pass up to 50 session tags.
+ // The plaintext session tag keys can’t exceed 128 characters, and the values can’t
+ // exceed 256 characters. For these and additional limits, see IAM and STS
+ // Character Limits
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
+ // in the IAM User Guide. An Amazon Web Services conversion compresses the passed
+ // session policies and session tags into a packed binary format that has a
+ // separate limit. Your request can fail for this limit even if your plaintext
+ // meets the other requirements. The PackedPolicySize response element indicates by
+ // percentage how close the policies and tags for your request are to the upper
+ // size limit. You can pass a session tag with the same key as a tag that is
+ // already attached to the role. When you do, session tags override a role tag with
+ // the same key. Tag key–value pairs are not case sensitive, but case is preserved.
+ // This means that you cannot have separate Department and department tag keys.
+ // Assume that the role has the Department=Marketing tag and you pass the
+ // department=engineering session tag. Department and department are not saved as
+ // separate tags, and the session tag passed in the request takes precedence over
+ // the role tag. Additionally, if you used temporary credentials to perform this
+ // operation, the new session inherits any transitive session tags from the calling
+ // session. If you pass a session tag with the same key as an inherited tag, the
+ // operation fails. To view the inherited tags for a session, see the CloudTrail
+ // logs. For more information, see Viewing Session Tags in CloudTrail
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/session-tags.html#id_session-tags_ctlogs)
+ // in the IAM User Guide.
+ Tags []types.Tag
+
+ // The value provided by the MFA device, if the trust policy of the role being
+ // assumed requires MFA. (In other words, if the policy includes a condition that
+ // tests for MFA). If the role being assumed requires MFA and if the TokenCode
+ // value is missing or expired, the AssumeRole call returns an "access denied"
+ // error. The format for this parameter, as described by its regex pattern, is a
+ // sequence of six numeric digits.
+ TokenCode *string
+
+ // A list of keys for session tags that you want to set as transitive. If you set a
+ // tag key as transitive, the corresponding key and value passes to subsequent
+ // sessions in a role chain. For more information, see Chaining Roles with Session
+ // Tags
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
+ // in the IAM User Guide. This parameter is optional. When you set session tags as
+ // transitive, the session policy and session tags packed binary limit is not
+ // affected. If you choose not to specify a transitive tag key, then no tags are
+ // passed from this session to any subsequent sessions.
+ TransitiveTagKeys []string
+
+ noSmithyDocumentSerde
+}
+
+// Contains the response to a successful AssumeRole request, including temporary
+// Amazon Web Services credentials that can be used to make Amazon Web Services
+// requests.
+type AssumeRoleOutput struct {
+
+ // The Amazon Resource Name (ARN) and the assumed role ID, which are identifiers
+ // that you can use to refer to the resulting temporary security credentials. For
+ // example, you can reference these credentials as a principal in a resource-based
+ // policy by using the ARN or assumed role ID. The ARN and ID include the
+ // RoleSessionName that you specified when you called AssumeRole.
+ AssumedRoleUser *types.AssumedRoleUser
+
+ // The temporary security credentials, which include an access key ID, a secret
+ // access key, and a security (or session) token. The size of the security token
+ // that STS API operations return is not fixed. We strongly recommend that you make
+ // no assumptions about the maximum size.
+ Credentials *types.Credentials
+
+ // A percentage value that indicates the packed size of the session policies and
+ // session tags combined passed in the request. The request fails if the packed
+ // size is greater than 100 percent, which means the policies and tags exceeded the
+ // allowed space.
+ PackedPolicySize *int32
+
+ // The source identity specified by the principal that is calling the AssumeRole
+ // operation. You can require users to specify a source identity when they assume a
+ // role. You do this by using the sts:SourceIdentity condition key in a role trust
+ // policy. You can use source identity information in CloudTrail logs to determine
+ // who took actions with a role. You can use the aws:SourceIdentity condition key
+ // to further control access to Amazon Web Services resources based on the value of
+ // source identity. For more information about using source identity, see Monitor
+ // and control actions taken with assumed roles
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_monitor.html)
+ // in the IAM User Guide. The regex used to validate this parameter is a string of
+ // characters consisting of upper- and lower-case alphanumeric characters with no
+ // spaces. You can also include underscores or any of the following characters:
+ // =,.@-
+ SourceIdentity *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationAssumeRoleMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsquery_serializeOpAssumeRole{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsquery_deserializeOpAssumeRole{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpAssumeRoleValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opAssumeRole(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opAssumeRole(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "sts",
+ OperationName: "AssumeRole",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRoleWithSAML.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRoleWithSAML.go
new file mode 100644
index 000000000000..e12315e4c140
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRoleWithSAML.go
@@ -0,0 +1,377 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns a set of temporary security credentials for users who have been
+// authenticated via a SAML authentication response. This operation provides a
+// mechanism for tying an enterprise identity store or directory to role-based
+// Amazon Web Services access without user-specific credentials or configuration.
+// For a comparison of AssumeRoleWithSAML with the other API operations that
+// produce temporary credentials, see Requesting Temporary Security Credentials
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
+// and Comparing the Amazon Web Services STS API operations
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
+// in the IAM User Guide. The temporary security credentials returned by this
+// operation consist of an access key ID, a secret access key, and a security
+// token. Applications can use these temporary security credentials to sign calls
+// to Amazon Web Services services. Session Duration By default, the temporary
+// security credentials created by AssumeRoleWithSAML last for one hour. However,
+// you can use the optional DurationSeconds parameter to specify the duration of
+// your session. Your role session lasts for the duration that you specify, or
+// until the time specified in the SAML authentication response's
+// SessionNotOnOrAfter value, whichever is shorter. You can provide a
+// DurationSeconds value from 900 seconds (15 minutes) up to the maximum session
+// duration setting for the role. This setting can have a value from 1 hour to 12
+// hours. To learn how to view the maximum value for your role, see View the
+// Maximum Session Duration Setting for a Role
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
+// in the IAM User Guide. The maximum session duration limit applies when you use
+// the AssumeRole* API operations or the assume-role* CLI commands. However the
+// limit does not apply when you use those operations to create a console URL. For
+// more information, see Using IAM Roles
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) in the IAM
+// User Guide. Role chaining
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_terms-and-concepts.html#iam-term-role-chaining)
+// limits your CLI or Amazon Web Services API role session to a maximum of one
+// hour. When you use the AssumeRole API operation to assume a role, you can
+// specify the duration of your role session with the DurationSeconds parameter.
+// You can specify a parameter value of up to 43200 seconds (12 hours), depending
+// on the maximum session duration setting for your role. However, if you assume a
+// role using role chaining and provide a DurationSeconds parameter value greater
+// than one hour, the operation fails. Permissions The temporary security
+// credentials created by AssumeRoleWithSAML can be used to make API calls to any
+// Amazon Web Services service with the following exception: you cannot call the
+// STS GetFederationToken or GetSessionToken API operations. (Optional) You can
+// pass inline or managed session policies
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+// to this operation. You can pass a single JSON policy document to use as an
+// inline session policy. You can also specify up to 10 managed policies to use as
+// managed session policies. The plaintext that you use for both inline and managed
+// session policies can't exceed 2,048 characters. Passing policies to this
+// operation returns new temporary credentials. The resulting session's permissions
+// are the intersection of the role's identity-based policy and the session
+// policies. You can use the role's temporary credentials in subsequent Amazon Web
+// Services API calls to access resources in the account that owns the role. You
+// cannot use session policies to grant more permissions than those allowed by the
+// identity-based policy of the role that is being assumed. For more information,
+// see Session Policies
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+// in the IAM User Guide. Calling AssumeRoleWithSAML does not require the use of
+// Amazon Web Services security credentials. The identity of the caller is
+// validated by using keys in the metadata document that is uploaded for the SAML
+// provider entity for your identity provider. Calling AssumeRoleWithSAML can
+// result in an entry in your CloudTrail logs. The entry includes the value in the
+// NameID element of the SAML assertion. We recommend that you use a NameIDType
+// that is not associated with any personally identifiable information (PII). For
+// example, you could instead use the persistent identifier
+// (urn:oasis:names:tc:SAML:2.0:nameid-format:persistent). Tags (Optional) You can
+// configure your IdP to pass attributes into your SAML assertion as session tags.
+// Each session tag consists of a key name and an associated value. For more
+// information about session tags, see Passing Session Tags in STS
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+// IAM User Guide. You can pass up to 50 session tags. The plaintext session tag
+// keys can’t exceed 128 characters and the values can’t exceed 256 characters. For
+// these and additional limits, see IAM and STS Character Limits
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
+// in the IAM User Guide. An Amazon Web Services conversion compresses the passed
+// session policies and session tags into a packed binary format that has a
+// separate limit. Your request can fail for this limit even if your plaintext
+// meets the other requirements. The PackedPolicySize response element indicates by
+// percentage how close the policies and tags for your request are to the upper
+// size limit. You can pass a session tag with the same key as a tag that is
+// attached to the role. When you do, session tags override the role's tags with
+// the same key. An administrator must grant you the permissions necessary to pass
+// session tags. The administrator can also create granular permissions to allow
+// you to pass only specific session tags. For more information, see Tutorial:
+// Using Tags for Attribute-Based Access Control
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html)
+// in the IAM User Guide. You can set the session tags as transitive. Transitive
+// tags persist during role chaining. For more information, see Chaining Roles with
+// Session Tags
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
+// in the IAM User Guide. SAML Configuration Before your application can call
+// AssumeRoleWithSAML, you must configure your SAML identity provider (IdP) to
+// issue the claims required by Amazon Web Services. Additionally, you must use
+// Identity and Access Management (IAM) to create a SAML provider entity in your
+// Amazon Web Services account that represents your identity provider. You must
+// also create an IAM role that specifies this SAML provider in its trust policy.
+// For more information, see the following resources:
+//
+// * About SAML 2.0-based
+// Federation
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_saml.html)
+// in the IAM User Guide.
+//
+// * Creating SAML Identity Providers
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml.html)
+// in the IAM User Guide.
+//
+// * Configuring a Relying Party and Claims
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml_relying-party.html)
+// in the IAM User Guide.
+//
+// * Creating a Role for SAML 2.0 Federation
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-idp_saml.html)
+// in the IAM User Guide.
+func (c *Client) AssumeRoleWithSAML(ctx context.Context, params *AssumeRoleWithSAMLInput, optFns ...func(*Options)) (*AssumeRoleWithSAMLOutput, error) {
+ if params == nil {
+ params = &AssumeRoleWithSAMLInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "AssumeRoleWithSAML", params, optFns, c.addOperationAssumeRoleWithSAMLMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*AssumeRoleWithSAMLOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type AssumeRoleWithSAMLInput struct {
+
+ // The Amazon Resource Name (ARN) of the SAML provider in IAM that describes the
+ // IdP.
+ //
+ // This member is required.
+ PrincipalArn *string
+
+ // The Amazon Resource Name (ARN) of the role that the caller is assuming.
+ //
+ // This member is required.
+ RoleArn *string
+
+ // The base64 encoded SAML authentication response provided by the IdP. For more
+ // information, see Configuring a Relying Party and Adding Claims
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/create-role-saml-IdP-tasks.html)
+ // in the IAM User Guide.
+ //
+ // This member is required.
+ SAMLAssertion *string
+
+ // The duration, in seconds, of the role session. Your role session lasts for the
+ // duration that you specify for the DurationSeconds parameter, or until the time
+ // specified in the SAML authentication response's SessionNotOnOrAfter value,
+ // whichever is shorter. You can provide a DurationSeconds value from 900 seconds
+ // (15 minutes) up to the maximum session duration setting for the role. This
+ // setting can have a value from 1 hour to 12 hours. If you specify a value higher
+ // than this setting, the operation fails. For example, if you specify a session
+ // duration of 12 hours, but your administrator set the maximum session duration to
+ // 6 hours, your operation fails. To learn how to view the maximum value for your
+ // role, see View the Maximum Session Duration Setting for a Role
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
+ // in the IAM User Guide. By default, the value is set to 3600 seconds. The
+ // DurationSeconds parameter is separate from the duration of a console session
+ // that you might request using the returned credentials. The request to the
+ // federation endpoint for a console sign-in token takes a SessionDuration
+ // parameter that specifies the maximum length of the console session. For more
+ // information, see Creating a URL that Enables Federated Users to Access the
+ // Amazon Web Services Management Console
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html)
+ // in the IAM User Guide.
+ DurationSeconds *int32
+
+ // An IAM policy in JSON format that you want to use as an inline session policy.
+ // This parameter is optional. Passing policies to this operation returns new
+ // temporary credentials. The resulting session's permissions are the intersection
+ // of the role's identity-based policy and the session policies. You can use the
+ // role's temporary credentials in subsequent Amazon Web Services API calls to
+ // access resources in the account that owns the role. You cannot use session
+ // policies to grant more permissions than those allowed by the identity-based
+ // policy of the role that is being assumed. For more information, see Session
+ // Policies
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide. The plaintext that you use for both inline and managed
+ // session policies can't exceed 2,048 characters. The JSON policy characters can
+ // be any ASCII character from the space character to the end of the valid
+ // character list (\u0020 through \u00FF). It can also include the tab (\u0009),
+ // linefeed (\u000A), and carriage return (\u000D) characters. An Amazon Web
+ // Services conversion compresses the passed session policies and session tags into
+ // a packed binary format that has a separate limit. Your request can fail for this
+ // limit even if your plaintext meets the other requirements. The PackedPolicySize
+ // response element indicates by percentage how close the policies and tags for
+ // your request are to the upper size limit.
+ Policy *string
+
+ // The Amazon Resource Names (ARNs) of the IAM managed policies that you want to
+ // use as managed session policies. The policies must exist in the same account as
+ // the role. This parameter is optional. You can provide up to 10 managed policy
+ // ARNs. However, the plaintext that you use for both inline and managed session
+ // policies can't exceed 2,048 characters. For more information about ARNs, see
+ // Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces
+ // (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) in
+ // the Amazon Web Services General Reference. An Amazon Web Services conversion
+ // compresses the passed session policies and session tags into a packed binary
+ // format that has a separate limit. Your request can fail for this limit even if
+ // your plaintext meets the other requirements. The PackedPolicySize response
+ // element indicates by percentage how close the policies and tags for your request
+ // are to the upper size limit. Passing policies to this operation returns new
+ // temporary credentials. The resulting session's permissions are the intersection
+ // of the role's identity-based policy and the session policies. You can use the
+ // role's temporary credentials in subsequent Amazon Web Services API calls to
+ // access resources in the account that owns the role. You cannot use session
+ // policies to grant more permissions than those allowed by the identity-based
+ // policy of the role that is being assumed. For more information, see Session
+ // Policies
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide.
+ PolicyArns []types.PolicyDescriptorType
+
+ noSmithyDocumentSerde
+}
+
+// Contains the response to a successful AssumeRoleWithSAML request, including
+// temporary Amazon Web Services credentials that can be used to make Amazon Web
+// Services requests.
+type AssumeRoleWithSAMLOutput struct {
+
+ // The identifiers for the temporary security credentials that the operation
+ // returns.
+ AssumedRoleUser *types.AssumedRoleUser
+
+ // The value of the Recipient attribute of the SubjectConfirmationData element of
+ // the SAML assertion.
+ Audience *string
+
+ // The temporary security credentials, which include an access key ID, a secret
+ // access key, and a security (or session) token. The size of the security token
+ // that STS API operations return is not fixed. We strongly recommend that you make
+ // no assumptions about the maximum size.
+ Credentials *types.Credentials
+
+ // The value of the Issuer element of the SAML assertion.
+ Issuer *string
+
+ // A hash value based on the concatenation of the following:
+ //
+ // * The Issuer response
+ // value.
+ //
+ // * The Amazon Web Services account ID.
+ //
+ // * The friendly name (the last
+ // part of the ARN) of the SAML provider in IAM.
+ //
+ // The combination of NameQualifier
+ // and Subject can be used to uniquely identify a federated user. The following
+ // pseudocode shows how the hash value is calculated: BASE64 ( SHA1 (
+ // "https://example.com/saml" + "123456789012" + "/MySAMLIdP" ) )
+ NameQualifier *string
+
+ // A percentage value that indicates the packed size of the session policies and
+ // session tags combined passed in the request. The request fails if the packed
+ // size is greater than 100 percent, which means the policies and tags exceeded the
+ // allowed space.
+ PackedPolicySize *int32
+
+ // The value in the SourceIdentity attribute in the SAML assertion. You can require
+ // users to set a source identity value when they assume a role. You do this by
+ // using the sts:SourceIdentity condition key in a role trust policy. That way,
+ // actions that are taken with the role are associated with that user. After the
+ // source identity is set, the value cannot be changed. It is present in the
+ // request for all actions that are taken by the role and persists across chained
+ // role
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_terms-and-concepts#iam-term-role-chaining)
+ // sessions. You can configure your SAML identity provider to use an attribute
+ // associated with your users, like user name or email, as the source identity when
+ // calling AssumeRoleWithSAML. You do this by adding an attribute to the SAML
+ // assertion. For more information about using source identity, see Monitor and
+ // control actions taken with assumed roles
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_monitor.html)
+ // in the IAM User Guide. The regex used to validate this parameter is a string of
+ // characters consisting of upper- and lower-case alphanumeric characters with no
+ // spaces. You can also include underscores or any of the following characters:
+ // =,.@-
+ SourceIdentity *string
+
+ // The value of the NameID element in the Subject element of the SAML assertion.
+ Subject *string
+
+ // The format of the name ID, as defined by the Format attribute in the NameID
+ // element of the SAML assertion. Typical examples of the format are transient or
+ // persistent. If the format includes the prefix
+ // urn:oasis:names:tc:SAML:2.0:nameid-format, that prefix is removed. For example,
+ // urn:oasis:names:tc:SAML:2.0:nameid-format:transient is returned as transient. If
+ // the format includes any other prefix, the format is returned with no
+ // modifications.
+ SubjectType *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationAssumeRoleWithSAMLMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsquery_serializeOpAssumeRoleWithSAML{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsquery_deserializeOpAssumeRoleWithSAML{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpAssumeRoleWithSAMLValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opAssumeRoleWithSAML(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opAssumeRoleWithSAML(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "sts",
+ OperationName: "AssumeRoleWithSAML",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRoleWithWebIdentity.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRoleWithWebIdentity.go
new file mode 100644
index 000000000000..240fa1b88275
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_AssumeRoleWithWebIdentity.go
@@ -0,0 +1,393 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns a set of temporary security credentials for users who have been
+// authenticated in a mobile or web application with a web identity provider.
+// Example providers include Amazon Cognito, Login with Amazon, Facebook, Google,
+// or any OpenID Connect-compatible identity provider. For mobile applications, we
+// recommend that you use Amazon Cognito. You can use Amazon Cognito with the
+// Amazon Web Services SDK for iOS Developer Guide
+// (http://aws.amazon.com/sdkforios/) and the Amazon Web Services SDK for Android
+// Developer Guide (http://aws.amazon.com/sdkforandroid/) to uniquely identify a
+// user. You can also supply the user with a consistent identity throughout the
+// lifetime of an application. To learn more about Amazon Cognito, see Amazon
+// Cognito Overview
+// (https://docs.aws.amazon.com/mobile/sdkforandroid/developerguide/cognito-auth.html#d0e840)
+// in Amazon Web Services SDK for Android Developer Guide and Amazon Cognito
+// Overview
+// (https://docs.aws.amazon.com/mobile/sdkforios/developerguide/cognito-auth.html#d0e664)
+// in the Amazon Web Services SDK for iOS Developer Guide. Calling
+// AssumeRoleWithWebIdentity does not require the use of Amazon Web Services
+// security credentials. Therefore, you can distribute an application (for example,
+// on mobile devices) that requests temporary security credentials without
+// including long-term Amazon Web Services credentials in the application. You also
+// don't need to deploy server-based proxy services that use long-term Amazon Web
+// Services credentials. Instead, the identity of the caller is validated by using
+// a token from the web identity provider. For a comparison of
+// AssumeRoleWithWebIdentity with the other API operations that produce temporary
+// credentials, see Requesting Temporary Security Credentials
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
+// and Comparing the Amazon Web Services STS API operations
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
+// in the IAM User Guide. The temporary security credentials returned by this API
+// consist of an access key ID, a secret access key, and a security token.
+// Applications can use these temporary security credentials to sign calls to
+// Amazon Web Services service API operations. Session Duration By default, the
+// temporary security credentials created by AssumeRoleWithWebIdentity last for one
+// hour. However, you can use the optional DurationSeconds parameter to specify the
+// duration of your session. You can provide a value from 900 seconds (15 minutes)
+// up to the maximum session duration setting for the role. This setting can have a
+// value from 1 hour to 12 hours. To learn how to view the maximum value for your
+// role, see View the Maximum Session Duration Setting for a Role
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
+// in the IAM User Guide. The maximum session duration limit applies when you use
+// the AssumeRole* API operations or the assume-role* CLI commands. However the
+// limit does not apply when you use those operations to create a console URL. For
+// more information, see Using IAM Roles
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) in the IAM
+// User Guide. Permissions The temporary security credentials created by
+// AssumeRoleWithWebIdentity can be used to make API calls to any Amazon Web
+// Services service with the following exception: you cannot call the STS
+// GetFederationToken or GetSessionToken API operations. (Optional) You can pass
+// inline or managed session policies
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+// to this operation. You can pass a single JSON policy document to use as an
+// inline session policy. You can also specify up to 10 managed policies to use as
+// managed session policies. The plaintext that you use for both inline and managed
+// session policies can't exceed 2,048 characters. Passing policies to this
+// operation returns new temporary credentials. The resulting session's permissions
+// are the intersection of the role's identity-based policy and the session
+// policies. You can use the role's temporary credentials in subsequent Amazon Web
+// Services API calls to access resources in the account that owns the role. You
+// cannot use session policies to grant more permissions than those allowed by the
+// identity-based policy of the role that is being assumed. For more information,
+// see Session Policies
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+// in the IAM User Guide. Tags (Optional) You can configure your IdP to pass
+// attributes into your web identity token as session tags. Each session tag
+// consists of a key name and an associated value. For more information about
+// session tags, see Passing Session Tags in STS
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+// IAM User Guide. You can pass up to 50 session tags. The plaintext session tag
+// keys can’t exceed 128 characters and the values can’t exceed 256 characters. For
+// these and additional limits, see IAM and STS Character Limits
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
+// in the IAM User Guide. An Amazon Web Services conversion compresses the passed
+// session policies and session tags into a packed binary format that has a
+// separate limit. Your request can fail for this limit even if your plaintext
+// meets the other requirements. The PackedPolicySize response element indicates by
+// percentage how close the policies and tags for your request are to the upper
+// size limit. You can pass a session tag with the same key as a tag that is
+// attached to the role. When you do, the session tag overrides the role tag with
+// the same key. An administrator must grant you the permissions necessary to pass
+// session tags. The administrator can also create granular permissions to allow
+// you to pass only specific session tags. For more information, see Tutorial:
+// Using Tags for Attribute-Based Access Control
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html)
+// in the IAM User Guide. You can set the session tags as transitive. Transitive
+// tags persist during role chaining. For more information, see Chaining Roles with
+// Session Tags
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
+// in the IAM User Guide. Identities Before your application can call
+// AssumeRoleWithWebIdentity, you must have an identity token from a supported
+// identity provider and create a role that the application can assume. The role
+// that your application assumes must trust the identity provider that is
+// associated with the identity token. In other words, the identity provider must
+// be specified in the role's trust policy. Calling AssumeRoleWithWebIdentity can
+// result in an entry in your CloudTrail logs. The entry includes the Subject
+// (http://openid.net/specs/openid-connect-core-1_0.html#Claims) of the provided
+// web identity token. We recommend that you avoid using any personally
+// identifiable information (PII) in this field. For example, you could instead use
+// a GUID or a pairwise identifier, as suggested in the OIDC specification
+// (http://openid.net/specs/openid-connect-core-1_0.html#SubjectIDTypes). For more
+// information about how to use web identity federation and the
+// AssumeRoleWithWebIdentity API, see the following resources:
+//
+// * Using Web
+// Identity Federation API Operations for Mobile Apps
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_oidc_manual.html)
+// and Federation Through a Web-based Identity Provider
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity).
+//
+// *
+// Web Identity Federation Playground
+// (https://aws.amazon.com/blogs/aws/the-aws-web-identity-federation-playground/).
+// Walk through the process of authenticating through Login with Amazon, Facebook,
+// or Google, getting temporary security credentials, and then using those
+// credentials to make a request to Amazon Web Services.
+//
+// * Amazon Web Services SDK
+// for iOS Developer Guide (http://aws.amazon.com/sdkforios/) and Amazon Web
+// Services SDK for Android Developer Guide (http://aws.amazon.com/sdkforandroid/).
+// These toolkits contain sample apps that show how to invoke the identity
+// providers. The toolkits then show how to use the information from these
+// providers to get and use temporary security credentials.
+//
+// * Web Identity
+// Federation with Mobile Applications
+// (http://aws.amazon.com/articles/web-identity-federation-with-mobile-applications).
+// This article discusses web identity federation and shows an example of how to
+// use web identity federation to get access to content in Amazon S3.
+func (c *Client) AssumeRoleWithWebIdentity(ctx context.Context, params *AssumeRoleWithWebIdentityInput, optFns ...func(*Options)) (*AssumeRoleWithWebIdentityOutput, error) {
+ if params == nil {
+ params = &AssumeRoleWithWebIdentityInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "AssumeRoleWithWebIdentity", params, optFns, c.addOperationAssumeRoleWithWebIdentityMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*AssumeRoleWithWebIdentityOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type AssumeRoleWithWebIdentityInput struct {
+
+ // The Amazon Resource Name (ARN) of the role that the caller is assuming.
+ //
+ // This member is required.
+ RoleArn *string
+
+ // An identifier for the assumed role session. Typically, you pass the name or
+ // identifier that is associated with the user who is using your application. That
+ // way, the temporary security credentials that your application will use are
+ // associated with that user. This session name is included as part of the ARN and
+ // assumed role ID in the AssumedRoleUser response element. The regex used to
+ // validate this parameter is a string of characters consisting of upper- and
+ // lower-case alphanumeric characters with no spaces. You can also include
+ // underscores or any of the following characters: =,.@-
+ //
+ // This member is required.
+ RoleSessionName *string
+
+ // The OAuth 2.0 access token or OpenID Connect ID token that is provided by the
+ // identity provider. Your application must get this token by authenticating the
+ // user who is using your application with a web identity provider before the
+ // application makes an AssumeRoleWithWebIdentity call.
+ //
+ // This member is required.
+ WebIdentityToken *string
+
+ // The duration, in seconds, of the role session. The value can range from 900
+ // seconds (15 minutes) up to the maximum session duration setting for the role.
+ // This setting can have a value from 1 hour to 12 hours. If you specify a value
+ // higher than this setting, the operation fails. For example, if you specify a
+ // session duration of 12 hours, but your administrator set the maximum session
+ // duration to 6 hours, your operation fails. To learn how to view the maximum
+ // value for your role, see View the Maximum Session Duration Setting for a Role
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
+ // in the IAM User Guide. By default, the value is set to 3600 seconds. The
+ // DurationSeconds parameter is separate from the duration of a console session
+ // that you might request using the returned credentials. The request to the
+ // federation endpoint for a console sign-in token takes a SessionDuration
+ // parameter that specifies the maximum length of the console session. For more
+ // information, see Creating a URL that Enables Federated Users to Access the
+ // Amazon Web Services Management Console
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html)
+ // in the IAM User Guide.
+ DurationSeconds *int32
+
+ // An IAM policy in JSON format that you want to use as an inline session policy.
+ // This parameter is optional. Passing policies to this operation returns new
+ // temporary credentials. The resulting session's permissions are the intersection
+ // of the role's identity-based policy and the session policies. You can use the
+ // role's temporary credentials in subsequent Amazon Web Services API calls to
+ // access resources in the account that owns the role. You cannot use session
+ // policies to grant more permissions than those allowed by the identity-based
+ // policy of the role that is being assumed. For more information, see Session
+ // Policies
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide. The plaintext that you use for both inline and managed
+ // session policies can't exceed 2,048 characters. The JSON policy characters can
+ // be any ASCII character from the space character to the end of the valid
+ // character list (\u0020 through \u00FF). It can also include the tab (\u0009),
+ // linefeed (\u000A), and carriage return (\u000D) characters. An Amazon Web
+ // Services conversion compresses the passed session policies and session tags into
+ // a packed binary format that has a separate limit. Your request can fail for this
+ // limit even if your plaintext meets the other requirements. The PackedPolicySize
+ // response element indicates by percentage how close the policies and tags for
+ // your request are to the upper size limit.
+ Policy *string
+
+ // The Amazon Resource Names (ARNs) of the IAM managed policies that you want to
+ // use as managed session policies. The policies must exist in the same account as
+ // the role. This parameter is optional. You can provide up to 10 managed policy
+ // ARNs. However, the plaintext that you use for both inline and managed session
+ // policies can't exceed 2,048 characters. For more information about ARNs, see
+ // Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces
+ // (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) in
+ // the Amazon Web Services General Reference. An Amazon Web Services conversion
+ // compresses the passed session policies and session tags into a packed binary
+ // format that has a separate limit. Your request can fail for this limit even if
+ // your plaintext meets the other requirements. The PackedPolicySize response
+ // element indicates by percentage how close the policies and tags for your request
+ // are to the upper size limit. Passing policies to this operation returns new
+ // temporary credentials. The resulting session's permissions are the intersection
+ // of the role's identity-based policy and the session policies. You can use the
+ // role's temporary credentials in subsequent Amazon Web Services API calls to
+ // access resources in the account that owns the role. You cannot use session
+ // policies to grant more permissions than those allowed by the identity-based
+ // policy of the role that is being assumed. For more information, see Session
+ // Policies
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide.
+ PolicyArns []types.PolicyDescriptorType
+
+ // The fully qualified host component of the domain name of the identity provider.
+ // Specify this value only for OAuth 2.0 access tokens. Currently www.amazon.com
+ // and graph.facebook.com are the only supported identity providers for OAuth 2.0
+ // access tokens. Do not include URL schemes and port numbers. Do not specify this
+ // value for OpenID Connect ID tokens.
+ ProviderId *string
+
+ noSmithyDocumentSerde
+}
+
+// Contains the response to a successful AssumeRoleWithWebIdentity request,
+// including temporary Amazon Web Services credentials that can be used to make
+// Amazon Web Services requests.
+type AssumeRoleWithWebIdentityOutput struct {
+
+ // The Amazon Resource Name (ARN) and the assumed role ID, which are identifiers
+ // that you can use to refer to the resulting temporary security credentials. For
+ // example, you can reference these credentials as a principal in a resource-based
+ // policy by using the ARN or assumed role ID. The ARN and ID include the
+ // RoleSessionName that you specified when you called AssumeRole.
+ AssumedRoleUser *types.AssumedRoleUser
+
+ // The intended audience (also known as client ID) of the web identity token. This
+ // is traditionally the client identifier issued to the application that requested
+ // the web identity token.
+ Audience *string
+
+ // The temporary security credentials, which include an access key ID, a secret
+ // access key, and a security token. The size of the security token that STS API
+ // operations return is not fixed. We strongly recommend that you make no
+ // assumptions about the maximum size.
+ Credentials *types.Credentials
+
+ // A percentage value that indicates the packed size of the session policies and
+ // session tags combined passed in the request. The request fails if the packed
+ // size is greater than 100 percent, which means the policies and tags exceeded the
+ // allowed space.
+ PackedPolicySize *int32
+
+ // The issuing authority of the web identity token presented. For OpenID Connect ID
+ // tokens, this contains the value of the iss field. For OAuth 2.0 access tokens,
+ // this contains the value of the ProviderId parameter that was passed in the
+ // AssumeRoleWithWebIdentity request.
+ Provider *string
+
+ // The value of the source identity that is returned in the JSON web token (JWT)
+ // from the identity provider. You can require users to set a source identity value
+ // when they assume a role. You do this by using the sts:SourceIdentity condition
+ // key in a role trust policy. That way, actions that are taken with the role are
+ // associated with that user. After the source identity is set, the value cannot be
+ // changed. It is present in the request for all actions that are taken by the role
+ // and persists across chained role
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_terms-and-concepts#iam-term-role-chaining)
+ // sessions. You can configure your identity provider to use an attribute
+ // associated with your users, like user name or email, as the source identity when
+ // calling AssumeRoleWithWebIdentity. You do this by adding a claim to the JSON web
+ // token. To learn more about OIDC tokens and claims, see Using Tokens with User
+ // Pools
+ // (https://docs.aws.amazon.com/cognito/latest/developerguide/amazon-cognito-user-pools-using-tokens-with-identity-providers.html)
+ // in the Amazon Cognito Developer Guide. For more information about using source
+ // identity, see Monitor and control actions taken with assumed roles
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_monitor.html)
+ // in the IAM User Guide. The regex used to validate this parameter is a string of
+ // characters consisting of upper- and lower-case alphanumeric characters with no
+ // spaces. You can also include underscores or any of the following characters:
+ // =,.@-
+ SourceIdentity *string
+
+ // The unique user identifier that is returned by the identity provider. This
+ // identifier is associated with the WebIdentityToken that was submitted with the
+ // AssumeRoleWithWebIdentity call. The identifier is typically unique to the user
+ // and the application that acquired the WebIdentityToken (pairwise identifier).
+ // For OpenID Connect ID tokens, this field contains the value returned by the
+ // identity provider as the token's sub (Subject) claim.
+ SubjectFromWebIdentityToken *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationAssumeRoleWithWebIdentityMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsquery_serializeOpAssumeRoleWithWebIdentity{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsquery_deserializeOpAssumeRoleWithWebIdentity{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpAssumeRoleWithWebIdentityValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opAssumeRoleWithWebIdentity(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opAssumeRoleWithWebIdentity(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "sts",
+ OperationName: "AssumeRoleWithWebIdentity",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_DecodeAuthorizationMessage.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_DecodeAuthorizationMessage.go
new file mode 100644
index 000000000000..b7a637d420cc
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_DecodeAuthorizationMessage.go
@@ -0,0 +1,155 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Decodes additional information about the authorization status of a request from
+// an encoded message returned in response to an Amazon Web Services request. For
+// example, if a user is not authorized to perform an operation that he or she has
+// requested, the request returns a Client.UnauthorizedOperation response (an HTTP
+// 403 response). Some Amazon Web Services operations additionally return an
+// encoded message that can provide details about this authorization failure. Only
+// certain Amazon Web Services operations return an encoded authorization message.
+// The documentation for an individual operation indicates whether that operation
+// returns an encoded message in addition to returning an HTTP code. The message is
+// encoded because the details of the authorization status can contain privileged
+// information that the user who requested the operation should not see. To decode
+// an authorization status message, a user must be granted permissions through an
+// IAM policy
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html) to
+// request the DecodeAuthorizationMessage (sts:DecodeAuthorizationMessage) action.
+// The decoded message includes the following type of information:
+//
+// * Whether the
+// request was denied due to an explicit deny or due to the absence of an explicit
+// allow. For more information, see Determining Whether a Request is Allowed or
+// Denied
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html#policy-eval-denyallow)
+// in the IAM User Guide.
+//
+// * The principal who made the request.
+//
+// * The requested
+// action.
+//
+// * The requested resource.
+//
+// * The values of condition keys in the
+// context of the user's request.
+func (c *Client) DecodeAuthorizationMessage(ctx context.Context, params *DecodeAuthorizationMessageInput, optFns ...func(*Options)) (*DecodeAuthorizationMessageOutput, error) {
+ if params == nil {
+ params = &DecodeAuthorizationMessageInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "DecodeAuthorizationMessage", params, optFns, c.addOperationDecodeAuthorizationMessageMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*DecodeAuthorizationMessageOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type DecodeAuthorizationMessageInput struct {
+
+ // The encoded message that was returned with the response.
+ //
+ // This member is required.
+ EncodedMessage *string
+
+ noSmithyDocumentSerde
+}
+
+// A document that contains additional information about the authorization status
+// of a request from an encoded message that is returned in response to an Amazon
+// Web Services request.
+type DecodeAuthorizationMessageOutput struct {
+
+ // The API returns a response with the decoded message.
+ DecodedMessage *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationDecodeAuthorizationMessageMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsquery_serializeOpDecodeAuthorizationMessage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsquery_deserializeOpDecodeAuthorizationMessage{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpDecodeAuthorizationMessageValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDecodeAuthorizationMessage(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opDecodeAuthorizationMessage(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "sts",
+ OperationName: "DecodeAuthorizationMessage",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetAccessKeyInfo.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetAccessKeyInfo.go
new file mode 100644
index 000000000000..b86a425d0a87
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetAccessKeyInfo.go
@@ -0,0 +1,141 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns the account identifier for the specified access key ID. Access keys
+// consist of two parts: an access key ID (for example, AKIAIOSFODNN7EXAMPLE) and a
+// secret access key (for example, wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY). For
+// more information about access keys, see Managing Access Keys for IAM Users
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html)
+// in the IAM User Guide. When you pass an access key ID to this operation, it
+// returns the ID of the Amazon Web Services account to which the keys belong.
+// Access key IDs beginning with AKIA are long-term credentials for an IAM user or
+// the Amazon Web Services account root user. Access key IDs beginning with ASIA
+// are temporary credentials that are created using STS operations. If the account
+// in the response belongs to you, you can sign in as the root user and review your
+// root user access keys. Then, you can pull a credentials report
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_getting-report.html)
+// to learn which IAM user owns the keys. To learn who requested the temporary
+// credentials for an ASIA access key, view the STS events in your CloudTrail logs
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail-integration.html)
+// in the IAM User Guide. This operation does not indicate the state of the access
+// key. The key might be active, inactive, or deleted. Active keys might not have
+// permissions to perform an operation. Providing a deleted access key might return
+// an error that the key doesn't exist.
+func (c *Client) GetAccessKeyInfo(ctx context.Context, params *GetAccessKeyInfoInput, optFns ...func(*Options)) (*GetAccessKeyInfoOutput, error) {
+ if params == nil {
+ params = &GetAccessKeyInfoInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetAccessKeyInfo", params, optFns, c.addOperationGetAccessKeyInfoMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetAccessKeyInfoOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetAccessKeyInfoInput struct {
+
+ // The identifier of an access key. This parameter allows (through its regex
+ // pattern) a string of characters that can consist of any upper- or lowercase
+ // letter or digit.
+ //
+ // This member is required.
+ AccessKeyId *string
+
+ noSmithyDocumentSerde
+}
+
+type GetAccessKeyInfoOutput struct {
+
+ // The number used to identify the Amazon Web Services account.
+ Account *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetAccessKeyInfoMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsquery_serializeOpGetAccessKeyInfo{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsquery_deserializeOpGetAccessKeyInfo{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetAccessKeyInfoValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetAccessKeyInfo(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetAccessKeyInfo(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "sts",
+ OperationName: "GetAccessKeyInfo",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetCallerIdentity.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetCallerIdentity.go
new file mode 100644
index 000000000000..a7f96c22014e
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetCallerIdentity.go
@@ -0,0 +1,156 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns details about the IAM user or role whose credentials are used to call
+// the operation. No permissions are required to perform this operation. If an
+// administrator adds a policy to your IAM user or role that explicitly denies
+// access to the sts:GetCallerIdentity action, you can still perform this
+// operation. Permissions are not required because the same information is returned
+// when an IAM user or role is denied access. To view an example response, see I Am
+// Not Authorized to Perform: iam:DeleteVirtualMFADevice
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_access-denied-delete-mfa)
+// in the IAM User Guide.
+func (c *Client) GetCallerIdentity(ctx context.Context, params *GetCallerIdentityInput, optFns ...func(*Options)) (*GetCallerIdentityOutput, error) {
+ if params == nil {
+ params = &GetCallerIdentityInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetCallerIdentity", params, optFns, c.addOperationGetCallerIdentityMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetCallerIdentityOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetCallerIdentityInput struct {
+ noSmithyDocumentSerde
+}
+
+// Contains the response to a successful GetCallerIdentity request, including
+// information about the entity making the request.
+type GetCallerIdentityOutput struct {
+
+ // The Amazon Web Services account ID number of the account that owns or contains
+ // the calling entity.
+ Account *string
+
+ // The Amazon Web Services ARN associated with the calling entity.
+ Arn *string
+
+ // The unique identifier of the calling entity. The exact value depends on the type
+ // of entity that is making the call. The values returned are those listed in the
+ // aws:userid column in the Principal table
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_variables.html#principaltable)
+ // found on the Policy Variables reference page in the IAM User Guide.
+ UserId *string
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetCallerIdentityMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsquery_serializeOpGetCallerIdentity{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsquery_deserializeOpGetCallerIdentity{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetCallerIdentity(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetCallerIdentity(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "sts",
+ OperationName: "GetCallerIdentity",
+ }
+}
+
+// PresignGetCallerIdentity is used to generate a presigned HTTP Request which
+// contains presigned URL, signed headers and HTTP method used.
+func (c *PresignClient) PresignGetCallerIdentity(ctx context.Context, params *GetCallerIdentityInput, optFns ...func(*PresignOptions)) (*v4.PresignedHTTPRequest, error) {
+ if params == nil {
+ params = &GetCallerIdentityInput{}
+ }
+ options := c.options.copy()
+ for _, fn := range optFns {
+ fn(&options)
+ }
+ clientOptFns := append(options.ClientOptions, withNopHTTPClientAPIOption)
+
+ result, _, err := c.client.invokeOperation(ctx, "GetCallerIdentity", params, clientOptFns,
+ c.client.addOperationGetCallerIdentityMiddlewares,
+ presignConverter(options).convertToPresignMiddleware,
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*v4.PresignedHTTPRequest)
+ return out, nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetFederationToken.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetFederationToken.go
new file mode 100644
index 000000000000..01a3d411b2cf
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetFederationToken.go
@@ -0,0 +1,324 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns a set of temporary security credentials (consisting of an access key ID,
+// a secret access key, and a security token) for a federated user. A typical use
+// is in a proxy application that gets temporary security credentials on behalf of
+// distributed applications inside a corporate network. You must call the
+// GetFederationToken operation using the long-term security credentials of an IAM
+// user. As a result, this call is appropriate in contexts where those credentials
+// can be safely stored, usually in a server-based application. For a comparison of
+// GetFederationToken with the other API operations that produce temporary
+// credentials, see Requesting Temporary Security Credentials
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
+// and Comparing the Amazon Web Services STS API operations
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
+// in the IAM User Guide. You can create a mobile-based or browser-based app that
+// can authenticate users using a web identity provider like Login with Amazon,
+// Facebook, Google, or an OpenID Connect-compatible identity provider. In this
+// case, we recommend that you use Amazon Cognito (http://aws.amazon.com/cognito/)
+// or AssumeRoleWithWebIdentity. For more information, see Federation Through a
+// Web-based Identity Provider
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity)
+// in the IAM User Guide. You can also call GetFederationToken using the security
+// credentials of an Amazon Web Services account root user, but we do not recommend
+// it. Instead, we recommend that you create an IAM user for the purpose of the
+// proxy application. Then attach a policy to the IAM user that limits federated
+// users to only the actions and resources that they need to access. For more
+// information, see IAM Best Practices
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html) in the
+// IAM User Guide. Session duration The temporary credentials are valid for the
+// specified duration, from 900 seconds (15 minutes) up to a maximum of 129,600
+// seconds (36 hours). The default session duration is 43,200 seconds (12 hours).
+// Temporary credentials obtained by using the Amazon Web Services account root
+// user credentials have a maximum duration of 3,600 seconds (1 hour). Permissions
+// You can use the temporary credentials created by GetFederationToken in any
+// Amazon Web Services service except the following:
+//
+// * You cannot call any IAM
+// operations using the CLI or the Amazon Web Services API.
+//
+// * You cannot call any
+// STS operations except GetCallerIdentity.
+//
+// You must pass an inline or managed
+// session policy
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+// to this operation. You can pass a single JSON policy document to use as an
+// inline session policy. You can also specify up to 10 managed policies to use as
+// managed session policies. The plaintext that you use for both inline and managed
+// session policies can't exceed 2,048 characters. Though the session policy
+// parameters are optional, if you do not pass a policy, then the resulting
+// federated user session has no permissions. When you pass session policies, the
+// session permissions are the intersection of the IAM user policies and the
+// session policies that you pass. This gives you a way to further restrict the
+// permissions for a federated user. You cannot use session policies to grant more
+// permissions than those that are defined in the permissions policy of the IAM
+// user. For more information, see Session Policies
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+// in the IAM User Guide. For information about using GetFederationToken to create
+// temporary security credentials, see GetFederationToken—Federation Through a
+// Custom Identity Broker
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getfederationtoken).
+// You can use the credentials to access a resource that has a resource-based
+// policy. If that policy specifically references the federated user session in the
+// Principal element of the policy, the session has the permissions allowed by the
+// policy. These permissions are granted in addition to the permissions granted by
+// the session policies. Tags (Optional) You can pass tag key-value pairs to your
+// session. These are called session tags. For more information about session tags,
+// see Passing Session Tags in STS
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+// IAM User Guide. You can create a mobile-based or browser-based app that can
+// authenticate users using a web identity provider like Login with Amazon,
+// Facebook, Google, or an OpenID Connect-compatible identity provider. In this
+// case, we recommend that you use Amazon Cognito (http://aws.amazon.com/cognito/)
+// or AssumeRoleWithWebIdentity. For more information, see Federation Through a
+// Web-based Identity Provider
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity)
+// in the IAM User Guide. An administrator must grant you the permissions necessary
+// to pass session tags. The administrator can also create granular permissions to
+// allow you to pass only specific session tags. For more information, see
+// Tutorial: Using Tags for Attribute-Based Access Control
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html)
+// in the IAM User Guide. Tag key–value pairs are not case sensitive, but case is
+// preserved. This means that you cannot have separate Department and department
+// tag keys. Assume that the user that you are federating has the
+// Department=Marketing tag and you pass the department=engineering session tag.
+// Department and department are not saved as separate tags, and the session tag
+// passed in the request takes precedence over the user tag.
+func (c *Client) GetFederationToken(ctx context.Context, params *GetFederationTokenInput, optFns ...func(*Options)) (*GetFederationTokenOutput, error) {
+ if params == nil {
+ params = &GetFederationTokenInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetFederationToken", params, optFns, c.addOperationGetFederationTokenMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetFederationTokenOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetFederationTokenInput struct {
+
+ // The name of the federated user. The name is used as an identifier for the
+ // temporary security credentials (such as Bob). For example, you can reference the
+ // federated user name in a resource-based policy, such as in an Amazon S3 bucket
+ // policy. The regex used to validate this parameter is a string of characters
+ // consisting of upper- and lower-case alphanumeric characters with no spaces. You
+ // can also include underscores or any of the following characters: =,.@-
+ //
+ // This member is required.
+ Name *string
+
+ // The duration, in seconds, that the session should last. Acceptable durations for
+ // federation sessions range from 900 seconds (15 minutes) to 129,600 seconds (36
+ // hours), with 43,200 seconds (12 hours) as the default. Sessions obtained using
+ // Amazon Web Services account root user credentials are restricted to a maximum of
+ // 3,600 seconds (one hour). If the specified duration is longer than one hour, the
+ // session obtained by using root user credentials defaults to one hour.
+ DurationSeconds *int32
+
+ // An IAM policy in JSON format that you want to use as an inline session policy.
+ // You must pass an inline or managed session policy
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // to this operation. You can pass a single JSON policy document to use as an
+ // inline session policy. You can also specify up to 10 managed policies to use as
+ // managed session policies. This parameter is optional. However, if you do not
+ // pass any session policies, then the resulting federated user session has no
+ // permissions. When you pass session policies, the session permissions are the
+ // intersection of the IAM user policies and the session policies that you pass.
+ // This gives you a way to further restrict the permissions for a federated user.
+ // You cannot use session policies to grant more permissions than those that are
+ // defined in the permissions policy of the IAM user. For more information, see
+ // Session Policies
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide. The resulting credentials can be used to access a
+ // resource that has a resource-based policy. If that policy specifically
+ // references the federated user session in the Principal element of the policy,
+ // the session has the permissions allowed by the policy. These permissions are
+ // granted in addition to the permissions that are granted by the session policies.
+ // The plaintext that you use for both inline and managed session policies can't
+ // exceed 2,048 characters. The JSON policy characters can be any ASCII character
+ // from the space character to the end of the valid character list (\u0020 through
+ // \u00FF). It can also include the tab (\u0009), linefeed (\u000A), and carriage
+ // return (\u000D) characters. An Amazon Web Services conversion compresses the
+ // passed session policies and session tags into a packed binary format that has a
+ // separate limit. Your request can fail for this limit even if your plaintext
+ // meets the other requirements. The PackedPolicySize response element indicates by
+ // percentage how close the policies and tags for your request are to the upper
+ // size limit.
+ Policy *string
+
+ // The Amazon Resource Names (ARNs) of the IAM managed policies that you want to
+ // use as a managed session policy. The policies must exist in the same account as
+ // the IAM user that is requesting federated access. You must pass an inline or
+ // managed session policy
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // to this operation. You can pass a single JSON policy document to use as an
+ // inline session policy. You can also specify up to 10 managed policies to use as
+ // managed session policies. The plaintext that you use for both inline and managed
+ // session policies can't exceed 2,048 characters. You can provide up to 10 managed
+ // policy ARNs. For more information about ARNs, see Amazon Resource Names (ARNs)
+ // and Amazon Web Services Service Namespaces
+ // (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) in
+ // the Amazon Web Services General Reference. This parameter is optional. However,
+ // if you do not pass any session policies, then the resulting federated user
+ // session has no permissions. When you pass session policies, the session
+ // permissions are the intersection of the IAM user policies and the session
+ // policies that you pass. This gives you a way to further restrict the permissions
+ // for a federated user. You cannot use session policies to grant more permissions
+ // than those that are defined in the permissions policy of the IAM user. For more
+ // information, see Session Policies
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
+ // in the IAM User Guide. The resulting credentials can be used to access a
+ // resource that has a resource-based policy. If that policy specifically
+ // references the federated user session in the Principal element of the policy,
+ // the session has the permissions allowed by the policy. These permissions are
+ // granted in addition to the permissions that are granted by the session policies.
+ // An Amazon Web Services conversion compresses the passed session policies and
+ // session tags into a packed binary format that has a separate limit. Your request
+ // can fail for this limit even if your plaintext meets the other requirements. The
+ // PackedPolicySize response element indicates by percentage how close the policies
+ // and tags for your request are to the upper size limit.
+ PolicyArns []types.PolicyDescriptorType
+
+ // A list of session tags. Each session tag consists of a key name and an
+ // associated value. For more information about session tags, see Passing Session
+ // Tags in STS
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+ // IAM User Guide. This parameter is optional. You can pass up to 50 session tags.
+ // The plaintext session tag keys can’t exceed 128 characters and the values can’t
+ // exceed 256 characters. For these and additional limits, see IAM and STS
+ // Character Limits
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
+ // in the IAM User Guide. An Amazon Web Services conversion compresses the passed
+ // session policies and session tags into a packed binary format that has a
+ // separate limit. Your request can fail for this limit even if your plaintext
+ // meets the other requirements. The PackedPolicySize response element indicates by
+ // percentage how close the policies and tags for your request are to the upper
+ // size limit. You can pass a session tag with the same key as a tag that is
+ // already attached to the user you are federating. When you do, session tags
+ // override a user tag with the same key. Tag key–value pairs are not case
+ // sensitive, but case is preserved. This means that you cannot have separate
+ // Department and department tag keys. Assume that the role has the
+ // Department=Marketing tag and you pass the department=engineering session tag.
+ // Department and department are not saved as separate tags, and the session tag
+ // passed in the request takes precedence over the role tag.
+ Tags []types.Tag
+
+ noSmithyDocumentSerde
+}
+
+// Contains the response to a successful GetFederationToken request, including
+// temporary Amazon Web Services credentials that can be used to make Amazon Web
+// Services requests.
+type GetFederationTokenOutput struct {
+
+ // The temporary security credentials, which include an access key ID, a secret
+ // access key, and a security (or session) token. The size of the security token
+ // that STS API operations return is not fixed. We strongly recommend that you make
+ // no assumptions about the maximum size.
+ Credentials *types.Credentials
+
+ // Identifiers for the federated user associated with the credentials (such as
+ // arn:aws:sts::123456789012:federated-user/Bob or 123456789012:Bob). You can use
+ // the federated user's ARN in your resource-based policies, such as an Amazon S3
+ // bucket policy.
+ FederatedUser *types.FederatedUser
+
+ // A percentage value that indicates the packed size of the session policies and
+ // session tags combined passed in the request. The request fails if the packed
+ // size is greater than 100 percent, which means the policies and tags exceeded the
+ // allowed space.
+ PackedPolicySize *int32
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetFederationTokenMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsquery_serializeOpGetFederationToken{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsquery_deserializeOpGetFederationToken{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addOpGetFederationTokenValidationMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetFederationToken(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetFederationToken(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "sts",
+ OperationName: "GetFederationToken",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetSessionToken.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetSessionToken.go
new file mode 100644
index 000000000000..b292f208a0ec
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/api_op_GetSessionToken.go
@@ -0,0 +1,196 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ "github.com/aws/aws-sdk-go-v2/aws/signer/v4"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+)
+
+// Returns a set of temporary credentials for an Amazon Web Services account or IAM
+// user. The credentials consist of an access key ID, a secret access key, and a
+// security token. Typically, you use GetSessionToken if you want to use MFA to
+// protect programmatic calls to specific Amazon Web Services API operations like
+// Amazon EC2 StopInstances. MFA-enabled IAM users would need to call
+// GetSessionToken and submit an MFA code that is associated with their MFA device.
+// Using the temporary security credentials that are returned from the call, IAM
+// users can then make programmatic calls to API operations that require MFA
+// authentication. If you do not supply a correct MFA code, then the API returns an
+// access denied error. For a comparison of GetSessionToken with the other API
+// operations that produce temporary credentials, see Requesting Temporary Security
+// Credentials
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
+// and Comparing the Amazon Web Services STS API operations
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
+// in the IAM User Guide. Session Duration The GetSessionToken operation must be
+// called by using the long-term Amazon Web Services security credentials of the
+// Amazon Web Services account root user or an IAM user. Credentials that are
+// created by IAM users are valid for the duration that you specify. This duration
+// can range from 900 seconds (15 minutes) up to a maximum of 129,600 seconds (36
+// hours), with a default of 43,200 seconds (12 hours). Credentials based on
+// account credentials can range from 900 seconds (15 minutes) up to 3,600 seconds
+// (1 hour), with a default of 1 hour. Permissions The temporary security
+// credentials created by GetSessionToken can be used to make API calls to any
+// Amazon Web Services service with the following exceptions:
+//
+// * You cannot call
+// any IAM API operations unless MFA authentication information is included in the
+// request.
+//
+// * You cannot call any STS API except AssumeRole or
+// GetCallerIdentity.
+//
+// We recommend that you do not call GetSessionToken with
+// Amazon Web Services account root user credentials. Instead, follow our best
+// practices
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#create-iam-users)
+// by creating one or more IAM users, giving them the necessary permissions, and
+// using IAM users for everyday interaction with Amazon Web Services. The
+// credentials that are returned by GetSessionToken are based on permissions
+// associated with the user whose credentials were used to call the operation. If
+// GetSessionToken is called using Amazon Web Services account root user
+// credentials, the temporary credentials have root user permissions. Similarly, if
+// GetSessionToken is called using the credentials of an IAM user, the temporary
+// credentials have the same permissions as the IAM user. For more information
+// about using GetSessionToken to create temporary credentials, go to Temporary
+// Credentials for Users in Untrusted Environments
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getsessiontoken)
+// in the IAM User Guide.
+func (c *Client) GetSessionToken(ctx context.Context, params *GetSessionTokenInput, optFns ...func(*Options)) (*GetSessionTokenOutput, error) {
+ if params == nil {
+ params = &GetSessionTokenInput{}
+ }
+
+ result, metadata, err := c.invokeOperation(ctx, "GetSessionToken", params, optFns, c.addOperationGetSessionTokenMiddlewares)
+ if err != nil {
+ return nil, err
+ }
+
+ out := result.(*GetSessionTokenOutput)
+ out.ResultMetadata = metadata
+ return out, nil
+}
+
+type GetSessionTokenInput struct {
+
+ // The duration, in seconds, that the credentials should remain valid. Acceptable
+ // durations for IAM user sessions range from 900 seconds (15 minutes) to 129,600
+ // seconds (36 hours), with 43,200 seconds (12 hours) as the default. Sessions for
+ // Amazon Web Services account owners are restricted to a maximum of 3,600 seconds
+ // (one hour). If the duration is longer than one hour, the session for Amazon Web
+ // Services account owners defaults to one hour.
+ DurationSeconds *int32
+
+ // The identification number of the MFA device that is associated with the IAM user
+ // who is making the GetSessionToken call. Specify this value if the IAM user has a
+ // policy that requires MFA authentication. The value is either the serial number
+ // for a hardware device (such as GAHT12345678) or an Amazon Resource Name (ARN)
+ // for a virtual device (such as arn:aws:iam::123456789012:mfa/user). You can find
+ // the device for an IAM user by going to the Amazon Web Services Management
+ // Console and viewing the user's security credentials. The regex used to validate
+ // this parameter is a string of characters consisting of upper- and lower-case
+ // alphanumeric characters with no spaces. You can also include underscores or any
+ // of the following characters: =,.@:/-
+ SerialNumber *string
+
+ // The value provided by the MFA device, if MFA is required. If any policy requires
+ // the IAM user to submit an MFA code, specify this value. If MFA authentication is
+ // required, the user must provide a code when requesting a set of temporary
+ // security credentials. A user who fails to provide the code receives an "access
+ // denied" response when requesting resources that require MFA authentication. The
+ // format for this parameter, as described by its regex pattern, is a sequence of
+ // six numeric digits.
+ TokenCode *string
+
+ noSmithyDocumentSerde
+}
+
+// Contains the response to a successful GetSessionToken request, including
+// temporary Amazon Web Services credentials that can be used to make Amazon Web
+// Services requests.
+type GetSessionTokenOutput struct {
+
+ // The temporary security credentials, which include an access key ID, a secret
+ // access key, and a security (or session) token. The size of the security token
+ // that STS API operations return is not fixed. We strongly recommend that you make
+ // no assumptions about the maximum size.
+ Credentials *types.Credentials
+
+ // Metadata pertaining to the operation's result.
+ ResultMetadata middleware.Metadata
+
+ noSmithyDocumentSerde
+}
+
+func (c *Client) addOperationGetSessionTokenMiddlewares(stack *middleware.Stack, options Options) (err error) {
+ err = stack.Serialize.Add(&awsAwsquery_serializeOpGetSessionToken{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ err = stack.Deserialize.Add(&awsAwsquery_deserializeOpGetSessionToken{}, middleware.After)
+ if err != nil {
+ return err
+ }
+ if err = addSetLoggerMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResolveEndpointMiddleware(stack, options); err != nil {
+ return err
+ }
+ if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil {
+ return err
+ }
+ if err = addRetryMiddlewares(stack, options); err != nil {
+ return err
+ }
+ if err = addHTTPSignerV4Middleware(stack, options); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil {
+ return err
+ }
+ if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil {
+ return err
+ }
+ if err = addClientUserAgent(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil {
+ return err
+ }
+ if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetSessionToken(options.Region), middleware.Before); err != nil {
+ return err
+ }
+ if err = addRequestIDRetrieverMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addResponseErrorMiddleware(stack); err != nil {
+ return err
+ }
+ if err = addRequestResponseLogging(stack, options); err != nil {
+ return err
+ }
+ return nil
+}
+
+func newServiceMetadataMiddleware_opGetSessionToken(region string) *awsmiddleware.RegisterServiceMetadata {
+ return &awsmiddleware.RegisterServiceMetadata{
+ Region: region,
+ ServiceID: ServiceID,
+ SigningName: "sts",
+ OperationName: "GetSessionToken",
+ }
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/deserializers.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/deserializers.go
new file mode 100644
index 000000000000..5d634ce35c8f
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/deserializers.go
@@ -0,0 +1,2507 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "bytes"
+ "context"
+ "encoding/xml"
+ "fmt"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ awsxml "github.com/aws/aws-sdk-go-v2/aws/protocol/xml"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+ smithy "github.com/aws/smithy-go"
+ smithyxml "github.com/aws/smithy-go/encoding/xml"
+ smithyio "github.com/aws/smithy-go/io"
+ "github.com/aws/smithy-go/middleware"
+ "github.com/aws/smithy-go/ptr"
+ smithytime "github.com/aws/smithy-go/time"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "io"
+ "strconv"
+ "strings"
+)
+
+type awsAwsquery_deserializeOpAssumeRole struct {
+}
+
+func (*awsAwsquery_deserializeOpAssumeRole) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsquery_deserializeOpAssumeRole) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsquery_deserializeOpErrorAssumeRole(response, &metadata)
+ }
+ output := &AssumeRoleOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(response.Body, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return out, metadata, nil
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("AssumeRoleResult")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeOpDocumentAssumeRoleOutput(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsquery_deserializeOpErrorAssumeRole(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false)
+ if err != nil {
+ return err
+ }
+ if reqID := errorComponents.RequestID; len(reqID) != 0 {
+ awsmiddleware.SetRequestIDMetadata(metadata, reqID)
+ }
+ if len(errorComponents.Code) != 0 {
+ errorCode = errorComponents.Code
+ }
+ if len(errorComponents.Message) != 0 {
+ errorMessage = errorComponents.Message
+ }
+ errorBody.Seek(0, io.SeekStart)
+ switch {
+ case strings.EqualFold("ExpiredTokenException", errorCode):
+ return awsAwsquery_deserializeErrorExpiredTokenException(response, errorBody)
+
+ case strings.EqualFold("MalformedPolicyDocument", errorCode):
+ return awsAwsquery_deserializeErrorMalformedPolicyDocumentException(response, errorBody)
+
+ case strings.EqualFold("PackedPolicyTooLarge", errorCode):
+ return awsAwsquery_deserializeErrorPackedPolicyTooLargeException(response, errorBody)
+
+ case strings.EqualFold("RegionDisabledException", errorCode):
+ return awsAwsquery_deserializeErrorRegionDisabledException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsquery_deserializeOpAssumeRoleWithSAML struct {
+}
+
+func (*awsAwsquery_deserializeOpAssumeRoleWithSAML) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsquery_deserializeOpAssumeRoleWithSAML) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsquery_deserializeOpErrorAssumeRoleWithSAML(response, &metadata)
+ }
+ output := &AssumeRoleWithSAMLOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(response.Body, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return out, metadata, nil
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("AssumeRoleWithSAMLResult")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeOpDocumentAssumeRoleWithSAMLOutput(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsquery_deserializeOpErrorAssumeRoleWithSAML(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false)
+ if err != nil {
+ return err
+ }
+ if reqID := errorComponents.RequestID; len(reqID) != 0 {
+ awsmiddleware.SetRequestIDMetadata(metadata, reqID)
+ }
+ if len(errorComponents.Code) != 0 {
+ errorCode = errorComponents.Code
+ }
+ if len(errorComponents.Message) != 0 {
+ errorMessage = errorComponents.Message
+ }
+ errorBody.Seek(0, io.SeekStart)
+ switch {
+ case strings.EqualFold("ExpiredTokenException", errorCode):
+ return awsAwsquery_deserializeErrorExpiredTokenException(response, errorBody)
+
+ case strings.EqualFold("IDPRejectedClaim", errorCode):
+ return awsAwsquery_deserializeErrorIDPRejectedClaimException(response, errorBody)
+
+ case strings.EqualFold("InvalidIdentityToken", errorCode):
+ return awsAwsquery_deserializeErrorInvalidIdentityTokenException(response, errorBody)
+
+ case strings.EqualFold("MalformedPolicyDocument", errorCode):
+ return awsAwsquery_deserializeErrorMalformedPolicyDocumentException(response, errorBody)
+
+ case strings.EqualFold("PackedPolicyTooLarge", errorCode):
+ return awsAwsquery_deserializeErrorPackedPolicyTooLargeException(response, errorBody)
+
+ case strings.EqualFold("RegionDisabledException", errorCode):
+ return awsAwsquery_deserializeErrorRegionDisabledException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsquery_deserializeOpAssumeRoleWithWebIdentity struct {
+}
+
+func (*awsAwsquery_deserializeOpAssumeRoleWithWebIdentity) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsquery_deserializeOpAssumeRoleWithWebIdentity) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsquery_deserializeOpErrorAssumeRoleWithWebIdentity(response, &metadata)
+ }
+ output := &AssumeRoleWithWebIdentityOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(response.Body, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return out, metadata, nil
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("AssumeRoleWithWebIdentityResult")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeOpDocumentAssumeRoleWithWebIdentityOutput(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsquery_deserializeOpErrorAssumeRoleWithWebIdentity(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false)
+ if err != nil {
+ return err
+ }
+ if reqID := errorComponents.RequestID; len(reqID) != 0 {
+ awsmiddleware.SetRequestIDMetadata(metadata, reqID)
+ }
+ if len(errorComponents.Code) != 0 {
+ errorCode = errorComponents.Code
+ }
+ if len(errorComponents.Message) != 0 {
+ errorMessage = errorComponents.Message
+ }
+ errorBody.Seek(0, io.SeekStart)
+ switch {
+ case strings.EqualFold("ExpiredTokenException", errorCode):
+ return awsAwsquery_deserializeErrorExpiredTokenException(response, errorBody)
+
+ case strings.EqualFold("IDPCommunicationError", errorCode):
+ return awsAwsquery_deserializeErrorIDPCommunicationErrorException(response, errorBody)
+
+ case strings.EqualFold("IDPRejectedClaim", errorCode):
+ return awsAwsquery_deserializeErrorIDPRejectedClaimException(response, errorBody)
+
+ case strings.EqualFold("InvalidIdentityToken", errorCode):
+ return awsAwsquery_deserializeErrorInvalidIdentityTokenException(response, errorBody)
+
+ case strings.EqualFold("MalformedPolicyDocument", errorCode):
+ return awsAwsquery_deserializeErrorMalformedPolicyDocumentException(response, errorBody)
+
+ case strings.EqualFold("PackedPolicyTooLarge", errorCode):
+ return awsAwsquery_deserializeErrorPackedPolicyTooLargeException(response, errorBody)
+
+ case strings.EqualFold("RegionDisabledException", errorCode):
+ return awsAwsquery_deserializeErrorRegionDisabledException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsquery_deserializeOpDecodeAuthorizationMessage struct {
+}
+
+func (*awsAwsquery_deserializeOpDecodeAuthorizationMessage) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsquery_deserializeOpDecodeAuthorizationMessage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsquery_deserializeOpErrorDecodeAuthorizationMessage(response, &metadata)
+ }
+ output := &DecodeAuthorizationMessageOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(response.Body, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return out, metadata, nil
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("DecodeAuthorizationMessageResult")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeOpDocumentDecodeAuthorizationMessageOutput(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsquery_deserializeOpErrorDecodeAuthorizationMessage(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false)
+ if err != nil {
+ return err
+ }
+ if reqID := errorComponents.RequestID; len(reqID) != 0 {
+ awsmiddleware.SetRequestIDMetadata(metadata, reqID)
+ }
+ if len(errorComponents.Code) != 0 {
+ errorCode = errorComponents.Code
+ }
+ if len(errorComponents.Message) != 0 {
+ errorMessage = errorComponents.Message
+ }
+ errorBody.Seek(0, io.SeekStart)
+ switch {
+ case strings.EqualFold("InvalidAuthorizationMessageException", errorCode):
+ return awsAwsquery_deserializeErrorInvalidAuthorizationMessageException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsquery_deserializeOpGetAccessKeyInfo struct {
+}
+
+func (*awsAwsquery_deserializeOpGetAccessKeyInfo) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsquery_deserializeOpGetAccessKeyInfo) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsquery_deserializeOpErrorGetAccessKeyInfo(response, &metadata)
+ }
+ output := &GetAccessKeyInfoOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(response.Body, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return out, metadata, nil
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("GetAccessKeyInfoResult")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeOpDocumentGetAccessKeyInfoOutput(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsquery_deserializeOpErrorGetAccessKeyInfo(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false)
+ if err != nil {
+ return err
+ }
+ if reqID := errorComponents.RequestID; len(reqID) != 0 {
+ awsmiddleware.SetRequestIDMetadata(metadata, reqID)
+ }
+ if len(errorComponents.Code) != 0 {
+ errorCode = errorComponents.Code
+ }
+ if len(errorComponents.Message) != 0 {
+ errorMessage = errorComponents.Message
+ }
+ errorBody.Seek(0, io.SeekStart)
+ switch {
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsquery_deserializeOpGetCallerIdentity struct {
+}
+
+func (*awsAwsquery_deserializeOpGetCallerIdentity) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsquery_deserializeOpGetCallerIdentity) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsquery_deserializeOpErrorGetCallerIdentity(response, &metadata)
+ }
+ output := &GetCallerIdentityOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(response.Body, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return out, metadata, nil
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("GetCallerIdentityResult")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeOpDocumentGetCallerIdentityOutput(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsquery_deserializeOpErrorGetCallerIdentity(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false)
+ if err != nil {
+ return err
+ }
+ if reqID := errorComponents.RequestID; len(reqID) != 0 {
+ awsmiddleware.SetRequestIDMetadata(metadata, reqID)
+ }
+ if len(errorComponents.Code) != 0 {
+ errorCode = errorComponents.Code
+ }
+ if len(errorComponents.Message) != 0 {
+ errorMessage = errorComponents.Message
+ }
+ errorBody.Seek(0, io.SeekStart)
+ switch {
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsquery_deserializeOpGetFederationToken struct {
+}
+
+func (*awsAwsquery_deserializeOpGetFederationToken) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsquery_deserializeOpGetFederationToken) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsquery_deserializeOpErrorGetFederationToken(response, &metadata)
+ }
+ output := &GetFederationTokenOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(response.Body, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return out, metadata, nil
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("GetFederationTokenResult")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeOpDocumentGetFederationTokenOutput(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsquery_deserializeOpErrorGetFederationToken(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false)
+ if err != nil {
+ return err
+ }
+ if reqID := errorComponents.RequestID; len(reqID) != 0 {
+ awsmiddleware.SetRequestIDMetadata(metadata, reqID)
+ }
+ if len(errorComponents.Code) != 0 {
+ errorCode = errorComponents.Code
+ }
+ if len(errorComponents.Message) != 0 {
+ errorMessage = errorComponents.Message
+ }
+ errorBody.Seek(0, io.SeekStart)
+ switch {
+ case strings.EqualFold("MalformedPolicyDocument", errorCode):
+ return awsAwsquery_deserializeErrorMalformedPolicyDocumentException(response, errorBody)
+
+ case strings.EqualFold("PackedPolicyTooLarge", errorCode):
+ return awsAwsquery_deserializeErrorPackedPolicyTooLargeException(response, errorBody)
+
+ case strings.EqualFold("RegionDisabledException", errorCode):
+ return awsAwsquery_deserializeErrorRegionDisabledException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+type awsAwsquery_deserializeOpGetSessionToken struct {
+}
+
+func (*awsAwsquery_deserializeOpGetSessionToken) ID() string {
+ return "OperationDeserializer"
+}
+
+func (m *awsAwsquery_deserializeOpGetSessionToken) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*smithyhttp.Response)
+ if !ok {
+ return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)}
+ }
+
+ if response.StatusCode < 200 || response.StatusCode >= 300 {
+ return out, metadata, awsAwsquery_deserializeOpErrorGetSessionToken(response, &metadata)
+ }
+ output := &GetSessionTokenOutput{}
+ out.Result = output
+
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(response.Body, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return out, metadata, nil
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return out, metadata, &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("GetSessionTokenResult")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeOpDocumentGetSessionTokenOutput(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ err = &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ return out, metadata, err
+ }
+
+ return out, metadata, err
+}
+
+func awsAwsquery_deserializeOpErrorGetSessionToken(response *smithyhttp.Response, metadata *middleware.Metadata) error {
+ var errorBuffer bytes.Buffer
+ if _, err := io.Copy(&errorBuffer, response.Body); err != nil {
+ return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)}
+ }
+ errorBody := bytes.NewReader(errorBuffer.Bytes())
+
+ errorCode := "UnknownError"
+ errorMessage := errorCode
+
+ errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false)
+ if err != nil {
+ return err
+ }
+ if reqID := errorComponents.RequestID; len(reqID) != 0 {
+ awsmiddleware.SetRequestIDMetadata(metadata, reqID)
+ }
+ if len(errorComponents.Code) != 0 {
+ errorCode = errorComponents.Code
+ }
+ if len(errorComponents.Message) != 0 {
+ errorMessage = errorComponents.Message
+ }
+ errorBody.Seek(0, io.SeekStart)
+ switch {
+ case strings.EqualFold("RegionDisabledException", errorCode):
+ return awsAwsquery_deserializeErrorRegionDisabledException(response, errorBody)
+
+ default:
+ genericError := &smithy.GenericAPIError{
+ Code: errorCode,
+ Message: errorMessage,
+ }
+ return genericError
+
+ }
+}
+
+func awsAwsquery_deserializeErrorExpiredTokenException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.ExpiredTokenException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(errorBody, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return output
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("Error")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeDocumentExpiredTokenException(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return output
+}
+
+func awsAwsquery_deserializeErrorIDPCommunicationErrorException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.IDPCommunicationErrorException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(errorBody, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return output
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("Error")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeDocumentIDPCommunicationErrorException(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return output
+}
+
+func awsAwsquery_deserializeErrorIDPRejectedClaimException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.IDPRejectedClaimException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(errorBody, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return output
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("Error")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeDocumentIDPRejectedClaimException(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return output
+}
+
+func awsAwsquery_deserializeErrorInvalidAuthorizationMessageException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.InvalidAuthorizationMessageException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(errorBody, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return output
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("Error")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeDocumentInvalidAuthorizationMessageException(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return output
+}
+
+func awsAwsquery_deserializeErrorInvalidIdentityTokenException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.InvalidIdentityTokenException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(errorBody, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return output
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("Error")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeDocumentInvalidIdentityTokenException(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return output
+}
+
+func awsAwsquery_deserializeErrorMalformedPolicyDocumentException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.MalformedPolicyDocumentException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(errorBody, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return output
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("Error")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeDocumentMalformedPolicyDocumentException(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return output
+}
+
+func awsAwsquery_deserializeErrorPackedPolicyTooLargeException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.PackedPolicyTooLargeException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(errorBody, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return output
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("Error")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeDocumentPackedPolicyTooLargeException(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return output
+}
+
+func awsAwsquery_deserializeErrorRegionDisabledException(response *smithyhttp.Response, errorBody *bytes.Reader) error {
+ output := &types.RegionDisabledException{}
+ var buff [1024]byte
+ ringBuffer := smithyio.NewRingBuffer(buff[:])
+ body := io.TeeReader(errorBody, ringBuffer)
+ rootDecoder := xml.NewDecoder(body)
+ t, err := smithyxml.FetchRootElement(rootDecoder)
+ if err == io.EOF {
+ return output
+ }
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder := smithyxml.WrapNodeDecoder(rootDecoder, t)
+ t, err = decoder.GetElement("Error")
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ err = awsAwsquery_deserializeDocumentRegionDisabledException(&output, decoder)
+ if err != nil {
+ var snapshot bytes.Buffer
+ io.Copy(&snapshot, ringBuffer)
+ return &smithy.DeserializationError{
+ Err: fmt.Errorf("failed to decode response body, %w", err),
+ Snapshot: snapshot.Bytes(),
+ }
+ }
+
+ return output
+}
+
+func awsAwsquery_deserializeDocumentAssumedRoleUser(v **types.AssumedRoleUser, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.AssumedRoleUser
+ if *v == nil {
+ sv = &types.AssumedRoleUser{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("Arn", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Arn = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("AssumedRoleId", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.AssumedRoleId = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentCredentials(v **types.Credentials, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.Credentials
+ if *v == nil {
+ sv = &types.Credentials{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("AccessKeyId", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.AccessKeyId = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("Expiration", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ t, err := smithytime.ParseDateTime(xtv)
+ if err != nil {
+ return err
+ }
+ sv.Expiration = ptr.Time(t)
+ }
+
+ case strings.EqualFold("SecretAccessKey", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.SecretAccessKey = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("SessionToken", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.SessionToken = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentExpiredTokenException(v **types.ExpiredTokenException, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.ExpiredTokenException
+ if *v == nil {
+ sv = &types.ExpiredTokenException{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("message", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Message = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentFederatedUser(v **types.FederatedUser, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.FederatedUser
+ if *v == nil {
+ sv = &types.FederatedUser{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("Arn", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Arn = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("FederatedUserId", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.FederatedUserId = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentIDPCommunicationErrorException(v **types.IDPCommunicationErrorException, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.IDPCommunicationErrorException
+ if *v == nil {
+ sv = &types.IDPCommunicationErrorException{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("message", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Message = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentIDPRejectedClaimException(v **types.IDPRejectedClaimException, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.IDPRejectedClaimException
+ if *v == nil {
+ sv = &types.IDPRejectedClaimException{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("message", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Message = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentInvalidAuthorizationMessageException(v **types.InvalidAuthorizationMessageException, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.InvalidAuthorizationMessageException
+ if *v == nil {
+ sv = &types.InvalidAuthorizationMessageException{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("message", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Message = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentInvalidIdentityTokenException(v **types.InvalidIdentityTokenException, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.InvalidIdentityTokenException
+ if *v == nil {
+ sv = &types.InvalidIdentityTokenException{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("message", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Message = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentMalformedPolicyDocumentException(v **types.MalformedPolicyDocumentException, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.MalformedPolicyDocumentException
+ if *v == nil {
+ sv = &types.MalformedPolicyDocumentException{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("message", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Message = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentPackedPolicyTooLargeException(v **types.PackedPolicyTooLargeException, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.PackedPolicyTooLargeException
+ if *v == nil {
+ sv = &types.PackedPolicyTooLargeException{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("message", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Message = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeDocumentRegionDisabledException(v **types.RegionDisabledException, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *types.RegionDisabledException
+ if *v == nil {
+ sv = &types.RegionDisabledException{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("message", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Message = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeOpDocumentAssumeRoleOutput(v **AssumeRoleOutput, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *AssumeRoleOutput
+ if *v == nil {
+ sv = &AssumeRoleOutput{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("AssumedRoleUser", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentAssumedRoleUser(&sv.AssumedRoleUser, nodeDecoder); err != nil {
+ return err
+ }
+
+ case strings.EqualFold("Credentials", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentCredentials(&sv.Credentials, nodeDecoder); err != nil {
+ return err
+ }
+
+ case strings.EqualFold("PackedPolicySize", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ i64, err := strconv.ParseInt(xtv, 10, 64)
+ if err != nil {
+ return err
+ }
+ sv.PackedPolicySize = ptr.Int32(int32(i64))
+ }
+
+ case strings.EqualFold("SourceIdentity", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.SourceIdentity = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeOpDocumentAssumeRoleWithSAMLOutput(v **AssumeRoleWithSAMLOutput, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *AssumeRoleWithSAMLOutput
+ if *v == nil {
+ sv = &AssumeRoleWithSAMLOutput{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("AssumedRoleUser", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentAssumedRoleUser(&sv.AssumedRoleUser, nodeDecoder); err != nil {
+ return err
+ }
+
+ case strings.EqualFold("Audience", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Audience = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("Credentials", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentCredentials(&sv.Credentials, nodeDecoder); err != nil {
+ return err
+ }
+
+ case strings.EqualFold("Issuer", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Issuer = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("NameQualifier", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.NameQualifier = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("PackedPolicySize", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ i64, err := strconv.ParseInt(xtv, 10, 64)
+ if err != nil {
+ return err
+ }
+ sv.PackedPolicySize = ptr.Int32(int32(i64))
+ }
+
+ case strings.EqualFold("SourceIdentity", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.SourceIdentity = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("Subject", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Subject = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("SubjectType", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.SubjectType = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeOpDocumentAssumeRoleWithWebIdentityOutput(v **AssumeRoleWithWebIdentityOutput, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *AssumeRoleWithWebIdentityOutput
+ if *v == nil {
+ sv = &AssumeRoleWithWebIdentityOutput{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("AssumedRoleUser", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentAssumedRoleUser(&sv.AssumedRoleUser, nodeDecoder); err != nil {
+ return err
+ }
+
+ case strings.EqualFold("Audience", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Audience = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("Credentials", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentCredentials(&sv.Credentials, nodeDecoder); err != nil {
+ return err
+ }
+
+ case strings.EqualFold("PackedPolicySize", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ i64, err := strconv.ParseInt(xtv, 10, 64)
+ if err != nil {
+ return err
+ }
+ sv.PackedPolicySize = ptr.Int32(int32(i64))
+ }
+
+ case strings.EqualFold("Provider", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Provider = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("SourceIdentity", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.SourceIdentity = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("SubjectFromWebIdentityToken", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.SubjectFromWebIdentityToken = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeOpDocumentDecodeAuthorizationMessageOutput(v **DecodeAuthorizationMessageOutput, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *DecodeAuthorizationMessageOutput
+ if *v == nil {
+ sv = &DecodeAuthorizationMessageOutput{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("DecodedMessage", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.DecodedMessage = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeOpDocumentGetAccessKeyInfoOutput(v **GetAccessKeyInfoOutput, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *GetAccessKeyInfoOutput
+ if *v == nil {
+ sv = &GetAccessKeyInfoOutput{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("Account", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Account = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeOpDocumentGetCallerIdentityOutput(v **GetCallerIdentityOutput, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *GetCallerIdentityOutput
+ if *v == nil {
+ sv = &GetCallerIdentityOutput{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("Account", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Account = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("Arn", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.Arn = ptr.String(xtv)
+ }
+
+ case strings.EqualFold("UserId", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ sv.UserId = ptr.String(xtv)
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeOpDocumentGetFederationTokenOutput(v **GetFederationTokenOutput, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *GetFederationTokenOutput
+ if *v == nil {
+ sv = &GetFederationTokenOutput{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("Credentials", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentCredentials(&sv.Credentials, nodeDecoder); err != nil {
+ return err
+ }
+
+ case strings.EqualFold("FederatedUser", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentFederatedUser(&sv.FederatedUser, nodeDecoder); err != nil {
+ return err
+ }
+
+ case strings.EqualFold("PackedPolicySize", t.Name.Local):
+ val, err := decoder.Value()
+ if err != nil {
+ return err
+ }
+ if val == nil {
+ break
+ }
+ {
+ xtv := string(val)
+ i64, err := strconv.ParseInt(xtv, 10, 64)
+ if err != nil {
+ return err
+ }
+ sv.PackedPolicySize = ptr.Int32(int32(i64))
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
+
+func awsAwsquery_deserializeOpDocumentGetSessionTokenOutput(v **GetSessionTokenOutput, decoder smithyxml.NodeDecoder) error {
+ if v == nil {
+ return fmt.Errorf("unexpected nil of type %T", v)
+ }
+ var sv *GetSessionTokenOutput
+ if *v == nil {
+ sv = &GetSessionTokenOutput{}
+ } else {
+ sv = *v
+ }
+
+ for {
+ t, done, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if done {
+ break
+ }
+ originalDecoder := decoder
+ decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t)
+ switch {
+ case strings.EqualFold("Credentials", t.Name.Local):
+ nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t)
+ if err := awsAwsquery_deserializeDocumentCredentials(&sv.Credentials, nodeDecoder); err != nil {
+ return err
+ }
+
+ default:
+ // Do nothing and ignore the unexpected tag element
+ err = decoder.Decoder.Skip()
+ if err != nil {
+ return err
+ }
+
+ }
+ decoder = originalDecoder
+ }
+ *v = sv
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/doc.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/doc.go
new file mode 100644
index 000000000000..7cabbb97e9f5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/doc.go
@@ -0,0 +1,12 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+// Package sts provides the API client, operations, and parameter types for AWS
+// Security Token Service.
+//
+// Security Token Service Security Token Service (STS) enables you to request
+// temporary, limited-privilege credentials for Identity and Access Management
+// (IAM) users or for users that you authenticate (federated users). This guide
+// provides descriptions of the STS API. For more information about using this
+// service, see Temporary Security Credentials
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html).
+package sts
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/endpoints.go
new file mode 100644
index 000000000000..cababea22d90
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/endpoints.go
@@ -0,0 +1,200 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/aws"
+ awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware"
+ internalendpoints "github.com/aws/aws-sdk-go-v2/service/sts/internal/endpoints"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "net/url"
+ "strings"
+)
+
+// EndpointResolverOptions is the service endpoint resolver options
+type EndpointResolverOptions = internalendpoints.Options
+
+// EndpointResolver interface for resolving service endpoints.
+type EndpointResolver interface {
+ ResolveEndpoint(region string, options EndpointResolverOptions) (aws.Endpoint, error)
+}
+
+var _ EndpointResolver = &internalendpoints.Resolver{}
+
+// NewDefaultEndpointResolver constructs a new service endpoint resolver
+func NewDefaultEndpointResolver() *internalendpoints.Resolver {
+ return internalendpoints.New()
+}
+
+// EndpointResolverFunc is a helper utility that wraps a function so it satisfies
+// the EndpointResolver interface. This is useful when you want to add additional
+// endpoint resolving logic, or stub out specific endpoints with custom values.
+type EndpointResolverFunc func(region string, options EndpointResolverOptions) (aws.Endpoint, error)
+
+func (fn EndpointResolverFunc) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error) {
+ return fn(region, options)
+}
+
+func resolveDefaultEndpointConfiguration(o *Options) {
+ if o.EndpointResolver != nil {
+ return
+ }
+ o.EndpointResolver = NewDefaultEndpointResolver()
+}
+
+// EndpointResolverFromURL returns an EndpointResolver configured using the
+// provided endpoint url. By default, the resolved endpoint resolver uses the
+// client region as signing region, and the endpoint source is set to
+// EndpointSourceCustom.You can provide functional options to configure endpoint
+// values for the resolved endpoint.
+func EndpointResolverFromURL(url string, optFns ...func(*aws.Endpoint)) EndpointResolver {
+ e := aws.Endpoint{URL: url, Source: aws.EndpointSourceCustom}
+ for _, fn := range optFns {
+ fn(&e)
+ }
+
+ return EndpointResolverFunc(
+ func(region string, options EndpointResolverOptions) (aws.Endpoint, error) {
+ if len(e.SigningRegion) == 0 {
+ e.SigningRegion = region
+ }
+ return e, nil
+ },
+ )
+}
+
+type ResolveEndpoint struct {
+ Resolver EndpointResolver
+ Options EndpointResolverOptions
+}
+
+func (*ResolveEndpoint) ID() string {
+ return "ResolveEndpoint"
+}
+
+func (m *ResolveEndpoint) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in.Request)
+ }
+
+ if m.Resolver == nil {
+ return out, metadata, fmt.Errorf("expected endpoint resolver to not be nil")
+ }
+
+ eo := m.Options
+ eo.Logger = middleware.GetLogger(ctx)
+
+ var endpoint aws.Endpoint
+ endpoint, err = m.Resolver.ResolveEndpoint(awsmiddleware.GetRegion(ctx), eo)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to resolve service endpoint, %w", err)
+ }
+
+ req.URL, err = url.Parse(endpoint.URL)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to parse endpoint URL: %w", err)
+ }
+
+ if len(awsmiddleware.GetSigningName(ctx)) == 0 {
+ signingName := endpoint.SigningName
+ if len(signingName) == 0 {
+ signingName = "sts"
+ }
+ ctx = awsmiddleware.SetSigningName(ctx, signingName)
+ }
+ ctx = awsmiddleware.SetEndpointSource(ctx, endpoint.Source)
+ ctx = smithyhttp.SetHostnameImmutable(ctx, endpoint.HostnameImmutable)
+ ctx = awsmiddleware.SetSigningRegion(ctx, endpoint.SigningRegion)
+ ctx = awsmiddleware.SetPartitionID(ctx, endpoint.PartitionID)
+ return next.HandleSerialize(ctx, in)
+}
+func addResolveEndpointMiddleware(stack *middleware.Stack, o Options) error {
+ return stack.Serialize.Insert(&ResolveEndpoint{
+ Resolver: o.EndpointResolver,
+ Options: o.EndpointOptions,
+ }, "OperationSerializer", middleware.Before)
+}
+
+func removeResolveEndpointMiddleware(stack *middleware.Stack) error {
+ _, err := stack.Serialize.Remove((&ResolveEndpoint{}).ID())
+ return err
+}
+
+type wrappedEndpointResolver struct {
+ awsResolver aws.EndpointResolverWithOptions
+ resolver EndpointResolver
+}
+
+func (w *wrappedEndpointResolver) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error) {
+ if w.awsResolver == nil {
+ goto fallback
+ }
+ endpoint, err = w.awsResolver.ResolveEndpoint(ServiceID, region, options)
+ if err == nil {
+ return endpoint, nil
+ }
+
+ if nf := (&aws.EndpointNotFoundError{}); !errors.As(err, &nf) {
+ return endpoint, err
+ }
+
+fallback:
+ if w.resolver == nil {
+ return endpoint, fmt.Errorf("default endpoint resolver provided was nil")
+ }
+ return w.resolver.ResolveEndpoint(region, options)
+}
+
+type awsEndpointResolverAdaptor func(service, region string) (aws.Endpoint, error)
+
+func (a awsEndpointResolverAdaptor) ResolveEndpoint(service, region string, options ...interface{}) (aws.Endpoint, error) {
+ return a(service, region)
+}
+
+var _ aws.EndpointResolverWithOptions = awsEndpointResolverAdaptor(nil)
+
+// withEndpointResolver returns an EndpointResolver that first delegates endpoint resolution to the awsResolver.
+// If awsResolver returns aws.EndpointNotFoundError error, the resolver will use the the provided
+// fallbackResolver for resolution.
+//
+// fallbackResolver must not be nil
+func withEndpointResolver(awsResolver aws.EndpointResolver, awsResolverWithOptions aws.EndpointResolverWithOptions, fallbackResolver EndpointResolver) EndpointResolver {
+ var resolver aws.EndpointResolverWithOptions
+
+ if awsResolverWithOptions != nil {
+ resolver = awsResolverWithOptions
+ } else if awsResolver != nil {
+ resolver = awsEndpointResolverAdaptor(awsResolver.ResolveEndpoint)
+ }
+
+ return &wrappedEndpointResolver{
+ awsResolver: resolver,
+ resolver: fallbackResolver,
+ }
+}
+
+func finalizeClientEndpointResolverOptions(options *Options) {
+ options.EndpointOptions.LogDeprecated = options.ClientLogMode.IsDeprecatedUsage()
+
+ if len(options.EndpointOptions.ResolvedRegion) == 0 {
+ const fipsInfix = "-fips-"
+ const fipsPrefix = "fips-"
+ const fipsSuffix = "-fips"
+
+ if strings.Contains(options.Region, fipsInfix) ||
+ strings.Contains(options.Region, fipsPrefix) ||
+ strings.Contains(options.Region, fipsSuffix) {
+ options.EndpointOptions.ResolvedRegion = strings.ReplaceAll(strings.ReplaceAll(strings.ReplaceAll(
+ options.Region, fipsInfix, "-"), fipsPrefix, ""), fipsSuffix, "")
+ options.EndpointOptions.UseFIPSEndpoint = aws.FIPSEndpointStateEnabled
+ }
+ }
+
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/generated.json b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/generated.json
new file mode 100644
index 000000000000..9aca91bc3eb6
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/generated.json
@@ -0,0 +1,34 @@
+{
+ "dependencies": {
+ "github.com/aws/aws-sdk-go-v2": "v1.4.0",
+ "github.com/aws/aws-sdk-go-v2/internal/configsources": "v0.0.0-00010101000000-000000000000",
+ "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2": "v2.0.0-00010101000000-000000000000",
+ "github.com/aws/aws-sdk-go-v2/service/internal/presigned-url": "v1.0.7",
+ "github.com/aws/smithy-go": "v1.4.0"
+ },
+ "files": [
+ "api_client.go",
+ "api_op_AssumeRole.go",
+ "api_op_AssumeRoleWithSAML.go",
+ "api_op_AssumeRoleWithWebIdentity.go",
+ "api_op_DecodeAuthorizationMessage.go",
+ "api_op_GetAccessKeyInfo.go",
+ "api_op_GetCallerIdentity.go",
+ "api_op_GetFederationToken.go",
+ "api_op_GetSessionToken.go",
+ "deserializers.go",
+ "doc.go",
+ "endpoints.go",
+ "generated.json",
+ "internal/endpoints/endpoints.go",
+ "internal/endpoints/endpoints_test.go",
+ "protocol_test.go",
+ "serializers.go",
+ "types/errors.go",
+ "types/types.go",
+ "validators.go"
+ ],
+ "go": "1.15",
+ "module": "github.com/aws/aws-sdk-go-v2/service/sts",
+ "unstable": false
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go.mod b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go.mod
new file mode 100644
index 000000000000..f36b057dc3ab
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go.mod
@@ -0,0 +1,19 @@
+module github.com/aws/aws-sdk-go-v2/service/sts
+
+go 1.15
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.12.0
+ github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3
+ github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0
+ github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.6.0
+ github.com/aws/smithy-go v1.9.1
+)
+
+replace github.com/aws/aws-sdk-go-v2 => ../../
+
+replace github.com/aws/aws-sdk-go-v2/internal/configsources => ../../internal/configsources/
+
+replace github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 => ../../internal/endpoints/v2/
+
+replace github.com/aws/aws-sdk-go-v2/service/internal/presigned-url => ../../service/internal/presigned-url/
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go.sum b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go.sum
new file mode 100644
index 000000000000..e05213ea4b1b
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go.sum
@@ -0,0 +1,14 @@
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go_module_metadata.go
new file mode 100644
index 000000000000..dbf76e3adb4d
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package sts
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.13.0"
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/internal/endpoints/endpoints.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/internal/endpoints/endpoints.go
new file mode 100644
index 000000000000..28ed441bf8e5
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/internal/endpoints/endpoints.go
@@ -0,0 +1,445 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package endpoints
+
+import (
+ "github.com/aws/aws-sdk-go-v2/aws"
+ endpoints "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2"
+ "github.com/aws/smithy-go/logging"
+ "regexp"
+)
+
+// Options is the endpoint resolver configuration options
+type Options struct {
+ // Logger is a logging implementation that log events should be sent to.
+ Logger logging.Logger
+
+ // LogDeprecated indicates that deprecated endpoints should be logged to the
+ // provided logger.
+ LogDeprecated bool
+
+ // ResolvedRegion is used to override the region to be resolved, rather then the
+ // using the value passed to the ResolveEndpoint method. This value is used by the
+ // SDK to translate regions like fips-us-east-1 or us-east-1-fips to an alternative
+ // name. You must not set this value directly in your application.
+ ResolvedRegion string
+
+ // DisableHTTPS informs the resolver to return an endpoint that does not use the
+ // HTTPS scheme.
+ DisableHTTPS bool
+
+ // UseDualStackEndpoint specifies the resolver must resolve a dual-stack endpoint.
+ UseDualStackEndpoint aws.DualStackEndpointState
+
+ // UseFIPSEndpoint specifies the resolver must resolve a FIPS endpoint.
+ UseFIPSEndpoint aws.FIPSEndpointState
+}
+
+func (o Options) GetResolvedRegion() string {
+ return o.ResolvedRegion
+}
+
+func (o Options) GetDisableHTTPS() bool {
+ return o.DisableHTTPS
+}
+
+func (o Options) GetUseDualStackEndpoint() aws.DualStackEndpointState {
+ return o.UseDualStackEndpoint
+}
+
+func (o Options) GetUseFIPSEndpoint() aws.FIPSEndpointState {
+ return o.UseFIPSEndpoint
+}
+
+func transformToSharedOptions(options Options) endpoints.Options {
+ return endpoints.Options{
+ Logger: options.Logger,
+ LogDeprecated: options.LogDeprecated,
+ ResolvedRegion: options.ResolvedRegion,
+ DisableHTTPS: options.DisableHTTPS,
+ UseDualStackEndpoint: options.UseDualStackEndpoint,
+ UseFIPSEndpoint: options.UseFIPSEndpoint,
+ }
+}
+
+// Resolver STS endpoint resolver
+type Resolver struct {
+ partitions endpoints.Partitions
+}
+
+// ResolveEndpoint resolves the service endpoint for the given region and options
+func (r *Resolver) ResolveEndpoint(region string, options Options) (endpoint aws.Endpoint, err error) {
+ if len(region) == 0 {
+ return endpoint, &aws.MissingRegionError{}
+ }
+
+ opt := transformToSharedOptions(options)
+ return r.partitions.ResolveEndpoint(region, opt)
+}
+
+// New returns a new Resolver
+func New() *Resolver {
+ return &Resolver{
+ partitions: defaultPartitions,
+ }
+}
+
+var partitionRegexp = struct {
+ Aws *regexp.Regexp
+ AwsCn *regexp.Regexp
+ AwsIso *regexp.Regexp
+ AwsIsoB *regexp.Regexp
+ AwsUsGov *regexp.Regexp
+}{
+
+ Aws: regexp.MustCompile("^(us|eu|ap|sa|ca|me|af)\\-\\w+\\-\\d+$"),
+ AwsCn: regexp.MustCompile("^cn\\-\\w+\\-\\d+$"),
+ AwsIso: regexp.MustCompile("^us\\-iso\\-\\w+\\-\\d+$"),
+ AwsIsoB: regexp.MustCompile("^us\\-isob\\-\\w+\\-\\d+$"),
+ AwsUsGov: regexp.MustCompile("^us\\-gov\\-\\w+\\-\\d+$"),
+}
+
+var defaultPartitions = endpoints.Partitions{
+ {
+ ID: "aws",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "sts.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts-fips.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "sts-fips.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "sts.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.Aws,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "af-south-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "ap-east-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "ap-northeast-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "ap-northeast-2",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "ap-northeast-3",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "ap-south-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "ap-southeast-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "ap-southeast-2",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "ap-southeast-3",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "aws-global",
+ }: endpoints.Endpoint{
+ Hostname: "sts.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ },
+ endpoints.EndpointKey{
+ Region: "ca-central-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "eu-central-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "eu-north-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "eu-south-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "eu-west-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "eu-west-2",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "eu-west-3",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "me-south-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "sa-east-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "us-east-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "us-east-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts-fips.us-east-1.amazonaws.com",
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-1-fips",
+ }: endpoints.Endpoint{
+ Hostname: "sts-fips.us-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-2",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "us-east-2",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts-fips.us-east-2.amazonaws.com",
+ },
+ endpoints.EndpointKey{
+ Region: "us-east-2-fips",
+ }: endpoints.Endpoint{
+ Hostname: "sts-fips.us-east-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-east-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "us-west-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts-fips.us-west-1.amazonaws.com",
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-1-fips",
+ }: endpoints.Endpoint{
+ Hostname: "sts-fips.us-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-2",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "us-west-2",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts-fips.us-west-2.amazonaws.com",
+ },
+ endpoints.EndpointKey{
+ Region: "us-west-2-fips",
+ }: endpoints.Endpoint{
+ Hostname: "sts-fips.us-west-2.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ },
+ },
+ {
+ ID: "aws-cn",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "sts.{region}.api.amazonwebservices.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts-fips.{region}.amazonaws.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "sts-fips.{region}.api.amazonwebservices.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "sts.{region}.amazonaws.com.cn",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsCn,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "cn-north-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "cn-northwest-1",
+ }: endpoints.Endpoint{},
+ },
+ },
+ {
+ ID: "aws-iso",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts-fips.{region}.c2s.ic.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "sts.{region}.c2s.ic.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsIso,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "us-iso-east-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "us-iso-west-1",
+ }: endpoints.Endpoint{},
+ },
+ },
+ {
+ ID: "aws-iso-b",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts-fips.{region}.sc2s.sgov.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "sts.{region}.sc2s.sgov.gov",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsIsoB,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "us-isob-east-1",
+ }: endpoints.Endpoint{},
+ },
+ },
+ {
+ ID: "aws-us-gov",
+ Defaults: map[endpoints.DefaultKey]endpoints.Endpoint{
+ {
+ Variant: endpoints.DualStackVariant,
+ }: {
+ Hostname: "sts.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: endpoints.FIPSVariant | endpoints.DualStackVariant,
+ }: {
+ Hostname: "sts-fips.{region}.api.aws",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ {
+ Variant: 0,
+ }: {
+ Hostname: "sts.{region}.amazonaws.com",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ RegionRegex: partitionRegexp.AwsUsGov,
+ IsRegionalized: true,
+ Endpoints: endpoints.Endpoints{
+ endpoints.EndpointKey{
+ Region: "us-gov-east-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "us-gov-east-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts.us-gov-east-1.amazonaws.com",
+ },
+ endpoints.EndpointKey{
+ Region: "us-gov-east-1-fips",
+ }: endpoints.Endpoint{
+ Hostname: "sts.us-gov-east-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-east-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ endpoints.EndpointKey{
+ Region: "us-gov-west-1",
+ }: endpoints.Endpoint{},
+ endpoints.EndpointKey{
+ Region: "us-gov-west-1",
+ Variant: endpoints.FIPSVariant,
+ }: {
+ Hostname: "sts.us-gov-west-1.amazonaws.com",
+ },
+ endpoints.EndpointKey{
+ Region: "us-gov-west-1-fips",
+ }: endpoints.Endpoint{
+ Hostname: "sts.us-gov-west-1.amazonaws.com",
+ CredentialScope: endpoints.CredentialScope{
+ Region: "us-gov-west-1",
+ },
+ Deprecated: aws.TrueTernary,
+ },
+ },
+ },
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/serializers.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/serializers.go
new file mode 100644
index 000000000000..05531d369599
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/serializers.go
@@ -0,0 +1,835 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "bytes"
+ "context"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/aws/protocol/query"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/encoding/httpbinding"
+ "github.com/aws/smithy-go/middleware"
+ smithyhttp "github.com/aws/smithy-go/transport/http"
+ "path"
+)
+
+type awsAwsquery_serializeOpAssumeRole struct {
+}
+
+func (*awsAwsquery_serializeOpAssumeRole) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsquery_serializeOpAssumeRole) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*AssumeRoleInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded")
+
+ bodyWriter := bytes.NewBuffer(nil)
+ bodyEncoder := query.NewEncoder(bodyWriter)
+ body := bodyEncoder.Object()
+ body.Key("Action").String("AssumeRole")
+ body.Key("Version").String("2011-06-15")
+
+ if err := awsAwsquery_serializeOpDocumentAssumeRoleInput(input, bodyEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ err = bodyEncoder.Encode()
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsquery_serializeOpAssumeRoleWithSAML struct {
+}
+
+func (*awsAwsquery_serializeOpAssumeRoleWithSAML) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsquery_serializeOpAssumeRoleWithSAML) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*AssumeRoleWithSAMLInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded")
+
+ bodyWriter := bytes.NewBuffer(nil)
+ bodyEncoder := query.NewEncoder(bodyWriter)
+ body := bodyEncoder.Object()
+ body.Key("Action").String("AssumeRoleWithSAML")
+ body.Key("Version").String("2011-06-15")
+
+ if err := awsAwsquery_serializeOpDocumentAssumeRoleWithSAMLInput(input, bodyEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ err = bodyEncoder.Encode()
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsquery_serializeOpAssumeRoleWithWebIdentity struct {
+}
+
+func (*awsAwsquery_serializeOpAssumeRoleWithWebIdentity) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsquery_serializeOpAssumeRoleWithWebIdentity) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*AssumeRoleWithWebIdentityInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded")
+
+ bodyWriter := bytes.NewBuffer(nil)
+ bodyEncoder := query.NewEncoder(bodyWriter)
+ body := bodyEncoder.Object()
+ body.Key("Action").String("AssumeRoleWithWebIdentity")
+ body.Key("Version").String("2011-06-15")
+
+ if err := awsAwsquery_serializeOpDocumentAssumeRoleWithWebIdentityInput(input, bodyEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ err = bodyEncoder.Encode()
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsquery_serializeOpDecodeAuthorizationMessage struct {
+}
+
+func (*awsAwsquery_serializeOpDecodeAuthorizationMessage) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsquery_serializeOpDecodeAuthorizationMessage) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*DecodeAuthorizationMessageInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded")
+
+ bodyWriter := bytes.NewBuffer(nil)
+ bodyEncoder := query.NewEncoder(bodyWriter)
+ body := bodyEncoder.Object()
+ body.Key("Action").String("DecodeAuthorizationMessage")
+ body.Key("Version").String("2011-06-15")
+
+ if err := awsAwsquery_serializeOpDocumentDecodeAuthorizationMessageInput(input, bodyEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ err = bodyEncoder.Encode()
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsquery_serializeOpGetAccessKeyInfo struct {
+}
+
+func (*awsAwsquery_serializeOpGetAccessKeyInfo) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsquery_serializeOpGetAccessKeyInfo) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetAccessKeyInfoInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded")
+
+ bodyWriter := bytes.NewBuffer(nil)
+ bodyEncoder := query.NewEncoder(bodyWriter)
+ body := bodyEncoder.Object()
+ body.Key("Action").String("GetAccessKeyInfo")
+ body.Key("Version").String("2011-06-15")
+
+ if err := awsAwsquery_serializeOpDocumentGetAccessKeyInfoInput(input, bodyEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ err = bodyEncoder.Encode()
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsquery_serializeOpGetCallerIdentity struct {
+}
+
+func (*awsAwsquery_serializeOpGetCallerIdentity) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsquery_serializeOpGetCallerIdentity) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetCallerIdentityInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded")
+
+ bodyWriter := bytes.NewBuffer(nil)
+ bodyEncoder := query.NewEncoder(bodyWriter)
+ body := bodyEncoder.Object()
+ body.Key("Action").String("GetCallerIdentity")
+ body.Key("Version").String("2011-06-15")
+
+ err = bodyEncoder.Encode()
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsquery_serializeOpGetFederationToken struct {
+}
+
+func (*awsAwsquery_serializeOpGetFederationToken) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsquery_serializeOpGetFederationToken) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetFederationTokenInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded")
+
+ bodyWriter := bytes.NewBuffer(nil)
+ bodyEncoder := query.NewEncoder(bodyWriter)
+ body := bodyEncoder.Object()
+ body.Key("Action").String("GetFederationToken")
+ body.Key("Version").String("2011-06-15")
+
+ if err := awsAwsquery_serializeOpDocumentGetFederationTokenInput(input, bodyEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ err = bodyEncoder.Encode()
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+
+type awsAwsquery_serializeOpGetSessionToken struct {
+}
+
+func (*awsAwsquery_serializeOpGetSessionToken) ID() string {
+ return "OperationSerializer"
+}
+
+func (m *awsAwsquery_serializeOpGetSessionToken) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) (
+ out middleware.SerializeOutput, metadata middleware.Metadata, err error,
+) {
+ request, ok := in.Request.(*smithyhttp.Request)
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)}
+ }
+
+ input, ok := in.Parameters.(*GetSessionTokenInput)
+ _ = input
+ if !ok {
+ return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)}
+ }
+
+ operationPath := "/"
+ if len(request.Request.URL.Path) == 0 {
+ request.Request.URL.Path = operationPath
+ } else {
+ request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath)
+ if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' {
+ request.Request.URL.Path += "/"
+ }
+ }
+ request.Request.Method = "POST"
+ httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header)
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded")
+
+ bodyWriter := bytes.NewBuffer(nil)
+ bodyEncoder := query.NewEncoder(bodyWriter)
+ body := bodyEncoder.Object()
+ body.Key("Action").String("GetSessionToken")
+ body.Key("Version").String("2011-06-15")
+
+ if err := awsAwsquery_serializeOpDocumentGetSessionTokenInput(input, bodyEncoder.Value); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ err = bodyEncoder.Encode()
+ if err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+
+ if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil {
+ return out, metadata, &smithy.SerializationError{Err: err}
+ }
+ in.Request = request
+
+ return next.HandleSerialize(ctx, in)
+}
+func awsAwsquery_serializeDocumentPolicyDescriptorListType(v []types.PolicyDescriptorType, value query.Value) error {
+ if len(v) == 0 {
+ return nil
+ }
+ array := value.Array("member")
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsquery_serializeDocumentPolicyDescriptorType(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsquery_serializeDocumentPolicyDescriptorType(v *types.PolicyDescriptorType, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.Arn != nil {
+ objectKey := object.Key("arn")
+ objectKey.String(*v.Arn)
+ }
+
+ return nil
+}
+
+func awsAwsquery_serializeDocumentTag(v *types.Tag, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.Key != nil {
+ objectKey := object.Key("Key")
+ objectKey.String(*v.Key)
+ }
+
+ if v.Value != nil {
+ objectKey := object.Key("Value")
+ objectKey.String(*v.Value)
+ }
+
+ return nil
+}
+
+func awsAwsquery_serializeDocumentTagKeyListType(v []string, value query.Value) error {
+ if len(v) == 0 {
+ return nil
+ }
+ array := value.Array("member")
+
+ for i := range v {
+ av := array.Value()
+ av.String(v[i])
+ }
+ return nil
+}
+
+func awsAwsquery_serializeDocumentTagListType(v []types.Tag, value query.Value) error {
+ if len(v) == 0 {
+ return nil
+ }
+ array := value.Array("member")
+
+ for i := range v {
+ av := array.Value()
+ if err := awsAwsquery_serializeDocumentTag(&v[i], av); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func awsAwsquery_serializeOpDocumentAssumeRoleInput(v *AssumeRoleInput, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.DurationSeconds != nil {
+ objectKey := object.Key("DurationSeconds")
+ objectKey.Integer(*v.DurationSeconds)
+ }
+
+ if v.ExternalId != nil {
+ objectKey := object.Key("ExternalId")
+ objectKey.String(*v.ExternalId)
+ }
+
+ if v.Policy != nil {
+ objectKey := object.Key("Policy")
+ objectKey.String(*v.Policy)
+ }
+
+ if v.PolicyArns != nil {
+ objectKey := object.Key("PolicyArns")
+ if err := awsAwsquery_serializeDocumentPolicyDescriptorListType(v.PolicyArns, objectKey); err != nil {
+ return err
+ }
+ }
+
+ if v.RoleArn != nil {
+ objectKey := object.Key("RoleArn")
+ objectKey.String(*v.RoleArn)
+ }
+
+ if v.RoleSessionName != nil {
+ objectKey := object.Key("RoleSessionName")
+ objectKey.String(*v.RoleSessionName)
+ }
+
+ if v.SerialNumber != nil {
+ objectKey := object.Key("SerialNumber")
+ objectKey.String(*v.SerialNumber)
+ }
+
+ if v.SourceIdentity != nil {
+ objectKey := object.Key("SourceIdentity")
+ objectKey.String(*v.SourceIdentity)
+ }
+
+ if v.Tags != nil {
+ objectKey := object.Key("Tags")
+ if err := awsAwsquery_serializeDocumentTagListType(v.Tags, objectKey); err != nil {
+ return err
+ }
+ }
+
+ if v.TokenCode != nil {
+ objectKey := object.Key("TokenCode")
+ objectKey.String(*v.TokenCode)
+ }
+
+ if v.TransitiveTagKeys != nil {
+ objectKey := object.Key("TransitiveTagKeys")
+ if err := awsAwsquery_serializeDocumentTagKeyListType(v.TransitiveTagKeys, objectKey); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsquery_serializeOpDocumentAssumeRoleWithSAMLInput(v *AssumeRoleWithSAMLInput, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.DurationSeconds != nil {
+ objectKey := object.Key("DurationSeconds")
+ objectKey.Integer(*v.DurationSeconds)
+ }
+
+ if v.Policy != nil {
+ objectKey := object.Key("Policy")
+ objectKey.String(*v.Policy)
+ }
+
+ if v.PolicyArns != nil {
+ objectKey := object.Key("PolicyArns")
+ if err := awsAwsquery_serializeDocumentPolicyDescriptorListType(v.PolicyArns, objectKey); err != nil {
+ return err
+ }
+ }
+
+ if v.PrincipalArn != nil {
+ objectKey := object.Key("PrincipalArn")
+ objectKey.String(*v.PrincipalArn)
+ }
+
+ if v.RoleArn != nil {
+ objectKey := object.Key("RoleArn")
+ objectKey.String(*v.RoleArn)
+ }
+
+ if v.SAMLAssertion != nil {
+ objectKey := object.Key("SAMLAssertion")
+ objectKey.String(*v.SAMLAssertion)
+ }
+
+ return nil
+}
+
+func awsAwsquery_serializeOpDocumentAssumeRoleWithWebIdentityInput(v *AssumeRoleWithWebIdentityInput, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.DurationSeconds != nil {
+ objectKey := object.Key("DurationSeconds")
+ objectKey.Integer(*v.DurationSeconds)
+ }
+
+ if v.Policy != nil {
+ objectKey := object.Key("Policy")
+ objectKey.String(*v.Policy)
+ }
+
+ if v.PolicyArns != nil {
+ objectKey := object.Key("PolicyArns")
+ if err := awsAwsquery_serializeDocumentPolicyDescriptorListType(v.PolicyArns, objectKey); err != nil {
+ return err
+ }
+ }
+
+ if v.ProviderId != nil {
+ objectKey := object.Key("ProviderId")
+ objectKey.String(*v.ProviderId)
+ }
+
+ if v.RoleArn != nil {
+ objectKey := object.Key("RoleArn")
+ objectKey.String(*v.RoleArn)
+ }
+
+ if v.RoleSessionName != nil {
+ objectKey := object.Key("RoleSessionName")
+ objectKey.String(*v.RoleSessionName)
+ }
+
+ if v.WebIdentityToken != nil {
+ objectKey := object.Key("WebIdentityToken")
+ objectKey.String(*v.WebIdentityToken)
+ }
+
+ return nil
+}
+
+func awsAwsquery_serializeOpDocumentDecodeAuthorizationMessageInput(v *DecodeAuthorizationMessageInput, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.EncodedMessage != nil {
+ objectKey := object.Key("EncodedMessage")
+ objectKey.String(*v.EncodedMessage)
+ }
+
+ return nil
+}
+
+func awsAwsquery_serializeOpDocumentGetAccessKeyInfoInput(v *GetAccessKeyInfoInput, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.AccessKeyId != nil {
+ objectKey := object.Key("AccessKeyId")
+ objectKey.String(*v.AccessKeyId)
+ }
+
+ return nil
+}
+
+func awsAwsquery_serializeOpDocumentGetCallerIdentityInput(v *GetCallerIdentityInput, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ return nil
+}
+
+func awsAwsquery_serializeOpDocumentGetFederationTokenInput(v *GetFederationTokenInput, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.DurationSeconds != nil {
+ objectKey := object.Key("DurationSeconds")
+ objectKey.Integer(*v.DurationSeconds)
+ }
+
+ if v.Name != nil {
+ objectKey := object.Key("Name")
+ objectKey.String(*v.Name)
+ }
+
+ if v.Policy != nil {
+ objectKey := object.Key("Policy")
+ objectKey.String(*v.Policy)
+ }
+
+ if v.PolicyArns != nil {
+ objectKey := object.Key("PolicyArns")
+ if err := awsAwsquery_serializeDocumentPolicyDescriptorListType(v.PolicyArns, objectKey); err != nil {
+ return err
+ }
+ }
+
+ if v.Tags != nil {
+ objectKey := object.Key("Tags")
+ if err := awsAwsquery_serializeDocumentTagListType(v.Tags, objectKey); err != nil {
+ return err
+ }
+ }
+
+ return nil
+}
+
+func awsAwsquery_serializeOpDocumentGetSessionTokenInput(v *GetSessionTokenInput, value query.Value) error {
+ object := value.Object()
+ _ = object
+
+ if v.DurationSeconds != nil {
+ objectKey := object.Key("DurationSeconds")
+ objectKey.Integer(*v.DurationSeconds)
+ }
+
+ if v.SerialNumber != nil {
+ objectKey := object.Key("SerialNumber")
+ objectKey.String(*v.SerialNumber)
+ }
+
+ if v.TokenCode != nil {
+ objectKey := object.Key("TokenCode")
+ objectKey.String(*v.TokenCode)
+ }
+
+ return nil
+}
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/types/errors.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/types/errors.go
new file mode 100644
index 000000000000..b109fe5fc181
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/types/errors.go
@@ -0,0 +1,193 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+import (
+ "fmt"
+ smithy "github.com/aws/smithy-go"
+)
+
+// The web identity token that was passed is expired or is not valid. Get a new
+// identity token from the identity provider and then retry the request.
+type ExpiredTokenException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *ExpiredTokenException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *ExpiredTokenException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *ExpiredTokenException) ErrorCode() string { return "ExpiredTokenException" }
+func (e *ExpiredTokenException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The request could not be fulfilled because the identity provider (IDP) that was
+// asked to verify the incoming identity token could not be reached. This is often
+// a transient error caused by network conditions. Retry the request a limited
+// number of times so that you don't exceed the request rate. If the error
+// persists, the identity provider might be down or not responding.
+type IDPCommunicationErrorException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *IDPCommunicationErrorException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *IDPCommunicationErrorException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *IDPCommunicationErrorException) ErrorCode() string { return "IDPCommunicationError" }
+func (e *IDPCommunicationErrorException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The identity provider (IdP) reported that authentication failed. This might be
+// because the claim is invalid. If this error is returned for the
+// AssumeRoleWithWebIdentity operation, it can also mean that the claim has expired
+// or has been explicitly revoked.
+type IDPRejectedClaimException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *IDPRejectedClaimException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *IDPRejectedClaimException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *IDPRejectedClaimException) ErrorCode() string { return "IDPRejectedClaim" }
+func (e *IDPRejectedClaimException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The error returned if the message passed to DecodeAuthorizationMessage was
+// invalid. This can happen if the token contains invalid characters, such as
+// linebreaks.
+type InvalidAuthorizationMessageException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidAuthorizationMessageException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidAuthorizationMessageException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidAuthorizationMessageException) ErrorCode() string {
+ return "InvalidAuthorizationMessageException"
+}
+func (e *InvalidAuthorizationMessageException) ErrorFault() smithy.ErrorFault {
+ return smithy.FaultClient
+}
+
+// The web identity token that was passed could not be validated by Amazon Web
+// Services. Get a new identity token from the identity provider and then retry the
+// request.
+type InvalidIdentityTokenException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *InvalidIdentityTokenException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *InvalidIdentityTokenException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *InvalidIdentityTokenException) ErrorCode() string { return "InvalidIdentityToken" }
+func (e *InvalidIdentityTokenException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The request was rejected because the policy document was malformed. The error
+// message describes the specific error.
+type MalformedPolicyDocumentException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *MalformedPolicyDocumentException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *MalformedPolicyDocumentException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *MalformedPolicyDocumentException) ErrorCode() string { return "MalformedPolicyDocument" }
+func (e *MalformedPolicyDocumentException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// The request was rejected because the total packed size of the session policies
+// and session tags combined was too large. An Amazon Web Services conversion
+// compresses the session policy document, session policy ARNs, and session tags
+// into a packed binary format that has a separate limit. The error message
+// indicates by percentage how close the policies and tags are to the upper size
+// limit. For more information, see Passing Session Tags in STS
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+// IAM User Guide. You could receive this error even though you meet other defined
+// session policy and session tag limits. For more information, see IAM and STS
+// Entity Character Limits
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-quotas.html#reference_iam-limits-entity-length)
+// in the IAM User Guide.
+type PackedPolicyTooLargeException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *PackedPolicyTooLargeException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *PackedPolicyTooLargeException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *PackedPolicyTooLargeException) ErrorCode() string { return "PackedPolicyTooLarge" }
+func (e *PackedPolicyTooLargeException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
+
+// STS is not activated in the requested region for the account that is being asked
+// to generate credentials. The account administrator must use the IAM console to
+// activate STS in that region. For more information, see Activating and
+// Deactivating Amazon Web Services STS in an Amazon Web Services Region
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
+// in the IAM User Guide.
+type RegionDisabledException struct {
+ Message *string
+
+ noSmithyDocumentSerde
+}
+
+func (e *RegionDisabledException) Error() string {
+ return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage())
+}
+func (e *RegionDisabledException) ErrorMessage() string {
+ if e.Message == nil {
+ return ""
+ }
+ return *e.Message
+}
+func (e *RegionDisabledException) ErrorCode() string { return "RegionDisabledException" }
+func (e *RegionDisabledException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient }
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/types/types.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/types/types.go
new file mode 100644
index 000000000000..86e509905bea
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/types/types.go
@@ -0,0 +1,124 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package types
+
+import (
+ smithydocument "github.com/aws/smithy-go/document"
+ "time"
+)
+
+// The identifiers for the temporary security credentials that the operation
+// returns.
+type AssumedRoleUser struct {
+
+ // The ARN of the temporary security credentials that are returned from the
+ // AssumeRole action. For more information about ARNs and how to use them in
+ // policies, see IAM Identifiers
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html) in
+ // the IAM User Guide.
+ //
+ // This member is required.
+ Arn *string
+
+ // A unique identifier that contains the role ID and the role session name of the
+ // role that is being assumed. The role ID is generated by Amazon Web Services when
+ // the role is created.
+ //
+ // This member is required.
+ AssumedRoleId *string
+
+ noSmithyDocumentSerde
+}
+
+// Amazon Web Services credentials for API authentication.
+type Credentials struct {
+
+ // The access key ID that identifies the temporary security credentials.
+ //
+ // This member is required.
+ AccessKeyId *string
+
+ // The date on which the current credentials expire.
+ //
+ // This member is required.
+ Expiration *time.Time
+
+ // The secret access key that can be used to sign requests.
+ //
+ // This member is required.
+ SecretAccessKey *string
+
+ // The token that users must pass to the service API to use the temporary
+ // credentials.
+ //
+ // This member is required.
+ SessionToken *string
+
+ noSmithyDocumentSerde
+}
+
+// Identifiers for the federated user that is associated with the credentials.
+type FederatedUser struct {
+
+ // The ARN that specifies the federated user that is associated with the
+ // credentials. For more information about ARNs and how to use them in policies,
+ // see IAM Identifiers
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html) in
+ // the IAM User Guide.
+ //
+ // This member is required.
+ Arn *string
+
+ // The string that identifies the federated user associated with the credentials,
+ // similar to the unique ID of an IAM user.
+ //
+ // This member is required.
+ FederatedUserId *string
+
+ noSmithyDocumentSerde
+}
+
+// A reference to the IAM managed policy that is passed as a session policy for a
+// role session or a federated user session.
+type PolicyDescriptorType struct {
+
+ // The Amazon Resource Name (ARN) of the IAM managed policy to use as a session
+ // policy for the role. For more information about ARNs, see Amazon Resource Names
+ // (ARNs) and Amazon Web Services Service Namespaces
+ // (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) in
+ // the Amazon Web Services General Reference.
+ Arn *string
+
+ noSmithyDocumentSerde
+}
+
+// You can pass custom key-value pair attributes when you assume a role or federate
+// a user. These are called session tags. You can then use the session tags to
+// control access to resources. For more information, see Tagging Amazon Web
+// Services STS Sessions
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html) in the
+// IAM User Guide.
+type Tag struct {
+
+ // The key for a session tag. You can pass up to 50 session tags. The plain text
+ // session tag keys can’t exceed 128 characters. For these and additional limits,
+ // see IAM and STS Character Limits
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
+ // in the IAM User Guide.
+ //
+ // This member is required.
+ Key *string
+
+ // The value for a session tag. You can pass up to 50 session tags. The plain text
+ // session tag values can’t exceed 256 characters. For these and additional limits,
+ // see IAM and STS Character Limits
+ // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
+ // in the IAM User Guide.
+ //
+ // This member is required.
+ Value *string
+
+ noSmithyDocumentSerde
+}
+
+type noSmithyDocumentSerde = smithydocument.NoSerde
diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/sts/validators.go b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/validators.go
new file mode 100644
index 000000000000..3e4bad2a9255
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go-v2/service/sts/validators.go
@@ -0,0 +1,305 @@
+// Code generated by smithy-go-codegen DO NOT EDIT.
+
+package sts
+
+import (
+ "context"
+ "fmt"
+ "github.com/aws/aws-sdk-go-v2/service/sts/types"
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/middleware"
+)
+
+type validateOpAssumeRole struct {
+}
+
+func (*validateOpAssumeRole) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpAssumeRole) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*AssumeRoleInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpAssumeRoleInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpAssumeRoleWithSAML struct {
+}
+
+func (*validateOpAssumeRoleWithSAML) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpAssumeRoleWithSAML) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*AssumeRoleWithSAMLInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpAssumeRoleWithSAMLInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpAssumeRoleWithWebIdentity struct {
+}
+
+func (*validateOpAssumeRoleWithWebIdentity) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpAssumeRoleWithWebIdentity) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*AssumeRoleWithWebIdentityInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpAssumeRoleWithWebIdentityInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpDecodeAuthorizationMessage struct {
+}
+
+func (*validateOpDecodeAuthorizationMessage) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpDecodeAuthorizationMessage) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*DecodeAuthorizationMessageInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpDecodeAuthorizationMessageInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpGetAccessKeyInfo struct {
+}
+
+func (*validateOpGetAccessKeyInfo) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetAccessKeyInfo) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetAccessKeyInfoInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetAccessKeyInfoInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+type validateOpGetFederationToken struct {
+}
+
+func (*validateOpGetFederationToken) ID() string {
+ return "OperationInputValidation"
+}
+
+func (m *validateOpGetFederationToken) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ input, ok := in.Parameters.(*GetFederationTokenInput)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters)
+ }
+ if err := validateOpGetFederationTokenInput(input); err != nil {
+ return out, metadata, err
+ }
+ return next.HandleInitialize(ctx, in)
+}
+
+func addOpAssumeRoleValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpAssumeRole{}, middleware.After)
+}
+
+func addOpAssumeRoleWithSAMLValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpAssumeRoleWithSAML{}, middleware.After)
+}
+
+func addOpAssumeRoleWithWebIdentityValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpAssumeRoleWithWebIdentity{}, middleware.After)
+}
+
+func addOpDecodeAuthorizationMessageValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpDecodeAuthorizationMessage{}, middleware.After)
+}
+
+func addOpGetAccessKeyInfoValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetAccessKeyInfo{}, middleware.After)
+}
+
+func addOpGetFederationTokenValidationMiddleware(stack *middleware.Stack) error {
+ return stack.Initialize.Add(&validateOpGetFederationToken{}, middleware.After)
+}
+
+func validateTag(v *types.Tag) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "Tag"}
+ if v.Key == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Key"))
+ }
+ if v.Value == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Value"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateTagListType(v []types.Tag) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "TagListType"}
+ for i := range v {
+ if err := validateTag(&v[i]); err != nil {
+ invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpAssumeRoleInput(v *AssumeRoleInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "AssumeRoleInput"}
+ if v.RoleArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RoleArn"))
+ }
+ if v.RoleSessionName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RoleSessionName"))
+ }
+ if v.Tags != nil {
+ if err := validateTagListType(v.Tags); err != nil {
+ invalidParams.AddNested("Tags", err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpAssumeRoleWithSAMLInput(v *AssumeRoleWithSAMLInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "AssumeRoleWithSAMLInput"}
+ if v.RoleArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RoleArn"))
+ }
+ if v.PrincipalArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("PrincipalArn"))
+ }
+ if v.SAMLAssertion == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("SAMLAssertion"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpAssumeRoleWithWebIdentityInput(v *AssumeRoleWithWebIdentityInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "AssumeRoleWithWebIdentityInput"}
+ if v.RoleArn == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RoleArn"))
+ }
+ if v.RoleSessionName == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("RoleSessionName"))
+ }
+ if v.WebIdentityToken == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("WebIdentityToken"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpDecodeAuthorizationMessageInput(v *DecodeAuthorizationMessageInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "DecodeAuthorizationMessageInput"}
+ if v.EncodedMessage == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("EncodedMessage"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpGetAccessKeyInfoInput(v *GetAccessKeyInfoInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetAccessKeyInfoInput"}
+ if v.AccessKeyId == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("AccessKeyId"))
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
+
+func validateOpGetFederationTokenInput(v *GetFederationTokenInput) error {
+ if v == nil {
+ return nil
+ }
+ invalidParams := smithy.InvalidParamsError{Context: "GetFederationTokenInput"}
+ if v.Name == nil {
+ invalidParams.Add(smithy.NewErrParamRequired("Name"))
+ }
+ if v.Tags != nil {
+ if err := validateTagListType(v.Tags); err != nil {
+ invalidParams.AddNested("Tags", err.(smithy.InvalidParamsError))
+ }
+ }
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ } else {
+ return nil
+ }
+}
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
deleted file mode 100644
index 99849c0e19c0..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go
+++ /dev/null
@@ -1,164 +0,0 @@
-// Package awserr represents API error interface accessors for the SDK.
-package awserr
-
-// An Error wraps lower level errors with code, message and an original error.
-// The underlying concrete error type may also satisfy other interfaces which
-// can be to used to obtain more specific information about the error.
-//
-// Calling Error() or String() will always include the full information about
-// an error based on its underlying type.
-//
-// Example:
-//
-// output, err := s3manage.Upload(svc, input, opts)
-// if err != nil {
-// if awsErr, ok := err.(awserr.Error); ok {
-// // Get error details
-// log.Println("Error:", awsErr.Code(), awsErr.Message())
-//
-// // Prints out full error message, including original error if there was one.
-// log.Println("Error:", awsErr.Error())
-//
-// // Get original error
-// if origErr := awsErr.OrigErr(); origErr != nil {
-// // operate on original error.
-// }
-// } else {
-// fmt.Println(err.Error())
-// }
-// }
-//
-type Error interface {
- // Satisfy the generic error interface.
- error
-
- // Returns the short phrase depicting the classification of the error.
- Code() string
-
- // Returns the error details message.
- Message() string
-
- // Returns the original error if one was set. Nil is returned if not set.
- OrigErr() error
-}
-
-// BatchError is a batch of errors which also wraps lower level errors with
-// code, message, and original errors. Calling Error() will include all errors
-// that occurred in the batch.
-//
-// Deprecated: Replaced with BatchedErrors. Only defined for backwards
-// compatibility.
-type BatchError interface {
- // Satisfy the generic error interface.
- error
-
- // Returns the short phrase depicting the classification of the error.
- Code() string
-
- // Returns the error details message.
- Message() string
-
- // Returns the original error if one was set. Nil is returned if not set.
- OrigErrs() []error
-}
-
-// BatchedErrors is a batch of errors which also wraps lower level errors with
-// code, message, and original errors. Calling Error() will include all errors
-// that occurred in the batch.
-//
-// Replaces BatchError
-type BatchedErrors interface {
- // Satisfy the base Error interface.
- Error
-
- // Returns the original error if one was set. Nil is returned if not set.
- OrigErrs() []error
-}
-
-// New returns an Error object described by the code, message, and origErr.
-//
-// If origErr satisfies the Error interface it will not be wrapped within a new
-// Error object and will instead be returned.
-func New(code, message string, origErr error) Error {
- var errs []error
- if origErr != nil {
- errs = append(errs, origErr)
- }
- return newBaseError(code, message, errs)
-}
-
-// NewBatchError returns an BatchedErrors with a collection of errors as an
-// array of errors.
-func NewBatchError(code, message string, errs []error) BatchedErrors {
- return newBaseError(code, message, errs)
-}
-
-// A RequestFailure is an interface to extract request failure information from
-// an Error such as the request ID of the failed request returned by a service.
-// RequestFailures may not always have a requestID value if the request failed
-// prior to reaching the service such as a connection error.
-//
-// Example:
-//
-// output, err := s3manage.Upload(svc, input, opts)
-// if err != nil {
-// if reqerr, ok := err.(RequestFailure); ok {
-// log.Println("Request failed", reqerr.Code(), reqerr.Message(), reqerr.RequestID())
-// } else {
-// log.Println("Error:", err.Error())
-// }
-// }
-//
-// Combined with awserr.Error:
-//
-// output, err := s3manage.Upload(svc, input, opts)
-// if err != nil {
-// if awsErr, ok := err.(awserr.Error); ok {
-// // Generic AWS Error with Code, Message, and original error (if any)
-// fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
-//
-// if reqErr, ok := err.(awserr.RequestFailure); ok {
-// // A service error occurred
-// fmt.Println(reqErr.StatusCode(), reqErr.RequestID())
-// }
-// } else {
-// fmt.Println(err.Error())
-// }
-// }
-//
-type RequestFailure interface {
- Error
-
- // The status code of the HTTP response.
- StatusCode() int
-
- // The request ID returned by the service for a request failure. This will
- // be empty if no request ID is available such as the request failed due
- // to a connection error.
- RequestID() string
-}
-
-// NewRequestFailure returns a wrapped error with additional information for
-// request status code, and service requestID.
-//
-// Should be used to wrap all request which involve service requests. Even if
-// the request failed without a service response, but had an HTTP status code
-// that may be meaningful.
-func NewRequestFailure(err Error, statusCode int, reqID string) RequestFailure {
- return newRequestError(err, statusCode, reqID)
-}
-
-// UnmarshalError provides the interface for the SDK failing to unmarshal data.
-type UnmarshalError interface {
- awsError
- Bytes() []byte
-}
-
-// NewUnmarshalError returns an initialized UnmarshalError error wrapper adding
-// the bytes that fail to unmarshal to the error.
-func NewUnmarshalError(err error, msg string, bytes []byte) UnmarshalError {
- return &unmarshalError{
- awsError: New("UnmarshalError", msg, err),
- bytes: bytes,
- }
-}
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
deleted file mode 100644
index 9cf7eaf4007f..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go
+++ /dev/null
@@ -1,221 +0,0 @@
-package awserr
-
-import (
- "encoding/hex"
- "fmt"
-)
-
-// SprintError returns a string of the formatted error code.
-//
-// Both extra and origErr are optional. If they are included their lines
-// will be added, but if they are not included their lines will be ignored.
-func SprintError(code, message, extra string, origErr error) string {
- msg := fmt.Sprintf("%s: %s", code, message)
- if extra != "" {
- msg = fmt.Sprintf("%s\n\t%s", msg, extra)
- }
- if origErr != nil {
- msg = fmt.Sprintf("%s\ncaused by: %s", msg, origErr.Error())
- }
- return msg
-}
-
-// A baseError wraps the code and message which defines an error. It also
-// can be used to wrap an original error object.
-//
-// Should be used as the root for errors satisfying the awserr.Error. Also
-// for any error which does not fit into a specific error wrapper type.
-type baseError struct {
- // Classification of error
- code string
-
- // Detailed information about error
- message string
-
- // Optional original error this error is based off of. Allows building
- // chained errors.
- errs []error
-}
-
-// newBaseError returns an error object for the code, message, and errors.
-//
-// code is a short no whitespace phrase depicting the classification of
-// the error that is being created.
-//
-// message is the free flow string containing detailed information about the
-// error.
-//
-// origErrs is the error objects which will be nested under the new errors to
-// be returned.
-func newBaseError(code, message string, origErrs []error) *baseError {
- b := &baseError{
- code: code,
- message: message,
- errs: origErrs,
- }
-
- return b
-}
-
-// Error returns the string representation of the error.
-//
-// See ErrorWithExtra for formatting.
-//
-// Satisfies the error interface.
-func (b baseError) Error() string {
- size := len(b.errs)
- if size > 0 {
- return SprintError(b.code, b.message, "", errorList(b.errs))
- }
-
- return SprintError(b.code, b.message, "", nil)
-}
-
-// String returns the string representation of the error.
-// Alias for Error to satisfy the stringer interface.
-func (b baseError) String() string {
- return b.Error()
-}
-
-// Code returns the short phrase depicting the classification of the error.
-func (b baseError) Code() string {
- return b.code
-}
-
-// Message returns the error details message.
-func (b baseError) Message() string {
- return b.message
-}
-
-// OrigErr returns the original error if one was set. Nil is returned if no
-// error was set. This only returns the first element in the list. If the full
-// list is needed, use BatchedErrors.
-func (b baseError) OrigErr() error {
- switch len(b.errs) {
- case 0:
- return nil
- case 1:
- return b.errs[0]
- default:
- if err, ok := b.errs[0].(Error); ok {
- return NewBatchError(err.Code(), err.Message(), b.errs[1:])
- }
- return NewBatchError("BatchedErrors",
- "multiple errors occurred", b.errs)
- }
-}
-
-// OrigErrs returns the original errors if one was set. An empty slice is
-// returned if no error was set.
-func (b baseError) OrigErrs() []error {
- return b.errs
-}
-
-// So that the Error interface type can be included as an anonymous field
-// in the requestError struct and not conflict with the error.Error() method.
-type awsError Error
-
-// A requestError wraps a request or service error.
-//
-// Composed of baseError for code, message, and original error.
-type requestError struct {
- awsError
- statusCode int
- requestID string
- bytes []byte
-}
-
-// newRequestError returns a wrapped error with additional information for
-// request status code, and service requestID.
-//
-// Should be used to wrap all request which involve service requests. Even if
-// the request failed without a service response, but had an HTTP status code
-// that may be meaningful.
-//
-// Also wraps original errors via the baseError.
-func newRequestError(err Error, statusCode int, requestID string) *requestError {
- return &requestError{
- awsError: err,
- statusCode: statusCode,
- requestID: requestID,
- }
-}
-
-// Error returns the string representation of the error.
-// Satisfies the error interface.
-func (r requestError) Error() string {
- extra := fmt.Sprintf("status code: %d, request id: %s",
- r.statusCode, r.requestID)
- return SprintError(r.Code(), r.Message(), extra, r.OrigErr())
-}
-
-// String returns the string representation of the error.
-// Alias for Error to satisfy the stringer interface.
-func (r requestError) String() string {
- return r.Error()
-}
-
-// StatusCode returns the wrapped status code for the error
-func (r requestError) StatusCode() int {
- return r.statusCode
-}
-
-// RequestID returns the wrapped requestID
-func (r requestError) RequestID() string {
- return r.requestID
-}
-
-// OrigErrs returns the original errors if one was set. An empty slice is
-// returned if no error was set.
-func (r requestError) OrigErrs() []error {
- if b, ok := r.awsError.(BatchedErrors); ok {
- return b.OrigErrs()
- }
- return []error{r.OrigErr()}
-}
-
-type unmarshalError struct {
- awsError
- bytes []byte
-}
-
-// Error returns the string representation of the error.
-// Satisfies the error interface.
-func (e unmarshalError) Error() string {
- extra := hex.Dump(e.bytes)
- return SprintError(e.Code(), e.Message(), extra, e.OrigErr())
-}
-
-// String returns the string representation of the error.
-// Alias for Error to satisfy the stringer interface.
-func (e unmarshalError) String() string {
- return e.Error()
-}
-
-// Bytes returns the bytes that failed to unmarshal.
-func (e unmarshalError) Bytes() []byte {
- return e.bytes
-}
-
-// An error list that satisfies the golang interface
-type errorList []error
-
-// Error returns the string representation of the error.
-//
-// Satisfies the error interface.
-func (e errorList) Error() string {
- msg := ""
- // How do we want to handle the array size being zero
- if size := len(e); size > 0 {
- for i := 0; i < size; i++ {
- msg += e[i].Error()
- // We check the next index to see if it is within the slice.
- // If it is, then we append a newline. We do this, because unit tests
- // could be broken with the additional '\n'
- if i+1 < size {
- msg += "\n"
- }
- }
- }
- return msg
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/copy.go b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/copy.go
deleted file mode 100644
index 1a3d106d5c1b..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/copy.go
+++ /dev/null
@@ -1,108 +0,0 @@
-package awsutil
-
-import (
- "io"
- "reflect"
- "time"
-)
-
-// Copy deeply copies a src structure to dst. Useful for copying request and
-// response structures.
-//
-// Can copy between structs of different type, but will only copy fields which
-// are assignable, and exist in both structs. Fields which are not assignable,
-// or do not exist in both structs are ignored.
-func Copy(dst, src interface{}) {
- dstval := reflect.ValueOf(dst)
- if !dstval.IsValid() {
- panic("Copy dst cannot be nil")
- }
-
- rcopy(dstval, reflect.ValueOf(src), true)
-}
-
-// CopyOf returns a copy of src while also allocating the memory for dst.
-// src must be a pointer type or this operation will fail.
-func CopyOf(src interface{}) (dst interface{}) {
- dsti := reflect.New(reflect.TypeOf(src).Elem())
- dst = dsti.Interface()
- rcopy(dsti, reflect.ValueOf(src), true)
- return
-}
-
-// rcopy performs a recursive copy of values from the source to destination.
-//
-// root is used to skip certain aspects of the copy which are not valid
-// for the root node of a object.
-func rcopy(dst, src reflect.Value, root bool) {
- if !src.IsValid() {
- return
- }
-
- switch src.Kind() {
- case reflect.Ptr:
- if _, ok := src.Interface().(io.Reader); ok {
- if dst.Kind() == reflect.Ptr && dst.Elem().CanSet() {
- dst.Elem().Set(src)
- } else if dst.CanSet() {
- dst.Set(src)
- }
- } else {
- e := src.Type().Elem()
- if dst.CanSet() && !src.IsNil() {
- if _, ok := src.Interface().(*time.Time); !ok {
- dst.Set(reflect.New(e))
- } else {
- tempValue := reflect.New(e)
- tempValue.Elem().Set(src.Elem())
- // Sets time.Time's unexported values
- dst.Set(tempValue)
- }
- }
- if src.Elem().IsValid() {
- // Keep the current root state since the depth hasn't changed
- rcopy(dst.Elem(), src.Elem(), root)
- }
- }
- case reflect.Struct:
- t := dst.Type()
- for i := 0; i < t.NumField(); i++ {
- name := t.Field(i).Name
- srcVal := src.FieldByName(name)
- dstVal := dst.FieldByName(name)
- if srcVal.IsValid() && dstVal.CanSet() {
- rcopy(dstVal, srcVal, false)
- }
- }
- case reflect.Slice:
- if src.IsNil() {
- break
- }
-
- s := reflect.MakeSlice(src.Type(), src.Len(), src.Cap())
- dst.Set(s)
- for i := 0; i < src.Len(); i++ {
- rcopy(dst.Index(i), src.Index(i), false)
- }
- case reflect.Map:
- if src.IsNil() {
- break
- }
-
- s := reflect.MakeMap(src.Type())
- dst.Set(s)
- for _, k := range src.MapKeys() {
- v := src.MapIndex(k)
- v2 := reflect.New(v.Type()).Elem()
- rcopy(v2, v, false)
- dst.SetMapIndex(k, v2)
- }
- default:
- // Assign the value if possible. If its not assignable, the value would
- // need to be converted and the impact of that may be unexpected, or is
- // not compatible with the dst type.
- if src.Type().AssignableTo(dst.Type()) {
- dst.Set(src)
- }
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/equal.go b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/equal.go
deleted file mode 100644
index 142a7a01c527..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/equal.go
+++ /dev/null
@@ -1,27 +0,0 @@
-package awsutil
-
-import (
- "reflect"
-)
-
-// DeepEqual returns if the two values are deeply equal like reflect.DeepEqual.
-// In addition to this, this method will also dereference the input values if
-// possible so the DeepEqual performed will not fail if one parameter is a
-// pointer and the other is not.
-//
-// DeepEqual will not perform indirection of nested values of the input parameters.
-func DeepEqual(a, b interface{}) bool {
- ra := reflect.Indirect(reflect.ValueOf(a))
- rb := reflect.Indirect(reflect.ValueOf(b))
-
- if raValid, rbValid := ra.IsValid(), rb.IsValid(); !raValid && !rbValid {
- // If the elements are both nil, and of the same type they are equal
- // If they are of different types they are not equal
- return reflect.TypeOf(a) == reflect.TypeOf(b)
- } else if raValid != rbValid {
- // Both values must be valid to be equal
- return false
- }
-
- return reflect.DeepEqual(ra.Interface(), rb.Interface())
-}
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
deleted file mode 100644
index a4eb6a7f43aa..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/path_value.go
+++ /dev/null
@@ -1,221 +0,0 @@
-package awsutil
-
-import (
- "reflect"
- "regexp"
- "strconv"
- "strings"
-
- "github.com/jmespath/go-jmespath"
-)
-
-var indexRe = regexp.MustCompile(`(.+)\[(-?\d+)?\]$`)
-
-// rValuesAtPath returns a slice of values found in value v. The values
-// in v are explored recursively so all nested values are collected.
-func rValuesAtPath(v interface{}, path string, createPath, caseSensitive, nilTerm bool) []reflect.Value {
- pathparts := strings.Split(path, "||")
- if len(pathparts) > 1 {
- for _, pathpart := range pathparts {
- vals := rValuesAtPath(v, pathpart, createPath, caseSensitive, nilTerm)
- if len(vals) > 0 {
- return vals
- }
- }
- return nil
- }
-
- values := []reflect.Value{reflect.Indirect(reflect.ValueOf(v))}
- components := strings.Split(path, ".")
- for len(values) > 0 && len(components) > 0 {
- var index *int64
- var indexStar bool
- c := strings.TrimSpace(components[0])
- if c == "" { // no actual component, illegal syntax
- return nil
- } else if caseSensitive && c != "*" && strings.ToLower(c[0:1]) == c[0:1] {
- // TODO normalize case for user
- return nil // don't support unexported fields
- }
-
- // parse this component
- if m := indexRe.FindStringSubmatch(c); m != nil {
- c = m[1]
- if m[2] == "" {
- index = nil
- indexStar = true
- } else {
- i, _ := strconv.ParseInt(m[2], 10, 32)
- index = &i
- indexStar = false
- }
- }
-
- nextvals := []reflect.Value{}
- for _, value := range values {
- // pull component name out of struct member
- if value.Kind() != reflect.Struct {
- continue
- }
-
- if c == "*" { // pull all members
- for i := 0; i < value.NumField(); i++ {
- if f := reflect.Indirect(value.Field(i)); f.IsValid() {
- nextvals = append(nextvals, f)
- }
- }
- continue
- }
-
- value = value.FieldByNameFunc(func(name string) bool {
- if c == name {
- return true
- } else if !caseSensitive && strings.EqualFold(name, c) {
- return true
- }
- return false
- })
-
- if nilTerm && value.Kind() == reflect.Ptr && len(components[1:]) == 0 {
- if !value.IsNil() {
- value.Set(reflect.Zero(value.Type()))
- }
- return []reflect.Value{value}
- }
-
- if createPath && value.Kind() == reflect.Ptr && value.IsNil() {
- // TODO if the value is the terminus it should not be created
- // if the value to be set to its position is nil.
- value.Set(reflect.New(value.Type().Elem()))
- value = value.Elem()
- } else {
- value = reflect.Indirect(value)
- }
-
- if value.Kind() == reflect.Slice || value.Kind() == reflect.Map {
- if !createPath && value.IsNil() {
- value = reflect.ValueOf(nil)
- }
- }
-
- if value.IsValid() {
- nextvals = append(nextvals, value)
- }
- }
- values = nextvals
-
- if indexStar || index != nil {
- nextvals = []reflect.Value{}
- for _, valItem := range values {
- value := reflect.Indirect(valItem)
- if value.Kind() != reflect.Slice {
- continue
- }
-
- if indexStar { // grab all indices
- for i := 0; i < value.Len(); i++ {
- idx := reflect.Indirect(value.Index(i))
- if idx.IsValid() {
- nextvals = append(nextvals, idx)
- }
- }
- continue
- }
-
- // pull out index
- i := int(*index)
- if i >= value.Len() { // check out of bounds
- if createPath {
- // TODO resize slice
- } else {
- continue
- }
- } else if i < 0 { // support negative indexing
- i = value.Len() + i
- }
- value = reflect.Indirect(value.Index(i))
-
- if value.Kind() == reflect.Slice || value.Kind() == reflect.Map {
- if !createPath && value.IsNil() {
- value = reflect.ValueOf(nil)
- }
- }
-
- if value.IsValid() {
- nextvals = append(nextvals, value)
- }
- }
- values = nextvals
- }
-
- components = components[1:]
- }
- return values
-}
-
-// ValuesAtPath returns a list of values at the case insensitive lexical
-// path inside of a structure.
-func ValuesAtPath(i interface{}, path string) ([]interface{}, error) {
- result, err := jmespath.Search(path, i)
- if err != nil {
- return nil, err
- }
-
- v := reflect.ValueOf(result)
- if !v.IsValid() || (v.Kind() == reflect.Ptr && v.IsNil()) {
- return nil, nil
- }
- if s, ok := result.([]interface{}); ok {
- return s, err
- }
- if v.Kind() == reflect.Map && v.Len() == 0 {
- return nil, nil
- }
- if v.Kind() == reflect.Slice {
- out := make([]interface{}, v.Len())
- for i := 0; i < v.Len(); i++ {
- out[i] = v.Index(i).Interface()
- }
- return out, nil
- }
-
- return []interface{}{result}, nil
-}
-
-// SetValueAtPath sets a value at the case insensitive lexical path inside
-// of a structure.
-func SetValueAtPath(i interface{}, path string, v interface{}) {
- rvals := rValuesAtPath(i, path, true, false, v == nil)
- for _, rval := range rvals {
- if rval.Kind() == reflect.Ptr && rval.IsNil() {
- continue
- }
- setValue(rval, v)
- }
-}
-
-func setValue(dstVal reflect.Value, src interface{}) {
- if dstVal.Kind() == reflect.Ptr {
- dstVal = reflect.Indirect(dstVal)
- }
- srcVal := reflect.ValueOf(src)
-
- if !srcVal.IsValid() { // src is literal nil
- if dstVal.CanAddr() {
- // Convert to pointer so that pointer's value can be nil'ed
- // dstVal = dstVal.Addr()
- }
- dstVal.Set(reflect.Zero(dstVal.Type()))
-
- } else if srcVal.Kind() == reflect.Ptr {
- if srcVal.IsNil() {
- srcVal = reflect.Zero(dstVal.Type())
- } else {
- srcVal = reflect.ValueOf(src).Elem()
- }
- dstVal.Set(srcVal)
- } else {
- dstVal.Set(srcVal)
- }
-
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/prettify.go b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/prettify.go
deleted file mode 100644
index 710eb432f851..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/prettify.go
+++ /dev/null
@@ -1,113 +0,0 @@
-package awsutil
-
-import (
- "bytes"
- "fmt"
- "io"
- "reflect"
- "strings"
-)
-
-// Prettify returns the string representation of a value.
-func Prettify(i interface{}) string {
- var buf bytes.Buffer
- prettify(reflect.ValueOf(i), 0, &buf)
- return buf.String()
-}
-
-// prettify will recursively walk value v to build a textual
-// representation of the value.
-func prettify(v reflect.Value, indent int, buf *bytes.Buffer) {
- for v.Kind() == reflect.Ptr {
- v = v.Elem()
- }
-
- switch v.Kind() {
- case reflect.Struct:
- strtype := v.Type().String()
- if strtype == "time.Time" {
- fmt.Fprintf(buf, "%s", v.Interface())
- break
- } else if strings.HasPrefix(strtype, "io.") {
- buf.WriteString("")
- break
- }
-
- buf.WriteString("{\n")
-
- names := []string{}
- for i := 0; i < v.Type().NumField(); i++ {
- name := v.Type().Field(i).Name
- f := v.Field(i)
- if name[0:1] == strings.ToLower(name[0:1]) {
- continue // ignore unexported fields
- }
- if (f.Kind() == reflect.Ptr || f.Kind() == reflect.Slice || f.Kind() == reflect.Map) && f.IsNil() {
- continue // ignore unset fields
- }
- names = append(names, name)
- }
-
- for i, n := range names {
- val := v.FieldByName(n)
- buf.WriteString(strings.Repeat(" ", indent+2))
- buf.WriteString(n + ": ")
- prettify(val, indent+2, buf)
-
- if i < len(names)-1 {
- buf.WriteString(",\n")
- }
- }
-
- buf.WriteString("\n" + strings.Repeat(" ", indent) + "}")
- case reflect.Slice:
- strtype := v.Type().String()
- if strtype == "[]uint8" {
- fmt.Fprintf(buf, " len %d", v.Len())
- break
- }
-
- nl, id, id2 := "", "", ""
- if v.Len() > 3 {
- nl, id, id2 = "\n", strings.Repeat(" ", indent), strings.Repeat(" ", indent+2)
- }
- buf.WriteString("[" + nl)
- for i := 0; i < v.Len(); i++ {
- buf.WriteString(id2)
- prettify(v.Index(i), indent+2, buf)
-
- if i < v.Len()-1 {
- buf.WriteString("," + nl)
- }
- }
-
- buf.WriteString(nl + id + "]")
- case reflect.Map:
- buf.WriteString("{\n")
-
- for i, k := range v.MapKeys() {
- buf.WriteString(strings.Repeat(" ", indent+2))
- buf.WriteString(k.String() + ": ")
- prettify(v.MapIndex(k), indent+2, buf)
-
- if i < v.Len()-1 {
- buf.WriteString(",\n")
- }
- }
-
- buf.WriteString("\n" + strings.Repeat(" ", indent) + "}")
- default:
- if !v.IsValid() {
- fmt.Fprint(buf, "")
- return
- }
- format := "%v"
- switch v.Interface().(type) {
- case string:
- format = "%q"
- case io.ReadSeeker, io.Reader:
- format = "buffer(%p)"
- }
- fmt.Fprintf(buf, format, v.Interface())
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go
deleted file mode 100644
index 645df2450fc5..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go
+++ /dev/null
@@ -1,88 +0,0 @@
-package awsutil
-
-import (
- "bytes"
- "fmt"
- "reflect"
- "strings"
-)
-
-// StringValue returns the string representation of a value.
-func StringValue(i interface{}) string {
- var buf bytes.Buffer
- stringValue(reflect.ValueOf(i), 0, &buf)
- return buf.String()
-}
-
-func stringValue(v reflect.Value, indent int, buf *bytes.Buffer) {
- for v.Kind() == reflect.Ptr {
- v = v.Elem()
- }
-
- switch v.Kind() {
- case reflect.Struct:
- buf.WriteString("{\n")
-
- for i := 0; i < v.Type().NumField(); i++ {
- ft := v.Type().Field(i)
- fv := v.Field(i)
-
- if ft.Name[0:1] == strings.ToLower(ft.Name[0:1]) {
- continue // ignore unexported fields
- }
- if (fv.Kind() == reflect.Ptr || fv.Kind() == reflect.Slice) && fv.IsNil() {
- continue // ignore unset fields
- }
-
- buf.WriteString(strings.Repeat(" ", indent+2))
- buf.WriteString(ft.Name + ": ")
-
- if tag := ft.Tag.Get("sensitive"); tag == "true" {
- buf.WriteString("")
- } else {
- stringValue(fv, indent+2, buf)
- }
-
- buf.WriteString(",\n")
- }
-
- buf.WriteString("\n" + strings.Repeat(" ", indent) + "}")
- case reflect.Slice:
- nl, id, id2 := "", "", ""
- if v.Len() > 3 {
- nl, id, id2 = "\n", strings.Repeat(" ", indent), strings.Repeat(" ", indent+2)
- }
- buf.WriteString("[" + nl)
- for i := 0; i < v.Len(); i++ {
- buf.WriteString(id2)
- stringValue(v.Index(i), indent+2, buf)
-
- if i < v.Len()-1 {
- buf.WriteString("," + nl)
- }
- }
-
- buf.WriteString(nl + id + "]")
- case reflect.Map:
- buf.WriteString("{\n")
-
- for i, k := range v.MapKeys() {
- buf.WriteString(strings.Repeat(" ", indent+2))
- buf.WriteString(k.String() + ": ")
- stringValue(v.MapIndex(k), indent+2, buf)
-
- if i < v.Len()-1 {
- buf.WriteString(",\n")
- }
- }
-
- buf.WriteString("\n" + strings.Repeat(" ", indent) + "}")
- default:
- format := "%v"
- switch v.Interface().(type) {
- case string:
- format = "%q"
- }
- fmt.Fprintf(buf, format, v.Interface())
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/client.go b/vendor/github.com/aws/aws-sdk-go/aws/client/client.go
deleted file mode 100644
index 03334d69207b..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/client/client.go
+++ /dev/null
@@ -1,97 +0,0 @@
-package client
-
-import (
- "fmt"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/client/metadata"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// A Config provides configuration to a service client instance.
-type Config struct {
- Config *aws.Config
- Handlers request.Handlers
- PartitionID string
- Endpoint string
- SigningRegion string
- SigningName string
-
- // States that the signing name did not come from a modeled source but
- // was derived based on other data. Used by service client constructors
- // to determine if the signin name can be overridden based on metadata the
- // service has.
- SigningNameDerived bool
-}
-
-// ConfigProvider provides a generic way for a service client to receive
-// the ClientConfig without circular dependencies.
-type ConfigProvider interface {
- ClientConfig(serviceName string, cfgs ...*aws.Config) Config
-}
-
-// ConfigNoResolveEndpointProvider same as ConfigProvider except it will not
-// resolve the endpoint automatically. The service client's endpoint must be
-// provided via the aws.Config.Endpoint field.
-type ConfigNoResolveEndpointProvider interface {
- ClientConfigNoResolveEndpoint(cfgs ...*aws.Config) Config
-}
-
-// A Client implements the base client request and response handling
-// used by all service clients.
-type Client struct {
- request.Retryer
- metadata.ClientInfo
-
- Config aws.Config
- Handlers request.Handlers
-}
-
-// New will return a pointer to a new initialized service client.
-func New(cfg aws.Config, info metadata.ClientInfo, handlers request.Handlers, options ...func(*Client)) *Client {
- svc := &Client{
- Config: cfg,
- ClientInfo: info,
- Handlers: handlers.Copy(),
- }
-
- switch retryer, ok := cfg.Retryer.(request.Retryer); {
- case ok:
- svc.Retryer = retryer
- case cfg.Retryer != nil && cfg.Logger != nil:
- s := fmt.Sprintf("WARNING: %T does not implement request.Retryer; using DefaultRetryer instead", cfg.Retryer)
- cfg.Logger.Log(s)
- fallthrough
- default:
- maxRetries := aws.IntValue(cfg.MaxRetries)
- if cfg.MaxRetries == nil || maxRetries == aws.UseServiceDefaultRetries {
- maxRetries = DefaultRetryerMaxNumRetries
- }
- svc.Retryer = DefaultRetryer{NumMaxRetries: maxRetries}
- }
-
- svc.AddDebugHandlers()
-
- for _, option := range options {
- option(svc)
- }
-
- return svc
-}
-
-// NewRequest returns a new Request pointer for the service API
-// operation and parameters.
-func (c *Client) NewRequest(operation *request.Operation, params interface{}, data interface{}) *request.Request {
- return request.New(c.Config, c.ClientInfo, c.Handlers, c.Retryer, operation, params, data)
-}
-
-// AddDebugHandlers injects debug logging handlers into the service to log request
-// debug information.
-func (c *Client) AddDebugHandlers() {
- if !c.Config.LogLevel.AtLeast(aws.LogDebug) {
- return
- }
-
- c.Handlers.Send.PushFrontNamed(LogHTTPRequestHandler)
- c.Handlers.Send.PushBackNamed(LogHTTPResponseHandler)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/default_retryer.go b/vendor/github.com/aws/aws-sdk-go/aws/client/default_retryer.go
deleted file mode 100644
index 9f6af19dd459..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/client/default_retryer.go
+++ /dev/null
@@ -1,177 +0,0 @@
-package client
-
-import (
- "math"
- "strconv"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/internal/sdkrand"
-)
-
-// DefaultRetryer implements basic retry logic using exponential backoff for
-// most services. If you want to implement custom retry logic, you can implement the
-// request.Retryer interface.
-//
-type DefaultRetryer struct {
- // Num max Retries is the number of max retries that will be performed.
- // By default, this is zero.
- NumMaxRetries int
-
- // MinRetryDelay is the minimum retry delay after which retry will be performed.
- // If not set, the value is 0ns.
- MinRetryDelay time.Duration
-
- // MinThrottleRetryDelay is the minimum retry delay when throttled.
- // If not set, the value is 0ns.
- MinThrottleDelay time.Duration
-
- // MaxRetryDelay is the maximum retry delay before which retry must be performed.
- // If not set, the value is 0ns.
- MaxRetryDelay time.Duration
-
- // MaxThrottleDelay is the maximum retry delay when throttled.
- // If not set, the value is 0ns.
- MaxThrottleDelay time.Duration
-}
-
-const (
- // DefaultRetryerMaxNumRetries sets maximum number of retries
- DefaultRetryerMaxNumRetries = 3
-
- // DefaultRetryerMinRetryDelay sets minimum retry delay
- DefaultRetryerMinRetryDelay = 30 * time.Millisecond
-
- // DefaultRetryerMinThrottleDelay sets minimum delay when throttled
- DefaultRetryerMinThrottleDelay = 500 * time.Millisecond
-
- // DefaultRetryerMaxRetryDelay sets maximum retry delay
- DefaultRetryerMaxRetryDelay = 300 * time.Second
-
- // DefaultRetryerMaxThrottleDelay sets maximum delay when throttled
- DefaultRetryerMaxThrottleDelay = 300 * time.Second
-)
-
-// MaxRetries returns the number of maximum returns the service will use to make
-// an individual API request.
-func (d DefaultRetryer) MaxRetries() int {
- return d.NumMaxRetries
-}
-
-// setRetryerDefaults sets the default values of the retryer if not set
-func (d *DefaultRetryer) setRetryerDefaults() {
- if d.MinRetryDelay == 0 {
- d.MinRetryDelay = DefaultRetryerMinRetryDelay
- }
- if d.MaxRetryDelay == 0 {
- d.MaxRetryDelay = DefaultRetryerMaxRetryDelay
- }
- if d.MinThrottleDelay == 0 {
- d.MinThrottleDelay = DefaultRetryerMinThrottleDelay
- }
- if d.MaxThrottleDelay == 0 {
- d.MaxThrottleDelay = DefaultRetryerMaxThrottleDelay
- }
-}
-
-// RetryRules returns the delay duration before retrying this request again
-func (d DefaultRetryer) RetryRules(r *request.Request) time.Duration {
-
- // if number of max retries is zero, no retries will be performed.
- if d.NumMaxRetries == 0 {
- return 0
- }
-
- // Sets default value for retryer members
- d.setRetryerDefaults()
-
- // minDelay is the minimum retryer delay
- minDelay := d.MinRetryDelay
-
- var initialDelay time.Duration
-
- isThrottle := r.IsErrorThrottle()
- if isThrottle {
- if delay, ok := getRetryAfterDelay(r); ok {
- initialDelay = delay
- }
- minDelay = d.MinThrottleDelay
- }
-
- retryCount := r.RetryCount
-
- // maxDelay the maximum retryer delay
- maxDelay := d.MaxRetryDelay
-
- if isThrottle {
- maxDelay = d.MaxThrottleDelay
- }
-
- var delay time.Duration
-
- // Logic to cap the retry count based on the minDelay provided
- actualRetryCount := int(math.Log2(float64(minDelay))) + 1
- if actualRetryCount < 63-retryCount {
- delay = time.Duration(1< maxDelay {
- delay = getJitterDelay(maxDelay / 2)
- }
- } else {
- delay = getJitterDelay(maxDelay / 2)
- }
- return delay + initialDelay
-}
-
-// getJitterDelay returns a jittered delay for retry
-func getJitterDelay(duration time.Duration) time.Duration {
- return time.Duration(sdkrand.SeededRand.Int63n(int64(duration)) + int64(duration))
-}
-
-// ShouldRetry returns true if the request should be retried.
-func (d DefaultRetryer) ShouldRetry(r *request.Request) bool {
-
- // ShouldRetry returns false if number of max retries is 0.
- if d.NumMaxRetries == 0 {
- return false
- }
-
- // If one of the other handlers already set the retry state
- // we don't want to override it based on the service's state
- if r.Retryable != nil {
- return *r.Retryable
- }
- return r.IsErrorRetryable() || r.IsErrorThrottle()
-}
-
-// This will look in the Retry-After header, RFC 7231, for how long
-// it will wait before attempting another request
-func getRetryAfterDelay(r *request.Request) (time.Duration, bool) {
- if !canUseRetryAfterHeader(r) {
- return 0, false
- }
-
- delayStr := r.HTTPResponse.Header.Get("Retry-After")
- if len(delayStr) == 0 {
- return 0, false
- }
-
- delay, err := strconv.Atoi(delayStr)
- if err != nil {
- return 0, false
- }
-
- return time.Duration(delay) * time.Second, true
-}
-
-// Will look at the status code to see if the retry header pertains to
-// the status code.
-func canUseRetryAfterHeader(r *request.Request) bool {
- switch r.HTTPResponse.StatusCode {
- case 429:
- case 503:
- default:
- return false
- }
-
- return true
-}
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
deleted file mode 100644
index 8958c32d4e9f..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go
+++ /dev/null
@@ -1,194 +0,0 @@
-package client
-
-import (
- "bytes"
- "fmt"
- "io"
- "io/ioutil"
- "net/http/httputil"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-const logReqMsg = `DEBUG: Request %s/%s Details:
----[ REQUEST POST-SIGN ]-----------------------------
-%s
------------------------------------------------------`
-
-const logReqErrMsg = `DEBUG ERROR: Request %s/%s:
----[ REQUEST DUMP ERROR ]-----------------------------
-%s
-------------------------------------------------------`
-
-type logWriter struct {
- // Logger is what we will use to log the payload of a response.
- Logger aws.Logger
- // buf stores the contents of what has been read
- buf *bytes.Buffer
-}
-
-func (logger *logWriter) Write(b []byte) (int, error) {
- return logger.buf.Write(b)
-}
-
-type teeReaderCloser struct {
- // io.Reader will be a tee reader that is used during logging.
- // This structure will read from a body and write the contents to a logger.
- io.Reader
- // Source is used just to close when we are done reading.
- Source io.ReadCloser
-}
-
-func (reader *teeReaderCloser) Close() error {
- return reader.Source.Close()
-}
-
-// LogHTTPRequestHandler is a SDK request handler to log the HTTP request sent
-// to a service. Will include the HTTP request body if the LogLevel of the
-// request matches LogDebugWithHTTPBody.
-var LogHTTPRequestHandler = request.NamedHandler{
- Name: "awssdk.client.LogRequest",
- Fn: logRequest,
-}
-
-func logRequest(r *request.Request) {
- logBody := r.Config.LogLevel.Matches(aws.LogDebugWithHTTPBody)
- bodySeekable := aws.IsReaderSeekable(r.Body)
-
- b, err := httputil.DumpRequestOut(r.HTTPRequest, logBody)
- if err != nil {
- r.Config.Logger.Log(fmt.Sprintf(logReqErrMsg,
- r.ClientInfo.ServiceName, r.Operation.Name, err))
- return
- }
-
- if logBody {
- if !bodySeekable {
- r.SetReaderBody(aws.ReadSeekCloser(r.HTTPRequest.Body))
- }
- // Reset the request body because dumpRequest will re-wrap the
- // r.HTTPRequest's Body as a NoOpCloser and will not be reset after
- // read by the HTTP client reader.
- if err := r.Error; err != nil {
- r.Config.Logger.Log(fmt.Sprintf(logReqErrMsg,
- r.ClientInfo.ServiceName, r.Operation.Name, err))
- return
- }
- }
-
- r.Config.Logger.Log(fmt.Sprintf(logReqMsg,
- r.ClientInfo.ServiceName, r.Operation.Name, string(b)))
-}
-
-// LogHTTPRequestHeaderHandler is a SDK request handler to log the HTTP request sent
-// to a service. Will only log the HTTP request's headers. The request payload
-// will not be read.
-var LogHTTPRequestHeaderHandler = request.NamedHandler{
- Name: "awssdk.client.LogRequestHeader",
- Fn: logRequestHeader,
-}
-
-func logRequestHeader(r *request.Request) {
- b, err := httputil.DumpRequestOut(r.HTTPRequest, false)
- if err != nil {
- r.Config.Logger.Log(fmt.Sprintf(logReqErrMsg,
- r.ClientInfo.ServiceName, r.Operation.Name, err))
- return
- }
-
- r.Config.Logger.Log(fmt.Sprintf(logReqMsg,
- r.ClientInfo.ServiceName, r.Operation.Name, string(b)))
-}
-
-const logRespMsg = `DEBUG: Response %s/%s Details:
----[ RESPONSE ]--------------------------------------
-%s
------------------------------------------------------`
-
-const logRespErrMsg = `DEBUG ERROR: Response %s/%s:
----[ RESPONSE DUMP ERROR ]-----------------------------
-%s
------------------------------------------------------`
-
-// LogHTTPResponseHandler is a SDK request handler to log the HTTP response
-// received from a service. Will include the HTTP response body if the LogLevel
-// of the request matches LogDebugWithHTTPBody.
-var LogHTTPResponseHandler = request.NamedHandler{
- Name: "awssdk.client.LogResponse",
- Fn: logResponse,
-}
-
-func logResponse(r *request.Request) {
- lw := &logWriter{r.Config.Logger, bytes.NewBuffer(nil)}
-
- if r.HTTPResponse == nil {
- lw.Logger.Log(fmt.Sprintf(logRespErrMsg,
- r.ClientInfo.ServiceName, r.Operation.Name, "request's HTTPResponse is nil"))
- return
- }
-
- logBody := r.Config.LogLevel.Matches(aws.LogDebugWithHTTPBody)
- if logBody {
- r.HTTPResponse.Body = &teeReaderCloser{
- Reader: io.TeeReader(r.HTTPResponse.Body, lw),
- Source: r.HTTPResponse.Body,
- }
- }
-
- handlerFn := func(req *request.Request) {
- b, err := httputil.DumpResponse(req.HTTPResponse, false)
- if err != nil {
- lw.Logger.Log(fmt.Sprintf(logRespErrMsg,
- req.ClientInfo.ServiceName, req.Operation.Name, err))
- return
- }
-
- lw.Logger.Log(fmt.Sprintf(logRespMsg,
- req.ClientInfo.ServiceName, req.Operation.Name, string(b)))
-
- if logBody {
- b, err := ioutil.ReadAll(lw.buf)
- if err != nil {
- lw.Logger.Log(fmt.Sprintf(logRespErrMsg,
- req.ClientInfo.ServiceName, req.Operation.Name, err))
- return
- }
-
- lw.Logger.Log(string(b))
- }
- }
-
- const handlerName = "awsdk.client.LogResponse.ResponseBody"
-
- r.Handlers.Unmarshal.SetBackNamed(request.NamedHandler{
- Name: handlerName, Fn: handlerFn,
- })
- r.Handlers.UnmarshalError.SetBackNamed(request.NamedHandler{
- Name: handlerName, Fn: handlerFn,
- })
-}
-
-// LogHTTPResponseHeaderHandler is a SDK request handler to log the HTTP
-// response received from a service. Will only log the HTTP response's headers.
-// The response payload will not be read.
-var LogHTTPResponseHeaderHandler = request.NamedHandler{
- Name: "awssdk.client.LogResponseHeader",
- Fn: logResponseHeader,
-}
-
-func logResponseHeader(r *request.Request) {
- if r.Config.Logger == nil {
- return
- }
-
- b, err := httputil.DumpResponse(r.HTTPResponse, false)
- if err != nil {
- r.Config.Logger.Log(fmt.Sprintf(logRespErrMsg,
- r.ClientInfo.ServiceName, r.Operation.Name, err))
- return
- }
-
- r.Config.Logger.Log(fmt.Sprintf(logRespMsg,
- r.ClientInfo.ServiceName, r.Operation.Name, string(b)))
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/metadata/client_info.go b/vendor/github.com/aws/aws-sdk-go/aws/client/metadata/client_info.go
deleted file mode 100644
index 0c48f72e08e4..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/client/metadata/client_info.go
+++ /dev/null
@@ -1,14 +0,0 @@
-package metadata
-
-// ClientInfo wraps immutable data from the client.Client structure.
-type ClientInfo struct {
- ServiceName string
- ServiceID string
- APIVersion string
- PartitionID string
- Endpoint string
- SigningName string
- SigningRegion string
- JSONVersion string
- TargetPrefix string
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/no_op_retryer.go b/vendor/github.com/aws/aws-sdk-go/aws/client/no_op_retryer.go
deleted file mode 100644
index 881d575f0101..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/client/no_op_retryer.go
+++ /dev/null
@@ -1,28 +0,0 @@
-package client
-
-import (
- "time"
-
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// NoOpRetryer provides a retryer that performs no retries.
-// It should be used when we do not want retries to be performed.
-type NoOpRetryer struct{}
-
-// MaxRetries returns the number of maximum returns the service will use to make
-// an individual API; For NoOpRetryer the MaxRetries will always be zero.
-func (d NoOpRetryer) MaxRetries() int {
- return 0
-}
-
-// ShouldRetry will always return false for NoOpRetryer, as it should never retry.
-func (d NoOpRetryer) ShouldRetry(_ *request.Request) bool {
- return false
-}
-
-// RetryRules returns the delay duration before retrying this request again;
-// since NoOpRetryer does not retry, RetryRules always returns 0.
-func (d NoOpRetryer) RetryRules(_ *request.Request) time.Duration {
- return 0
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/config.go b/vendor/github.com/aws/aws-sdk-go/aws/config.go
deleted file mode 100644
index 3b809e8478c1..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/config.go
+++ /dev/null
@@ -1,587 +0,0 @@
-package aws
-
-import (
- "net/http"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/endpoints"
-)
-
-// UseServiceDefaultRetries instructs the config to use the service's own
-// default number of retries. This will be the default action if
-// Config.MaxRetries is nil also.
-const UseServiceDefaultRetries = -1
-
-// RequestRetryer is an alias for a type that implements the request.Retryer
-// interface.
-type RequestRetryer interface{}
-
-// A Config provides service configuration for service clients. By default,
-// all clients will use the defaults.DefaultConfig structure.
-//
-// // Create Session with MaxRetries configuration to be shared by multiple
-// // service clients.
-// sess := session.Must(session.NewSession(&aws.Config{
-// MaxRetries: aws.Int(3),
-// }))
-//
-// // Create S3 service client with a specific Region.
-// svc := s3.New(sess, &aws.Config{
-// Region: aws.String("us-west-2"),
-// })
-type Config struct {
- // Enables verbose error printing of all credential chain errors.
- // Should be used when wanting to see all errors while attempting to
- // retrieve credentials.
- CredentialsChainVerboseErrors *bool
-
- // The credentials object to use when signing requests. Defaults to a
- // chain of credential providers to search for credentials in environment
- // variables, shared credential file, and EC2 Instance Roles.
- Credentials *credentials.Credentials
-
- // An optional endpoint URL (hostname only or fully qualified URI)
- // that overrides the default generated endpoint for a client. Set this
- // to `nil` or the value to `""` to use the default generated endpoint.
- //
- // Note: You must still provide a `Region` value when specifying an
- // endpoint for a client.
- Endpoint *string
-
- // The resolver to use for looking up endpoints for AWS service clients
- // to use based on region.
- EndpointResolver endpoints.Resolver
-
- // EnforceShouldRetryCheck is used in the AfterRetryHandler to always call
- // ShouldRetry regardless of whether or not if request.Retryable is set.
- // This will utilize ShouldRetry method of custom retryers. If EnforceShouldRetryCheck
- // is not set, then ShouldRetry will only be called if request.Retryable is nil.
- // Proper handling of the request.Retryable field is important when setting this field.
- EnforceShouldRetryCheck *bool
-
- // The region to send requests to. This parameter is required and must
- // be configured globally or on a per-client basis unless otherwise
- // noted. A full list of regions is found in the "Regions and Endpoints"
- // document.
- //
- // See http://docs.aws.amazon.com/general/latest/gr/rande.html for AWS
- // Regions and Endpoints.
- Region *string
-
- // Set this to `true` to disable SSL when sending requests. Defaults
- // to `false`.
- DisableSSL *bool
-
- // The HTTP client to use when sending requests. Defaults to
- // `http.DefaultClient`.
- HTTPClient *http.Client
-
- // An integer value representing the logging level. The default log level
- // is zero (LogOff), which represents no logging. To enable logging set
- // to a LogLevel Value.
- LogLevel *LogLevelType
-
- // The logger writer interface to write logging messages to. Defaults to
- // standard out.
- Logger Logger
-
- // The maximum number of times that a request will be retried for failures.
- // Defaults to -1, which defers the max retry setting to the service
- // specific configuration.
- MaxRetries *int
-
- // Retryer guides how HTTP requests should be retried in case of
- // recoverable failures.
- //
- // When nil or the value does not implement the request.Retryer interface,
- // the client.DefaultRetryer will be used.
- //
- // When both Retryer and MaxRetries are non-nil, the former is used and
- // the latter ignored.
- //
- // To set the Retryer field in a type-safe manner and with chaining, use
- // the request.WithRetryer helper function:
- //
- // cfg := request.WithRetryer(aws.NewConfig(), myRetryer)
- //
- Retryer RequestRetryer
-
- // Disables semantic parameter validation, which validates input for
- // missing required fields and/or other semantic request input errors.
- DisableParamValidation *bool
-
- // Disables the computation of request and response checksums, e.g.,
- // CRC32 checksums in Amazon DynamoDB.
- DisableComputeChecksums *bool
-
- // Set this to `true` to force the request to use path-style addressing,
- // i.e., `http://s3.amazonaws.com/BUCKET/KEY`. By default, the S3 client
- // will use virtual hosted bucket addressing when possible
- // (`http://BUCKET.s3.amazonaws.com/KEY`).
- //
- // Note: This configuration option is specific to the Amazon S3 service.
- //
- // See http://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html
- // for Amazon S3: Virtual Hosting of Buckets
- S3ForcePathStyle *bool
-
- // Set this to `true` to disable the SDK adding the `Expect: 100-Continue`
- // header to PUT requests over 2MB of content. 100-Continue instructs the
- // HTTP client not to send the body until the service responds with a
- // `continue` status. This is useful to prevent sending the request body
- // until after the request is authenticated, and validated.
- //
- // http://docs.aws.amazon.com/AmazonS3/latest/API/RESTObjectPUT.html
- //
- // 100-Continue is only enabled for Go 1.6 and above. See `http.Transport`'s
- // `ExpectContinueTimeout` for information on adjusting the continue wait
- // timeout. https://golang.org/pkg/net/http/#Transport
- //
- // You should use this flag to disable 100-Continue if you experience issues
- // with proxies or third party S3 compatible services.
- S3Disable100Continue *bool
-
- // Set this to `true` to enable S3 Accelerate feature. For all operations
- // compatible with S3 Accelerate will use the accelerate endpoint for
- // requests. Requests not compatible will fall back to normal S3 requests.
- //
- // The bucket must be enable for accelerate to be used with S3 client with
- // accelerate enabled. If the bucket is not enabled for accelerate an error
- // will be returned. The bucket name must be DNS compatible to also work
- // with accelerate.
- S3UseAccelerate *bool
-
- // S3DisableContentMD5Validation config option is temporarily disabled,
- // For S3 GetObject API calls, #1837.
- //
- // Set this to `true` to disable the S3 service client from automatically
- // adding the ContentMD5 to S3 Object Put and Upload API calls. This option
- // will also disable the SDK from performing object ContentMD5 validation
- // on GetObject API calls.
- S3DisableContentMD5Validation *bool
-
- // Set this to `true` to have the S3 service client to use the region specified
- // in the ARN, when an ARN is provided as an argument to a bucket parameter.
- S3UseARNRegion *bool
-
- // Set this to `true` to enable the SDK to unmarshal API response header maps to
- // normalized lower case map keys.
- //
- // For example S3's X-Amz-Meta prefixed header will be unmarshaled to lower case
- // Metadata member's map keys. The value of the header in the map is unaffected.
- LowerCaseHeaderMaps *bool
-
- // Set this to `true` to disable the EC2Metadata client from overriding the
- // default http.Client's Timeout. This is helpful if you do not want the
- // EC2Metadata client to create a new http.Client. This options is only
- // meaningful if you're not already using a custom HTTP client with the
- // SDK. Enabled by default.
- //
- // Must be set and provided to the session.NewSession() in order to disable
- // the EC2Metadata overriding the timeout for default credentials chain.
- //
- // Example:
- // sess := session.Must(session.NewSession(aws.NewConfig()
- // .WithEC2MetadataDisableTimeoutOverride(true)))
- //
- // svc := s3.New(sess)
- //
- EC2MetadataDisableTimeoutOverride *bool
-
- // Instructs the endpoint to be generated for a service client to
- // be the dual stack endpoint. The dual stack endpoint will support
- // both IPv4 and IPv6 addressing.
- //
- // Setting this for a service which does not support dual stack will fail
- // to make requests. It is not recommended to set this value on the session
- // as it will apply to all service clients created with the session. Even
- // services which don't support dual stack endpoints.
- //
- // If the Endpoint config value is also provided the UseDualStack flag
- // will be ignored.
- //
- // Only supported with.
- //
- // sess := session.Must(session.NewSession())
- //
- // svc := s3.New(sess, &aws.Config{
- // UseDualStack: aws.Bool(true),
- // })
- UseDualStack *bool
-
- // SleepDelay is an override for the func the SDK will call when sleeping
- // during the lifecycle of a request. Specifically this will be used for
- // request delays. This value should only be used for testing. To adjust
- // the delay of a request see the aws/client.DefaultRetryer and
- // aws/request.Retryer.
- //
- // SleepDelay will prevent any Context from being used for canceling retry
- // delay of an API operation. It is recommended to not use SleepDelay at all
- // and specify a Retryer instead.
- SleepDelay func(time.Duration)
-
- // DisableRestProtocolURICleaning will not clean the URL path when making rest protocol requests.
- // Will default to false. This would only be used for empty directory names in s3 requests.
- //
- // Example:
- // sess := session.Must(session.NewSession(&aws.Config{
- // DisableRestProtocolURICleaning: aws.Bool(true),
- // }))
- //
- // svc := s3.New(sess)
- // out, err := svc.GetObject(&s3.GetObjectInput {
- // Bucket: aws.String("bucketname"),
- // Key: aws.String("//foo//bar//moo"),
- // })
- DisableRestProtocolURICleaning *bool
-
- // EnableEndpointDiscovery will allow for endpoint discovery on operations that
- // have the definition in its model. By default, endpoint discovery is off.
- // To use EndpointDiscovery, Endpoint should be unset or set to an empty string.
- //
- // Example:
- // sess := session.Must(session.NewSession(&aws.Config{
- // EnableEndpointDiscovery: aws.Bool(true),
- // }))
- //
- // svc := s3.New(sess)
- // out, err := svc.GetObject(&s3.GetObjectInput {
- // Bucket: aws.String("bucketname"),
- // Key: aws.String("/foo/bar/moo"),
- // })
- EnableEndpointDiscovery *bool
-
- // DisableEndpointHostPrefix will disable the SDK's behavior of prefixing
- // request endpoint hosts with modeled information.
- //
- // Disabling this feature is useful when you want to use local endpoints
- // for testing that do not support the modeled host prefix pattern.
- DisableEndpointHostPrefix *bool
-
- // STSRegionalEndpoint will enable regional or legacy endpoint resolving
- STSRegionalEndpoint endpoints.STSRegionalEndpoint
-
- // S3UsEast1RegionalEndpoint will enable regional or legacy endpoint resolving
- S3UsEast1RegionalEndpoint endpoints.S3UsEast1RegionalEndpoint
-}
-
-// NewConfig returns a new Config pointer that can be chained with builder
-// methods to set multiple configuration values inline without using pointers.
-//
-// // Create Session with MaxRetries configuration to be shared by multiple
-// // service clients.
-// sess := session.Must(session.NewSession(aws.NewConfig().
-// WithMaxRetries(3),
-// ))
-//
-// // Create S3 service client with a specific Region.
-// svc := s3.New(sess, aws.NewConfig().
-// WithRegion("us-west-2"),
-// )
-func NewConfig() *Config {
- return &Config{}
-}
-
-// WithCredentialsChainVerboseErrors sets a config verbose errors boolean and returning
-// a Config pointer.
-func (c *Config) WithCredentialsChainVerboseErrors(verboseErrs bool) *Config {
- c.CredentialsChainVerboseErrors = &verboseErrs
- return c
-}
-
-// WithCredentials sets a config Credentials value returning a Config pointer
-// for chaining.
-func (c *Config) WithCredentials(creds *credentials.Credentials) *Config {
- c.Credentials = creds
- return c
-}
-
-// WithEndpoint sets a config Endpoint value returning a Config pointer for
-// chaining.
-func (c *Config) WithEndpoint(endpoint string) *Config {
- c.Endpoint = &endpoint
- return c
-}
-
-// WithEndpointResolver sets a config EndpointResolver value returning a
-// Config pointer for chaining.
-func (c *Config) WithEndpointResolver(resolver endpoints.Resolver) *Config {
- c.EndpointResolver = resolver
- return c
-}
-
-// WithRegion sets a config Region value returning a Config pointer for
-// chaining.
-func (c *Config) WithRegion(region string) *Config {
- c.Region = ®ion
- return c
-}
-
-// WithDisableSSL sets a config DisableSSL value returning a Config pointer
-// for chaining.
-func (c *Config) WithDisableSSL(disable bool) *Config {
- c.DisableSSL = &disable
- return c
-}
-
-// WithHTTPClient sets a config HTTPClient value returning a Config pointer
-// for chaining.
-func (c *Config) WithHTTPClient(client *http.Client) *Config {
- c.HTTPClient = client
- return c
-}
-
-// WithMaxRetries sets a config MaxRetries value returning a Config pointer
-// for chaining.
-func (c *Config) WithMaxRetries(max int) *Config {
- c.MaxRetries = &max
- return c
-}
-
-// WithDisableParamValidation sets a config DisableParamValidation value
-// returning a Config pointer for chaining.
-func (c *Config) WithDisableParamValidation(disable bool) *Config {
- c.DisableParamValidation = &disable
- return c
-}
-
-// WithDisableComputeChecksums sets a config DisableComputeChecksums value
-// returning a Config pointer for chaining.
-func (c *Config) WithDisableComputeChecksums(disable bool) *Config {
- c.DisableComputeChecksums = &disable
- return c
-}
-
-// WithLogLevel sets a config LogLevel value returning a Config pointer for
-// chaining.
-func (c *Config) WithLogLevel(level LogLevelType) *Config {
- c.LogLevel = &level
- return c
-}
-
-// WithLogger sets a config Logger value returning a Config pointer for
-// chaining.
-func (c *Config) WithLogger(logger Logger) *Config {
- c.Logger = logger
- return c
-}
-
-// WithS3ForcePathStyle sets a config S3ForcePathStyle value returning a Config
-// pointer for chaining.
-func (c *Config) WithS3ForcePathStyle(force bool) *Config {
- c.S3ForcePathStyle = &force
- return c
-}
-
-// WithS3Disable100Continue sets a config S3Disable100Continue value returning
-// a Config pointer for chaining.
-func (c *Config) WithS3Disable100Continue(disable bool) *Config {
- c.S3Disable100Continue = &disable
- return c
-}
-
-// WithS3UseAccelerate sets a config S3UseAccelerate value returning a Config
-// pointer for chaining.
-func (c *Config) WithS3UseAccelerate(enable bool) *Config {
- c.S3UseAccelerate = &enable
- return c
-
-}
-
-// WithS3DisableContentMD5Validation sets a config
-// S3DisableContentMD5Validation value returning a Config pointer for chaining.
-func (c *Config) WithS3DisableContentMD5Validation(enable bool) *Config {
- c.S3DisableContentMD5Validation = &enable
- return c
-
-}
-
-// WithS3UseARNRegion sets a config S3UseARNRegion value and
-// returning a Config pointer for chaining
-func (c *Config) WithS3UseARNRegion(enable bool) *Config {
- c.S3UseARNRegion = &enable
- return c
-}
-
-// WithUseDualStack sets a config UseDualStack value returning a Config
-// pointer for chaining.
-func (c *Config) WithUseDualStack(enable bool) *Config {
- c.UseDualStack = &enable
- return c
-}
-
-// WithEC2MetadataDisableTimeoutOverride sets a config EC2MetadataDisableTimeoutOverride value
-// returning a Config pointer for chaining.
-func (c *Config) WithEC2MetadataDisableTimeoutOverride(enable bool) *Config {
- c.EC2MetadataDisableTimeoutOverride = &enable
- return c
-}
-
-// WithSleepDelay overrides the function used to sleep while waiting for the
-// next retry. Defaults to time.Sleep.
-func (c *Config) WithSleepDelay(fn func(time.Duration)) *Config {
- c.SleepDelay = fn
- return c
-}
-
-// WithEndpointDiscovery will set whether or not to use endpoint discovery.
-func (c *Config) WithEndpointDiscovery(t bool) *Config {
- c.EnableEndpointDiscovery = &t
- return c
-}
-
-// WithDisableEndpointHostPrefix will set whether or not to use modeled host prefix
-// when making requests.
-func (c *Config) WithDisableEndpointHostPrefix(t bool) *Config {
- c.DisableEndpointHostPrefix = &t
- return c
-}
-
-// MergeIn merges the passed in configs into the existing config object.
-func (c *Config) MergeIn(cfgs ...*Config) {
- for _, other := range cfgs {
- mergeInConfig(c, other)
- }
-}
-
-// WithSTSRegionalEndpoint will set whether or not to use regional endpoint flag
-// when resolving the endpoint for a service
-func (c *Config) WithSTSRegionalEndpoint(sre endpoints.STSRegionalEndpoint) *Config {
- c.STSRegionalEndpoint = sre
- return c
-}
-
-// WithS3UsEast1RegionalEndpoint will set whether or not to use regional endpoint flag
-// when resolving the endpoint for a service
-func (c *Config) WithS3UsEast1RegionalEndpoint(sre endpoints.S3UsEast1RegionalEndpoint) *Config {
- c.S3UsEast1RegionalEndpoint = sre
- return c
-}
-
-func mergeInConfig(dst *Config, other *Config) {
- if other == nil {
- return
- }
-
- if other.CredentialsChainVerboseErrors != nil {
- dst.CredentialsChainVerboseErrors = other.CredentialsChainVerboseErrors
- }
-
- if other.Credentials != nil {
- dst.Credentials = other.Credentials
- }
-
- if other.Endpoint != nil {
- dst.Endpoint = other.Endpoint
- }
-
- if other.EndpointResolver != nil {
- dst.EndpointResolver = other.EndpointResolver
- }
-
- if other.Region != nil {
- dst.Region = other.Region
- }
-
- if other.DisableSSL != nil {
- dst.DisableSSL = other.DisableSSL
- }
-
- if other.HTTPClient != nil {
- dst.HTTPClient = other.HTTPClient
- }
-
- if other.LogLevel != nil {
- dst.LogLevel = other.LogLevel
- }
-
- if other.Logger != nil {
- dst.Logger = other.Logger
- }
-
- if other.MaxRetries != nil {
- dst.MaxRetries = other.MaxRetries
- }
-
- if other.Retryer != nil {
- dst.Retryer = other.Retryer
- }
-
- if other.DisableParamValidation != nil {
- dst.DisableParamValidation = other.DisableParamValidation
- }
-
- if other.DisableComputeChecksums != nil {
- dst.DisableComputeChecksums = other.DisableComputeChecksums
- }
-
- if other.S3ForcePathStyle != nil {
- dst.S3ForcePathStyle = other.S3ForcePathStyle
- }
-
- if other.S3Disable100Continue != nil {
- dst.S3Disable100Continue = other.S3Disable100Continue
- }
-
- if other.S3UseAccelerate != nil {
- dst.S3UseAccelerate = other.S3UseAccelerate
- }
-
- if other.S3DisableContentMD5Validation != nil {
- dst.S3DisableContentMD5Validation = other.S3DisableContentMD5Validation
- }
-
- if other.S3UseARNRegion != nil {
- dst.S3UseARNRegion = other.S3UseARNRegion
- }
-
- if other.UseDualStack != nil {
- dst.UseDualStack = other.UseDualStack
- }
-
- if other.EC2MetadataDisableTimeoutOverride != nil {
- dst.EC2MetadataDisableTimeoutOverride = other.EC2MetadataDisableTimeoutOverride
- }
-
- if other.SleepDelay != nil {
- dst.SleepDelay = other.SleepDelay
- }
-
- if other.DisableRestProtocolURICleaning != nil {
- dst.DisableRestProtocolURICleaning = other.DisableRestProtocolURICleaning
- }
-
- if other.EnforceShouldRetryCheck != nil {
- dst.EnforceShouldRetryCheck = other.EnforceShouldRetryCheck
- }
-
- if other.EnableEndpointDiscovery != nil {
- dst.EnableEndpointDiscovery = other.EnableEndpointDiscovery
- }
-
- if other.DisableEndpointHostPrefix != nil {
- dst.DisableEndpointHostPrefix = other.DisableEndpointHostPrefix
- }
-
- if other.STSRegionalEndpoint != endpoints.UnsetSTSEndpoint {
- dst.STSRegionalEndpoint = other.STSRegionalEndpoint
- }
-
- if other.S3UsEast1RegionalEndpoint != endpoints.UnsetS3UsEast1Endpoint {
- dst.S3UsEast1RegionalEndpoint = other.S3UsEast1RegionalEndpoint
- }
-}
-
-// Copy will return a shallow copy of the Config object. If any additional
-// configurations are provided they will be merged into the new config returned.
-func (c *Config) Copy(cfgs ...*Config) *Config {
- dst := &Config{}
- dst.MergeIn(c)
-
- for _, cfg := range cfgs {
- dst.MergeIn(cfg)
- }
-
- return dst
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go b/vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go
deleted file mode 100644
index 2866f9a7fb9d..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go
+++ /dev/null
@@ -1,37 +0,0 @@
-// +build !go1.9
-
-package aws
-
-import "time"
-
-// Context is an copy of the Go v1.7 stdlib's context.Context interface.
-// It is represented as a SDK interface to enable you to use the "WithContext"
-// API methods with Go v1.6 and a Context type such as golang.org/x/net/context.
-//
-// See https://golang.org/pkg/context on how to use contexts.
-type Context interface {
- // Deadline returns the time when work done on behalf of this context
- // should be canceled. Deadline returns ok==false when no deadline is
- // set. Successive calls to Deadline return the same results.
- Deadline() (deadline time.Time, ok bool)
-
- // Done returns a channel that's closed when work done on behalf of this
- // context should be canceled. Done may return nil if this context can
- // never be canceled. Successive calls to Done return the same value.
- Done() <-chan struct{}
-
- // Err returns a non-nil error value after Done is closed. Err returns
- // Canceled if the context was canceled or DeadlineExceeded if the
- // context's deadline passed. No other values for Err are defined.
- // After Done is closed, successive calls to Err return the same value.
- Err() error
-
- // Value returns the value associated with this context for key, or nil
- // if no value is associated with key. Successive calls to Value with
- // the same key returns the same result.
- //
- // Use context values only for request-scoped data that transits
- // processes and API boundaries, not for passing optional parameters to
- // functions.
- Value(key interface{}) interface{}
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go b/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go
deleted file mode 100644
index 3718b26e1019..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go
+++ /dev/null
@@ -1,11 +0,0 @@
-// +build go1.9
-
-package aws
-
-import "context"
-
-// Context is an alias of the Go stdlib's context.Context interface.
-// It can be used within the SDK's API operation "WithContext" methods.
-//
-// See https://golang.org/pkg/context on how to use contexts.
-type Context = context.Context
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go b/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go
deleted file mode 100644
index 2f9446333a65..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go
+++ /dev/null
@@ -1,22 +0,0 @@
-// +build !go1.7
-
-package aws
-
-import (
- "github.com/aws/aws-sdk-go/internal/context"
-)
-
-// BackgroundContext returns a context that will never be canceled, has no
-// values, and no deadline. This context is used by the SDK to provide
-// backwards compatibility with non-context API operations and functionality.
-//
-// Go 1.6 and before:
-// This context function is equivalent to context.Background in the Go stdlib.
-//
-// Go 1.7 and later:
-// The context returned will be the value returned by context.Background()
-//
-// See https://golang.org/pkg/context for more information on Contexts.
-func BackgroundContext() Context {
- return context.BackgroundCtx
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go b/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go
deleted file mode 100644
index 9c29f29af17a..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go
+++ /dev/null
@@ -1,20 +0,0 @@
-// +build go1.7
-
-package aws
-
-import "context"
-
-// BackgroundContext returns a context that will never be canceled, has no
-// values, and no deadline. This context is used by the SDK to provide
-// backwards compatibility with non-context API operations and functionality.
-//
-// Go 1.6 and before:
-// This context function is equivalent to context.Background in the Go stdlib.
-//
-// Go 1.7 and later:
-// The context returned will be the value returned by context.Background()
-//
-// See https://golang.org/pkg/context for more information on Contexts.
-func BackgroundContext() Context {
- return context.Background()
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go b/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go
deleted file mode 100644
index 304fd156120c..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go
+++ /dev/null
@@ -1,24 +0,0 @@
-package aws
-
-import (
- "time"
-)
-
-// SleepWithContext will wait for the timer duration to expire, or the context
-// is canceled. Which ever happens first. If the context is canceled the Context's
-// error will be returned.
-//
-// Expects Context to always return a non-nil error if the Done channel is closed.
-func SleepWithContext(ctx Context, dur time.Duration) error {
- t := time.NewTimer(dur)
- defer t.Stop()
-
- select {
- case <-t.C:
- break
- case <-ctx.Done():
- return ctx.Err()
- }
-
- return nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/convert_types.go b/vendor/github.com/aws/aws-sdk-go/aws/convert_types.go
deleted file mode 100644
index 4e076c1837a7..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/convert_types.go
+++ /dev/null
@@ -1,918 +0,0 @@
-package aws
-
-import "time"
-
-// String returns a pointer to the string value passed in.
-func String(v string) *string {
- return &v
-}
-
-// StringValue returns the value of the string pointer passed in or
-// "" if the pointer is nil.
-func StringValue(v *string) string {
- if v != nil {
- return *v
- }
- return ""
-}
-
-// StringSlice converts a slice of string values into a slice of
-// string pointers
-func StringSlice(src []string) []*string {
- dst := make([]*string, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// StringValueSlice converts a slice of string pointers into a slice of
-// string values
-func StringValueSlice(src []*string) []string {
- dst := make([]string, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// StringMap converts a string map of string values into a string
-// map of string pointers
-func StringMap(src map[string]string) map[string]*string {
- dst := make(map[string]*string)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// StringValueMap converts a string map of string pointers into a string
-// map of string values
-func StringValueMap(src map[string]*string) map[string]string {
- dst := make(map[string]string)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Bool returns a pointer to the bool value passed in.
-func Bool(v bool) *bool {
- return &v
-}
-
-// BoolValue returns the value of the bool pointer passed in or
-// false if the pointer is nil.
-func BoolValue(v *bool) bool {
- if v != nil {
- return *v
- }
- return false
-}
-
-// BoolSlice converts a slice of bool values into a slice of
-// bool pointers
-func BoolSlice(src []bool) []*bool {
- dst := make([]*bool, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// BoolValueSlice converts a slice of bool pointers into a slice of
-// bool values
-func BoolValueSlice(src []*bool) []bool {
- dst := make([]bool, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// BoolMap converts a string map of bool values into a string
-// map of bool pointers
-func BoolMap(src map[string]bool) map[string]*bool {
- dst := make(map[string]*bool)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// BoolValueMap converts a string map of bool pointers into a string
-// map of bool values
-func BoolValueMap(src map[string]*bool) map[string]bool {
- dst := make(map[string]bool)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Int returns a pointer to the int value passed in.
-func Int(v int) *int {
- return &v
-}
-
-// IntValue returns the value of the int pointer passed in or
-// 0 if the pointer is nil.
-func IntValue(v *int) int {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// IntSlice converts a slice of int values into a slice of
-// int pointers
-func IntSlice(src []int) []*int {
- dst := make([]*int, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// IntValueSlice converts a slice of int pointers into a slice of
-// int values
-func IntValueSlice(src []*int) []int {
- dst := make([]int, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// IntMap converts a string map of int values into a string
-// map of int pointers
-func IntMap(src map[string]int) map[string]*int {
- dst := make(map[string]*int)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// IntValueMap converts a string map of int pointers into a string
-// map of int values
-func IntValueMap(src map[string]*int) map[string]int {
- dst := make(map[string]int)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Uint returns a pointer to the uint value passed in.
-func Uint(v uint) *uint {
- return &v
-}
-
-// UintValue returns the value of the uint pointer passed in or
-// 0 if the pointer is nil.
-func UintValue(v *uint) uint {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// UintSlice converts a slice of uint values uinto a slice of
-// uint pointers
-func UintSlice(src []uint) []*uint {
- dst := make([]*uint, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// UintValueSlice converts a slice of uint pointers uinto a slice of
-// uint values
-func UintValueSlice(src []*uint) []uint {
- dst := make([]uint, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// UintMap converts a string map of uint values uinto a string
-// map of uint pointers
-func UintMap(src map[string]uint) map[string]*uint {
- dst := make(map[string]*uint)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// UintValueMap converts a string map of uint pointers uinto a string
-// map of uint values
-func UintValueMap(src map[string]*uint) map[string]uint {
- dst := make(map[string]uint)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Int8 returns a pointer to the int8 value passed in.
-func Int8(v int8) *int8 {
- return &v
-}
-
-// Int8Value returns the value of the int8 pointer passed in or
-// 0 if the pointer is nil.
-func Int8Value(v *int8) int8 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Int8Slice converts a slice of int8 values into a slice of
-// int8 pointers
-func Int8Slice(src []int8) []*int8 {
- dst := make([]*int8, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Int8ValueSlice converts a slice of int8 pointers into a slice of
-// int8 values
-func Int8ValueSlice(src []*int8) []int8 {
- dst := make([]int8, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Int8Map converts a string map of int8 values into a string
-// map of int8 pointers
-func Int8Map(src map[string]int8) map[string]*int8 {
- dst := make(map[string]*int8)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Int8ValueMap converts a string map of int8 pointers into a string
-// map of int8 values
-func Int8ValueMap(src map[string]*int8) map[string]int8 {
- dst := make(map[string]int8)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Int16 returns a pointer to the int16 value passed in.
-func Int16(v int16) *int16 {
- return &v
-}
-
-// Int16Value returns the value of the int16 pointer passed in or
-// 0 if the pointer is nil.
-func Int16Value(v *int16) int16 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Int16Slice converts a slice of int16 values into a slice of
-// int16 pointers
-func Int16Slice(src []int16) []*int16 {
- dst := make([]*int16, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Int16ValueSlice converts a slice of int16 pointers into a slice of
-// int16 values
-func Int16ValueSlice(src []*int16) []int16 {
- dst := make([]int16, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Int16Map converts a string map of int16 values into a string
-// map of int16 pointers
-func Int16Map(src map[string]int16) map[string]*int16 {
- dst := make(map[string]*int16)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Int16ValueMap converts a string map of int16 pointers into a string
-// map of int16 values
-func Int16ValueMap(src map[string]*int16) map[string]int16 {
- dst := make(map[string]int16)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Int32 returns a pointer to the int32 value passed in.
-func Int32(v int32) *int32 {
- return &v
-}
-
-// Int32Value returns the value of the int32 pointer passed in or
-// 0 if the pointer is nil.
-func Int32Value(v *int32) int32 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Int32Slice converts a slice of int32 values into a slice of
-// int32 pointers
-func Int32Slice(src []int32) []*int32 {
- dst := make([]*int32, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Int32ValueSlice converts a slice of int32 pointers into a slice of
-// int32 values
-func Int32ValueSlice(src []*int32) []int32 {
- dst := make([]int32, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Int32Map converts a string map of int32 values into a string
-// map of int32 pointers
-func Int32Map(src map[string]int32) map[string]*int32 {
- dst := make(map[string]*int32)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Int32ValueMap converts a string map of int32 pointers into a string
-// map of int32 values
-func Int32ValueMap(src map[string]*int32) map[string]int32 {
- dst := make(map[string]int32)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Int64 returns a pointer to the int64 value passed in.
-func Int64(v int64) *int64 {
- return &v
-}
-
-// Int64Value returns the value of the int64 pointer passed in or
-// 0 if the pointer is nil.
-func Int64Value(v *int64) int64 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Int64Slice converts a slice of int64 values into a slice of
-// int64 pointers
-func Int64Slice(src []int64) []*int64 {
- dst := make([]*int64, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Int64ValueSlice converts a slice of int64 pointers into a slice of
-// int64 values
-func Int64ValueSlice(src []*int64) []int64 {
- dst := make([]int64, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Int64Map converts a string map of int64 values into a string
-// map of int64 pointers
-func Int64Map(src map[string]int64) map[string]*int64 {
- dst := make(map[string]*int64)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Int64ValueMap converts a string map of int64 pointers into a string
-// map of int64 values
-func Int64ValueMap(src map[string]*int64) map[string]int64 {
- dst := make(map[string]int64)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Uint8 returns a pointer to the uint8 value passed in.
-func Uint8(v uint8) *uint8 {
- return &v
-}
-
-// Uint8Value returns the value of the uint8 pointer passed in or
-// 0 if the pointer is nil.
-func Uint8Value(v *uint8) uint8 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Uint8Slice converts a slice of uint8 values into a slice of
-// uint8 pointers
-func Uint8Slice(src []uint8) []*uint8 {
- dst := make([]*uint8, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Uint8ValueSlice converts a slice of uint8 pointers into a slice of
-// uint8 values
-func Uint8ValueSlice(src []*uint8) []uint8 {
- dst := make([]uint8, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Uint8Map converts a string map of uint8 values into a string
-// map of uint8 pointers
-func Uint8Map(src map[string]uint8) map[string]*uint8 {
- dst := make(map[string]*uint8)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Uint8ValueMap converts a string map of uint8 pointers into a string
-// map of uint8 values
-func Uint8ValueMap(src map[string]*uint8) map[string]uint8 {
- dst := make(map[string]uint8)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Uint16 returns a pointer to the uint16 value passed in.
-func Uint16(v uint16) *uint16 {
- return &v
-}
-
-// Uint16Value returns the value of the uint16 pointer passed in or
-// 0 if the pointer is nil.
-func Uint16Value(v *uint16) uint16 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Uint16Slice converts a slice of uint16 values into a slice of
-// uint16 pointers
-func Uint16Slice(src []uint16) []*uint16 {
- dst := make([]*uint16, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Uint16ValueSlice converts a slice of uint16 pointers into a slice of
-// uint16 values
-func Uint16ValueSlice(src []*uint16) []uint16 {
- dst := make([]uint16, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Uint16Map converts a string map of uint16 values into a string
-// map of uint16 pointers
-func Uint16Map(src map[string]uint16) map[string]*uint16 {
- dst := make(map[string]*uint16)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Uint16ValueMap converts a string map of uint16 pointers into a string
-// map of uint16 values
-func Uint16ValueMap(src map[string]*uint16) map[string]uint16 {
- dst := make(map[string]uint16)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Uint32 returns a pointer to the uint32 value passed in.
-func Uint32(v uint32) *uint32 {
- return &v
-}
-
-// Uint32Value returns the value of the uint32 pointer passed in or
-// 0 if the pointer is nil.
-func Uint32Value(v *uint32) uint32 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Uint32Slice converts a slice of uint32 values into a slice of
-// uint32 pointers
-func Uint32Slice(src []uint32) []*uint32 {
- dst := make([]*uint32, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Uint32ValueSlice converts a slice of uint32 pointers into a slice of
-// uint32 values
-func Uint32ValueSlice(src []*uint32) []uint32 {
- dst := make([]uint32, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Uint32Map converts a string map of uint32 values into a string
-// map of uint32 pointers
-func Uint32Map(src map[string]uint32) map[string]*uint32 {
- dst := make(map[string]*uint32)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Uint32ValueMap converts a string map of uint32 pointers into a string
-// map of uint32 values
-func Uint32ValueMap(src map[string]*uint32) map[string]uint32 {
- dst := make(map[string]uint32)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Uint64 returns a pointer to the uint64 value passed in.
-func Uint64(v uint64) *uint64 {
- return &v
-}
-
-// Uint64Value returns the value of the uint64 pointer passed in or
-// 0 if the pointer is nil.
-func Uint64Value(v *uint64) uint64 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Uint64Slice converts a slice of uint64 values into a slice of
-// uint64 pointers
-func Uint64Slice(src []uint64) []*uint64 {
- dst := make([]*uint64, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Uint64ValueSlice converts a slice of uint64 pointers into a slice of
-// uint64 values
-func Uint64ValueSlice(src []*uint64) []uint64 {
- dst := make([]uint64, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Uint64Map converts a string map of uint64 values into a string
-// map of uint64 pointers
-func Uint64Map(src map[string]uint64) map[string]*uint64 {
- dst := make(map[string]*uint64)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Uint64ValueMap converts a string map of uint64 pointers into a string
-// map of uint64 values
-func Uint64ValueMap(src map[string]*uint64) map[string]uint64 {
- dst := make(map[string]uint64)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Float32 returns a pointer to the float32 value passed in.
-func Float32(v float32) *float32 {
- return &v
-}
-
-// Float32Value returns the value of the float32 pointer passed in or
-// 0 if the pointer is nil.
-func Float32Value(v *float32) float32 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Float32Slice converts a slice of float32 values into a slice of
-// float32 pointers
-func Float32Slice(src []float32) []*float32 {
- dst := make([]*float32, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Float32ValueSlice converts a slice of float32 pointers into a slice of
-// float32 values
-func Float32ValueSlice(src []*float32) []float32 {
- dst := make([]float32, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Float32Map converts a string map of float32 values into a string
-// map of float32 pointers
-func Float32Map(src map[string]float32) map[string]*float32 {
- dst := make(map[string]*float32)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Float32ValueMap converts a string map of float32 pointers into a string
-// map of float32 values
-func Float32ValueMap(src map[string]*float32) map[string]float32 {
- dst := make(map[string]float32)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Float64 returns a pointer to the float64 value passed in.
-func Float64(v float64) *float64 {
- return &v
-}
-
-// Float64Value returns the value of the float64 pointer passed in or
-// 0 if the pointer is nil.
-func Float64Value(v *float64) float64 {
- if v != nil {
- return *v
- }
- return 0
-}
-
-// Float64Slice converts a slice of float64 values into a slice of
-// float64 pointers
-func Float64Slice(src []float64) []*float64 {
- dst := make([]*float64, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// Float64ValueSlice converts a slice of float64 pointers into a slice of
-// float64 values
-func Float64ValueSlice(src []*float64) []float64 {
- dst := make([]float64, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// Float64Map converts a string map of float64 values into a string
-// map of float64 pointers
-func Float64Map(src map[string]float64) map[string]*float64 {
- dst := make(map[string]*float64)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// Float64ValueMap converts a string map of float64 pointers into a string
-// map of float64 values
-func Float64ValueMap(src map[string]*float64) map[string]float64 {
- dst := make(map[string]float64)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
-
-// Time returns a pointer to the time.Time value passed in.
-func Time(v time.Time) *time.Time {
- return &v
-}
-
-// TimeValue returns the value of the time.Time pointer passed in or
-// time.Time{} if the pointer is nil.
-func TimeValue(v *time.Time) time.Time {
- if v != nil {
- return *v
- }
- return time.Time{}
-}
-
-// SecondsTimeValue converts an int64 pointer to a time.Time value
-// representing seconds since Epoch or time.Time{} if the pointer is nil.
-func SecondsTimeValue(v *int64) time.Time {
- if v != nil {
- return time.Unix((*v / 1000), 0)
- }
- return time.Time{}
-}
-
-// MillisecondsTimeValue converts an int64 pointer to a time.Time value
-// representing milliseconds sinch Epoch or time.Time{} if the pointer is nil.
-func MillisecondsTimeValue(v *int64) time.Time {
- if v != nil {
- return time.Unix(0, (*v * 1000000))
- }
- return time.Time{}
-}
-
-// TimeUnixMilli returns a Unix timestamp in milliseconds from "January 1, 1970 UTC".
-// The result is undefined if the Unix time cannot be represented by an int64.
-// Which includes calling TimeUnixMilli on a zero Time is undefined.
-//
-// This utility is useful for service API's such as CloudWatch Logs which require
-// their unix time values to be in milliseconds.
-//
-// See Go stdlib https://golang.org/pkg/time/#Time.UnixNano for more information.
-func TimeUnixMilli(t time.Time) int64 {
- return t.UnixNano() / int64(time.Millisecond/time.Nanosecond)
-}
-
-// TimeSlice converts a slice of time.Time values into a slice of
-// time.Time pointers
-func TimeSlice(src []time.Time) []*time.Time {
- dst := make([]*time.Time, len(src))
- for i := 0; i < len(src); i++ {
- dst[i] = &(src[i])
- }
- return dst
-}
-
-// TimeValueSlice converts a slice of time.Time pointers into a slice of
-// time.Time values
-func TimeValueSlice(src []*time.Time) []time.Time {
- dst := make([]time.Time, len(src))
- for i := 0; i < len(src); i++ {
- if src[i] != nil {
- dst[i] = *(src[i])
- }
- }
- return dst
-}
-
-// TimeMap converts a string map of time.Time values into a string
-// map of time.Time pointers
-func TimeMap(src map[string]time.Time) map[string]*time.Time {
- dst := make(map[string]*time.Time)
- for k, val := range src {
- v := val
- dst[k] = &v
- }
- return dst
-}
-
-// TimeValueMap converts a string map of time.Time pointers into a string
-// map of time.Time values
-func TimeValueMap(src map[string]*time.Time) map[string]time.Time {
- dst := make(map[string]time.Time)
- for k, val := range src {
- if val != nil {
- dst[k] = *val
- }
- }
- return dst
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go
deleted file mode 100644
index d95a5eb54080..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go
+++ /dev/null
@@ -1,232 +0,0 @@
-package corehandlers
-
-import (
- "bytes"
- "fmt"
- "io/ioutil"
- "net/http"
- "net/url"
- "regexp"
- "strconv"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// Interface for matching types which also have a Len method.
-type lener interface {
- Len() int
-}
-
-// BuildContentLengthHandler builds the content length of a request based on the body,
-// or will use the HTTPRequest.Header's "Content-Length" if defined. If unable
-// to determine request body length and no "Content-Length" was specified it will panic.
-//
-// The Content-Length will only be added to the request if the length of the body
-// is greater than 0. If the body is empty or the current `Content-Length`
-// header is <= 0, the header will also be stripped.
-var BuildContentLengthHandler = request.NamedHandler{Name: "core.BuildContentLengthHandler", Fn: func(r *request.Request) {
- var length int64
-
- if slength := r.HTTPRequest.Header.Get("Content-Length"); slength != "" {
- length, _ = strconv.ParseInt(slength, 10, 64)
- } else {
- if r.Body != nil {
- var err error
- length, err = aws.SeekerLen(r.Body)
- if err != nil {
- r.Error = awserr.New(request.ErrCodeSerialization, "failed to get request body's length", err)
- return
- }
- }
- }
-
- if length > 0 {
- r.HTTPRequest.ContentLength = length
- r.HTTPRequest.Header.Set("Content-Length", fmt.Sprintf("%d", length))
- } else {
- r.HTTPRequest.ContentLength = 0
- r.HTTPRequest.Header.Del("Content-Length")
- }
-}}
-
-var reStatusCode = regexp.MustCompile(`^(\d{3})`)
-
-// ValidateReqSigHandler is a request handler to ensure that the request's
-// signature doesn't expire before it is sent. This can happen when a request
-// is built and signed significantly before it is sent. Or significant delays
-// occur when retrying requests that would cause the signature to expire.
-var ValidateReqSigHandler = request.NamedHandler{
- Name: "core.ValidateReqSigHandler",
- Fn: func(r *request.Request) {
- // Unsigned requests are not signed
- if r.Config.Credentials == credentials.AnonymousCredentials {
- return
- }
-
- signedTime := r.Time
- if !r.LastSignedAt.IsZero() {
- signedTime = r.LastSignedAt
- }
-
- // 5 minutes to allow for some clock skew/delays in transmission.
- // Would be improved with aws/aws-sdk-go#423
- if signedTime.Add(5 * time.Minute).After(time.Now()) {
- return
- }
-
- fmt.Println("request expired, resigning")
- r.Sign()
- },
-}
-
-// SendHandler is a request handler to send service request using HTTP client.
-var SendHandler = request.NamedHandler{
- Name: "core.SendHandler",
- Fn: func(r *request.Request) {
- sender := sendFollowRedirects
- if r.DisableFollowRedirects {
- sender = sendWithoutFollowRedirects
- }
-
- if request.NoBody == r.HTTPRequest.Body {
- // Strip off the request body if the NoBody reader was used as a
- // place holder for a request body. This prevents the SDK from
- // making requests with a request body when it would be invalid
- // to do so.
- //
- // Use a shallow copy of the http.Request to ensure the race condition
- // of transport on Body will not trigger
- reqOrig, reqCopy := r.HTTPRequest, *r.HTTPRequest
- reqCopy.Body = nil
- r.HTTPRequest = &reqCopy
- defer func() {
- r.HTTPRequest = reqOrig
- }()
- }
-
- var err error
- r.HTTPResponse, err = sender(r)
- if err != nil {
- handleSendError(r, err)
- }
- },
-}
-
-func sendFollowRedirects(r *request.Request) (*http.Response, error) {
- return r.Config.HTTPClient.Do(r.HTTPRequest)
-}
-
-func sendWithoutFollowRedirects(r *request.Request) (*http.Response, error) {
- transport := r.Config.HTTPClient.Transport
- if transport == nil {
- transport = http.DefaultTransport
- }
-
- return transport.RoundTrip(r.HTTPRequest)
-}
-
-func handleSendError(r *request.Request, err error) {
- // Prevent leaking if an HTTPResponse was returned. Clean up
- // the body.
- if r.HTTPResponse != nil {
- r.HTTPResponse.Body.Close()
- }
- // Capture the case where url.Error is returned for error processing
- // response. e.g. 301 without location header comes back as string
- // error and r.HTTPResponse is nil. Other URL redirect errors will
- // comeback in a similar method.
- if e, ok := err.(*url.Error); ok && e.Err != nil {
- if s := reStatusCode.FindStringSubmatch(e.Err.Error()); s != nil {
- code, _ := strconv.ParseInt(s[1], 10, 64)
- r.HTTPResponse = &http.Response{
- StatusCode: int(code),
- Status: http.StatusText(int(code)),
- Body: ioutil.NopCloser(bytes.NewReader([]byte{})),
- }
- return
- }
- }
- if r.HTTPResponse == nil {
- // Add a dummy request response object to ensure the HTTPResponse
- // value is consistent.
- r.HTTPResponse = &http.Response{
- StatusCode: int(0),
- Status: http.StatusText(int(0)),
- Body: ioutil.NopCloser(bytes.NewReader([]byte{})),
- }
- }
- // Catch all request errors, and let the default retrier determine
- // if the error is retryable.
- r.Error = awserr.New(request.ErrCodeRequestError, "send request failed", err)
-
- // Override the error with a context canceled error, if that was canceled.
- ctx := r.Context()
- select {
- case <-ctx.Done():
- r.Error = awserr.New(request.CanceledErrorCode,
- "request context canceled", ctx.Err())
- r.Retryable = aws.Bool(false)
- default:
- }
-}
-
-// ValidateResponseHandler is a request handler to validate service response.
-var ValidateResponseHandler = request.NamedHandler{Name: "core.ValidateResponseHandler", Fn: func(r *request.Request) {
- if r.HTTPResponse.StatusCode == 0 || r.HTTPResponse.StatusCode >= 300 {
- // this may be replaced by an UnmarshalError handler
- r.Error = awserr.New("UnknownError", "unknown error", nil)
- }
-}}
-
-// AfterRetryHandler performs final checks to determine if the request should
-// be retried and how long to delay.
-var AfterRetryHandler = request.NamedHandler{
- Name: "core.AfterRetryHandler",
- Fn: func(r *request.Request) {
- // If one of the other handlers already set the retry state
- // we don't want to override it based on the service's state
- if r.Retryable == nil || aws.BoolValue(r.Config.EnforceShouldRetryCheck) {
- r.Retryable = aws.Bool(r.ShouldRetry(r))
- }
-
- if r.WillRetry() {
- r.RetryDelay = r.RetryRules(r)
-
- if sleepFn := r.Config.SleepDelay; sleepFn != nil {
- // Support SleepDelay for backwards compatibility and testing
- sleepFn(r.RetryDelay)
- } else if err := aws.SleepWithContext(r.Context(), r.RetryDelay); err != nil {
- r.Error = awserr.New(request.CanceledErrorCode,
- "request context canceled", err)
- r.Retryable = aws.Bool(false)
- return
- }
-
- // when the expired token exception occurs the credentials
- // need to be expired locally so that the next request to
- // get credentials will trigger a credentials refresh.
- if r.IsErrorExpired() {
- r.Config.Credentials.Expire()
- }
-
- r.RetryCount++
- r.Error = nil
- }
- }}
-
-// ValidateEndpointHandler is a request handler to validate a request had the
-// appropriate Region and Endpoint set. Will set r.Error if the endpoint or
-// region is not valid.
-var ValidateEndpointHandler = request.NamedHandler{Name: "core.ValidateEndpointHandler", Fn: func(r *request.Request) {
- if r.ClientInfo.SigningRegion == "" && aws.StringValue(r.Config.Region) == "" {
- r.Error = aws.ErrMissingRegion
- } else if r.ClientInfo.Endpoint == "" {
- // Was any endpoint provided by the user, or one was derived by the
- // SDK's endpoint resolver?
- r.Error = aws.ErrMissingEndpoint
- }
-}}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/param_validator.go b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/param_validator.go
deleted file mode 100644
index 7d50b1557cc0..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/param_validator.go
+++ /dev/null
@@ -1,17 +0,0 @@
-package corehandlers
-
-import "github.com/aws/aws-sdk-go/aws/request"
-
-// ValidateParametersHandler is a request handler to validate the input parameters.
-// Validating parameters only has meaning if done prior to the request being sent.
-var ValidateParametersHandler = request.NamedHandler{Name: "core.ValidateParametersHandler", Fn: func(r *request.Request) {
- if !r.ParamsFilled() {
- return
- }
-
- if v, ok := r.Params.(request.Validator); ok {
- if err := v.Validate(); err != nil {
- r.Error = err
- }
- }
-}}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go
deleted file mode 100644
index ab69c7a6f388..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go
+++ /dev/null
@@ -1,37 +0,0 @@
-package corehandlers
-
-import (
- "os"
- "runtime"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// SDKVersionUserAgentHandler is a request handler for adding the SDK Version
-// to the user agent.
-var SDKVersionUserAgentHandler = request.NamedHandler{
- Name: "core.SDKVersionUserAgentHandler",
- Fn: request.MakeAddToUserAgentHandler(aws.SDKName, aws.SDKVersion,
- runtime.Version(), runtime.GOOS, runtime.GOARCH),
-}
-
-const execEnvVar = `AWS_EXECUTION_ENV`
-const execEnvUAKey = `exec-env`
-
-// AddHostExecEnvUserAgentHander is a request handler appending the SDK's
-// execution environment to the user agent.
-//
-// If the environment variable AWS_EXECUTION_ENV is set, its value will be
-// appended to the user agent string.
-var AddHostExecEnvUserAgentHander = request.NamedHandler{
- Name: "core.AddHostExecEnvUserAgentHander",
- Fn: func(r *request.Request) {
- v := os.Getenv(execEnvVar)
- if len(v) == 0 {
- return
- }
-
- request.AddToUserAgent(r, execEnvUAKey+"/"+v)
- },
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go
deleted file mode 100644
index 3ad1e798df80..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go
+++ /dev/null
@@ -1,100 +0,0 @@
-package credentials
-
-import (
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-var (
- // ErrNoValidProvidersFoundInChain Is returned when there are no valid
- // providers in the ChainProvider.
- //
- // This has been deprecated. For verbose error messaging set
- // aws.Config.CredentialsChainVerboseErrors to true.
- ErrNoValidProvidersFoundInChain = awserr.New("NoCredentialProviders",
- `no valid providers in chain. Deprecated.
- For verbose messaging see aws.Config.CredentialsChainVerboseErrors`,
- nil)
-)
-
-// A ChainProvider will search for a provider which returns credentials
-// and cache that provider until Retrieve is called again.
-//
-// The ChainProvider provides a way of chaining multiple providers together
-// which will pick the first available using priority order of the Providers
-// in the list.
-//
-// If none of the Providers retrieve valid credentials Value, ChainProvider's
-// Retrieve() will return the error ErrNoValidProvidersFoundInChain.
-//
-// If a Provider is found which returns valid credentials Value ChainProvider
-// will cache that Provider for all calls to IsExpired(), until Retrieve is
-// called again.
-//
-// Example of ChainProvider to be used with an EnvProvider and EC2RoleProvider.
-// In this example EnvProvider will first check if any credentials are available
-// via the environment variables. If there are none ChainProvider will check
-// the next Provider in the list, EC2RoleProvider in this case. If EC2RoleProvider
-// does not return any credentials ChainProvider will return the error
-// ErrNoValidProvidersFoundInChain
-//
-// creds := credentials.NewChainCredentials(
-// []credentials.Provider{
-// &credentials.EnvProvider{},
-// &ec2rolecreds.EC2RoleProvider{
-// Client: ec2metadata.New(sess),
-// },
-// })
-//
-// // Usage of ChainCredentials with aws.Config
-// svc := ec2.New(session.Must(session.NewSession(&aws.Config{
-// Credentials: creds,
-// })))
-//
-type ChainProvider struct {
- Providers []Provider
- curr Provider
- VerboseErrors bool
-}
-
-// NewChainCredentials returns a pointer to a new Credentials object
-// wrapping a chain of providers.
-func NewChainCredentials(providers []Provider) *Credentials {
- return NewCredentials(&ChainProvider{
- Providers: append([]Provider{}, providers...),
- })
-}
-
-// Retrieve returns the credentials value or error if no provider returned
-// without error.
-//
-// If a provider is found it will be cached and any calls to IsExpired()
-// will return the expired state of the cached provider.
-func (c *ChainProvider) Retrieve() (Value, error) {
- var errs []error
- for _, p := range c.Providers {
- creds, err := p.Retrieve()
- if err == nil {
- c.curr = p
- return creds, nil
- }
- errs = append(errs, err)
- }
- c.curr = nil
-
- var err error
- err = ErrNoValidProvidersFoundInChain
- if c.VerboseErrors {
- err = awserr.NewBatchError("NoCredentialProviders", "no valid providers in chain", errs)
- }
- return Value{}, err
-}
-
-// IsExpired will returned the expired state of the currently cached provider
-// if there is one. If there is no current provider, true will be returned.
-func (c *ChainProvider) IsExpired() bool {
- if c.curr != nil {
- return c.curr.IsExpired()
- }
-
- return true
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.5.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.5.go
deleted file mode 100644
index 5852b2648703..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.5.go
+++ /dev/null
@@ -1,22 +0,0 @@
-// +build !go1.7
-
-package credentials
-
-import (
- "github.com/aws/aws-sdk-go/internal/context"
-)
-
-// backgroundContext returns a context that will never be canceled, has no
-// values, and no deadline. This context is used by the SDK to provide
-// backwards compatibility with non-context API operations and functionality.
-//
-// Go 1.6 and before:
-// This context function is equivalent to context.Background in the Go stdlib.
-//
-// Go 1.7 and later:
-// The context returned will be the value returned by context.Background()
-//
-// See https://golang.org/pkg/context for more information on Contexts.
-func backgroundContext() Context {
- return context.BackgroundCtx
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.7.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.7.go
deleted file mode 100644
index 388b2154182d..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_background_go1.7.go
+++ /dev/null
@@ -1,20 +0,0 @@
-// +build go1.7
-
-package credentials
-
-import "context"
-
-// backgroundContext returns a context that will never be canceled, has no
-// values, and no deadline. This context is used by the SDK to provide
-// backwards compatibility with non-context API operations and functionality.
-//
-// Go 1.6 and before:
-// This context function is equivalent to context.Background in the Go stdlib.
-//
-// Go 1.7 and later:
-// The context returned will be the value returned by context.Background()
-//
-// See https://golang.org/pkg/context for more information on Contexts.
-func backgroundContext() Context {
- return context.Background()
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.5.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.5.go
deleted file mode 100644
index 8152a864add6..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.5.go
+++ /dev/null
@@ -1,39 +0,0 @@
-// +build !go1.9
-
-package credentials
-
-import "time"
-
-// Context is an copy of the Go v1.7 stdlib's context.Context interface.
-// It is represented as a SDK interface to enable you to use the "WithContext"
-// API methods with Go v1.6 and a Context type such as golang.org/x/net/context.
-//
-// This type, aws.Context, and context.Context are equivalent.
-//
-// See https://golang.org/pkg/context on how to use contexts.
-type Context interface {
- // Deadline returns the time when work done on behalf of this context
- // should be canceled. Deadline returns ok==false when no deadline is
- // set. Successive calls to Deadline return the same results.
- Deadline() (deadline time.Time, ok bool)
-
- // Done returns a channel that's closed when work done on behalf of this
- // context should be canceled. Done may return nil if this context can
- // never be canceled. Successive calls to Done return the same value.
- Done() <-chan struct{}
-
- // Err returns a non-nil error value after Done is closed. Err returns
- // Canceled if the context was canceled or DeadlineExceeded if the
- // context's deadline passed. No other values for Err are defined.
- // After Done is closed, successive calls to Err return the same value.
- Err() error
-
- // Value returns the value associated with this context for key, or nil
- // if no value is associated with key. Successive calls to Value with
- // the same key returns the same result.
- //
- // Use context values only for request-scoped data that transits
- // processes and API boundaries, not for passing optional parameters to
- // functions.
- Value(key interface{}) interface{}
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.9.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.9.go
deleted file mode 100644
index 4356edb3d5d3..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/context_go1.9.go
+++ /dev/null
@@ -1,13 +0,0 @@
-// +build go1.9
-
-package credentials
-
-import "context"
-
-// Context is an alias of the Go stdlib's context.Context interface.
-// It can be used within the SDK's API operation "WithContext" methods.
-//
-// This type, aws.Context, and context.Context are equivalent.
-//
-// See https://golang.org/pkg/context on how to use contexts.
-type Context = context.Context
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
deleted file mode 100644
index a880a3de8fe9..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go
+++ /dev/null
@@ -1,383 +0,0 @@
-// Package credentials provides credential retrieval and management
-//
-// The Credentials is the primary method of getting access to and managing
-// credentials Values. Using dependency injection retrieval of the credential
-// values is handled by a object which satisfies the Provider interface.
-//
-// By default the Credentials.Get() will cache the successful result of a
-// Provider's Retrieve() until Provider.IsExpired() returns true. At which
-// point Credentials will call Provider's Retrieve() to get new credential Value.
-//
-// The Provider is responsible for determining when credentials Value have expired.
-// It is also important to note that Credentials will always call Retrieve the
-// first time Credentials.Get() is called.
-//
-// Example of using the environment variable credentials.
-//
-// creds := credentials.NewEnvCredentials()
-//
-// // Retrieve the credentials value
-// credValue, err := creds.Get()
-// if err != nil {
-// // handle error
-// }
-//
-// Example of forcing credentials to expire and be refreshed on the next Get().
-// This may be helpful to proactively expire credentials and refresh them sooner
-// than they would naturally expire on their own.
-//
-// creds := credentials.NewCredentials(&ec2rolecreds.EC2RoleProvider{})
-// creds.Expire()
-// credsValue, err := creds.Get()
-// // New credentials will be retrieved instead of from cache.
-//
-//
-// Custom Provider
-//
-// Each Provider built into this package also provides a helper method to generate
-// a Credentials pointer setup with the provider. To use a custom Provider just
-// create a type which satisfies the Provider interface and pass it to the
-// NewCredentials method.
-//
-// type MyProvider struct{}
-// func (m *MyProvider) Retrieve() (Value, error) {...}
-// func (m *MyProvider) IsExpired() bool {...}
-//
-// creds := credentials.NewCredentials(&MyProvider{})
-// credValue, err := creds.Get()
-//
-package credentials
-
-import (
- "fmt"
- "sync"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/internal/sync/singleflight"
-)
-
-// AnonymousCredentials is an empty Credential object that can be used as
-// dummy placeholder credentials for requests that do not need signed.
-//
-// This Credentials can be used to configure a service to not sign requests
-// when making service API calls. For example, when accessing public
-// s3 buckets.
-//
-// svc := s3.New(session.Must(session.NewSession(&aws.Config{
-// Credentials: credentials.AnonymousCredentials,
-// })))
-// // Access public S3 buckets.
-var AnonymousCredentials = NewStaticCredentials("", "", "")
-
-// A Value is the AWS credentials value for individual credential fields.
-type Value struct {
- // AWS Access key ID
- AccessKeyID string
-
- // AWS Secret Access Key
- SecretAccessKey string
-
- // AWS Session Token
- SessionToken string
-
- // Provider used to get credentials
- ProviderName string
-}
-
-// HasKeys returns if the credentials Value has both AccessKeyID and
-// SecretAccessKey value set.
-func (v Value) HasKeys() bool {
- return len(v.AccessKeyID) != 0 && len(v.SecretAccessKey) != 0
-}
-
-// A Provider is the interface for any component which will provide credentials
-// Value. A provider is required to manage its own Expired state, and what to
-// be expired means.
-//
-// The Provider should not need to implement its own mutexes, because
-// that will be managed by Credentials.
-type Provider interface {
- // Retrieve returns nil if it successfully retrieved the value.
- // Error is returned if the value were not obtainable, or empty.
- Retrieve() (Value, error)
-
- // IsExpired returns if the credentials are no longer valid, and need
- // to be retrieved.
- IsExpired() bool
-}
-
-// ProviderWithContext is a Provider that can retrieve credentials with a Context
-type ProviderWithContext interface {
- Provider
-
- RetrieveWithContext(Context) (Value, error)
-}
-
-// An Expirer is an interface that Providers can implement to expose the expiration
-// time, if known. If the Provider cannot accurately provide this info,
-// it should not implement this interface.
-type Expirer interface {
- // The time at which the credentials are no longer valid
- ExpiresAt() time.Time
-}
-
-// An ErrorProvider is a stub credentials provider that always returns an error
-// this is used by the SDK when construction a known provider is not possible
-// due to an error.
-type ErrorProvider struct {
- // The error to be returned from Retrieve
- Err error
-
- // The provider name to set on the Retrieved returned Value
- ProviderName string
-}
-
-// Retrieve will always return the error that the ErrorProvider was created with.
-func (p ErrorProvider) Retrieve() (Value, error) {
- return Value{ProviderName: p.ProviderName}, p.Err
-}
-
-// IsExpired will always return not expired.
-func (p ErrorProvider) IsExpired() bool {
- return false
-}
-
-// A Expiry provides shared expiration logic to be used by credentials
-// providers to implement expiry functionality.
-//
-// The best method to use this struct is as an anonymous field within the
-// provider's struct.
-//
-// Example:
-// type EC2RoleProvider struct {
-// Expiry
-// ...
-// }
-type Expiry struct {
- // The date/time when to expire on
- expiration time.Time
-
- // If set will be used by IsExpired to determine the current time.
- // Defaults to time.Now if CurrentTime is not set. Available for testing
- // to be able to mock out the current time.
- CurrentTime func() time.Time
-}
-
-// SetExpiration sets the expiration IsExpired will check when called.
-//
-// If window is greater than 0 the expiration time will be reduced by the
-// window value.
-//
-// Using a window is helpful to trigger credentials to expire sooner than
-// the expiration time given to ensure no requests are made with expired
-// tokens.
-func (e *Expiry) SetExpiration(expiration time.Time, window time.Duration) {
- // Passed in expirations should have the monotonic clock values stripped.
- // This ensures time comparisons will be based on wall-time.
- e.expiration = expiration.Round(0)
- if window > 0 {
- e.expiration = e.expiration.Add(-window)
- }
-}
-
-// IsExpired returns if the credentials are expired.
-func (e *Expiry) IsExpired() bool {
- curTime := e.CurrentTime
- if curTime == nil {
- curTime = time.Now
- }
- return e.expiration.Before(curTime())
-}
-
-// ExpiresAt returns the expiration time of the credential
-func (e *Expiry) ExpiresAt() time.Time {
- return e.expiration
-}
-
-// A Credentials provides concurrency safe retrieval of AWS credentials Value.
-// Credentials will cache the credentials value until they expire. Once the value
-// expires the next Get will attempt to retrieve valid credentials.
-//
-// Credentials is safe to use across multiple goroutines and will manage the
-// synchronous state so the Providers do not need to implement their own
-// synchronization.
-//
-// The first Credentials.Get() will always call Provider.Retrieve() to get the
-// first instance of the credentials Value. All calls to Get() after that
-// will return the cached credentials Value until IsExpired() returns true.
-type Credentials struct {
- sf singleflight.Group
-
- m sync.RWMutex
- creds Value
- provider Provider
-}
-
-// NewCredentials returns a pointer to a new Credentials with the provider set.
-func NewCredentials(provider Provider) *Credentials {
- c := &Credentials{
- provider: provider,
- }
- return c
-}
-
-// GetWithContext returns the credentials value, or error if the credentials
-// Value failed to be retrieved. Will return early if the passed in context is
-// canceled.
-//
-// Will return the cached credentials Value if it has not expired. If the
-// credentials Value has expired the Provider's Retrieve() will be called
-// to refresh the credentials.
-//
-// If Credentials.Expire() was called the credentials Value will be force
-// expired, and the next call to Get() will cause them to be refreshed.
-//
-// Passed in Context is equivalent to aws.Context, and context.Context.
-func (c *Credentials) GetWithContext(ctx Context) (Value, error) {
- // Check if credentials are cached, and not expired.
- select {
- case curCreds, ok := <-c.asyncIsExpired():
- // ok will only be true, of the credentials were not expired. ok will
- // be false and have no value if the credentials are expired.
- if ok {
- return curCreds, nil
- }
- case <-ctx.Done():
- return Value{}, awserr.New("RequestCanceled",
- "request context canceled", ctx.Err())
- }
-
- // Cannot pass context down to the actual retrieve, because the first
- // context would cancel the whole group when there is not direct
- // association of items in the group.
- resCh := c.sf.DoChan("", func() (interface{}, error) {
- return c.singleRetrieve(&suppressedContext{ctx})
- })
- select {
- case res := <-resCh:
- return res.Val.(Value), res.Err
- case <-ctx.Done():
- return Value{}, awserr.New("RequestCanceled",
- "request context canceled", ctx.Err())
- }
-}
-
-func (c *Credentials) singleRetrieve(ctx Context) (interface{}, error) {
- c.m.Lock()
- defer c.m.Unlock()
-
- if curCreds := c.creds; !c.isExpiredLocked(curCreds) {
- return curCreds, nil
- }
-
- var creds Value
- var err error
- if p, ok := c.provider.(ProviderWithContext); ok {
- creds, err = p.RetrieveWithContext(ctx)
- } else {
- creds, err = c.provider.Retrieve()
- }
- if err == nil {
- c.creds = creds
- }
-
- return creds, err
-}
-
-// Get returns the credentials value, or error if the credentials Value failed
-// to be retrieved.
-//
-// Will return the cached credentials Value if it has not expired. If the
-// credentials Value has expired the Provider's Retrieve() will be called
-// to refresh the credentials.
-//
-// If Credentials.Expire() was called the credentials Value will be force
-// expired, and the next call to Get() will cause them to be refreshed.
-func (c *Credentials) Get() (Value, error) {
- return c.GetWithContext(backgroundContext())
-}
-
-// Expire expires the credentials and forces them to be retrieved on the
-// next call to Get().
-//
-// This will override the Provider's expired state, and force Credentials
-// to call the Provider's Retrieve().
-func (c *Credentials) Expire() {
- c.m.Lock()
- defer c.m.Unlock()
-
- c.creds = Value{}
-}
-
-// IsExpired returns if the credentials are no longer valid, and need
-// to be retrieved.
-//
-// If the Credentials were forced to be expired with Expire() this will
-// reflect that override.
-func (c *Credentials) IsExpired() bool {
- c.m.RLock()
- defer c.m.RUnlock()
-
- return c.isExpiredLocked(c.creds)
-}
-
-// asyncIsExpired returns a channel of credentials Value. If the channel is
-// closed the credentials are expired and credentials value are not empty.
-func (c *Credentials) asyncIsExpired() <-chan Value {
- ch := make(chan Value, 1)
- go func() {
- c.m.RLock()
- defer c.m.RUnlock()
-
- if curCreds := c.creds; !c.isExpiredLocked(curCreds) {
- ch <- curCreds
- }
-
- close(ch)
- }()
-
- return ch
-}
-
-// isExpiredLocked helper method wrapping the definition of expired credentials.
-func (c *Credentials) isExpiredLocked(creds interface{}) bool {
- return creds == nil || creds.(Value) == Value{} || c.provider.IsExpired()
-}
-
-// ExpiresAt provides access to the functionality of the Expirer interface of
-// the underlying Provider, if it supports that interface. Otherwise, it returns
-// an error.
-func (c *Credentials) ExpiresAt() (time.Time, error) {
- c.m.RLock()
- defer c.m.RUnlock()
-
- expirer, ok := c.provider.(Expirer)
- if !ok {
- return time.Time{}, awserr.New("ProviderNotExpirer",
- fmt.Sprintf("provider %s does not support ExpiresAt()",
- c.creds.ProviderName),
- nil)
- }
- if c.creds == (Value{}) {
- // set expiration time to the distant past
- return time.Time{}, nil
- }
- return expirer.ExpiresAt(), nil
-}
-
-type suppressedContext struct {
- Context
-}
-
-func (s *suppressedContext) Deadline() (deadline time.Time, ok bool) {
- return time.Time{}, false
-}
-
-func (s *suppressedContext) Done() <-chan struct{} {
- return nil
-}
-
-func (s *suppressedContext) Err() error {
- return nil
-}
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
deleted file mode 100644
index 92af5b7250a8..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go
+++ /dev/null
@@ -1,188 +0,0 @@
-package ec2rolecreds
-
-import (
- "bufio"
- "encoding/json"
- "fmt"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/client"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/ec2metadata"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/internal/sdkuri"
-)
-
-// ProviderName provides a name of EC2Role provider
-const ProviderName = "EC2RoleProvider"
-
-// A EC2RoleProvider retrieves credentials from the EC2 service, and keeps track if
-// those credentials are expired.
-//
-// Example how to configure the EC2RoleProvider with custom http Client, Endpoint
-// or ExpiryWindow
-//
-// p := &ec2rolecreds.EC2RoleProvider{
-// // Pass in a custom timeout to be used when requesting
-// // IAM EC2 Role credentials.
-// Client: ec2metadata.New(sess, aws.Config{
-// HTTPClient: &http.Client{Timeout: 10 * time.Second},
-// }),
-//
-// // Do not use early expiry of credentials. If a non zero value is
-// // specified the credentials will be expired early
-// ExpiryWindow: 0,
-// }
-type EC2RoleProvider struct {
- credentials.Expiry
-
- // Required EC2Metadata client to use when connecting to EC2 metadata service.
- Client *ec2metadata.EC2Metadata
-
- // ExpiryWindow will allow the credentials to trigger refreshing prior to
- // the credentials actually expiring. This is beneficial so race conditions
- // with expiring credentials do not cause request to fail unexpectedly
- // due to ExpiredTokenException exceptions.
- //
- // So a ExpiryWindow of 10s would cause calls to IsExpired() to return true
- // 10 seconds before the credentials are actually expired.
- //
- // If ExpiryWindow is 0 or less it will be ignored.
- ExpiryWindow time.Duration
-}
-
-// NewCredentials returns a pointer to a new Credentials object wrapping
-// the EC2RoleProvider. Takes a ConfigProvider to create a EC2Metadata client.
-// The ConfigProvider is satisfied by the session.Session type.
-func NewCredentials(c client.ConfigProvider, options ...func(*EC2RoleProvider)) *credentials.Credentials {
- p := &EC2RoleProvider{
- Client: ec2metadata.New(c),
- }
-
- for _, option := range options {
- option(p)
- }
-
- return credentials.NewCredentials(p)
-}
-
-// NewCredentialsWithClient returns a pointer to a new Credentials object wrapping
-// the EC2RoleProvider. Takes a EC2Metadata client to use when connecting to EC2
-// metadata service.
-func NewCredentialsWithClient(client *ec2metadata.EC2Metadata, options ...func(*EC2RoleProvider)) *credentials.Credentials {
- p := &EC2RoleProvider{
- Client: client,
- }
-
- for _, option := range options {
- option(p)
- }
-
- return credentials.NewCredentials(p)
-}
-
-// Retrieve retrieves credentials from the EC2 service.
-// Error will be returned if the request fails, or unable to extract
-// the desired credentials.
-func (m *EC2RoleProvider) Retrieve() (credentials.Value, error) {
- return m.RetrieveWithContext(aws.BackgroundContext())
-}
-
-// RetrieveWithContext retrieves credentials from the EC2 service.
-// Error will be returned if the request fails, or unable to extract
-// the desired credentials.
-func (m *EC2RoleProvider) RetrieveWithContext(ctx credentials.Context) (credentials.Value, error) {
- credsList, err := requestCredList(ctx, m.Client)
- if err != nil {
- return credentials.Value{ProviderName: ProviderName}, err
- }
-
- if len(credsList) == 0 {
- return credentials.Value{ProviderName: ProviderName}, awserr.New("EmptyEC2RoleList", "empty EC2 Role list", nil)
- }
- credsName := credsList[0]
-
- roleCreds, err := requestCred(ctx, m.Client, credsName)
- if err != nil {
- return credentials.Value{ProviderName: ProviderName}, err
- }
-
- m.SetExpiration(roleCreds.Expiration, m.ExpiryWindow)
-
- return credentials.Value{
- AccessKeyID: roleCreds.AccessKeyID,
- SecretAccessKey: roleCreds.SecretAccessKey,
- SessionToken: roleCreds.Token,
- ProviderName: ProviderName,
- }, nil
-}
-
-// A ec2RoleCredRespBody provides the shape for unmarshaling credential
-// request responses.
-type ec2RoleCredRespBody struct {
- // Success State
- Expiration time.Time
- AccessKeyID string
- SecretAccessKey string
- Token string
-
- // Error state
- Code string
- Message string
-}
-
-const iamSecurityCredsPath = "iam/security-credentials/"
-
-// requestCredList requests a list of credentials from the EC2 service.
-// If there are no credentials, or there is an error making or receiving the request
-func requestCredList(ctx aws.Context, client *ec2metadata.EC2Metadata) ([]string, error) {
- resp, err := client.GetMetadataWithContext(ctx, iamSecurityCredsPath)
- if err != nil {
- return nil, awserr.New("EC2RoleRequestError", "no EC2 instance role found", err)
- }
-
- credsList := []string{}
- s := bufio.NewScanner(strings.NewReader(resp))
- for s.Scan() {
- credsList = append(credsList, s.Text())
- }
-
- if err := s.Err(); err != nil {
- return nil, awserr.New(request.ErrCodeSerialization,
- "failed to read EC2 instance role from metadata service", err)
- }
-
- return credsList, nil
-}
-
-// requestCred requests the credentials for a specific credentials from the EC2 service.
-//
-// If the credentials cannot be found, or there is an error reading the response
-// and error will be returned.
-func requestCred(ctx aws.Context, client *ec2metadata.EC2Metadata, credsName string) (ec2RoleCredRespBody, error) {
- resp, err := client.GetMetadataWithContext(ctx, sdkuri.PathJoin(iamSecurityCredsPath, credsName))
- if err != nil {
- return ec2RoleCredRespBody{},
- awserr.New("EC2RoleRequestError",
- fmt.Sprintf("failed to get %s EC2 instance role credentials", credsName),
- err)
- }
-
- respCreds := ec2RoleCredRespBody{}
- if err := json.NewDecoder(strings.NewReader(resp)).Decode(&respCreds); err != nil {
- return ec2RoleCredRespBody{},
- awserr.New(request.ErrCodeSerialization,
- fmt.Sprintf("failed to decode %s EC2 instance role credentials", credsName),
- err)
- }
-
- if respCreds.Code != "Success" {
- // If an error code was returned something failed requesting the role.
- return ec2RoleCredRespBody{}, awserr.New(respCreds.Code, respCreds.Message, nil)
- }
-
- return respCreds, nil
-}
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
deleted file mode 100644
index 785f30d8e6c3..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go
+++ /dev/null
@@ -1,210 +0,0 @@
-// Package endpointcreds provides support for retrieving credentials from an
-// arbitrary HTTP endpoint.
-//
-// The credentials endpoint Provider can receive both static and refreshable
-// credentials that will expire. Credentials are static when an "Expiration"
-// value is not provided in the endpoint's response.
-//
-// Static credentials will never expire once they have been retrieved. The format
-// of the static credentials response:
-// {
-// "AccessKeyId" : "MUA...",
-// "SecretAccessKey" : "/7PC5om....",
-// }
-//
-// Refreshable credentials will expire within the "ExpiryWindow" of the Expiration
-// value in the response. The format of the refreshable credentials response:
-// {
-// "AccessKeyId" : "MUA...",
-// "SecretAccessKey" : "/7PC5om....",
-// "Token" : "AQoDY....=",
-// "Expiration" : "2016-02-25T06:03:31Z"
-// }
-//
-// Errors should be returned in the following format and only returned with 400
-// or 500 HTTP status codes.
-// {
-// "code": "ErrorCode",
-// "message": "Helpful error message."
-// }
-package endpointcreds
-
-import (
- "encoding/json"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/client"
- "github.com/aws/aws-sdk-go/aws/client/metadata"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol/json/jsonutil"
-)
-
-// ProviderName is the name of the credentials provider.
-const ProviderName = `CredentialsEndpointProvider`
-
-// Provider satisfies the credentials.Provider interface, and is a client to
-// retrieve credentials from an arbitrary endpoint.
-type Provider struct {
- staticCreds bool
- credentials.Expiry
-
- // Requires a AWS Client to make HTTP requests to the endpoint with.
- // the Endpoint the request will be made to is provided by the aws.Config's
- // Endpoint value.
- Client *client.Client
-
- // ExpiryWindow will allow the credentials to trigger refreshing prior to
- // the credentials actually expiring. This is beneficial so race conditions
- // with expiring credentials do not cause request to fail unexpectedly
- // due to ExpiredTokenException exceptions.
- //
- // So a ExpiryWindow of 10s would cause calls to IsExpired() to return true
- // 10 seconds before the credentials are actually expired.
- //
- // If ExpiryWindow is 0 or less it will be ignored.
- ExpiryWindow time.Duration
-
- // Optional authorization token value if set will be used as the value of
- // the Authorization header of the endpoint credential request.
- AuthorizationToken string
-}
-
-// NewProviderClient returns a credentials Provider for retrieving AWS credentials
-// from arbitrary endpoint.
-func NewProviderClient(cfg aws.Config, handlers request.Handlers, endpoint string, options ...func(*Provider)) credentials.Provider {
- p := &Provider{
- Client: client.New(
- cfg,
- metadata.ClientInfo{
- ServiceName: "CredentialsEndpoint",
- Endpoint: endpoint,
- },
- handlers,
- ),
- }
-
- p.Client.Handlers.Unmarshal.PushBack(unmarshalHandler)
- p.Client.Handlers.UnmarshalError.PushBack(unmarshalError)
- p.Client.Handlers.Validate.Clear()
- p.Client.Handlers.Validate.PushBack(validateEndpointHandler)
-
- for _, option := range options {
- option(p)
- }
-
- return p
-}
-
-// NewCredentialsClient returns a pointer to a new Credentials object
-// wrapping the endpoint credentials Provider.
-func NewCredentialsClient(cfg aws.Config, handlers request.Handlers, endpoint string, options ...func(*Provider)) *credentials.Credentials {
- return credentials.NewCredentials(NewProviderClient(cfg, handlers, endpoint, options...))
-}
-
-// IsExpired returns true if the credentials retrieved are expired, or not yet
-// retrieved.
-func (p *Provider) IsExpired() bool {
- if p.staticCreds {
- return false
- }
- return p.Expiry.IsExpired()
-}
-
-// Retrieve will attempt to request the credentials from the endpoint the Provider
-// was configured for. And error will be returned if the retrieval fails.
-func (p *Provider) Retrieve() (credentials.Value, error) {
- return p.RetrieveWithContext(aws.BackgroundContext())
-}
-
-// RetrieveWithContext will attempt to request the credentials from the endpoint the Provider
-// was configured for. And error will be returned if the retrieval fails.
-func (p *Provider) RetrieveWithContext(ctx credentials.Context) (credentials.Value, error) {
- resp, err := p.getCredentials(ctx)
- if err != nil {
- return credentials.Value{ProviderName: ProviderName},
- awserr.New("CredentialsEndpointError", "failed to load credentials", err)
- }
-
- if resp.Expiration != nil {
- p.SetExpiration(*resp.Expiration, p.ExpiryWindow)
- } else {
- p.staticCreds = true
- }
-
- return credentials.Value{
- AccessKeyID: resp.AccessKeyID,
- SecretAccessKey: resp.SecretAccessKey,
- SessionToken: resp.Token,
- ProviderName: ProviderName,
- }, nil
-}
-
-type getCredentialsOutput struct {
- Expiration *time.Time
- AccessKeyID string
- SecretAccessKey string
- Token string
-}
-
-type errorOutput struct {
- Code string `json:"code"`
- Message string `json:"message"`
-}
-
-func (p *Provider) getCredentials(ctx aws.Context) (*getCredentialsOutput, error) {
- op := &request.Operation{
- Name: "GetCredentials",
- HTTPMethod: "GET",
- }
-
- out := &getCredentialsOutput{}
- req := p.Client.NewRequest(op, nil, out)
- req.SetContext(ctx)
- req.HTTPRequest.Header.Set("Accept", "application/json")
- if authToken := p.AuthorizationToken; len(authToken) != 0 {
- req.HTTPRequest.Header.Set("Authorization", authToken)
- }
-
- return out, req.Send()
-}
-
-func validateEndpointHandler(r *request.Request) {
- if len(r.ClientInfo.Endpoint) == 0 {
- r.Error = aws.ErrMissingEndpoint
- }
-}
-
-func unmarshalHandler(r *request.Request) {
- defer r.HTTPResponse.Body.Close()
-
- out := r.Data.(*getCredentialsOutput)
- if err := json.NewDecoder(r.HTTPResponse.Body).Decode(&out); err != nil {
- r.Error = awserr.New(request.ErrCodeSerialization,
- "failed to decode endpoint credentials",
- err,
- )
- }
-}
-
-func unmarshalError(r *request.Request) {
- defer r.HTTPResponse.Body.Close()
-
- var errOut errorOutput
- err := jsonutil.UnmarshalJSONError(&errOut, r.HTTPResponse.Body)
- if err != nil {
- r.Error = awserr.NewRequestFailure(
- awserr.New(request.ErrCodeSerialization,
- "failed to decode error message", err),
- r.HTTPResponse.StatusCode,
- r.RequestID,
- )
- return
- }
-
- // Response body format is not consistent between metadata endpoints.
- // Grab the error message as a string and include that as the source error
- r.Error = awserr.New(errOut.Code, errOut.Message, nil)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go
deleted file mode 100644
index 54c5cf7333ff..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go
+++ /dev/null
@@ -1,74 +0,0 @@
-package credentials
-
-import (
- "os"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-// EnvProviderName provides a name of Env provider
-const EnvProviderName = "EnvProvider"
-
-var (
- // ErrAccessKeyIDNotFound is returned when the AWS Access Key ID can't be
- // found in the process's environment.
- ErrAccessKeyIDNotFound = awserr.New("EnvAccessKeyNotFound", "AWS_ACCESS_KEY_ID or AWS_ACCESS_KEY not found in environment", nil)
-
- // ErrSecretAccessKeyNotFound is returned when the AWS Secret Access Key
- // can't be found in the process's environment.
- ErrSecretAccessKeyNotFound = awserr.New("EnvSecretNotFound", "AWS_SECRET_ACCESS_KEY or AWS_SECRET_KEY not found in environment", nil)
-)
-
-// A EnvProvider retrieves credentials from the environment variables of the
-// running process. Environment credentials never expire.
-//
-// Environment variables used:
-//
-// * Access Key ID: AWS_ACCESS_KEY_ID or AWS_ACCESS_KEY
-//
-// * Secret Access Key: AWS_SECRET_ACCESS_KEY or AWS_SECRET_KEY
-type EnvProvider struct {
- retrieved bool
-}
-
-// NewEnvCredentials returns a pointer to a new Credentials object
-// wrapping the environment variable provider.
-func NewEnvCredentials() *Credentials {
- return NewCredentials(&EnvProvider{})
-}
-
-// Retrieve retrieves the keys from the environment.
-func (e *EnvProvider) Retrieve() (Value, error) {
- e.retrieved = false
-
- id := os.Getenv("AWS_ACCESS_KEY_ID")
- if id == "" {
- id = os.Getenv("AWS_ACCESS_KEY")
- }
-
- secret := os.Getenv("AWS_SECRET_ACCESS_KEY")
- if secret == "" {
- secret = os.Getenv("AWS_SECRET_KEY")
- }
-
- if id == "" {
- return Value{ProviderName: EnvProviderName}, ErrAccessKeyIDNotFound
- }
-
- if secret == "" {
- return Value{ProviderName: EnvProviderName}, ErrSecretAccessKeyNotFound
- }
-
- e.retrieved = true
- return Value{
- AccessKeyID: id,
- SecretAccessKey: secret,
- SessionToken: os.Getenv("AWS_SESSION_TOKEN"),
- ProviderName: EnvProviderName,
- }, nil
-}
-
-// IsExpired returns if the credentials have been retrieved.
-func (e *EnvProvider) IsExpired() bool {
- return !e.retrieved
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/example.ini b/vendor/github.com/aws/aws-sdk-go/aws/credentials/example.ini
deleted file mode 100644
index 7fc91d9d2047..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/example.ini
+++ /dev/null
@@ -1,12 +0,0 @@
-[default]
-aws_access_key_id = accessKey
-aws_secret_access_key = secret
-aws_session_token = token
-
-[no_token]
-aws_access_key_id = accessKey
-aws_secret_access_key = secret
-
-[with_colon]
-aws_access_key_id: accessKey
-aws_secret_access_key: secret
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go
deleted file mode 100644
index e62483600299..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go
+++ /dev/null
@@ -1,426 +0,0 @@
-/*
-Package processcreds is a credential Provider to retrieve `credential_process`
-credentials.
-
-WARNING: The following describes a method of sourcing credentials from an external
-process. This can potentially be dangerous, so proceed with caution. Other
-credential providers should be preferred if at all possible. If using this
-option, you should make sure that the config file is as locked down as possible
-using security best practices for your operating system.
-
-You can use credentials from a `credential_process` in a variety of ways.
-
-One way is to setup your shared config file, located in the default
-location, with the `credential_process` key and the command you want to be
-called. You also need to set the AWS_SDK_LOAD_CONFIG environment variable
-(e.g., `export AWS_SDK_LOAD_CONFIG=1`) to use the shared config file.
-
- [default]
- credential_process = /command/to/call
-
-Creating a new session will use the credential process to retrieve credentials.
-NOTE: If there are credentials in the profile you are using, the credential
-process will not be used.
-
- // Initialize a session to load credentials.
- sess, _ := session.NewSession(&aws.Config{
- Region: aws.String("us-east-1")},
- )
-
- // Create S3 service client to use the credentials.
- svc := s3.New(sess)
-
-Another way to use the `credential_process` method is by using
-`credentials.NewCredentials()` and providing a command to be executed to
-retrieve credentials:
-
- // Create credentials using the ProcessProvider.
- creds := processcreds.NewCredentials("/path/to/command")
-
- // Create service client value configured for credentials.
- svc := s3.New(sess, &aws.Config{Credentials: creds})
-
-You can set a non-default timeout for the `credential_process` with another
-constructor, `credentials.NewCredentialsTimeout()`, providing the timeout. To
-set a one minute timeout:
-
- // Create credentials using the ProcessProvider.
- creds := processcreds.NewCredentialsTimeout(
- "/path/to/command",
- time.Duration(500) * time.Millisecond)
-
-If you need more control, you can set any configurable options in the
-credentials using one or more option functions. For example, you can set a two
-minute timeout, a credential duration of 60 minutes, and a maximum stdout
-buffer size of 2k.
-
- creds := processcreds.NewCredentials(
- "/path/to/command",
- func(opt *ProcessProvider) {
- opt.Timeout = time.Duration(2) * time.Minute
- opt.Duration = time.Duration(60) * time.Minute
- opt.MaxBufSize = 2048
- })
-
-You can also use your own `exec.Cmd`:
-
- // Create an exec.Cmd
- myCommand := exec.Command("/path/to/command")
-
- // Create credentials using your exec.Cmd and custom timeout
- creds := processcreds.NewCredentialsCommand(
- myCommand,
- func(opt *processcreds.ProcessProvider) {
- opt.Timeout = time.Duration(1) * time.Second
- })
-*/
-package processcreds
-
-import (
- "bytes"
- "encoding/json"
- "fmt"
- "io"
- "io/ioutil"
- "os"
- "os/exec"
- "runtime"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/internal/sdkio"
-)
-
-const (
- // ProviderName is the name this credentials provider will label any
- // returned credentials Value with.
- ProviderName = `ProcessProvider`
-
- // ErrCodeProcessProviderParse error parsing process output
- ErrCodeProcessProviderParse = "ProcessProviderParseError"
-
- // ErrCodeProcessProviderVersion version error in output
- ErrCodeProcessProviderVersion = "ProcessProviderVersionError"
-
- // ErrCodeProcessProviderRequired required attribute missing in output
- ErrCodeProcessProviderRequired = "ProcessProviderRequiredError"
-
- // ErrCodeProcessProviderExecution execution of command failed
- ErrCodeProcessProviderExecution = "ProcessProviderExecutionError"
-
- // errMsgProcessProviderTimeout process took longer than allowed
- errMsgProcessProviderTimeout = "credential process timed out"
-
- // errMsgProcessProviderProcess process error
- errMsgProcessProviderProcess = "error in credential_process"
-
- // errMsgProcessProviderParse problem parsing output
- errMsgProcessProviderParse = "parse failed of credential_process output"
-
- // errMsgProcessProviderVersion version error in output
- errMsgProcessProviderVersion = "wrong version in process output (not 1)"
-
- // errMsgProcessProviderMissKey missing access key id in output
- errMsgProcessProviderMissKey = "missing AccessKeyId in process output"
-
- // errMsgProcessProviderMissSecret missing secret acess key in output
- errMsgProcessProviderMissSecret = "missing SecretAccessKey in process output"
-
- // errMsgProcessProviderPrepareCmd prepare of command failed
- errMsgProcessProviderPrepareCmd = "failed to prepare command"
-
- // errMsgProcessProviderEmptyCmd command must not be empty
- errMsgProcessProviderEmptyCmd = "command must not be empty"
-
- // errMsgProcessProviderPipe failed to initialize pipe
- errMsgProcessProviderPipe = "failed to initialize pipe"
-
- // DefaultDuration is the default amount of time in minutes that the
- // credentials will be valid for.
- DefaultDuration = time.Duration(15) * time.Minute
-
- // DefaultBufSize limits buffer size from growing to an enormous
- // amount due to a faulty process.
- DefaultBufSize = int(8 * sdkio.KibiByte)
-
- // DefaultTimeout default limit on time a process can run.
- DefaultTimeout = time.Duration(1) * time.Minute
-)
-
-// ProcessProvider satisfies the credentials.Provider interface, and is a
-// client to retrieve credentials from a process.
-type ProcessProvider struct {
- staticCreds bool
- credentials.Expiry
- originalCommand []string
-
- // Expiry duration of the credentials. Defaults to 15 minutes if not set.
- Duration time.Duration
-
- // ExpiryWindow will allow the credentials to trigger refreshing prior to
- // the credentials actually expiring. This is beneficial so race conditions
- // with expiring credentials do not cause request to fail unexpectedly
- // due to ExpiredTokenException exceptions.
- //
- // So a ExpiryWindow of 10s would cause calls to IsExpired() to return true
- // 10 seconds before the credentials are actually expired.
- //
- // If ExpiryWindow is 0 or less it will be ignored.
- ExpiryWindow time.Duration
-
- // A string representing an os command that should return a JSON with
- // credential information.
- command *exec.Cmd
-
- // MaxBufSize limits memory usage from growing to an enormous
- // amount due to a faulty process.
- MaxBufSize int
-
- // Timeout limits the time a process can run.
- Timeout time.Duration
-}
-
-// NewCredentials returns a pointer to a new Credentials object wrapping the
-// ProcessProvider. The credentials will expire every 15 minutes by default.
-func NewCredentials(command string, options ...func(*ProcessProvider)) *credentials.Credentials {
- p := &ProcessProvider{
- command: exec.Command(command),
- Duration: DefaultDuration,
- Timeout: DefaultTimeout,
- MaxBufSize: DefaultBufSize,
- }
-
- for _, option := range options {
- option(p)
- }
-
- return credentials.NewCredentials(p)
-}
-
-// NewCredentialsTimeout returns a pointer to a new Credentials object with
-// the specified command and timeout, and default duration and max buffer size.
-func NewCredentialsTimeout(command string, timeout time.Duration) *credentials.Credentials {
- p := NewCredentials(command, func(opt *ProcessProvider) {
- opt.Timeout = timeout
- })
-
- return p
-}
-
-// NewCredentialsCommand returns a pointer to a new Credentials object with
-// the specified command, and default timeout, duration and max buffer size.
-func NewCredentialsCommand(command *exec.Cmd, options ...func(*ProcessProvider)) *credentials.Credentials {
- p := &ProcessProvider{
- command: command,
- Duration: DefaultDuration,
- Timeout: DefaultTimeout,
- MaxBufSize: DefaultBufSize,
- }
-
- for _, option := range options {
- option(p)
- }
-
- return credentials.NewCredentials(p)
-}
-
-type credentialProcessResponse struct {
- Version int
- AccessKeyID string `json:"AccessKeyId"`
- SecretAccessKey string
- SessionToken string
- Expiration *time.Time
-}
-
-// Retrieve executes the 'credential_process' and returns the credentials.
-func (p *ProcessProvider) Retrieve() (credentials.Value, error) {
- out, err := p.executeCredentialProcess()
- if err != nil {
- return credentials.Value{ProviderName: ProviderName}, err
- }
-
- // Serialize and validate response
- resp := &credentialProcessResponse{}
- if err = json.Unmarshal(out, resp); err != nil {
- return credentials.Value{ProviderName: ProviderName}, awserr.New(
- ErrCodeProcessProviderParse,
- fmt.Sprintf("%s: %s", errMsgProcessProviderParse, string(out)),
- err)
- }
-
- if resp.Version != 1 {
- return credentials.Value{ProviderName: ProviderName}, awserr.New(
- ErrCodeProcessProviderVersion,
- errMsgProcessProviderVersion,
- nil)
- }
-
- if len(resp.AccessKeyID) == 0 {
- return credentials.Value{ProviderName: ProviderName}, awserr.New(
- ErrCodeProcessProviderRequired,
- errMsgProcessProviderMissKey,
- nil)
- }
-
- if len(resp.SecretAccessKey) == 0 {
- return credentials.Value{ProviderName: ProviderName}, awserr.New(
- ErrCodeProcessProviderRequired,
- errMsgProcessProviderMissSecret,
- nil)
- }
-
- // Handle expiration
- p.staticCreds = resp.Expiration == nil
- if resp.Expiration != nil {
- p.SetExpiration(*resp.Expiration, p.ExpiryWindow)
- }
-
- return credentials.Value{
- ProviderName: ProviderName,
- AccessKeyID: resp.AccessKeyID,
- SecretAccessKey: resp.SecretAccessKey,
- SessionToken: resp.SessionToken,
- }, nil
-}
-
-// IsExpired returns true if the credentials retrieved are expired, or not yet
-// retrieved.
-func (p *ProcessProvider) IsExpired() bool {
- if p.staticCreds {
- return false
- }
- return p.Expiry.IsExpired()
-}
-
-// prepareCommand prepares the command to be executed.
-func (p *ProcessProvider) prepareCommand() error {
-
- var cmdArgs []string
- if runtime.GOOS == "windows" {
- cmdArgs = []string{"cmd.exe", "/C"}
- } else {
- cmdArgs = []string{"sh", "-c"}
- }
-
- if len(p.originalCommand) == 0 {
- p.originalCommand = make([]string, len(p.command.Args))
- copy(p.originalCommand, p.command.Args)
-
- // check for empty command because it succeeds
- if len(strings.TrimSpace(p.originalCommand[0])) < 1 {
- return awserr.New(
- ErrCodeProcessProviderExecution,
- fmt.Sprintf(
- "%s: %s",
- errMsgProcessProviderPrepareCmd,
- errMsgProcessProviderEmptyCmd),
- nil)
- }
- }
-
- cmdArgs = append(cmdArgs, p.originalCommand...)
- p.command = exec.Command(cmdArgs[0], cmdArgs[1:]...)
- p.command.Env = os.Environ()
-
- return nil
-}
-
-// executeCredentialProcess starts the credential process on the OS and
-// returns the results or an error.
-func (p *ProcessProvider) executeCredentialProcess() ([]byte, error) {
-
- if err := p.prepareCommand(); err != nil {
- return nil, err
- }
-
- // Setup the pipes
- outReadPipe, outWritePipe, err := os.Pipe()
- if err != nil {
- return nil, awserr.New(
- ErrCodeProcessProviderExecution,
- errMsgProcessProviderPipe,
- err)
- }
-
- p.command.Stderr = os.Stderr // display stderr on console for MFA
- p.command.Stdout = outWritePipe // get creds json on process's stdout
- p.command.Stdin = os.Stdin // enable stdin for MFA
-
- output := bytes.NewBuffer(make([]byte, 0, p.MaxBufSize))
-
- stdoutCh := make(chan error, 1)
- go readInput(
- io.LimitReader(outReadPipe, int64(p.MaxBufSize)),
- output,
- stdoutCh)
-
- execCh := make(chan error, 1)
- go executeCommand(*p.command, execCh)
-
- finished := false
- var errors []error
- for !finished {
- select {
- case readError := <-stdoutCh:
- errors = appendError(errors, readError)
- finished = true
- case execError := <-execCh:
- err := outWritePipe.Close()
- errors = appendError(errors, err)
- errors = appendError(errors, execError)
- if errors != nil {
- return output.Bytes(), awserr.NewBatchError(
- ErrCodeProcessProviderExecution,
- errMsgProcessProviderProcess,
- errors)
- }
- case <-time.After(p.Timeout):
- finished = true
- return output.Bytes(), awserr.NewBatchError(
- ErrCodeProcessProviderExecution,
- errMsgProcessProviderTimeout,
- errors) // errors can be nil
- }
- }
-
- out := output.Bytes()
-
- if runtime.GOOS == "windows" {
- // windows adds slashes to quotes
- out = []byte(strings.Replace(string(out), `\"`, `"`, -1))
- }
-
- return out, nil
-}
-
-// appendError conveniently checks for nil before appending slice
-func appendError(errors []error, err error) []error {
- if err != nil {
- return append(errors, err)
- }
- return errors
-}
-
-func executeCommand(cmd exec.Cmd, exec chan error) {
- // Start the command
- err := cmd.Start()
- if err == nil {
- err = cmd.Wait()
- }
-
- exec <- err
-}
-
-func readInput(r io.Reader, w io.Writer, read chan error) {
- tee := io.TeeReader(r, w)
-
- _, err := ioutil.ReadAll(tee)
-
- if err == io.EOF {
- err = nil
- }
-
- read <- err // will only arrive here when write end of pipe is closed
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go
deleted file mode 100644
index 22b5c5d9f322..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go
+++ /dev/null
@@ -1,151 +0,0 @@
-package credentials
-
-import (
- "fmt"
- "os"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/internal/ini"
- "github.com/aws/aws-sdk-go/internal/shareddefaults"
-)
-
-// SharedCredsProviderName provides a name of SharedCreds provider
-const SharedCredsProviderName = "SharedCredentialsProvider"
-
-var (
- // ErrSharedCredentialsHomeNotFound is emitted when the user directory cannot be found.
- ErrSharedCredentialsHomeNotFound = awserr.New("UserHomeNotFound", "user home directory not found.", nil)
-)
-
-// A SharedCredentialsProvider retrieves access key pair (access key ID,
-// secret access key, and session token if present) credentials from the current
-// user's home directory, and keeps track if those credentials are expired.
-//
-// Profile ini file example: $HOME/.aws/credentials
-type SharedCredentialsProvider struct {
- // Path to the shared credentials file.
- //
- // If empty will look for "AWS_SHARED_CREDENTIALS_FILE" env variable. If the
- // env value is empty will default to current user's home directory.
- // Linux/OSX: "$HOME/.aws/credentials"
- // Windows: "%USERPROFILE%\.aws\credentials"
- Filename string
-
- // AWS Profile to extract credentials from the shared credentials file. If empty
- // will default to environment variable "AWS_PROFILE" or "default" if
- // environment variable is also not set.
- Profile string
-
- // retrieved states if the credentials have been successfully retrieved.
- retrieved bool
-}
-
-// NewSharedCredentials returns a pointer to a new Credentials object
-// wrapping the Profile file provider.
-func NewSharedCredentials(filename, profile string) *Credentials {
- return NewCredentials(&SharedCredentialsProvider{
- Filename: filename,
- Profile: profile,
- })
-}
-
-// Retrieve reads and extracts the shared credentials from the current
-// users home directory.
-func (p *SharedCredentialsProvider) Retrieve() (Value, error) {
- p.retrieved = false
-
- filename, err := p.filename()
- if err != nil {
- return Value{ProviderName: SharedCredsProviderName}, err
- }
-
- creds, err := loadProfile(filename, p.profile())
- if err != nil {
- return Value{ProviderName: SharedCredsProviderName}, err
- }
-
- p.retrieved = true
- return creds, nil
-}
-
-// IsExpired returns if the shared credentials have expired.
-func (p *SharedCredentialsProvider) IsExpired() bool {
- return !p.retrieved
-}
-
-// loadProfiles loads from the file pointed to by shared credentials filename for profile.
-// The credentials retrieved from the profile will be returned or error. Error will be
-// returned if it fails to read from the file, or the data is invalid.
-func loadProfile(filename, profile string) (Value, error) {
- config, err := ini.OpenFile(filename)
- if err != nil {
- return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsLoad", "failed to load shared credentials file", err)
- }
-
- iniProfile, ok := config.GetSection(profile)
- if !ok {
- return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsLoad", "failed to get profile", nil)
- }
-
- id := iniProfile.String("aws_access_key_id")
- if len(id) == 0 {
- return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsAccessKey",
- fmt.Sprintf("shared credentials %s in %s did not contain aws_access_key_id", profile, filename),
- nil)
- }
-
- secret := iniProfile.String("aws_secret_access_key")
- if len(secret) == 0 {
- return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsSecret",
- fmt.Sprintf("shared credentials %s in %s did not contain aws_secret_access_key", profile, filename),
- nil)
- }
-
- // Default to empty string if not found
- token := iniProfile.String("aws_session_token")
-
- return Value{
- AccessKeyID: id,
- SecretAccessKey: secret,
- SessionToken: token,
- ProviderName: SharedCredsProviderName,
- }, nil
-}
-
-// filename returns the filename to use to read AWS shared credentials.
-//
-// Will return an error if the user's home directory path cannot be found.
-func (p *SharedCredentialsProvider) filename() (string, error) {
- if len(p.Filename) != 0 {
- return p.Filename, nil
- }
-
- if p.Filename = os.Getenv("AWS_SHARED_CREDENTIALS_FILE"); len(p.Filename) != 0 {
- return p.Filename, nil
- }
-
- if home := shareddefaults.UserHomeDir(); len(home) == 0 {
- // Backwards compatibility of home directly not found error being returned.
- // This error is too verbose, failure when opening the file would of been
- // a better error to return.
- return "", ErrSharedCredentialsHomeNotFound
- }
-
- p.Filename = shareddefaults.SharedCredentialsFilename()
-
- return p.Filename, nil
-}
-
-// profile returns the AWS shared credentials profile. If empty will read
-// environment variable "AWS_PROFILE". If that is not set profile will
-// return "default".
-func (p *SharedCredentialsProvider) profile() string {
- if p.Profile == "" {
- p.Profile = os.Getenv("AWS_PROFILE")
- }
- if p.Profile == "" {
- p.Profile = "default"
- }
-
- return p.Profile
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go
deleted file mode 100644
index cbba1e3d560c..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go
+++ /dev/null
@@ -1,57 +0,0 @@
-package credentials
-
-import (
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-// StaticProviderName provides a name of Static provider
-const StaticProviderName = "StaticProvider"
-
-var (
- // ErrStaticCredentialsEmpty is emitted when static credentials are empty.
- ErrStaticCredentialsEmpty = awserr.New("EmptyStaticCreds", "static credentials are empty", nil)
-)
-
-// A StaticProvider is a set of credentials which are set programmatically,
-// and will never expire.
-type StaticProvider struct {
- Value
-}
-
-// NewStaticCredentials returns a pointer to a new Credentials object
-// wrapping a static credentials value provider. Token is only required
-// for temporary security credentials retrieved via STS, otherwise an empty
-// string can be passed for this parameter.
-func NewStaticCredentials(id, secret, token string) *Credentials {
- return NewCredentials(&StaticProvider{Value: Value{
- AccessKeyID: id,
- SecretAccessKey: secret,
- SessionToken: token,
- }})
-}
-
-// NewStaticCredentialsFromCreds returns a pointer to a new Credentials object
-// wrapping the static credentials value provide. Same as NewStaticCredentials
-// but takes the creds Value instead of individual fields
-func NewStaticCredentialsFromCreds(creds Value) *Credentials {
- return NewCredentials(&StaticProvider{Value: creds})
-}
-
-// Retrieve returns the credentials or error if the credentials are invalid.
-func (s *StaticProvider) Retrieve() (Value, error) {
- if s.AccessKeyID == "" || s.SecretAccessKey == "" {
- return Value{ProviderName: StaticProviderName}, ErrStaticCredentialsEmpty
- }
-
- if len(s.Value.ProviderName) == 0 {
- s.Value.ProviderName = StaticProviderName
- }
- return s.Value, nil
-}
-
-// IsExpired returns if the credentials are expired.
-//
-// For StaticProvider, the credentials never expired.
-func (s *StaticProvider) IsExpired() bool {
- return false
-}
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
deleted file mode 100644
index 6846ef6f8085..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go
+++ /dev/null
@@ -1,363 +0,0 @@
-/*
-Package stscreds are credential Providers to retrieve STS AWS credentials.
-
-STS provides multiple ways to retrieve credentials which can be used when making
-future AWS service API operation calls.
-
-The SDK will ensure that per instance of credentials.Credentials all requests
-to refresh the credentials will be synchronized. But, the SDK is unable to
-ensure synchronous usage of the AssumeRoleProvider if the value is shared
-between multiple Credentials, Sessions or service clients.
-
-Assume Role
-
-To assume an IAM role using STS with the SDK you can create a new Credentials
-with the SDKs's stscreds package.
-
- // Initial credentials loaded from SDK's default credential chain. Such as
- // the environment, shared credentials (~/.aws/credentials), or EC2 Instance
- // Role. These credentials will be used to to make the STS Assume Role API.
- sess := session.Must(session.NewSession())
-
- // Create the credentials from AssumeRoleProvider to assume the role
- // referenced by the "myRoleARN" ARN.
- creds := stscreds.NewCredentials(sess, "myRoleArn")
-
- // Create service client value configured for credentials
- // from assumed role.
- svc := s3.New(sess, &aws.Config{Credentials: creds})
-
-Assume Role with static MFA Token
-
-To assume an IAM role with a MFA token you can either specify a MFA token code
-directly or provide a function to prompt the user each time the credentials
-need to refresh the role's credentials. Specifying the TokenCode should be used
-for short lived operations that will not need to be refreshed, and when you do
-not want to have direct control over the user provides their MFA token.
-
-With TokenCode the AssumeRoleProvider will be not be able to refresh the role's
-credentials.
-
- // Create the credentials from AssumeRoleProvider to assume the role
- // referenced by the "myRoleARN" ARN using the MFA token code provided.
- creds := stscreds.NewCredentials(sess, "myRoleArn", func(p *stscreds.AssumeRoleProvider) {
- p.SerialNumber = aws.String("myTokenSerialNumber")
- p.TokenCode = aws.String("00000000")
- })
-
- // Create service client value configured for credentials
- // from assumed role.
- svc := s3.New(sess, &aws.Config{Credentials: creds})
-
-Assume Role with MFA Token Provider
-
-To assume an IAM role with MFA for longer running tasks where the credentials
-may need to be refreshed setting the TokenProvider field of AssumeRoleProvider
-will allow the credential provider to prompt for new MFA token code when the
-role's credentials need to be refreshed.
-
-The StdinTokenProvider function is available to prompt on stdin to retrieve
-the MFA token code from the user. You can also implement custom prompts by
-satisfing the TokenProvider function signature.
-
-Using StdinTokenProvider with multiple AssumeRoleProviders, or Credentials will
-have undesirable results as the StdinTokenProvider will not be synchronized. A
-single Credentials with an AssumeRoleProvider can be shared safely.
-
- // Create the credentials from AssumeRoleProvider to assume the role
- // referenced by the "myRoleARN" ARN. Prompting for MFA token from stdin.
- creds := stscreds.NewCredentials(sess, "myRoleArn", func(p *stscreds.AssumeRoleProvider) {
- p.SerialNumber = aws.String("myTokenSerialNumber")
- p.TokenProvider = stscreds.StdinTokenProvider
- })
-
- // Create service client value configured for credentials
- // from assumed role.
- svc := s3.New(sess, &aws.Config{Credentials: creds})
-
-*/
-package stscreds
-
-import (
- "fmt"
- "os"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/client"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/internal/sdkrand"
- "github.com/aws/aws-sdk-go/service/sts"
-)
-
-// StdinTokenProvider will prompt on stderr and read from stdin for a string value.
-// An error is returned if reading from stdin fails.
-//
-// Use this function go read MFA tokens from stdin. The function makes no attempt
-// to make atomic prompts from stdin across multiple gorouties.
-//
-// Using StdinTokenProvider with multiple AssumeRoleProviders, or Credentials will
-// have undesirable results as the StdinTokenProvider will not be synchronized. A
-// single Credentials with an AssumeRoleProvider can be shared safely
-//
-// Will wait forever until something is provided on the stdin.
-func StdinTokenProvider() (string, error) {
- var v string
- fmt.Fprintf(os.Stderr, "Assume Role MFA token code: ")
- _, err := fmt.Scanln(&v)
-
- return v, err
-}
-
-// ProviderName provides a name of AssumeRole provider
-const ProviderName = "AssumeRoleProvider"
-
-// AssumeRoler represents the minimal subset of the STS client API used by this provider.
-type AssumeRoler interface {
- AssumeRole(input *sts.AssumeRoleInput) (*sts.AssumeRoleOutput, error)
-}
-
-type assumeRolerWithContext interface {
- AssumeRoleWithContext(aws.Context, *sts.AssumeRoleInput, ...request.Option) (*sts.AssumeRoleOutput, error)
-}
-
-// DefaultDuration is the default amount of time in minutes that the credentials
-// will be valid for.
-var DefaultDuration = time.Duration(15) * time.Minute
-
-// AssumeRoleProvider retrieves temporary credentials from the STS service, and
-// keeps track of their expiration time.
-//
-// This credential provider will be used by the SDKs default credential change
-// when shared configuration is enabled, and the shared config or shared credentials
-// file configure assume role. See Session docs for how to do this.
-//
-// AssumeRoleProvider does not provide any synchronization and it is not safe
-// to share this value across multiple Credentials, Sessions, or service clients
-// without also sharing the same Credentials instance.
-type AssumeRoleProvider struct {
- credentials.Expiry
-
- // STS client to make assume role request with.
- Client AssumeRoler
-
- // Role to be assumed.
- RoleARN string
-
- // Session name, if you wish to reuse the credentials elsewhere.
- RoleSessionName string
-
- // Optional, you can pass tag key-value pairs to your session. These tags are called session tags.
- Tags []*sts.Tag
-
- // A list of keys for session tags that you want to set as transitive.
- // If you set a tag key as transitive, the corresponding key and value passes to subsequent sessions in a role chain.
- TransitiveTagKeys []*string
-
- // Expiry duration of the STS credentials. Defaults to 15 minutes if not set.
- Duration time.Duration
-
- // Optional ExternalID to pass along, defaults to nil if not set.
- ExternalID *string
-
- // The policy plain text must be 2048 bytes or shorter. However, an internal
- // conversion compresses it into a packed binary format with a separate limit.
- // The PackedPolicySize response element indicates by percentage how close to
- // the upper size limit the policy is, with 100% equaling the maximum allowed
- // size.
- Policy *string
-
- // The ARNs of IAM managed policies you want to use as managed session policies.
- // The policies must exist in the same account as the role.
- //
- // This parameter is optional. You can provide up to 10 managed policy ARNs.
- // However, the plain text that you use for both inline and managed session
- // policies can't exceed 2,048 characters.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- //
- // Passing policies to this operation returns new temporary credentials. The
- // resulting session's permissions are the intersection of the role's identity-based
- // policy and the session policies. You can use the role's temporary credentials
- // in subsequent AWS API calls to access resources in the account that owns
- // the role. You cannot use session policies to grant more permissions than
- // those allowed by the identity-based policy of the role that is being assumed.
- // For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- PolicyArns []*sts.PolicyDescriptorType
-
- // The identification number of the MFA device that is associated with the user
- // who is making the AssumeRole call. Specify this value if the trust policy
- // of the role being assumed includes a condition that requires MFA authentication.
- // The value is either the serial number for a hardware device (such as GAHT12345678)
- // or an Amazon Resource Name (ARN) for a virtual device (such as arn:aws:iam::123456789012:mfa/user).
- SerialNumber *string
-
- // The value provided by the MFA device, if the trust policy of the role being
- // assumed requires MFA (that is, if the policy includes a condition that tests
- // for MFA). If the role being assumed requires MFA and if the TokenCode value
- // is missing or expired, the AssumeRole call returns an "access denied" error.
- //
- // If SerialNumber is set and neither TokenCode nor TokenProvider are also
- // set an error will be returned.
- TokenCode *string
-
- // Async method of providing MFA token code for assuming an IAM role with MFA.
- // The value returned by the function will be used as the TokenCode in the Retrieve
- // call. See StdinTokenProvider for a provider that prompts and reads from stdin.
- //
- // This token provider will be called when ever the assumed role's
- // credentials need to be refreshed when SerialNumber is also set and
- // TokenCode is not set.
- //
- // If both TokenCode and TokenProvider is set, TokenProvider will be used and
- // TokenCode is ignored.
- TokenProvider func() (string, error)
-
- // ExpiryWindow will allow the credentials to trigger refreshing prior to
- // the credentials actually expiring. This is beneficial so race conditions
- // with expiring credentials do not cause request to fail unexpectedly
- // due to ExpiredTokenException exceptions.
- //
- // So a ExpiryWindow of 10s would cause calls to IsExpired() to return true
- // 10 seconds before the credentials are actually expired.
- //
- // If ExpiryWindow is 0 or less it will be ignored.
- ExpiryWindow time.Duration
-
- // MaxJitterFrac reduces the effective Duration of each credential requested
- // by a random percentage between 0 and MaxJitterFraction. MaxJitterFrac must
- // have a value between 0 and 1. Any other value may lead to expected behavior.
- // With a MaxJitterFrac value of 0, default) will no jitter will be used.
- //
- // For example, with a Duration of 30m and a MaxJitterFrac of 0.1, the
- // AssumeRole call will be made with an arbitrary Duration between 27m and
- // 30m.
- //
- // MaxJitterFrac should not be negative.
- MaxJitterFrac float64
-}
-
-// NewCredentials returns a pointer to a new Credentials object wrapping the
-// AssumeRoleProvider. The credentials will expire every 15 minutes and the
-// role will be named after a nanosecond timestamp of this operation.
-//
-// Takes a Config provider to create the STS client. The ConfigProvider is
-// satisfied by the session.Session type.
-//
-// It is safe to share the returned Credentials with multiple Sessions and
-// service clients. All access to the credentials and refreshing them
-// will be synchronized.
-func NewCredentials(c client.ConfigProvider, roleARN string, options ...func(*AssumeRoleProvider)) *credentials.Credentials {
- p := &AssumeRoleProvider{
- Client: sts.New(c),
- RoleARN: roleARN,
- Duration: DefaultDuration,
- }
-
- for _, option := range options {
- option(p)
- }
-
- return credentials.NewCredentials(p)
-}
-
-// NewCredentialsWithClient returns a pointer to a new Credentials object wrapping the
-// AssumeRoleProvider. The credentials will expire every 15 minutes and the
-// role will be named after a nanosecond timestamp of this operation.
-//
-// Takes an AssumeRoler which can be satisfied by the STS client.
-//
-// It is safe to share the returned Credentials with multiple Sessions and
-// service clients. All access to the credentials and refreshing them
-// will be synchronized.
-func NewCredentialsWithClient(svc AssumeRoler, roleARN string, options ...func(*AssumeRoleProvider)) *credentials.Credentials {
- p := &AssumeRoleProvider{
- Client: svc,
- RoleARN: roleARN,
- Duration: DefaultDuration,
- }
-
- for _, option := range options {
- option(p)
- }
-
- return credentials.NewCredentials(p)
-}
-
-// Retrieve generates a new set of temporary credentials using STS.
-func (p *AssumeRoleProvider) Retrieve() (credentials.Value, error) {
- return p.RetrieveWithContext(aws.BackgroundContext())
-}
-
-// RetrieveWithContext generates a new set of temporary credentials using STS.
-func (p *AssumeRoleProvider) RetrieveWithContext(ctx credentials.Context) (credentials.Value, error) {
- // Apply defaults where parameters are not set.
- if p.RoleSessionName == "" {
- // Try to work out a role name that will hopefully end up unique.
- p.RoleSessionName = fmt.Sprintf("%d", time.Now().UTC().UnixNano())
- }
- if p.Duration == 0 {
- // Expire as often as AWS permits.
- p.Duration = DefaultDuration
- }
- jitter := time.Duration(sdkrand.SeededRand.Float64() * p.MaxJitterFrac * float64(p.Duration))
- input := &sts.AssumeRoleInput{
- DurationSeconds: aws.Int64(int64((p.Duration - jitter) / time.Second)),
- RoleArn: aws.String(p.RoleARN),
- RoleSessionName: aws.String(p.RoleSessionName),
- ExternalId: p.ExternalID,
- Tags: p.Tags,
- PolicyArns: p.PolicyArns,
- TransitiveTagKeys: p.TransitiveTagKeys,
- }
- if p.Policy != nil {
- input.Policy = p.Policy
- }
- if p.SerialNumber != nil {
- if p.TokenCode != nil {
- input.SerialNumber = p.SerialNumber
- input.TokenCode = p.TokenCode
- } else if p.TokenProvider != nil {
- input.SerialNumber = p.SerialNumber
- code, err := p.TokenProvider()
- if err != nil {
- return credentials.Value{ProviderName: ProviderName}, err
- }
- input.TokenCode = aws.String(code)
- } else {
- return credentials.Value{ProviderName: ProviderName},
- awserr.New("AssumeRoleTokenNotAvailable",
- "assume role with MFA enabled, but neither TokenCode nor TokenProvider are set", nil)
- }
- }
-
- var roleOutput *sts.AssumeRoleOutput
- var err error
-
- if c, ok := p.Client.(assumeRolerWithContext); ok {
- roleOutput, err = c.AssumeRoleWithContext(ctx, input)
- } else {
- roleOutput, err = p.Client.AssumeRole(input)
- }
-
- if err != nil {
- return credentials.Value{ProviderName: ProviderName}, err
- }
-
- // We will proactively generate new credentials before they expire.
- p.SetExpiration(*roleOutput.Credentials.Expiration, p.ExpiryWindow)
-
- return credentials.Value{
- AccessKeyID: *roleOutput.Credentials.AccessKeyId,
- SecretAccessKey: *roleOutput.Credentials.SecretAccessKey,
- SessionToken: *roleOutput.Credentials.SessionToken,
- ProviderName: ProviderName,
- }, nil
-}
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
deleted file mode 100644
index cefe2a76d4de..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go
+++ /dev/null
@@ -1,154 +0,0 @@
-package stscreds
-
-import (
- "fmt"
- "io/ioutil"
- "strconv"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/client"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/service/sts"
- "github.com/aws/aws-sdk-go/service/sts/stsiface"
-)
-
-const (
- // ErrCodeWebIdentity will be used as an error code when constructing
- // a new error to be returned during session creation or retrieval.
- ErrCodeWebIdentity = "WebIdentityErr"
-
- // WebIdentityProviderName is the web identity provider name
- WebIdentityProviderName = "WebIdentityCredentials"
-)
-
-// now is used to return a time.Time object representing
-// the current time. This can be used to easily test and
-// compare test values.
-var now = time.Now
-
-// TokenFetcher shuold return WebIdentity token bytes or an error
-type TokenFetcher interface {
- FetchToken(credentials.Context) ([]byte, error)
-}
-
-// FetchTokenPath is a path to a WebIdentity token file
-type FetchTokenPath string
-
-// FetchToken returns a token by reading from the filesystem
-func (f FetchTokenPath) FetchToken(ctx credentials.Context) ([]byte, error) {
- data, err := ioutil.ReadFile(string(f))
- if err != nil {
- errMsg := fmt.Sprintf("unable to read file at %s", f)
- return nil, awserr.New(ErrCodeWebIdentity, errMsg, err)
- }
- return data, nil
-}
-
-// WebIdentityRoleProvider is used to retrieve credentials using
-// an OIDC token.
-type WebIdentityRoleProvider struct {
- credentials.Expiry
- PolicyArns []*sts.PolicyDescriptorType
-
- // Duration the STS credentials will be valid for. Truncated to seconds.
- // If unset, the assumed role will use AssumeRoleWithWebIdentity's default
- // expiry duration. See
- // https://docs.aws.amazon.com/sdk-for-go/api/service/sts/#STS.AssumeRoleWithWebIdentity
- // for more information.
- Duration time.Duration
-
- // The amount of time the credentials will be refreshed before they expire.
- // This is useful refresh credentials before they expire to reduce risk of
- // using credentials as they expire. If unset, will default to no expiry
- // window.
- ExpiryWindow time.Duration
-
- client stsiface.STSAPI
-
- tokenFetcher TokenFetcher
- roleARN string
- roleSessionName string
-}
-
-// NewWebIdentityCredentials will return a new set of credentials with a given
-// configuration, role arn, and token file path.
-func NewWebIdentityCredentials(c client.ConfigProvider, roleARN, roleSessionName, path string) *credentials.Credentials {
- svc := sts.New(c)
- p := NewWebIdentityRoleProvider(svc, roleARN, roleSessionName, path)
- return credentials.NewCredentials(p)
-}
-
-// NewWebIdentityRoleProvider will return a new WebIdentityRoleProvider with the
-// provided stsiface.STSAPI
-func NewWebIdentityRoleProvider(svc stsiface.STSAPI, roleARN, roleSessionName, path string) *WebIdentityRoleProvider {
- return NewWebIdentityRoleProviderWithToken(svc, roleARN, roleSessionName, FetchTokenPath(path))
-}
-
-// NewWebIdentityRoleProviderWithToken will return a new WebIdentityRoleProvider with the
-// provided stsiface.STSAPI and a TokenFetcher
-func NewWebIdentityRoleProviderWithToken(svc stsiface.STSAPI, roleARN, roleSessionName string, tokenFetcher TokenFetcher) *WebIdentityRoleProvider {
- return &WebIdentityRoleProvider{
- client: svc,
- tokenFetcher: tokenFetcher,
- roleARN: roleARN,
- roleSessionName: roleSessionName,
- }
-}
-
-// Retrieve will attempt to assume a role from a token which is located at
-// 'WebIdentityTokenFilePath' specified destination and if that is empty an
-// error will be returned.
-func (p *WebIdentityRoleProvider) Retrieve() (credentials.Value, error) {
- return p.RetrieveWithContext(aws.BackgroundContext())
-}
-
-// RetrieveWithContext will attempt to assume a role from a token which is located at
-// 'WebIdentityTokenFilePath' specified destination and if that is empty an
-// error will be returned.
-func (p *WebIdentityRoleProvider) RetrieveWithContext(ctx credentials.Context) (credentials.Value, error) {
- b, err := p.tokenFetcher.FetchToken(ctx)
- if err != nil {
- return credentials.Value{}, awserr.New(ErrCodeWebIdentity, "failed fetching WebIdentity token: ", err)
- }
-
- sessionName := p.roleSessionName
- if len(sessionName) == 0 {
- // session name is used to uniquely identify a session. This simply
- // uses unix time in nanoseconds to uniquely identify sessions.
- sessionName = strconv.FormatInt(now().UnixNano(), 10)
- }
-
- var duration *int64
- if p.Duration != 0 {
- duration = aws.Int64(int64(p.Duration / time.Second))
- }
-
- req, resp := p.client.AssumeRoleWithWebIdentityRequest(&sts.AssumeRoleWithWebIdentityInput{
- PolicyArns: p.PolicyArns,
- RoleArn: &p.roleARN,
- RoleSessionName: &sessionName,
- WebIdentityToken: aws.String(string(b)),
- DurationSeconds: duration,
- })
-
- req.SetContext(ctx)
-
- // InvalidIdentityToken error is a temporary error that can occur
- // when assuming an Role with a JWT web identity token.
- req.RetryErrorCodes = append(req.RetryErrorCodes, sts.ErrCodeInvalidIdentityTokenException)
- if err := req.Send(); err != nil {
- return credentials.Value{}, awserr.New(ErrCodeWebIdentity, "failed to retrieve credentials", err)
- }
-
- p.SetExpiration(aws.TimeValue(resp.Credentials.Expiration), p.ExpiryWindow)
-
- value := credentials.Value{
- AccessKeyID: aws.StringValue(resp.Credentials.AccessKeyId),
- SecretAccessKey: aws.StringValue(resp.Credentials.SecretAccessKey),
- SessionToken: aws.StringValue(resp.Credentials.SessionToken),
- ProviderName: WebIdentityProviderName,
- }
- return value, nil
-}
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
deleted file mode 100644
index 25a66d1dda22..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go
+++ /dev/null
@@ -1,69 +0,0 @@
-// Package csm provides the Client Side Monitoring (CSM) client which enables
-// sending metrics via UDP connection to the CSM agent. This package provides
-// control options, and configuration for the CSM client. The client can be
-// controlled manually, or automatically via the SDK's Session configuration.
-//
-// Enabling CSM client via SDK's Session configuration
-//
-// The CSM client can be enabled automatically via SDK's Session configuration.
-// The SDK's session configuration enables the CSM client if the AWS_CSM_PORT
-// environment variable is set to a non-empty value.
-//
-// The configuration options for the CSM client via the SDK's session
-// configuration are:
-//
-// * AWS_CSM_PORT=
-// The port number the CSM agent will receive metrics on.
-//
-// * AWS_CSM_HOST=
-// The hostname, or IP address the CSM agent will receive metrics on.
-// Without port number.
-//
-// Manually enabling the CSM client
-//
-// The CSM client can be started, paused, and resumed manually. The Start
-// function will enable the CSM client to publish metrics to the CSM agent. It
-// is safe to call Start concurrently, but if Start is called additional times
-// with different ClientID or address it will panic.
-//
-// r, err := csm.Start("clientID", ":31000")
-// if err != nil {
-// panic(fmt.Errorf("failed starting CSM: %v", err))
-// }
-//
-// When controlling the CSM client manually, you must also inject its request
-// handlers into the SDK's Session configuration for the SDK's API clients to
-// publish metrics.
-//
-// sess, err := session.NewSession(&aws.Config{})
-// if err != nil {
-// panic(fmt.Errorf("failed loading session: %v", err))
-// }
-//
-// // Add CSM client's metric publishing request handlers to the SDK's
-// // Session Configuration.
-// r.InjectHandlers(&sess.Handlers)
-//
-// Controlling CSM client
-//
-// Once the CSM client has been enabled the Get function will return a Reporter
-// value that you can use to pause and resume the metrics published to the CSM
-// agent. If Get function is called before the reporter is enabled with the
-// Start function or via SDK's Session configuration nil will be returned.
-//
-// The Pause method can be called to stop the CSM client publishing metrics to
-// the CSM agent. The Continue method will resume metric publishing.
-//
-// // Get the CSM client Reporter.
-// r := csm.Get()
-//
-// // Will pause monitoring
-// r.Pause()
-// resp, err = client.GetObject(&s3.GetObjectInput{
-// Bucket: aws.String("bucket"),
-// Key: aws.String("key"),
-// })
-//
-// // Resume monitoring
-// r.Continue()
-package 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
deleted file mode 100644
index 4b19e2800e3c..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go
+++ /dev/null
@@ -1,89 +0,0 @@
-package csm
-
-import (
- "fmt"
- "strings"
- "sync"
-)
-
-var (
- lock sync.Mutex
-)
-
-const (
- // DefaultPort is used when no port is specified.
- DefaultPort = "31000"
-
- // DefaultHost is the host that will be used when none is specified.
- DefaultHost = "127.0.0.1"
-)
-
-// AddressWithDefaults returns a CSM address built from the host and port
-// values. If the host or port is not set, default values will be used
-// instead. If host is "localhost" it will be replaced with "127.0.0.1".
-func AddressWithDefaults(host, port string) string {
- if len(host) == 0 || strings.EqualFold(host, "localhost") {
- host = DefaultHost
- }
-
- if len(port) == 0 {
- port = DefaultPort
- }
-
- // Only IP6 host can contain a colon
- if strings.Contains(host, ":") {
- return "[" + host + "]:" + port
- }
-
- return host + ":" + port
-}
-
-// Start will start a long running go routine to capture
-// client side metrics. Calling start multiple time will only
-// start the metric listener once and will panic if a different
-// client ID or port is passed in.
-//
-// r, err := csm.Start("clientID", "127.0.0.1:31000")
-// if err != nil {
-// panic(fmt.Errorf("expected no error, but received %v", err))
-// }
-// sess := session.NewSession()
-// r.InjectHandlers(sess.Handlers)
-//
-// svc := s3.New(sess)
-// out, err := svc.GetObject(&s3.GetObjectInput{
-// Bucket: aws.String("bucket"),
-// Key: aws.String("key"),
-// })
-func Start(clientID string, url string) (*Reporter, error) {
- lock.Lock()
- defer lock.Unlock()
-
- if sender == nil {
- sender = newReporter(clientID, url)
- } else {
- if sender.clientID != clientID {
- panic(fmt.Errorf("inconsistent client IDs. %q was expected, but received %q", sender.clientID, clientID))
- }
-
- if sender.url != url {
- panic(fmt.Errorf("inconsistent URLs. %q was expected, but received %q", sender.url, url))
- }
- }
-
- if err := connect(url); err != nil {
- sender = nil
- return nil, err
- }
-
- return sender, nil
-}
-
-// Get will return a reporter if one exists, if one does not exist, nil will
-// be returned.
-func Get() *Reporter {
- lock.Lock()
- defer lock.Unlock()
-
- return sender
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go
deleted file mode 100644
index 5bacc791a1e9..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go
+++ /dev/null
@@ -1,109 +0,0 @@
-package csm
-
-import (
- "strconv"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
-)
-
-type metricTime time.Time
-
-func (t metricTime) MarshalJSON() ([]byte, error) {
- ns := time.Duration(time.Time(t).UnixNano())
- return []byte(strconv.FormatInt(int64(ns/time.Millisecond), 10)), nil
-}
-
-type metric struct {
- ClientID *string `json:"ClientId,omitempty"`
- API *string `json:"Api,omitempty"`
- Service *string `json:"Service,omitempty"`
- Timestamp *metricTime `json:"Timestamp,omitempty"`
- Type *string `json:"Type,omitempty"`
- Version *int `json:"Version,omitempty"`
-
- AttemptCount *int `json:"AttemptCount,omitempty"`
- Latency *int `json:"Latency,omitempty"`
-
- Fqdn *string `json:"Fqdn,omitempty"`
- UserAgent *string `json:"UserAgent,omitempty"`
- AttemptLatency *int `json:"AttemptLatency,omitempty"`
-
- SessionToken *string `json:"SessionToken,omitempty"`
- Region *string `json:"Region,omitempty"`
- AccessKey *string `json:"AccessKey,omitempty"`
- HTTPStatusCode *int `json:"HttpStatusCode,omitempty"`
- XAmzID2 *string `json:"XAmzId2,omitempty"`
- XAmzRequestID *string `json:"XAmznRequestId,omitempty"`
-
- AWSException *string `json:"AwsException,omitempty"`
- AWSExceptionMessage *string `json:"AwsExceptionMessage,omitempty"`
- SDKException *string `json:"SdkException,omitempty"`
- SDKExceptionMessage *string `json:"SdkExceptionMessage,omitempty"`
-
- FinalHTTPStatusCode *int `json:"FinalHttpStatusCode,omitempty"`
- FinalAWSException *string `json:"FinalAwsException,omitempty"`
- FinalAWSExceptionMessage *string `json:"FinalAwsExceptionMessage,omitempty"`
- FinalSDKException *string `json:"FinalSdkException,omitempty"`
- FinalSDKExceptionMessage *string `json:"FinalSdkExceptionMessage,omitempty"`
-
- DestinationIP *string `json:"DestinationIp,omitempty"`
- ConnectionReused *int `json:"ConnectionReused,omitempty"`
-
- AcquireConnectionLatency *int `json:"AcquireConnectionLatency,omitempty"`
- ConnectLatency *int `json:"ConnectLatency,omitempty"`
- RequestLatency *int `json:"RequestLatency,omitempty"`
- DNSLatency *int `json:"DnsLatency,omitempty"`
- TCPLatency *int `json:"TcpLatency,omitempty"`
- SSLLatency *int `json:"SslLatency,omitempty"`
-
- MaxRetriesExceeded *int `json:"MaxRetriesExceeded,omitempty"`
-}
-
-func (m *metric) TruncateFields() {
- m.ClientID = truncateString(m.ClientID, 255)
- m.UserAgent = truncateString(m.UserAgent, 256)
-
- m.AWSException = truncateString(m.AWSException, 128)
- m.AWSExceptionMessage = truncateString(m.AWSExceptionMessage, 512)
-
- m.SDKException = truncateString(m.SDKException, 128)
- m.SDKExceptionMessage = truncateString(m.SDKExceptionMessage, 512)
-
- m.FinalAWSException = truncateString(m.FinalAWSException, 128)
- m.FinalAWSExceptionMessage = truncateString(m.FinalAWSExceptionMessage, 512)
-
- m.FinalSDKException = truncateString(m.FinalSDKException, 128)
- m.FinalSDKExceptionMessage = truncateString(m.FinalSDKExceptionMessage, 512)
-}
-
-func truncateString(v *string, l int) *string {
- if v != nil && len(*v) > l {
- nv := (*v)[:l]
- return &nv
- }
-
- return v
-}
-
-func (m *metric) SetException(e metricException) {
- switch te := e.(type) {
- case awsException:
- m.AWSException = aws.String(te.exception)
- m.AWSExceptionMessage = aws.String(te.message)
- case sdkException:
- m.SDKException = aws.String(te.exception)
- m.SDKExceptionMessage = aws.String(te.message)
- }
-}
-
-func (m *metric) SetFinalException(e metricException) {
- switch te := e.(type) {
- case awsException:
- m.FinalAWSException = aws.String(te.exception)
- m.FinalAWSExceptionMessage = aws.String(te.message)
- case sdkException:
- m.FinalSDKException = aws.String(te.exception)
- m.FinalSDKExceptionMessage = aws.String(te.message)
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_chan.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_chan.go
deleted file mode 100644
index 82a3e345e936..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_chan.go
+++ /dev/null
@@ -1,55 +0,0 @@
-package csm
-
-import (
- "sync/atomic"
-)
-
-const (
- runningEnum = iota
- pausedEnum
-)
-
-var (
- // MetricsChannelSize of metrics to hold in the channel
- MetricsChannelSize = 100
-)
-
-type metricChan struct {
- ch chan metric
- paused *int64
-}
-
-func newMetricChan(size int) metricChan {
- return metricChan{
- ch: make(chan metric, size),
- paused: new(int64),
- }
-}
-
-func (ch *metricChan) Pause() {
- atomic.StoreInt64(ch.paused, pausedEnum)
-}
-
-func (ch *metricChan) Continue() {
- atomic.StoreInt64(ch.paused, runningEnum)
-}
-
-func (ch *metricChan) IsPaused() bool {
- v := atomic.LoadInt64(ch.paused)
- return v == pausedEnum
-}
-
-// Push will push metrics to the metric channel if the channel
-// is not paused
-func (ch *metricChan) Push(m metric) bool {
- if ch.IsPaused() {
- return false
- }
-
- select {
- case ch.ch <- m:
- return true
- default:
- return false
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go
deleted file mode 100644
index 54a99280ce9c..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go
+++ /dev/null
@@ -1,26 +0,0 @@
-package csm
-
-type metricException interface {
- Exception() string
- Message() string
-}
-
-type requestException struct {
- exception string
- message string
-}
-
-func (e requestException) Exception() string {
- return e.exception
-}
-func (e requestException) Message() string {
- return e.message
-}
-
-type awsException struct {
- requestException
-}
-
-type sdkException struct {
- requestException
-}
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
deleted file mode 100644
index 835bcd49cbaf..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go
+++ /dev/null
@@ -1,264 +0,0 @@
-package csm
-
-import (
- "encoding/json"
- "net"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// Reporter will gather metrics of API requests made and
-// send those metrics to the CSM endpoint.
-type Reporter struct {
- clientID string
- url string
- conn net.Conn
- metricsCh metricChan
- done chan struct{}
-}
-
-var (
- sender *Reporter
-)
-
-func connect(url string) error {
- const network = "udp"
- if err := sender.connect(network, url); err != nil {
- return err
- }
-
- if sender.done == nil {
- sender.done = make(chan struct{})
- go sender.start()
- }
-
- return nil
-}
-
-func newReporter(clientID, url string) *Reporter {
- return &Reporter{
- clientID: clientID,
- url: url,
- metricsCh: newMetricChan(MetricsChannelSize),
- }
-}
-
-func (rep *Reporter) sendAPICallAttemptMetric(r *request.Request) {
- if rep == nil {
- return
- }
-
- now := time.Now()
- creds, _ := r.Config.Credentials.Get()
-
- m := metric{
- ClientID: aws.String(rep.clientID),
- API: aws.String(r.Operation.Name),
- Service: aws.String(r.ClientInfo.ServiceID),
- Timestamp: (*metricTime)(&now),
- UserAgent: aws.String(r.HTTPRequest.Header.Get("User-Agent")),
- Region: r.Config.Region,
- Type: aws.String("ApiCallAttempt"),
- Version: aws.Int(1),
-
- XAmzRequestID: aws.String(r.RequestID),
-
- AttemptLatency: aws.Int(int(now.Sub(r.AttemptTime).Nanoseconds() / int64(time.Millisecond))),
- AccessKey: aws.String(creds.AccessKeyID),
- }
-
- if r.HTTPResponse != nil {
- m.HTTPStatusCode = aws.Int(r.HTTPResponse.StatusCode)
- }
-
- if r.Error != nil {
- if awserr, ok := r.Error.(awserr.Error); ok {
- m.SetException(getMetricException(awserr))
- }
- }
-
- m.TruncateFields()
- rep.metricsCh.Push(m)
-}
-
-func getMetricException(err awserr.Error) metricException {
- msg := err.Error()
- code := err.Code()
-
- switch code {
- case request.ErrCodeRequestError,
- request.ErrCodeSerialization,
- request.CanceledErrorCode:
- return sdkException{
- requestException{exception: code, message: msg},
- }
- default:
- return awsException{
- requestException{exception: code, message: msg},
- }
- }
-}
-
-func (rep *Reporter) sendAPICallMetric(r *request.Request) {
- if rep == nil {
- return
- }
-
- now := time.Now()
- m := metric{
- ClientID: aws.String(rep.clientID),
- API: aws.String(r.Operation.Name),
- Service: aws.String(r.ClientInfo.ServiceID),
- Timestamp: (*metricTime)(&now),
- UserAgent: aws.String(r.HTTPRequest.Header.Get("User-Agent")),
- Type: aws.String("ApiCall"),
- AttemptCount: aws.Int(r.RetryCount + 1),
- Region: r.Config.Region,
- Latency: aws.Int(int(time.Since(r.Time) / time.Millisecond)),
- XAmzRequestID: aws.String(r.RequestID),
- MaxRetriesExceeded: aws.Int(boolIntValue(r.RetryCount >= r.MaxRetries())),
- }
-
- if r.HTTPResponse != nil {
- m.FinalHTTPStatusCode = aws.Int(r.HTTPResponse.StatusCode)
- }
-
- if r.Error != nil {
- if awserr, ok := r.Error.(awserr.Error); ok {
- m.SetFinalException(getMetricException(awserr))
- }
- }
-
- m.TruncateFields()
-
- // TODO: Probably want to figure something out for logging dropped
- // metrics
- rep.metricsCh.Push(m)
-}
-
-func (rep *Reporter) connect(network, url string) error {
- if rep.conn != nil {
- rep.conn.Close()
- }
-
- conn, err := net.Dial(network, url)
- if err != nil {
- return awserr.New("UDPError", "Could not connect", err)
- }
-
- rep.conn = conn
-
- return nil
-}
-
-func (rep *Reporter) close() {
- if rep.done != nil {
- close(rep.done)
- }
-
- rep.metricsCh.Pause()
-}
-
-func (rep *Reporter) start() {
- defer func() {
- rep.metricsCh.Pause()
- }()
-
- for {
- select {
- case <-rep.done:
- rep.done = nil
- return
- case m := <-rep.metricsCh.ch:
- // TODO: What to do with this error? Probably should just log
- b, err := json.Marshal(m)
- if err != nil {
- continue
- }
-
- rep.conn.Write(b)
- }
- }
-}
-
-// Pause will pause the metric channel preventing any new metrics from being
-// added. It is safe to call concurrently with other calls to Pause, but if
-// called concurently with Continue can lead to unexpected state.
-func (rep *Reporter) Pause() {
- lock.Lock()
- defer lock.Unlock()
-
- if rep == nil {
- return
- }
-
- rep.close()
-}
-
-// Continue will reopen the metric channel and allow for monitoring to be
-// resumed. It is safe to call concurrently with other calls to Continue, but
-// if called concurently with Pause can lead to unexpected state.
-func (rep *Reporter) Continue() {
- lock.Lock()
- defer lock.Unlock()
- if rep == nil {
- return
- }
-
- if !rep.metricsCh.IsPaused() {
- return
- }
-
- rep.metricsCh.Continue()
-}
-
-// Client side metric handler names
-const (
- APICallMetricHandlerName = "awscsm.SendAPICallMetric"
- APICallAttemptMetricHandlerName = "awscsm.SendAPICallAttemptMetric"
-)
-
-// InjectHandlers will will enable client side metrics and inject the proper
-// handlers to handle how metrics are sent.
-//
-// InjectHandlers is NOT safe to call concurrently. Calling InjectHandlers
-// multiple times may lead to unexpected behavior, (e.g. duplicate metrics).
-//
-// // Start must be called in order to inject the correct handlers
-// r, err := csm.Start("clientID", "127.0.0.1:8094")
-// if err != nil {
-// panic(fmt.Errorf("expected no error, but received %v", err))
-// }
-//
-// sess := session.NewSession()
-// r.InjectHandlers(&sess.Handlers)
-//
-// // create a new service client with our client side metric session
-// svc := s3.New(sess)
-func (rep *Reporter) InjectHandlers(handlers *request.Handlers) {
- if rep == nil {
- return
- }
-
- handlers.Complete.PushFrontNamed(request.NamedHandler{
- Name: APICallMetricHandlerName,
- Fn: rep.sendAPICallMetric,
- })
-
- handlers.CompleteAttempt.PushFrontNamed(request.NamedHandler{
- Name: APICallAttemptMetricHandlerName,
- Fn: rep.sendAPICallAttemptMetric,
- })
-}
-
-// boolIntValue return 1 for true and 0 for false.
-func boolIntValue(b bool) int {
- if b {
- return 1
- }
-
- return 0
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go b/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go
deleted file mode 100644
index 23bb639e0186..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go
+++ /dev/null
@@ -1,207 +0,0 @@
-// Package defaults is a collection of helpers to retrieve the SDK's default
-// configuration and handlers.
-//
-// Generally this package shouldn't be used directly, but session.Session
-// instead. This package is useful when you need to reset the defaults
-// of a session or service client to the SDK defaults before setting
-// additional parameters.
-package defaults
-
-import (
- "fmt"
- "net"
- "net/http"
- "net/url"
- "os"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/corehandlers"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds"
- "github.com/aws/aws-sdk-go/aws/credentials/endpointcreds"
- "github.com/aws/aws-sdk-go/aws/ec2metadata"
- "github.com/aws/aws-sdk-go/aws/endpoints"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/internal/shareddefaults"
-)
-
-// A Defaults provides a collection of default values for SDK clients.
-type Defaults struct {
- Config *aws.Config
- Handlers request.Handlers
-}
-
-// Get returns the SDK's default values with Config and handlers pre-configured.
-func Get() Defaults {
- cfg := Config()
- handlers := Handlers()
- cfg.Credentials = CredChain(cfg, handlers)
-
- return Defaults{
- Config: cfg,
- Handlers: handlers,
- }
-}
-
-// Config returns the default configuration without credentials.
-// To retrieve a config with credentials also included use
-// `defaults.Get().Config` instead.
-//
-// Generally you shouldn't need to use this method directly, but
-// is available if you need to reset the configuration of an
-// existing service client or session.
-func Config() *aws.Config {
- return aws.NewConfig().
- WithCredentials(credentials.AnonymousCredentials).
- WithRegion(os.Getenv("AWS_REGION")).
- WithHTTPClient(http.DefaultClient).
- WithMaxRetries(aws.UseServiceDefaultRetries).
- WithLogger(aws.NewDefaultLogger()).
- WithLogLevel(aws.LogOff).
- WithEndpointResolver(endpoints.DefaultResolver())
-}
-
-// Handlers returns the default request handlers.
-//
-// Generally you shouldn't need to use this method directly, but
-// is available if you need to reset the request handlers of an
-// existing service client or session.
-func Handlers() request.Handlers {
- var handlers request.Handlers
-
- handlers.Validate.PushBackNamed(corehandlers.ValidateEndpointHandler)
- handlers.Validate.AfterEachFn = request.HandlerListStopOnError
- handlers.Build.PushBackNamed(corehandlers.SDKVersionUserAgentHandler)
- handlers.Build.PushBackNamed(corehandlers.AddHostExecEnvUserAgentHander)
- handlers.Build.AfterEachFn = request.HandlerListStopOnError
- handlers.Sign.PushBackNamed(corehandlers.BuildContentLengthHandler)
- handlers.Send.PushBackNamed(corehandlers.ValidateReqSigHandler)
- handlers.Send.PushBackNamed(corehandlers.SendHandler)
- handlers.AfterRetry.PushBackNamed(corehandlers.AfterRetryHandler)
- handlers.ValidateResponse.PushBackNamed(corehandlers.ValidateResponseHandler)
-
- return handlers
-}
-
-// CredChain returns the default credential chain.
-//
-// Generally you shouldn't need to use this method directly, but
-// is available if you need to reset the credentials of an
-// existing service client or session's Config.
-func CredChain(cfg *aws.Config, handlers request.Handlers) *credentials.Credentials {
- return credentials.NewCredentials(&credentials.ChainProvider{
- VerboseErrors: aws.BoolValue(cfg.CredentialsChainVerboseErrors),
- Providers: CredProviders(cfg, handlers),
- })
-}
-
-// CredProviders returns the slice of providers used in
-// the default credential chain.
-//
-// For applications that need to use some other provider (for example use
-// different environment variables for legacy reasons) but still fall back
-// on the default chain of providers. This allows that default chaint to be
-// automatically updated
-func CredProviders(cfg *aws.Config, handlers request.Handlers) []credentials.Provider {
- return []credentials.Provider{
- &credentials.EnvProvider{},
- &credentials.SharedCredentialsProvider{Filename: "", Profile: ""},
- RemoteCredProvider(*cfg, handlers),
- }
-}
-
-const (
- httpProviderAuthorizationEnvVar = "AWS_CONTAINER_AUTHORIZATION_TOKEN"
- httpProviderEnvVar = "AWS_CONTAINER_CREDENTIALS_FULL_URI"
-)
-
-// RemoteCredProvider returns a credentials provider for the default remote
-// endpoints such as EC2 or ECS Roles.
-func RemoteCredProvider(cfg aws.Config, handlers request.Handlers) credentials.Provider {
- if u := os.Getenv(httpProviderEnvVar); len(u) > 0 {
- return localHTTPCredProvider(cfg, handlers, u)
- }
-
- if uri := os.Getenv(shareddefaults.ECSCredsProviderEnvVar); len(uri) > 0 {
- u := fmt.Sprintf("%s%s", shareddefaults.ECSContainerCredentialsURI, uri)
- return httpCredProvider(cfg, handlers, u)
- }
-
- return ec2RoleProvider(cfg, handlers)
-}
-
-var lookupHostFn = net.LookupHost
-
-func isLoopbackHost(host string) (bool, error) {
- ip := net.ParseIP(host)
- if ip != nil {
- return ip.IsLoopback(), nil
- }
-
- // Host is not an ip, perform lookup
- addrs, err := lookupHostFn(host)
- if err != nil {
- return false, err
- }
- for _, addr := range addrs {
- if !net.ParseIP(addr).IsLoopback() {
- return false, nil
- }
- }
-
- return true, nil
-}
-
-func localHTTPCredProvider(cfg aws.Config, handlers request.Handlers, u string) credentials.Provider {
- var errMsg string
-
- parsed, err := url.Parse(u)
- if err != nil {
- errMsg = fmt.Sprintf("invalid URL, %v", err)
- } else {
- host := aws.URLHostname(parsed)
- if len(host) == 0 {
- errMsg = "unable to parse host from local HTTP cred provider URL"
- } else if isLoopback, loopbackErr := isLoopbackHost(host); loopbackErr != nil {
- errMsg = fmt.Sprintf("failed to resolve host %q, %v", host, loopbackErr)
- } else if !isLoopback {
- errMsg = fmt.Sprintf("invalid endpoint host, %q, only loopback hosts are allowed.", host)
- }
- }
-
- if len(errMsg) > 0 {
- if cfg.Logger != nil {
- cfg.Logger.Log("Ignoring, HTTP credential provider", errMsg, err)
- }
- return credentials.ErrorProvider{
- Err: awserr.New("CredentialsEndpointError", errMsg, err),
- ProviderName: endpointcreds.ProviderName,
- }
- }
-
- return httpCredProvider(cfg, handlers, u)
-}
-
-func httpCredProvider(cfg aws.Config, handlers request.Handlers, u string) credentials.Provider {
- return endpointcreds.NewProviderClient(cfg, handlers, u,
- func(p *endpointcreds.Provider) {
- p.ExpiryWindow = 5 * time.Minute
- p.AuthorizationToken = os.Getenv(httpProviderAuthorizationEnvVar)
- },
- )
-}
-
-func ec2RoleProvider(cfg aws.Config, handlers request.Handlers) credentials.Provider {
- resolver := cfg.EndpointResolver
- if resolver == nil {
- resolver = endpoints.DefaultResolver()
- }
-
- e, _ := resolver.EndpointFor(endpoints.Ec2metadataServiceID, "")
- return &ec2rolecreds.EC2RoleProvider{
- Client: ec2metadata.NewClient(cfg, handlers, e.URL, e.SigningRegion),
- ExpiryWindow: 5 * time.Minute,
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/defaults/shared_config.go b/vendor/github.com/aws/aws-sdk-go/aws/defaults/shared_config.go
deleted file mode 100644
index ca0ee1dcc78e..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/defaults/shared_config.go
+++ /dev/null
@@ -1,27 +0,0 @@
-package defaults
-
-import (
- "github.com/aws/aws-sdk-go/internal/shareddefaults"
-)
-
-// SharedCredentialsFilename returns the SDK's default file path
-// for the shared credentials file.
-//
-// Builds the shared config file path based on the OS's platform.
-//
-// - Linux/Unix: $HOME/.aws/credentials
-// - Windows: %USERPROFILE%\.aws\credentials
-func SharedCredentialsFilename() string {
- return shareddefaults.SharedCredentialsFilename()
-}
-
-// SharedConfigFilename returns the SDK's default file path for
-// the shared config file.
-//
-// Builds the shared config file path based on the OS's platform.
-//
-// - Linux/Unix: $HOME/.aws/config
-// - Windows: %USERPROFILE%\.aws\config
-func SharedConfigFilename() string {
- return shareddefaults.SharedConfigFilename()
-}
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
deleted file mode 100644
index 69fa63dc08f3..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go
+++ /dev/null
@@ -1,250 +0,0 @@
-package ec2metadata
-
-import (
- "encoding/json"
- "fmt"
- "net/http"
- "strconv"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/internal/sdkuri"
-)
-
-// getToken uses the duration to return a token for EC2 metadata service,
-// or an error if the request failed.
-func (c *EC2Metadata) getToken(ctx aws.Context, duration time.Duration) (tokenOutput, error) {
- op := &request.Operation{
- Name: "GetToken",
- HTTPMethod: "PUT",
- HTTPPath: "/latest/api/token",
- }
-
- var output tokenOutput
- req := c.NewRequest(op, nil, &output)
- req.SetContext(ctx)
-
- // remove the fetch token handler from the request handlers to avoid infinite recursion
- req.Handlers.Sign.RemoveByName(fetchTokenHandlerName)
-
- // Swap the unmarshalMetadataHandler with unmarshalTokenHandler on this request.
- req.Handlers.Unmarshal.Swap(unmarshalMetadataHandlerName, unmarshalTokenHandler)
-
- ttl := strconv.FormatInt(int64(duration/time.Second), 10)
- req.HTTPRequest.Header.Set(ttlHeader, ttl)
-
- err := req.Send()
-
- // Errors with bad request status should be returned.
- if err != nil {
- err = awserr.NewRequestFailure(
- awserr.New(req.HTTPResponse.Status, http.StatusText(req.HTTPResponse.StatusCode), err),
- req.HTTPResponse.StatusCode, req.RequestID)
- }
-
- return output, err
-}
-
-// GetMetadata uses the path provided to request information from the EC2
-// instance metadata service. The content will be returned as a string, or
-// error if the request failed.
-func (c *EC2Metadata) GetMetadata(p string) (string, error) {
- return c.GetMetadataWithContext(aws.BackgroundContext(), p)
-}
-
-// GetMetadataWithContext uses the path provided to request information from the EC2
-// instance metadata service. The content will be returned as a string, or
-// error if the request failed.
-func (c *EC2Metadata) GetMetadataWithContext(ctx aws.Context, p string) (string, error) {
- op := &request.Operation{
- Name: "GetMetadata",
- HTTPMethod: "GET",
- HTTPPath: sdkuri.PathJoin("/latest/meta-data", p),
- }
- output := &metadataOutput{}
-
- req := c.NewRequest(op, nil, output)
-
- req.SetContext(ctx)
-
- err := req.Send()
- return output.Content, err
-}
-
-// GetUserData returns the userdata that was configured for the service. If
-// there is no user-data setup for the EC2 instance a "NotFoundError" error
-// code will be returned.
-func (c *EC2Metadata) GetUserData() (string, error) {
- return c.GetUserDataWithContext(aws.BackgroundContext())
-}
-
-// GetUserDataWithContext returns the userdata that was configured for the service. If
-// there is no user-data setup for the EC2 instance a "NotFoundError" error
-// code will be returned.
-func (c *EC2Metadata) GetUserDataWithContext(ctx aws.Context) (string, error) {
- op := &request.Operation{
- Name: "GetUserData",
- HTTPMethod: "GET",
- HTTPPath: "/latest/user-data",
- }
-
- output := &metadataOutput{}
- req := c.NewRequest(op, nil, output)
- req.SetContext(ctx)
-
- err := req.Send()
- return output.Content, err
-}
-
-// GetDynamicData uses the path provided to request information from the EC2
-// instance metadata service for dynamic data. The content will be returned
-// as a string, or error if the request failed.
-func (c *EC2Metadata) GetDynamicData(p string) (string, error) {
- return c.GetDynamicDataWithContext(aws.BackgroundContext(), p)
-}
-
-// GetDynamicDataWithContext uses the path provided to request information from the EC2
-// instance metadata service for dynamic data. The content will be returned
-// as a string, or error if the request failed.
-func (c *EC2Metadata) GetDynamicDataWithContext(ctx aws.Context, p string) (string, error) {
- op := &request.Operation{
- Name: "GetDynamicData",
- HTTPMethod: "GET",
- HTTPPath: sdkuri.PathJoin("/latest/dynamic", p),
- }
-
- output := &metadataOutput{}
- req := c.NewRequest(op, nil, output)
- req.SetContext(ctx)
-
- err := req.Send()
- return output.Content, err
-}
-
-// GetInstanceIdentityDocument retrieves an identity document describing an
-// instance. Error is returned if the request fails or is unable to parse
-// the response.
-func (c *EC2Metadata) GetInstanceIdentityDocument() (EC2InstanceIdentityDocument, error) {
- return c.GetInstanceIdentityDocumentWithContext(aws.BackgroundContext())
-}
-
-// GetInstanceIdentityDocumentWithContext retrieves an identity document describing an
-// instance. Error is returned if the request fails or is unable to parse
-// the response.
-func (c *EC2Metadata) GetInstanceIdentityDocumentWithContext(ctx aws.Context) (EC2InstanceIdentityDocument, error) {
- resp, err := c.GetDynamicDataWithContext(ctx, "instance-identity/document")
- if err != nil {
- return EC2InstanceIdentityDocument{},
- awserr.New("EC2MetadataRequestError",
- "failed to get EC2 instance identity document", err)
- }
-
- doc := EC2InstanceIdentityDocument{}
- if err := json.NewDecoder(strings.NewReader(resp)).Decode(&doc); err != nil {
- return EC2InstanceIdentityDocument{},
- awserr.New(request.ErrCodeSerialization,
- "failed to decode EC2 instance identity document", err)
- }
-
- return doc, nil
-}
-
-// IAMInfo retrieves IAM info from the metadata API
-func (c *EC2Metadata) IAMInfo() (EC2IAMInfo, error) {
- return c.IAMInfoWithContext(aws.BackgroundContext())
-}
-
-// IAMInfoWithContext retrieves IAM info from the metadata API
-func (c *EC2Metadata) IAMInfoWithContext(ctx aws.Context) (EC2IAMInfo, error) {
- resp, err := c.GetMetadataWithContext(ctx, "iam/info")
- if err != nil {
- return EC2IAMInfo{},
- awserr.New("EC2MetadataRequestError",
- "failed to get EC2 IAM info", err)
- }
-
- info := EC2IAMInfo{}
- if err := json.NewDecoder(strings.NewReader(resp)).Decode(&info); err != nil {
- return EC2IAMInfo{},
- awserr.New(request.ErrCodeSerialization,
- "failed to decode EC2 IAM info", err)
- }
-
- if info.Code != "Success" {
- errMsg := fmt.Sprintf("failed to get EC2 IAM Info (%s)", info.Code)
- return EC2IAMInfo{},
- awserr.New("EC2MetadataError", errMsg, nil)
- }
-
- return info, nil
-}
-
-// Region returns the region the instance is running in.
-func (c *EC2Metadata) Region() (string, error) {
- return c.RegionWithContext(aws.BackgroundContext())
-}
-
-// RegionWithContext returns the region the instance is running in.
-func (c *EC2Metadata) RegionWithContext(ctx aws.Context) (string, error) {
- ec2InstanceIdentityDocument, err := c.GetInstanceIdentityDocumentWithContext(ctx)
- if err != nil {
- return "", err
- }
- // extract region from the ec2InstanceIdentityDocument
- region := ec2InstanceIdentityDocument.Region
- if len(region) == 0 {
- return "", awserr.New("EC2MetadataError", "invalid region received for ec2metadata instance", nil)
- }
- // returns region
- return region, nil
-}
-
-// Available returns if the application has access to the EC2 Metadata service.
-// Can be used to determine if application is running within an EC2 Instance and
-// the metadata service is available.
-func (c *EC2Metadata) Available() bool {
- return c.AvailableWithContext(aws.BackgroundContext())
-}
-
-// AvailableWithContext returns if the application has access to the EC2 Metadata service.
-// Can be used to determine if application is running within an EC2 Instance and
-// the metadata service is available.
-func (c *EC2Metadata) AvailableWithContext(ctx aws.Context) bool {
- if _, err := c.GetMetadataWithContext(ctx, "instance-id"); err != nil {
- return false
- }
-
- return true
-}
-
-// An EC2IAMInfo provides the shape for unmarshaling
-// an IAM info from the metadata API
-type EC2IAMInfo struct {
- Code string
- LastUpdated time.Time
- InstanceProfileArn string
- InstanceProfileID string
-}
-
-// An EC2InstanceIdentityDocument provides the shape for unmarshaling
-// an instance identity document
-type EC2InstanceIdentityDocument struct {
- DevpayProductCodes []string `json:"devpayProductCodes"`
- MarketplaceProductCodes []string `json:"marketplaceProductCodes"`
- AvailabilityZone string `json:"availabilityZone"`
- PrivateIP string `json:"privateIp"`
- Version string `json:"version"`
- Region string `json:"region"`
- InstanceID string `json:"instanceId"`
- BillingProducts []string `json:"billingProducts"`
- InstanceType string `json:"instanceType"`
- AccountID string `json:"accountId"`
- PendingTime time.Time `json:"pendingTime"`
- ImageID string `json:"imageId"`
- KernelID string `json:"kernelId"`
- RamdiskID string `json:"ramdiskId"`
- Architecture string `json:"architecture"`
-}
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
deleted file mode 100644
index 8f35b3464ba1..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go
+++ /dev/null
@@ -1,245 +0,0 @@
-// Package ec2metadata provides the client for making API calls to the
-// EC2 Metadata service.
-//
-// This package's client can be disabled completely by setting the environment
-// variable "AWS_EC2_METADATA_DISABLED=true". This environment variable set to
-// true instructs the SDK to disable the EC2 Metadata client. The client cannot
-// be used while the environment variable is set to true, (case insensitive).
-//
-// The endpoint of the EC2 IMDS client can be configured via the environment
-// variable, AWS_EC2_METADATA_SERVICE_ENDPOINT when creating the client with a
-// Session. See aws/session#Options.EC2IMDSEndpoint for more details.
-package ec2metadata
-
-import (
- "bytes"
- "errors"
- "io"
- "net/http"
- "net/url"
- "os"
- "strconv"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/client"
- "github.com/aws/aws-sdk-go/aws/client/metadata"
- "github.com/aws/aws-sdk-go/aws/corehandlers"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-const (
- // ServiceName is the name of the service.
- ServiceName = "ec2metadata"
- disableServiceEnvVar = "AWS_EC2_METADATA_DISABLED"
-
- // Headers for Token and TTL
- ttlHeader = "x-aws-ec2-metadata-token-ttl-seconds"
- tokenHeader = "x-aws-ec2-metadata-token"
-
- // Named Handler constants
- fetchTokenHandlerName = "FetchTokenHandler"
- unmarshalMetadataHandlerName = "unmarshalMetadataHandler"
- unmarshalTokenHandlerName = "unmarshalTokenHandler"
- enableTokenProviderHandlerName = "enableTokenProviderHandler"
-
- // TTL constants
- defaultTTL = 21600 * time.Second
- ttlExpirationWindow = 30 * time.Second
-)
-
-// A EC2Metadata is an EC2 Metadata service Client.
-type EC2Metadata struct {
- *client.Client
-}
-
-// New creates a new instance of the EC2Metadata client with a session.
-// This client is safe to use across multiple goroutines.
-//
-//
-// Example:
-// // Create a EC2Metadata client from just a session.
-// svc := ec2metadata.New(mySession)
-//
-// // Create a EC2Metadata client with additional configuration
-// svc := ec2metadata.New(mySession, aws.NewConfig().WithLogLevel(aws.LogDebugHTTPBody))
-func New(p client.ConfigProvider, cfgs ...*aws.Config) *EC2Metadata {
- c := p.ClientConfig(ServiceName, cfgs...)
- return NewClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
-}
-
-// NewClient returns a new EC2Metadata client. Should be used to create
-// a client when not using a session. Generally using just New with a session
-// is preferred.
-//
-// Will remove the URL path from the endpoint provided to ensure the EC2 IMDS
-// client is able to communicate with the EC2 IMDS API.
-//
-// If an unmodified HTTP client is provided from the stdlib default, or no client
-// the EC2RoleProvider's EC2Metadata HTTP client's timeout will be shortened.
-// To disable this set Config.EC2MetadataDisableTimeoutOverride to false. Enabled by default.
-func NewClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string, opts ...func(*client.Client)) *EC2Metadata {
- if !aws.BoolValue(cfg.EC2MetadataDisableTimeoutOverride) && httpClientZero(cfg.HTTPClient) {
- // If the http client is unmodified and this feature is not disabled
- // set custom timeouts for EC2Metadata requests.
- cfg.HTTPClient = &http.Client{
- // use a shorter timeout than default because the metadata
- // service is local if it is running, and to fail faster
- // if not running on an ec2 instance.
- Timeout: 1 * time.Second,
- }
- // max number of retries on the client operation
- cfg.MaxRetries = aws.Int(2)
- }
-
- if u, err := url.Parse(endpoint); err == nil {
- // Remove path from the endpoint since it will be added by requests.
- // This is an artifact of the SDK adding `/latest` to the endpoint for
- // EC2 IMDS, but this is now moved to the operation definition.
- u.Path = ""
- u.RawPath = ""
- endpoint = u.String()
- }
-
- svc := &EC2Metadata{
- Client: client.New(
- cfg,
- metadata.ClientInfo{
- ServiceName: ServiceName,
- ServiceID: ServiceName,
- Endpoint: endpoint,
- APIVersion: "latest",
- },
- handlers,
- ),
- }
-
- // token provider instance
- tp := newTokenProvider(svc, defaultTTL)
-
- // NamedHandler for fetching token
- svc.Handlers.Sign.PushBackNamed(request.NamedHandler{
- Name: fetchTokenHandlerName,
- Fn: tp.fetchTokenHandler,
- })
- // NamedHandler for enabling token provider
- svc.Handlers.Complete.PushBackNamed(request.NamedHandler{
- Name: enableTokenProviderHandlerName,
- Fn: tp.enableTokenProviderHandler,
- })
-
- svc.Handlers.Unmarshal.PushBackNamed(unmarshalHandler)
- svc.Handlers.UnmarshalError.PushBack(unmarshalError)
- svc.Handlers.Validate.Clear()
- svc.Handlers.Validate.PushBack(validateEndpointHandler)
-
- // Disable the EC2 Metadata service if the environment variable is set.
- // This short-circuits the service's functionality to always fail to send
- // requests.
- if strings.ToLower(os.Getenv(disableServiceEnvVar)) == "true" {
- svc.Handlers.Send.SwapNamed(request.NamedHandler{
- Name: corehandlers.SendHandler.Name,
- Fn: func(r *request.Request) {
- r.HTTPResponse = &http.Response{
- Header: http.Header{},
- }
- r.Error = awserr.New(
- request.CanceledErrorCode,
- "EC2 IMDS access disabled via "+disableServiceEnvVar+" env var",
- nil)
- },
- })
- }
-
- // Add additional options to the service config
- for _, option := range opts {
- option(svc.Client)
- }
- return svc
-}
-
-func httpClientZero(c *http.Client) bool {
- return c == nil || (c.Transport == nil && c.CheckRedirect == nil && c.Jar == nil && c.Timeout == 0)
-}
-
-type metadataOutput struct {
- Content string
-}
-
-type tokenOutput struct {
- Token string
- TTL time.Duration
-}
-
-// unmarshal token handler is used to parse the response of a getToken operation
-var unmarshalTokenHandler = request.NamedHandler{
- Name: unmarshalTokenHandlerName,
- Fn: func(r *request.Request) {
- defer r.HTTPResponse.Body.Close()
- var b bytes.Buffer
- if _, err := io.Copy(&b, r.HTTPResponse.Body); err != nil {
- r.Error = awserr.NewRequestFailure(awserr.New(request.ErrCodeSerialization,
- "unable to unmarshal EC2 metadata response", err), r.HTTPResponse.StatusCode, r.RequestID)
- return
- }
-
- v := r.HTTPResponse.Header.Get(ttlHeader)
- data, ok := r.Data.(*tokenOutput)
- if !ok {
- return
- }
-
- data.Token = b.String()
- // TTL is in seconds
- i, err := strconv.ParseInt(v, 10, 64)
- if err != nil {
- r.Error = awserr.NewRequestFailure(awserr.New(request.ParamFormatErrCode,
- "unable to parse EC2 token TTL response", err), r.HTTPResponse.StatusCode, r.RequestID)
- return
- }
- t := time.Duration(i) * time.Second
- data.TTL = t
- },
-}
-
-var unmarshalHandler = request.NamedHandler{
- Name: unmarshalMetadataHandlerName,
- Fn: func(r *request.Request) {
- defer r.HTTPResponse.Body.Close()
- var b bytes.Buffer
- if _, err := io.Copy(&b, r.HTTPResponse.Body); err != nil {
- r.Error = awserr.NewRequestFailure(awserr.New(request.ErrCodeSerialization,
- "unable to unmarshal EC2 metadata response", err), r.HTTPResponse.StatusCode, r.RequestID)
- return
- }
-
- if data, ok := r.Data.(*metadataOutput); ok {
- data.Content = b.String()
- }
- },
-}
-
-func unmarshalError(r *request.Request) {
- defer r.HTTPResponse.Body.Close()
- var b bytes.Buffer
-
- if _, err := io.Copy(&b, r.HTTPResponse.Body); err != nil {
- r.Error = awserr.NewRequestFailure(
- awserr.New(request.ErrCodeSerialization, "unable to unmarshal EC2 metadata error response", err),
- r.HTTPResponse.StatusCode, r.RequestID)
- return
- }
-
- // Response body format is not consistent between metadata endpoints.
- // Grab the error message as a string and include that as the source error
- r.Error = awserr.NewRequestFailure(awserr.New("EC2MetadataError", "failed to make EC2Metadata request", errors.New(b.String())),
- r.HTTPResponse.StatusCode, r.RequestID)
-}
-
-func validateEndpointHandler(r *request.Request) {
- if r.ClientInfo.Endpoint == "" {
- r.Error = aws.ErrMissingEndpoint
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/token_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/token_provider.go
deleted file mode 100644
index 4b29f190bf94..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/token_provider.go
+++ /dev/null
@@ -1,93 +0,0 @@
-package ec2metadata
-
-import (
- "net/http"
- "sync/atomic"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// A tokenProvider struct provides access to EC2Metadata client
-// and atomic instance of a token, along with configuredTTL for it.
-// tokenProvider also provides an atomic flag to disable the
-// fetch token operation.
-// The disabled member will use 0 as false, and 1 as true.
-type tokenProvider struct {
- client *EC2Metadata
- token atomic.Value
- configuredTTL time.Duration
- disabled uint32
-}
-
-// A ec2Token struct helps use of token in EC2 Metadata service ops
-type ec2Token struct {
- token string
- credentials.Expiry
-}
-
-// newTokenProvider provides a pointer to a tokenProvider instance
-func newTokenProvider(c *EC2Metadata, duration time.Duration) *tokenProvider {
- return &tokenProvider{client: c, configuredTTL: duration}
-}
-
-// fetchTokenHandler fetches token for EC2Metadata service client by default.
-func (t *tokenProvider) fetchTokenHandler(r *request.Request) {
-
- // short-circuits to insecure data flow if tokenProvider is disabled.
- if v := atomic.LoadUint32(&t.disabled); v == 1 {
- return
- }
-
- if ec2Token, ok := t.token.Load().(ec2Token); ok && !ec2Token.IsExpired() {
- r.HTTPRequest.Header.Set(tokenHeader, ec2Token.token)
- return
- }
-
- output, err := t.client.getToken(r.Context(), t.configuredTTL)
-
- if err != nil {
-
- // change the disabled flag on token provider to true,
- // when error is request timeout error.
- if requestFailureError, ok := err.(awserr.RequestFailure); ok {
- switch requestFailureError.StatusCode() {
- case http.StatusForbidden, http.StatusNotFound, http.StatusMethodNotAllowed:
- atomic.StoreUint32(&t.disabled, 1)
- case http.StatusBadRequest:
- r.Error = requestFailureError
- }
-
- // Check if request timed out while waiting for response
- if e, ok := requestFailureError.OrigErr().(awserr.Error); ok {
- if e.Code() == request.ErrCodeRequestError {
- atomic.StoreUint32(&t.disabled, 1)
- }
- }
- }
- return
- }
-
- newToken := ec2Token{
- token: output.Token,
- }
- newToken.SetExpiration(time.Now().Add(output.TTL), ttlExpirationWindow)
- t.token.Store(newToken)
-
- // Inject token header to the request.
- if ec2Token, ok := t.token.Load().(ec2Token); ok {
- r.HTTPRequest.Header.Set(tokenHeader, ec2Token.token)
- }
-}
-
-// enableTokenProviderHandler enables the token provider
-func (t *tokenProvider) enableTokenProviderHandler(r *request.Request) {
- // If the error code status is 401, we enable the token provider
- if e, ok := r.Error.(awserr.RequestFailure); ok && e != nil &&
- e.StatusCode() == http.StatusUnauthorized {
- t.token.Store(ec2Token{})
- atomic.StoreUint32(&t.disabled, 0)
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go
deleted file mode 100644
index 654fb1ad52d0..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go
+++ /dev/null
@@ -1,216 +0,0 @@
-package endpoints
-
-import (
- "encoding/json"
- "fmt"
- "io"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-type modelDefinition map[string]json.RawMessage
-
-// A DecodeModelOptions are the options for how the endpoints model definition
-// are decoded.
-type DecodeModelOptions struct {
- SkipCustomizations bool
-}
-
-// Set combines all of the option functions together.
-func (d *DecodeModelOptions) Set(optFns ...func(*DecodeModelOptions)) {
- for _, fn := range optFns {
- fn(d)
- }
-}
-
-// DecodeModel unmarshals a Regions and Endpoint model definition file into
-// a endpoint Resolver. If the file format is not supported, or an error occurs
-// when unmarshaling the model an error will be returned.
-//
-// Casting the return value of this func to a EnumPartitions will
-// allow you to get a list of the partitions in the order the endpoints
-// will be resolved in.
-//
-// resolver, err := endpoints.DecodeModel(reader)
-//
-// partitions := resolver.(endpoints.EnumPartitions).Partitions()
-// for _, p := range partitions {
-// // ... inspect partitions
-// }
-func DecodeModel(r io.Reader, optFns ...func(*DecodeModelOptions)) (Resolver, error) {
- var opts DecodeModelOptions
- opts.Set(optFns...)
-
- // Get the version of the partition file to determine what
- // unmarshaling model to use.
- modelDef := modelDefinition{}
- if err := json.NewDecoder(r).Decode(&modelDef); err != nil {
- return nil, newDecodeModelError("failed to decode endpoints model", err)
- }
-
- var version string
- if b, ok := modelDef["version"]; ok {
- version = string(b)
- } else {
- return nil, newDecodeModelError("endpoints version not found in model", nil)
- }
-
- if version == "3" {
- return decodeV3Endpoints(modelDef, opts)
- }
-
- return nil, newDecodeModelError(
- fmt.Sprintf("endpoints version %s, not supported", version), nil)
-}
-
-func decodeV3Endpoints(modelDef modelDefinition, opts DecodeModelOptions) (Resolver, error) {
- b, ok := modelDef["partitions"]
- if !ok {
- return nil, newDecodeModelError("endpoints model missing partitions", nil)
- }
-
- ps := partitions{}
- if err := json.Unmarshal(b, &ps); err != nil {
- return nil, newDecodeModelError("failed to decode endpoints model", err)
- }
-
- if opts.SkipCustomizations {
- return ps, nil
- }
-
- // Customization
- for i := 0; i < len(ps); i++ {
- p := &ps[i]
- custAddEC2Metadata(p)
- custAddS3DualStack(p)
- custRegionalS3(p)
- custRmIotDataService(p)
- custFixAppAutoscalingChina(p)
- custFixAppAutoscalingUsGov(p)
- }
-
- return ps, nil
-}
-
-func custAddS3DualStack(p *partition) {
- if !(p.ID == "aws" || p.ID == "aws-cn" || p.ID == "aws-us-gov") {
- return
- }
-
- custAddDualstack(p, "s3")
- custAddDualstack(p, "s3-control")
-}
-
-func custRegionalS3(p *partition) {
- if p.ID != "aws" {
- return
- }
-
- service, ok := p.Services["s3"]
- if !ok {
- return
- }
-
- // If global endpoint already exists no customization needed.
- if _, ok := service.Endpoints["aws-global"]; ok {
- return
- }
-
- service.PartitionEndpoint = "aws-global"
- service.Endpoints["us-east-1"] = endpoint{}
- service.Endpoints["aws-global"] = endpoint{
- Hostname: "s3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- }
-
- p.Services["s3"] = service
-}
-
-func custAddDualstack(p *partition, svcName string) {
- s, ok := p.Services[svcName]
- if !ok {
- return
- }
-
- s.Defaults.HasDualStack = boxedTrue
- s.Defaults.DualStackHostname = "{service}.dualstack.{region}.{dnsSuffix}"
-
- p.Services[svcName] = s
-}
-
-func custAddEC2Metadata(p *partition) {
- p.Services["ec2metadata"] = service{
- IsRegionalized: boxedFalse,
- PartitionEndpoint: "aws-global",
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "169.254.169.254/latest",
- Protocols: []string{"http"},
- },
- },
- }
-}
-
-func custRmIotDataService(p *partition) {
- delete(p.Services, "data.iot")
-}
-
-func custFixAppAutoscalingChina(p *partition) {
- if p.ID != "aws-cn" {
- return
- }
-
- const serviceName = "application-autoscaling"
- s, ok := p.Services[serviceName]
- if !ok {
- return
- }
-
- const expectHostname = `autoscaling.{region}.amazonaws.com`
- if e, a := s.Defaults.Hostname, expectHostname; e != a {
- fmt.Printf("custFixAppAutoscalingChina: ignoring customization, expected %s, got %s\n", e, a)
- return
- }
-
- s.Defaults.Hostname = expectHostname + ".cn"
- p.Services[serviceName] = s
-}
-
-func custFixAppAutoscalingUsGov(p *partition) {
- if p.ID != "aws-us-gov" {
- return
- }
-
- const serviceName = "application-autoscaling"
- s, ok := p.Services[serviceName]
- if !ok {
- return
- }
-
- if a := s.Defaults.CredentialScope.Service; a != "" {
- fmt.Printf("custFixAppAutoscalingUsGov: ignoring customization, expected empty credential scope service, got %s\n", a)
- return
- }
-
- if a := s.Defaults.Hostname; a != "" {
- fmt.Printf("custFixAppAutoscalingUsGov: ignoring customization, expected empty hostname, got %s\n", a)
- return
- }
-
- s.Defaults.CredentialScope.Service = "application-autoscaling"
- s.Defaults.Hostname = "autoscaling.{region}.amazonaws.com"
-
- p.Services[serviceName] = s
-}
-
-type decodeModelError struct {
- awsError
-}
-
-func newDecodeModelError(msg string, err error) decodeModelError {
- return decodeModelError{
- awsError: awserr.New("DecodeEndpointsModelError", msg, err),
- }
-}
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
deleted file mode 100644
index c303910847cd..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
+++ /dev/null
@@ -1,9912 +0,0 @@
-// Code generated by aws/endpoints/v3model_codegen.go. DO NOT EDIT.
-
-package endpoints
-
-import (
- "regexp"
-)
-
-// Partition identifiers
-const (
- AwsPartitionID = "aws" // AWS Standard partition.
- AwsCnPartitionID = "aws-cn" // AWS China partition.
- AwsUsGovPartitionID = "aws-us-gov" // AWS GovCloud (US) partition.
- AwsIsoPartitionID = "aws-iso" // AWS ISO (US) partition.
- AwsIsoBPartitionID = "aws-iso-b" // AWS ISOB (US) partition.
-)
-
-// AWS Standard partition's regions.
-const (
- AfSouth1RegionID = "af-south-1" // Africa (Cape Town).
- ApEast1RegionID = "ap-east-1" // Asia Pacific (Hong Kong).
- ApNortheast1RegionID = "ap-northeast-1" // Asia Pacific (Tokyo).
- ApNortheast2RegionID = "ap-northeast-2" // Asia Pacific (Seoul).
- ApSouth1RegionID = "ap-south-1" // Asia Pacific (Mumbai).
- ApSoutheast1RegionID = "ap-southeast-1" // Asia Pacific (Singapore).
- ApSoutheast2RegionID = "ap-southeast-2" // Asia Pacific (Sydney).
- CaCentral1RegionID = "ca-central-1" // Canada (Central).
- EuCentral1RegionID = "eu-central-1" // Europe (Frankfurt).
- EuNorth1RegionID = "eu-north-1" // Europe (Stockholm).
- EuSouth1RegionID = "eu-south-1" // Europe (Milan).
- EuWest1RegionID = "eu-west-1" // Europe (Ireland).
- EuWest2RegionID = "eu-west-2" // Europe (London).
- EuWest3RegionID = "eu-west-3" // Europe (Paris).
- MeSouth1RegionID = "me-south-1" // Middle East (Bahrain).
- SaEast1RegionID = "sa-east-1" // South America (Sao Paulo).
- UsEast1RegionID = "us-east-1" // US East (N. Virginia).
- UsEast2RegionID = "us-east-2" // US East (Ohio).
- UsWest1RegionID = "us-west-1" // US West (N. California).
- UsWest2RegionID = "us-west-2" // US West (Oregon).
-)
-
-// AWS China partition's regions.
-const (
- CnNorth1RegionID = "cn-north-1" // China (Beijing).
- CnNorthwest1RegionID = "cn-northwest-1" // China (Ningxia).
-)
-
-// AWS GovCloud (US) partition's regions.
-const (
- UsGovEast1RegionID = "us-gov-east-1" // AWS GovCloud (US-East).
- UsGovWest1RegionID = "us-gov-west-1" // AWS GovCloud (US-West).
-)
-
-// AWS ISO (US) partition's regions.
-const (
- UsIsoEast1RegionID = "us-iso-east-1" // US ISO East.
-)
-
-// AWS ISOB (US) partition's regions.
-const (
- UsIsobEast1RegionID = "us-isob-east-1" // US ISOB East (Ohio).
-)
-
-// DefaultResolver returns an Endpoint resolver that will be able
-// to resolve endpoints for: AWS Standard, AWS China, AWS GovCloud (US), AWS ISO (US), and AWS ISOB (US).
-//
-// Use DefaultPartitions() to get the list of the default partitions.
-func DefaultResolver() Resolver {
- return defaultPartitions
-}
-
-// DefaultPartitions returns a list of the partitions the SDK is bundled
-// with. The available partitions are: AWS Standard, AWS China, AWS GovCloud (US), AWS ISO (US), and AWS ISOB (US).
-//
-// partitions := endpoints.DefaultPartitions
-// for _, p := range partitions {
-// // ... inspect partitions
-// }
-func DefaultPartitions() []Partition {
- return defaultPartitions.Partitions()
-}
-
-var defaultPartitions = partitions{
- awsPartition,
- awscnPartition,
- awsusgovPartition,
- awsisoPartition,
- awsisobPartition,
-}
-
-// AwsPartition returns the Resolver for AWS Standard.
-func AwsPartition() Partition {
- return awsPartition.Partition()
-}
-
-var awsPartition = partition{
- ID: "aws",
- Name: "AWS Standard",
- DNSSuffix: "amazonaws.com",
- RegionRegex: regionRegex{
- Regexp: func() *regexp.Regexp {
- reg, _ := regexp.Compile("^(us|eu|ap|sa|ca|me|af)\\-\\w+\\-\\d+$")
- return reg
- }(),
- },
- Defaults: endpoint{
- Hostname: "{service}.{region}.{dnsSuffix}",
- Protocols: []string{"https"},
- SignatureVersions: []string{"v4"},
- },
- Regions: regions{
- "af-south-1": region{
- Description: "Africa (Cape Town)",
- },
- "ap-east-1": region{
- Description: "Asia Pacific (Hong Kong)",
- },
- "ap-northeast-1": region{
- Description: "Asia Pacific (Tokyo)",
- },
- "ap-northeast-2": region{
- Description: "Asia Pacific (Seoul)",
- },
- "ap-south-1": region{
- Description: "Asia Pacific (Mumbai)",
- },
- "ap-southeast-1": region{
- Description: "Asia Pacific (Singapore)",
- },
- "ap-southeast-2": region{
- Description: "Asia Pacific (Sydney)",
- },
- "ca-central-1": region{
- Description: "Canada (Central)",
- },
- "eu-central-1": region{
- Description: "Europe (Frankfurt)",
- },
- "eu-north-1": region{
- Description: "Europe (Stockholm)",
- },
- "eu-south-1": region{
- Description: "Europe (Milan)",
- },
- "eu-west-1": region{
- Description: "Europe (Ireland)",
- },
- "eu-west-2": region{
- Description: "Europe (London)",
- },
- "eu-west-3": region{
- Description: "Europe (Paris)",
- },
- "me-south-1": region{
- Description: "Middle East (Bahrain)",
- },
- "sa-east-1": region{
- Description: "South America (Sao Paulo)",
- },
- "us-east-1": region{
- Description: "US East (N. Virginia)",
- },
- "us-east-2": region{
- Description: "US East (Ohio)",
- },
- "us-west-1": region{
- Description: "US West (N. California)",
- },
- "us-west-2": region{
- Description: "US West (Oregon)",
- },
- },
- Services: services{
- "a4b": service{
-
- Endpoints: endpoints{
- "us-east-1": endpoint{},
- },
- },
- "access-analyzer": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "access-analyzer-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "access-analyzer-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "access-analyzer-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "access-analyzer-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "access-analyzer-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "acm": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "ca-central-1-fips": endpoint{
- Hostname: "acm-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "acm-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "acm-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "acm-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "acm-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "acm-pca": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "acm-pca-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "acm-pca-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "acm-pca-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "acm-pca-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "acm-pca-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "api.detective": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "api.ecr": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{
- Hostname: "api.ecr.af-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "af-south-1",
- },
- },
- "ap-east-1": endpoint{
- Hostname: "api.ecr.ap-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-east-1",
- },
- },
- "ap-northeast-1": endpoint{
- Hostname: "api.ecr.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "ap-northeast-2": endpoint{
- Hostname: "api.ecr.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "ap-south-1": endpoint{
- Hostname: "api.ecr.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "ap-southeast-1": endpoint{
- Hostname: "api.ecr.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "ap-southeast-2": endpoint{
- Hostname: "api.ecr.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "ca-central-1": endpoint{
- Hostname: "api.ecr.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{
- Hostname: "api.ecr.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "eu-north-1": endpoint{
- Hostname: "api.ecr.eu-north-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-north-1",
- },
- },
- "eu-south-1": endpoint{
- Hostname: "api.ecr.eu-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-south-1",
- },
- },
- "eu-west-1": endpoint{
- Hostname: "api.ecr.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "eu-west-2": endpoint{
- Hostname: "api.ecr.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "eu-west-3": endpoint{
- Hostname: "api.ecr.eu-west-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "fips-dkr-us-east-1": endpoint{
- Hostname: "ecr-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-dkr-us-east-2": endpoint{
- Hostname: "ecr-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-dkr-us-west-1": endpoint{
- Hostname: "ecr-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-dkr-us-west-2": endpoint{
- Hostname: "ecr-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "ecr-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "ecr-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "ecr-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "ecr-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{
- Hostname: "api.ecr.me-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "me-south-1",
- },
- },
- "sa-east-1": endpoint{
- Hostname: "api.ecr.sa-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "sa-east-1",
- },
- },
- "us-east-1": endpoint{
- Hostname: "api.ecr.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{
- Hostname: "api.ecr.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{
- Hostname: "api.ecr.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{
- Hostname: "api.ecr.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "api.elastic-inference": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{
- Hostname: "api.elastic-inference.ap-northeast-1.amazonaws.com",
- },
- "ap-northeast-2": endpoint{
- Hostname: "api.elastic-inference.ap-northeast-2.amazonaws.com",
- },
- "eu-west-1": endpoint{
- Hostname: "api.elastic-inference.eu-west-1.amazonaws.com",
- },
- "us-east-1": endpoint{
- Hostname: "api.elastic-inference.us-east-1.amazonaws.com",
- },
- "us-east-2": endpoint{
- Hostname: "api.elastic-inference.us-east-2.amazonaws.com",
- },
- "us-west-2": endpoint{
- Hostname: "api.elastic-inference.us-west-2.amazonaws.com",
- },
- },
- },
- "api.mediatailor": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "api.pricing": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "pricing",
- },
- },
- Endpoints: endpoints{
- "ap-south-1": endpoint{},
- "us-east-1": endpoint{},
- },
- },
- "api.sagemaker": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "api-fips.sagemaker.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "api-fips.sagemaker.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "api-fips.sagemaker.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "api-fips.sagemaker.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "apigateway": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "appflow": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "application-autoscaling": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "appmesh": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "appstream2": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- CredentialScope: credentialScope{
- Service: "appstream",
- },
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "fips": endpoint{
- Hostname: "appstream2-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "appsync": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "athena": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "autoscaling": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "autoscaling-plans": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "backup": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "batch": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "fips.batch.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "fips.batch.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "fips.batch.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "fips.batch.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "budgets": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "budgets.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "ce": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "ce.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "chime": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
- Defaults: endpoint{
- SSLCommonName: "service.chime.aws.amazon.com",
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "service.chime.aws.amazon.com",
- Protocols: []string{"https"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "cloud9": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "clouddirectory": service{
-
- Endpoints: endpoints{
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "cloudformation": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "cloudformation-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "cloudformation-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "cloudformation-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "cloudformation-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "cloudfront": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "cloudfront.amazonaws.com",
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "cloudhsm": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "cloudhsmv2": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "cloudhsm",
- },
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "cloudsearch": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "cloudtrail": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "cloudtrail-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "cloudtrail-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "cloudtrail-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "cloudtrail-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "codeartifact": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "codebuild": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "codebuild-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "codebuild-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "codebuild-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "codebuild-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "codecommit": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips": endpoint{
- Hostname: "codecommit-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "codedeploy": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "codedeploy-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "codedeploy-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "codedeploy-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "codedeploy-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "codepipeline": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "codepipeline-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "codepipeline-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "codepipeline-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "codepipeline-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "codepipeline-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "codestar": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "codestar-connections": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "cognito-identity": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "cognito-identity-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "cognito-identity-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "cognito-identity-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "cognito-idp": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "cognito-idp-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "cognito-idp-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "cognito-idp-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "cognito-sync": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "comprehend": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "comprehend-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "comprehend-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "comprehend-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "comprehendmedical": service{
-
- Endpoints: endpoints{
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "comprehendmedical-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "comprehendmedical-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "comprehendmedical-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "config": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "connect": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "cur": service{
-
- Endpoints: endpoints{
- "us-east-1": endpoint{},
- },
- },
- "data.mediastore": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "dataexchange": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "datapipeline": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "datasync": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "datasync-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "datasync-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "datasync-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "datasync-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "datasync-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "dax": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "devicefarm": service{
-
- Endpoints: endpoints{
- "us-west-2": endpoint{},
- },
- },
- "directconnect": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "directconnect-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "directconnect-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "directconnect-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "directconnect-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "discovery": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "dms": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "dms-fips": endpoint{
- Hostname: "dms-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "docdb": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{
- Hostname: "rds.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "ap-northeast-2": endpoint{
- Hostname: "rds.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "ap-south-1": endpoint{
- Hostname: "rds.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "ap-southeast-1": endpoint{
- Hostname: "rds.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "ap-southeast-2": endpoint{
- Hostname: "rds.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "ca-central-1": endpoint{
- Hostname: "rds.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{
- Hostname: "rds.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "eu-west-1": endpoint{
- Hostname: "rds.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "eu-west-2": endpoint{
- Hostname: "rds.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "eu-west-3": endpoint{
- Hostname: "rds.eu-west-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "us-east-1": endpoint{
- Hostname: "rds.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{
- Hostname: "rds.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-2": endpoint{
- Hostname: "rds.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "ds": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "ds-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "ds-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "ds-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "ds-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "ds-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "dynamodb": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "ca-central-1-fips": endpoint{
- Hostname: "dynamodb-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "local": endpoint{
- Hostname: "localhost:8000",
- Protocols: []string{"http"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "dynamodb-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "dynamodb-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "dynamodb-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "dynamodb-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "ebs": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "ebs-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "ebs-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "ebs-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "ebs-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "ebs-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "ec2": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "ec2-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "ec2-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "ec2-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "ec2-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "ec2-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "ec2metadata": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "169.254.169.254/latest",
- Protocols: []string{"http"},
- },
- },
- },
- "ecs": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "ecs-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "ecs-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "ecs-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "ecs-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "eks": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "fips.eks.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "fips.eks.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "fips.eks.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "fips.eks.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "elasticache": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips": endpoint{
- Hostname: "elasticache-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "elasticbeanstalk": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "elasticbeanstalk-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "elasticbeanstalk-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "elasticbeanstalk-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "elasticbeanstalk-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "elasticfilesystem": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-af-south-1": endpoint{
- Hostname: "elasticfilesystem-fips.af-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "af-south-1",
- },
- },
- "fips-ap-east-1": endpoint{
- Hostname: "elasticfilesystem-fips.ap-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-east-1",
- },
- },
- "fips-ap-northeast-1": endpoint{
- Hostname: "elasticfilesystem-fips.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "fips-ap-northeast-2": endpoint{
- Hostname: "elasticfilesystem-fips.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "fips-ap-south-1": endpoint{
- Hostname: "elasticfilesystem-fips.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "fips-ap-southeast-1": endpoint{
- Hostname: "elasticfilesystem-fips.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "fips-ap-southeast-2": endpoint{
- Hostname: "elasticfilesystem-fips.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "fips-ca-central-1": endpoint{
- Hostname: "elasticfilesystem-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-eu-central-1": endpoint{
- Hostname: "elasticfilesystem-fips.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "fips-eu-north-1": endpoint{
- Hostname: "elasticfilesystem-fips.eu-north-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-north-1",
- },
- },
- "fips-eu-south-1": endpoint{
- Hostname: "elasticfilesystem-fips.eu-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-south-1",
- },
- },
- "fips-eu-west-1": endpoint{
- Hostname: "elasticfilesystem-fips.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "fips-eu-west-2": endpoint{
- Hostname: "elasticfilesystem-fips.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "fips-eu-west-3": endpoint{
- Hostname: "elasticfilesystem-fips.eu-west-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "fips-me-south-1": endpoint{
- Hostname: "elasticfilesystem-fips.me-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "me-south-1",
- },
- },
- "fips-sa-east-1": endpoint{
- Hostname: "elasticfilesystem-fips.sa-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "sa-east-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "elasticfilesystem-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "elasticfilesystem-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "elasticfilesystem-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "elasticfilesystem-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "elasticloadbalancing": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "elasticloadbalancing-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "elasticloadbalancing-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "elasticloadbalancing-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "elasticloadbalancing-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "elasticmapreduce": service{
- Defaults: endpoint{
- SSLCommonName: "{region}.{service}.{dnsSuffix}",
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{
- SSLCommonName: "{service}.{region}.{dnsSuffix}",
- },
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "elasticmapreduce-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "elasticmapreduce-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "elasticmapreduce-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "elasticmapreduce-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "elasticmapreduce-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{
- SSLCommonName: "{service}.{region}.{dnsSuffix}",
- },
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "elastictranscoder": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "email": service{
-
- Endpoints: endpoints{
- "ap-south-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "entitlement.marketplace": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "aws-marketplace",
- },
- },
- Endpoints: endpoints{
- "us-east-1": endpoint{},
- },
- },
- "es": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips": endpoint{
- Hostname: "es-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "events": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "events-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "events-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "events-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "events-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "firehose": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "firehose-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "firehose-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "firehose-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "firehose-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "fms": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ap-northeast-1": endpoint{
- Hostname: "fms-fips.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "fips-ap-northeast-2": endpoint{
- Hostname: "fms-fips.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "fips-ap-south-1": endpoint{
- Hostname: "fms-fips.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "fips-ap-southeast-1": endpoint{
- Hostname: "fms-fips.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "fips-ap-southeast-2": endpoint{
- Hostname: "fms-fips.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "fips-ca-central-1": endpoint{
- Hostname: "fms-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-eu-central-1": endpoint{
- Hostname: "fms-fips.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "fips-eu-west-1": endpoint{
- Hostname: "fms-fips.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "fips-eu-west-2": endpoint{
- Hostname: "fms-fips.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "fips-eu-west-3": endpoint{
- Hostname: "fms-fips.eu-west-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "fips-sa-east-1": endpoint{
- Hostname: "fms-fips.sa-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "sa-east-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "fms-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "fms-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "fms-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "fms-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "forecast": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "forecastquery": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "fsx": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "gamelift": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "glacier": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "glacier-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "glacier-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "glacier-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "glacier-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "glacier-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "glue": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "glue-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "glue-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "glue-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "glue-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "greengrass": service{
- IsRegionalized: boxedTrue,
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "groundstation": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "fips-us-east-2": endpoint{
- Hostname: "groundstation-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "groundstation-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "guardduty": service{
- IsRegionalized: boxedTrue,
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "guardduty-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "guardduty-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "guardduty-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "guardduty-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "health": service{
-
- Endpoints: endpoints{
- "fips-us-east-2": endpoint{
- Hostname: "health-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- },
- },
- "honeycode": service{
-
- Endpoints: endpoints{
- "us-west-2": endpoint{},
- },
- },
- "iam": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "iam.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "iam-fips": endpoint{
- Hostname: "iam-fips.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "identitystore": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "importexport": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "importexport.amazonaws.com",
- SignatureVersions: []string{"v2", "v4"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- Service: "IngestionService",
- },
- },
- },
- },
- "inspector": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "inspector-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "inspector-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "inspector-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "inspector-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "iot": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
- },
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "iotanalytics": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "iotevents": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "ioteventsdata": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{
- Hostname: "data.iotevents.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "ap-northeast-2": endpoint{
- Hostname: "data.iotevents.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "ap-southeast-1": endpoint{
- Hostname: "data.iotevents.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "ap-southeast-2": endpoint{
- Hostname: "data.iotevents.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "eu-central-1": endpoint{
- Hostname: "data.iotevents.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "eu-west-1": endpoint{
- Hostname: "data.iotevents.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "eu-west-2": endpoint{
- Hostname: "data.iotevents.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "us-east-1": endpoint{
- Hostname: "data.iotevents.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{
- Hostname: "data.iotevents.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-2": endpoint{
- Hostname: "data.iotevents.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "iotsecuredtunneling": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "iotthingsgraph": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "iotthingsgraph",
- },
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "kafka": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "kinesis": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "kinesis-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "kinesis-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "kinesis-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "kinesis-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "kinesisanalytics": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "kinesisvideo": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "kms": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "lakeformation": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "lakeformation-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "lakeformation-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "lakeformation-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "lakeformation-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "lambda": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "lambda-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "lambda-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "lambda-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "lambda-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "license-manager": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "license-manager-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "license-manager-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "license-manager-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "license-manager-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "lightsail": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "logs": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "logs-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "logs-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "logs-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "logs-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "machinelearning": service{
-
- Endpoints: endpoints{
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- },
- },
- "macie": service{
-
- Endpoints: endpoints{
- "fips-us-east-1": endpoint{
- Hostname: "macie-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "macie-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "macie2": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "macie2-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "macie2-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "macie2-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "macie2-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "managedblockchain": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- },
- },
- "marketplacecommerceanalytics": service{
-
- Endpoints: endpoints{
- "us-east-1": endpoint{},
- },
- },
- "mediaconnect": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "mediaconvert": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "mediaconvert-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "mediaconvert-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "mediaconvert-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "mediaconvert-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "mediaconvert-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "medialive": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "medialive-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "medialive-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "medialive-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "mediapackage": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "mediastore": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "metering.marketplace": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "aws-marketplace",
- },
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "mgh": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "mobileanalytics": service{
-
- Endpoints: endpoints{
- "us-east-1": endpoint{},
- },
- },
- "models.lex": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "lex",
- },
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "monitoring": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "monitoring-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "monitoring-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "monitoring-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "monitoring-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "mq": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "mq-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "mq-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "mq-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "mq-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "mturk-requester": service{
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "sandbox": endpoint{
- Hostname: "mturk-requester-sandbox.us-east-1.amazonaws.com",
- },
- "us-east-1": endpoint{},
- },
- },
- "neptune": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{
- Hostname: "rds.ap-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-east-1",
- },
- },
- "ap-northeast-1": endpoint{
- Hostname: "rds.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "ap-northeast-2": endpoint{
- Hostname: "rds.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "ap-south-1": endpoint{
- Hostname: "rds.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "ap-southeast-1": endpoint{
- Hostname: "rds.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "ap-southeast-2": endpoint{
- Hostname: "rds.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "ca-central-1": endpoint{
- Hostname: "rds.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{
- Hostname: "rds.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "eu-north-1": endpoint{
- Hostname: "rds.eu-north-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-north-1",
- },
- },
- "eu-west-1": endpoint{
- Hostname: "rds.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "eu-west-2": endpoint{
- Hostname: "rds.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "eu-west-3": endpoint{
- Hostname: "rds.eu-west-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "me-south-1": endpoint{
- Hostname: "rds.me-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "me-south-1",
- },
- },
- "sa-east-1": endpoint{
- Hostname: "rds.sa-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "sa-east-1",
- },
- },
- "us-east-1": endpoint{
- Hostname: "rds.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{
- Hostname: "rds.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{
- Hostname: "rds.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{
- Hostname: "rds.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "oidc": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{
- Hostname: "oidc.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "ap-northeast-2": endpoint{
- Hostname: "oidc.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "ap-south-1": endpoint{
- Hostname: "oidc.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "ap-southeast-1": endpoint{
- Hostname: "oidc.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "ap-southeast-2": endpoint{
- Hostname: "oidc.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "ca-central-1": endpoint{
- Hostname: "oidc.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{
- Hostname: "oidc.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "eu-north-1": endpoint{
- Hostname: "oidc.eu-north-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-north-1",
- },
- },
- "eu-west-1": endpoint{
- Hostname: "oidc.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "eu-west-2": endpoint{
- Hostname: "oidc.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "us-east-1": endpoint{
- Hostname: "oidc.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{
- Hostname: "oidc.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-2": endpoint{
- Hostname: "oidc.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "opsworks": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "opsworks-cm": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "organizations": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "organizations.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-aws-global": endpoint{
- Hostname: "organizations-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "outposts": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "outposts-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "outposts-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "outposts-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "outposts-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "outposts-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "pinpoint": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "mobiletargeting",
- },
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "pinpoint-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "pinpoint-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{
- Hostname: "pinpoint.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-west-2": endpoint{
- Hostname: "pinpoint.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "polly": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "polly-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "polly-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "polly-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "polly-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "portal.sso": service{
-
- Endpoints: endpoints{
- "ap-southeast-1": endpoint{
- Hostname: "portal.sso.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "ap-southeast-2": endpoint{
- Hostname: "portal.sso.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "ca-central-1": endpoint{
- Hostname: "portal.sso.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{
- Hostname: "portal.sso.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "eu-west-1": endpoint{
- Hostname: "portal.sso.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "eu-west-2": endpoint{
- Hostname: "portal.sso.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "us-east-1": endpoint{
- Hostname: "portal.sso.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{
- Hostname: "portal.sso.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-2": endpoint{
- Hostname: "portal.sso.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "projects.iot1click": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "qldb": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "ram": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "rds": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "rds-fips.ca-central-1": endpoint{
- Hostname: "rds-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "rds-fips.us-east-1": endpoint{
- Hostname: "rds-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "rds-fips.us-east-2": endpoint{
- Hostname: "rds-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "rds-fips.us-west-1": endpoint{
- Hostname: "rds-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "rds-fips.us-west-2": endpoint{
- Hostname: "rds-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{
- SSLCommonName: "{service}.{dnsSuffix}",
- },
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "redshift": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "redshift-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "redshift-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "redshift-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "redshift-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "redshift-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "rekognition": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "rekognition-fips.ca-central-1": endpoint{
- Hostname: "rekognition-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "rekognition-fips.us-east-1": endpoint{
- Hostname: "rekognition-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "rekognition-fips.us-east-2": endpoint{
- Hostname: "rekognition-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "rekognition-fips.us-west-1": endpoint{
- Hostname: "rekognition-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "rekognition-fips.us-west-2": endpoint{
- Hostname: "rekognition-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "resource-groups": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "resource-groups-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "resource-groups-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "resource-groups-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "resource-groups-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "robomaker": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "route53": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "route53.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-aws-global": endpoint{
- Hostname: "route53-fips.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "route53domains": service{
-
- Endpoints: endpoints{
- "us-east-1": endpoint{},
- },
- },
- "route53resolver": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "runtime.lex": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "lex",
- },
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "runtime.sagemaker": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "runtime-fips.sagemaker.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "runtime-fips.sagemaker.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "runtime-fips.sagemaker.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "runtime-fips.sagemaker.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "s3": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedTrue,
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- SignatureVersions: []string{"s3v4"},
-
- HasDualStack: boxedTrue,
- DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}",
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{
- Hostname: "s3.ap-northeast-1.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- },
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{
- Hostname: "s3.ap-southeast-1.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- },
- "ap-southeast-2": endpoint{
- Hostname: "s3.ap-southeast-2.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- },
- "aws-global": endpoint{
- Hostname: "s3.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{
- Hostname: "s3.eu-west-1.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- },
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "s3-external-1": endpoint{
- Hostname: "s3-external-1.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "sa-east-1": endpoint{
- Hostname: "s3.sa-east-1.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- },
- "us-east-1": endpoint{
- Hostname: "s3.us-east-1.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- },
- "us-east-2": endpoint{},
- "us-west-1": endpoint{
- Hostname: "s3.us-west-1.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- },
- "us-west-2": endpoint{
- Hostname: "s3.us-west-2.amazonaws.com",
- SignatureVersions: []string{"s3", "s3v4"},
- },
- },
- },
- "s3-control": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- SignatureVersions: []string{"s3v4"},
-
- HasDualStack: boxedTrue,
- DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}",
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{
- Hostname: "s3-control.ap-northeast-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "ap-northeast-2": endpoint{
- Hostname: "s3-control.ap-northeast-2.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "ap-south-1": endpoint{
- Hostname: "s3-control.ap-south-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "ap-southeast-1": endpoint{
- Hostname: "s3-control.ap-southeast-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "ap-southeast-2": endpoint{
- Hostname: "s3-control.ap-southeast-2.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "ca-central-1": endpoint{
- Hostname: "s3-control.ca-central-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "ca-central-1-fips": endpoint{
- Hostname: "s3-control-fips.ca-central-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{
- Hostname: "s3-control.eu-central-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "eu-north-1": endpoint{
- Hostname: "s3-control.eu-north-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "eu-north-1",
- },
- },
- "eu-west-1": endpoint{
- Hostname: "s3-control.eu-west-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "eu-west-2": endpoint{
- Hostname: "s3-control.eu-west-2.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "eu-west-3": endpoint{
- Hostname: "s3-control.eu-west-3.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "sa-east-1": endpoint{
- Hostname: "s3-control.sa-east-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "sa-east-1",
- },
- },
- "us-east-1": endpoint{
- Hostname: "s3-control.us-east-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-1-fips": endpoint{
- Hostname: "s3-control-fips.us-east-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{
- Hostname: "s3-control.us-east-2.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-east-2-fips": endpoint{
- Hostname: "s3-control-fips.us-east-2.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{
- Hostname: "s3-control.us-west-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-1-fips": endpoint{
- Hostname: "s3-control-fips.us-west-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{
- Hostname: "s3-control.us-west-2.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-west-2-fips": endpoint{
- Hostname: "s3-control-fips.us-west-2.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "savingsplans": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "savingsplans.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "schemas": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "sdb": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- SignatureVersions: []string{"v2"},
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-west-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{
- Hostname: "sdb.amazonaws.com",
- },
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "secretsmanager": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "secretsmanager-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "secretsmanager-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "secretsmanager-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "secretsmanager-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "securityhub": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "securityhub-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "securityhub-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "securityhub-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "securityhub-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "serverlessrepo": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "ap-east-1": endpoint{
- Protocols: []string{"https"},
- },
- "ap-northeast-1": endpoint{
- Protocols: []string{"https"},
- },
- "ap-northeast-2": endpoint{
- Protocols: []string{"https"},
- },
- "ap-south-1": endpoint{
- Protocols: []string{"https"},
- },
- "ap-southeast-1": endpoint{
- Protocols: []string{"https"},
- },
- "ap-southeast-2": endpoint{
- Protocols: []string{"https"},
- },
- "ca-central-1": endpoint{
- Protocols: []string{"https"},
- },
- "eu-central-1": endpoint{
- Protocols: []string{"https"},
- },
- "eu-north-1": endpoint{
- Protocols: []string{"https"},
- },
- "eu-west-1": endpoint{
- Protocols: []string{"https"},
- },
- "eu-west-2": endpoint{
- Protocols: []string{"https"},
- },
- "eu-west-3": endpoint{
- Protocols: []string{"https"},
- },
- "me-south-1": endpoint{
- Protocols: []string{"https"},
- },
- "sa-east-1": endpoint{
- Protocols: []string{"https"},
- },
- "us-east-1": endpoint{
- Protocols: []string{"https"},
- },
- "us-east-2": endpoint{
- Protocols: []string{"https"},
- },
- "us-west-1": endpoint{
- Protocols: []string{"https"},
- },
- "us-west-2": endpoint{
- Protocols: []string{"https"},
- },
- },
- },
- "servicecatalog": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "servicecatalog-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "servicecatalog-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "servicecatalog-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "servicecatalog-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "servicediscovery": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "servicediscovery-fips": endpoint{
- Hostname: "servicediscovery-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "servicequotas": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "session.qldb": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "shield": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
- Defaults: endpoint{
- SSLCommonName: "shield.us-east-1.amazonaws.com",
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "shield.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-aws-global": endpoint{
- Hostname: "shield-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "sms": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "sms-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "sms-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "sms-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "sms-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "snowball": service{
-
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ap-northeast-1": endpoint{
- Hostname: "snowball-fips.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "fips-ap-northeast-2": endpoint{
- Hostname: "snowball-fips.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "fips-ap-northeast-3": endpoint{
- Hostname: "snowball-fips.ap-northeast-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-3",
- },
- },
- "fips-ap-south-1": endpoint{
- Hostname: "snowball-fips.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "fips-ap-southeast-1": endpoint{
- Hostname: "snowball-fips.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "fips-ap-southeast-2": endpoint{
- Hostname: "snowball-fips.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "fips-ca-central-1": endpoint{
- Hostname: "snowball-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-eu-central-1": endpoint{
- Hostname: "snowball-fips.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "fips-eu-west-1": endpoint{
- Hostname: "snowball-fips.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "fips-eu-west-2": endpoint{
- Hostname: "snowball-fips.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "fips-eu-west-3": endpoint{
- Hostname: "snowball-fips.eu-west-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "fips-sa-east-1": endpoint{
- Hostname: "snowball-fips.sa-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "sa-east-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "snowball-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "snowball-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "snowball-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "snowball-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "sns": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "sns-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "sns-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "sns-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "sns-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "sqs": service{
- Defaults: endpoint{
- SSLCommonName: "{region}.queue.{dnsSuffix}",
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "sqs-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "sqs-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "sqs-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "sqs-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{
- SSLCommonName: "queue.{dnsSuffix}",
- },
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "ssm": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "ssm-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "ssm-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "ssm-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "ssm-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "ssm-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "states": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "states-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "states-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "states-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "states-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "storagegateway": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips": endpoint{
- Hostname: "storagegateway-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "streams.dynamodb": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Service: "dynamodb",
- },
- },
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "ca-central-1-fips": endpoint{
- Hostname: "dynamodb-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "local": endpoint{
- Hostname: "localhost:8000",
- Protocols: []string{"http"},
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "dynamodb-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "dynamodb-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "dynamodb-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "dynamodb-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "sts": service{
- PartitionEndpoint: "aws-global",
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "aws-global": endpoint{
- Hostname: "sts.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "sts-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "sts-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-1-fips": endpoint{
- Hostname: "sts-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "sts-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "support": service{
- PartitionEndpoint: "aws-global",
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "support.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "swf": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "swf-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "swf-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "swf-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "swf-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "tagging": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "transcribe": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "fips.transcribe.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "fips.transcribe.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "fips.transcribe.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "fips.transcribe.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "transcribestreaming": service{
-
- Endpoints: endpoints{
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "transfer": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "fips-ca-central-1": endpoint{
- Hostname: "transfer-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "transfer-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "transfer-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "transfer-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "transfer-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "translate": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "us-east-1": endpoint{},
- "us-east-1-fips": endpoint{
- Hostname: "translate-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{},
- "us-east-2-fips": endpoint{
- Hostname: "translate-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- "us-west-2-fips": endpoint{
- Hostname: "translate-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "waf": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-fips": endpoint{
- Hostname: "waf-fips.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "aws-global": endpoint{
- Hostname: "waf.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- },
- },
- "waf-regional": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{
- Hostname: "waf-regional.af-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "af-south-1",
- },
- },
- "ap-east-1": endpoint{
- Hostname: "waf-regional.ap-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-east-1",
- },
- },
- "ap-northeast-1": endpoint{
- Hostname: "waf-regional.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "ap-northeast-2": endpoint{
- Hostname: "waf-regional.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "ap-south-1": endpoint{
- Hostname: "waf-regional.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "ap-southeast-1": endpoint{
- Hostname: "waf-regional.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "ap-southeast-2": endpoint{
- Hostname: "waf-regional.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "ca-central-1": endpoint{
- Hostname: "waf-regional.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "eu-central-1": endpoint{
- Hostname: "waf-regional.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "eu-north-1": endpoint{
- Hostname: "waf-regional.eu-north-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-north-1",
- },
- },
- "eu-south-1": endpoint{
- Hostname: "waf-regional.eu-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-south-1",
- },
- },
- "eu-west-1": endpoint{
- Hostname: "waf-regional.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "eu-west-2": endpoint{
- Hostname: "waf-regional.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "eu-west-3": endpoint{
- Hostname: "waf-regional.eu-west-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "fips-af-south-1": endpoint{
- Hostname: "waf-regional-fips.af-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "af-south-1",
- },
- },
- "fips-ap-east-1": endpoint{
- Hostname: "waf-regional-fips.ap-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-east-1",
- },
- },
- "fips-ap-northeast-1": endpoint{
- Hostname: "waf-regional-fips.ap-northeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-1",
- },
- },
- "fips-ap-northeast-2": endpoint{
- Hostname: "waf-regional-fips.ap-northeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-northeast-2",
- },
- },
- "fips-ap-south-1": endpoint{
- Hostname: "waf-regional-fips.ap-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-south-1",
- },
- },
- "fips-ap-southeast-1": endpoint{
- Hostname: "waf-regional-fips.ap-southeast-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-1",
- },
- },
- "fips-ap-southeast-2": endpoint{
- Hostname: "waf-regional-fips.ap-southeast-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ap-southeast-2",
- },
- },
- "fips-ca-central-1": endpoint{
- Hostname: "waf-regional-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "ca-central-1",
- },
- },
- "fips-eu-central-1": endpoint{
- Hostname: "waf-regional-fips.eu-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-central-1",
- },
- },
- "fips-eu-north-1": endpoint{
- Hostname: "waf-regional-fips.eu-north-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-north-1",
- },
- },
- "fips-eu-south-1": endpoint{
- Hostname: "waf-regional-fips.eu-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-south-1",
- },
- },
- "fips-eu-west-1": endpoint{
- Hostname: "waf-regional-fips.eu-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-1",
- },
- },
- "fips-eu-west-2": endpoint{
- Hostname: "waf-regional-fips.eu-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-2",
- },
- },
- "fips-eu-west-3": endpoint{
- Hostname: "waf-regional-fips.eu-west-3.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "eu-west-3",
- },
- },
- "fips-me-south-1": endpoint{
- Hostname: "waf-regional-fips.me-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "me-south-1",
- },
- },
- "fips-sa-east-1": endpoint{
- Hostname: "waf-regional-fips.sa-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "sa-east-1",
- },
- },
- "fips-us-east-1": endpoint{
- Hostname: "waf-regional-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-east-2": endpoint{
- Hostname: "waf-regional-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "fips-us-west-1": endpoint{
- Hostname: "waf-regional-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "waf-regional-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "me-south-1": endpoint{
- Hostname: "waf-regional.me-south-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "me-south-1",
- },
- },
- "sa-east-1": endpoint{
- Hostname: "waf-regional.sa-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "sa-east-1",
- },
- },
- "us-east-1": endpoint{
- Hostname: "waf-regional.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "us-east-2": endpoint{
- Hostname: "waf-regional.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-2",
- },
- },
- "us-west-1": endpoint{
- Hostname: "waf-regional.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-1",
- },
- },
- "us-west-2": endpoint{
- Hostname: "waf-regional.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- },
- },
- "workdocs": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "eu-west-1": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "workdocs-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "workdocs-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "workmail": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "eu-west-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "workspaces": service{
-
- Endpoints: endpoints{
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "fips-us-east-1": endpoint{
- Hostname: "workspaces-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-east-1",
- },
- },
- "fips-us-west-2": endpoint{
- Hostname: "workspaces-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-west-2",
- },
- },
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- "xray": service{
-
- Endpoints: endpoints{
- "af-south-1": endpoint{},
- "ap-east-1": endpoint{},
- "ap-northeast-1": endpoint{},
- "ap-northeast-2": endpoint{},
- "ap-south-1": endpoint{},
- "ap-southeast-1": endpoint{},
- "ap-southeast-2": endpoint{},
- "ca-central-1": endpoint{},
- "eu-central-1": endpoint{},
- "eu-north-1": endpoint{},
- "eu-south-1": endpoint{},
- "eu-west-1": endpoint{},
- "eu-west-2": endpoint{},
- "eu-west-3": endpoint{},
- "me-south-1": endpoint{},
- "sa-east-1": endpoint{},
- "us-east-1": endpoint{},
- "us-east-2": endpoint{},
- "us-west-1": endpoint{},
- "us-west-2": endpoint{},
- },
- },
- },
-}
-
-// AwsCnPartition returns the Resolver for AWS China.
-func AwsCnPartition() Partition {
- return awscnPartition.Partition()
-}
-
-var awscnPartition = partition{
- ID: "aws-cn",
- Name: "AWS China",
- DNSSuffix: "amazonaws.com.cn",
- RegionRegex: regionRegex{
- Regexp: func() *regexp.Regexp {
- reg, _ := regexp.Compile("^cn\\-\\w+\\-\\d+$")
- return reg
- }(),
- },
- Defaults: endpoint{
- Hostname: "{service}.{region}.{dnsSuffix}",
- Protocols: []string{"https"},
- SignatureVersions: []string{"v4"},
- },
- Regions: regions{
- "cn-north-1": region{
- Description: "China (Beijing)",
- },
- "cn-northwest-1": region{
- Description: "China (Ningxia)",
- },
- },
- Services: services{
- "access-analyzer": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "acm": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "api.ecr": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{
- Hostname: "api.ecr.cn-north-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-north-1",
- },
- },
- "cn-northwest-1": endpoint{
- Hostname: "api.ecr.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "api.sagemaker": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "apigateway": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "application-autoscaling": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "appsync": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- },
- },
- "athena": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "autoscaling": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "autoscaling-plans": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "backup": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "batch": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "budgets": service{
- PartitionEndpoint: "aws-cn-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-cn-global": endpoint{
- Hostname: "budgets.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "ce": service{
- PartitionEndpoint: "aws-cn-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-cn-global": endpoint{
- Hostname: "ce.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "cloudformation": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "cloudfront": service{
- PartitionEndpoint: "aws-cn-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-cn-global": endpoint{
- Hostname: "cloudfront.cn-northwest-1.amazonaws.com.cn",
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "cloudtrail": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "codebuild": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "codecommit": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "codedeploy": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "cognito-identity": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- },
- },
- "config": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "cur": service{
-
- Endpoints: endpoints{
- "cn-northwest-1": endpoint{},
- },
- },
- "dax": service{
-
- Endpoints: endpoints{
- "cn-northwest-1": endpoint{},
- },
- },
- "directconnect": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "dms": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "ds": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "dynamodb": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "ebs": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "ec2": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "ec2metadata": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "169.254.169.254/latest",
- Protocols: []string{"http"},
- },
- },
- },
- "ecs": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "eks": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "elasticache": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "elasticbeanstalk": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "elasticfilesystem": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- "fips-cn-north-1": endpoint{
- Hostname: "elasticfilesystem-fips.cn-north-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-north-1",
- },
- },
- "fips-cn-northwest-1": endpoint{
- Hostname: "elasticfilesystem-fips.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "elasticloadbalancing": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "elasticmapreduce": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "es": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "events": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "firehose": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "fsx": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "gamelift": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- },
- },
- "glacier": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "glue": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "greengrass": service{
- IsRegionalized: boxedTrue,
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- },
- },
- "health": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "iam": service{
- PartitionEndpoint: "aws-cn-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-cn-global": endpoint{
- Hostname: "iam.cn-north-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-north-1",
- },
- },
- },
- },
- "iot": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "iotanalytics": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- },
- },
- "iotevents": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- },
- },
- "ioteventsdata": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{
- Hostname: "data.iotevents.cn-north-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-north-1",
- },
- },
- },
- },
- "iotsecuredtunneling": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "kafka": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "kinesis": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "kinesisanalytics": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "kms": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "lakeformation": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- },
- },
- "lambda": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "license-manager": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "logs": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "mediaconvert": service{
-
- Endpoints: endpoints{
- "cn-northwest-1": endpoint{
- Hostname: "subscribe.mediaconvert.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "monitoring": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "neptune": service{
-
- Endpoints: endpoints{
- "cn-northwest-1": endpoint{
- Hostname: "rds.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "organizations": service{
- PartitionEndpoint: "aws-cn-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-cn-global": endpoint{
- Hostname: "organizations.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- "fips-aws-cn-global": endpoint{
- Hostname: "organizations.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "polly": service{
-
- Endpoints: endpoints{
- "cn-northwest-1": endpoint{},
- },
- },
- "rds": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "redshift": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "resource-groups": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "route53": service{
- PartitionEndpoint: "aws-cn-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-cn-global": endpoint{
- Hostname: "route53.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "runtime.sagemaker": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "s3": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- SignatureVersions: []string{"s3v4"},
-
- HasDualStack: boxedTrue,
- DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}",
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "s3-control": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- SignatureVersions: []string{"s3v4"},
-
- HasDualStack: boxedTrue,
- DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}",
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{
- Hostname: "s3-control.cn-north-1.amazonaws.com.cn",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "cn-north-1",
- },
- },
- "cn-northwest-1": endpoint{
- Hostname: "s3-control.cn-northwest-1.amazonaws.com.cn",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "secretsmanager": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "securityhub": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "serverlessrepo": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{
- Protocols: []string{"https"},
- },
- "cn-northwest-1": endpoint{
- Protocols: []string{"https"},
- },
- },
- },
- "servicediscovery": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "sms": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "snowball": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- "fips-cn-north-1": endpoint{
- Hostname: "snowball-fips.cn-north-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-north-1",
- },
- },
- "fips-cn-northwest-1": endpoint{
- Hostname: "snowball-fips.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "sns": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "sqs": service{
- Defaults: endpoint{
- SSLCommonName: "{region}.queue.{dnsSuffix}",
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "ssm": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "states": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "storagegateway": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "streams.dynamodb": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Service: "dynamodb",
- },
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "sts": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "support": service{
- PartitionEndpoint: "aws-cn-global",
-
- Endpoints: endpoints{
- "aws-cn-global": endpoint{
- Hostname: "support.cn-north-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-north-1",
- },
- },
- },
- },
- "swf": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "tagging": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- "transcribe": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "cn-north-1": endpoint{
- Hostname: "cn.transcribe.cn-north-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-north-1",
- },
- },
- "cn-northwest-1": endpoint{
- Hostname: "cn.transcribe.cn-northwest-1.amazonaws.com.cn",
- CredentialScope: credentialScope{
- Region: "cn-northwest-1",
- },
- },
- },
- },
- "workspaces": service{
-
- Endpoints: endpoints{
- "cn-northwest-1": endpoint{},
- },
- },
- "xray": service{
-
- Endpoints: endpoints{
- "cn-north-1": endpoint{},
- "cn-northwest-1": endpoint{},
- },
- },
- },
-}
-
-// AwsUsGovPartition returns the Resolver for AWS GovCloud (US).
-func AwsUsGovPartition() Partition {
- return awsusgovPartition.Partition()
-}
-
-var awsusgovPartition = partition{
- ID: "aws-us-gov",
- Name: "AWS GovCloud (US)",
- DNSSuffix: "amazonaws.com",
- RegionRegex: regionRegex{
- Regexp: func() *regexp.Regexp {
- reg, _ := regexp.Compile("^us\\-gov\\-\\w+\\-\\d+$")
- return reg
- }(),
- },
- Defaults: endpoint{
- Hostname: "{service}.{region}.{dnsSuffix}",
- Protocols: []string{"https"},
- SignatureVersions: []string{"v4"},
- },
- Regions: regions{
- "us-gov-east-1": region{
- Description: "AWS GovCloud (US-East)",
- },
- "us-gov-west-1": region{
- Description: "AWS GovCloud (US-West)",
- },
- },
- Services: services{
- "access-analyzer": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "access-analyzer.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "access-analyzer.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "acm": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "acm.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "acm.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "acm-pca": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "acm-pca.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "acm-pca.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "api.ecr": service{
-
- Endpoints: endpoints{
- "fips-dkr-us-gov-east-1": endpoint{
- Hostname: "ecr-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-dkr-us-gov-west-1": endpoint{
- Hostname: "ecr-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "fips-us-gov-east-1": endpoint{
- Hostname: "ecr-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "ecr-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{
- Hostname: "api.ecr.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "api.ecr.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "api.sagemaker": service{
-
- Endpoints: endpoints{
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "api-fips.sagemaker.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1-fips-secondary": endpoint{
- Hostname: "api.sagemaker.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "apigateway": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "application-autoscaling": service{
- Defaults: endpoint{
- Hostname: "autoscaling.{region}.amazonaws.com",
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Service: "application-autoscaling",
- },
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- "us-gov-west-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "appstream2": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- CredentialScope: credentialScope{
- Service: "appstream",
- },
- },
- Endpoints: endpoints{
- "fips": endpoint{
- Hostname: "appstream2-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "athena": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "athena-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "athena-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "autoscaling": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- "us-gov-west-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "autoscaling-plans": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- "us-gov-west-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "backup": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "batch": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "batch.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "batch.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "clouddirectory": service{
-
- Endpoints: endpoints{
- "us-gov-west-1": endpoint{},
- },
- },
- "cloudformation": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "cloudformation.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "cloudformation.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "cloudhsm": service{
-
- Endpoints: endpoints{
- "us-gov-west-1": endpoint{},
- },
- },
- "cloudhsmv2": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "cloudhsm",
- },
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "cloudtrail": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "cloudtrail.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "cloudtrail.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "codebuild": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-east-1-fips": endpoint{
- Hostname: "codebuild-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "codebuild-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "codecommit": service{
-
- Endpoints: endpoints{
- "fips": endpoint{
- Hostname: "codecommit-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "codedeploy": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-east-1-fips": endpoint{
- Hostname: "codedeploy-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "codedeploy-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "codepipeline": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "codepipeline-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "cognito-identity": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "cognito-identity-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "cognito-idp": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "cognito-idp-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "comprehend": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "comprehend-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "comprehendmedical": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "comprehendmedical-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "config": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "datasync": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "datasync-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "datasync-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "directconnect": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "directconnect.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "directconnect.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "dms": service{
-
- Endpoints: endpoints{
- "dms-fips": endpoint{
- Hostname: "dms.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "docdb": service{
-
- Endpoints: endpoints{
- "us-gov-west-1": endpoint{
- Hostname: "rds.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "ds": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "ds-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "ds-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "dynamodb": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-east-1-fips": endpoint{
- Hostname: "dynamodb.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "dynamodb.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "ebs": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "ec2": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "ec2.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "ec2.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "ec2metadata": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "169.254.169.254/latest",
- Protocols: []string{"http"},
- },
- },
- },
- "ecs": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "ecs-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "ecs-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "eks": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "eks.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "eks.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "elasticache": service{
-
- Endpoints: endpoints{
- "fips": endpoint{
- Hostname: "elasticache.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "elasticbeanstalk": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "elasticbeanstalk.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "elasticbeanstalk.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "elasticfilesystem": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "elasticfilesystem-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "elasticfilesystem-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "elasticloadbalancing": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "elasticloadbalancing.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "elasticloadbalancing.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "elasticmapreduce": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "elasticmapreduce.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "elasticmapreduce.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{
- Protocols: []string{"https"},
- },
- },
- },
- "email": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "email-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "es": service{
-
- Endpoints: endpoints{
- "fips": endpoint{
- Hostname: "es-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "events": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "events.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "events.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "firehose": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "firehose-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "firehose-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "glacier": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "glacier.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "glacier.us-gov-west-1.amazonaws.com",
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "glue": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "glue-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "glue-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "greengrass": service{
- IsRegionalized: boxedTrue,
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "dataplane-us-gov-west-1": endpoint{
- Hostname: "greengrass-ats.iot.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "greengrass.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "guardduty": service{
- IsRegionalized: boxedTrue,
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "guardduty.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "health": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "health-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "iam": service{
- PartitionEndpoint: "aws-us-gov-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-us-gov-global": endpoint{
- Hostname: "iam.us-gov.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "iam-govcloud-fips": endpoint{
- Hostname: "iam.us-gov.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "inspector": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "inspector-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "inspector-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "iot": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "iotsecuredtunneling": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "kafka": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "kinesis": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "kinesis.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "kinesis.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "kinesisanalytics": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "kms": service{
-
- Endpoints: endpoints{
- "ProdFips": endpoint{
- Hostname: "kms-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "lambda": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "lambda-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "lambda-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "license-manager": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "license-manager-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "license-manager-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "logs": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "logs.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "logs.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "mediaconvert": service{
-
- Endpoints: endpoints{
- "us-gov-west-1": endpoint{
- Hostname: "mediaconvert.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "metering.marketplace": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "aws-marketplace",
- },
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "monitoring": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "monitoring.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "monitoring.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "neptune": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "rds.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "rds.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "organizations": service{
- PartitionEndpoint: "aws-us-gov-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-us-gov-global": endpoint{
- Hostname: "organizations.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "fips-aws-us-gov-global": endpoint{
- Hostname: "organizations.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "outposts": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "outposts.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "outposts.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "pinpoint": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "mobiletargeting",
- },
- },
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "pinpoint-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "pinpoint.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "polly": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "polly-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "ram": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "rds": service{
-
- Endpoints: endpoints{
- "rds.us-gov-east-1": endpoint{
- Hostname: "rds.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "rds.us-gov-west-1": endpoint{
- Hostname: "rds.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "redshift": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "redshift.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "redshift.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "rekognition": service{
-
- Endpoints: endpoints{
- "rekognition-fips.us-gov-west-1": endpoint{
- Hostname: "rekognition-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "resource-groups": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "resource-groups.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "resource-groups.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "route53": service{
- PartitionEndpoint: "aws-us-gov-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-us-gov-global": endpoint{
- Hostname: "route53.us-gov.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "fips-aws-us-gov-global": endpoint{
- Hostname: "route53.us-gov.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "route53resolver": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "runtime.sagemaker": service{
-
- Endpoints: endpoints{
- "us-gov-west-1": endpoint{},
- },
- },
- "s3": service{
- Defaults: endpoint{
- SignatureVersions: []string{"s3", "s3v4"},
-
- HasDualStack: boxedTrue,
- DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}",
- },
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "s3-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{
- Hostname: "s3.us-gov-east-1.amazonaws.com",
- Protocols: []string{"http", "https"},
- },
- "us-gov-west-1": endpoint{
- Hostname: "s3.us-gov-west-1.amazonaws.com",
- Protocols: []string{"http", "https"},
- },
- },
- },
- "s3-control": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- SignatureVersions: []string{"s3v4"},
-
- HasDualStack: boxedTrue,
- DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}",
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "s3-control.us-gov-east-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-east-1-fips": endpoint{
- Hostname: "s3-control-fips.us-gov-east-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "s3-control.us-gov-west-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1-fips": endpoint{
- Hostname: "s3-control-fips.us-gov-west-1.amazonaws.com",
- SignatureVersions: []string{"s3v4"},
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "secretsmanager": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-east-1-fips": endpoint{
- Hostname: "secretsmanager-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "secretsmanager-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "securityhub": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "securityhub-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "securityhub-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "serverlessrepo": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "serverlessrepo.us-gov-east-1.amazonaws.com",
- Protocols: []string{"https"},
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "serverlessrepo.us-gov-west-1.amazonaws.com",
- Protocols: []string{"https"},
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "servicecatalog": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-east-1-fips": endpoint{
- Hostname: "servicecatalog-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "servicecatalog-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "sms": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "sms-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "sms-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "snowball": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "snowball-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "snowball-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "sns": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "sns.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "sns.us-gov-west-1.amazonaws.com",
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "sqs": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "sqs.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "sqs.us-gov-west-1.amazonaws.com",
- SSLCommonName: "{region}.queue.{dnsSuffix}",
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "ssm": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "ssm.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "ssm.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "states": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "states-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "states.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "storagegateway": service{
-
- Endpoints: endpoints{
- "fips": endpoint{
- Hostname: "storagegateway-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "streams.dynamodb": service{
- Defaults: endpoint{
- CredentialScope: credentialScope{
- Service: "dynamodb",
- },
- },
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-east-1-fips": endpoint{
- Hostname: "dynamodb.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "dynamodb.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "sts": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-east-1-fips": endpoint{
- Hostname: "sts.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "sts.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "support": service{
- PartitionEndpoint: "aws-us-gov-global",
-
- Endpoints: endpoints{
- "aws-us-gov-global": endpoint{
- Hostname: "support.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "support.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "swf": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{
- Hostname: "swf.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "swf.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "tagging": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "transcribe": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "fips.transcribe.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "fips.transcribe.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "transfer": service{
-
- Endpoints: endpoints{
- "fips-us-gov-east-1": endpoint{
- Hostname: "transfer-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-east-1",
- },
- },
- "fips-us-gov-west-1": endpoint{
- Hostname: "transfer-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- "translate": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "us-gov-west-1": endpoint{},
- "us-gov-west-1-fips": endpoint{
- Hostname: "translate-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "waf-regional": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "waf-regional-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{
- Hostname: "waf-regional.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- },
- },
- "workspaces": service{
-
- Endpoints: endpoints{
- "fips-us-gov-west-1": endpoint{
- Hostname: "workspaces-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Region: "us-gov-west-1",
- },
- },
- "us-gov-west-1": endpoint{},
- },
- },
- "xray": service{
-
- Endpoints: endpoints{
- "us-gov-east-1": endpoint{},
- "us-gov-west-1": endpoint{},
- },
- },
- },
-}
-
-// AwsIsoPartition returns the Resolver for AWS ISO (US).
-func AwsIsoPartition() Partition {
- return awsisoPartition.Partition()
-}
-
-var awsisoPartition = partition{
- ID: "aws-iso",
- Name: "AWS ISO (US)",
- DNSSuffix: "c2s.ic.gov",
- RegionRegex: regionRegex{
- Regexp: func() *regexp.Regexp {
- reg, _ := regexp.Compile("^us\\-iso\\-\\w+\\-\\d+$")
- return reg
- }(),
- },
- Defaults: endpoint{
- Hostname: "{service}.{region}.{dnsSuffix}",
- Protocols: []string{"https"},
- SignatureVersions: []string{"v4"},
- },
- Regions: regions{
- "us-iso-east-1": region{
- Description: "US ISO East",
- },
- },
- Services: services{
- "api.ecr": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Hostname: "api.ecr.us-iso-east-1.c2s.ic.gov",
- CredentialScope: credentialScope{
- Region: "us-iso-east-1",
- },
- },
- },
- },
- "api.sagemaker": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "apigateway": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "application-autoscaling": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "autoscaling": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "cloudformation": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "cloudtrail": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "codedeploy": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "comprehend": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "config": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "datapipeline": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "directconnect": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "dms": service{
-
- Endpoints: endpoints{
- "dms-fips": endpoint{
- Hostname: "dms.us-iso-east-1.c2s.ic.gov",
- CredentialScope: credentialScope{
- Region: "us-iso-east-1",
- },
- },
- "us-iso-east-1": endpoint{},
- },
- },
- "ds": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "dynamodb": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "ec2": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "ec2metadata": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "169.254.169.254/latest",
- Protocols: []string{"http"},
- },
- },
- },
- "ecs": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "elasticache": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "elasticloadbalancing": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "elasticmapreduce": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"https"},
- },
- },
- },
- "es": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "events": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "glacier": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "health": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "iam": service{
- PartitionEndpoint: "aws-iso-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-iso-global": endpoint{
- Hostname: "iam.us-iso-east-1.c2s.ic.gov",
- CredentialScope: credentialScope{
- Region: "us-iso-east-1",
- },
- },
- },
- },
- "kinesis": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "kms": service{
-
- Endpoints: endpoints{
- "ProdFips": endpoint{
- Hostname: "kms-fips.us-iso-east-1.c2s.ic.gov",
- CredentialScope: credentialScope{
- Region: "us-iso-east-1",
- },
- },
- "us-iso-east-1": endpoint{},
- },
- },
- "lambda": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "logs": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "monitoring": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "rds": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "redshift": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "route53": service{
- PartitionEndpoint: "aws-iso-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-iso-global": endpoint{
- Hostname: "route53.c2s.ic.gov",
- CredentialScope: credentialScope{
- Region: "us-iso-east-1",
- },
- },
- },
- },
- "runtime.sagemaker": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "s3": service{
- Defaults: endpoint{
- SignatureVersions: []string{"s3v4"},
- },
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"http", "https"},
- SignatureVersions: []string{"s3v4"},
- },
- },
- },
- "snowball": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "sns": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "sqs": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "states": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "streams.dynamodb": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Service: "dynamodb",
- },
- },
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{
- Protocols: []string{"http", "https"},
- },
- },
- },
- "sts": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "support": service{
- PartitionEndpoint: "aws-iso-global",
-
- Endpoints: endpoints{
- "aws-iso-global": endpoint{
- Hostname: "support.us-iso-east-1.c2s.ic.gov",
- CredentialScope: credentialScope{
- Region: "us-iso-east-1",
- },
- },
- },
- },
- "swf": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "transcribe": service{
- Defaults: endpoint{
- Protocols: []string{"https"},
- },
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "transcribestreaming": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- "workspaces": service{
-
- Endpoints: endpoints{
- "us-iso-east-1": endpoint{},
- },
- },
- },
-}
-
-// AwsIsoBPartition returns the Resolver for AWS ISOB (US).
-func AwsIsoBPartition() Partition {
- return awsisobPartition.Partition()
-}
-
-var awsisobPartition = partition{
- ID: "aws-iso-b",
- Name: "AWS ISOB (US)",
- DNSSuffix: "sc2s.sgov.gov",
- RegionRegex: regionRegex{
- Regexp: func() *regexp.Regexp {
- reg, _ := regexp.Compile("^us\\-isob\\-\\w+\\-\\d+$")
- return reg
- }(),
- },
- Defaults: endpoint{
- Hostname: "{service}.{region}.{dnsSuffix}",
- Protocols: []string{"https"},
- SignatureVersions: []string{"v4"},
- },
- Regions: regions{
- "us-isob-east-1": region{
- Description: "US ISOB East (Ohio)",
- },
- },
- Services: services{
- "api.ecr": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{
- Hostname: "api.ecr.us-isob-east-1.sc2s.sgov.gov",
- CredentialScope: credentialScope{
- Region: "us-isob-east-1",
- },
- },
- },
- },
- "application-autoscaling": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "autoscaling": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "cloudformation": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "cloudtrail": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "config": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "directconnect": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "dms": service{
-
- Endpoints: endpoints{
- "dms-fips": endpoint{
- Hostname: "dms.us-isob-east-1.sc2s.sgov.gov",
- CredentialScope: credentialScope{
- Region: "us-isob-east-1",
- },
- },
- "us-isob-east-1": endpoint{},
- },
- },
- "dynamodb": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "ec2": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "ec2metadata": service{
- PartitionEndpoint: "aws-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-global": endpoint{
- Hostname: "169.254.169.254/latest",
- Protocols: []string{"http"},
- },
- },
- },
- "ecs": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "elasticache": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "elasticloadbalancing": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{
- Protocols: []string{"https"},
- },
- },
- },
- "elasticmapreduce": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "events": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "glacier": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "health": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "iam": service{
- PartitionEndpoint: "aws-iso-b-global",
- IsRegionalized: boxedFalse,
-
- Endpoints: endpoints{
- "aws-iso-b-global": endpoint{
- Hostname: "iam.us-isob-east-1.sc2s.sgov.gov",
- CredentialScope: credentialScope{
- Region: "us-isob-east-1",
- },
- },
- },
- },
- "kinesis": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "kms": service{
-
- Endpoints: endpoints{
- "ProdFips": endpoint{
- Hostname: "kms-fips.us-isob-east-1.sc2s.sgov.gov",
- CredentialScope: credentialScope{
- Region: "us-isob-east-1",
- },
- },
- "us-isob-east-1": endpoint{},
- },
- },
- "lambda": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "license-manager": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "logs": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "monitoring": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "rds": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "redshift": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "s3": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- SignatureVersions: []string{"s3v4"},
- },
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "snowball": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "sns": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "sqs": service{
- Defaults: endpoint{
- SSLCommonName: "{region}.queue.{dnsSuffix}",
- Protocols: []string{"http", "https"},
- },
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "ssm": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "states": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "streams.dynamodb": service{
- Defaults: endpoint{
- Protocols: []string{"http", "https"},
- CredentialScope: credentialScope{
- Service: "dynamodb",
- },
- },
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "sts": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- "support": service{
- PartitionEndpoint: "aws-iso-b-global",
-
- Endpoints: endpoints{
- "aws-iso-b-global": endpoint{
- Hostname: "support.us-isob-east-1.sc2s.sgov.gov",
- CredentialScope: credentialScope{
- Region: "us-isob-east-1",
- },
- },
- },
- },
- "swf": service{
-
- Endpoints: endpoints{
- "us-isob-east-1": endpoint{},
- },
- },
- },
-}
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
deleted file mode 100644
index ca8fc828e159..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go
+++ /dev/null
@@ -1,141 +0,0 @@
-package endpoints
-
-// Service identifiers
-//
-// Deprecated: Use client package's EndpointsID value instead of these
-// ServiceIDs. These IDs are not maintained, and are out of date.
-const (
- A4bServiceID = "a4b" // A4b.
- AcmServiceID = "acm" // Acm.
- AcmPcaServiceID = "acm-pca" // AcmPca.
- ApiMediatailorServiceID = "api.mediatailor" // ApiMediatailor.
- ApiPricingServiceID = "api.pricing" // ApiPricing.
- ApiSagemakerServiceID = "api.sagemaker" // ApiSagemaker.
- ApigatewayServiceID = "apigateway" // Apigateway.
- ApplicationAutoscalingServiceID = "application-autoscaling" // ApplicationAutoscaling.
- Appstream2ServiceID = "appstream2" // Appstream2.
- AppsyncServiceID = "appsync" // Appsync.
- AthenaServiceID = "athena" // Athena.
- AutoscalingServiceID = "autoscaling" // Autoscaling.
- AutoscalingPlansServiceID = "autoscaling-plans" // AutoscalingPlans.
- BatchServiceID = "batch" // Batch.
- BudgetsServiceID = "budgets" // Budgets.
- CeServiceID = "ce" // Ce.
- ChimeServiceID = "chime" // Chime.
- Cloud9ServiceID = "cloud9" // Cloud9.
- ClouddirectoryServiceID = "clouddirectory" // Clouddirectory.
- CloudformationServiceID = "cloudformation" // Cloudformation.
- CloudfrontServiceID = "cloudfront" // Cloudfront.
- CloudhsmServiceID = "cloudhsm" // Cloudhsm.
- Cloudhsmv2ServiceID = "cloudhsmv2" // Cloudhsmv2.
- CloudsearchServiceID = "cloudsearch" // Cloudsearch.
- CloudtrailServiceID = "cloudtrail" // Cloudtrail.
- CodebuildServiceID = "codebuild" // Codebuild.
- CodecommitServiceID = "codecommit" // Codecommit.
- CodedeployServiceID = "codedeploy" // Codedeploy.
- CodepipelineServiceID = "codepipeline" // Codepipeline.
- CodestarServiceID = "codestar" // Codestar.
- CognitoIdentityServiceID = "cognito-identity" // CognitoIdentity.
- CognitoIdpServiceID = "cognito-idp" // CognitoIdp.
- CognitoSyncServiceID = "cognito-sync" // CognitoSync.
- ComprehendServiceID = "comprehend" // Comprehend.
- ConfigServiceID = "config" // Config.
- CurServiceID = "cur" // Cur.
- DatapipelineServiceID = "datapipeline" // Datapipeline.
- DaxServiceID = "dax" // Dax.
- DevicefarmServiceID = "devicefarm" // Devicefarm.
- DirectconnectServiceID = "directconnect" // Directconnect.
- DiscoveryServiceID = "discovery" // Discovery.
- DmsServiceID = "dms" // Dms.
- DsServiceID = "ds" // Ds.
- DynamodbServiceID = "dynamodb" // Dynamodb.
- Ec2ServiceID = "ec2" // Ec2.
- Ec2metadataServiceID = "ec2metadata" // Ec2metadata.
- EcrServiceID = "ecr" // Ecr.
- EcsServiceID = "ecs" // Ecs.
- ElasticacheServiceID = "elasticache" // Elasticache.
- ElasticbeanstalkServiceID = "elasticbeanstalk" // Elasticbeanstalk.
- ElasticfilesystemServiceID = "elasticfilesystem" // Elasticfilesystem.
- ElasticloadbalancingServiceID = "elasticloadbalancing" // Elasticloadbalancing.
- ElasticmapreduceServiceID = "elasticmapreduce" // Elasticmapreduce.
- ElastictranscoderServiceID = "elastictranscoder" // Elastictranscoder.
- EmailServiceID = "email" // Email.
- EntitlementMarketplaceServiceID = "entitlement.marketplace" // EntitlementMarketplace.
- EsServiceID = "es" // Es.
- EventsServiceID = "events" // Events.
- FirehoseServiceID = "firehose" // Firehose.
- FmsServiceID = "fms" // Fms.
- GameliftServiceID = "gamelift" // Gamelift.
- GlacierServiceID = "glacier" // Glacier.
- GlueServiceID = "glue" // Glue.
- GreengrassServiceID = "greengrass" // Greengrass.
- GuarddutyServiceID = "guardduty" // Guardduty.
- HealthServiceID = "health" // Health.
- IamServiceID = "iam" // Iam.
- ImportexportServiceID = "importexport" // Importexport.
- InspectorServiceID = "inspector" // Inspector.
- IotServiceID = "iot" // Iot.
- IotanalyticsServiceID = "iotanalytics" // Iotanalytics.
- KinesisServiceID = "kinesis" // Kinesis.
- KinesisanalyticsServiceID = "kinesisanalytics" // Kinesisanalytics.
- KinesisvideoServiceID = "kinesisvideo" // Kinesisvideo.
- KmsServiceID = "kms" // Kms.
- LambdaServiceID = "lambda" // Lambda.
- LightsailServiceID = "lightsail" // Lightsail.
- LogsServiceID = "logs" // Logs.
- MachinelearningServiceID = "machinelearning" // Machinelearning.
- MarketplacecommerceanalyticsServiceID = "marketplacecommerceanalytics" // Marketplacecommerceanalytics.
- MediaconvertServiceID = "mediaconvert" // Mediaconvert.
- MedialiveServiceID = "medialive" // Medialive.
- MediapackageServiceID = "mediapackage" // Mediapackage.
- MediastoreServiceID = "mediastore" // Mediastore.
- MeteringMarketplaceServiceID = "metering.marketplace" // MeteringMarketplace.
- MghServiceID = "mgh" // Mgh.
- MobileanalyticsServiceID = "mobileanalytics" // Mobileanalytics.
- ModelsLexServiceID = "models.lex" // ModelsLex.
- MonitoringServiceID = "monitoring" // Monitoring.
- MturkRequesterServiceID = "mturk-requester" // MturkRequester.
- NeptuneServiceID = "neptune" // Neptune.
- OpsworksServiceID = "opsworks" // Opsworks.
- OpsworksCmServiceID = "opsworks-cm" // OpsworksCm.
- OrganizationsServiceID = "organizations" // Organizations.
- PinpointServiceID = "pinpoint" // Pinpoint.
- PollyServiceID = "polly" // Polly.
- RdsServiceID = "rds" // Rds.
- RedshiftServiceID = "redshift" // Redshift.
- RekognitionServiceID = "rekognition" // Rekognition.
- ResourceGroupsServiceID = "resource-groups" // ResourceGroups.
- Route53ServiceID = "route53" // Route53.
- Route53domainsServiceID = "route53domains" // Route53domains.
- RuntimeLexServiceID = "runtime.lex" // RuntimeLex.
- RuntimeSagemakerServiceID = "runtime.sagemaker" // RuntimeSagemaker.
- S3ServiceID = "s3" // S3.
- S3ControlServiceID = "s3-control" // S3Control.
- SagemakerServiceID = "api.sagemaker" // Sagemaker.
- SdbServiceID = "sdb" // Sdb.
- SecretsmanagerServiceID = "secretsmanager" // Secretsmanager.
- ServerlessrepoServiceID = "serverlessrepo" // Serverlessrepo.
- ServicecatalogServiceID = "servicecatalog" // Servicecatalog.
- ServicediscoveryServiceID = "servicediscovery" // Servicediscovery.
- ShieldServiceID = "shield" // Shield.
- SmsServiceID = "sms" // Sms.
- SnowballServiceID = "snowball" // Snowball.
- SnsServiceID = "sns" // Sns.
- SqsServiceID = "sqs" // Sqs.
- SsmServiceID = "ssm" // Ssm.
- StatesServiceID = "states" // States.
- StoragegatewayServiceID = "storagegateway" // Storagegateway.
- StreamsDynamodbServiceID = "streams.dynamodb" // StreamsDynamodb.
- StsServiceID = "sts" // Sts.
- SupportServiceID = "support" // Support.
- SwfServiceID = "swf" // Swf.
- TaggingServiceID = "tagging" // Tagging.
- TransferServiceID = "transfer" // Transfer.
- TranslateServiceID = "translate" // Translate.
- WafServiceID = "waf" // Waf.
- WafRegionalServiceID = "waf-regional" // WafRegional.
- WorkdocsServiceID = "workdocs" // Workdocs.
- WorkmailServiceID = "workmail" // Workmail.
- WorkspacesServiceID = "workspaces" // Workspaces.
- XrayServiceID = "xray" // Xray.
-)
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/doc.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/doc.go
deleted file mode 100644
index 84316b92c053..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/doc.go
+++ /dev/null
@@ -1,66 +0,0 @@
-// Package endpoints provides the types and functionality for defining regions
-// and endpoints, as well as querying those definitions.
-//
-// The SDK's Regions and Endpoints metadata is code generated into the endpoints
-// package, and is accessible via the DefaultResolver function. This function
-// returns a endpoint Resolver will search the metadata and build an associated
-// endpoint if one is found. The default resolver will search all partitions
-// known by the SDK. e.g AWS Standard (aws), AWS China (aws-cn), and
-// AWS GovCloud (US) (aws-us-gov).
-// .
-//
-// Enumerating Regions and Endpoint Metadata
-//
-// Casting the Resolver returned by DefaultResolver to a EnumPartitions interface
-// will allow you to get access to the list of underlying Partitions with the
-// Partitions method. This is helpful if you want to limit the SDK's endpoint
-// resolving to a single partition, or enumerate regions, services, and endpoints
-// in the partition.
-//
-// resolver := endpoints.DefaultResolver()
-// partitions := resolver.(endpoints.EnumPartitions).Partitions()
-//
-// for _, p := range partitions {
-// fmt.Println("Regions for", p.ID())
-// for id, _ := range p.Regions() {
-// fmt.Println("*", id)
-// }
-//
-// fmt.Println("Services for", p.ID())
-// for id, _ := range p.Services() {
-// fmt.Println("*", id)
-// }
-// }
-//
-// Using Custom Endpoints
-//
-// The endpoints package also gives you the ability to use your own logic how
-// endpoints are resolved. This is a great way to define a custom endpoint
-// for select services, without passing that logic down through your code.
-//
-// If a type implements the Resolver interface it can be used to resolve
-// endpoints. To use this with the SDK's Session and Config set the value
-// of the type to the EndpointsResolver field of aws.Config when initializing
-// the session, or service client.
-//
-// In addition the ResolverFunc is a wrapper for a func matching the signature
-// of Resolver.EndpointFor, converting it to a type that satisfies the
-// Resolver interface.
-//
-//
-// myCustomResolver := func(service, region string, optFns ...func(*endpoints.Options)) (endpoints.ResolvedEndpoint, error) {
-// if service == endpoints.S3ServiceID {
-// return endpoints.ResolvedEndpoint{
-// URL: "s3.custom.endpoint.com",
-// SigningRegion: "custom-signing-region",
-// }, nil
-// }
-//
-// return endpoints.DefaultResolver().EndpointFor(service, region, optFns...)
-// }
-//
-// sess := session.Must(session.NewSession(&aws.Config{
-// Region: aws.String("us-west-2"),
-// EndpointResolver: endpoints.ResolverFunc(myCustomResolver),
-// }))
-package endpoints
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go
deleted file mode 100644
index ca956e5f12af..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go
+++ /dev/null
@@ -1,564 +0,0 @@
-package endpoints
-
-import (
- "fmt"
- "regexp"
- "strings"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-// Options provide the configuration needed to direct how the
-// endpoints will be resolved.
-type Options struct {
- // DisableSSL forces the endpoint to be resolved as HTTP.
- // instead of HTTPS if the service supports it.
- DisableSSL bool
-
- // Sets the resolver to resolve the endpoint as a dualstack endpoint
- // for the service. If dualstack support for a service is not known and
- // StrictMatching is not enabled a dualstack endpoint for the service will
- // be returned. This endpoint may not be valid. If StrictMatching is
- // enabled only services that are known to support dualstack will return
- // dualstack endpoints.
- UseDualStack bool
-
- // Enables strict matching of services and regions resolved endpoints.
- // If the partition doesn't enumerate the exact service and region an
- // error will be returned. This option will prevent returning endpoints
- // that look valid, but may not resolve to any real endpoint.
- StrictMatching bool
-
- // Enables resolving a service endpoint based on the region provided if the
- // service does not exist. The service endpoint ID will be used as the service
- // domain name prefix. By default the endpoint resolver requires the service
- // to be known when resolving endpoints.
- //
- // If resolving an endpoint on the partition list the provided region will
- // be used to determine which partition's domain name pattern to the service
- // endpoint ID with. If both the service and region are unknown and resolving
- // the endpoint on partition list an UnknownEndpointError error will be returned.
- //
- // If resolving and endpoint on a partition specific resolver that partition's
- // domain name pattern will be used with the service endpoint ID. If both
- // region and service do not exist when resolving an endpoint on a specific
- // partition the partition's domain pattern will be used to combine the
- // endpoint and region together.
- //
- // This option is ignored if StrictMatching is enabled.
- ResolveUnknownService bool
-
- // STS Regional Endpoint flag helps with resolving the STS endpoint
- STSRegionalEndpoint STSRegionalEndpoint
-
- // S3 Regional Endpoint flag helps with resolving the S3 endpoint
- S3UsEast1RegionalEndpoint S3UsEast1RegionalEndpoint
-}
-
-// STSRegionalEndpoint is an enum for the states of the STS Regional Endpoint
-// options.
-type STSRegionalEndpoint int
-
-func (e STSRegionalEndpoint) String() string {
- switch e {
- case LegacySTSEndpoint:
- return "legacy"
- case RegionalSTSEndpoint:
- return "regional"
- case UnsetSTSEndpoint:
- return ""
- default:
- return "unknown"
- }
-}
-
-const (
-
- // UnsetSTSEndpoint represents that STS Regional Endpoint flag is not specified.
- UnsetSTSEndpoint STSRegionalEndpoint = iota
-
- // LegacySTSEndpoint represents when STS Regional Endpoint flag is specified
- // to use legacy endpoints.
- LegacySTSEndpoint
-
- // RegionalSTSEndpoint represents when STS Regional Endpoint flag is specified
- // to use regional endpoints.
- RegionalSTSEndpoint
-)
-
-// GetSTSRegionalEndpoint function returns the STSRegionalEndpointFlag based
-// on the input string provided in env config or shared config by the user.
-//
-// `legacy`, `regional` are the only case-insensitive valid strings for
-// resolving the STS regional Endpoint flag.
-func GetSTSRegionalEndpoint(s string) (STSRegionalEndpoint, error) {
- switch {
- case strings.EqualFold(s, "legacy"):
- return LegacySTSEndpoint, nil
- case strings.EqualFold(s, "regional"):
- return RegionalSTSEndpoint, nil
- default:
- return UnsetSTSEndpoint, fmt.Errorf("unable to resolve the value of STSRegionalEndpoint for %v", s)
- }
-}
-
-// S3UsEast1RegionalEndpoint is an enum for the states of the S3 us-east-1
-// Regional Endpoint options.
-type S3UsEast1RegionalEndpoint int
-
-func (e S3UsEast1RegionalEndpoint) String() string {
- switch e {
- case LegacyS3UsEast1Endpoint:
- return "legacy"
- case RegionalS3UsEast1Endpoint:
- return "regional"
- case UnsetS3UsEast1Endpoint:
- return ""
- default:
- return "unknown"
- }
-}
-
-const (
-
- // UnsetS3UsEast1Endpoint represents that S3 Regional Endpoint flag is not
- // specified.
- UnsetS3UsEast1Endpoint S3UsEast1RegionalEndpoint = iota
-
- // LegacyS3UsEast1Endpoint represents when S3 Regional Endpoint flag is
- // specified to use legacy endpoints.
- LegacyS3UsEast1Endpoint
-
- // RegionalS3UsEast1Endpoint represents when S3 Regional Endpoint flag is
- // specified to use regional endpoints.
- RegionalS3UsEast1Endpoint
-)
-
-// GetS3UsEast1RegionalEndpoint function returns the S3UsEast1RegionalEndpointFlag based
-// on the input string provided in env config or shared config by the user.
-//
-// `legacy`, `regional` are the only case-insensitive valid strings for
-// resolving the S3 regional Endpoint flag.
-func GetS3UsEast1RegionalEndpoint(s string) (S3UsEast1RegionalEndpoint, error) {
- switch {
- case strings.EqualFold(s, "legacy"):
- return LegacyS3UsEast1Endpoint, nil
- case strings.EqualFold(s, "regional"):
- return RegionalS3UsEast1Endpoint, nil
- default:
- return UnsetS3UsEast1Endpoint,
- fmt.Errorf("unable to resolve the value of S3UsEast1RegionalEndpoint for %v", s)
- }
-}
-
-// Set combines all of the option functions together.
-func (o *Options) Set(optFns ...func(*Options)) {
- for _, fn := range optFns {
- fn(o)
- }
-}
-
-// DisableSSLOption sets the DisableSSL options. Can be used as a functional
-// option when resolving endpoints.
-func DisableSSLOption(o *Options) {
- o.DisableSSL = true
-}
-
-// UseDualStackOption sets the UseDualStack option. Can be used as a functional
-// option when resolving endpoints.
-func UseDualStackOption(o *Options) {
- o.UseDualStack = true
-}
-
-// StrictMatchingOption sets the StrictMatching option. Can be used as a functional
-// option when resolving endpoints.
-func StrictMatchingOption(o *Options) {
- o.StrictMatching = true
-}
-
-// ResolveUnknownServiceOption sets the ResolveUnknownService option. Can be used
-// as a functional option when resolving endpoints.
-func ResolveUnknownServiceOption(o *Options) {
- o.ResolveUnknownService = true
-}
-
-// STSRegionalEndpointOption enables the STS endpoint resolver behavior to resolve
-// STS endpoint to their regional endpoint, instead of the global endpoint.
-func STSRegionalEndpointOption(o *Options) {
- o.STSRegionalEndpoint = RegionalSTSEndpoint
-}
-
-// A Resolver provides the interface for functionality to resolve endpoints.
-// The build in Partition and DefaultResolver return value satisfy this interface.
-type Resolver interface {
- EndpointFor(service, region string, opts ...func(*Options)) (ResolvedEndpoint, error)
-}
-
-// ResolverFunc is a helper utility that wraps a function so it satisfies the
-// Resolver interface. This is useful when you want to add additional endpoint
-// resolving logic, or stub out specific endpoints with custom values.
-type ResolverFunc func(service, region string, opts ...func(*Options)) (ResolvedEndpoint, error)
-
-// EndpointFor wraps the ResolverFunc function to satisfy the Resolver interface.
-func (fn ResolverFunc) EndpointFor(service, region string, opts ...func(*Options)) (ResolvedEndpoint, error) {
- return fn(service, region, opts...)
-}
-
-var schemeRE = regexp.MustCompile("^([^:]+)://")
-
-// AddScheme adds the HTTP or HTTPS schemes to a endpoint URL if there is no
-// scheme. If disableSSL is true HTTP will set HTTP instead of the default HTTPS.
-//
-// If disableSSL is set, it will only set the URL's scheme if the URL does not
-// contain a scheme.
-func AddScheme(endpoint string, disableSSL bool) string {
- if !schemeRE.MatchString(endpoint) {
- scheme := "https"
- if disableSSL {
- scheme = "http"
- }
- endpoint = fmt.Sprintf("%s://%s", scheme, endpoint)
- }
-
- return endpoint
-}
-
-// EnumPartitions a provides a way to retrieve the underlying partitions that
-// make up the SDK's default Resolver, or any resolver decoded from a model
-// file.
-//
-// Use this interface with DefaultResolver and DecodeModels to get the list of
-// Partitions.
-type EnumPartitions interface {
- Partitions() []Partition
-}
-
-// RegionsForService returns a map of regions for the partition and service.
-// If either the partition or service does not exist false will be returned
-// as the second parameter.
-//
-// This example shows how to get the regions for DynamoDB in the AWS partition.
-// rs, exists := endpoints.RegionsForService(endpoints.DefaultPartitions(), endpoints.AwsPartitionID, endpoints.DynamodbServiceID)
-//
-// This is equivalent to using the partition directly.
-// rs := endpoints.AwsPartition().Services()[endpoints.DynamodbServiceID].Regions()
-func RegionsForService(ps []Partition, partitionID, serviceID string) (map[string]Region, bool) {
- for _, p := range ps {
- if p.ID() != partitionID {
- continue
- }
- if _, ok := p.p.Services[serviceID]; !ok {
- break
- }
-
- s := Service{
- id: serviceID,
- p: p.p,
- }
- return s.Regions(), true
- }
-
- return map[string]Region{}, false
-}
-
-// PartitionForRegion returns the first partition which includes the region
-// passed in. This includes both known regions and regions which match
-// a pattern supported by the partition which may include regions that are
-// not explicitly known by the partition. Use the Regions method of the
-// returned Partition if explicit support is needed.
-func PartitionForRegion(ps []Partition, regionID string) (Partition, bool) {
- for _, p := range ps {
- if _, ok := p.p.Regions[regionID]; ok || p.p.RegionRegex.MatchString(regionID) {
- return p, true
- }
- }
-
- return Partition{}, false
-}
-
-// A Partition provides the ability to enumerate the partition's regions
-// and services.
-type Partition struct {
- id, dnsSuffix string
- p *partition
-}
-
-// DNSSuffix returns the base domain name of the partition.
-func (p Partition) DNSSuffix() string { return p.dnsSuffix }
-
-// ID returns the identifier of the partition.
-func (p Partition) ID() string { return p.id }
-
-// EndpointFor attempts to resolve the endpoint based on service and region.
-// See Options for information on configuring how the endpoint is resolved.
-//
-// If the service cannot be found in the metadata the UnknownServiceError
-// error will be returned. This validation will occur regardless if
-// StrictMatching is enabled. To enable resolving unknown services set the
-// "ResolveUnknownService" option to true. When StrictMatching is disabled
-// this option allows the partition resolver to resolve a endpoint based on
-// the service endpoint ID provided.
-//
-// When resolving endpoints you can choose to enable StrictMatching. This will
-// require the provided service and region to be known by the partition.
-// If the endpoint cannot be strictly resolved an error will be returned. This
-// mode is useful to ensure the endpoint resolved is valid. Without
-// StrictMatching enabled the endpoint returned may look valid but may not work.
-// StrictMatching requires the SDK to be updated if you want to take advantage
-// of new regions and services expansions.
-//
-// Errors that can be returned.
-// * UnknownServiceError
-// * UnknownEndpointError
-func (p Partition) EndpointFor(service, region string, opts ...func(*Options)) (ResolvedEndpoint, error) {
- return p.p.EndpointFor(service, region, opts...)
-}
-
-// Regions returns a map of Regions indexed by their ID. This is useful for
-// enumerating over the regions in a partition.
-func (p Partition) Regions() map[string]Region {
- rs := make(map[string]Region, len(p.p.Regions))
- for id, r := range p.p.Regions {
- rs[id] = Region{
- id: id,
- desc: r.Description,
- p: p.p,
- }
- }
-
- return rs
-}
-
-// Services returns a map of Service indexed by their ID. This is useful for
-// enumerating over the services in a partition.
-func (p Partition) Services() map[string]Service {
- ss := make(map[string]Service, len(p.p.Services))
- for id := range p.p.Services {
- ss[id] = Service{
- id: id,
- p: p.p,
- }
- }
-
- return ss
-}
-
-// A Region provides information about a region, and ability to resolve an
-// endpoint from the context of a region, given a service.
-type Region struct {
- id, desc string
- p *partition
-}
-
-// ID returns the region's identifier.
-func (r Region) ID() string { return r.id }
-
-// Description returns the region's description. The region description
-// is free text, it can be empty, and it may change between SDK releases.
-func (r Region) Description() string { return r.desc }
-
-// ResolveEndpoint resolves an endpoint from the context of the region given
-// a service. See Partition.EndpointFor for usage and errors that can be returned.
-func (r Region) ResolveEndpoint(service string, opts ...func(*Options)) (ResolvedEndpoint, error) {
- return r.p.EndpointFor(service, r.id, opts...)
-}
-
-// Services returns a list of all services that are known to be in this region.
-func (r Region) Services() map[string]Service {
- ss := map[string]Service{}
- for id, s := range r.p.Services {
- if _, ok := s.Endpoints[r.id]; ok {
- ss[id] = Service{
- id: id,
- p: r.p,
- }
- }
- }
-
- return ss
-}
-
-// A Service provides information about a service, and ability to resolve an
-// endpoint from the context of a service, given a region.
-type Service struct {
- id string
- p *partition
-}
-
-// ID returns the identifier for the service.
-func (s Service) ID() string { return s.id }
-
-// ResolveEndpoint resolves an endpoint from the context of a service given
-// a region. See Partition.EndpointFor for usage and errors that can be returned.
-func (s Service) ResolveEndpoint(region string, opts ...func(*Options)) (ResolvedEndpoint, error) {
- return s.p.EndpointFor(s.id, region, opts...)
-}
-
-// Regions returns a map of Regions that the service is present in.
-//
-// A region is the AWS region the service exists in. Whereas a Endpoint is
-// an URL that can be resolved to a instance of a service.
-func (s Service) Regions() map[string]Region {
- rs := map[string]Region{}
- for id := range s.p.Services[s.id].Endpoints {
- if r, ok := s.p.Regions[id]; ok {
- rs[id] = Region{
- id: id,
- desc: r.Description,
- p: s.p,
- }
- }
- }
-
- return rs
-}
-
-// Endpoints returns a map of Endpoints indexed by their ID for all known
-// endpoints for a service.
-//
-// A region is the AWS region the service exists in. Whereas a Endpoint is
-// an URL that can be resolved to a instance of a service.
-func (s Service) Endpoints() map[string]Endpoint {
- es := make(map[string]Endpoint, len(s.p.Services[s.id].Endpoints))
- for id := range s.p.Services[s.id].Endpoints {
- es[id] = Endpoint{
- id: id,
- serviceID: s.id,
- p: s.p,
- }
- }
-
- return es
-}
-
-// A Endpoint provides information about endpoints, and provides the ability
-// to resolve that endpoint for the service, and the region the endpoint
-// represents.
-type Endpoint struct {
- id string
- serviceID string
- p *partition
-}
-
-// ID returns the identifier for an endpoint.
-func (e Endpoint) ID() string { return e.id }
-
-// ServiceID returns the identifier the endpoint belongs to.
-func (e Endpoint) ServiceID() string { return e.serviceID }
-
-// ResolveEndpoint resolves an endpoint from the context of a service and
-// region the endpoint represents. See Partition.EndpointFor for usage and
-// errors that can be returned.
-func (e Endpoint) ResolveEndpoint(opts ...func(*Options)) (ResolvedEndpoint, error) {
- return e.p.EndpointFor(e.serviceID, e.id, opts...)
-}
-
-// A ResolvedEndpoint is an endpoint that has been resolved based on a partition
-// service, and region.
-type ResolvedEndpoint struct {
- // The endpoint URL
- URL string
-
- // The endpoint partition
- PartitionID string
-
- // The region that should be used for signing requests.
- SigningRegion string
-
- // The service name that should be used for signing requests.
- SigningName string
-
- // States that the signing name for this endpoint was derived from metadata
- // passed in, but was not explicitly modeled.
- SigningNameDerived bool
-
- // The signing method that should be used for signing requests.
- SigningMethod string
-}
-
-// So that the Error interface type can be included as an anonymous field
-// in the requestError struct and not conflict with the error.Error() method.
-type awsError awserr.Error
-
-// A EndpointNotFoundError is returned when in StrictMatching mode, and the
-// endpoint for the service and region cannot be found in any of the partitions.
-type EndpointNotFoundError struct {
- awsError
- Partition string
- Service string
- Region string
-}
-
-// A UnknownServiceError is returned when the service does not resolve to an
-// endpoint. Includes a list of all known services for the partition. Returned
-// when a partition does not support the service.
-type UnknownServiceError struct {
- awsError
- Partition string
- Service string
- Known []string
-}
-
-// NewUnknownServiceError builds and returns UnknownServiceError.
-func NewUnknownServiceError(p, s string, known []string) UnknownServiceError {
- return UnknownServiceError{
- awsError: awserr.New("UnknownServiceError",
- "could not resolve endpoint for unknown service", nil),
- Partition: p,
- Service: s,
- Known: known,
- }
-}
-
-// String returns the string representation of the error.
-func (e UnknownServiceError) Error() string {
- extra := fmt.Sprintf("partition: %q, service: %q",
- e.Partition, e.Service)
- if len(e.Known) > 0 {
- extra += fmt.Sprintf(", known: %v", e.Known)
- }
- return awserr.SprintError(e.Code(), e.Message(), extra, e.OrigErr())
-}
-
-// String returns the string representation of the error.
-func (e UnknownServiceError) String() string {
- return e.Error()
-}
-
-// A UnknownEndpointError is returned when in StrictMatching mode and the
-// service is valid, but the region does not resolve to an endpoint. Includes
-// a list of all known endpoints for the service.
-type UnknownEndpointError struct {
- awsError
- Partition string
- Service string
- Region string
- Known []string
-}
-
-// NewUnknownEndpointError builds and returns UnknownEndpointError.
-func NewUnknownEndpointError(p, s, r string, known []string) UnknownEndpointError {
- return UnknownEndpointError{
- awsError: awserr.New("UnknownEndpointError",
- "could not resolve endpoint", nil),
- Partition: p,
- Service: s,
- Region: r,
- Known: known,
- }
-}
-
-// String returns the string representation of the error.
-func (e UnknownEndpointError) Error() string {
- extra := fmt.Sprintf("partition: %q, service: %q, region: %q",
- e.Partition, e.Service, e.Region)
- if len(e.Known) > 0 {
- extra += fmt.Sprintf(", known: %v", e.Known)
- }
- return awserr.SprintError(e.Code(), e.Message(), extra, e.OrigErr())
-}
-
-// String returns the string representation of the error.
-func (e UnknownEndpointError) String() string {
- return e.Error()
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/legacy_regions.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/legacy_regions.go
deleted file mode 100644
index df75e899adbe..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/legacy_regions.go
+++ /dev/null
@@ -1,24 +0,0 @@
-package endpoints
-
-var legacyGlobalRegions = map[string]map[string]struct{}{
- "sts": {
- "ap-northeast-1": {},
- "ap-south-1": {},
- "ap-southeast-1": {},
- "ap-southeast-2": {},
- "ca-central-1": {},
- "eu-central-1": {},
- "eu-north-1": {},
- "eu-west-1": {},
- "eu-west-2": {},
- "eu-west-3": {},
- "sa-east-1": {},
- "us-east-1": {},
- "us-east-2": {},
- "us-west-1": {},
- "us-west-2": {},
- },
- "s3": {
- "us-east-1": {},
- },
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go
deleted file mode 100644
index 773613722f49..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go
+++ /dev/null
@@ -1,351 +0,0 @@
-package endpoints
-
-import (
- "fmt"
- "regexp"
- "strconv"
- "strings"
-)
-
-var regionValidationRegex = regexp.MustCompile(`^[[:alnum:]]([[:alnum:]\-]*[[:alnum:]])?$`)
-
-type partitions []partition
-
-func (ps partitions) EndpointFor(service, region string, opts ...func(*Options)) (ResolvedEndpoint, error) {
- var opt Options
- opt.Set(opts...)
-
- for i := 0; i < len(ps); i++ {
- if !ps[i].canResolveEndpoint(service, region, opt.StrictMatching) {
- continue
- }
-
- return ps[i].EndpointFor(service, region, opts...)
- }
-
- // If loose matching fallback to first partition format to use
- // when resolving the endpoint.
- if !opt.StrictMatching && len(ps) > 0 {
- return ps[0].EndpointFor(service, region, opts...)
- }
-
- return ResolvedEndpoint{}, NewUnknownEndpointError("all partitions", service, region, []string{})
-}
-
-// Partitions satisfies the EnumPartitions interface and returns a list
-// of Partitions representing each partition represented in the SDK's
-// endpoints model.
-func (ps partitions) Partitions() []Partition {
- parts := make([]Partition, 0, len(ps))
- for i := 0; i < len(ps); i++ {
- parts = append(parts, ps[i].Partition())
- }
-
- return parts
-}
-
-type partition struct {
- ID string `json:"partition"`
- Name string `json:"partitionName"`
- DNSSuffix string `json:"dnsSuffix"`
- RegionRegex regionRegex `json:"regionRegex"`
- Defaults endpoint `json:"defaults"`
- Regions regions `json:"regions"`
- Services services `json:"services"`
-}
-
-func (p partition) Partition() Partition {
- return Partition{
- dnsSuffix: p.DNSSuffix,
- id: p.ID,
- p: &p,
- }
-}
-
-func (p partition) canResolveEndpoint(service, region string, strictMatch bool) bool {
- s, hasService := p.Services[service]
- _, hasEndpoint := s.Endpoints[region]
-
- if hasEndpoint && hasService {
- return true
- }
-
- if strictMatch {
- return false
- }
-
- return p.RegionRegex.MatchString(region)
-}
-
-func allowLegacyEmptyRegion(service string) bool {
- legacy := map[string]struct{}{
- "budgets": {},
- "ce": {},
- "chime": {},
- "cloudfront": {},
- "ec2metadata": {},
- "iam": {},
- "importexport": {},
- "organizations": {},
- "route53": {},
- "sts": {},
- "support": {},
- "waf": {},
- }
-
- _, allowed := legacy[service]
- return allowed
-}
-
-func (p partition) EndpointFor(service, region string, opts ...func(*Options)) (resolved ResolvedEndpoint, err error) {
- var opt Options
- opt.Set(opts...)
-
- s, hasService := p.Services[service]
- if len(service) == 0 || !(hasService || opt.ResolveUnknownService) {
- // Only return error if the resolver will not fallback to creating
- // endpoint based on service endpoint ID passed in.
- return resolved, NewUnknownServiceError(p.ID, service, serviceList(p.Services))
- }
-
- if len(region) == 0 && allowLegacyEmptyRegion(service) && len(s.PartitionEndpoint) != 0 {
- region = s.PartitionEndpoint
- }
-
- if (service == "sts" && opt.STSRegionalEndpoint != RegionalSTSEndpoint) ||
- (service == "s3" && opt.S3UsEast1RegionalEndpoint != RegionalS3UsEast1Endpoint) {
- if _, ok := legacyGlobalRegions[service][region]; ok {
- region = "aws-global"
- }
- }
-
- e, hasEndpoint := s.endpointForRegion(region)
- if len(region) == 0 || (!hasEndpoint && opt.StrictMatching) {
- return resolved, NewUnknownEndpointError(p.ID, service, region, endpointList(s.Endpoints))
- }
-
- defs := []endpoint{p.Defaults, s.Defaults}
-
- return e.resolve(service, p.ID, region, p.DNSSuffix, defs, opt)
-}
-
-func serviceList(ss services) []string {
- list := make([]string, 0, len(ss))
- for k := range ss {
- list = append(list, k)
- }
- return list
-}
-func endpointList(es endpoints) []string {
- list := make([]string, 0, len(es))
- for k := range es {
- list = append(list, k)
- }
- return list
-}
-
-type regionRegex struct {
- *regexp.Regexp
-}
-
-func (rr *regionRegex) UnmarshalJSON(b []byte) (err error) {
- // Strip leading and trailing quotes
- regex, err := strconv.Unquote(string(b))
- if err != nil {
- return fmt.Errorf("unable to strip quotes from regex, %v", err)
- }
-
- rr.Regexp, err = regexp.Compile(regex)
- if err != nil {
- return fmt.Errorf("unable to unmarshal region regex, %v", err)
- }
- return nil
-}
-
-type regions map[string]region
-
-type region struct {
- Description string `json:"description"`
-}
-
-type services map[string]service
-
-type service struct {
- PartitionEndpoint string `json:"partitionEndpoint"`
- IsRegionalized boxedBool `json:"isRegionalized,omitempty"`
- Defaults endpoint `json:"defaults"`
- Endpoints endpoints `json:"endpoints"`
-}
-
-func (s *service) endpointForRegion(region string) (endpoint, bool) {
- if s.IsRegionalized == boxedFalse {
- return s.Endpoints[s.PartitionEndpoint], region == s.PartitionEndpoint
- }
-
- if e, ok := s.Endpoints[region]; ok {
- return e, true
- }
-
- // Unable to find any matching endpoint, return
- // blank that will be used for generic endpoint creation.
- return endpoint{}, false
-}
-
-type endpoints map[string]endpoint
-
-type endpoint struct {
- Hostname string `json:"hostname"`
- Protocols []string `json:"protocols"`
- CredentialScope credentialScope `json:"credentialScope"`
-
- // Custom fields not modeled
- HasDualStack boxedBool `json:"-"`
- DualStackHostname string `json:"-"`
-
- // Signature Version not used
- SignatureVersions []string `json:"signatureVersions"`
-
- // SSLCommonName not used.
- SSLCommonName string `json:"sslCommonName"`
-}
-
-const (
- defaultProtocol = "https"
- defaultSigner = "v4"
-)
-
-var (
- protocolPriority = []string{"https", "http"}
- signerPriority = []string{"v4", "v2"}
-)
-
-func getByPriority(s []string, p []string, def string) string {
- if len(s) == 0 {
- return def
- }
-
- for i := 0; i < len(p); i++ {
- for j := 0; j < len(s); j++ {
- if s[j] == p[i] {
- return s[j]
- }
- }
- }
-
- return s[0]
-}
-
-func (e endpoint) resolve(service, partitionID, region, dnsSuffix string, defs []endpoint, opts Options) (ResolvedEndpoint, error) {
- var merged endpoint
- for _, def := range defs {
- merged.mergeIn(def)
- }
- merged.mergeIn(e)
- e = merged
-
- signingRegion := e.CredentialScope.Region
- if len(signingRegion) == 0 {
- signingRegion = region
- }
-
- signingName := e.CredentialScope.Service
- var signingNameDerived bool
- if len(signingName) == 0 {
- signingName = service
- signingNameDerived = true
- }
-
- hostname := e.Hostname
- // Offset the hostname for dualstack if enabled
- if opts.UseDualStack && e.HasDualStack == boxedTrue {
- hostname = e.DualStackHostname
- region = signingRegion
- }
-
- if !validateInputRegion(region) {
- return ResolvedEndpoint{}, fmt.Errorf("invalid region identifier format provided")
- }
-
- u := strings.Replace(hostname, "{service}", service, 1)
- u = strings.Replace(u, "{region}", region, 1)
- u = strings.Replace(u, "{dnsSuffix}", dnsSuffix, 1)
-
- scheme := getEndpointScheme(e.Protocols, opts.DisableSSL)
- u = fmt.Sprintf("%s://%s", scheme, u)
-
- return ResolvedEndpoint{
- URL: u,
- PartitionID: partitionID,
- SigningRegion: signingRegion,
- SigningName: signingName,
- SigningNameDerived: signingNameDerived,
- SigningMethod: getByPriority(e.SignatureVersions, signerPriority, defaultSigner),
- }, nil
-}
-
-func getEndpointScheme(protocols []string, disableSSL bool) string {
- if disableSSL {
- return "http"
- }
-
- return getByPriority(protocols, protocolPriority, defaultProtocol)
-}
-
-func (e *endpoint) mergeIn(other endpoint) {
- if len(other.Hostname) > 0 {
- e.Hostname = other.Hostname
- }
- if len(other.Protocols) > 0 {
- e.Protocols = other.Protocols
- }
- if len(other.SignatureVersions) > 0 {
- e.SignatureVersions = other.SignatureVersions
- }
- if len(other.CredentialScope.Region) > 0 {
- e.CredentialScope.Region = other.CredentialScope.Region
- }
- if len(other.CredentialScope.Service) > 0 {
- e.CredentialScope.Service = other.CredentialScope.Service
- }
- if len(other.SSLCommonName) > 0 {
- e.SSLCommonName = other.SSLCommonName
- }
- if other.HasDualStack != boxedBoolUnset {
- e.HasDualStack = other.HasDualStack
- }
- if len(other.DualStackHostname) > 0 {
- e.DualStackHostname = other.DualStackHostname
- }
-}
-
-type credentialScope struct {
- Region string `json:"region"`
- Service string `json:"service"`
-}
-
-type boxedBool int
-
-func (b *boxedBool) UnmarshalJSON(buf []byte) error {
- v, err := strconv.ParseBool(string(buf))
- if err != nil {
- return err
- }
-
- if v {
- *b = boxedTrue
- } else {
- *b = boxedFalse
- }
-
- return nil
-}
-
-const (
- boxedBoolUnset boxedBool = iota
- boxedFalse
- boxedTrue
-)
-
-func validateInputRegion(region string) bool {
- return regionValidationRegex.MatchString(region)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go
deleted file mode 100644
index 0fdfcc56e05d..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go
+++ /dev/null
@@ -1,351 +0,0 @@
-// +build codegen
-
-package endpoints
-
-import (
- "fmt"
- "io"
- "reflect"
- "strings"
- "text/template"
- "unicode"
-)
-
-// A CodeGenOptions are the options for code generating the endpoints into
-// Go code from the endpoints model definition.
-type CodeGenOptions struct {
- // Options for how the model will be decoded.
- DecodeModelOptions DecodeModelOptions
-
- // Disables code generation of the service endpoint prefix IDs defined in
- // the model.
- DisableGenerateServiceIDs bool
-}
-
-// Set combines all of the option functions together
-func (d *CodeGenOptions) Set(optFns ...func(*CodeGenOptions)) {
- for _, fn := range optFns {
- fn(d)
- }
-}
-
-// CodeGenModel given a endpoints model file will decode it and attempt to
-// generate Go code from the model definition. Error will be returned if
-// the code is unable to be generated, or decoded.
-func CodeGenModel(modelFile io.Reader, outFile io.Writer, optFns ...func(*CodeGenOptions)) error {
- var opts CodeGenOptions
- opts.Set(optFns...)
-
- resolver, err := DecodeModel(modelFile, func(d *DecodeModelOptions) {
- *d = opts.DecodeModelOptions
- })
- if err != nil {
- return err
- }
-
- v := struct {
- Resolver
- CodeGenOptions
- }{
- Resolver: resolver,
- CodeGenOptions: opts,
- }
-
- tmpl := template.Must(template.New("tmpl").Funcs(funcMap).Parse(v3Tmpl))
- if err := tmpl.ExecuteTemplate(outFile, "defaults", v); err != nil {
- return fmt.Errorf("failed to execute template, %v", err)
- }
-
- return nil
-}
-
-func toSymbol(v string) string {
- out := []rune{}
- for _, c := range strings.Title(v) {
- if !(unicode.IsNumber(c) || unicode.IsLetter(c)) {
- continue
- }
-
- out = append(out, c)
- }
-
- return string(out)
-}
-
-func quoteString(v string) string {
- return fmt.Sprintf("%q", v)
-}
-
-func regionConstName(p, r string) string {
- return toSymbol(p) + toSymbol(r)
-}
-
-func partitionGetter(id string) string {
- return fmt.Sprintf("%sPartition", toSymbol(id))
-}
-
-func partitionVarName(id string) string {
- return fmt.Sprintf("%sPartition", strings.ToLower(toSymbol(id)))
-}
-
-func listPartitionNames(ps partitions) string {
- names := []string{}
- switch len(ps) {
- case 1:
- return ps[0].Name
- case 2:
- return fmt.Sprintf("%s and %s", ps[0].Name, ps[1].Name)
- default:
- for i, p := range ps {
- if i == len(ps)-1 {
- names = append(names, "and "+p.Name)
- } else {
- names = append(names, p.Name)
- }
- }
- return strings.Join(names, ", ")
- }
-}
-
-func boxedBoolIfSet(msg string, v boxedBool) string {
- switch v {
- case boxedTrue:
- return fmt.Sprintf(msg, "boxedTrue")
- case boxedFalse:
- return fmt.Sprintf(msg, "boxedFalse")
- default:
- return ""
- }
-}
-
-func stringIfSet(msg, v string) string {
- if len(v) == 0 {
- return ""
- }
-
- return fmt.Sprintf(msg, v)
-}
-
-func stringSliceIfSet(msg string, vs []string) string {
- if len(vs) == 0 {
- return ""
- }
-
- names := []string{}
- for _, v := range vs {
- names = append(names, `"`+v+`"`)
- }
-
- return fmt.Sprintf(msg, strings.Join(names, ","))
-}
-
-func endpointIsSet(v endpoint) bool {
- return !reflect.DeepEqual(v, endpoint{})
-}
-
-func serviceSet(ps partitions) map[string]struct{} {
- set := map[string]struct{}{}
- for _, p := range ps {
- for id := range p.Services {
- set[id] = struct{}{}
- }
- }
-
- return set
-}
-
-var funcMap = template.FuncMap{
- "ToSymbol": toSymbol,
- "QuoteString": quoteString,
- "RegionConst": regionConstName,
- "PartitionGetter": partitionGetter,
- "PartitionVarName": partitionVarName,
- "ListPartitionNames": listPartitionNames,
- "BoxedBoolIfSet": boxedBoolIfSet,
- "StringIfSet": stringIfSet,
- "StringSliceIfSet": stringSliceIfSet,
- "EndpointIsSet": endpointIsSet,
- "ServicesSet": serviceSet,
-}
-
-const v3Tmpl = `
-{{ define "defaults" -}}
-// Code generated by aws/endpoints/v3model_codegen.go. DO NOT EDIT.
-
-package endpoints
-
-import (
- "regexp"
-)
-
- {{ template "partition consts" $.Resolver }}
-
- {{ range $_, $partition := $.Resolver }}
- {{ template "partition region consts" $partition }}
- {{ end }}
-
- {{ if not $.DisableGenerateServiceIDs -}}
- {{ template "service consts" $.Resolver }}
- {{- end }}
-
- {{ template "endpoint resolvers" $.Resolver }}
-{{- end }}
-
-{{ define "partition consts" }}
- // Partition identifiers
- const (
- {{ range $_, $p := . -}}
- {{ ToSymbol $p.ID }}PartitionID = {{ QuoteString $p.ID }} // {{ $p.Name }} partition.
- {{ end -}}
- )
-{{- end }}
-
-{{ define "partition region consts" }}
- // {{ .Name }} partition's regions.
- const (
- {{ range $id, $region := .Regions -}}
- {{ ToSymbol $id }}RegionID = {{ QuoteString $id }} // {{ $region.Description }}.
- {{ end -}}
- )
-{{- end }}
-
-{{ define "service consts" }}
- // Service identifiers
- const (
- {{ $serviceSet := ServicesSet . -}}
- {{ range $id, $_ := $serviceSet -}}
- {{ ToSymbol $id }}ServiceID = {{ QuoteString $id }} // {{ ToSymbol $id }}.
- {{ end -}}
- )
-{{- end }}
-
-{{ define "endpoint resolvers" }}
- // DefaultResolver returns an Endpoint resolver that will be able
- // to resolve endpoints for: {{ ListPartitionNames . }}.
- //
- // Use DefaultPartitions() to get the list of the default partitions.
- func DefaultResolver() Resolver {
- return defaultPartitions
- }
-
- // DefaultPartitions returns a list of the partitions the SDK is bundled
- // with. The available partitions are: {{ ListPartitionNames . }}.
- //
- // partitions := endpoints.DefaultPartitions
- // for _, p := range partitions {
- // // ... inspect partitions
- // }
- func DefaultPartitions() []Partition {
- return defaultPartitions.Partitions()
- }
-
- var defaultPartitions = partitions{
- {{ range $_, $partition := . -}}
- {{ PartitionVarName $partition.ID }},
- {{ end }}
- }
-
- {{ range $_, $partition := . -}}
- {{ $name := PartitionGetter $partition.ID -}}
- // {{ $name }} returns the Resolver for {{ $partition.Name }}.
- func {{ $name }}() Partition {
- return {{ PartitionVarName $partition.ID }}.Partition()
- }
- var {{ PartitionVarName $partition.ID }} = {{ template "gocode Partition" $partition }}
- {{ end }}
-{{ end }}
-
-{{ define "default partitions" }}
- func DefaultPartitions() []Partition {
- return []partition{
- {{ range $_, $partition := . -}}
- // {{ ToSymbol $partition.ID}}Partition(),
- {{ end }}
- }
- }
-{{ end }}
-
-{{ define "gocode Partition" -}}
-partition{
- {{ StringIfSet "ID: %q,\n" .ID -}}
- {{ StringIfSet "Name: %q,\n" .Name -}}
- {{ StringIfSet "DNSSuffix: %q,\n" .DNSSuffix -}}
- RegionRegex: {{ template "gocode RegionRegex" .RegionRegex }},
- {{ if EndpointIsSet .Defaults -}}
- Defaults: {{ template "gocode Endpoint" .Defaults }},
- {{- end }}
- Regions: {{ template "gocode Regions" .Regions }},
- Services: {{ template "gocode Services" .Services }},
-}
-{{- end }}
-
-{{ define "gocode RegionRegex" -}}
-regionRegex{
- Regexp: func() *regexp.Regexp{
- reg, _ := regexp.Compile({{ QuoteString .Regexp.String }})
- return reg
- }(),
-}
-{{- end }}
-
-{{ define "gocode Regions" -}}
-regions{
- {{ range $id, $region := . -}}
- "{{ $id }}": {{ template "gocode Region" $region }},
- {{ end -}}
-}
-{{- end }}
-
-{{ define "gocode Region" -}}
-region{
- {{ StringIfSet "Description: %q,\n" .Description -}}
-}
-{{- end }}
-
-{{ define "gocode Services" -}}
-services{
- {{ range $id, $service := . -}}
- "{{ $id }}": {{ template "gocode Service" $service }},
- {{ end }}
-}
-{{- end }}
-
-{{ define "gocode Service" -}}
-service{
- {{ StringIfSet "PartitionEndpoint: %q,\n" .PartitionEndpoint -}}
- {{ BoxedBoolIfSet "IsRegionalized: %s,\n" .IsRegionalized -}}
- {{ if EndpointIsSet .Defaults -}}
- Defaults: {{ template "gocode Endpoint" .Defaults -}},
- {{- end }}
- {{ if .Endpoints -}}
- Endpoints: {{ template "gocode Endpoints" .Endpoints }},
- {{- end }}
-}
-{{- end }}
-
-{{ define "gocode Endpoints" -}}
-endpoints{
- {{ range $id, $endpoint := . -}}
- "{{ $id }}": {{ template "gocode Endpoint" $endpoint }},
- {{ end }}
-}
-{{- end }}
-
-{{ define "gocode Endpoint" -}}
-endpoint{
- {{ StringIfSet "Hostname: %q,\n" .Hostname -}}
- {{ StringIfSet "SSLCommonName: %q,\n" .SSLCommonName -}}
- {{ StringSliceIfSet "Protocols: []string{%s},\n" .Protocols -}}
- {{ StringSliceIfSet "SignatureVersions: []string{%s},\n" .SignatureVersions -}}
- {{ if or .CredentialScope.Region .CredentialScope.Service -}}
- CredentialScope: credentialScope{
- {{ StringIfSet "Region: %q,\n" .CredentialScope.Region -}}
- {{ StringIfSet "Service: %q,\n" .CredentialScope.Service -}}
- },
- {{- end }}
- {{ BoxedBoolIfSet "HasDualStack: %s,\n" .HasDualStack -}}
- {{ StringIfSet "DualStackHostname: %q,\n" .DualStackHostname -}}
-
-}
-{{- end }}
-`
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/errors.go b/vendor/github.com/aws/aws-sdk-go/aws/errors.go
deleted file mode 100644
index fa06f7a8f8b8..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/errors.go
+++ /dev/null
@@ -1,13 +0,0 @@
-package aws
-
-import "github.com/aws/aws-sdk-go/aws/awserr"
-
-var (
- // ErrMissingRegion is an error that is returned if region configuration is
- // not found.
- ErrMissingRegion = awserr.New("MissingRegion", "could not find region configuration", nil)
-
- // ErrMissingEndpoint is an error that is returned if an endpoint cannot be
- // resolved for a service.
- ErrMissingEndpoint = awserr.New("MissingEndpoint", "'Endpoint' configuration is required for this service", nil)
-)
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/jsonvalue.go b/vendor/github.com/aws/aws-sdk-go/aws/jsonvalue.go
deleted file mode 100644
index 91a6f277a7eb..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/jsonvalue.go
+++ /dev/null
@@ -1,12 +0,0 @@
-package aws
-
-// JSONValue is a representation of a grab bag type that will be marshaled
-// into a json string. This type can be used just like any other map.
-//
-// Example:
-//
-// values := aws.JSONValue{
-// "Foo": "Bar",
-// }
-// values["Baz"] = "Qux"
-type JSONValue map[string]interface{}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/logger.go b/vendor/github.com/aws/aws-sdk-go/aws/logger.go
deleted file mode 100644
index 6ed15b2ecc26..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/logger.go
+++ /dev/null
@@ -1,118 +0,0 @@
-package aws
-
-import (
- "log"
- "os"
-)
-
-// A LogLevelType defines the level logging should be performed at. Used to instruct
-// the SDK which statements should be logged.
-type LogLevelType uint
-
-// LogLevel returns the pointer to a LogLevel. Should be used to workaround
-// not being able to take the address of a non-composite literal.
-func LogLevel(l LogLevelType) *LogLevelType {
- return &l
-}
-
-// Value returns the LogLevel value or the default value LogOff if the LogLevel
-// is nil. Safe to use on nil value LogLevelTypes.
-func (l *LogLevelType) Value() LogLevelType {
- if l != nil {
- return *l
- }
- return LogOff
-}
-
-// Matches returns true if the v LogLevel is enabled by this LogLevel. Should be
-// used with logging sub levels. Is safe to use on nil value LogLevelTypes. If
-// LogLevel is nil, will default to LogOff comparison.
-func (l *LogLevelType) Matches(v LogLevelType) bool {
- c := l.Value()
- return c&v == v
-}
-
-// AtLeast returns true if this LogLevel is at least high enough to satisfies v.
-// Is safe to use on nil value LogLevelTypes. If LogLevel is nil, will default
-// to LogOff comparison.
-func (l *LogLevelType) AtLeast(v LogLevelType) bool {
- c := l.Value()
- return c >= v
-}
-
-const (
- // LogOff states that no logging should be performed by the SDK. This is the
- // default state of the SDK, and should be use to disable all logging.
- LogOff LogLevelType = iota * 0x1000
-
- // LogDebug state that debug output should be logged by the SDK. This should
- // be used to inspect request made and responses received.
- LogDebug
-)
-
-// Debug Logging Sub Levels
-const (
- // LogDebugWithSigning states that the SDK should log request signing and
- // presigning events. This should be used to log the signing details of
- // requests for debugging. Will also enable LogDebug.
- LogDebugWithSigning LogLevelType = LogDebug | (1 << iota)
-
- // LogDebugWithHTTPBody states the SDK should log HTTP request and response
- // HTTP bodys in addition to the headers and path. This should be used to
- // see the body content of requests and responses made while using the SDK
- // Will also enable LogDebug.
- LogDebugWithHTTPBody
-
- // LogDebugWithRequestRetries states the SDK should log when service requests will
- // be retried. This should be used to log when you want to log when service
- // requests are being retried. Will also enable LogDebug.
- LogDebugWithRequestRetries
-
- // LogDebugWithRequestErrors states the SDK should log when service requests fail
- // to build, send, validate, or unmarshal.
- LogDebugWithRequestErrors
-
- // LogDebugWithEventStreamBody states the SDK should log EventStream
- // request and response bodys. This should be used to log the EventStream
- // wire unmarshaled message content of requests and responses made while
- // using the SDK Will also enable LogDebug.
- LogDebugWithEventStreamBody
-)
-
-// A Logger is a minimalistic interface for the SDK to log messages to. Should
-// be used to provide custom logging writers for the SDK to use.
-type Logger interface {
- Log(...interface{})
-}
-
-// A LoggerFunc is a convenience type to convert a function taking a variadic
-// list of arguments and wrap it so the Logger interface can be used.
-//
-// Example:
-// s3.New(sess, &aws.Config{Logger: aws.LoggerFunc(func(args ...interface{}) {
-// fmt.Fprintln(os.Stdout, args...)
-// })})
-type LoggerFunc func(...interface{})
-
-// Log calls the wrapped function with the arguments provided
-func (f LoggerFunc) Log(args ...interface{}) {
- f(args...)
-}
-
-// NewDefaultLogger returns a Logger which will write log messages to stdout, and
-// use same formatting runes as the stdlib log.Logger
-func NewDefaultLogger() Logger {
- return &defaultLogger{
- logger: log.New(os.Stdout, "", log.LstdFlags),
- }
-}
-
-// A defaultLogger provides a minimalistic logger satisfying the Logger interface.
-type defaultLogger struct {
- logger *log.Logger
-}
-
-// Log logs the parameters to the stdlib logger. See log.Println.
-func (l defaultLogger) Log(args ...interface{}) {
- l.logger.Println(args...)
-}
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
deleted file mode 100644
index 2ba3c56c11fb..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go
+++ /dev/null
@@ -1,19 +0,0 @@
-package request
-
-import (
- "strings"
-)
-
-func isErrConnectionReset(err error) bool {
- if strings.Contains(err.Error(), "read: connection reset") {
- return false
- }
-
- if strings.Contains(err.Error(), "use of closed network connection") ||
- strings.Contains(err.Error(), "connection reset") ||
- strings.Contains(err.Error(), "broken pipe") {
- return true
- }
-
- return false
-}
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
deleted file mode 100644
index e819ab6c0e87..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go
+++ /dev/null
@@ -1,343 +0,0 @@
-package request
-
-import (
- "fmt"
- "strings"
-)
-
-// A Handlers provides a collection of request handlers for various
-// stages of handling requests.
-type Handlers struct {
- Validate HandlerList
- Build HandlerList
- BuildStream HandlerList
- Sign HandlerList
- Send HandlerList
- ValidateResponse HandlerList
- Unmarshal HandlerList
- UnmarshalStream HandlerList
- UnmarshalMeta HandlerList
- UnmarshalError HandlerList
- Retry HandlerList
- AfterRetry HandlerList
- CompleteAttempt HandlerList
- Complete HandlerList
-}
-
-// Copy returns a copy of this handler's lists.
-func (h *Handlers) Copy() Handlers {
- return Handlers{
- Validate: h.Validate.copy(),
- Build: h.Build.copy(),
- BuildStream: h.BuildStream.copy(),
- Sign: h.Sign.copy(),
- Send: h.Send.copy(),
- ValidateResponse: h.ValidateResponse.copy(),
- Unmarshal: h.Unmarshal.copy(),
- UnmarshalStream: h.UnmarshalStream.copy(),
- UnmarshalError: h.UnmarshalError.copy(),
- UnmarshalMeta: h.UnmarshalMeta.copy(),
- Retry: h.Retry.copy(),
- AfterRetry: h.AfterRetry.copy(),
- CompleteAttempt: h.CompleteAttempt.copy(),
- Complete: h.Complete.copy(),
- }
-}
-
-// Clear removes callback functions for all handlers.
-func (h *Handlers) Clear() {
- h.Validate.Clear()
- h.Build.Clear()
- h.BuildStream.Clear()
- h.Send.Clear()
- h.Sign.Clear()
- h.Unmarshal.Clear()
- h.UnmarshalStream.Clear()
- h.UnmarshalMeta.Clear()
- h.UnmarshalError.Clear()
- h.ValidateResponse.Clear()
- h.Retry.Clear()
- h.AfterRetry.Clear()
- h.CompleteAttempt.Clear()
- h.Complete.Clear()
-}
-
-// IsEmpty returns if there are no handlers in any of the handlerlists.
-func (h *Handlers) IsEmpty() bool {
- if h.Validate.Len() != 0 {
- return false
- }
- if h.Build.Len() != 0 {
- return false
- }
- if h.BuildStream.Len() != 0 {
- return false
- }
- if h.Send.Len() != 0 {
- return false
- }
- if h.Sign.Len() != 0 {
- return false
- }
- if h.Unmarshal.Len() != 0 {
- return false
- }
- if h.UnmarshalStream.Len() != 0 {
- return false
- }
- if h.UnmarshalMeta.Len() != 0 {
- return false
- }
- if h.UnmarshalError.Len() != 0 {
- return false
- }
- if h.ValidateResponse.Len() != 0 {
- return false
- }
- if h.Retry.Len() != 0 {
- return false
- }
- if h.AfterRetry.Len() != 0 {
- return false
- }
- if h.CompleteAttempt.Len() != 0 {
- return false
- }
- if h.Complete.Len() != 0 {
- return false
- }
-
- return true
-}
-
-// A HandlerListRunItem represents an entry in the HandlerList which
-// is being run.
-type HandlerListRunItem struct {
- Index int
- Handler NamedHandler
- Request *Request
-}
-
-// A HandlerList manages zero or more handlers in a list.
-type HandlerList struct {
- list []NamedHandler
-
- // Called after each request handler in the list is called. If set
- // and the func returns true the HandlerList will continue to iterate
- // over the request handlers. If false is returned the HandlerList
- // will stop iterating.
- //
- // Should be used if extra logic to be performed between each handler
- // in the list. This can be used to terminate a list's iteration
- // based on a condition such as error like, HandlerListStopOnError.
- // Or for logging like HandlerListLogItem.
- AfterEachFn func(item HandlerListRunItem) bool
-}
-
-// A NamedHandler is a struct that contains a name and function callback.
-type NamedHandler struct {
- Name string
- Fn func(*Request)
-}
-
-// copy creates a copy of the handler list.
-func (l *HandlerList) copy() HandlerList {
- n := HandlerList{
- AfterEachFn: l.AfterEachFn,
- }
- if len(l.list) == 0 {
- return n
- }
-
- n.list = append(make([]NamedHandler, 0, len(l.list)), l.list...)
- return n
-}
-
-// Clear clears the handler list.
-func (l *HandlerList) Clear() {
- l.list = l.list[0:0]
-}
-
-// Len returns the number of handlers in the list.
-func (l *HandlerList) Len() int {
- return len(l.list)
-}
-
-// PushBack pushes handler f to the back of the handler list.
-func (l *HandlerList) PushBack(f func(*Request)) {
- l.PushBackNamed(NamedHandler{"__anonymous", f})
-}
-
-// PushBackNamed pushes named handler f to the back of the handler list.
-func (l *HandlerList) PushBackNamed(n NamedHandler) {
- if cap(l.list) == 0 {
- l.list = make([]NamedHandler, 0, 5)
- }
- l.list = append(l.list, n)
-}
-
-// PushFront pushes handler f to the front of the handler list.
-func (l *HandlerList) PushFront(f func(*Request)) {
- l.PushFrontNamed(NamedHandler{"__anonymous", f})
-}
-
-// PushFrontNamed pushes named handler f to the front of the handler list.
-func (l *HandlerList) PushFrontNamed(n NamedHandler) {
- if cap(l.list) == len(l.list) {
- // Allocating new list required
- l.list = append([]NamedHandler{n}, l.list...)
- } else {
- // Enough room to prepend into list.
- l.list = append(l.list, NamedHandler{})
- copy(l.list[1:], l.list)
- l.list[0] = n
- }
-}
-
-// Remove removes a NamedHandler n
-func (l *HandlerList) Remove(n NamedHandler) {
- l.RemoveByName(n.Name)
-}
-
-// RemoveByName removes a NamedHandler by name.
-func (l *HandlerList) RemoveByName(name string) {
- for i := 0; i < len(l.list); i++ {
- m := l.list[i]
- if m.Name == name {
- // Shift array preventing creating new arrays
- copy(l.list[i:], l.list[i+1:])
- l.list[len(l.list)-1] = NamedHandler{}
- l.list = l.list[:len(l.list)-1]
-
- // decrement list so next check to length is correct
- i--
- }
- }
-}
-
-// SwapNamed will swap out any existing handlers with the same name as the
-// passed in NamedHandler returning true if handlers were swapped. False is
-// returned otherwise.
-func (l *HandlerList) SwapNamed(n NamedHandler) (swapped bool) {
- for i := 0; i < len(l.list); i++ {
- if l.list[i].Name == n.Name {
- l.list[i].Fn = n.Fn
- swapped = true
- }
- }
-
- return swapped
-}
-
-// Swap will swap out all handlers matching the name passed in. The matched
-// handlers will be swapped in. True is returned if the handlers were swapped.
-func (l *HandlerList) Swap(name string, replace NamedHandler) bool {
- var swapped bool
-
- for i := 0; i < len(l.list); i++ {
- if l.list[i].Name == name {
- l.list[i] = replace
- swapped = true
- }
- }
-
- return swapped
-}
-
-// SetBackNamed will replace the named handler if it exists in the handler list.
-// If the handler does not exist the handler will be added to the end of the list.
-func (l *HandlerList) SetBackNamed(n NamedHandler) {
- if !l.SwapNamed(n) {
- l.PushBackNamed(n)
- }
-}
-
-// SetFrontNamed will replace the named handler if it exists in the handler list.
-// If the handler does not exist the handler will be added to the beginning of
-// the list.
-func (l *HandlerList) SetFrontNamed(n NamedHandler) {
- if !l.SwapNamed(n) {
- l.PushFrontNamed(n)
- }
-}
-
-// Run executes all handlers in the list with a given request object.
-func (l *HandlerList) Run(r *Request) {
- for i, h := range l.list {
- h.Fn(r)
- item := HandlerListRunItem{
- Index: i, Handler: h, Request: r,
- }
- if l.AfterEachFn != nil && !l.AfterEachFn(item) {
- return
- }
- }
-}
-
-// HandlerListLogItem logs the request handler and the state of the
-// request's Error value. Always returns true to continue iterating
-// request handlers in a HandlerList.
-func HandlerListLogItem(item HandlerListRunItem) bool {
- if item.Request.Config.Logger == nil {
- return true
- }
- item.Request.Config.Logger.Log("DEBUG: RequestHandler",
- item.Index, item.Handler.Name, item.Request.Error)
-
- return true
-}
-
-// HandlerListStopOnError returns false to stop the HandlerList iterating
-// over request handlers if Request.Error is not nil. True otherwise
-// to continue iterating.
-func HandlerListStopOnError(item HandlerListRunItem) bool {
- return item.Request.Error == nil
-}
-
-// WithAppendUserAgent will add a string to the user agent prefixed with a
-// single white space.
-func WithAppendUserAgent(s string) Option {
- return func(r *Request) {
- r.Handlers.Build.PushBack(func(r2 *Request) {
- AddToUserAgent(r, s)
- })
- }
-}
-
-// MakeAddToUserAgentHandler will add the name/version pair to the User-Agent request
-// header. If the extra parameters are provided they will be added as metadata to the
-// name/version pair resulting in the following format.
-// "name/version (extra0; extra1; ...)"
-// The user agent part will be concatenated with this current request's user agent string.
-func MakeAddToUserAgentHandler(name, version string, extra ...string) func(*Request) {
- ua := fmt.Sprintf("%s/%s", name, version)
- if len(extra) > 0 {
- ua += fmt.Sprintf(" (%s)", strings.Join(extra, "; "))
- }
- return func(r *Request) {
- AddToUserAgent(r, ua)
- }
-}
-
-// MakeAddToUserAgentFreeFormHandler adds the input to the User-Agent request header.
-// The input string will be concatenated with the current request's user agent string.
-func MakeAddToUserAgentFreeFormHandler(s string) func(*Request) {
- return func(r *Request) {
- AddToUserAgent(r, s)
- }
-}
-
-// WithSetRequestHeaders updates the operation request's HTTP header to contain
-// the header key value pairs provided. If the header key already exists in the
-// request's HTTP header set, the existing value(s) will be replaced.
-func WithSetRequestHeaders(h map[string]string) Option {
- return withRequestHeader(h).SetRequestHeaders
-}
-
-type withRequestHeader map[string]string
-
-func (h withRequestHeader) SetRequestHeaders(r *Request) {
- for k, v := range h {
- r.HTTPRequest.Header[k] = []string{v}
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/http_request.go b/vendor/github.com/aws/aws-sdk-go/aws/request/http_request.go
deleted file mode 100644
index 79f79602b03f..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/http_request.go
+++ /dev/null
@@ -1,24 +0,0 @@
-package request
-
-import (
- "io"
- "net/http"
- "net/url"
-)
-
-func copyHTTPRequest(r *http.Request, body io.ReadCloser) *http.Request {
- req := new(http.Request)
- *req = *r
- req.URL = &url.URL{}
- *req.URL = *r.URL
- req.Body = body
-
- req.Header = http.Header{}
- for k, v := range r.Header {
- for _, vv := range v {
- req.Header.Add(k, vv)
- }
- }
-
- return req
-}
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
deleted file mode 100644
index 9370fa50c382..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go
+++ /dev/null
@@ -1,65 +0,0 @@
-package request
-
-import (
- "io"
- "sync"
-
- "github.com/aws/aws-sdk-go/internal/sdkio"
-)
-
-// offsetReader is a thread-safe io.ReadCloser to prevent racing
-// with retrying requests
-type offsetReader struct {
- buf io.ReadSeeker
- lock sync.Mutex
- closed bool
-}
-
-func newOffsetReader(buf io.ReadSeeker, offset int64) (*offsetReader, error) {
- reader := &offsetReader{}
- _, err := buf.Seek(offset, sdkio.SeekStart)
- if err != nil {
- return nil, err
- }
-
- reader.buf = buf
- return reader, nil
-}
-
-// Close will close the instance of the offset reader's access to
-// the underlying io.ReadSeeker.
-func (o *offsetReader) Close() error {
- o.lock.Lock()
- defer o.lock.Unlock()
- o.closed = true
- return nil
-}
-
-// Read is a thread-safe read of the underlying io.ReadSeeker
-func (o *offsetReader) Read(p []byte) (int, error) {
- o.lock.Lock()
- defer o.lock.Unlock()
-
- if o.closed {
- return 0, io.EOF
- }
-
- return o.buf.Read(p)
-}
-
-// Seek is a thread-safe seeking operation.
-func (o *offsetReader) Seek(offset int64, whence int) (int64, error) {
- o.lock.Lock()
- defer o.lock.Unlock()
-
- return o.buf.Seek(offset, whence)
-}
-
-// CloseAndCopy will return a new offsetReader with a copy of the old buffer
-// and close the old buffer.
-func (o *offsetReader) CloseAndCopy(offset int64) (*offsetReader, error) {
- if err := o.Close(); err != nil {
- return nil, err
- }
- return newOffsetReader(o.buf, offset)
-}
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
deleted file mode 100644
index d597c6ead555..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request.go
+++ /dev/null
@@ -1,698 +0,0 @@
-package request
-
-import (
- "bytes"
- "fmt"
- "io"
- "net/http"
- "net/url"
- "reflect"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/client/metadata"
- "github.com/aws/aws-sdk-go/internal/sdkio"
-)
-
-const (
- // ErrCodeSerialization is the serialization error code that is received
- // during protocol unmarshaling.
- ErrCodeSerialization = "SerializationError"
-
- // ErrCodeRead is an error that is returned during HTTP reads.
- ErrCodeRead = "ReadError"
-
- // ErrCodeResponseTimeout is the connection timeout error that is received
- // during body reads.
- ErrCodeResponseTimeout = "ResponseTimeout"
-
- // ErrCodeInvalidPresignExpire is returned when the expire time provided to
- // presign is invalid
- ErrCodeInvalidPresignExpire = "InvalidPresignExpireError"
-
- // CanceledErrorCode is the error code that will be returned by an
- // API request that was canceled. Requests given a aws.Context may
- // return this error when canceled.
- CanceledErrorCode = "RequestCanceled"
-
- // ErrCodeRequestError is an error preventing the SDK from continuing to
- // process the request.
- ErrCodeRequestError = "RequestError"
-)
-
-// A Request is the service request to be made.
-type Request struct {
- Config aws.Config
- ClientInfo metadata.ClientInfo
- Handlers Handlers
-
- Retryer
- AttemptTime time.Time
- Time time.Time
- Operation *Operation
- HTTPRequest *http.Request
- HTTPResponse *http.Response
- Body io.ReadSeeker
- streamingBody io.ReadCloser
- BodyStart int64 // offset from beginning of Body that the request body starts
- Params interface{}
- Error error
- Data interface{}
- RequestID string
- RetryCount int
- Retryable *bool
- RetryDelay time.Duration
- NotHoist bool
- SignedHeaderVals http.Header
- LastSignedAt time.Time
- DisableFollowRedirects bool
-
- // Additional API error codes that should be retried. IsErrorRetryable
- // will consider these codes in addition to its built in cases.
- RetryErrorCodes []string
-
- // Additional API error codes that should be retried with throttle backoff
- // delay. IsErrorThrottle will consider these codes in addition to its
- // built in cases.
- ThrottleErrorCodes []string
-
- // A value greater than 0 instructs the request to be signed as Presigned URL
- // You should not set this field directly. Instead use Request's
- // Presign or PresignRequest methods.
- ExpireTime time.Duration
-
- context aws.Context
-
- built bool
-
- // Need to persist an intermediate body between the input Body and HTTP
- // request body because the HTTP Client's transport can maintain a reference
- // to the HTTP request's body after the client has returned. This value is
- // safe to use concurrently and wrap the input Body for each HTTP request.
- safeBody *offsetReader
-}
-
-// An Operation is the service API operation to be made.
-type Operation struct {
- Name string
- HTTPMethod string
- HTTPPath string
- *Paginator
-
- BeforePresignFn func(r *Request) error
-}
-
-// New returns a new Request pointer for the service API operation and
-// parameters.
-//
-// A Retryer should be provided to direct how the request is retried. If
-// Retryer is nil, a default no retry value will be used. You can use
-// NoOpRetryer in the Client package to disable retry behavior directly.
-//
-// Params is any value of input parameters to be the request payload.
-// Data is pointer value to an object which the request's response
-// payload will be deserialized to.
-func New(cfg aws.Config, clientInfo metadata.ClientInfo, handlers Handlers,
- retryer Retryer, operation *Operation, params interface{}, data interface{}) *Request {
-
- if retryer == nil {
- retryer = noOpRetryer{}
- }
-
- method := operation.HTTPMethod
- if method == "" {
- method = "POST"
- }
-
- httpReq, _ := http.NewRequest(method, "", nil)
-
- var err error
- httpReq.URL, err = url.Parse(clientInfo.Endpoint + operation.HTTPPath)
- if err != nil {
- httpReq.URL = &url.URL{}
- err = awserr.New("InvalidEndpointURL", "invalid endpoint uri", err)
- }
-
- r := &Request{
- Config: cfg,
- ClientInfo: clientInfo,
- Handlers: handlers.Copy(),
-
- Retryer: retryer,
- Time: time.Now(),
- ExpireTime: 0,
- Operation: operation,
- HTTPRequest: httpReq,
- Body: nil,
- Params: params,
- Error: err,
- Data: data,
- }
- r.SetBufferBody([]byte{})
-
- return r
-}
-
-// A Option is a functional option that can augment or modify a request when
-// using a WithContext API operation method.
-type Option func(*Request)
-
-// WithGetResponseHeader builds a request Option which will retrieve a single
-// header value from the HTTP Response. If there are multiple values for the
-// header key use WithGetResponseHeaders instead to access the http.Header
-// map directly. The passed in val pointer must be non-nil.
-//
-// This Option can be used multiple times with a single API operation.
-//
-// var id2, versionID string
-// svc.PutObjectWithContext(ctx, params,
-// request.WithGetResponseHeader("x-amz-id-2", &id2),
-// request.WithGetResponseHeader("x-amz-version-id", &versionID),
-// )
-func WithGetResponseHeader(key string, val *string) Option {
- return func(r *Request) {
- r.Handlers.Complete.PushBack(func(req *Request) {
- *val = req.HTTPResponse.Header.Get(key)
- })
- }
-}
-
-// WithGetResponseHeaders builds a request Option which will retrieve the
-// headers from the HTTP response and assign them to the passed in headers
-// variable. The passed in headers pointer must be non-nil.
-//
-// var headers http.Header
-// svc.PutObjectWithContext(ctx, params, request.WithGetResponseHeaders(&headers))
-func WithGetResponseHeaders(headers *http.Header) Option {
- return func(r *Request) {
- r.Handlers.Complete.PushBack(func(req *Request) {
- *headers = req.HTTPResponse.Header
- })
- }
-}
-
-// WithLogLevel is a request option that will set the request to use a specific
-// log level when the request is made.
-//
-// svc.PutObjectWithContext(ctx, params, request.WithLogLevel(aws.LogDebugWithHTTPBody)
-func WithLogLevel(l aws.LogLevelType) Option {
- return func(r *Request) {
- r.Config.LogLevel = aws.LogLevel(l)
- }
-}
-
-// ApplyOptions will apply each option to the request calling them in the order
-// the were provided.
-func (r *Request) ApplyOptions(opts ...Option) {
- for _, opt := range opts {
- opt(r)
- }
-}
-
-// Context will always returns a non-nil context. If Request does not have a
-// context aws.BackgroundContext will be returned.
-func (r *Request) Context() aws.Context {
- if r.context != nil {
- return r.context
- }
- return aws.BackgroundContext()
-}
-
-// SetContext adds a Context to the current request that can be used to cancel
-// a in-flight request. The Context value must not be nil, or this method will
-// panic.
-//
-// Unlike http.Request.WithContext, SetContext does not return a copy of the
-// Request. It is not safe to use use a single Request value for multiple
-// requests. A new Request should be created for each API operation request.
-//
-// Go 1.6 and below:
-// The http.Request's Cancel field will be set to the Done() value of
-// the context. This will overwrite the Cancel field's value.
-//
-// Go 1.7 and above:
-// The http.Request.WithContext will be used to set the context on the underlying
-// http.Request. This will create a shallow copy of the http.Request. The SDK
-// may create sub contexts in the future for nested requests such as retries.
-func (r *Request) SetContext(ctx aws.Context) {
- if ctx == nil {
- panic("context cannot be nil")
- }
- setRequestContext(r, ctx)
-}
-
-// WillRetry returns if the request's can be retried.
-func (r *Request) WillRetry() bool {
- if !aws.IsReaderSeekable(r.Body) && r.HTTPRequest.Body != NoBody {
- return false
- }
- return r.Error != nil && aws.BoolValue(r.Retryable) && r.RetryCount < r.MaxRetries()
-}
-
-func fmtAttemptCount(retryCount, maxRetries int) string {
- return fmt.Sprintf("attempt %v/%v", retryCount, maxRetries)
-}
-
-// ParamsFilled returns if the request's parameters have been populated
-// and the parameters are valid. False is returned if no parameters are
-// provided or invalid.
-func (r *Request) ParamsFilled() bool {
- return r.Params != nil && reflect.ValueOf(r.Params).Elem().IsValid()
-}
-
-// DataFilled returns true if the request's data for response deserialization
-// target has been set and is a valid. False is returned if data is not
-// set, or is invalid.
-func (r *Request) DataFilled() bool {
- return r.Data != nil && reflect.ValueOf(r.Data).Elem().IsValid()
-}
-
-// SetBufferBody will set the request's body bytes that will be sent to
-// the service API.
-func (r *Request) SetBufferBody(buf []byte) {
- r.SetReaderBody(bytes.NewReader(buf))
-}
-
-// SetStringBody sets the body of the request to be backed by a string.
-func (r *Request) SetStringBody(s string) {
- r.SetReaderBody(strings.NewReader(s))
-}
-
-// SetReaderBody will set the request's body reader.
-func (r *Request) SetReaderBody(reader io.ReadSeeker) {
- r.Body = reader
-
- if aws.IsReaderSeekable(reader) {
- var err error
- // Get the Bodies current offset so retries will start from the same
- // initial position.
- r.BodyStart, err = reader.Seek(0, sdkio.SeekCurrent)
- if err != nil {
- r.Error = awserr.New(ErrCodeSerialization,
- "failed to determine start of request body", err)
- return
- }
- }
- r.ResetBody()
-}
-
-// SetStreamingBody set the reader to be used for the request that will stream
-// bytes to the server. Request's Body must not be set to any reader.
-func (r *Request) SetStreamingBody(reader io.ReadCloser) {
- r.streamingBody = reader
- r.SetReaderBody(aws.ReadSeekCloser(reader))
-}
-
-// Presign returns the request's signed URL. Error will be returned
-// if the signing fails. The expire parameter is only used for presigned Amazon
-// S3 API requests. All other AWS services will use a fixed expiration
-// time of 15 minutes.
-//
-// It is invalid to create a presigned URL with a expire duration 0 or less. An
-// error is returned if expire duration is 0 or less.
-func (r *Request) Presign(expire time.Duration) (string, error) {
- r = r.copy()
-
- // Presign requires all headers be hoisted. There is no way to retrieve
- // the signed headers not hoisted without this. Making the presigned URL
- // useless.
- r.NotHoist = false
-
- u, _, err := getPresignedURL(r, expire)
- return u, err
-}
-
-// PresignRequest behaves just like presign, with the addition of returning a
-// set of headers that were signed. The expire parameter is only used for
-// presigned Amazon S3 API requests. All other AWS services will use a fixed
-// expiration time of 15 minutes.
-//
-// It is invalid to create a presigned URL with a expire duration 0 or less. An
-// error is returned if expire duration is 0 or less.
-//
-// Returns the URL string for the API operation with signature in the query string,
-// and the HTTP headers that were included in the signature. These headers must
-// be included in any HTTP request made with the presigned URL.
-//
-// To prevent hoisting any headers to the query string set NotHoist to true on
-// this Request value prior to calling PresignRequest.
-func (r *Request) PresignRequest(expire time.Duration) (string, http.Header, error) {
- r = r.copy()
- return getPresignedURL(r, expire)
-}
-
-// IsPresigned returns true if the request represents a presigned API url.
-func (r *Request) IsPresigned() bool {
- return r.ExpireTime != 0
-}
-
-func getPresignedURL(r *Request, expire time.Duration) (string, http.Header, error) {
- if expire <= 0 {
- return "", nil, awserr.New(
- ErrCodeInvalidPresignExpire,
- "presigned URL requires an expire duration greater than 0",
- nil,
- )
- }
-
- r.ExpireTime = expire
-
- if r.Operation.BeforePresignFn != nil {
- if err := r.Operation.BeforePresignFn(r); err != nil {
- return "", nil, err
- }
- }
-
- if err := r.Sign(); err != nil {
- return "", nil, err
- }
-
- return r.HTTPRequest.URL.String(), r.SignedHeaderVals, nil
-}
-
-const (
- notRetrying = "not retrying"
-)
-
-func debugLogReqError(r *Request, stage, retryStr string, err error) {
- if !r.Config.LogLevel.Matches(aws.LogDebugWithRequestErrors) {
- return
- }
-
- r.Config.Logger.Log(fmt.Sprintf("DEBUG: %s %s/%s failed, %s, error %v",
- stage, r.ClientInfo.ServiceName, r.Operation.Name, retryStr, err))
-}
-
-// Build will build the request's object so it can be signed and sent
-// to the service. Build will also validate all the request's parameters.
-// Any additional build Handlers set on this request will be run
-// in the order they were set.
-//
-// The request will only be built once. Multiple calls to build will have
-// no effect.
-//
-// If any Validate or Build errors occur the build will stop and the error
-// which occurred will be returned.
-func (r *Request) Build() error {
- if !r.built {
- r.Handlers.Validate.Run(r)
- if r.Error != nil {
- debugLogReqError(r, "Validate Request", notRetrying, r.Error)
- return r.Error
- }
- r.Handlers.Build.Run(r)
- if r.Error != nil {
- debugLogReqError(r, "Build Request", notRetrying, r.Error)
- return r.Error
- }
- r.built = true
- }
-
- return r.Error
-}
-
-// Sign will sign the request, returning error if errors are encountered.
-//
-// Sign will build the request prior to signing. All Sign Handlers will
-// be executed in the order they were set.
-func (r *Request) Sign() error {
- r.Build()
- if r.Error != nil {
- debugLogReqError(r, "Build Request", notRetrying, r.Error)
- return r.Error
- }
-
- SanitizeHostForHeader(r.HTTPRequest)
-
- r.Handlers.Sign.Run(r)
- return r.Error
-}
-
-func (r *Request) getNextRequestBody() (body io.ReadCloser, err error) {
- if r.streamingBody != nil {
- return r.streamingBody, nil
- }
-
- if r.safeBody != nil {
- r.safeBody.Close()
- }
-
- r.safeBody, err = newOffsetReader(r.Body, r.BodyStart)
- if err != nil {
- return nil, awserr.New(ErrCodeSerialization,
- "failed to get next request body reader", err)
- }
-
- // Go 1.8 tightened and clarified the rules code needs to use when building
- // requests with the http package. Go 1.8 removed the automatic detection
- // of if the Request.Body was empty, or actually had bytes in it. The SDK
- // always sets the Request.Body even if it is empty and should not actually
- // be sent. This is incorrect.
- //
- // Go 1.8 did add a http.NoBody value that the SDK can use to tell the http
- // client that the request really should be sent without a body. The
- // Request.Body cannot be set to nil, which is preferable, because the
- // field is exported and could introduce nil pointer dereferences for users
- // of the SDK if they used that field.
- //
- // Related golang/go#18257
- l, err := aws.SeekerLen(r.Body)
- if err != nil {
- return nil, awserr.New(ErrCodeSerialization,
- "failed to compute request body size", err)
- }
-
- if l == 0 {
- body = NoBody
- } else if l > 0 {
- body = r.safeBody
- } else {
- // Hack to prevent sending bodies for methods where the body
- // should be ignored by the server. Sending bodies on these
- // methods without an associated ContentLength will cause the
- // request to socket timeout because the server does not handle
- // Transfer-Encoding: chunked bodies for these methods.
- //
- // This would only happen if a aws.ReaderSeekerCloser was used with
- // a io.Reader that was not also an io.Seeker, or did not implement
- // Len() method.
- switch r.Operation.HTTPMethod {
- case "GET", "HEAD", "DELETE":
- body = NoBody
- default:
- body = r.safeBody
- }
- }
-
- return body, nil
-}
-
-// GetBody will return an io.ReadSeeker of the Request's underlying
-// input body with a concurrency safe wrapper.
-func (r *Request) GetBody() io.ReadSeeker {
- return r.safeBody
-}
-
-// Send will send the request, returning error if errors are encountered.
-//
-// Send will sign the request prior to sending. All Send Handlers will
-// be executed in the order they were set.
-//
-// Canceling a request is non-deterministic. If a request has been canceled,
-// then the transport will choose, randomly, one of the state channels during
-// reads or getting the connection.
-//
-// readLoop() and getConn(req *Request, cm connectMethod)
-// https://github.com/golang/go/blob/master/src/net/http/transport.go
-//
-// Send will not close the request.Request's body.
-func (r *Request) Send() error {
- defer func() {
- // Regardless of success or failure of the request trigger the Complete
- // request handlers.
- r.Handlers.Complete.Run(r)
- }()
-
- if err := r.Error; err != nil {
- return err
- }
-
- for {
- r.Error = nil
- r.AttemptTime = time.Now()
-
- if err := r.Sign(); err != nil {
- debugLogReqError(r, "Sign Request", notRetrying, err)
- return err
- }
-
- if err := r.sendRequest(); err == nil {
- return nil
- }
- r.Handlers.Retry.Run(r)
- r.Handlers.AfterRetry.Run(r)
-
- if r.Error != nil || !aws.BoolValue(r.Retryable) {
- return r.Error
- }
-
- if err := r.prepareRetry(); err != nil {
- r.Error = err
- return err
- }
- }
-}
-
-func (r *Request) prepareRetry() error {
- if r.Config.LogLevel.Matches(aws.LogDebugWithRequestRetries) {
- r.Config.Logger.Log(fmt.Sprintf("DEBUG: Retrying Request %s/%s, attempt %d",
- r.ClientInfo.ServiceName, r.Operation.Name, r.RetryCount))
- }
-
- // The previous http.Request will have a reference to the r.Body
- // and the HTTP Client's Transport may still be reading from
- // the request's body even though the Client's Do returned.
- r.HTTPRequest = copyHTTPRequest(r.HTTPRequest, nil)
- r.ResetBody()
- if err := r.Error; err != nil {
- return awserr.New(ErrCodeSerialization,
- "failed to prepare body for retry", err)
-
- }
-
- // Closing response body to ensure that no response body is leaked
- // between retry attempts.
- if r.HTTPResponse != nil && r.HTTPResponse.Body != nil {
- r.HTTPResponse.Body.Close()
- }
-
- return nil
-}
-
-func (r *Request) sendRequest() (sendErr error) {
- defer r.Handlers.CompleteAttempt.Run(r)
-
- r.Retryable = nil
- r.Handlers.Send.Run(r)
- if r.Error != nil {
- debugLogReqError(r, "Send Request",
- fmtAttemptCount(r.RetryCount, r.MaxRetries()),
- r.Error)
- return r.Error
- }
-
- r.Handlers.UnmarshalMeta.Run(r)
- r.Handlers.ValidateResponse.Run(r)
- if r.Error != nil {
- r.Handlers.UnmarshalError.Run(r)
- debugLogReqError(r, "Validate Response",
- fmtAttemptCount(r.RetryCount, r.MaxRetries()),
- r.Error)
- return r.Error
- }
-
- r.Handlers.Unmarshal.Run(r)
- if r.Error != nil {
- debugLogReqError(r, "Unmarshal Response",
- fmtAttemptCount(r.RetryCount, r.MaxRetries()),
- r.Error)
- return r.Error
- }
-
- return nil
-}
-
-// copy will copy a request which will allow for local manipulation of the
-// request.
-func (r *Request) copy() *Request {
- req := &Request{}
- *req = *r
- req.Handlers = r.Handlers.Copy()
- op := *r.Operation
- req.Operation = &op
- return req
-}
-
-// AddToUserAgent adds the string to the end of the request's current user agent.
-func AddToUserAgent(r *Request, s string) {
- curUA := r.HTTPRequest.Header.Get("User-Agent")
- if len(curUA) > 0 {
- s = curUA + " " + s
- }
- r.HTTPRequest.Header.Set("User-Agent", s)
-}
-
-// SanitizeHostForHeader removes default port from host and updates request.Host
-func SanitizeHostForHeader(r *http.Request) {
- host := getHost(r)
- port := portOnly(host)
- if port != "" && isDefaultPort(r.URL.Scheme, port) {
- r.Host = stripPort(host)
- }
-}
-
-// Returns host from request
-func getHost(r *http.Request) string {
- if r.Host != "" {
- return r.Host
- }
-
- if r.URL == nil {
- return ""
- }
-
- return r.URL.Host
-}
-
-// Hostname returns u.Host, without any port number.
-//
-// If Host is an IPv6 literal with a port number, Hostname returns the
-// IPv6 literal without the square brackets. IPv6 literals may include
-// a zone identifier.
-//
-// Copied from the Go 1.8 standard library (net/url)
-func stripPort(hostport string) string {
- colon := strings.IndexByte(hostport, ':')
- if colon == -1 {
- return hostport
- }
- if i := strings.IndexByte(hostport, ']'); i != -1 {
- return strings.TrimPrefix(hostport[:i], "[")
- }
- return hostport[:colon]
-}
-
-// Port returns the port part of u.Host, without the leading colon.
-// If u.Host doesn't contain a port, Port returns an empty string.
-//
-// Copied from the Go 1.8 standard library (net/url)
-func portOnly(hostport string) string {
- colon := strings.IndexByte(hostport, ':')
- if colon == -1 {
- return ""
- }
- if i := strings.Index(hostport, "]:"); i != -1 {
- return hostport[i+len("]:"):]
- }
- if strings.Contains(hostport, "]") {
- return ""
- }
- return hostport[colon+len(":"):]
-}
-
-// Returns true if the specified URI is using the standard port
-// (i.e. port 80 for HTTP URIs or 443 for HTTPS URIs)
-func isDefaultPort(scheme, port string) bool {
- if port == "" {
- return true
- }
-
- lowerCaseScheme := strings.ToLower(scheme)
- if (lowerCaseScheme == "http" && port == "80") || (lowerCaseScheme == "https" && port == "443") {
- return true
- }
-
- return false
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/request_1_7.go b/vendor/github.com/aws/aws-sdk-go/aws/request/request_1_7.go
deleted file mode 100644
index e36e468b7c61..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request_1_7.go
+++ /dev/null
@@ -1,39 +0,0 @@
-// +build !go1.8
-
-package request
-
-import "io"
-
-// NoBody is an io.ReadCloser with no bytes. Read always returns EOF
-// and Close always returns nil. It can be used in an outgoing client
-// request to explicitly signal that a request has zero bytes.
-// An alternative, however, is to simply set Request.Body to nil.
-//
-// Copy of Go 1.8 NoBody type from net/http/http.go
-type noBody struct{}
-
-func (noBody) Read([]byte) (int, error) { return 0, io.EOF }
-func (noBody) Close() error { return nil }
-func (noBody) WriteTo(io.Writer) (int64, error) { return 0, nil }
-
-// NoBody is an empty reader that will trigger the Go HTTP client to not include
-// and body in the HTTP request.
-var NoBody = noBody{}
-
-// ResetBody rewinds the request body back to its starting position, and
-// sets the HTTP Request body reference. When the body is read prior
-// to being sent in the HTTP request it will need to be rewound.
-//
-// ResetBody will automatically be called by the SDK's build handler, but if
-// the request is being used directly ResetBody must be called before the request
-// is Sent. SetStringBody, SetBufferBody, and SetReaderBody will automatically
-// call ResetBody.
-func (r *Request) ResetBody() {
- body, err := r.getNextRequestBody()
- if err != nil {
- r.Error = err
- return
- }
-
- r.HTTPRequest.Body = body
-}
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
deleted file mode 100644
index de1292f45a23..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request_1_8.go
+++ /dev/null
@@ -1,36 +0,0 @@
-// +build go1.8
-
-package request
-
-import (
- "net/http"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-// NoBody is a http.NoBody reader instructing Go HTTP client to not include
-// and body in the HTTP request.
-var NoBody = http.NoBody
-
-// ResetBody rewinds the request body back to its starting position, and
-// sets the HTTP Request body reference. When the body is read prior
-// to being sent in the HTTP request it will need to be rewound.
-//
-// ResetBody will automatically be called by the SDK's build handler, but if
-// the request is being used directly ResetBody must be called before the request
-// is Sent. SetStringBody, SetBufferBody, and SetReaderBody will automatically
-// call ResetBody.
-//
-// Will also set the Go 1.8's http.Request.GetBody member to allow retrying
-// PUT/POST redirects.
-func (r *Request) ResetBody() {
- body, err := r.getNextRequestBody()
- if err != nil {
- r.Error = awserr.New(ErrCodeSerialization,
- "failed to reset request body", err)
- return
- }
-
- r.HTTPRequest.Body = body
- r.HTTPRequest.GetBody = r.getNextRequestBody
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/request_context.go b/vendor/github.com/aws/aws-sdk-go/aws/request/request_context.go
deleted file mode 100644
index a7365cd1e46e..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request_context.go
+++ /dev/null
@@ -1,14 +0,0 @@
-// +build go1.7
-
-package request
-
-import "github.com/aws/aws-sdk-go/aws"
-
-// setContext updates the Request to use the passed in context for cancellation.
-// Context will also be used for request retry delay.
-//
-// Creates shallow copy of the http.Request with the WithContext method.
-func setRequestContext(r *Request, ctx aws.Context) {
- r.context = ctx
- r.HTTPRequest = r.HTTPRequest.WithContext(ctx)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/request_context_1_6.go b/vendor/github.com/aws/aws-sdk-go/aws/request/request_context_1_6.go
deleted file mode 100644
index 307fa0705be6..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request_context_1_6.go
+++ /dev/null
@@ -1,14 +0,0 @@
-// +build !go1.7
-
-package request
-
-import "github.com/aws/aws-sdk-go/aws"
-
-// setContext updates the Request to use the passed in context for cancellation.
-// Context will also be used for request retry delay.
-//
-// Creates shallow copy of the http.Request with the WithContext method.
-func setRequestContext(r *Request, ctx aws.Context) {
- r.context = ctx
- r.HTTPRequest.Cancel = ctx.Done()
-}
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
deleted file mode 100644
index 64784e16f3de..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request_pagination.go
+++ /dev/null
@@ -1,266 +0,0 @@
-package request
-
-import (
- "reflect"
- "sync/atomic"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awsutil"
-)
-
-// A Pagination provides paginating of SDK API operations which are paginatable.
-// Generally you should not use this type directly, but use the "Pages" API
-// operations method to automatically perform pagination for you. Such as,
-// "S3.ListObjectsPages", and "S3.ListObjectsPagesWithContext" methods.
-//
-// Pagination differs from a Paginator type in that pagination is the type that
-// does the pagination between API operations, and Paginator defines the
-// configuration that will be used per page request.
-//
-// for p.Next() {
-// data := p.Page().(*s3.ListObjectsOutput)
-// // process the page's data
-// // ...
-// // break out of loop to stop fetching additional pages
-// }
-//
-// return p.Err()
-//
-// See service client API operation Pages methods for examples how the SDK will
-// use the Pagination type.
-type Pagination struct {
- // Function to return a Request value for each pagination request.
- // Any configuration or handlers that need to be applied to the request
- // prior to getting the next page should be done here before the request
- // returned.
- //
- // NewRequest should always be built from the same API operations. It is
- // undefined if different API operations are returned on subsequent calls.
- NewRequest func() (*Request, error)
- // EndPageOnSameToken, when enabled, will allow the paginator to stop on
- // token that are the same as its previous tokens.
- EndPageOnSameToken bool
-
- started bool
- prevTokens []interface{}
- nextTokens []interface{}
-
- err error
- curPage interface{}
-}
-
-// HasNextPage will return true if Pagination is able to determine that the API
-// operation has additional pages. False will be returned if there are no more
-// pages remaining.
-//
-// Will always return true if Next has not been called yet.
-func (p *Pagination) HasNextPage() bool {
- if !p.started {
- return true
- }
-
- hasNextPage := len(p.nextTokens) != 0
- if p.EndPageOnSameToken {
- return hasNextPage && !awsutil.DeepEqual(p.nextTokens, p.prevTokens)
- }
- return hasNextPage
-}
-
-// Err returns the error Pagination encountered when retrieving the next page.
-func (p *Pagination) Err() error {
- return p.err
-}
-
-// Page returns the current page. Page should only be called after a successful
-// call to Next. It is undefined what Page will return if Page is called after
-// Next returns false.
-func (p *Pagination) Page() interface{} {
- return p.curPage
-}
-
-// Next will attempt to retrieve the next page for the API operation. When a page
-// is retrieved true will be returned. If the page cannot be retrieved, or there
-// are no more pages false will be returned.
-//
-// Use the Page method to retrieve the current page data. The data will need
-// to be cast to the API operation's output type.
-//
-// Use the Err method to determine if an error occurred if Page returns false.
-func (p *Pagination) Next() bool {
- if !p.HasNextPage() {
- return false
- }
-
- req, err := p.NewRequest()
- if err != nil {
- p.err = err
- return false
- }
-
- if p.started {
- for i, intok := range req.Operation.InputTokens {
- awsutil.SetValueAtPath(req.Params, intok, p.nextTokens[i])
- }
- }
- p.started = true
-
- err = req.Send()
- if err != nil {
- p.err = err
- return false
- }
-
- p.prevTokens = p.nextTokens
- p.nextTokens = req.nextPageTokens()
- p.curPage = req.Data
-
- return true
-}
-
-// A Paginator is the configuration data that defines how an API operation
-// should be paginated. This type is used by the API service models to define
-// the generated pagination config for service APIs.
-//
-// The Pagination type is what provides iterating between pages of an API. It
-// is only used to store the token metadata the SDK should use for performing
-// pagination.
-type Paginator struct {
- InputTokens []string
- OutputTokens []string
- LimitToken string
- TruncationToken string
-}
-
-// nextPageTokens returns the tokens to use when asking for the next page of data.
-func (r *Request) nextPageTokens() []interface{} {
- if r.Operation.Paginator == nil {
- return nil
- }
- if r.Operation.TruncationToken != "" {
- tr, _ := awsutil.ValuesAtPath(r.Data, r.Operation.TruncationToken)
- if len(tr) == 0 {
- return nil
- }
-
- switch v := tr[0].(type) {
- case *bool:
- if !aws.BoolValue(v) {
- return nil
- }
- case bool:
- if !v {
- return nil
- }
- }
- }
-
- tokens := []interface{}{}
- tokenAdded := false
- for _, outToken := range r.Operation.OutputTokens {
- vs, _ := awsutil.ValuesAtPath(r.Data, outToken)
- if len(vs) == 0 {
- tokens = append(tokens, nil)
- continue
- }
- v := vs[0]
-
- switch tv := v.(type) {
- case *string:
- if len(aws.StringValue(tv)) == 0 {
- tokens = append(tokens, nil)
- continue
- }
- case string:
- if len(tv) == 0 {
- tokens = append(tokens, nil)
- continue
- }
- }
-
- tokenAdded = true
- tokens = append(tokens, v)
- }
- if !tokenAdded {
- return nil
- }
-
- return tokens
-}
-
-// Ensure a deprecated item is only logged once instead of each time its used.
-func logDeprecatedf(logger aws.Logger, flag *int32, msg string) {
- if logger == nil {
- return
- }
- if atomic.CompareAndSwapInt32(flag, 0, 1) {
- logger.Log(msg)
- }
-}
-
-var (
- logDeprecatedHasNextPage int32
- logDeprecatedNextPage int32
- logDeprecatedEachPage int32
-)
-
-// HasNextPage returns true if this request has more pages of data available.
-//
-// Deprecated Use Pagination type for configurable pagination of API operations
-func (r *Request) HasNextPage() bool {
- logDeprecatedf(r.Config.Logger, &logDeprecatedHasNextPage,
- "Request.HasNextPage deprecated. Use Pagination type for configurable pagination of API operations")
-
- return len(r.nextPageTokens()) > 0
-}
-
-// NextPage returns a new Request that can be executed to return the next
-// page of result data. Call .Send() on this request to execute it.
-//
-// Deprecated Use Pagination type for configurable pagination of API operations
-func (r *Request) NextPage() *Request {
- logDeprecatedf(r.Config.Logger, &logDeprecatedNextPage,
- "Request.NextPage deprecated. Use Pagination type for configurable pagination of API operations")
-
- tokens := r.nextPageTokens()
- if len(tokens) == 0 {
- return nil
- }
-
- data := reflect.New(reflect.TypeOf(r.Data).Elem()).Interface()
- nr := New(r.Config, r.ClientInfo, r.Handlers, r.Retryer, r.Operation, awsutil.CopyOf(r.Params), data)
- for i, intok := range nr.Operation.InputTokens {
- awsutil.SetValueAtPath(nr.Params, intok, tokens[i])
- }
- return nr
-}
-
-// EachPage iterates over each page of a paginated request object. The fn
-// parameter should be a function with the following sample signature:
-//
-// func(page *T, lastPage bool) bool {
-// return true // return false to stop iterating
-// }
-//
-// Where "T" is the structure type matching the output structure of the given
-// operation. For example, a request object generated by
-// DynamoDB.ListTablesRequest() would expect to see dynamodb.ListTablesOutput
-// as the structure "T". The lastPage value represents whether the page is
-// the last page of data or not. The return value of this function should
-// return true to keep iterating or false to stop.
-//
-// Deprecated Use Pagination type for configurable pagination of API operations
-func (r *Request) EachPage(fn func(data interface{}, isLastPage bool) (shouldContinue bool)) error {
- logDeprecatedf(r.Config.Logger, &logDeprecatedEachPage,
- "Request.EachPage deprecated. Use Pagination type for configurable pagination of API operations")
-
- for page := r; page != nil; page = page.NextPage() {
- if err := page.Send(); err != nil {
- return err
- }
- if getNextPage := fn(page.Data, !page.HasNextPage()); !getNextPage {
- return page.Error
- }
- }
-
- return nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go b/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go
deleted file mode 100644
index 752ae47f8459..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go
+++ /dev/null
@@ -1,309 +0,0 @@
-package request
-
-import (
- "net"
- "net/url"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-// Retryer provides the interface drive the SDK's request retry behavior. The
-// Retryer implementation is responsible for implementing exponential backoff,
-// and determine if a request API error should be retried.
-//
-// client.DefaultRetryer is the SDK's default implementation of the Retryer. It
-// uses the which uses the Request.IsErrorRetryable and Request.IsErrorThrottle
-// methods to determine if the request is retried.
-type Retryer interface {
- // RetryRules return the retry delay that should be used by the SDK before
- // making another request attempt for the failed request.
- RetryRules(*Request) time.Duration
-
- // ShouldRetry returns if the failed request is retryable.
- //
- // Implementations may consider request attempt count when determining if a
- // request is retryable, but the SDK will use MaxRetries to limit the
- // number of attempts a request are made.
- ShouldRetry(*Request) bool
-
- // MaxRetries is the number of times a request may be retried before
- // failing.
- MaxRetries() int
-}
-
-// WithRetryer sets a Retryer value to the given Config returning the Config
-// value for chaining. The value must not be nil.
-func WithRetryer(cfg *aws.Config, retryer Retryer) *aws.Config {
- if retryer == nil {
- if cfg.Logger != nil {
- cfg.Logger.Log("ERROR: Request.WithRetryer called with nil retryer. Replacing with retry disabled Retryer.")
- }
- retryer = noOpRetryer{}
- }
- cfg.Retryer = retryer
- return cfg
-
-}
-
-// noOpRetryer is a internal no op retryer used when a request is created
-// without a retryer.
-//
-// Provides a retryer that performs no retries.
-// It should be used when we do not want retries to be performed.
-type noOpRetryer struct{}
-
-// MaxRetries returns the number of maximum returns the service will use to make
-// an individual API; For NoOpRetryer the MaxRetries will always be zero.
-func (d noOpRetryer) MaxRetries() int {
- return 0
-}
-
-// ShouldRetry will always return false for NoOpRetryer, as it should never retry.
-func (d noOpRetryer) ShouldRetry(_ *Request) bool {
- return false
-}
-
-// RetryRules returns the delay duration before retrying this request again;
-// since NoOpRetryer does not retry, RetryRules always returns 0.
-func (d noOpRetryer) RetryRules(_ *Request) time.Duration {
- return 0
-}
-
-// retryableCodes is a collection of service response codes which are retry-able
-// without any further action.
-var retryableCodes = map[string]struct{}{
- ErrCodeRequestError: {},
- "RequestTimeout": {},
- ErrCodeResponseTimeout: {},
- "RequestTimeoutException": {}, // Glacier's flavor of RequestTimeout
-}
-
-var throttleCodes = map[string]struct{}{
- "ProvisionedThroughputExceededException": {},
- "ThrottledException": {}, // SNS, XRay, ResourceGroupsTagging API
- "Throttling": {},
- "ThrottlingException": {},
- "RequestLimitExceeded": {},
- "RequestThrottled": {},
- "RequestThrottledException": {},
- "TooManyRequestsException": {}, // Lambda functions
- "PriorRequestNotComplete": {}, // Route53
- "TransactionInProgressException": {},
- "EC2ThrottledException": {}, // EC2
-}
-
-// credsExpiredCodes is a collection of error codes which signify the credentials
-// need to be refreshed. Expired tokens require refreshing of credentials, and
-// resigning before the request can be retried.
-var credsExpiredCodes = map[string]struct{}{
- "ExpiredToken": {},
- "ExpiredTokenException": {},
- "RequestExpired": {}, // EC2 Only
-}
-
-func isCodeThrottle(code string) bool {
- _, ok := throttleCodes[code]
- return ok
-}
-
-func isCodeRetryable(code string) bool {
- if _, ok := retryableCodes[code]; ok {
- return true
- }
-
- return isCodeExpiredCreds(code)
-}
-
-func isCodeExpiredCreds(code string) bool {
- _, ok := credsExpiredCodes[code]
- return ok
-}
-
-var validParentCodes = map[string]struct{}{
- ErrCodeSerialization: {},
- ErrCodeRead: {},
-}
-
-func isNestedErrorRetryable(parentErr awserr.Error) bool {
- if parentErr == nil {
- return false
- }
-
- if _, ok := validParentCodes[parentErr.Code()]; !ok {
- return false
- }
-
- err := parentErr.OrigErr()
- if err == nil {
- return false
- }
-
- if aerr, ok := err.(awserr.Error); ok {
- return isCodeRetryable(aerr.Code())
- }
-
- if t, ok := err.(temporary); ok {
- return t.Temporary() || isErrConnectionReset(err)
- }
-
- return isErrConnectionReset(err)
-}
-
-// IsErrorRetryable returns whether the error is retryable, based on its Code.
-// Returns false if error is nil.
-func IsErrorRetryable(err error) bool {
- if err == nil {
- return false
- }
- return shouldRetryError(err)
-}
-
-type temporary interface {
- Temporary() bool
-}
-
-func shouldRetryError(origErr error) bool {
- switch err := origErr.(type) {
- case awserr.Error:
- if err.Code() == CanceledErrorCode {
- return false
- }
- if isNestedErrorRetryable(err) {
- return true
- }
-
- origErr := err.OrigErr()
- var shouldRetry bool
- if origErr != nil {
- shouldRetry = shouldRetryError(origErr)
- if err.Code() == ErrCodeRequestError && !shouldRetry {
- return false
- }
- }
- if isCodeRetryable(err.Code()) {
- return true
- }
- return shouldRetry
-
- case *url.Error:
- if strings.Contains(err.Error(), "connection refused") {
- // Refused connections should be retried as the service may not yet
- // be running on the port. Go TCP dial considers refused
- // connections as not temporary.
- return true
- }
- // *url.Error only implements Temporary after golang 1.6 but since
- // url.Error only wraps the error:
- return shouldRetryError(err.Err)
-
- case temporary:
- if netErr, ok := err.(*net.OpError); ok && netErr.Op == "dial" {
- return true
- }
- // If the error is temporary, we want to allow continuation of the
- // retry process
- return err.Temporary() || isErrConnectionReset(origErr)
-
- case nil:
- // `awserr.Error.OrigErr()` can be nil, meaning there was an error but
- // because we don't know the cause, it is marked as retryable. See
- // TestRequest4xxUnretryable for an example.
- return true
-
- default:
- switch err.Error() {
- case "net/http: request canceled",
- "net/http: request canceled while waiting for connection":
- // known 1.5 error case when an http request is cancelled
- return false
- }
- // here we don't know the error; so we allow a retry.
- return true
- }
-}
-
-// IsErrorThrottle returns whether the error is to be throttled based on its code.
-// Returns false if error is nil.
-func IsErrorThrottle(err error) bool {
- if aerr, ok := err.(awserr.Error); ok && aerr != nil {
- return isCodeThrottle(aerr.Code())
- }
- return false
-}
-
-// IsErrorExpiredCreds returns whether the error code is a credential expiry
-// error. Returns false if error is nil.
-func IsErrorExpiredCreds(err error) bool {
- if aerr, ok := err.(awserr.Error); ok && aerr != nil {
- return isCodeExpiredCreds(aerr.Code())
- }
- return false
-}
-
-// IsErrorRetryable returns whether the error is retryable, based on its Code.
-// Returns false if the request has no Error set.
-//
-// Alias for the utility function IsErrorRetryable
-func (r *Request) IsErrorRetryable() bool {
- if isErrCode(r.Error, r.RetryErrorCodes) {
- return true
- }
-
- // HTTP response status code 501 should not be retried.
- // 501 represents Not Implemented which means the request method is not
- // supported by the server and cannot be handled.
- if r.HTTPResponse != nil {
- // HTTP response status code 500 represents internal server error and
- // should be retried without any throttle.
- if r.HTTPResponse.StatusCode == 500 {
- return true
- }
- }
- return IsErrorRetryable(r.Error)
-}
-
-// IsErrorThrottle returns whether the error is to be throttled based on its
-// code. Returns false if the request has no Error set.
-//
-// Alias for the utility function IsErrorThrottle
-func (r *Request) IsErrorThrottle() bool {
- if isErrCode(r.Error, r.ThrottleErrorCodes) {
- return true
- }
-
- if r.HTTPResponse != nil {
- switch r.HTTPResponse.StatusCode {
- case
- 429, // error caused due to too many requests
- 502, // Bad Gateway error should be throttled
- 503, // caused when service is unavailable
- 504: // error occurred due to gateway timeout
- return true
- }
- }
-
- return IsErrorThrottle(r.Error)
-}
-
-func isErrCode(err error, codes []string) bool {
- if aerr, ok := err.(awserr.Error); ok && aerr != nil {
- for _, code := range codes {
- if code == aerr.Code() {
- return true
- }
- }
- }
-
- return false
-}
-
-// IsErrorExpired returns whether the error code is a credential expiry error.
-// Returns false if the request has no Error set.
-//
-// Alias for the utility function IsErrorExpiredCreds
-func (r *Request) IsErrorExpired() bool {
- return IsErrorExpiredCreds(r.Error)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/timeout_read_closer.go b/vendor/github.com/aws/aws-sdk-go/aws/request/timeout_read_closer.go
deleted file mode 100644
index 09a44eb987ac..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/timeout_read_closer.go
+++ /dev/null
@@ -1,94 +0,0 @@
-package request
-
-import (
- "io"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-var timeoutErr = awserr.New(
- ErrCodeResponseTimeout,
- "read on body has reached the timeout limit",
- nil,
-)
-
-type readResult struct {
- n int
- err error
-}
-
-// timeoutReadCloser will handle body reads that take too long.
-// We will return a ErrReadTimeout error if a timeout occurs.
-type timeoutReadCloser struct {
- reader io.ReadCloser
- duration time.Duration
-}
-
-// Read will spin off a goroutine to call the reader's Read method. We will
-// select on the timer's channel or the read's channel. Whoever completes first
-// will be returned.
-func (r *timeoutReadCloser) Read(b []byte) (int, error) {
- timer := time.NewTimer(r.duration)
- c := make(chan readResult, 1)
-
- go func() {
- n, err := r.reader.Read(b)
- timer.Stop()
- c <- readResult{n: n, err: err}
- }()
-
- select {
- case data := <-c:
- return data.n, data.err
- case <-timer.C:
- return 0, timeoutErr
- }
-}
-
-func (r *timeoutReadCloser) Close() error {
- return r.reader.Close()
-}
-
-const (
- // HandlerResponseTimeout is what we use to signify the name of the
- // response timeout handler.
- HandlerResponseTimeout = "ResponseTimeoutHandler"
-)
-
-// adaptToResponseTimeoutError is a handler that will replace any top level error
-// to a ErrCodeResponseTimeout, if its child is that.
-func adaptToResponseTimeoutError(req *Request) {
- if err, ok := req.Error.(awserr.Error); ok {
- aerr, ok := err.OrigErr().(awserr.Error)
- if ok && aerr.Code() == ErrCodeResponseTimeout {
- req.Error = aerr
- }
- }
-}
-
-// WithResponseReadTimeout is a request option that will wrap the body in a timeout read closer.
-// This will allow for per read timeouts. If a timeout occurred, we will return the
-// ErrCodeResponseTimeout.
-//
-// svc.PutObjectWithContext(ctx, params, request.WithTimeoutReadCloser(30 * time.Second)
-func WithResponseReadTimeout(duration time.Duration) Option {
- return func(r *Request) {
-
- var timeoutHandler = NamedHandler{
- HandlerResponseTimeout,
- func(req *Request) {
- req.HTTPResponse.Body = &timeoutReadCloser{
- reader: req.HTTPResponse.Body,
- duration: duration,
- }
- }}
-
- // remove the handler so we are not stomping over any new durations.
- r.Handlers.Send.RemoveByName(HandlerResponseTimeout)
- r.Handlers.Send.PushBackNamed(timeoutHandler)
-
- r.Handlers.Unmarshal.PushBack(adaptToResponseTimeoutError)
- r.Handlers.UnmarshalError.PushBack(adaptToResponseTimeoutError)
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go b/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go
deleted file mode 100644
index 8630683f3174..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go
+++ /dev/null
@@ -1,286 +0,0 @@
-package request
-
-import (
- "bytes"
- "fmt"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
-)
-
-const (
- // InvalidParameterErrCode is the error code for invalid parameters errors
- InvalidParameterErrCode = "InvalidParameter"
- // ParamRequiredErrCode is the error code for required parameter errors
- ParamRequiredErrCode = "ParamRequiredError"
- // ParamMinValueErrCode is the error code for fields with too low of a
- // number value.
- ParamMinValueErrCode = "ParamMinValueError"
- // ParamMinLenErrCode is the error code for fields without enough elements.
- ParamMinLenErrCode = "ParamMinLenError"
- // ParamMaxLenErrCode is the error code for value being too long.
- ParamMaxLenErrCode = "ParamMaxLenError"
-
- // ParamFormatErrCode is the error code for a field with invalid
- // format or characters.
- ParamFormatErrCode = "ParamFormatInvalidError"
-)
-
-// Validator provides a way for types to perform validation logic on their
-// input values that external code can use to determine if a type's values
-// are valid.
-type Validator interface {
- Validate() error
-}
-
-// An ErrInvalidParams provides wrapping of invalid parameter errors found when
-// validating API operation input parameters.
-type ErrInvalidParams struct {
- // Context is the base context of the invalid parameter group.
- Context string
- errs []ErrInvalidParam
-}
-
-// Add adds a new invalid parameter error to the collection of invalid
-// parameters. The context of the invalid parameter will be updated to reflect
-// this collection.
-func (e *ErrInvalidParams) Add(err ErrInvalidParam) {
- err.SetContext(e.Context)
- e.errs = append(e.errs, err)
-}
-
-// AddNested adds the invalid parameter errors from another ErrInvalidParams
-// value into this collection. The nested errors will have their nested context
-// updated and base context to reflect the merging.
-//
-// Use for nested validations errors.
-func (e *ErrInvalidParams) AddNested(nestedCtx string, nested ErrInvalidParams) {
- for _, err := range nested.errs {
- err.SetContext(e.Context)
- err.AddNestedContext(nestedCtx)
- e.errs = append(e.errs, err)
- }
-}
-
-// Len returns the number of invalid parameter errors
-func (e ErrInvalidParams) Len() int {
- return len(e.errs)
-}
-
-// Code returns the code of the error
-func (e ErrInvalidParams) Code() string {
- return InvalidParameterErrCode
-}
-
-// Message returns the message of the error
-func (e ErrInvalidParams) Message() string {
- return fmt.Sprintf("%d validation error(s) found.", len(e.errs))
-}
-
-// Error returns the string formatted form of the invalid parameters.
-func (e ErrInvalidParams) Error() string {
- w := &bytes.Buffer{}
- fmt.Fprintf(w, "%s: %s\n", e.Code(), e.Message())
-
- for _, err := range e.errs {
- fmt.Fprintf(w, "- %s\n", err.Message())
- }
-
- return w.String()
-}
-
-// OrigErr returns the invalid parameters as a awserr.BatchedErrors value
-func (e ErrInvalidParams) OrigErr() error {
- return awserr.NewBatchError(
- InvalidParameterErrCode, e.Message(), e.OrigErrs())
-}
-
-// OrigErrs returns a slice of the invalid parameters
-func (e ErrInvalidParams) OrigErrs() []error {
- errs := make([]error, len(e.errs))
- for i := 0; i < len(errs); i++ {
- errs[i] = e.errs[i]
- }
-
- return errs
-}
-
-// An ErrInvalidParam represents an invalid parameter error type.
-type ErrInvalidParam interface {
- awserr.Error
-
- // Field name the error occurred on.
- Field() string
-
- // SetContext updates the context of the error.
- SetContext(string)
-
- // AddNestedContext updates the error's context to include a nested level.
- AddNestedContext(string)
-}
-
-type errInvalidParam struct {
- context string
- nestedContext string
- field string
- code string
- msg string
-}
-
-// Code returns the error code for the type of invalid parameter.
-func (e *errInvalidParam) Code() string {
- return e.code
-}
-
-// Message returns the reason the parameter was invalid, and its context.
-func (e *errInvalidParam) Message() string {
- return fmt.Sprintf("%s, %s.", e.msg, e.Field())
-}
-
-// Error returns the string version of the invalid parameter error.
-func (e *errInvalidParam) Error() string {
- return fmt.Sprintf("%s: %s", e.code, e.Message())
-}
-
-// OrigErr returns nil, Implemented for awserr.Error interface.
-func (e *errInvalidParam) OrigErr() error {
- return nil
-}
-
-// Field Returns the field and context the error occurred.
-func (e *errInvalidParam) Field() string {
- field := e.context
- if len(field) > 0 {
- field += "."
- }
- if len(e.nestedContext) > 0 {
- field += fmt.Sprintf("%s.", e.nestedContext)
- }
- field += e.field
-
- return field
-}
-
-// SetContext updates the base context of the error.
-func (e *errInvalidParam) SetContext(ctx string) {
- e.context = ctx
-}
-
-// AddNestedContext prepends a context to the field's path.
-func (e *errInvalidParam) AddNestedContext(ctx string) {
- if len(e.nestedContext) == 0 {
- e.nestedContext = ctx
- } else {
- e.nestedContext = fmt.Sprintf("%s.%s", ctx, e.nestedContext)
- }
-
-}
-
-// An ErrParamRequired represents an required parameter error.
-type ErrParamRequired struct {
- errInvalidParam
-}
-
-// NewErrParamRequired creates a new required parameter error.
-func NewErrParamRequired(field string) *ErrParamRequired {
- return &ErrParamRequired{
- errInvalidParam{
- code: ParamRequiredErrCode,
- field: field,
- msg: fmt.Sprintf("missing required field"),
- },
- }
-}
-
-// An ErrParamMinValue represents a minimum value parameter error.
-type ErrParamMinValue struct {
- errInvalidParam
- min float64
-}
-
-// NewErrParamMinValue creates a new minimum value parameter error.
-func NewErrParamMinValue(field string, min float64) *ErrParamMinValue {
- return &ErrParamMinValue{
- errInvalidParam: errInvalidParam{
- code: ParamMinValueErrCode,
- field: field,
- msg: fmt.Sprintf("minimum field value of %v", min),
- },
- min: min,
- }
-}
-
-// MinValue returns the field's require minimum value.
-//
-// float64 is returned for both int and float min values.
-func (e *ErrParamMinValue) MinValue() float64 {
- return e.min
-}
-
-// An ErrParamMinLen represents a minimum length parameter error.
-type ErrParamMinLen struct {
- errInvalidParam
- min int
-}
-
-// NewErrParamMinLen creates a new minimum length parameter error.
-func NewErrParamMinLen(field string, min int) *ErrParamMinLen {
- return &ErrParamMinLen{
- errInvalidParam: errInvalidParam{
- code: ParamMinLenErrCode,
- field: field,
- msg: fmt.Sprintf("minimum field size of %v", min),
- },
- min: min,
- }
-}
-
-// MinLen returns the field's required minimum length.
-func (e *ErrParamMinLen) MinLen() int {
- return e.min
-}
-
-// An ErrParamMaxLen represents a maximum length parameter error.
-type ErrParamMaxLen struct {
- errInvalidParam
- max int
-}
-
-// NewErrParamMaxLen creates a new maximum length parameter error.
-func NewErrParamMaxLen(field string, max int, value string) *ErrParamMaxLen {
- return &ErrParamMaxLen{
- errInvalidParam: errInvalidParam{
- code: ParamMaxLenErrCode,
- field: field,
- msg: fmt.Sprintf("maximum size of %v, %v", max, value),
- },
- max: max,
- }
-}
-
-// MaxLen returns the field's required minimum length.
-func (e *ErrParamMaxLen) MaxLen() int {
- return e.max
-}
-
-// An ErrParamFormat represents a invalid format parameter error.
-type ErrParamFormat struct {
- errInvalidParam
- format string
-}
-
-// NewErrParamFormat creates a new invalid format parameter error.
-func NewErrParamFormat(field string, format, value string) *ErrParamFormat {
- return &ErrParamFormat{
- errInvalidParam: errInvalidParam{
- code: ParamFormatErrCode,
- field: field,
- msg: fmt.Sprintf("format %v, %v", format, value),
- },
- format: format,
- }
-}
-
-// Format returns the field's required format.
-func (e *ErrParamFormat) Format() string {
- return e.format
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/waiter.go b/vendor/github.com/aws/aws-sdk-go/aws/request/waiter.go
deleted file mode 100644
index 4601f883cc51..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/waiter.go
+++ /dev/null
@@ -1,295 +0,0 @@
-package request
-
-import (
- "fmt"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/awsutil"
-)
-
-// WaiterResourceNotReadyErrorCode is the error code returned by a waiter when
-// the waiter's max attempts have been exhausted.
-const WaiterResourceNotReadyErrorCode = "ResourceNotReady"
-
-// A WaiterOption is a function that will update the Waiter value's fields to
-// configure the waiter.
-type WaiterOption func(*Waiter)
-
-// WithWaiterMaxAttempts returns the maximum number of times the waiter should
-// attempt to check the resource for the target state.
-func WithWaiterMaxAttempts(max int) WaiterOption {
- return func(w *Waiter) {
- w.MaxAttempts = max
- }
-}
-
-// WaiterDelay will return a delay the waiter should pause between attempts to
-// check the resource state. The passed in attempt is the number of times the
-// Waiter has checked the resource state.
-//
-// Attempt is the number of attempts the Waiter has made checking the resource
-// state.
-type WaiterDelay func(attempt int) time.Duration
-
-// ConstantWaiterDelay returns a WaiterDelay that will always return a constant
-// delay the waiter should use between attempts. It ignores the number of
-// attempts made.
-func ConstantWaiterDelay(delay time.Duration) WaiterDelay {
- return func(attempt int) time.Duration {
- return delay
- }
-}
-
-// WithWaiterDelay will set the Waiter to use the WaiterDelay passed in.
-func WithWaiterDelay(delayer WaiterDelay) WaiterOption {
- return func(w *Waiter) {
- w.Delay = delayer
- }
-}
-
-// WithWaiterLogger returns a waiter option to set the logger a waiter
-// should use to log warnings and errors to.
-func WithWaiterLogger(logger aws.Logger) WaiterOption {
- return func(w *Waiter) {
- w.Logger = logger
- }
-}
-
-// WithWaiterRequestOptions returns a waiter option setting the request
-// options for each request the waiter makes. Appends to waiter's request
-// options already set.
-func WithWaiterRequestOptions(opts ...Option) WaiterOption {
- return func(w *Waiter) {
- w.RequestOptions = append(w.RequestOptions, opts...)
- }
-}
-
-// A Waiter provides the functionality to perform a blocking call which will
-// wait for a resource state to be satisfied by a service.
-//
-// This type should not be used directly. The API operations provided in the
-// service packages prefixed with "WaitUntil" should be used instead.
-type Waiter struct {
- Name string
- Acceptors []WaiterAcceptor
- Logger aws.Logger
-
- MaxAttempts int
- Delay WaiterDelay
-
- RequestOptions []Option
- NewRequest func([]Option) (*Request, error)
- SleepWithContext func(aws.Context, time.Duration) error
-}
-
-// ApplyOptions updates the waiter with the list of waiter options provided.
-func (w *Waiter) ApplyOptions(opts ...WaiterOption) {
- for _, fn := range opts {
- fn(w)
- }
-}
-
-// WaiterState are states the waiter uses based on WaiterAcceptor definitions
-// to identify if the resource state the waiter is waiting on has occurred.
-type WaiterState int
-
-// String returns the string representation of the waiter state.
-func (s WaiterState) String() string {
- switch s {
- case SuccessWaiterState:
- return "success"
- case FailureWaiterState:
- return "failure"
- case RetryWaiterState:
- return "retry"
- default:
- return "unknown waiter state"
- }
-}
-
-// States the waiter acceptors will use to identify target resource states.
-const (
- SuccessWaiterState WaiterState = iota // waiter successful
- FailureWaiterState // waiter failed
- RetryWaiterState // waiter needs to be retried
-)
-
-// WaiterMatchMode is the mode that the waiter will use to match the WaiterAcceptor
-// definition's Expected attribute.
-type WaiterMatchMode int
-
-// Modes the waiter will use when inspecting API response to identify target
-// resource states.
-const (
- PathAllWaiterMatch WaiterMatchMode = iota // match on all paths
- PathWaiterMatch // match on specific path
- PathAnyWaiterMatch // match on any path
- PathListWaiterMatch // match on list of paths
- StatusWaiterMatch // match on status code
- ErrorWaiterMatch // match on error
-)
-
-// String returns the string representation of the waiter match mode.
-func (m WaiterMatchMode) String() string {
- switch m {
- case PathAllWaiterMatch:
- return "pathAll"
- case PathWaiterMatch:
- return "path"
- case PathAnyWaiterMatch:
- return "pathAny"
- case PathListWaiterMatch:
- return "pathList"
- case StatusWaiterMatch:
- return "status"
- case ErrorWaiterMatch:
- return "error"
- default:
- return "unknown waiter match mode"
- }
-}
-
-// WaitWithContext will make requests for the API operation using NewRequest to
-// build API requests. The request's response will be compared against the
-// Waiter's Acceptors to determine the successful state of the resource the
-// waiter is inspecting.
-//
-// The passed in context must not be nil. If it is nil a panic will occur. The
-// Context will be used to cancel the waiter's pending requests and retry delays.
-// Use aws.BackgroundContext if no context is available.
-//
-// The waiter will continue until the target state defined by the Acceptors,
-// or the max attempts expires.
-//
-// Will return the WaiterResourceNotReadyErrorCode error code if the waiter's
-// retryer ShouldRetry returns false. This normally will happen when the max
-// wait attempts expires.
-func (w Waiter) WaitWithContext(ctx aws.Context) error {
-
- for attempt := 1; ; attempt++ {
- req, err := w.NewRequest(w.RequestOptions)
- if err != nil {
- waiterLogf(w.Logger, "unable to create request %v", err)
- return err
- }
- req.Handlers.Build.PushBack(MakeAddToUserAgentFreeFormHandler("Waiter"))
- err = req.Send()
-
- // See if any of the acceptors match the request's response, or error
- for _, a := range w.Acceptors {
- if matched, matchErr := a.match(w.Name, w.Logger, req, err); matched {
- return matchErr
- }
- }
-
- // The Waiter should only check the resource state MaxAttempts times
- // This is here instead of in the for loop above to prevent delaying
- // unnecessary when the waiter will not retry.
- if attempt == w.MaxAttempts {
- break
- }
-
- // Delay to wait before inspecting the resource again
- delay := w.Delay(attempt)
- if sleepFn := req.Config.SleepDelay; sleepFn != nil {
- // Support SleepDelay for backwards compatibility and testing
- sleepFn(delay)
- } else {
- sleepCtxFn := w.SleepWithContext
- if sleepCtxFn == nil {
- sleepCtxFn = aws.SleepWithContext
- }
-
- if err := sleepCtxFn(ctx, delay); err != nil {
- return awserr.New(CanceledErrorCode, "waiter context canceled", err)
- }
- }
- }
-
- return awserr.New(WaiterResourceNotReadyErrorCode, "exceeded wait attempts", nil)
-}
-
-// A WaiterAcceptor provides the information needed to wait for an API operation
-// to complete.
-type WaiterAcceptor struct {
- State WaiterState
- Matcher WaiterMatchMode
- Argument string
- Expected interface{}
-}
-
-// match returns if the acceptor found a match with the passed in request
-// or error. True is returned if the acceptor made a match, error is returned
-// if there was an error attempting to perform the match.
-func (a *WaiterAcceptor) match(name string, l aws.Logger, req *Request, err error) (bool, error) {
- result := false
- var vals []interface{}
-
- switch a.Matcher {
- case PathAllWaiterMatch, PathWaiterMatch:
- // Require all matches to be equal for result to match
- vals, _ = awsutil.ValuesAtPath(req.Data, a.Argument)
- if len(vals) == 0 {
- break
- }
- result = true
- for _, val := range vals {
- if !awsutil.DeepEqual(val, a.Expected) {
- result = false
- break
- }
- }
- case PathAnyWaiterMatch:
- // Only a single match needs to equal for the result to match
- vals, _ = awsutil.ValuesAtPath(req.Data, a.Argument)
- for _, val := range vals {
- if awsutil.DeepEqual(val, a.Expected) {
- result = true
- break
- }
- }
- case PathListWaiterMatch:
- // ignored matcher
- case StatusWaiterMatch:
- s := a.Expected.(int)
- result = s == req.HTTPResponse.StatusCode
- case ErrorWaiterMatch:
- if aerr, ok := err.(awserr.Error); ok {
- result = aerr.Code() == a.Expected.(string)
- }
- default:
- waiterLogf(l, "WARNING: Waiter %s encountered unexpected matcher: %s",
- name, a.Matcher)
- }
-
- if !result {
- // If there was no matching result found there is nothing more to do
- // for this response, retry the request.
- return false, nil
- }
-
- switch a.State {
- case SuccessWaiterState:
- // waiter completed
- return true, nil
- case FailureWaiterState:
- // Waiter failure state triggered
- return true, awserr.New(WaiterResourceNotReadyErrorCode,
- "failed waiting for successful resource state", err)
- case RetryWaiterState:
- // clear the error and retry the operation
- return false, nil
- default:
- waiterLogf(l, "WARNING: Waiter %s encountered unexpected state: %s",
- name, a.State)
- return false, nil
- }
-}
-
-func waiterLogf(logger aws.Logger, msg string, args ...interface{}) {
- if logger != nil {
- logger.Log(fmt.Sprintf(msg, args...))
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport.go b/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport.go
deleted file mode 100644
index ea9ebb6f6a25..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport.go
+++ /dev/null
@@ -1,26 +0,0 @@
-// +build go1.7
-
-package session
-
-import (
- "net"
- "net/http"
- "time"
-)
-
-// Transport that should be used when a custom CA bundle is specified with the
-// SDK.
-func getCABundleTransport() *http.Transport {
- return &http.Transport{
- Proxy: http.ProxyFromEnvironment,
- DialContext: (&net.Dialer{
- Timeout: 30 * time.Second,
- KeepAlive: 30 * time.Second,
- DualStack: true,
- }).DialContext,
- MaxIdleConns: 100,
- IdleConnTimeout: 90 * time.Second,
- TLSHandshakeTimeout: 10 * time.Second,
- ExpectContinueTimeout: 1 * time.Second,
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_5.go b/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_5.go
deleted file mode 100644
index fec39dfc1264..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_5.go
+++ /dev/null
@@ -1,22 +0,0 @@
-// +build !go1.6,go1.5
-
-package session
-
-import (
- "net"
- "net/http"
- "time"
-)
-
-// Transport that should be used when a custom CA bundle is specified with the
-// SDK.
-func getCABundleTransport() *http.Transport {
- return &http.Transport{
- Proxy: http.ProxyFromEnvironment,
- Dial: (&net.Dialer{
- Timeout: 30 * time.Second,
- KeepAlive: 30 * time.Second,
- }).Dial,
- TLSHandshakeTimeout: 10 * time.Second,
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_6.go b/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_6.go
deleted file mode 100644
index 1c5a5391e658..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_6.go
+++ /dev/null
@@ -1,23 +0,0 @@
-// +build !go1.7,go1.6
-
-package session
-
-import (
- "net"
- "net/http"
- "time"
-)
-
-// Transport that should be used when a custom CA bundle is specified with the
-// SDK.
-func getCABundleTransport() *http.Transport {
- return &http.Transport{
- Proxy: http.ProxyFromEnvironment,
- Dial: (&net.Dialer{
- Timeout: 30 * time.Second,
- KeepAlive: 30 * time.Second,
- }).Dial,
- TLSHandshakeTimeout: 10 * time.Second,
- ExpectContinueTimeout: 1 * time.Second,
- }
-}
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
deleted file mode 100644
index fe6dac1f4764..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go
+++ /dev/null
@@ -1,267 +0,0 @@
-package session
-
-import (
- "fmt"
- "os"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/credentials/processcreds"
- "github.com/aws/aws-sdk-go/aws/credentials/stscreds"
- "github.com/aws/aws-sdk-go/aws/defaults"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/internal/shareddefaults"
-)
-
-func resolveCredentials(cfg *aws.Config,
- envCfg envConfig, sharedCfg sharedConfig,
- handlers request.Handlers,
- sessOpts Options,
-) (*credentials.Credentials, error) {
-
- switch {
- case len(sessOpts.Profile) != 0:
- // User explicitly provided an Profile in the session's configuration
- // so load that profile from shared config first.
- // Github(aws/aws-sdk-go#2727)
- return resolveCredsFromProfile(cfg, envCfg, sharedCfg, handlers, sessOpts)
-
- case envCfg.Creds.HasKeys():
- // Environment credentials
- return credentials.NewStaticCredentialsFromCreds(envCfg.Creds), nil
-
- case len(envCfg.WebIdentityTokenFilePath) != 0:
- // Web identity token from environment, RoleARN required to also be
- // set.
- return assumeWebIdentity(cfg, handlers,
- envCfg.WebIdentityTokenFilePath,
- envCfg.RoleARN,
- envCfg.RoleSessionName,
- )
-
- default:
- // Fallback to the "default" credential resolution chain.
- return resolveCredsFromProfile(cfg, envCfg, sharedCfg, handlers, sessOpts)
- }
-}
-
-// WebIdentityEmptyRoleARNErr will occur if 'AWS_WEB_IDENTITY_TOKEN_FILE' was set but
-// 'AWS_ROLE_ARN' was not set.
-var WebIdentityEmptyRoleARNErr = awserr.New(stscreds.ErrCodeWebIdentity, "role ARN is not set", nil)
-
-// WebIdentityEmptyTokenFilePathErr will occur if 'AWS_ROLE_ARN' was set but
-// 'AWS_WEB_IDENTITY_TOKEN_FILE' was not set.
-var WebIdentityEmptyTokenFilePathErr = awserr.New(stscreds.ErrCodeWebIdentity, "token file path is not set", nil)
-
-func assumeWebIdentity(cfg *aws.Config, handlers request.Handlers,
- filepath string,
- roleARN, sessionName string,
-) (*credentials.Credentials, error) {
-
- if len(filepath) == 0 {
- return nil, WebIdentityEmptyTokenFilePathErr
- }
-
- if len(roleARN) == 0 {
- return nil, WebIdentityEmptyRoleARNErr
- }
-
- creds := stscreds.NewWebIdentityCredentials(
- &Session{
- Config: cfg,
- Handlers: handlers.Copy(),
- },
- roleARN,
- sessionName,
- filepath,
- )
-
- return creds, nil
-}
-
-func resolveCredsFromProfile(cfg *aws.Config,
- envCfg envConfig, sharedCfg sharedConfig,
- handlers request.Handlers,
- sessOpts Options,
-) (creds *credentials.Credentials, err error) {
-
- switch {
- case sharedCfg.SourceProfile != nil:
- // Assume IAM role with credentials source from a different profile.
- creds, err = resolveCredsFromProfile(cfg, envCfg,
- *sharedCfg.SourceProfile, handlers, sessOpts,
- )
-
- case sharedCfg.Creds.HasKeys():
- // Static Credentials from Shared Config/Credentials file.
- creds = credentials.NewStaticCredentialsFromCreds(
- sharedCfg.Creds,
- )
-
- case len(sharedCfg.CredentialProcess) != 0:
- // Get credentials from CredentialProcess
- creds = processcreds.NewCredentials(sharedCfg.CredentialProcess)
-
- case len(sharedCfg.CredentialSource) != 0:
- creds, err = resolveCredsFromSource(cfg, envCfg,
- sharedCfg, handlers, sessOpts,
- )
-
- case len(sharedCfg.WebIdentityTokenFile) != 0:
- // Credentials from Assume Web Identity token require an IAM Role, and
- // that roll will be assumed. May be wrapped with another assume role
- // via SourceProfile.
- return assumeWebIdentity(cfg, handlers,
- sharedCfg.WebIdentityTokenFile,
- sharedCfg.RoleARN,
- sharedCfg.RoleSessionName,
- )
-
- default:
- // Fallback to default credentials provider, include mock errors for
- // the credential chain so user can identify why credentials failed to
- // be retrieved.
- creds = credentials.NewCredentials(&credentials.ChainProvider{
- VerboseErrors: aws.BoolValue(cfg.CredentialsChainVerboseErrors),
- Providers: []credentials.Provider{
- &credProviderError{
- Err: awserr.New("EnvAccessKeyNotFound",
- "failed to find credentials in the environment.", nil),
- },
- &credProviderError{
- Err: awserr.New("SharedCredsLoad",
- fmt.Sprintf("failed to load profile, %s.", envCfg.Profile), nil),
- },
- defaults.RemoteCredProvider(*cfg, handlers),
- },
- })
- }
- if err != nil {
- return nil, err
- }
-
- if len(sharedCfg.RoleARN) > 0 {
- cfgCp := *cfg
- cfgCp.Credentials = creds
- return credsFromAssumeRole(cfgCp, handlers, sharedCfg, sessOpts)
- }
-
- return creds, nil
-}
-
-// valid credential source values
-const (
- credSourceEc2Metadata = "Ec2InstanceMetadata"
- credSourceEnvironment = "Environment"
- credSourceECSContainer = "EcsContainer"
-)
-
-func resolveCredsFromSource(cfg *aws.Config,
- envCfg envConfig, sharedCfg sharedConfig,
- handlers request.Handlers,
- sessOpts Options,
-) (creds *credentials.Credentials, err error) {
-
- switch sharedCfg.CredentialSource {
- case credSourceEc2Metadata:
- p := defaults.RemoteCredProvider(*cfg, handlers)
- creds = credentials.NewCredentials(p)
-
- case credSourceEnvironment:
- creds = credentials.NewStaticCredentialsFromCreds(envCfg.Creds)
-
- case credSourceECSContainer:
- if len(os.Getenv(shareddefaults.ECSCredsProviderEnvVar)) == 0 {
- return nil, ErrSharedConfigECSContainerEnvVarEmpty
- }
-
- p := defaults.RemoteCredProvider(*cfg, handlers)
- creds = credentials.NewCredentials(p)
-
- default:
- return nil, ErrSharedConfigInvalidCredSource
- }
-
- return creds, nil
-}
-
-func credsFromAssumeRole(cfg aws.Config,
- handlers request.Handlers,
- sharedCfg sharedConfig,
- sessOpts Options,
-) (*credentials.Credentials, error) {
-
- if len(sharedCfg.MFASerial) != 0 && sessOpts.AssumeRoleTokenProvider == nil {
- // AssumeRole Token provider is required if doing Assume Role
- // with MFA.
- return nil, AssumeRoleTokenProviderNotSetError{}
- }
-
- return stscreds.NewCredentials(
- &Session{
- Config: &cfg,
- Handlers: handlers.Copy(),
- },
- sharedCfg.RoleARN,
- func(opt *stscreds.AssumeRoleProvider) {
- opt.RoleSessionName = sharedCfg.RoleSessionName
-
- if sessOpts.AssumeRoleDuration == 0 &&
- sharedCfg.AssumeRoleDuration != nil &&
- *sharedCfg.AssumeRoleDuration/time.Minute > 15 {
- opt.Duration = *sharedCfg.AssumeRoleDuration
- } else if sessOpts.AssumeRoleDuration != 0 {
- opt.Duration = sessOpts.AssumeRoleDuration
- }
-
- // Assume role with external ID
- if len(sharedCfg.ExternalID) > 0 {
- opt.ExternalID = aws.String(sharedCfg.ExternalID)
- }
-
- // Assume role with MFA
- if len(sharedCfg.MFASerial) > 0 {
- opt.SerialNumber = aws.String(sharedCfg.MFASerial)
- opt.TokenProvider = sessOpts.AssumeRoleTokenProvider
- }
- },
- ), nil
-}
-
-// AssumeRoleTokenProviderNotSetError is an error returned when creating a
-// session when the MFAToken option is not set when shared config is configured
-// load assume a role with an MFA token.
-type AssumeRoleTokenProviderNotSetError struct{}
-
-// Code is the short id of the error.
-func (e AssumeRoleTokenProviderNotSetError) Code() string {
- return "AssumeRoleTokenProviderNotSetError"
-}
-
-// Message is the description of the error
-func (e AssumeRoleTokenProviderNotSetError) Message() string {
- return fmt.Sprintf("assume role with MFA enabled, but AssumeRoleTokenProvider session option not set.")
-}
-
-// OrigErr is the underlying error that caused the failure.
-func (e AssumeRoleTokenProviderNotSetError) OrigErr() error {
- return nil
-}
-
-// Error satisfies the error interface.
-func (e AssumeRoleTokenProviderNotSetError) Error() string {
- return awserr.SprintError(e.Code(), e.Message(), "", nil)
-}
-
-type credProviderError struct {
- Err error
-}
-
-func (c credProviderError) Retrieve() (credentials.Value, error) {
- return credentials.Value{}, c.Err
-}
-func (c credProviderError) IsExpired() bool {
- return true
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go b/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go
deleted file mode 100644
index cc461bd3230d..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go
+++ /dev/null
@@ -1,262 +0,0 @@
-/*
-Package session provides configuration for the SDK's service clients. Sessions
-can be shared across service clients that share the same base configuration.
-
-Sessions are safe to use concurrently as long as the Session is not being
-modified. Sessions should be cached when possible, because creating a new
-Session will load all configuration values from the environment, and config
-files each time the Session is created. Sharing the Session value across all of
-your service clients will ensure the configuration is loaded the fewest number
-of times possible.
-
-Sessions options from Shared Config
-
-By default NewSession will only load credentials from the shared credentials
-file (~/.aws/credentials). If the AWS_SDK_LOAD_CONFIG environment variable is
-set to a truthy value the Session will be created from the configuration
-values from the shared config (~/.aws/config) and shared credentials
-(~/.aws/credentials) files. Using the NewSessionWithOptions with
-SharedConfigState set to SharedConfigEnable will create the session as if the
-AWS_SDK_LOAD_CONFIG environment variable was set.
-
-Credential and config loading order
-
-The Session will attempt to load configuration and credentials from the
-environment, configuration files, and other credential sources. The order
-configuration is loaded in is:
-
- * Environment Variables
- * Shared Credentials file
- * Shared Configuration file (if SharedConfig is enabled)
- * EC2 Instance Metadata (credentials only)
-
-The Environment variables for credentials will have precedence over shared
-config even if SharedConfig is enabled. To override this behavior, and use
-shared config credentials instead specify the session.Options.Profile, (e.g.
-when using credential_source=Environment to assume a role).
-
- sess, err := session.NewSessionWithOptions(session.Options{
- Profile: "myProfile",
- })
-
-Creating Sessions
-
-Creating a Session without additional options will load credentials region, and
-profile loaded from the environment and shared config automatically. See,
-"Environment Variables" section for information on environment variables used
-by Session.
-
- // Create Session
- sess, err := session.NewSession()
-
-
-When creating Sessions optional aws.Config values can be passed in that will
-override the default, or loaded, config values the Session is being created
-with. This allows you to provide additional, or case based, configuration
-as needed.
-
- // Create a Session with a custom region
- sess, err := session.NewSession(&aws.Config{
- Region: aws.String("us-west-2"),
- })
-
-Use NewSessionWithOptions to provide additional configuration driving how the
-Session's configuration will be loaded. Such as, specifying shared config
-profile, or override the shared config state, (AWS_SDK_LOAD_CONFIG).
-
- // Equivalent to session.NewSession()
- sess, err := session.NewSessionWithOptions(session.Options{
- // Options
- })
-
- sess, err := session.NewSessionWithOptions(session.Options{
- // Specify profile to load for the session's config
- Profile: "profile_name",
-
- // Provide SDK Config options, such as Region.
- Config: aws.Config{
- Region: aws.String("us-west-2"),
- },
-
- // Force enable Shared Config support
- SharedConfigState: session.SharedConfigEnable,
- })
-
-Adding Handlers
-
-You can add handlers to a session to decorate API operation, (e.g. adding HTTP
-headers). All clients that use the Session receive a copy of the Session's
-handlers. For example, the following request handler added to the Session logs
-every requests made.
-
- // Create a session, and add additional handlers for all service
- // clients created with the Session to inherit. Adds logging handler.
- sess := session.Must(session.NewSession())
-
- sess.Handlers.Send.PushFront(func(r *request.Request) {
- // Log every request made and its payload
- logger.Printf("Request: %s/%s, Params: %s",
- r.ClientInfo.ServiceName, r.Operation, r.Params)
- })
-
-Shared Config Fields
-
-By default the SDK will only load the shared credentials file's
-(~/.aws/credentials) credentials values, and all other config is provided by
-the environment variables, SDK defaults, and user provided aws.Config values.
-
-If the AWS_SDK_LOAD_CONFIG environment variable is set, or SharedConfigEnable
-option is used to create the Session the full shared config values will be
-loaded. This includes credentials, region, and support for assume role. In
-addition the Session will load its configuration from both the shared config
-file (~/.aws/config) and shared credentials file (~/.aws/credentials). Both
-files have the same format.
-
-If both config files are present the configuration from both files will be
-read. The Session will be created from configuration values from the shared
-credentials file (~/.aws/credentials) over those in the shared config file
-(~/.aws/config).
-
-Credentials are the values the SDK uses to authenticating requests with AWS
-Services. When specified in a file, both aws_access_key_id and
-aws_secret_access_key must be provided together in the same file to be
-considered valid. They will be ignored if both are not present.
-aws_session_token is an optional field that can be provided in addition to the
-other two fields.
-
- aws_access_key_id = AKID
- aws_secret_access_key = SECRET
- aws_session_token = TOKEN
-
- ; region only supported if SharedConfigEnabled.
- region = us-east-1
-
-Assume Role configuration
-
-The role_arn field allows you to configure the SDK to assume an IAM role using
-a set of credentials from another source. Such as when paired with static
-credentials, "profile_source", "credential_process", or "credential_source"
-fields. If "role_arn" is provided, a source of credentials must also be
-specified, such as "source_profile", "credential_source", or
-"credential_process".
-
- role_arn = arn:aws:iam:::role/
- source_profile = profile_with_creds
- external_id = 1234
- mfa_serial =
- role_session_name = session_name
-
-
-The SDK supports assuming a role with MFA token. If "mfa_serial" is set, you
-must also set the Session Option.AssumeRoleTokenProvider. The Session will fail
-to load if the AssumeRoleTokenProvider is not specified.
-
- sess := session.Must(session.NewSessionWithOptions(session.Options{
- AssumeRoleTokenProvider: stscreds.StdinTokenProvider,
- }))
-
-To setup Assume Role outside of a session see the stscreds.AssumeRoleProvider
-documentation.
-
-Environment Variables
-
-When a Session is created several environment variables can be set to adjust
-how the SDK functions, and what configuration data it loads when creating
-Sessions. All environment values are optional, but some values like credentials
-require multiple of the values to set or the partial values will be ignored.
-All environment variable values are strings unless otherwise noted.
-
-Environment configuration values. If set both Access Key ID and Secret Access
-Key must be provided. Session Token and optionally also be provided, but is
-not required.
-
- # Access Key ID
- AWS_ACCESS_KEY_ID=AKID
- AWS_ACCESS_KEY=AKID # only read if AWS_ACCESS_KEY_ID is not set.
-
- # Secret Access Key
- AWS_SECRET_ACCESS_KEY=SECRET
- AWS_SECRET_KEY=SECRET=SECRET # only read if AWS_SECRET_ACCESS_KEY is not set.
-
- # Session Token
- AWS_SESSION_TOKEN=TOKEN
-
-Region value will instruct the SDK where to make service API requests to. If is
-not provided in the environment the region must be provided before a service
-client request is made.
-
- AWS_REGION=us-east-1
-
- # AWS_DEFAULT_REGION is only read if AWS_SDK_LOAD_CONFIG is also set,
- # and AWS_REGION is not also set.
- AWS_DEFAULT_REGION=us-east-1
-
-Profile name the SDK should load use when loading shared config from the
-configuration files. If not provided "default" will be used as the profile name.
-
- AWS_PROFILE=my_profile
-
- # AWS_DEFAULT_PROFILE is only read if AWS_SDK_LOAD_CONFIG is also set,
- # and AWS_PROFILE is not also set.
- AWS_DEFAULT_PROFILE=my_profile
-
-SDK load config instructs the SDK to load the shared config in addition to
-shared credentials. This also expands the configuration loaded so the shared
-credentials will have parity with the shared config file. This also enables
-Region and Profile support for the AWS_DEFAULT_REGION and AWS_DEFAULT_PROFILE
-env values as well.
-
- AWS_SDK_LOAD_CONFIG=1
-
-Shared credentials file path can be set to instruct the SDK to use an alternative
-file for the shared credentials. If not set the file will be loaded from
-$HOME/.aws/credentials on Linux/Unix based systems, and
-%USERPROFILE%\.aws\credentials on Windows.
-
- AWS_SHARED_CREDENTIALS_FILE=$HOME/my_shared_credentials
-
-Shared config file path can be set to instruct the SDK to use an alternative
-file for the shared config. If not set the file will be loaded from
-$HOME/.aws/config on Linux/Unix based systems, and
-%USERPROFILE%\.aws\config on Windows.
-
- AWS_CONFIG_FILE=$HOME/my_shared_config
-
-Path to a custom Credentials Authority (CA) bundle PEM file that the SDK
-will use instead of the default system's root CA bundle. Use this only
-if you want to replace the CA bundle the SDK uses for TLS requests.
-
- AWS_CA_BUNDLE=$HOME/my_custom_ca_bundle
-
-Enabling this option will attempt to merge the Transport into the SDK's HTTP
-client. If the client's Transport is not a http.Transport an error will be
-returned. If the Transport's TLS config is set this option will cause the SDK
-to overwrite the Transport's TLS config's RootCAs value. If the CA bundle file
-contains multiple certificates all of them will be loaded.
-
-The Session option CustomCABundle is also available when creating sessions
-to also enable this feature. CustomCABundle session option field has priority
-over the AWS_CA_BUNDLE environment variable, and will be used if both are set.
-
-Setting a custom HTTPClient in the aws.Config options will override this setting.
-To use this option and custom HTTP client, the HTTP client needs to be provided
-when creating the session. Not the service client.
-
-The endpoint of the EC2 IMDS client can be configured via the environment
-variable, AWS_EC2_METADATA_SERVICE_ENDPOINT when creating the client with a
-Session. See Options.EC2IMDSEndpoint for more details.
-
- AWS_EC2_METADATA_SERVICE_ENDPOINT=http://169.254.169.254
-
-If using an URL with an IPv6 address literal, the IPv6 address
-component must be enclosed in square brackets.
-
- AWS_EC2_METADATA_SERVICE_ENDPOINT=http://[::1]
-
-The custom EC2 IMDS endpoint can also be specified via the Session options.
-
- sess, err := session.NewSessionWithOptions(session.Options{
- EC2IMDSEndpoint: "http://[::1]",
- })
-*/
-package session
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
deleted file mode 100644
index d67c261d74f7..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go
+++ /dev/null
@@ -1,355 +0,0 @@
-package session
-
-import (
- "fmt"
- "os"
- "strconv"
- "strings"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/defaults"
- "github.com/aws/aws-sdk-go/aws/endpoints"
-)
-
-// EnvProviderName provides a name of the provider when config is loaded from environment.
-const EnvProviderName = "EnvConfigCredentials"
-
-// envConfig is a collection of environment values the SDK will read
-// setup config from. All environment values are optional. But some values
-// such as credentials require multiple values to be complete or the values
-// will be ignored.
-type envConfig struct {
- // Environment configuration values. If set both Access Key ID and Secret Access
- // Key must be provided. Session Token and optionally also be provided, but is
- // not required.
- //
- // # Access Key ID
- // AWS_ACCESS_KEY_ID=AKID
- // AWS_ACCESS_KEY=AKID # only read if AWS_ACCESS_KEY_ID is not set.
- //
- // # Secret Access Key
- // AWS_SECRET_ACCESS_KEY=SECRET
- // AWS_SECRET_KEY=SECRET=SECRET # only read if AWS_SECRET_ACCESS_KEY is not set.
- //
- // # Session Token
- // AWS_SESSION_TOKEN=TOKEN
- Creds credentials.Value
-
- // Region value will instruct the SDK where to make service API requests to. If is
- // not provided in the environment the region must be provided before a service
- // client request is made.
- //
- // AWS_REGION=us-east-1
- //
- // # AWS_DEFAULT_REGION is only read if AWS_SDK_LOAD_CONFIG is also set,
- // # and AWS_REGION is not also set.
- // AWS_DEFAULT_REGION=us-east-1
- Region string
-
- // Profile name the SDK should load use when loading shared configuration from the
- // shared configuration files. If not provided "default" will be used as the
- // profile name.
- //
- // AWS_PROFILE=my_profile
- //
- // # AWS_DEFAULT_PROFILE is only read if AWS_SDK_LOAD_CONFIG is also set,
- // # and AWS_PROFILE is not also set.
- // AWS_DEFAULT_PROFILE=my_profile
- Profile string
-
- // SDK load config instructs the SDK to load the shared config in addition to
- // shared credentials. This also expands the configuration loaded from the shared
- // credentials to have parity with the shared config file. This also enables
- // Region and Profile support for the AWS_DEFAULT_REGION and AWS_DEFAULT_PROFILE
- // env values as well.
- //
- // AWS_SDK_LOAD_CONFIG=1
- EnableSharedConfig bool
-
- // Shared credentials file path can be set to instruct the SDK to use an alternate
- // file for the shared credentials. If not set the file will be loaded from
- // $HOME/.aws/credentials on Linux/Unix based systems, and
- // %USERPROFILE%\.aws\credentials on Windows.
- //
- // AWS_SHARED_CREDENTIALS_FILE=$HOME/my_shared_credentials
- SharedCredentialsFile string
-
- // Shared config file path can be set to instruct the SDK to use an alternate
- // file for the shared config. If not set the file will be loaded from
- // $HOME/.aws/config on Linux/Unix based systems, and
- // %USERPROFILE%\.aws\config on Windows.
- //
- // AWS_CONFIG_FILE=$HOME/my_shared_config
- SharedConfigFile string
-
- // Sets the path to a custom Credentials Authority (CA) Bundle PEM file
- // that the SDK will use instead of the system's root CA bundle.
- // Only use this if you want to configure the SDK to use a custom set
- // of CAs.
- //
- // Enabling this option will attempt to merge the Transport
- // into the SDK's HTTP client. If the client's Transport is
- // not a http.Transport an error will be returned. If the
- // Transport's TLS config is set this option will cause the
- // SDK to overwrite the Transport's TLS config's RootCAs value.
- //
- // Setting a custom HTTPClient in the aws.Config options will override this setting.
- // To use this option and custom HTTP client, the HTTP client needs to be provided
- // when creating the session. Not the service client.
- //
- // AWS_CA_BUNDLE=$HOME/my_custom_ca_bundle
- CustomCABundle string
-
- csmEnabled string
- CSMEnabled *bool
- CSMPort string
- CSMHost string
- CSMClientID string
-
- // Enables endpoint discovery via environment variables.
- //
- // AWS_ENABLE_ENDPOINT_DISCOVERY=true
- EnableEndpointDiscovery *bool
- enableEndpointDiscovery string
-
- // Specifies the WebIdentity token the SDK should use to assume a role
- // with.
- //
- // AWS_WEB_IDENTITY_TOKEN_FILE=file_path
- WebIdentityTokenFilePath string
-
- // Specifies the IAM role arn to use when assuming an role.
- //
- // AWS_ROLE_ARN=role_arn
- RoleARN string
-
- // Specifies the IAM role session name to use when assuming a role.
- //
- // AWS_ROLE_SESSION_NAME=session_name
- RoleSessionName string
-
- // Specifies the STS Regional Endpoint flag for the SDK to resolve the endpoint
- // for a service.
- //
- // AWS_STS_REGIONAL_ENDPOINTS=regional
- // This can take value as `regional` or `legacy`
- STSRegionalEndpoint endpoints.STSRegionalEndpoint
-
- // Specifies the S3 Regional Endpoint flag for the SDK to resolve the
- // endpoint for a service.
- //
- // AWS_S3_US_EAST_1_REGIONAL_ENDPOINT=regional
- // This can take value as `regional` or `legacy`
- S3UsEast1RegionalEndpoint endpoints.S3UsEast1RegionalEndpoint
-
- // Specifies if the S3 service should allow ARNs to direct the region
- // the client's requests are sent to.
- //
- // AWS_S3_USE_ARN_REGION=true
- S3UseARNRegion bool
-
- // Specifies the alternative endpoint to use for EC2 IMDS.
- //
- // AWS_EC2_METADATA_SERVICE_ENDPOINT=http://[::1]
- EC2IMDSEndpoint string
-}
-
-var (
- csmEnabledEnvKey = []string{
- "AWS_CSM_ENABLED",
- }
- csmHostEnvKey = []string{
- "AWS_CSM_HOST",
- }
- csmPortEnvKey = []string{
- "AWS_CSM_PORT",
- }
- csmClientIDEnvKey = []string{
- "AWS_CSM_CLIENT_ID",
- }
- credAccessEnvKey = []string{
- "AWS_ACCESS_KEY_ID",
- "AWS_ACCESS_KEY",
- }
- credSecretEnvKey = []string{
- "AWS_SECRET_ACCESS_KEY",
- "AWS_SECRET_KEY",
- }
- credSessionEnvKey = []string{
- "AWS_SESSION_TOKEN",
- }
-
- enableEndpointDiscoveryEnvKey = []string{
- "AWS_ENABLE_ENDPOINT_DISCOVERY",
- }
-
- regionEnvKeys = []string{
- "AWS_REGION",
- "AWS_DEFAULT_REGION", // Only read if AWS_SDK_LOAD_CONFIG is also set
- }
- profileEnvKeys = []string{
- "AWS_PROFILE",
- "AWS_DEFAULT_PROFILE", // Only read if AWS_SDK_LOAD_CONFIG is also set
- }
- sharedCredsFileEnvKey = []string{
- "AWS_SHARED_CREDENTIALS_FILE",
- }
- sharedConfigFileEnvKey = []string{
- "AWS_CONFIG_FILE",
- }
- webIdentityTokenFilePathEnvKey = []string{
- "AWS_WEB_IDENTITY_TOKEN_FILE",
- }
- roleARNEnvKey = []string{
- "AWS_ROLE_ARN",
- }
- roleSessionNameEnvKey = []string{
- "AWS_ROLE_SESSION_NAME",
- }
- stsRegionalEndpointKey = []string{
- "AWS_STS_REGIONAL_ENDPOINTS",
- }
- s3UsEast1RegionalEndpoint = []string{
- "AWS_S3_US_EAST_1_REGIONAL_ENDPOINT",
- }
- s3UseARNRegionEnvKey = []string{
- "AWS_S3_USE_ARN_REGION",
- }
- ec2IMDSEndpointEnvKey = []string{
- "AWS_EC2_METADATA_SERVICE_ENDPOINT",
- }
-)
-
-// loadEnvConfig retrieves the SDK's environment configuration.
-// See `envConfig` for the values that will be retrieved.
-//
-// If the environment variable `AWS_SDK_LOAD_CONFIG` is set to a truthy value
-// the shared SDK config will be loaded in addition to the SDK's specific
-// configuration values.
-func loadEnvConfig() (envConfig, error) {
- enableSharedConfig, _ := strconv.ParseBool(os.Getenv("AWS_SDK_LOAD_CONFIG"))
- return envConfigLoad(enableSharedConfig)
-}
-
-// loadEnvSharedConfig retrieves the SDK's environment configuration, and the
-// SDK shared config. See `envConfig` for the values that will be retrieved.
-//
-// Loads the shared configuration in addition to the SDK's specific configuration.
-// This will load the same values as `loadEnvConfig` if the `AWS_SDK_LOAD_CONFIG`
-// environment variable is set.
-func loadSharedEnvConfig() (envConfig, error) {
- return envConfigLoad(true)
-}
-
-func envConfigLoad(enableSharedConfig bool) (envConfig, error) {
- cfg := envConfig{}
-
- cfg.EnableSharedConfig = enableSharedConfig
-
- // Static environment credentials
- var creds credentials.Value
- setFromEnvVal(&creds.AccessKeyID, credAccessEnvKey)
- setFromEnvVal(&creds.SecretAccessKey, credSecretEnvKey)
- setFromEnvVal(&creds.SessionToken, credSessionEnvKey)
- if creds.HasKeys() {
- // Require logical grouping of credentials
- creds.ProviderName = EnvProviderName
- cfg.Creds = creds
- }
-
- // Role Metadata
- setFromEnvVal(&cfg.RoleARN, roleARNEnvKey)
- setFromEnvVal(&cfg.RoleSessionName, roleSessionNameEnvKey)
-
- // Web identity environment variables
- setFromEnvVal(&cfg.WebIdentityTokenFilePath, webIdentityTokenFilePathEnvKey)
-
- // CSM environment variables
- setFromEnvVal(&cfg.csmEnabled, csmEnabledEnvKey)
- setFromEnvVal(&cfg.CSMHost, csmHostEnvKey)
- setFromEnvVal(&cfg.CSMPort, csmPortEnvKey)
- setFromEnvVal(&cfg.CSMClientID, csmClientIDEnvKey)
-
- if len(cfg.csmEnabled) != 0 {
- v, _ := strconv.ParseBool(cfg.csmEnabled)
- cfg.CSMEnabled = &v
- }
-
- regionKeys := regionEnvKeys
- profileKeys := profileEnvKeys
- if !cfg.EnableSharedConfig {
- regionKeys = regionKeys[:1]
- profileKeys = profileKeys[:1]
- }
-
- setFromEnvVal(&cfg.Region, regionKeys)
- setFromEnvVal(&cfg.Profile, profileKeys)
-
- // endpoint discovery is in reference to it being enabled.
- setFromEnvVal(&cfg.enableEndpointDiscovery, enableEndpointDiscoveryEnvKey)
- if len(cfg.enableEndpointDiscovery) > 0 {
- cfg.EnableEndpointDiscovery = aws.Bool(cfg.enableEndpointDiscovery != "false")
- }
-
- setFromEnvVal(&cfg.SharedCredentialsFile, sharedCredsFileEnvKey)
- setFromEnvVal(&cfg.SharedConfigFile, sharedConfigFileEnvKey)
-
- if len(cfg.SharedCredentialsFile) == 0 {
- cfg.SharedCredentialsFile = defaults.SharedCredentialsFilename()
- }
- if len(cfg.SharedConfigFile) == 0 {
- cfg.SharedConfigFile = defaults.SharedConfigFilename()
- }
-
- cfg.CustomCABundle = os.Getenv("AWS_CA_BUNDLE")
-
- var err error
- // STS Regional Endpoint variable
- for _, k := range stsRegionalEndpointKey {
- if v := os.Getenv(k); len(v) != 0 {
- cfg.STSRegionalEndpoint, err = endpoints.GetSTSRegionalEndpoint(v)
- if err != nil {
- return cfg, fmt.Errorf("failed to load, %v from env config, %v", k, err)
- }
- }
- }
-
- // S3 Regional Endpoint variable
- for _, k := range s3UsEast1RegionalEndpoint {
- if v := os.Getenv(k); len(v) != 0 {
- cfg.S3UsEast1RegionalEndpoint, err = endpoints.GetS3UsEast1RegionalEndpoint(v)
- if err != nil {
- return cfg, fmt.Errorf("failed to load, %v from env config, %v", k, err)
- }
- }
- }
-
- var s3UseARNRegion string
- setFromEnvVal(&s3UseARNRegion, s3UseARNRegionEnvKey)
- if len(s3UseARNRegion) != 0 {
- switch {
- case strings.EqualFold(s3UseARNRegion, "false"):
- cfg.S3UseARNRegion = false
- case strings.EqualFold(s3UseARNRegion, "true"):
- cfg.S3UseARNRegion = true
- default:
- return envConfig{}, fmt.Errorf(
- "invalid value for environment variable, %s=%s, need true or false",
- s3UseARNRegionEnvKey[0], s3UseARNRegion)
- }
- }
-
- setFromEnvVal(&cfg.EC2IMDSEndpoint, ec2IMDSEndpointEnvKey)
-
- return cfg, nil
-}
-
-func setFromEnvVal(dst *string, keys []string) {
- for _, k := range keys {
- if v := os.Getenv(k); len(v) != 0 {
- *dst = v
- break
- }
- }
-}
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
deleted file mode 100644
index 6430a7f15261..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go
+++ /dev/null
@@ -1,791 +0,0 @@
-package session
-
-import (
- "crypto/tls"
- "crypto/x509"
- "fmt"
- "io"
- "io/ioutil"
- "net/http"
- "os"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/client"
- "github.com/aws/aws-sdk-go/aws/corehandlers"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/csm"
- "github.com/aws/aws-sdk-go/aws/defaults"
- "github.com/aws/aws-sdk-go/aws/endpoints"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-const (
- // ErrCodeSharedConfig represents an error that occurs in the shared
- // configuration logic
- ErrCodeSharedConfig = "SharedConfigErr"
-)
-
-// ErrSharedConfigSourceCollision will be returned if a section contains both
-// source_profile and credential_source
-var ErrSharedConfigSourceCollision = awserr.New(ErrCodeSharedConfig, "only source profile or credential source can be specified, not both", nil)
-
-// ErrSharedConfigECSContainerEnvVarEmpty will be returned if the environment
-// variables are empty and Environment was set as the credential source
-var ErrSharedConfigECSContainerEnvVarEmpty = awserr.New(ErrCodeSharedConfig, "EcsContainer was specified as the credential_source, but 'AWS_CONTAINER_CREDENTIALS_RELATIVE_URI' was not set", nil)
-
-// ErrSharedConfigInvalidCredSource will be returned if an invalid credential source was provided
-var ErrSharedConfigInvalidCredSource = awserr.New(ErrCodeSharedConfig, "credential source values must be EcsContainer, Ec2InstanceMetadata, or Environment", nil)
-
-// A Session provides a central location to create service clients from and
-// store configurations and request handlers for those services.
-//
-// Sessions are safe to create service clients concurrently, but it is not safe
-// to mutate the Session concurrently.
-//
-// The Session satisfies the service client's client.ConfigProvider.
-type Session struct {
- Config *aws.Config
- Handlers request.Handlers
-
- options Options
-}
-
-// New creates a new instance of the handlers merging in the provided configs
-// on top of the SDK's default configurations. Once the Session is created it
-// can be mutated to modify the Config or Handlers. The Session is safe to be
-// read concurrently, but it should not be written to concurrently.
-//
-// If the AWS_SDK_LOAD_CONFIG environment is set to a truthy value, the New
-// method could now encounter an error when loading the configuration. When
-// The environment variable is set, and an error occurs, New will return a
-// session that will fail all requests reporting the error that occurred while
-// loading the session. Use NewSession to get the error when creating the
-// session.
-//
-// If the AWS_SDK_LOAD_CONFIG environment variable is set to a truthy value
-// the shared config file (~/.aws/config) will also be loaded, in addition to
-// the shared credentials file (~/.aws/credentials). Values set in both the
-// shared config, and shared credentials will be taken from the shared
-// credentials file.
-//
-// Deprecated: Use NewSession functions to create sessions instead. NewSession
-// has the same functionality as New except an error can be returned when the
-// func is called instead of waiting to receive an error until a request is made.
-func New(cfgs ...*aws.Config) *Session {
- // load initial config from environment
- envCfg, envErr := loadEnvConfig()
-
- if envCfg.EnableSharedConfig {
- var cfg aws.Config
- cfg.MergeIn(cfgs...)
- s, err := NewSessionWithOptions(Options{
- Config: cfg,
- SharedConfigState: SharedConfigEnable,
- })
- if err != nil {
- // Old session.New expected all errors to be discovered when
- // a request is made, and would report the errors then. This
- // needs to be replicated if an error occurs while creating
- // the session.
- msg := "failed to create session with AWS_SDK_LOAD_CONFIG enabled. " +
- "Use session.NewSession to handle errors occurring during session creation."
-
- // Session creation failed, need to report the error and prevent
- // any requests from succeeding.
- s = &Session{Config: defaults.Config()}
- s.logDeprecatedNewSessionError(msg, err, cfgs)
- }
-
- return s
- }
-
- s := deprecatedNewSession(envCfg, cfgs...)
- if envErr != nil {
- msg := "failed to load env config"
- s.logDeprecatedNewSessionError(msg, envErr, cfgs)
- }
-
- if csmCfg, err := loadCSMConfig(envCfg, []string{}); err != nil {
- if l := s.Config.Logger; l != nil {
- l.Log(fmt.Sprintf("ERROR: failed to load CSM configuration, %v", err))
- }
- } else if csmCfg.Enabled {
- err := enableCSM(&s.Handlers, csmCfg, s.Config.Logger)
- if err != nil {
- msg := "failed to enable CSM"
- s.logDeprecatedNewSessionError(msg, err, cfgs)
- }
- }
-
- return s
-}
-
-// NewSession returns a new Session created from SDK defaults, config files,
-// environment, and user provided config files. Once the Session is created
-// it can be mutated to modify the Config or Handlers. The Session is safe to
-// be read concurrently, but it should not be written to concurrently.
-//
-// If the AWS_SDK_LOAD_CONFIG environment variable is set to a truthy value
-// the shared config file (~/.aws/config) will also be loaded in addition to
-// the shared credentials file (~/.aws/credentials). Values set in both the
-// shared config, and shared credentials will be taken from the shared
-// credentials file. Enabling the Shared Config will also allow the Session
-// to be built with retrieving credentials with AssumeRole set in the config.
-//
-// See the NewSessionWithOptions func for information on how to override or
-// control through code how the Session will be created, such as specifying the
-// config profile, and controlling if shared config is enabled or not.
-func NewSession(cfgs ...*aws.Config) (*Session, error) {
- opts := Options{}
- opts.Config.MergeIn(cfgs...)
-
- return NewSessionWithOptions(opts)
-}
-
-// SharedConfigState provides the ability to optionally override the state
-// of the session's creation based on the shared config being enabled or
-// disabled.
-type SharedConfigState int
-
-const (
- // SharedConfigStateFromEnv does not override any state of the
- // AWS_SDK_LOAD_CONFIG env var. It is the default value of the
- // SharedConfigState type.
- SharedConfigStateFromEnv SharedConfigState = iota
-
- // SharedConfigDisable overrides the AWS_SDK_LOAD_CONFIG env var value
- // and disables the shared config functionality.
- SharedConfigDisable
-
- // SharedConfigEnable overrides the AWS_SDK_LOAD_CONFIG env var value
- // and enables the shared config functionality.
- SharedConfigEnable
-)
-
-// Options provides the means to control how a Session is created and what
-// configuration values will be loaded.
-//
-type Options struct {
- // Provides config values for the SDK to use when creating service clients
- // and making API requests to services. Any value set in with this field
- // will override the associated value provided by the SDK defaults,
- // environment or config files where relevant.
- //
- // If not set, configuration values from from SDK defaults, environment,
- // config will be used.
- Config aws.Config
-
- // Overrides the config profile the Session should be created from. If not
- // set the value of the environment variable will be loaded (AWS_PROFILE,
- // or AWS_DEFAULT_PROFILE if the Shared Config is enabled).
- //
- // If not set and environment variables are not set the "default"
- // (DefaultSharedConfigProfile) will be used as the profile to load the
- // session config from.
- Profile string
-
- // Instructs how the Session will be created based on the AWS_SDK_LOAD_CONFIG
- // environment variable. By default a Session will be created using the
- // value provided by the AWS_SDK_LOAD_CONFIG environment variable.
- //
- // Setting this value to SharedConfigEnable or SharedConfigDisable
- // will allow you to override the AWS_SDK_LOAD_CONFIG environment variable
- // and enable or disable the shared config functionality.
- SharedConfigState SharedConfigState
-
- // Ordered list of files the session will load configuration from.
- // It will override environment variable AWS_SHARED_CREDENTIALS_FILE, AWS_CONFIG_FILE.
- SharedConfigFiles []string
-
- // When the SDK's shared config is configured to assume a role with MFA
- // this option is required in order to provide the mechanism that will
- // retrieve the MFA token. There is no default value for this field. If
- // it is not set an error will be returned when creating the session.
- //
- // This token provider will be called when ever the assumed role's
- // credentials need to be refreshed. Within the context of service clients
- // all sharing the same session the SDK will ensure calls to the token
- // provider are atomic. When sharing a token provider across multiple
- // sessions additional synchronization logic is needed to ensure the
- // token providers do not introduce race conditions. It is recommend to
- // share the session where possible.
- //
- // stscreds.StdinTokenProvider is a basic implementation that will prompt
- // from stdin for the MFA token code.
- //
- // This field is only used if the shared configuration is enabled, and
- // the config enables assume role wit MFA via the mfa_serial field.
- AssumeRoleTokenProvider func() (string, error)
-
- // When the SDK's shared config is configured to assume a role this option
- // may be provided to set the expiry duration of the STS credentials.
- // Defaults to 15 minutes if not set as documented in the
- // stscreds.AssumeRoleProvider.
- AssumeRoleDuration time.Duration
-
- // Reader for a custom Credentials Authority (CA) bundle in PEM format that
- // the SDK will use instead of the default system's root CA bundle. Use this
- // only if you want to replace the CA bundle the SDK uses for TLS requests.
- //
- // Enabling this option will attempt to merge the Transport into the SDK's HTTP
- // client. If the client's Transport is not a http.Transport an error will be
- // returned. If the Transport's TLS config is set this option will cause the SDK
- // to overwrite the Transport's TLS config's RootCAs value. If the CA
- // bundle reader contains multiple certificates all of them will be loaded.
- //
- // The Session option CustomCABundle is also available when creating sessions
- // to also enable this feature. CustomCABundle session option field has priority
- // over the AWS_CA_BUNDLE environment variable, and will be used if both are set.
- CustomCABundle io.Reader
-
- // The handlers that the session and all API clients will be created with.
- // This must be a complete set of handlers. Use the defaults.Handlers()
- // function to initialize this value before changing the handlers to be
- // used by the SDK.
- Handlers request.Handlers
-
- // Allows specifying a custom endpoint to be used by the EC2 IMDS client
- // when making requests to the EC2 IMDS API. The must endpoint value must
- // include protocol prefix.
- //
- // If unset, will the EC2 IMDS client will use its default endpoint.
- //
- // Can also be specified via the environment variable,
- // AWS_EC2_METADATA_SERVICE_ENDPOINT.
- //
- // AWS_EC2_METADATA_SERVICE_ENDPOINT=http://169.254.169.254
- //
- // If using an URL with an IPv6 address literal, the IPv6 address
- // component must be enclosed in square brackets.
- //
- // AWS_EC2_METADATA_SERVICE_ENDPOINT=http://[::1]
- EC2IMDSEndpoint string
-}
-
-// NewSessionWithOptions returns a new Session created from SDK defaults, config files,
-// environment, and user provided config files. This func uses the Options
-// values to configure how the Session is created.
-//
-// If the AWS_SDK_LOAD_CONFIG environment variable is set to a truthy value
-// the shared config file (~/.aws/config) will also be loaded in addition to
-// the shared credentials file (~/.aws/credentials). Values set in both the
-// shared config, and shared credentials will be taken from the shared
-// credentials file. Enabling the Shared Config will also allow the Session
-// to be built with retrieving credentials with AssumeRole set in the config.
-//
-// // Equivalent to session.New
-// sess := session.Must(session.NewSessionWithOptions(session.Options{}))
-//
-// // Specify profile to load for the session's config
-// sess := session.Must(session.NewSessionWithOptions(session.Options{
-// Profile: "profile_name",
-// }))
-//
-// // Specify profile for config and region for requests
-// sess := session.Must(session.NewSessionWithOptions(session.Options{
-// Config: aws.Config{Region: aws.String("us-east-1")},
-// Profile: "profile_name",
-// }))
-//
-// // Force enable Shared Config support
-// sess := session.Must(session.NewSessionWithOptions(session.Options{
-// SharedConfigState: session.SharedConfigEnable,
-// }))
-func NewSessionWithOptions(opts Options) (*Session, error) {
- var envCfg envConfig
- var err error
- if opts.SharedConfigState == SharedConfigEnable {
- envCfg, err = loadSharedEnvConfig()
- if err != nil {
- return nil, fmt.Errorf("failed to load shared config, %v", err)
- }
- } else {
- envCfg, err = loadEnvConfig()
- if err != nil {
- return nil, fmt.Errorf("failed to load environment config, %v", err)
- }
- }
-
- if len(opts.Profile) != 0 {
- envCfg.Profile = opts.Profile
- }
-
- switch opts.SharedConfigState {
- case SharedConfigDisable:
- envCfg.EnableSharedConfig = false
- case SharedConfigEnable:
- envCfg.EnableSharedConfig = true
- }
-
- // Only use AWS_CA_BUNDLE if session option is not provided.
- if len(envCfg.CustomCABundle) != 0 && opts.CustomCABundle == nil {
- f, err := os.Open(envCfg.CustomCABundle)
- if err != nil {
- return nil, awserr.New("LoadCustomCABundleError",
- "failed to open custom CA bundle PEM file", err)
- }
- defer f.Close()
- opts.CustomCABundle = f
- }
-
- return newSession(opts, envCfg, &opts.Config)
-}
-
-// Must is a helper function to ensure the Session is valid and there was no
-// error when calling a NewSession function.
-//
-// This helper is intended to be used in variable initialization to load the
-// Session and configuration at startup. Such as:
-//
-// var sess = session.Must(session.NewSession())
-func Must(sess *Session, err error) *Session {
- if err != nil {
- panic(err)
- }
-
- return sess
-}
-
-// Wraps the endpoint resolver with a resolver that will return a custom
-// endpoint for EC2 IMDS.
-func wrapEC2IMDSEndpoint(resolver endpoints.Resolver, endpoint string) endpoints.Resolver {
- return endpoints.ResolverFunc(
- func(service, region string, opts ...func(*endpoints.Options)) (
- endpoints.ResolvedEndpoint, error,
- ) {
- if service == ec2MetadataServiceID {
- return endpoints.ResolvedEndpoint{
- URL: endpoint,
- SigningName: ec2MetadataServiceID,
- SigningRegion: region,
- }, nil
- }
- return resolver.EndpointFor(service, region)
- })
-}
-
-func deprecatedNewSession(envCfg envConfig, cfgs ...*aws.Config) *Session {
- cfg := defaults.Config()
- handlers := defaults.Handlers()
-
- // Apply the passed in configs so the configuration can be applied to the
- // default credential chain
- cfg.MergeIn(cfgs...)
- if cfg.EndpointResolver == nil {
- // An endpoint resolver is required for a session to be able to provide
- // endpoints for service client configurations.
- cfg.EndpointResolver = endpoints.DefaultResolver()
- }
-
- if len(envCfg.EC2IMDSEndpoint) != 0 {
- cfg.EndpointResolver = wrapEC2IMDSEndpoint(cfg.EndpointResolver, envCfg.EC2IMDSEndpoint)
- }
-
- cfg.Credentials = defaults.CredChain(cfg, handlers)
-
- // Reapply any passed in configs to override credentials if set
- cfg.MergeIn(cfgs...)
-
- s := &Session{
- Config: cfg,
- Handlers: handlers,
- options: Options{
- EC2IMDSEndpoint: envCfg.EC2IMDSEndpoint,
- },
- }
-
- initHandlers(s)
- return s
-}
-
-func enableCSM(handlers *request.Handlers, cfg csmConfig, logger aws.Logger) error {
- if logger != nil {
- logger.Log("Enabling CSM")
- }
-
- r, err := csm.Start(cfg.ClientID, csm.AddressWithDefaults(cfg.Host, cfg.Port))
- if err != nil {
- return err
- }
- r.InjectHandlers(handlers)
-
- return nil
-}
-
-func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session, error) {
- cfg := defaults.Config()
-
- handlers := opts.Handlers
- if handlers.IsEmpty() {
- handlers = defaults.Handlers()
- }
-
- // Get a merged version of the user provided config to determine if
- // credentials were.
- userCfg := &aws.Config{}
- userCfg.MergeIn(cfgs...)
- cfg.MergeIn(userCfg)
-
- // Ordered config files will be loaded in with later files overwriting
- // previous config file values.
- var cfgFiles []string
- if opts.SharedConfigFiles != nil {
- cfgFiles = opts.SharedConfigFiles
- } else {
- cfgFiles = []string{envCfg.SharedConfigFile, envCfg.SharedCredentialsFile}
- if !envCfg.EnableSharedConfig {
- // The shared config file (~/.aws/config) is only loaded if instructed
- // to load via the envConfig.EnableSharedConfig (AWS_SDK_LOAD_CONFIG).
- cfgFiles = cfgFiles[1:]
- }
- }
-
- // Load additional config from file(s)
- sharedCfg, err := loadSharedConfig(envCfg.Profile, cfgFiles, envCfg.EnableSharedConfig)
- if err != nil {
- if len(envCfg.Profile) == 0 && !envCfg.EnableSharedConfig && (envCfg.Creds.HasKeys() || userCfg.Credentials != nil) {
- // Special case where the user has not explicitly specified an AWS_PROFILE,
- // or session.Options.profile, shared config is not enabled, and the
- // environment has credentials, allow the shared config file to fail to
- // load since the user has already provided credentials, and nothing else
- // is required to be read file. Github(aws/aws-sdk-go#2455)
- } else if _, ok := err.(SharedConfigProfileNotExistsError); !ok {
- return nil, err
- }
- }
-
- if err := mergeConfigSrcs(cfg, userCfg, envCfg, sharedCfg, handlers, opts); err != nil {
- return nil, err
- }
-
- s := &Session{
- Config: cfg,
- Handlers: handlers,
- options: opts,
- }
-
- initHandlers(s)
-
- if csmCfg, err := loadCSMConfig(envCfg, cfgFiles); err != nil {
- if l := s.Config.Logger; l != nil {
- l.Log(fmt.Sprintf("ERROR: failed to load CSM configuration, %v", err))
- }
- } else if csmCfg.Enabled {
- err = enableCSM(&s.Handlers, csmCfg, s.Config.Logger)
- if err != nil {
- return nil, err
- }
- }
-
- // Setup HTTP client with custom cert bundle if enabled
- if opts.CustomCABundle != nil {
- if err := loadCustomCABundle(s, opts.CustomCABundle); err != nil {
- return nil, err
- }
- }
-
- return s, nil
-}
-
-type csmConfig struct {
- Enabled bool
- Host string
- Port string
- ClientID string
-}
-
-var csmProfileName = "aws_csm"
-
-func loadCSMConfig(envCfg envConfig, cfgFiles []string) (csmConfig, error) {
- if envCfg.CSMEnabled != nil {
- if *envCfg.CSMEnabled {
- return csmConfig{
- Enabled: true,
- ClientID: envCfg.CSMClientID,
- Host: envCfg.CSMHost,
- Port: envCfg.CSMPort,
- }, nil
- }
- return csmConfig{}, nil
- }
-
- sharedCfg, err := loadSharedConfig(csmProfileName, cfgFiles, false)
- if err != nil {
- if _, ok := err.(SharedConfigProfileNotExistsError); !ok {
- return csmConfig{}, err
- }
- }
- if sharedCfg.CSMEnabled != nil && *sharedCfg.CSMEnabled == true {
- return csmConfig{
- Enabled: true,
- ClientID: sharedCfg.CSMClientID,
- Host: sharedCfg.CSMHost,
- Port: sharedCfg.CSMPort,
- }, nil
- }
-
- return csmConfig{}, nil
-}
-
-func loadCustomCABundle(s *Session, bundle io.Reader) error {
- var t *http.Transport
- switch v := s.Config.HTTPClient.Transport.(type) {
- case *http.Transport:
- t = v
- default:
- if s.Config.HTTPClient.Transport != nil {
- return awserr.New("LoadCustomCABundleError",
- "unable to load custom CA bundle, HTTPClient's transport unsupported type", nil)
- }
- }
- if t == nil {
- // Nil transport implies `http.DefaultTransport` should be used. Since
- // the SDK cannot modify, nor copy the `DefaultTransport` specifying
- // the values the next closest behavior.
- t = getCABundleTransport()
- }
-
- p, err := loadCertPool(bundle)
- if err != nil {
- return err
- }
- if t.TLSClientConfig == nil {
- t.TLSClientConfig = &tls.Config{}
- }
- t.TLSClientConfig.RootCAs = p
-
- s.Config.HTTPClient.Transport = t
-
- return nil
-}
-
-func loadCertPool(r io.Reader) (*x509.CertPool, error) {
- b, err := ioutil.ReadAll(r)
- if err != nil {
- return nil, awserr.New("LoadCustomCABundleError",
- "failed to read custom CA bundle PEM file", err)
- }
-
- p := x509.NewCertPool()
- if !p.AppendCertsFromPEM(b) {
- return nil, awserr.New("LoadCustomCABundleError",
- "failed to load custom CA bundle PEM file", err)
- }
-
- return p, nil
-}
-
-func mergeConfigSrcs(cfg, userCfg *aws.Config,
- envCfg envConfig, sharedCfg sharedConfig,
- handlers request.Handlers,
- sessOpts Options,
-) error {
-
- // Region if not already set by user
- if len(aws.StringValue(cfg.Region)) == 0 {
- if len(envCfg.Region) > 0 {
- cfg.WithRegion(envCfg.Region)
- } else if envCfg.EnableSharedConfig && len(sharedCfg.Region) > 0 {
- cfg.WithRegion(sharedCfg.Region)
- }
- }
-
- if cfg.EnableEndpointDiscovery == nil {
- if envCfg.EnableEndpointDiscovery != nil {
- cfg.WithEndpointDiscovery(*envCfg.EnableEndpointDiscovery)
- } else if envCfg.EnableSharedConfig && sharedCfg.EnableEndpointDiscovery != nil {
- cfg.WithEndpointDiscovery(*sharedCfg.EnableEndpointDiscovery)
- }
- }
-
- // Regional Endpoint flag for STS endpoint resolving
- mergeSTSRegionalEndpointConfig(cfg, []endpoints.STSRegionalEndpoint{
- userCfg.STSRegionalEndpoint,
- envCfg.STSRegionalEndpoint,
- sharedCfg.STSRegionalEndpoint,
- endpoints.LegacySTSEndpoint,
- })
-
- // Regional Endpoint flag for S3 endpoint resolving
- mergeS3UsEast1RegionalEndpointConfig(cfg, []endpoints.S3UsEast1RegionalEndpoint{
- userCfg.S3UsEast1RegionalEndpoint,
- envCfg.S3UsEast1RegionalEndpoint,
- sharedCfg.S3UsEast1RegionalEndpoint,
- endpoints.LegacyS3UsEast1Endpoint,
- })
-
- ec2IMDSEndpoint := sessOpts.EC2IMDSEndpoint
- if len(ec2IMDSEndpoint) == 0 {
- ec2IMDSEndpoint = envCfg.EC2IMDSEndpoint
- }
- if len(ec2IMDSEndpoint) != 0 {
- cfg.EndpointResolver = wrapEC2IMDSEndpoint(cfg.EndpointResolver, ec2IMDSEndpoint)
- }
-
- // Configure credentials if not already set by the user when creating the
- // Session.
- if cfg.Credentials == credentials.AnonymousCredentials && userCfg.Credentials == nil {
- creds, err := resolveCredentials(cfg, envCfg, sharedCfg, handlers, sessOpts)
- if err != nil {
- return err
- }
- cfg.Credentials = creds
- }
-
- cfg.S3UseARNRegion = userCfg.S3UseARNRegion
- if cfg.S3UseARNRegion == nil {
- cfg.S3UseARNRegion = &envCfg.S3UseARNRegion
- }
- if cfg.S3UseARNRegion == nil {
- cfg.S3UseARNRegion = &sharedCfg.S3UseARNRegion
- }
-
- return nil
-}
-
-func mergeSTSRegionalEndpointConfig(cfg *aws.Config, values []endpoints.STSRegionalEndpoint) {
- for _, v := range values {
- if v != endpoints.UnsetSTSEndpoint {
- cfg.STSRegionalEndpoint = v
- break
- }
- }
-}
-
-func mergeS3UsEast1RegionalEndpointConfig(cfg *aws.Config, values []endpoints.S3UsEast1RegionalEndpoint) {
- for _, v := range values {
- if v != endpoints.UnsetS3UsEast1Endpoint {
- cfg.S3UsEast1RegionalEndpoint = v
- break
- }
- }
-}
-
-func initHandlers(s *Session) {
- // Add the Validate parameter handler if it is not disabled.
- s.Handlers.Validate.Remove(corehandlers.ValidateParametersHandler)
- if !aws.BoolValue(s.Config.DisableParamValidation) {
- s.Handlers.Validate.PushBackNamed(corehandlers.ValidateParametersHandler)
- }
-}
-
-// Copy creates and returns a copy of the current Session, copying the config
-// and handlers. If any additional configs are provided they will be merged
-// on top of the Session's copied config.
-//
-// // Create a copy of the current Session, configured for the us-west-2 region.
-// sess.Copy(&aws.Config{Region: aws.String("us-west-2")})
-func (s *Session) Copy(cfgs ...*aws.Config) *Session {
- newSession := &Session{
- Config: s.Config.Copy(cfgs...),
- Handlers: s.Handlers.Copy(),
- options: s.options,
- }
-
- initHandlers(newSession)
-
- return newSession
-}
-
-// ClientConfig satisfies the client.ConfigProvider interface and is used to
-// configure the service client instances. Passing the Session to the service
-// client's constructor (New) will use this method to configure the client.
-func (s *Session) ClientConfig(service string, cfgs ...*aws.Config) client.Config {
- s = s.Copy(cfgs...)
-
- region := aws.StringValue(s.Config.Region)
- resolved, err := s.resolveEndpoint(service, region, s.Config)
- if err != nil {
- s.Handlers.Validate.PushBack(func(r *request.Request) {
- if len(r.ClientInfo.Endpoint) != 0 {
- // Error occurred while resolving endpoint, but the request
- // being invoked has had an endpoint specified after the client
- // was created.
- return
- }
- r.Error = err
- })
- }
-
- return client.Config{
- Config: s.Config,
- Handlers: s.Handlers,
- PartitionID: resolved.PartitionID,
- Endpoint: resolved.URL,
- SigningRegion: resolved.SigningRegion,
- SigningNameDerived: resolved.SigningNameDerived,
- SigningName: resolved.SigningName,
- }
-}
-
-const ec2MetadataServiceID = "ec2metadata"
-
-func (s *Session) resolveEndpoint(service, region string, cfg *aws.Config) (endpoints.ResolvedEndpoint, error) {
-
- if ep := aws.StringValue(cfg.Endpoint); len(ep) != 0 {
- return endpoints.ResolvedEndpoint{
- URL: endpoints.AddScheme(ep, aws.BoolValue(cfg.DisableSSL)),
- SigningRegion: region,
- }, nil
- }
-
- resolved, err := cfg.EndpointResolver.EndpointFor(service, region,
- func(opt *endpoints.Options) {
- opt.DisableSSL = aws.BoolValue(cfg.DisableSSL)
- opt.UseDualStack = aws.BoolValue(cfg.UseDualStack)
- // Support for STSRegionalEndpoint where the STSRegionalEndpoint is
- // provided in envConfig or sharedConfig with envConfig getting
- // precedence.
- opt.STSRegionalEndpoint = cfg.STSRegionalEndpoint
-
- // Support for S3UsEast1RegionalEndpoint where the S3UsEast1RegionalEndpoint is
- // provided in envConfig or sharedConfig with envConfig getting
- // precedence.
- opt.S3UsEast1RegionalEndpoint = cfg.S3UsEast1RegionalEndpoint
-
- // Support the condition where the service is modeled but its
- // endpoint metadata is not available.
- opt.ResolveUnknownService = true
- },
- )
- if err != nil {
- return endpoints.ResolvedEndpoint{}, err
- }
-
- return resolved, nil
-}
-
-// ClientConfigNoResolveEndpoint is the same as ClientConfig with the exception
-// that the EndpointResolver will not be used to resolve the endpoint. The only
-// endpoint set must come from the aws.Config.Endpoint field.
-func (s *Session) ClientConfigNoResolveEndpoint(cfgs ...*aws.Config) client.Config {
- s = s.Copy(cfgs...)
-
- var resolved endpoints.ResolvedEndpoint
- if ep := aws.StringValue(s.Config.Endpoint); len(ep) > 0 {
- resolved.URL = endpoints.AddScheme(ep, aws.BoolValue(s.Config.DisableSSL))
- resolved.SigningRegion = aws.StringValue(s.Config.Region)
- }
-
- return client.Config{
- Config: s.Config,
- Handlers: s.Handlers,
- Endpoint: resolved.URL,
- SigningRegion: resolved.SigningRegion,
- SigningNameDerived: resolved.SigningNameDerived,
- SigningName: resolved.SigningName,
- }
-}
-
-// logDeprecatedNewSessionError function enables error handling for session
-func (s *Session) logDeprecatedNewSessionError(msg string, err error, cfgs []*aws.Config) {
- // Session creation failed, need to report the error and prevent
- // any requests from succeeding.
- s.Config.MergeIn(cfgs...)
- s.Config.Logger.Log("ERROR:", msg, "Error:", err)
- s.Handlers.Validate.PushBack(func(r *request.Request) {
- r.Error = err
- })
-}
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
deleted file mode 100644
index 680805a38add..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go
+++ /dev/null
@@ -1,555 +0,0 @@
-package session
-
-import (
- "fmt"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/endpoints"
- "github.com/aws/aws-sdk-go/internal/ini"
-)
-
-const (
- // Static Credentials group
- accessKeyIDKey = `aws_access_key_id` // group required
- secretAccessKey = `aws_secret_access_key` // group required
- sessionTokenKey = `aws_session_token` // optional
-
- // Assume Role Credentials group
- roleArnKey = `role_arn` // group required
- sourceProfileKey = `source_profile` // group required (or credential_source)
- credentialSourceKey = `credential_source` // group required (or source_profile)
- externalIDKey = `external_id` // optional
- mfaSerialKey = `mfa_serial` // optional
- roleSessionNameKey = `role_session_name` // optional
- roleDurationSecondsKey = "duration_seconds" // optional
-
- // CSM options
- csmEnabledKey = `csm_enabled`
- csmHostKey = `csm_host`
- csmPortKey = `csm_port`
- csmClientIDKey = `csm_client_id`
-
- // Additional Config fields
- regionKey = `region`
-
- // endpoint discovery group
- enableEndpointDiscoveryKey = `endpoint_discovery_enabled` // optional
-
- // External Credential Process
- credentialProcessKey = `credential_process` // optional
-
- // Web Identity Token File
- webIdentityTokenFileKey = `web_identity_token_file` // optional
-
- // Additional config fields for regional or legacy endpoints
- stsRegionalEndpointSharedKey = `sts_regional_endpoints`
-
- // Additional config fields for regional or legacy endpoints
- s3UsEast1RegionalSharedKey = `s3_us_east_1_regional_endpoint`
-
- // DefaultSharedConfigProfile is the default profile to be used when
- // loading configuration from the config files if another profile name
- // is not provided.
- DefaultSharedConfigProfile = `default`
-
- // S3 ARN Region Usage
- s3UseARNRegionKey = "s3_use_arn_region"
-)
-
-// sharedConfig represents the configuration fields of the SDK config files.
-type sharedConfig struct {
- // Credentials values from the config file. Both aws_access_key_id and
- // aws_secret_access_key must be provided together in the same file to be
- // considered valid. The values will be ignored if not a complete group.
- // aws_session_token is an optional field that can be provided if both of
- // the other two fields are also provided.
- //
- // aws_access_key_id
- // aws_secret_access_key
- // aws_session_token
- Creds credentials.Value
-
- CredentialSource string
- CredentialProcess string
- WebIdentityTokenFile string
-
- RoleARN string
- RoleSessionName string
- ExternalID string
- MFASerial string
- AssumeRoleDuration *time.Duration
-
- SourceProfileName string
- SourceProfile *sharedConfig
-
- // Region is the region the SDK should use for looking up AWS service
- // endpoints and signing requests.
- //
- // region
- Region string
-
- // EnableEndpointDiscovery can be enabled in the shared config by setting
- // endpoint_discovery_enabled to true
- //
- // endpoint_discovery_enabled = true
- EnableEndpointDiscovery *bool
-
- // CSM Options
- CSMEnabled *bool
- CSMHost string
- CSMPort string
- CSMClientID string
-
- // Specifies the Regional Endpoint flag for the SDK to resolve the endpoint for a service
- //
- // sts_regional_endpoints = regional
- // This can take value as `LegacySTSEndpoint` or `RegionalSTSEndpoint`
- STSRegionalEndpoint endpoints.STSRegionalEndpoint
-
- // Specifies the Regional Endpoint flag for the SDK to resolve the endpoint for a service
- //
- // s3_us_east_1_regional_endpoint = regional
- // This can take value as `LegacyS3UsEast1Endpoint` or `RegionalS3UsEast1Endpoint`
- S3UsEast1RegionalEndpoint endpoints.S3UsEast1RegionalEndpoint
-
- // Specifies if the S3 service should allow ARNs to direct the region
- // the client's requests are sent to.
- //
- // s3_use_arn_region=true
- S3UseARNRegion bool
-}
-
-type sharedConfigFile struct {
- Filename string
- IniData ini.Sections
-}
-
-// loadSharedConfig retrieves the configuration from the list of files using
-// the profile provided. The order the files are listed will determine
-// precedence. Values in subsequent files will overwrite values defined in
-// earlier files.
-//
-// For example, given two files A and B. Both define credentials. If the order
-// of the files are A then B, B's credential values will be used instead of
-// A's.
-//
-// See sharedConfig.setFromFile for information how the config files
-// will be loaded.
-func loadSharedConfig(profile string, filenames []string, exOpts bool) (sharedConfig, error) {
- if len(profile) == 0 {
- profile = DefaultSharedConfigProfile
- }
-
- files, err := loadSharedConfigIniFiles(filenames)
- if err != nil {
- return sharedConfig{}, err
- }
-
- cfg := sharedConfig{}
- profiles := map[string]struct{}{}
- if err = cfg.setFromIniFiles(profiles, profile, files, exOpts); err != nil {
- return sharedConfig{}, err
- }
-
- return cfg, nil
-}
-
-func loadSharedConfigIniFiles(filenames []string) ([]sharedConfigFile, error) {
- files := make([]sharedConfigFile, 0, len(filenames))
-
- for _, filename := range filenames {
- sections, err := ini.OpenFile(filename)
- if aerr, ok := err.(awserr.Error); ok && aerr.Code() == ini.ErrCodeUnableToReadFile {
- // Skip files which can't be opened and read for whatever reason
- continue
- } else if err != nil {
- return nil, SharedConfigLoadError{Filename: filename, Err: err}
- }
-
- files = append(files, sharedConfigFile{
- Filename: filename, IniData: sections,
- })
- }
-
- return files, nil
-}
-
-func (cfg *sharedConfig) setFromIniFiles(profiles map[string]struct{}, profile string, files []sharedConfigFile, exOpts bool) error {
- // Trim files from the list that don't exist.
- var skippedFiles int
- var profileNotFoundErr error
- for _, f := range files {
- if err := cfg.setFromIniFile(profile, f, exOpts); err != nil {
- if _, ok := err.(SharedConfigProfileNotExistsError); ok {
- // Ignore profiles not defined in individual files.
- profileNotFoundErr = err
- skippedFiles++
- continue
- }
- return err
- }
- }
- if skippedFiles == len(files) {
- // If all files were skipped because the profile is not found, return
- // the original profile not found error.
- return profileNotFoundErr
- }
-
- if _, ok := profiles[profile]; ok {
- // if this is the second instance of the profile the Assume Role
- // options must be cleared because they are only valid for the
- // first reference of a profile. The self linked instance of the
- // profile only have credential provider options.
- cfg.clearAssumeRoleOptions()
- } else {
- // First time a profile has been seen, It must either be a assume role
- // or credentials. Assert if the credential type requires a role ARN,
- // the ARN is also set.
- if err := cfg.validateCredentialsRequireARN(profile); err != nil {
- return err
- }
- }
- profiles[profile] = struct{}{}
-
- if err := cfg.validateCredentialType(); err != nil {
- return err
- }
-
- // Link source profiles for assume roles
- if len(cfg.SourceProfileName) != 0 {
- // Linked profile via source_profile ignore credential provider
- // options, the source profile must provide the credentials.
- cfg.clearCredentialOptions()
-
- srcCfg := &sharedConfig{}
- err := srcCfg.setFromIniFiles(profiles, cfg.SourceProfileName, files, exOpts)
- if err != nil {
- // SourceProfile that doesn't exist is an error in configuration.
- if _, ok := err.(SharedConfigProfileNotExistsError); ok {
- err = SharedConfigAssumeRoleError{
- RoleARN: cfg.RoleARN,
- SourceProfile: cfg.SourceProfileName,
- }
- }
- return err
- }
-
- if !srcCfg.hasCredentials() {
- return SharedConfigAssumeRoleError{
- RoleARN: cfg.RoleARN,
- SourceProfile: cfg.SourceProfileName,
- }
- }
-
- cfg.SourceProfile = srcCfg
- }
-
- return nil
-}
-
-// setFromFile loads the configuration from the file using the profile
-// provided. A sharedConfig pointer type value is used so that multiple config
-// file loadings can be chained.
-//
-// Only loads complete logically grouped values, and will not set fields in cfg
-// for incomplete grouped values in the config. Such as credentials. For
-// example if a config file only includes aws_access_key_id but no
-// aws_secret_access_key the aws_access_key_id will be ignored.
-func (cfg *sharedConfig) setFromIniFile(profile string, file sharedConfigFile, exOpts bool) error {
- section, ok := file.IniData.GetSection(profile)
- if !ok {
- // Fallback to to alternate profile name: profile
- section, ok = file.IniData.GetSection(fmt.Sprintf("profile %s", profile))
- if !ok {
- return SharedConfigProfileNotExistsError{Profile: profile, Err: nil}
- }
- }
-
- if exOpts {
- // Assume Role Parameters
- updateString(&cfg.RoleARN, section, roleArnKey)
- updateString(&cfg.ExternalID, section, externalIDKey)
- updateString(&cfg.MFASerial, section, mfaSerialKey)
- updateString(&cfg.RoleSessionName, section, roleSessionNameKey)
- updateString(&cfg.SourceProfileName, section, sourceProfileKey)
- updateString(&cfg.CredentialSource, section, credentialSourceKey)
- updateString(&cfg.Region, section, regionKey)
-
- if section.Has(roleDurationSecondsKey) {
- d := time.Duration(section.Int(roleDurationSecondsKey)) * time.Second
- cfg.AssumeRoleDuration = &d
- }
-
- if v := section.String(stsRegionalEndpointSharedKey); len(v) != 0 {
- sre, err := endpoints.GetSTSRegionalEndpoint(v)
- if err != nil {
- return fmt.Errorf("failed to load %s from shared config, %s, %v",
- stsRegionalEndpointSharedKey, file.Filename, err)
- }
- cfg.STSRegionalEndpoint = sre
- }
-
- if v := section.String(s3UsEast1RegionalSharedKey); len(v) != 0 {
- sre, err := endpoints.GetS3UsEast1RegionalEndpoint(v)
- if err != nil {
- return fmt.Errorf("failed to load %s from shared config, %s, %v",
- s3UsEast1RegionalSharedKey, file.Filename, err)
- }
- cfg.S3UsEast1RegionalEndpoint = sre
- }
- }
-
- updateString(&cfg.CredentialProcess, section, credentialProcessKey)
- updateString(&cfg.WebIdentityTokenFile, section, webIdentityTokenFileKey)
-
- // Shared Credentials
- creds := credentials.Value{
- AccessKeyID: section.String(accessKeyIDKey),
- SecretAccessKey: section.String(secretAccessKey),
- SessionToken: section.String(sessionTokenKey),
- ProviderName: fmt.Sprintf("SharedConfigCredentials: %s", file.Filename),
- }
- if creds.HasKeys() {
- cfg.Creds = creds
- }
-
- // Endpoint discovery
- updateBoolPtr(&cfg.EnableEndpointDiscovery, section, enableEndpointDiscoveryKey)
-
- // CSM options
- updateBoolPtr(&cfg.CSMEnabled, section, csmEnabledKey)
- updateString(&cfg.CSMHost, section, csmHostKey)
- updateString(&cfg.CSMPort, section, csmPortKey)
- updateString(&cfg.CSMClientID, section, csmClientIDKey)
-
- updateBool(&cfg.S3UseARNRegion, section, s3UseARNRegionKey)
-
- return nil
-}
-
-func (cfg *sharedConfig) validateCredentialsRequireARN(profile string) error {
- var credSource string
-
- switch {
- case len(cfg.SourceProfileName) != 0:
- credSource = sourceProfileKey
- case len(cfg.CredentialSource) != 0:
- credSource = credentialSourceKey
- case len(cfg.WebIdentityTokenFile) != 0:
- credSource = webIdentityTokenFileKey
- }
-
- if len(credSource) != 0 && len(cfg.RoleARN) == 0 {
- return CredentialRequiresARNError{
- Type: credSource,
- Profile: profile,
- }
- }
-
- return nil
-}
-
-func (cfg *sharedConfig) validateCredentialType() error {
- // Only one or no credential type can be defined.
- if !oneOrNone(
- len(cfg.SourceProfileName) != 0,
- len(cfg.CredentialSource) != 0,
- len(cfg.CredentialProcess) != 0,
- len(cfg.WebIdentityTokenFile) != 0,
- ) {
- return ErrSharedConfigSourceCollision
- }
-
- return nil
-}
-
-func (cfg *sharedConfig) hasCredentials() bool {
- switch {
- case len(cfg.SourceProfileName) != 0:
- case len(cfg.CredentialSource) != 0:
- case len(cfg.CredentialProcess) != 0:
- case len(cfg.WebIdentityTokenFile) != 0:
- case cfg.Creds.HasKeys():
- default:
- return false
- }
-
- return true
-}
-
-func (cfg *sharedConfig) clearCredentialOptions() {
- cfg.CredentialSource = ""
- cfg.CredentialProcess = ""
- cfg.WebIdentityTokenFile = ""
- cfg.Creds = credentials.Value{}
-}
-
-func (cfg *sharedConfig) clearAssumeRoleOptions() {
- cfg.RoleARN = ""
- cfg.ExternalID = ""
- cfg.MFASerial = ""
- cfg.RoleSessionName = ""
- cfg.SourceProfileName = ""
-}
-
-func oneOrNone(bs ...bool) bool {
- var count int
-
- for _, b := range bs {
- if b {
- count++
- if count > 1 {
- return false
- }
- }
- }
-
- return true
-}
-
-// updateString will only update the dst with the value in the section key, key
-// is present in the section.
-func updateString(dst *string, section ini.Section, key string) {
- if !section.Has(key) {
- return
- }
- *dst = section.String(key)
-}
-
-// updateBool will only update the dst with the value in the section key, key
-// is present in the section.
-func updateBool(dst *bool, section ini.Section, key string) {
- if !section.Has(key) {
- return
- }
- *dst = section.Bool(key)
-}
-
-// updateBoolPtr will only update the dst with the value in the section key,
-// key is present in the section.
-func updateBoolPtr(dst **bool, section ini.Section, key string) {
- if !section.Has(key) {
- return
- }
- *dst = new(bool)
- **dst = section.Bool(key)
-}
-
-// SharedConfigLoadError is an error for the shared config file failed to load.
-type SharedConfigLoadError struct {
- Filename string
- Err error
-}
-
-// Code is the short id of the error.
-func (e SharedConfigLoadError) Code() string {
- return "SharedConfigLoadError"
-}
-
-// Message is the description of the error
-func (e SharedConfigLoadError) Message() string {
- return fmt.Sprintf("failed to load config file, %s", e.Filename)
-}
-
-// OrigErr is the underlying error that caused the failure.
-func (e SharedConfigLoadError) OrigErr() error {
- return e.Err
-}
-
-// Error satisfies the error interface.
-func (e SharedConfigLoadError) Error() string {
- return awserr.SprintError(e.Code(), e.Message(), "", e.Err)
-}
-
-// SharedConfigProfileNotExistsError is an error for the shared config when
-// the profile was not find in the config file.
-type SharedConfigProfileNotExistsError struct {
- Profile string
- Err error
-}
-
-// Code is the short id of the error.
-func (e SharedConfigProfileNotExistsError) Code() string {
- return "SharedConfigProfileNotExistsError"
-}
-
-// Message is the description of the error
-func (e SharedConfigProfileNotExistsError) Message() string {
- return fmt.Sprintf("failed to get profile, %s", e.Profile)
-}
-
-// OrigErr is the underlying error that caused the failure.
-func (e SharedConfigProfileNotExistsError) OrigErr() error {
- return e.Err
-}
-
-// Error satisfies the error interface.
-func (e SharedConfigProfileNotExistsError) Error() string {
- return awserr.SprintError(e.Code(), e.Message(), "", e.Err)
-}
-
-// SharedConfigAssumeRoleError is an error for the shared config when the
-// profile contains assume role information, but that information is invalid
-// or not complete.
-type SharedConfigAssumeRoleError struct {
- RoleARN string
- SourceProfile string
-}
-
-// Code is the short id of the error.
-func (e SharedConfigAssumeRoleError) Code() string {
- return "SharedConfigAssumeRoleError"
-}
-
-// Message is the description of the error
-func (e SharedConfigAssumeRoleError) Message() string {
- return fmt.Sprintf(
- "failed to load assume role for %s, source profile %s has no shared credentials",
- e.RoleARN, e.SourceProfile,
- )
-}
-
-// OrigErr is the underlying error that caused the failure.
-func (e SharedConfigAssumeRoleError) OrigErr() error {
- return nil
-}
-
-// Error satisfies the error interface.
-func (e SharedConfigAssumeRoleError) Error() string {
- return awserr.SprintError(e.Code(), e.Message(), "", nil)
-}
-
-// CredentialRequiresARNError provides the error for shared config credentials
-// that are incorrectly configured in the shared config or credentials file.
-type CredentialRequiresARNError struct {
- // type of credentials that were configured.
- Type string
-
- // Profile name the credentials were in.
- Profile string
-}
-
-// Code is the short id of the error.
-func (e CredentialRequiresARNError) Code() string {
- return "CredentialRequiresARNError"
-}
-
-// Message is the description of the error
-func (e CredentialRequiresARNError) Message() string {
- return fmt.Sprintf(
- "credential type %s requires role_arn, profile %s",
- e.Type, e.Profile,
- )
-}
-
-// OrigErr is the underlying error that caused the failure.
-func (e CredentialRequiresARNError) OrigErr() error {
- return nil
-}
-
-// Error satisfies the error interface.
-func (e CredentialRequiresARNError) Error() string {
- return awserr.SprintError(e.Code(), e.Message(), "", nil)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/header_rules.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/header_rules.go
deleted file mode 100644
index 07ea799fbd37..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/header_rules.go
+++ /dev/null
@@ -1,81 +0,0 @@
-package v4
-
-import (
- "github.com/aws/aws-sdk-go/internal/strings"
-)
-
-// validator houses a set of rule needed for validation of a
-// string value
-type rules []rule
-
-// rule interface allows for more flexible rules and just simply
-// checks whether or not a value adheres to that rule
-type rule interface {
- IsValid(value string) bool
-}
-
-// IsValid will iterate through all rules and see if any rules
-// apply to the value and supports nested rules
-func (r rules) IsValid(value string) bool {
- for _, rule := range r {
- if rule.IsValid(value) {
- return true
- }
- }
- return false
-}
-
-// mapRule generic rule for maps
-type mapRule map[string]struct{}
-
-// IsValid for the map rule satisfies whether it exists in the map
-func (m mapRule) IsValid(value string) bool {
- _, ok := m[value]
- return ok
-}
-
-// whitelist is a generic rule for whitelisting
-type whitelist struct {
- rule
-}
-
-// IsValid for whitelist checks if the value is within the whitelist
-func (w whitelist) IsValid(value string) bool {
- return w.rule.IsValid(value)
-}
-
-// blacklist is a generic rule for blacklisting
-type blacklist struct {
- rule
-}
-
-// IsValid for whitelist checks if the value is within the whitelist
-func (b blacklist) IsValid(value string) bool {
- return !b.rule.IsValid(value)
-}
-
-type patterns []string
-
-// IsValid for patterns checks each pattern and returns if a match has
-// been found
-func (p patterns) IsValid(value string) bool {
- for _, pattern := range p {
- if strings.HasPrefixFold(value, pattern) {
- return true
- }
- }
- return false
-}
-
-// inclusiveRules rules allow for rules to depend on one another
-type inclusiveRules []rule
-
-// IsValid will return true if all rules are true
-func (r inclusiveRules) IsValid(value string) bool {
- for _, rule := range r {
- if !rule.IsValid(value) {
- return false
- }
- }
- return true
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/options.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/options.go
deleted file mode 100644
index 6aa2ed241bb1..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/options.go
+++ /dev/null
@@ -1,7 +0,0 @@
-package v4
-
-// WithUnsignedPayload will enable and set the UnsignedPayload field to
-// true of the signer.
-func WithUnsignedPayload(v4 *Signer) {
- v4.UnsignedPayload = true
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.5.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.5.go
deleted file mode 100644
index f35fc860b3b7..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.5.go
+++ /dev/null
@@ -1,13 +0,0 @@
-// +build !go1.7
-
-package v4
-
-import (
- "net/http"
-
- "github.com/aws/aws-sdk-go/aws"
-)
-
-func requestContext(r *http.Request) aws.Context {
- return aws.BackgroundContext()
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.7.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.7.go
deleted file mode 100644
index fed5c859ca66..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/request_context_go1.7.go
+++ /dev/null
@@ -1,13 +0,0 @@
-// +build go1.7
-
-package v4
-
-import (
- "net/http"
-
- "github.com/aws/aws-sdk-go/aws"
-)
-
-func requestContext(r *http.Request) aws.Context {
- return r.Context()
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/stream.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/stream.go
deleted file mode 100644
index 02cbd97e2341..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/stream.go
+++ /dev/null
@@ -1,63 +0,0 @@
-package v4
-
-import (
- "encoding/hex"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/credentials"
-)
-
-type credentialValueProvider interface {
- Get() (credentials.Value, error)
-}
-
-// StreamSigner implements signing of event stream encoded payloads
-type StreamSigner struct {
- region string
- service string
-
- credentials credentialValueProvider
-
- prevSig []byte
-}
-
-// NewStreamSigner creates a SigV4 signer used to sign Event Stream encoded messages
-func NewStreamSigner(region, service string, seedSignature []byte, credentials *credentials.Credentials) *StreamSigner {
- return &StreamSigner{
- region: region,
- service: service,
- credentials: credentials,
- prevSig: seedSignature,
- }
-}
-
-// GetSignature takes an event stream encoded headers and payload and returns a signature
-func (s *StreamSigner) GetSignature(headers, payload []byte, date time.Time) ([]byte, error) {
- credValue, err := s.credentials.Get()
- if err != nil {
- return nil, err
- }
-
- sigKey := deriveSigningKey(s.region, s.service, credValue.SecretAccessKey, date)
-
- keyPath := buildSigningScope(s.region, s.service, date)
-
- stringToSign := buildEventStreamStringToSign(headers, payload, s.prevSig, keyPath, date)
-
- signature := hmacSHA256(sigKey, []byte(stringToSign))
- s.prevSig = signature
-
- return signature, nil
-}
-
-func buildEventStreamStringToSign(headers, payload, prevSig []byte, scope string, date time.Time) string {
- return strings.Join([]string{
- "AWS4-HMAC-SHA256-PAYLOAD",
- formatTime(date),
- scope,
- hex.EncodeToString(prevSig),
- hex.EncodeToString(hashSHA256(headers)),
- hex.EncodeToString(hashSHA256(payload)),
- }, "\n")
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/uri_path.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/uri_path.go
deleted file mode 100644
index bd082e9d1f78..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/uri_path.go
+++ /dev/null
@@ -1,24 +0,0 @@
-// +build go1.5
-
-package v4
-
-import (
- "net/url"
- "strings"
-)
-
-func getURIPath(u *url.URL) string {
- var uri string
-
- if len(u.Opaque) > 0 {
- uri = "/" + strings.Join(strings.Split(u.Opaque, "/")[3:], "/")
- } else {
- uri = u.EscapedPath()
- }
-
- if len(uri) == 0 {
- uri = "/"
- }
-
- return uri
-}
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
deleted file mode 100644
index d71f7b3f4fa0..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go
+++ /dev/null
@@ -1,846 +0,0 @@
-// Package v4 implements signing for AWS V4 signer
-//
-// Provides request signing for request that need to be signed with
-// AWS V4 Signatures.
-//
-// Standalone Signer
-//
-// Generally using the signer outside of the SDK should not require any additional
-// logic when using Go v1.5 or higher. The signer does this by taking advantage
-// of the URL.EscapedPath method. If your request URI requires additional escaping
-// you many need to use the URL.Opaque to define what the raw URI should be sent
-// to the service as.
-//
-// The signer will first check the URL.Opaque field, and use its value if set.
-// The signer does require the URL.Opaque field to be set in the form of:
-//
-// "///"
-//
-// // e.g.
-// "//example.com/some/path"
-//
-// The leading "//" and hostname are required or the URL.Opaque escaping will
-// not work correctly.
-//
-// If URL.Opaque is not set the signer will fallback to the URL.EscapedPath()
-// method and using the returned value. If you're using Go v1.4 you must set
-// URL.Opaque if the URI path needs escaping. If URL.Opaque is not set with
-// Go v1.5 the signer will fallback to URL.Path.
-//
-// AWS v4 signature validation requires that the canonical string's URI path
-// element must be the URI escaped form of the HTTP request's path.
-// http://docs.aws.amazon.com/general/latest/gr/sigv4-create-canonical-request.html
-//
-// The Go HTTP client will perform escaping automatically on the request. Some
-// of these escaping may cause signature validation errors because the HTTP
-// request differs from the URI path or query that the signature was generated.
-// https://golang.org/pkg/net/url/#URL.EscapedPath
-//
-// Because of this, it is recommended that when using the signer outside of the
-// SDK that explicitly escaping the request prior to being signed is preferable,
-// and will help prevent signature validation errors. This can be done by setting
-// the URL.Opaque or URL.RawPath. The SDK will use URL.Opaque first and then
-// call URL.EscapedPath() if Opaque is not set.
-//
-// If signing a request intended for HTTP2 server, and you're using Go 1.6.2
-// through 1.7.4 you should use the URL.RawPath as the pre-escaped form of the
-// request URL. https://github.com/golang/go/issues/16847 points to a bug in
-// Go pre 1.8 that fails to make HTTP2 requests using absolute URL in the HTTP
-// message. URL.Opaque generally will force Go to make requests with absolute URL.
-// URL.RawPath does not do this, but RawPath must be a valid escaping of Path
-// or url.EscapedPath will ignore the RawPath escaping.
-//
-// Test `TestStandaloneSign` provides a complete example of using the signer
-// outside of the SDK and pre-escaping the URI path.
-package v4
-
-import (
- "crypto/hmac"
- "crypto/sha256"
- "encoding/hex"
- "fmt"
- "io"
- "io/ioutil"
- "net/http"
- "net/url"
- "sort"
- "strconv"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/internal/sdkio"
- "github.com/aws/aws-sdk-go/private/protocol/rest"
-)
-
-const (
- authorizationHeader = "Authorization"
- authHeaderSignatureElem = "Signature="
- signatureQueryKey = "X-Amz-Signature"
-
- authHeaderPrefix = "AWS4-HMAC-SHA256"
- timeFormat = "20060102T150405Z"
- shortTimeFormat = "20060102"
- awsV4Request = "aws4_request"
-
- // emptyStringSHA256 is a SHA256 of an empty string
- emptyStringSHA256 = `e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855`
-)
-
-var ignoredHeaders = rules{
- blacklist{
- mapRule{
- authorizationHeader: struct{}{},
- "User-Agent": struct{}{},
- "X-Amzn-Trace-Id": struct{}{},
- },
- },
-}
-
-// requiredSignedHeaders is a whitelist for build canonical headers.
-var requiredSignedHeaders = rules{
- whitelist{
- mapRule{
- "Cache-Control": struct{}{},
- "Content-Disposition": struct{}{},
- "Content-Encoding": struct{}{},
- "Content-Language": struct{}{},
- "Content-Md5": struct{}{},
- "Content-Type": struct{}{},
- "Expires": struct{}{},
- "If-Match": struct{}{},
- "If-Modified-Since": struct{}{},
- "If-None-Match": struct{}{},
- "If-Unmodified-Since": struct{}{},
- "Range": struct{}{},
- "X-Amz-Acl": struct{}{},
- "X-Amz-Copy-Source": struct{}{},
- "X-Amz-Copy-Source-If-Match": struct{}{},
- "X-Amz-Copy-Source-If-Modified-Since": struct{}{},
- "X-Amz-Copy-Source-If-None-Match": struct{}{},
- "X-Amz-Copy-Source-If-Unmodified-Since": struct{}{},
- "X-Amz-Copy-Source-Range": struct{}{},
- "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Algorithm": struct{}{},
- "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Key": struct{}{},
- "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Key-Md5": struct{}{},
- "X-Amz-Grant-Full-control": struct{}{},
- "X-Amz-Grant-Read": struct{}{},
- "X-Amz-Grant-Read-Acp": struct{}{},
- "X-Amz-Grant-Write": struct{}{},
- "X-Amz-Grant-Write-Acp": struct{}{},
- "X-Amz-Metadata-Directive": struct{}{},
- "X-Amz-Mfa": struct{}{},
- "X-Amz-Request-Payer": struct{}{},
- "X-Amz-Server-Side-Encryption": struct{}{},
- "X-Amz-Server-Side-Encryption-Aws-Kms-Key-Id": struct{}{},
- "X-Amz-Server-Side-Encryption-Customer-Algorithm": struct{}{},
- "X-Amz-Server-Side-Encryption-Customer-Key": struct{}{},
- "X-Amz-Server-Side-Encryption-Customer-Key-Md5": struct{}{},
- "X-Amz-Storage-Class": struct{}{},
- "X-Amz-Tagging": struct{}{},
- "X-Amz-Website-Redirect-Location": struct{}{},
- "X-Amz-Content-Sha256": struct{}{},
- },
- },
- patterns{"X-Amz-Meta-"},
-}
-
-// allowedHoisting is a whitelist for build query headers. The boolean value
-// represents whether or not it is a pattern.
-var allowedQueryHoisting = inclusiveRules{
- blacklist{requiredSignedHeaders},
- patterns{"X-Amz-"},
-}
-
-// Signer applies AWS v4 signing to given request. Use this to sign requests
-// that need to be signed with AWS V4 Signatures.
-type Signer struct {
- // The authentication credentials the request will be signed against.
- // This value must be set to sign requests.
- Credentials *credentials.Credentials
-
- // Sets the log level the signer should use when reporting information to
- // the logger. If the logger is nil nothing will be logged. See
- // aws.LogLevelType for more information on available logging levels
- //
- // By default nothing will be logged.
- Debug aws.LogLevelType
-
- // The logger loging information will be written to. If there the logger
- // is nil, nothing will be logged.
- Logger aws.Logger
-
- // Disables the Signer's moving HTTP header key/value pairs from the HTTP
- // request header to the request's query string. This is most commonly used
- // with pre-signed requests preventing headers from being added to the
- // request's query string.
- DisableHeaderHoisting bool
-
- // Disables the automatic escaping of the URI path of the request for the
- // siganture's canonical string's path. For services that do not need additional
- // escaping then use this to disable the signer escaping the path.
- //
- // S3 is an example of a service that does not need additional escaping.
- //
- // http://docs.aws.amazon.com/general/latest/gr/sigv4-create-canonical-request.html
- DisableURIPathEscaping bool
-
- // Disables the automatical setting of the HTTP request's Body field with the
- // io.ReadSeeker passed in to the signer. This is useful if you're using a
- // custom wrapper around the body for the io.ReadSeeker and want to preserve
- // the Body value on the Request.Body.
- //
- // This does run the risk of signing a request with a body that will not be
- // sent in the request. Need to ensure that the underlying data of the Body
- // values are the same.
- DisableRequestBodyOverwrite bool
-
- // currentTimeFn returns the time value which represents the current time.
- // This value should only be used for testing. If it is nil the default
- // time.Now will be used.
- currentTimeFn func() time.Time
-
- // UnsignedPayload will prevent signing of the payload. This will only
- // work for services that have support for this.
- UnsignedPayload bool
-}
-
-// NewSigner returns a Signer pointer configured with the credentials and optional
-// option values provided. If not options are provided the Signer will use its
-// default configuration.
-func NewSigner(credentials *credentials.Credentials, options ...func(*Signer)) *Signer {
- v4 := &Signer{
- Credentials: credentials,
- }
-
- for _, option := range options {
- option(v4)
- }
-
- return v4
-}
-
-type signingCtx struct {
- ServiceName string
- Region string
- Request *http.Request
- Body io.ReadSeeker
- Query url.Values
- Time time.Time
- ExpireTime time.Duration
- SignedHeaderVals http.Header
-
- DisableURIPathEscaping bool
-
- credValues credentials.Value
- isPresign bool
- unsignedPayload bool
-
- bodyDigest string
- signedHeaders string
- canonicalHeaders string
- canonicalString string
- credentialString string
- stringToSign string
- signature string
- authorization string
-}
-
-// Sign signs AWS v4 requests with the provided body, service name, region the
-// request is made to, and time the request is signed at. The signTime allows
-// you to specify that a request is signed for the future, and cannot be
-// used until then.
-//
-// Returns a list of HTTP headers that were included in the signature or an
-// error if signing the request failed. Generally for signed requests this value
-// is not needed as the full request context will be captured by the http.Request
-// value. It is included for reference though.
-//
-// Sign will set the request's Body to be the `body` parameter passed in. If
-// the body is not already an io.ReadCloser, it will be wrapped within one. If
-// a `nil` body parameter passed to Sign, the request's Body field will be
-// also set to nil. Its important to note that this functionality will not
-// change the request's ContentLength of the request.
-//
-// Sign differs from Presign in that it will sign the request using HTTP
-// header values. This type of signing is intended for http.Request values that
-// will not be shared, or are shared in a way the header values on the request
-// will not be lost.
-//
-// The requests body is an io.ReadSeeker so the SHA256 of the body can be
-// generated. To bypass the signer computing the hash you can set the
-// "X-Amz-Content-Sha256" header with a precomputed value. The signer will
-// only compute the hash if the request header value is empty.
-func (v4 Signer) Sign(r *http.Request, body io.ReadSeeker, service, region string, signTime time.Time) (http.Header, error) {
- return v4.signWithBody(r, body, service, region, 0, false, signTime)
-}
-
-// Presign signs AWS v4 requests with the provided body, service name, region
-// the request is made to, and time the request is signed at. The signTime
-// allows you to specify that a request is signed for the future, and cannot
-// be used until then.
-//
-// Returns a list of HTTP headers that were included in the signature or an
-// error if signing the request failed. For presigned requests these headers
-// and their values must be included on the HTTP request when it is made. This
-// is helpful to know what header values need to be shared with the party the
-// presigned request will be distributed to.
-//
-// Presign differs from Sign in that it will sign the request using query string
-// instead of header values. This allows you to share the Presigned Request's
-// URL with third parties, or distribute it throughout your system with minimal
-// dependencies.
-//
-// Presign also takes an exp value which is the duration the
-// signed request will be valid after the signing time. This is allows you to
-// set when the request will expire.
-//
-// The requests body is an io.ReadSeeker so the SHA256 of the body can be
-// generated. To bypass the signer computing the hash you can set the
-// "X-Amz-Content-Sha256" header with a precomputed value. The signer will
-// only compute the hash if the request header value is empty.
-//
-// Presigning a S3 request will not compute the body's SHA256 hash by default.
-// This is done due to the general use case for S3 presigned URLs is to share
-// PUT/GET capabilities. If you would like to include the body's SHA256 in the
-// presigned request's signature you can set the "X-Amz-Content-Sha256"
-// HTTP header and that will be included in the request's signature.
-func (v4 Signer) Presign(r *http.Request, body io.ReadSeeker, service, region string, exp time.Duration, signTime time.Time) (http.Header, error) {
- return v4.signWithBody(r, body, service, region, exp, true, signTime)
-}
-
-func (v4 Signer) signWithBody(r *http.Request, body io.ReadSeeker, service, region string, exp time.Duration, isPresign bool, signTime time.Time) (http.Header, error) {
- currentTimeFn := v4.currentTimeFn
- if currentTimeFn == nil {
- currentTimeFn = time.Now
- }
-
- ctx := &signingCtx{
- Request: r,
- Body: body,
- Query: r.URL.Query(),
- Time: signTime,
- ExpireTime: exp,
- isPresign: isPresign,
- ServiceName: service,
- Region: region,
- DisableURIPathEscaping: v4.DisableURIPathEscaping,
- unsignedPayload: v4.UnsignedPayload,
- }
-
- for key := range ctx.Query {
- sort.Strings(ctx.Query[key])
- }
-
- if ctx.isRequestSigned() {
- ctx.Time = currentTimeFn()
- ctx.handlePresignRemoval()
- }
-
- var err error
- ctx.credValues, err = v4.Credentials.GetWithContext(requestContext(r))
- if err != nil {
- return http.Header{}, err
- }
-
- ctx.sanitizeHostForHeader()
- ctx.assignAmzQueryValues()
- if err := ctx.build(v4.DisableHeaderHoisting); err != nil {
- return nil, err
- }
-
- // If the request is not presigned the body should be attached to it. This
- // prevents the confusion of wanting to send a signed request without
- // the body the request was signed for attached.
- if !(v4.DisableRequestBodyOverwrite || ctx.isPresign) {
- var reader io.ReadCloser
- if body != nil {
- var ok bool
- if reader, ok = body.(io.ReadCloser); !ok {
- reader = ioutil.NopCloser(body)
- }
- }
- r.Body = reader
- }
-
- if v4.Debug.Matches(aws.LogDebugWithSigning) {
- v4.logSigningInfo(ctx)
- }
-
- return ctx.SignedHeaderVals, nil
-}
-
-func (ctx *signingCtx) sanitizeHostForHeader() {
- request.SanitizeHostForHeader(ctx.Request)
-}
-
-func (ctx *signingCtx) handlePresignRemoval() {
- if !ctx.isPresign {
- return
- }
-
- // The credentials have expired for this request. The current signing
- // is invalid, and needs to be request because the request will fail.
- ctx.removePresign()
-
- // Update the request's query string to ensure the values stays in
- // sync in the case retrieving the new credentials fails.
- ctx.Request.URL.RawQuery = ctx.Query.Encode()
-}
-
-func (ctx *signingCtx) assignAmzQueryValues() {
- if ctx.isPresign {
- ctx.Query.Set("X-Amz-Algorithm", authHeaderPrefix)
- if ctx.credValues.SessionToken != "" {
- ctx.Query.Set("X-Amz-Security-Token", ctx.credValues.SessionToken)
- } else {
- ctx.Query.Del("X-Amz-Security-Token")
- }
-
- return
- }
-
- if ctx.credValues.SessionToken != "" {
- ctx.Request.Header.Set("X-Amz-Security-Token", ctx.credValues.SessionToken)
- }
-}
-
-// SignRequestHandler is a named request handler the SDK will use to sign
-// service client request with using the V4 signature.
-var SignRequestHandler = request.NamedHandler{
- Name: "v4.SignRequestHandler", Fn: SignSDKRequest,
-}
-
-// SignSDKRequest signs an AWS request with the V4 signature. This
-// request handler should only be used with the SDK's built in service client's
-// API operation requests.
-//
-// This function should not be used on its on its own, but in conjunction with
-// an AWS service client's API operation call. To sign a standalone request
-// not created by a service client's API operation method use the "Sign" or
-// "Presign" functions of the "Signer" type.
-//
-// If the credentials of the request's config are set to
-// credentials.AnonymousCredentials the request will not be signed.
-func SignSDKRequest(req *request.Request) {
- SignSDKRequestWithCurrentTime(req, time.Now)
-}
-
-// BuildNamedHandler will build a generic handler for signing.
-func BuildNamedHandler(name string, opts ...func(*Signer)) request.NamedHandler {
- return request.NamedHandler{
- Name: name,
- Fn: func(req *request.Request) {
- SignSDKRequestWithCurrentTime(req, time.Now, opts...)
- },
- }
-}
-
-// SignSDKRequestWithCurrentTime will sign the SDK's request using the time
-// function passed in. Behaves the same as SignSDKRequest with the exception
-// the request is signed with the value returned by the current time function.
-func SignSDKRequestWithCurrentTime(req *request.Request, curTimeFn func() time.Time, opts ...func(*Signer)) {
- // If the request does not need to be signed ignore the signing of the
- // request if the AnonymousCredentials object is used.
- if req.Config.Credentials == credentials.AnonymousCredentials {
- return
- }
-
- region := req.ClientInfo.SigningRegion
- if region == "" {
- region = aws.StringValue(req.Config.Region)
- }
-
- name := req.ClientInfo.SigningName
- if name == "" {
- name = req.ClientInfo.ServiceName
- }
-
- v4 := NewSigner(req.Config.Credentials, func(v4 *Signer) {
- v4.Debug = req.Config.LogLevel.Value()
- v4.Logger = req.Config.Logger
- v4.DisableHeaderHoisting = req.NotHoist
- v4.currentTimeFn = curTimeFn
- if name == "s3" {
- // S3 service should not have any escaping applied
- v4.DisableURIPathEscaping = true
- }
- // Prevents setting the HTTPRequest's Body. Since the Body could be
- // wrapped in a custom io.Closer that we do not want to be stompped
- // on top of by the signer.
- v4.DisableRequestBodyOverwrite = true
- })
-
- for _, opt := range opts {
- opt(v4)
- }
-
- curTime := curTimeFn()
- signedHeaders, err := v4.signWithBody(req.HTTPRequest, req.GetBody(),
- name, region, req.ExpireTime, req.ExpireTime > 0, curTime,
- )
- if err != nil {
- req.Error = err
- req.SignedHeaderVals = nil
- return
- }
-
- req.SignedHeaderVals = signedHeaders
- req.LastSignedAt = curTime
-}
-
-const logSignInfoMsg = `DEBUG: Request Signature:
----[ CANONICAL STRING ]-----------------------------
-%s
----[ STRING TO SIGN ]--------------------------------
-%s%s
------------------------------------------------------`
-const logSignedURLMsg = `
----[ SIGNED URL ]------------------------------------
-%s`
-
-func (v4 *Signer) logSigningInfo(ctx *signingCtx) {
- signedURLMsg := ""
- if ctx.isPresign {
- signedURLMsg = fmt.Sprintf(logSignedURLMsg, ctx.Request.URL.String())
- }
- msg := fmt.Sprintf(logSignInfoMsg, ctx.canonicalString, ctx.stringToSign, signedURLMsg)
- v4.Logger.Log(msg)
-}
-
-func (ctx *signingCtx) build(disableHeaderHoisting bool) error {
- ctx.buildTime() // no depends
- ctx.buildCredentialString() // no depends
-
- if err := ctx.buildBodyDigest(); err != nil {
- return err
- }
-
- unsignedHeaders := ctx.Request.Header
- if ctx.isPresign {
- if !disableHeaderHoisting {
- urlValues := url.Values{}
- urlValues, unsignedHeaders = buildQuery(allowedQueryHoisting, unsignedHeaders) // no depends
- for k := range urlValues {
- ctx.Query[k] = urlValues[k]
- }
- }
- }
-
- ctx.buildCanonicalHeaders(ignoredHeaders, unsignedHeaders)
- ctx.buildCanonicalString() // depends on canon headers / signed headers
- ctx.buildStringToSign() // depends on canon string
- ctx.buildSignature() // depends on string to sign
-
- if ctx.isPresign {
- ctx.Request.URL.RawQuery += "&" + signatureQueryKey + "=" + ctx.signature
- } else {
- parts := []string{
- authHeaderPrefix + " Credential=" + ctx.credValues.AccessKeyID + "/" + ctx.credentialString,
- "SignedHeaders=" + ctx.signedHeaders,
- authHeaderSignatureElem + ctx.signature,
- }
- ctx.Request.Header.Set(authorizationHeader, strings.Join(parts, ", "))
- }
-
- return nil
-}
-
-// GetSignedRequestSignature attempts to extract the signature of the request.
-// Returning an error if the request is unsigned, or unable to extract the
-// signature.
-func GetSignedRequestSignature(r *http.Request) ([]byte, error) {
-
- if auth := r.Header.Get(authorizationHeader); len(auth) != 0 {
- ps := strings.Split(auth, ", ")
- for _, p := range ps {
- if idx := strings.Index(p, authHeaderSignatureElem); idx >= 0 {
- sig := p[len(authHeaderSignatureElem):]
- if len(sig) == 0 {
- return nil, fmt.Errorf("invalid request signature authorization header")
- }
- return hex.DecodeString(sig)
- }
- }
- }
-
- if sig := r.URL.Query().Get("X-Amz-Signature"); len(sig) != 0 {
- return hex.DecodeString(sig)
- }
-
- return nil, fmt.Errorf("request not signed")
-}
-
-func (ctx *signingCtx) buildTime() {
- if ctx.isPresign {
- duration := int64(ctx.ExpireTime / time.Second)
- ctx.Query.Set("X-Amz-Date", formatTime(ctx.Time))
- ctx.Query.Set("X-Amz-Expires", strconv.FormatInt(duration, 10))
- } else {
- ctx.Request.Header.Set("X-Amz-Date", formatTime(ctx.Time))
- }
-}
-
-func (ctx *signingCtx) buildCredentialString() {
- ctx.credentialString = buildSigningScope(ctx.Region, ctx.ServiceName, ctx.Time)
-
- if ctx.isPresign {
- ctx.Query.Set("X-Amz-Credential", ctx.credValues.AccessKeyID+"/"+ctx.credentialString)
- }
-}
-
-func buildQuery(r rule, header http.Header) (url.Values, http.Header) {
- query := url.Values{}
- unsignedHeaders := http.Header{}
- for k, h := range header {
- if r.IsValid(k) {
- query[k] = h
- } else {
- unsignedHeaders[k] = h
- }
- }
-
- return query, unsignedHeaders
-}
-func (ctx *signingCtx) buildCanonicalHeaders(r rule, header http.Header) {
- var headers []string
- headers = append(headers, "host")
- for k, v := range header {
- if !r.IsValid(k) {
- continue // ignored header
- }
- if ctx.SignedHeaderVals == nil {
- ctx.SignedHeaderVals = make(http.Header)
- }
-
- lowerCaseKey := strings.ToLower(k)
- if _, ok := ctx.SignedHeaderVals[lowerCaseKey]; ok {
- // include additional values
- ctx.SignedHeaderVals[lowerCaseKey] = append(ctx.SignedHeaderVals[lowerCaseKey], v...)
- continue
- }
-
- headers = append(headers, lowerCaseKey)
- ctx.SignedHeaderVals[lowerCaseKey] = v
- }
- sort.Strings(headers)
-
- ctx.signedHeaders = strings.Join(headers, ";")
-
- if ctx.isPresign {
- ctx.Query.Set("X-Amz-SignedHeaders", ctx.signedHeaders)
- }
-
- headerValues := make([]string, len(headers))
- for i, k := range headers {
- if k == "host" {
- if ctx.Request.Host != "" {
- headerValues[i] = "host:" + ctx.Request.Host
- } else {
- headerValues[i] = "host:" + ctx.Request.URL.Host
- }
- } else {
- headerValues[i] = k + ":" +
- strings.Join(ctx.SignedHeaderVals[k], ",")
- }
- }
- stripExcessSpaces(headerValues)
- ctx.canonicalHeaders = strings.Join(headerValues, "\n")
-}
-
-func (ctx *signingCtx) buildCanonicalString() {
- ctx.Request.URL.RawQuery = strings.Replace(ctx.Query.Encode(), "+", "%20", -1)
-
- uri := getURIPath(ctx.Request.URL)
-
- if !ctx.DisableURIPathEscaping {
- uri = rest.EscapePath(uri, false)
- }
-
- ctx.canonicalString = strings.Join([]string{
- ctx.Request.Method,
- uri,
- ctx.Request.URL.RawQuery,
- ctx.canonicalHeaders + "\n",
- ctx.signedHeaders,
- ctx.bodyDigest,
- }, "\n")
-}
-
-func (ctx *signingCtx) buildStringToSign() {
- ctx.stringToSign = strings.Join([]string{
- authHeaderPrefix,
- formatTime(ctx.Time),
- ctx.credentialString,
- hex.EncodeToString(hashSHA256([]byte(ctx.canonicalString))),
- }, "\n")
-}
-
-func (ctx *signingCtx) buildSignature() {
- creds := deriveSigningKey(ctx.Region, ctx.ServiceName, ctx.credValues.SecretAccessKey, ctx.Time)
- signature := hmacSHA256(creds, []byte(ctx.stringToSign))
- ctx.signature = hex.EncodeToString(signature)
-}
-
-func (ctx *signingCtx) buildBodyDigest() error {
- hash := ctx.Request.Header.Get("X-Amz-Content-Sha256")
- if hash == "" {
- includeSHA256Header := ctx.unsignedPayload ||
- ctx.ServiceName == "s3" ||
- ctx.ServiceName == "glacier"
-
- s3Presign := ctx.isPresign && ctx.ServiceName == "s3"
-
- if ctx.unsignedPayload || s3Presign {
- hash = "UNSIGNED-PAYLOAD"
- includeSHA256Header = !s3Presign
- } else if ctx.Body == nil {
- hash = emptyStringSHA256
- } else {
- if !aws.IsReaderSeekable(ctx.Body) {
- return fmt.Errorf("cannot use unseekable request body %T, for signed request with body", ctx.Body)
- }
- hashBytes, err := makeSha256Reader(ctx.Body)
- if err != nil {
- return err
- }
- hash = hex.EncodeToString(hashBytes)
- }
-
- if includeSHA256Header {
- ctx.Request.Header.Set("X-Amz-Content-Sha256", hash)
- }
- }
- ctx.bodyDigest = hash
-
- return nil
-}
-
-// isRequestSigned returns if the request is currently signed or presigned
-func (ctx *signingCtx) isRequestSigned() bool {
- if ctx.isPresign && ctx.Query.Get("X-Amz-Signature") != "" {
- return true
- }
- if ctx.Request.Header.Get("Authorization") != "" {
- return true
- }
-
- return false
-}
-
-// unsign removes signing flags for both signed and presigned requests.
-func (ctx *signingCtx) removePresign() {
- ctx.Query.Del("X-Amz-Algorithm")
- ctx.Query.Del("X-Amz-Signature")
- ctx.Query.Del("X-Amz-Security-Token")
- ctx.Query.Del("X-Amz-Date")
- ctx.Query.Del("X-Amz-Expires")
- ctx.Query.Del("X-Amz-Credential")
- ctx.Query.Del("X-Amz-SignedHeaders")
-}
-
-func hmacSHA256(key []byte, data []byte) []byte {
- hash := hmac.New(sha256.New, key)
- hash.Write(data)
- return hash.Sum(nil)
-}
-
-func hashSHA256(data []byte) []byte {
- hash := sha256.New()
- hash.Write(data)
- return hash.Sum(nil)
-}
-
-func makeSha256Reader(reader io.ReadSeeker) (hashBytes []byte, err error) {
- hash := sha256.New()
- start, err := reader.Seek(0, sdkio.SeekCurrent)
- if err != nil {
- return nil, err
- }
- defer func() {
- // ensure error is return if unable to seek back to start of payload.
- _, err = reader.Seek(start, sdkio.SeekStart)
- }()
-
- // Use CopyN to avoid allocating the 32KB buffer in io.Copy for bodies
- // smaller than 32KB. Fall back to io.Copy if we fail to determine the size.
- size, err := aws.SeekerLen(reader)
- if err != nil {
- io.Copy(hash, reader)
- } else {
- io.CopyN(hash, reader, size)
- }
-
- return hash.Sum(nil), nil
-}
-
-const doubleSpace = " "
-
-// stripExcessSpaces will rewrite the passed in slice's string values to not
-// contain multiple side-by-side spaces.
-func stripExcessSpaces(vals []string) {
- var j, k, l, m, spaces int
- for i, str := range vals {
- // Trim trailing spaces
- for j = len(str) - 1; j >= 0 && str[j] == ' '; j-- {
- }
-
- // Trim leading spaces
- for k = 0; k < j && str[k] == ' '; k++ {
- }
- str = str[k : j+1]
-
- // Strip multiple spaces.
- j = strings.Index(str, doubleSpace)
- if j < 0 {
- vals[i] = str
- continue
- }
-
- buf := []byte(str)
- for k, m, l = j, j, len(buf); k < l; k++ {
- if buf[k] == ' ' {
- if spaces == 0 {
- // First space.
- buf[m] = buf[k]
- m++
- }
- spaces++
- } else {
- // End of multiple spaces.
- spaces = 0
- buf[m] = buf[k]
- m++
- }
- }
-
- vals[i] = string(buf[:m])
- }
-}
-
-func buildSigningScope(region, service string, dt time.Time) string {
- return strings.Join([]string{
- formatShortTime(dt),
- region,
- service,
- awsV4Request,
- }, "/")
-}
-
-func deriveSigningKey(region, service, secretKey string, dt time.Time) []byte {
- kDate := hmacSHA256([]byte("AWS4"+secretKey), []byte(formatShortTime(dt)))
- kRegion := hmacSHA256(kDate, []byte(region))
- kService := hmacSHA256(kRegion, []byte(service))
- signingKey := hmacSHA256(kService, []byte(awsV4Request))
- return signingKey
-}
-
-func formatShortTime(dt time.Time) string {
- return dt.UTC().Format(shortTimeFormat)
-}
-
-func formatTime(dt time.Time) string {
- return dt.UTC().Format(timeFormat)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/types.go b/vendor/github.com/aws/aws-sdk-go/aws/types.go
deleted file mode 100644
index 98751ee84f24..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/types.go
+++ /dev/null
@@ -1,264 +0,0 @@
-package aws
-
-import (
- "io"
- "strings"
- "sync"
-
- "github.com/aws/aws-sdk-go/internal/sdkio"
-)
-
-// ReadSeekCloser wraps a io.Reader returning a ReaderSeekerCloser. Allows the
-// SDK to accept an io.Reader that is not also an io.Seeker for unsigned
-// streaming payload API operations.
-//
-// A ReadSeekCloser wrapping an nonseekable io.Reader used in an API
-// operation's input will prevent that operation being retried in the case of
-// network errors, and cause operation requests to fail if the operation
-// requires payload signing.
-//
-// Note: If using With S3 PutObject to stream an object upload The SDK's S3
-// Upload manager (s3manager.Uploader) provides support for streaming with the
-// ability to retry network errors.
-func ReadSeekCloser(r io.Reader) ReaderSeekerCloser {
- return ReaderSeekerCloser{r}
-}
-
-// ReaderSeekerCloser represents a reader that can also delegate io.Seeker and
-// io.Closer interfaces to the underlying object if they are available.
-type ReaderSeekerCloser struct {
- r io.Reader
-}
-
-// IsReaderSeekable returns if the underlying reader type can be seeked. A
-// io.Reader might not actually be seekable if it is the ReaderSeekerCloser
-// type.
-func IsReaderSeekable(r io.Reader) bool {
- switch v := r.(type) {
- case ReaderSeekerCloser:
- return v.IsSeeker()
- case *ReaderSeekerCloser:
- return v.IsSeeker()
- case io.ReadSeeker:
- return true
- default:
- return false
- }
-}
-
-// Read reads from the reader up to size of p. The number of bytes read, and
-// error if it occurred will be returned.
-//
-// If the reader is not an io.Reader zero bytes read, and nil error will be
-// returned.
-//
-// Performs the same functionality as io.Reader Read
-func (r ReaderSeekerCloser) Read(p []byte) (int, error) {
- switch t := r.r.(type) {
- case io.Reader:
- return t.Read(p)
- }
- return 0, nil
-}
-
-// Seek sets the offset for the next Read to offset, interpreted according to
-// whence: 0 means relative to the origin of the file, 1 means relative to the
-// current offset, and 2 means relative to the end. Seek returns the new offset
-// and an error, if any.
-//
-// If the ReaderSeekerCloser is not an io.Seeker nothing will be done.
-func (r ReaderSeekerCloser) Seek(offset int64, whence int) (int64, error) {
- switch t := r.r.(type) {
- case io.Seeker:
- return t.Seek(offset, whence)
- }
- return int64(0), nil
-}
-
-// IsSeeker returns if the underlying reader is also a seeker.
-func (r ReaderSeekerCloser) IsSeeker() bool {
- _, ok := r.r.(io.Seeker)
- return ok
-}
-
-// HasLen returns the length of the underlying reader if the value implements
-// the Len() int method.
-func (r ReaderSeekerCloser) HasLen() (int, bool) {
- type lenner interface {
- Len() int
- }
-
- if lr, ok := r.r.(lenner); ok {
- return lr.Len(), true
- }
-
- return 0, false
-}
-
-// GetLen returns the length of the bytes remaining in the underlying reader.
-// Checks first for Len(), then io.Seeker to determine the size of the
-// underlying reader.
-//
-// Will return -1 if the length cannot be determined.
-func (r ReaderSeekerCloser) GetLen() (int64, error) {
- if l, ok := r.HasLen(); ok {
- return int64(l), nil
- }
-
- if s, ok := r.r.(io.Seeker); ok {
- return seekerLen(s)
- }
-
- return -1, nil
-}
-
-// SeekerLen attempts to get the number of bytes remaining at the seeker's
-// current position. Returns the number of bytes remaining or error.
-func SeekerLen(s io.Seeker) (int64, error) {
- // Determine if the seeker is actually seekable. ReaderSeekerCloser
- // hides the fact that a io.Readers might not actually be seekable.
- switch v := s.(type) {
- case ReaderSeekerCloser:
- return v.GetLen()
- case *ReaderSeekerCloser:
- return v.GetLen()
- }
-
- return seekerLen(s)
-}
-
-func seekerLen(s io.Seeker) (int64, error) {
- curOffset, err := s.Seek(0, sdkio.SeekCurrent)
- if err != nil {
- return 0, err
- }
-
- endOffset, err := s.Seek(0, sdkio.SeekEnd)
- if err != nil {
- return 0, err
- }
-
- _, err = s.Seek(curOffset, sdkio.SeekStart)
- if err != nil {
- return 0, err
- }
-
- return endOffset - curOffset, nil
-}
-
-// Close closes the ReaderSeekerCloser.
-//
-// If the ReaderSeekerCloser is not an io.Closer nothing will be done.
-func (r ReaderSeekerCloser) Close() error {
- switch t := r.r.(type) {
- case io.Closer:
- return t.Close()
- }
- return nil
-}
-
-// A WriteAtBuffer provides a in memory buffer supporting the io.WriterAt interface
-// Can be used with the s3manager.Downloader to download content to a buffer
-// in memory. Safe to use concurrently.
-type WriteAtBuffer struct {
- buf []byte
- m sync.Mutex
-
- // GrowthCoeff defines the growth rate of the internal buffer. By
- // default, the growth rate is 1, where expanding the internal
- // buffer will allocate only enough capacity to fit the new expected
- // length.
- GrowthCoeff float64
-}
-
-// NewWriteAtBuffer creates a WriteAtBuffer with an internal buffer
-// provided by buf.
-func NewWriteAtBuffer(buf []byte) *WriteAtBuffer {
- return &WriteAtBuffer{buf: buf}
-}
-
-// WriteAt writes a slice of bytes to a buffer starting at the position provided
-// The number of bytes written will be returned, or error. Can overwrite previous
-// written slices if the write ats overlap.
-func (b *WriteAtBuffer) WriteAt(p []byte, pos int64) (n int, err error) {
- pLen := len(p)
- expLen := pos + int64(pLen)
- b.m.Lock()
- defer b.m.Unlock()
- if int64(len(b.buf)) < expLen {
- if int64(cap(b.buf)) < expLen {
- if b.GrowthCoeff < 1 {
- b.GrowthCoeff = 1
- }
- newBuf := make([]byte, expLen, int64(b.GrowthCoeff*float64(expLen)))
- copy(newBuf, b.buf)
- b.buf = newBuf
- }
- b.buf = b.buf[:expLen]
- }
- copy(b.buf[pos:], p)
- return pLen, nil
-}
-
-// Bytes returns a slice of bytes written to the buffer.
-func (b *WriteAtBuffer) Bytes() []byte {
- b.m.Lock()
- defer b.m.Unlock()
- return b.buf
-}
-
-// MultiCloser is a utility to close multiple io.Closers within a single
-// statement.
-type MultiCloser []io.Closer
-
-// Close closes all of the io.Closers making up the MultiClosers. Any
-// errors that occur while closing will be returned in the order they
-// occur.
-func (m MultiCloser) Close() error {
- var errs errors
- for _, c := range m {
- err := c.Close()
- if err != nil {
- errs = append(errs, err)
- }
- }
- if len(errs) != 0 {
- return errs
- }
-
- return nil
-}
-
-type errors []error
-
-func (es errors) Error() string {
- var parts []string
- for _, e := range es {
- parts = append(parts, e.Error())
- }
-
- return strings.Join(parts, "\n")
-}
-
-// CopySeekableBody copies the seekable body to an io.Writer
-func CopySeekableBody(dst io.Writer, src io.ReadSeeker) (int64, error) {
- curPos, err := src.Seek(0, sdkio.SeekCurrent)
- if err != nil {
- return 0, err
- }
-
- // copy errors may be assumed to be from the body.
- n, err := io.Copy(dst, src)
- if err != nil {
- return n, err
- }
-
- // seek back to the first position after reading to reset
- // the body for transmission.
- _, err = src.Seek(curPos, sdkio.SeekStart)
- if err != nil {
- return n, err
- }
-
- return n, nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/url.go b/vendor/github.com/aws/aws-sdk-go/aws/url.go
deleted file mode 100644
index 6192b2455b63..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/url.go
+++ /dev/null
@@ -1,12 +0,0 @@
-// +build go1.8
-
-package aws
-
-import "net/url"
-
-// URLHostname will extract the Hostname without port from the URL value.
-//
-// Wrapper of net/url#URL.Hostname for backwards Go version compatibility.
-func URLHostname(url *url.URL) string {
- return url.Hostname()
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/url_1_7.go b/vendor/github.com/aws/aws-sdk-go/aws/url_1_7.go
deleted file mode 100644
index 0210d2720e77..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/url_1_7.go
+++ /dev/null
@@ -1,29 +0,0 @@
-// +build !go1.8
-
-package aws
-
-import (
- "net/url"
- "strings"
-)
-
-// URLHostname will extract the Hostname without port from the URL value.
-//
-// Copy of Go 1.8's net/url#URL.Hostname functionality.
-func URLHostname(url *url.URL) string {
- return stripPort(url.Host)
-
-}
-
-// stripPort is copy of Go 1.8 url#URL.Hostname functionality.
-// https://golang.org/src/net/url/url.go
-func stripPort(hostport string) string {
- colon := strings.IndexByte(hostport, ':')
- if colon == -1 {
- return hostport
- }
- if i := strings.IndexByte(hostport, ']'); i != -1 {
- return strings.TrimPrefix(hostport[:i], "[")
- }
- return hostport[:colon]
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/context/background_go1.5.go b/vendor/github.com/aws/aws-sdk-go/internal/context/background_go1.5.go
deleted file mode 100644
index 876dcb3fde28..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/context/background_go1.5.go
+++ /dev/null
@@ -1,40 +0,0 @@
-// +build !go1.7
-
-package context
-
-import "time"
-
-// An emptyCtx is a copy of the Go 1.7 context.emptyCtx type. This is copied to
-// provide a 1.6 and 1.5 safe version of context that is compatible with Go
-// 1.7's Context.
-//
-// An emptyCtx is never canceled, has no values, and has no deadline. It is not
-// struct{}, since vars of this type must have distinct addresses.
-type emptyCtx int
-
-func (*emptyCtx) Deadline() (deadline time.Time, ok bool) {
- return
-}
-
-func (*emptyCtx) Done() <-chan struct{} {
- return nil
-}
-
-func (*emptyCtx) Err() error {
- return nil
-}
-
-func (*emptyCtx) Value(key interface{}) interface{} {
- return nil
-}
-
-func (e *emptyCtx) String() string {
- switch e {
- case BackgroundCtx:
- return "aws.BackgroundContext"
- }
- return "unknown empty Context"
-}
-
-// BackgroundCtx is the common base context.
-var BackgroundCtx = new(emptyCtx)
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go
deleted file mode 100644
index 25ce0fe134de..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go
+++ /dev/null
@@ -1,29 +0,0 @@
-// Package ini is an LL(1) parser for configuration files.
-//
-// Example:
-// sections, err := ini.OpenFile("/path/to/file")
-// if err != nil {
-// panic(err)
-// }
-//
-// profile := "foo"
-// section, ok := sections.GetSection(profile)
-// if !ok {
-// fmt.Printf("section %q could not be found", profile)
-// }
-//
-// Below is the BNF that describes this parser
-// Grammar:
-// stmt -> value stmt'
-// stmt' -> epsilon | op stmt
-// value -> number | string | boolean | quoted_string
-//
-// section -> [ section'
-// section' -> value section_close
-// section_close -> ]
-//
-// SkipState will skip (NL WS)+
-//
-// comment -> # comment' | ; comment'
-// comment' -> epsilon | value
-package ini
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_error.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_error.go
deleted file mode 100644
index 45728701931c..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_error.go
+++ /dev/null
@@ -1,43 +0,0 @@
-package ini
-
-import "fmt"
-
-const (
- // ErrCodeParseError is returned when a parsing error
- // has occurred.
- ErrCodeParseError = "INIParseError"
-)
-
-// ParseError is an error which is returned during any part of
-// the parsing process.
-type ParseError struct {
- msg string
-}
-
-// NewParseError will return a new ParseError where message
-// is the description of the error.
-func NewParseError(message string) *ParseError {
- return &ParseError{
- msg: message,
- }
-}
-
-// Code will return the ErrCodeParseError
-func (err *ParseError) Code() string {
- return ErrCodeParseError
-}
-
-// Message returns the error's message
-func (err *ParseError) Message() string {
- return err.msg
-}
-
-// OrigError return nothing since there will never be any
-// original error.
-func (err *ParseError) OrigError() error {
- return nil
-}
-
-func (err *ParseError) Error() string {
- return fmt.Sprintf("%s: %s", err.Code(), err.Message())
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go
deleted file mode 100644
index 5aa9137e0f93..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go
+++ /dev/null
@@ -1,10 +0,0 @@
-// +build !go1.7
-
-package sdkio
-
-// Copy of Go 1.7 io package's Seeker constants.
-const (
- SeekStart = 0 // seek relative to the origin of the file
- SeekCurrent = 1 // seek relative to the current offset
- SeekEnd = 2 // seek relative to the end
-)
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go
deleted file mode 100644
index e5f005613b79..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go
+++ /dev/null
@@ -1,12 +0,0 @@
-// +build go1.7
-
-package sdkio
-
-import "io"
-
-// Alias for Go 1.7 io package Seeker constants
-const (
- SeekStart = io.SeekStart // seek relative to the origin of the file
- SeekCurrent = io.SeekCurrent // seek relative to the current offset
- SeekEnd = io.SeekEnd // seek relative to the end
-)
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor.go
deleted file mode 100644
index 44898eed0fdd..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor.go
+++ /dev/null
@@ -1,15 +0,0 @@
-// +build go1.10
-
-package sdkmath
-
-import "math"
-
-// Round returns the nearest integer, rounding half away from zero.
-//
-// Special cases are:
-// Round(±0) = ±0
-// Round(±Inf) = ±Inf
-// Round(NaN) = NaN
-func Round(x float64) float64 {
- return math.Round(x)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor_go1.9.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor_go1.9.go
deleted file mode 100644
index 810ec7f08b00..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/sdkmath/floor_go1.9.go
+++ /dev/null
@@ -1,56 +0,0 @@
-// +build !go1.10
-
-package sdkmath
-
-import "math"
-
-// Copied from the Go standard library's (Go 1.12) math/floor.go for use in
-// Go version prior to Go 1.10.
-const (
- uvone = 0x3FF0000000000000
- mask = 0x7FF
- shift = 64 - 11 - 1
- bias = 1023
- signMask = 1 << 63
- fracMask = 1<= 0.5 {
- // return t + Copysign(1, x)
- // }
- // return t
- // }
- bits := math.Float64bits(x)
- e := uint(bits>>shift) & mask
- if e < bias {
- // Round abs(x) < 1 including denormals.
- bits &= signMask // +-0
- if e == bias-1 {
- bits |= uvone // +-1
- }
- } else if e < bias+shift {
- // Round any abs(x) >= 1 containing a fractional component [0,1).
- //
- // Numbers with larger exponents are returned unchanged since they
- // must be either an integer, infinity, or NaN.
- const half = 1 << (shift - 1)
- e -= bias
- bits += half >> e
- bits &^= fracMask >> e
- }
- return math.Float64frombits(bits)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go
deleted file mode 100644
index 0c9802d87706..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go
+++ /dev/null
@@ -1,29 +0,0 @@
-package sdkrand
-
-import (
- "math/rand"
- "sync"
- "time"
-)
-
-// lockedSource is a thread-safe implementation of rand.Source
-type lockedSource struct {
- lk sync.Mutex
- src rand.Source
-}
-
-func (r *lockedSource) Int63() (n int64) {
- r.lk.Lock()
- n = r.src.Int63()
- r.lk.Unlock()
- return
-}
-
-func (r *lockedSource) Seed(seed int64) {
- r.lk.Lock()
- r.src.Seed(seed)
- r.lk.Unlock()
-}
-
-// SeededRand is a new RNG using a thread safe implementation of rand.Source
-var SeededRand = rand.New(&lockedSource{src: rand.NewSource(time.Now().UnixNano())})
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read.go
deleted file mode 100644
index f4651da2da58..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read.go
+++ /dev/null
@@ -1,11 +0,0 @@
-// +build go1.6
-
-package sdkrand
-
-import "math/rand"
-
-// Read provides the stub for math.Rand.Read method support for go version's
-// 1.6 and greater.
-func Read(r *rand.Rand, p []byte) (int, error) {
- return r.Read(p)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read_1_5.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read_1_5.go
deleted file mode 100644
index b1d93a33d48a..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/read_1_5.go
+++ /dev/null
@@ -1,24 +0,0 @@
-// +build !go1.6
-
-package sdkrand
-
-import "math/rand"
-
-// Read backfills Go 1.6's math.Rand.Reader for Go 1.5
-func Read(r *rand.Rand, p []byte) (n int, err error) {
- // Copy of Go standard libraries math package's read function not added to
- // standard library until Go 1.6.
- var pos int8
- var val int64
- for n = 0; n < len(p); n++ {
- if pos == 0 {
- val = r.Int63()
- pos = 7
- }
- p[n] = byte(val)
- val >>= 8
- pos--
- }
-
- return n, err
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkuri/path.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkuri/path.go
deleted file mode 100644
index 38ea61afeaa6..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/sdkuri/path.go
+++ /dev/null
@@ -1,23 +0,0 @@
-package sdkuri
-
-import (
- "path"
- "strings"
-)
-
-// PathJoin will join the elements of the path delimited by the "/"
-// character. Similar to path.Join with the exception the trailing "/"
-// character is preserved if present.
-func PathJoin(elems ...string) string {
- if len(elems) == 0 {
- return ""
- }
-
- hasTrailing := strings.HasSuffix(elems[len(elems)-1], "/")
- str := path.Join(elems...)
- if hasTrailing && str != "/" {
- str += "/"
- }
-
- return str
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go b/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go
deleted file mode 100644
index 7da8a49ce522..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go
+++ /dev/null
@@ -1,12 +0,0 @@
-package shareddefaults
-
-const (
- // ECSCredsProviderEnvVar is an environmental variable key used to
- // determine which path needs to be hit.
- ECSCredsProviderEnvVar = "AWS_CONTAINER_CREDENTIALS_RELATIVE_URI"
-)
-
-// ECSContainerCredentialsURI is the endpoint to retrieve container
-// credentials. This can be overridden to test to ensure the credential process
-// is behaving correctly.
-var ECSContainerCredentialsURI = "http://169.254.170.2"
diff --git a/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/shared_config.go b/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/shared_config.go
deleted file mode 100644
index ebcbc2b40a3f..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/shared_config.go
+++ /dev/null
@@ -1,40 +0,0 @@
-package shareddefaults
-
-import (
- "os"
- "path/filepath"
- "runtime"
-)
-
-// SharedCredentialsFilename returns the SDK's default file path
-// for the shared credentials file.
-//
-// Builds the shared config file path based on the OS's platform.
-//
-// - Linux/Unix: $HOME/.aws/credentials
-// - Windows: %USERPROFILE%\.aws\credentials
-func SharedCredentialsFilename() string {
- return filepath.Join(UserHomeDir(), ".aws", "credentials")
-}
-
-// SharedConfigFilename returns the SDK's default file path for
-// the shared config file.
-//
-// Builds the shared config file path based on the OS's platform.
-//
-// - Linux/Unix: $HOME/.aws/config
-// - Windows: %USERPROFILE%\.aws\config
-func SharedConfigFilename() string {
- return filepath.Join(UserHomeDir(), ".aws", "config")
-}
-
-// UserHomeDir returns the home directory for the user the process is
-// running under.
-func UserHomeDir() string {
- if runtime.GOOS == "windows" { // Windows
- return os.Getenv("USERPROFILE")
- }
-
- // *nix
- return os.Getenv("HOME")
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go
deleted file mode 100644
index d7d42db0a6a5..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go
+++ /dev/null
@@ -1,68 +0,0 @@
-package protocol
-
-import (
- "strings"
-
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// ValidateEndpointHostHandler is a request handler that will validate the
-// request endpoint's hosts is a valid RFC 3986 host.
-var ValidateEndpointHostHandler = request.NamedHandler{
- Name: "awssdk.protocol.ValidateEndpointHostHandler",
- Fn: func(r *request.Request) {
- err := ValidateEndpointHost(r.Operation.Name, r.HTTPRequest.URL.Host)
- if err != nil {
- r.Error = err
- }
- },
-}
-
-// ValidateEndpointHost validates that the host string passed in is a valid RFC
-// 3986 host. Returns error if the host is not valid.
-func ValidateEndpointHost(opName, host string) error {
- paramErrs := request.ErrInvalidParams{Context: opName}
- labels := strings.Split(host, ".")
-
- for i, label := range labels {
- if i == len(labels)-1 && len(label) == 0 {
- // Allow trailing dot for FQDN hosts.
- continue
- }
-
- if !ValidHostLabel(label) {
- paramErrs.Add(request.NewErrParamFormat(
- "endpoint host label", "[a-zA-Z0-9-]{1,63}", label))
- }
- }
-
- if len(host) > 255 {
- paramErrs.Add(request.NewErrParamMaxLen(
- "endpoint host", 255, host,
- ))
- }
-
- if paramErrs.Len() > 0 {
- return paramErrs
- }
- return nil
-}
-
-// ValidHostLabel returns if the label is a valid RFC 3986 host label.
-func ValidHostLabel(label string) bool {
- if l := len(label); l == 0 || l > 63 {
- return false
- }
- for _, r := range label {
- switch {
- case r >= '0' && r <= '9':
- case r >= 'A' && r <= 'Z':
- case r >= 'a' && r <= 'z':
- case r == '-':
- default:
- return false
- }
- }
-
- return true
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go
deleted file mode 100644
index 915b0fcafd73..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go
+++ /dev/null
@@ -1,54 +0,0 @@
-package protocol
-
-import (
- "strings"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// HostPrefixHandlerName is the handler name for the host prefix request
-// handler.
-const HostPrefixHandlerName = "awssdk.endpoint.HostPrefixHandler"
-
-// NewHostPrefixHandler constructs a build handler
-func NewHostPrefixHandler(prefix string, labelsFn func() map[string]string) request.NamedHandler {
- builder := HostPrefixBuilder{
- Prefix: prefix,
- LabelsFn: labelsFn,
- }
-
- return request.NamedHandler{
- Name: HostPrefixHandlerName,
- Fn: builder.Build,
- }
-}
-
-// HostPrefixBuilder provides the request handler to expand and prepend
-// the host prefix into the operation's request endpoint host.
-type HostPrefixBuilder struct {
- Prefix string
- LabelsFn func() map[string]string
-}
-
-// Build updates the passed in Request with the HostPrefix template expanded.
-func (h HostPrefixBuilder) Build(r *request.Request) {
- if aws.BoolValue(r.Config.DisableEndpointHostPrefix) {
- return
- }
-
- var labels map[string]string
- if h.LabelsFn != nil {
- labels = h.LabelsFn()
- }
-
- prefix := h.Prefix
- for name, value := range labels {
- prefix = strings.Replace(prefix, "{"+name+"}", value, -1)
- }
-
- r.HTTPRequest.URL.Host = prefix + r.HTTPRequest.URL.Host
- if len(r.HTTPRequest.Host) > 0 {
- r.HTTPRequest.Host = prefix + r.HTTPRequest.Host
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/idempotency.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/idempotency.go
deleted file mode 100644
index 53831dff9842..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/idempotency.go
+++ /dev/null
@@ -1,75 +0,0 @@
-package protocol
-
-import (
- "crypto/rand"
- "fmt"
- "reflect"
-)
-
-// RandReader is the random reader the protocol package will use to read
-// random bytes from. This is exported for testing, and should not be used.
-var RandReader = rand.Reader
-
-const idempotencyTokenFillTag = `idempotencyToken`
-
-// CanSetIdempotencyToken returns true if the struct field should be
-// automatically populated with a Idempotency token.
-//
-// Only *string and string type fields that are tagged with idempotencyToken
-// which are not already set can be auto filled.
-func CanSetIdempotencyToken(v reflect.Value, f reflect.StructField) bool {
- switch u := v.Interface().(type) {
- // To auto fill an Idempotency token the field must be a string,
- // tagged for auto fill, and have a zero value.
- case *string:
- return u == nil && len(f.Tag.Get(idempotencyTokenFillTag)) != 0
- case string:
- return len(u) == 0 && len(f.Tag.Get(idempotencyTokenFillTag)) != 0
- }
-
- return false
-}
-
-// GetIdempotencyToken returns a randomly generated idempotency token.
-func GetIdempotencyToken() string {
- b := make([]byte, 16)
- RandReader.Read(b)
-
- return UUIDVersion4(b)
-}
-
-// SetIdempotencyToken will set the value provided with a Idempotency Token.
-// Given that the value can be set. Will panic if value is not setable.
-func SetIdempotencyToken(v reflect.Value) {
- if v.Kind() == reflect.Ptr {
- if v.IsNil() && v.CanSet() {
- v.Set(reflect.New(v.Type().Elem()))
- }
- v = v.Elem()
- }
- v = reflect.Indirect(v)
-
- if !v.CanSet() {
- panic(fmt.Sprintf("unable to set idempotnecy token %v", v))
- }
-
- b := make([]byte, 16)
- _, err := rand.Read(b)
- if err != nil {
- // TODO handle error
- return
- }
-
- v.Set(reflect.ValueOf(UUIDVersion4(b)))
-}
-
-// UUIDVersion4 returns a Version 4 random UUID from the byte slice provided
-func UUIDVersion4(u []byte) string {
- // https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_4_.28random.29
- // 13th character is "4"
- u[6] = (u[6] | 0x40) & 0x4F
- // 17th character is "8", "9", "a", or "b"
- u[8] = (u[8] | 0x80) & 0xBF
-
- return fmt.Sprintf(`%X-%X-%X-%X-%X`, u[0:4], u[4:6], u[6:8], u[8:10], u[10:])
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/build.go
deleted file mode 100644
index 864fb6704b47..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/build.go
+++ /dev/null
@@ -1,296 +0,0 @@
-// Package jsonutil provides JSON serialization of AWS requests and responses.
-package jsonutil
-
-import (
- "bytes"
- "encoding/base64"
- "encoding/json"
- "fmt"
- "math"
- "reflect"
- "sort"
- "strconv"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/private/protocol"
-)
-
-var timeType = reflect.ValueOf(time.Time{}).Type()
-var byteSliceType = reflect.ValueOf([]byte{}).Type()
-
-// BuildJSON builds a JSON string for a given object v.
-func BuildJSON(v interface{}) ([]byte, error) {
- var buf bytes.Buffer
-
- err := buildAny(reflect.ValueOf(v), &buf, "")
- return buf.Bytes(), err
-}
-
-func buildAny(value reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error {
- origVal := value
- value = reflect.Indirect(value)
- if !value.IsValid() {
- return nil
- }
-
- vtype := value.Type()
-
- t := tag.Get("type")
- if t == "" {
- switch vtype.Kind() {
- case reflect.Struct:
- // also it can't be a time object
- if value.Type() != timeType {
- t = "structure"
- }
- case reflect.Slice:
- // also it can't be a byte slice
- if _, ok := value.Interface().([]byte); !ok {
- t = "list"
- }
- case reflect.Map:
- // cannot be a JSONValue map
- if _, ok := value.Interface().(aws.JSONValue); !ok {
- t = "map"
- }
- }
- }
-
- switch t {
- case "structure":
- if field, ok := vtype.FieldByName("_"); ok {
- tag = field.Tag
- }
- return buildStruct(value, buf, tag)
- case "list":
- return buildList(value, buf, tag)
- case "map":
- return buildMap(value, buf, tag)
- default:
- return buildScalar(origVal, buf, tag)
- }
-}
-
-func buildStruct(value reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error {
- if !value.IsValid() {
- return nil
- }
-
- // unwrap payloads
- if payload := tag.Get("payload"); payload != "" {
- field, _ := value.Type().FieldByName(payload)
- tag = field.Tag
- value = elemOf(value.FieldByName(payload))
-
- if !value.IsValid() {
- return nil
- }
- }
-
- buf.WriteByte('{')
-
- t := value.Type()
- first := true
- for i := 0; i < t.NumField(); i++ {
- member := value.Field(i)
-
- // This allocates the most memory.
- // Additionally, we cannot skip nil fields due to
- // idempotency auto filling.
- field := t.Field(i)
-
- if field.PkgPath != "" {
- continue // ignore unexported fields
- }
- if field.Tag.Get("json") == "-" {
- continue
- }
- if field.Tag.Get("location") != "" {
- continue // ignore non-body elements
- }
- if field.Tag.Get("ignore") != "" {
- continue
- }
-
- if protocol.CanSetIdempotencyToken(member, field) {
- token := protocol.GetIdempotencyToken()
- member = reflect.ValueOf(&token)
- }
-
- if (member.Kind() == reflect.Ptr || member.Kind() == reflect.Slice || member.Kind() == reflect.Map) && member.IsNil() {
- continue // ignore unset fields
- }
-
- if first {
- first = false
- } else {
- buf.WriteByte(',')
- }
-
- // figure out what this field is called
- name := field.Name
- if locName := field.Tag.Get("locationName"); locName != "" {
- name = locName
- }
-
- writeString(name, buf)
- buf.WriteString(`:`)
-
- err := buildAny(member, buf, field.Tag)
- if err != nil {
- return err
- }
-
- }
-
- buf.WriteString("}")
-
- return nil
-}
-
-func buildList(value reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error {
- buf.WriteString("[")
-
- for i := 0; i < value.Len(); i++ {
- buildAny(value.Index(i), buf, "")
-
- if i < value.Len()-1 {
- buf.WriteString(",")
- }
- }
-
- buf.WriteString("]")
-
- return nil
-}
-
-type sortedValues []reflect.Value
-
-func (sv sortedValues) Len() int { return len(sv) }
-func (sv sortedValues) Swap(i, j int) { sv[i], sv[j] = sv[j], sv[i] }
-func (sv sortedValues) Less(i, j int) bool { return sv[i].String() < sv[j].String() }
-
-func buildMap(value reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error {
- buf.WriteString("{")
-
- sv := sortedValues(value.MapKeys())
- sort.Sort(sv)
-
- for i, k := range sv {
- if i > 0 {
- buf.WriteByte(',')
- }
-
- writeString(k.String(), buf)
- buf.WriteString(`:`)
-
- buildAny(value.MapIndex(k), buf, "")
- }
-
- buf.WriteString("}")
-
- return nil
-}
-
-func buildScalar(v reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error {
- // prevents allocation on the heap.
- scratch := [64]byte{}
- switch value := reflect.Indirect(v); value.Kind() {
- case reflect.String:
- writeString(value.String(), buf)
- case reflect.Bool:
- if value.Bool() {
- buf.WriteString("true")
- } else {
- buf.WriteString("false")
- }
- case reflect.Int64:
- buf.Write(strconv.AppendInt(scratch[:0], value.Int(), 10))
- case reflect.Float64:
- f := value.Float()
- if math.IsInf(f, 0) || math.IsNaN(f) {
- return &json.UnsupportedValueError{Value: v, Str: strconv.FormatFloat(f, 'f', -1, 64)}
- }
- buf.Write(strconv.AppendFloat(scratch[:0], f, 'f', -1, 64))
- default:
- switch converted := value.Interface().(type) {
- case time.Time:
- format := tag.Get("timestampFormat")
- if len(format) == 0 {
- format = protocol.UnixTimeFormatName
- }
-
- ts := protocol.FormatTime(format, converted)
- if format != protocol.UnixTimeFormatName {
- ts = `"` + ts + `"`
- }
-
- buf.WriteString(ts)
- case []byte:
- if !value.IsNil() {
- buf.WriteByte('"')
- if len(converted) < 1024 {
- // for small buffers, using Encode directly is much faster.
- dst := make([]byte, base64.StdEncoding.EncodedLen(len(converted)))
- base64.StdEncoding.Encode(dst, converted)
- buf.Write(dst)
- } else {
- // for large buffers, avoid unnecessary extra temporary
- // buffer space.
- enc := base64.NewEncoder(base64.StdEncoding, buf)
- enc.Write(converted)
- enc.Close()
- }
- buf.WriteByte('"')
- }
- case aws.JSONValue:
- str, err := protocol.EncodeJSONValue(converted, protocol.QuotedEscape)
- if err != nil {
- return fmt.Errorf("unable to encode JSONValue, %v", err)
- }
- buf.WriteString(str)
- default:
- return fmt.Errorf("unsupported JSON value %v (%s)", value.Interface(), value.Type())
- }
- }
- return nil
-}
-
-var hex = "0123456789abcdef"
-
-func writeString(s string, buf *bytes.Buffer) {
- buf.WriteByte('"')
- for i := 0; i < len(s); i++ {
- if s[i] == '"' {
- buf.WriteString(`\"`)
- } else if s[i] == '\\' {
- buf.WriteString(`\\`)
- } else if s[i] == '\b' {
- buf.WriteString(`\b`)
- } else if s[i] == '\f' {
- buf.WriteString(`\f`)
- } else if s[i] == '\r' {
- buf.WriteString(`\r`)
- } else if s[i] == '\t' {
- buf.WriteString(`\t`)
- } else if s[i] == '\n' {
- buf.WriteString(`\n`)
- } else if s[i] < 32 {
- buf.WriteString("\\u00")
- buf.WriteByte(hex[s[i]>>4])
- buf.WriteByte(hex[s[i]&0xF])
- } else {
- buf.WriteByte(s[i])
- }
- }
- buf.WriteByte('"')
-}
-
-// Returns the reflection element of a value, if it is a pointer.
-func elemOf(value reflect.Value) reflect.Value {
- for value.Kind() == reflect.Ptr {
- value = value.Elem()
- }
- return value
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go
deleted file mode 100644
index 8b2c9bbeba0c..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go
+++ /dev/null
@@ -1,304 +0,0 @@
-package jsonutil
-
-import (
- "bytes"
- "encoding/base64"
- "encoding/json"
- "fmt"
- "io"
- "math/big"
- "reflect"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/private/protocol"
-)
-
-var millisecondsFloat = new(big.Float).SetInt64(1e3)
-
-// UnmarshalJSONError unmarshal's the reader's JSON document into the passed in
-// type. The value to unmarshal the json document into must be a pointer to the
-// type.
-func UnmarshalJSONError(v interface{}, stream io.Reader) error {
- var errBuf bytes.Buffer
- body := io.TeeReader(stream, &errBuf)
-
- err := json.NewDecoder(body).Decode(v)
- if err != nil {
- msg := "failed decoding error message"
- if err == io.EOF {
- msg = "error message missing"
- err = nil
- }
- return awserr.NewUnmarshalError(err, msg, errBuf.Bytes())
- }
-
- return nil
-}
-
-// UnmarshalJSON reads a stream and unmarshals the results in object v.
-func UnmarshalJSON(v interface{}, stream io.Reader) error {
- var out interface{}
-
- decoder := json.NewDecoder(stream)
- decoder.UseNumber()
- err := decoder.Decode(&out)
- if err == io.EOF {
- return nil
- } else if err != nil {
- return err
- }
-
- return unmarshaler{}.unmarshalAny(reflect.ValueOf(v), out, "")
-}
-
-// UnmarshalJSONCaseInsensitive reads a stream and unmarshals the result into the
-// object v. Ignores casing for structure members.
-func UnmarshalJSONCaseInsensitive(v interface{}, stream io.Reader) error {
- var out interface{}
-
- decoder := json.NewDecoder(stream)
- decoder.UseNumber()
- err := decoder.Decode(&out)
- if err == io.EOF {
- return nil
- } else if err != nil {
- return err
- }
-
- return unmarshaler{
- caseInsensitive: true,
- }.unmarshalAny(reflect.ValueOf(v), out, "")
-}
-
-type unmarshaler struct {
- caseInsensitive bool
-}
-
-func (u unmarshaler) unmarshalAny(value reflect.Value, data interface{}, tag reflect.StructTag) error {
- vtype := value.Type()
- if vtype.Kind() == reflect.Ptr {
- vtype = vtype.Elem() // check kind of actual element type
- }
-
- t := tag.Get("type")
- if t == "" {
- switch vtype.Kind() {
- case reflect.Struct:
- // also it can't be a time object
- if _, ok := value.Interface().(*time.Time); !ok {
- t = "structure"
- }
- case reflect.Slice:
- // also it can't be a byte slice
- if _, ok := value.Interface().([]byte); !ok {
- t = "list"
- }
- case reflect.Map:
- // cannot be a JSONValue map
- if _, ok := value.Interface().(aws.JSONValue); !ok {
- t = "map"
- }
- }
- }
-
- switch t {
- case "structure":
- if field, ok := vtype.FieldByName("_"); ok {
- tag = field.Tag
- }
- return u.unmarshalStruct(value, data, tag)
- case "list":
- return u.unmarshalList(value, data, tag)
- case "map":
- return u.unmarshalMap(value, data, tag)
- default:
- return u.unmarshalScalar(value, data, tag)
- }
-}
-
-func (u unmarshaler) unmarshalStruct(value reflect.Value, data interface{}, tag reflect.StructTag) error {
- if data == nil {
- return nil
- }
- mapData, ok := data.(map[string]interface{})
- if !ok {
- return fmt.Errorf("JSON value is not a structure (%#v)", data)
- }
-
- t := value.Type()
- if value.Kind() == reflect.Ptr {
- if value.IsNil() { // create the structure if it's nil
- s := reflect.New(value.Type().Elem())
- value.Set(s)
- value = s
- }
-
- value = value.Elem()
- t = t.Elem()
- }
-
- // unwrap any payloads
- if payload := tag.Get("payload"); payload != "" {
- field, _ := t.FieldByName(payload)
- return u.unmarshalAny(value.FieldByName(payload), data, field.Tag)
- }
-
- for i := 0; i < t.NumField(); i++ {
- field := t.Field(i)
- if field.PkgPath != "" {
- continue // ignore unexported fields
- }
-
- // figure out what this field is called
- name := field.Name
- if locName := field.Tag.Get("locationName"); locName != "" {
- name = locName
- }
- if u.caseInsensitive {
- if _, ok := mapData[name]; !ok {
- // Fallback to uncased name search if the exact name didn't match.
- for kn, v := range mapData {
- if strings.EqualFold(kn, name) {
- mapData[name] = v
- }
- }
- }
- }
-
- member := value.FieldByIndex(field.Index)
- err := u.unmarshalAny(member, mapData[name], field.Tag)
- if err != nil {
- return err
- }
- }
- return nil
-}
-
-func (u unmarshaler) unmarshalList(value reflect.Value, data interface{}, tag reflect.StructTag) error {
- if data == nil {
- return nil
- }
- listData, ok := data.([]interface{})
- if !ok {
- return fmt.Errorf("JSON value is not a list (%#v)", data)
- }
-
- if value.IsNil() {
- l := len(listData)
- value.Set(reflect.MakeSlice(value.Type(), l, l))
- }
-
- for i, c := range listData {
- err := u.unmarshalAny(value.Index(i), c, "")
- if err != nil {
- return err
- }
- }
-
- return nil
-}
-
-func (u unmarshaler) unmarshalMap(value reflect.Value, data interface{}, tag reflect.StructTag) error {
- if data == nil {
- return nil
- }
- mapData, ok := data.(map[string]interface{})
- if !ok {
- return fmt.Errorf("JSON value is not a map (%#v)", data)
- }
-
- if value.IsNil() {
- value.Set(reflect.MakeMap(value.Type()))
- }
-
- for k, v := range mapData {
- kvalue := reflect.ValueOf(k)
- vvalue := reflect.New(value.Type().Elem()).Elem()
-
- u.unmarshalAny(vvalue, v, "")
- value.SetMapIndex(kvalue, vvalue)
- }
-
- return nil
-}
-
-func (u unmarshaler) unmarshalScalar(value reflect.Value, data interface{}, tag reflect.StructTag) error {
-
- switch d := data.(type) {
- case nil:
- return nil // nothing to do here
- case string:
- switch value.Interface().(type) {
- case *string:
- value.Set(reflect.ValueOf(&d))
- case []byte:
- b, err := base64.StdEncoding.DecodeString(d)
- if err != nil {
- return err
- }
- value.Set(reflect.ValueOf(b))
- case *time.Time:
- format := tag.Get("timestampFormat")
- if len(format) == 0 {
- format = protocol.ISO8601TimeFormatName
- }
-
- t, err := protocol.ParseTime(format, d)
- if err != nil {
- return err
- }
- value.Set(reflect.ValueOf(&t))
- case aws.JSONValue:
- // No need to use escaping as the value is a non-quoted string.
- v, err := protocol.DecodeJSONValue(d, protocol.NoEscape)
- if err != nil {
- return err
- }
- value.Set(reflect.ValueOf(v))
- default:
- return fmt.Errorf("unsupported value: %v (%s)", value.Interface(), value.Type())
- }
- case json.Number:
- switch value.Interface().(type) {
- case *int64:
- // Retain the old behavior where we would just truncate the float64
- // calling d.Int64() here could cause an invalid syntax error due to the usage of strconv.ParseInt
- f, err := d.Float64()
- if err != nil {
- return err
- }
- di := int64(f)
- value.Set(reflect.ValueOf(&di))
- case *float64:
- f, err := d.Float64()
- if err != nil {
- return err
- }
- value.Set(reflect.ValueOf(&f))
- case *time.Time:
- float, ok := new(big.Float).SetString(d.String())
- if !ok {
- return fmt.Errorf("unsupported float time representation: %v", d.String())
- }
- float = float.Mul(float, millisecondsFloat)
- ms, _ := float.Int64()
- t := time.Unix(0, ms*1e6).UTC()
- value.Set(reflect.ValueOf(&t))
- default:
- return fmt.Errorf("unsupported value: %v (%s)", value.Interface(), value.Type())
- }
- case bool:
- switch value.Interface().(type) {
- case *bool:
- value.Set(reflect.ValueOf(&d))
- default:
- return fmt.Errorf("unsupported value: %v (%s)", value.Interface(), value.Type())
- }
- default:
- return fmt.Errorf("unsupported JSON value (%v)", data)
- }
- return nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/jsonrpc.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/jsonrpc.go
deleted file mode 100644
index a029217e4c61..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/jsonrpc.go
+++ /dev/null
@@ -1,88 +0,0 @@
-// Package jsonrpc provides JSON RPC utilities for serialization of AWS
-// requests and responses.
-package jsonrpc
-
-//go:generate go run -tags codegen ../../../private/model/cli/gen-protocol-tests ../../../models/protocol_tests/input/json.json build_test.go
-//go:generate go run -tags codegen ../../../private/model/cli/gen-protocol-tests ../../../models/protocol_tests/output/json.json unmarshal_test.go
-
-import (
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol/json/jsonutil"
- "github.com/aws/aws-sdk-go/private/protocol/rest"
-)
-
-var emptyJSON = []byte("{}")
-
-// BuildHandler is a named request handler for building jsonrpc protocol
-// requests
-var BuildHandler = request.NamedHandler{
- Name: "awssdk.jsonrpc.Build",
- Fn: Build,
-}
-
-// UnmarshalHandler is a named request handler for unmarshaling jsonrpc
-// protocol requests
-var UnmarshalHandler = request.NamedHandler{
- Name: "awssdk.jsonrpc.Unmarshal",
- Fn: Unmarshal,
-}
-
-// UnmarshalMetaHandler is a named request handler for unmarshaling jsonrpc
-// protocol request metadata
-var UnmarshalMetaHandler = request.NamedHandler{
- Name: "awssdk.jsonrpc.UnmarshalMeta",
- Fn: UnmarshalMeta,
-}
-
-// Build builds a JSON payload for a JSON RPC request.
-func Build(req *request.Request) {
- var buf []byte
- var err error
- if req.ParamsFilled() {
- buf, err = jsonutil.BuildJSON(req.Params)
- if err != nil {
- req.Error = awserr.New(request.ErrCodeSerialization, "failed encoding JSON RPC request", err)
- return
- }
- } else {
- buf = emptyJSON
- }
-
- if req.ClientInfo.TargetPrefix != "" || string(buf) != "{}" {
- req.SetBufferBody(buf)
- }
-
- if req.ClientInfo.TargetPrefix != "" {
- target := req.ClientInfo.TargetPrefix + "." + req.Operation.Name
- req.HTTPRequest.Header.Add("X-Amz-Target", target)
- }
-
- // Only set the content type if one is not already specified and an
- // JSONVersion is specified.
- if ct, v := req.HTTPRequest.Header.Get("Content-Type"), req.ClientInfo.JSONVersion; len(ct) == 0 && len(v) != 0 {
- jsonVersion := req.ClientInfo.JSONVersion
- req.HTTPRequest.Header.Set("Content-Type", "application/x-amz-json-"+jsonVersion)
- }
-}
-
-// Unmarshal unmarshals a response for a JSON RPC service.
-func Unmarshal(req *request.Request) {
- defer req.HTTPResponse.Body.Close()
- if req.DataFilled() {
- err := jsonutil.UnmarshalJSON(req.Data, req.HTTPResponse.Body)
- if err != nil {
- req.Error = awserr.NewRequestFailure(
- awserr.New(request.ErrCodeSerialization, "failed decoding JSON RPC response", err),
- req.HTTPResponse.StatusCode,
- req.RequestID,
- )
- }
- }
- return
-}
-
-// UnmarshalMeta unmarshals headers from a response for a JSON RPC service.
-func UnmarshalMeta(req *request.Request) {
- rest.UnmarshalMeta(req)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/unmarshal_error.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/unmarshal_error.go
deleted file mode 100644
index c0c52e2db0f3..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/unmarshal_error.go
+++ /dev/null
@@ -1,107 +0,0 @@
-package jsonrpc
-
-import (
- "bytes"
- "io"
- "io/ioutil"
- "net/http"
- "strings"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol"
- "github.com/aws/aws-sdk-go/private/protocol/json/jsonutil"
-)
-
-// UnmarshalTypedError provides unmarshaling errors API response errors
-// for both typed and untyped errors.
-type UnmarshalTypedError struct {
- exceptions map[string]func(protocol.ResponseMetadata) error
-}
-
-// NewUnmarshalTypedError returns an UnmarshalTypedError initialized for the
-// set of exception names to the error unmarshalers
-func NewUnmarshalTypedError(exceptions map[string]func(protocol.ResponseMetadata) error) *UnmarshalTypedError {
- return &UnmarshalTypedError{
- exceptions: exceptions,
- }
-}
-
-// UnmarshalError attempts to unmarshal the HTTP response error as a known
-// error type. If unable to unmarshal the error type, the generic SDK error
-// type will be used.
-func (u *UnmarshalTypedError) UnmarshalError(
- resp *http.Response,
- respMeta protocol.ResponseMetadata,
-) (error, error) {
-
- var buf bytes.Buffer
- var jsonErr jsonErrorResponse
- teeReader := io.TeeReader(resp.Body, &buf)
- err := jsonutil.UnmarshalJSONError(&jsonErr, teeReader)
- if err != nil {
- return nil, err
- }
- body := ioutil.NopCloser(&buf)
-
- // Code may be separated by hash(#), with the last element being the code
- // used by the SDK.
- codeParts := strings.SplitN(jsonErr.Code, "#", 2)
- code := codeParts[len(codeParts)-1]
- msg := jsonErr.Message
-
- if fn, ok := u.exceptions[code]; ok {
- // If exception code is know, use associated constructor to get a value
- // for the exception that the JSON body can be unmarshaled into.
- v := fn(respMeta)
- err := jsonutil.UnmarshalJSONCaseInsensitive(v, body)
- if err != nil {
- return nil, err
- }
-
- return v, nil
- }
-
- // fallback to unmodeled generic exceptions
- return awserr.NewRequestFailure(
- awserr.New(code, msg, nil),
- respMeta.StatusCode,
- respMeta.RequestID,
- ), nil
-}
-
-// UnmarshalErrorHandler is a named request handler for unmarshaling jsonrpc
-// protocol request errors
-var UnmarshalErrorHandler = request.NamedHandler{
- Name: "awssdk.jsonrpc.UnmarshalError",
- Fn: UnmarshalError,
-}
-
-// UnmarshalError unmarshals an error response for a JSON RPC service.
-func UnmarshalError(req *request.Request) {
- defer req.HTTPResponse.Body.Close()
-
- var jsonErr jsonErrorResponse
- err := jsonutil.UnmarshalJSONError(&jsonErr, req.HTTPResponse.Body)
- if err != nil {
- req.Error = awserr.NewRequestFailure(
- awserr.New(request.ErrCodeSerialization,
- "failed to unmarshal error message", err),
- req.HTTPResponse.StatusCode,
- req.RequestID,
- )
- return
- }
-
- codes := strings.SplitN(jsonErr.Code, "#", 2)
- req.Error = awserr.NewRequestFailure(
- awserr.New(codes[len(codes)-1], jsonErr.Message, nil),
- req.HTTPResponse.StatusCode,
- req.RequestID,
- )
-}
-
-type jsonErrorResponse struct {
- Code string `json:"__type"`
- Message string `json:"message"`
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonvalue.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonvalue.go
deleted file mode 100644
index 776d11018435..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonvalue.go
+++ /dev/null
@@ -1,76 +0,0 @@
-package protocol
-
-import (
- "encoding/base64"
- "encoding/json"
- "fmt"
- "strconv"
-
- "github.com/aws/aws-sdk-go/aws"
-)
-
-// EscapeMode is the mode that should be use for escaping a value
-type EscapeMode uint
-
-// The modes for escaping a value before it is marshaled, and unmarshaled.
-const (
- NoEscape EscapeMode = iota
- Base64Escape
- QuotedEscape
-)
-
-// EncodeJSONValue marshals the value into a JSON string, and optionally base64
-// encodes the string before returning it.
-//
-// Will panic if the escape mode is unknown.
-func EncodeJSONValue(v aws.JSONValue, escape EscapeMode) (string, error) {
- b, err := json.Marshal(v)
- if err != nil {
- return "", err
- }
-
- switch escape {
- case NoEscape:
- return string(b), nil
- case Base64Escape:
- return base64.StdEncoding.EncodeToString(b), nil
- case QuotedEscape:
- return strconv.Quote(string(b)), nil
- }
-
- panic(fmt.Sprintf("EncodeJSONValue called with unknown EscapeMode, %v", escape))
-}
-
-// DecodeJSONValue will attempt to decode the string input as a JSONValue.
-// Optionally decoding base64 the value first before JSON unmarshaling.
-//
-// Will panic if the escape mode is unknown.
-func DecodeJSONValue(v string, escape EscapeMode) (aws.JSONValue, error) {
- var b []byte
- var err error
-
- switch escape {
- case NoEscape:
- b = []byte(v)
- case Base64Escape:
- b, err = base64.StdEncoding.DecodeString(v)
- case QuotedEscape:
- var u string
- u, err = strconv.Unquote(v)
- b = []byte(u)
- default:
- panic(fmt.Sprintf("DecodeJSONValue called with unknown EscapeMode, %v", escape))
- }
-
- if err != nil {
- return nil, err
- }
-
- m := aws.JSONValue{}
- err = json.Unmarshal(b, &m)
- if err != nil {
- return nil, err
- }
-
- return m, nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/payload.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/payload.go
deleted file mode 100644
index 0ea0647a57df..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/payload.go
+++ /dev/null
@@ -1,81 +0,0 @@
-package protocol
-
-import (
- "io"
- "io/ioutil"
- "net/http"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/client/metadata"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// PayloadUnmarshaler provides the interface for unmarshaling a payload's
-// reader into a SDK shape.
-type PayloadUnmarshaler interface {
- UnmarshalPayload(io.Reader, interface{}) error
-}
-
-// HandlerPayloadUnmarshal implements the PayloadUnmarshaler from a
-// HandlerList. This provides the support for unmarshaling a payload reader to
-// a shape without needing a SDK request first.
-type HandlerPayloadUnmarshal struct {
- Unmarshalers request.HandlerList
-}
-
-// UnmarshalPayload unmarshals the io.Reader payload into the SDK shape using
-// the Unmarshalers HandlerList provided. Returns an error if unable
-// unmarshaling fails.
-func (h HandlerPayloadUnmarshal) UnmarshalPayload(r io.Reader, v interface{}) error {
- req := &request.Request{
- HTTPRequest: &http.Request{},
- HTTPResponse: &http.Response{
- StatusCode: 200,
- Header: http.Header{},
- Body: ioutil.NopCloser(r),
- },
- Data: v,
- }
-
- h.Unmarshalers.Run(req)
-
- return req.Error
-}
-
-// PayloadMarshaler provides the interface for marshaling a SDK shape into and
-// io.Writer.
-type PayloadMarshaler interface {
- MarshalPayload(io.Writer, interface{}) error
-}
-
-// HandlerPayloadMarshal implements the PayloadMarshaler from a HandlerList.
-// This provides support for marshaling a SDK shape into an io.Writer without
-// needing a SDK request first.
-type HandlerPayloadMarshal struct {
- Marshalers request.HandlerList
-}
-
-// MarshalPayload marshals the SDK shape into the io.Writer using the
-// Marshalers HandlerList provided. Returns an error if unable if marshal
-// fails.
-func (h HandlerPayloadMarshal) MarshalPayload(w io.Writer, v interface{}) error {
- req := request.New(
- aws.Config{},
- metadata.ClientInfo{},
- request.Handlers{},
- nil,
- &request.Operation{HTTPMethod: "PUT"},
- v,
- nil,
- )
-
- h.Marshalers.Run(req)
-
- if req.Error != nil {
- return req.Error
- }
-
- io.Copy(w, req.GetBody())
-
- return nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/protocol.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/protocol.go
deleted file mode 100644
index 9d521dcb950a..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/protocol.go
+++ /dev/null
@@ -1,49 +0,0 @@
-package protocol
-
-import (
- "fmt"
- "strings"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// RequireHTTPMinProtocol request handler is used to enforce that
-// the target endpoint supports the given major and minor HTTP protocol version.
-type RequireHTTPMinProtocol struct {
- Major, Minor int
-}
-
-// Handler will mark the request.Request with an error if the
-// target endpoint did not connect with the required HTTP protocol
-// major and minor version.
-func (p RequireHTTPMinProtocol) Handler(r *request.Request) {
- if r.Error != nil || r.HTTPResponse == nil {
- return
- }
-
- if !strings.HasPrefix(r.HTTPResponse.Proto, "HTTP") {
- r.Error = newMinHTTPProtoError(p.Major, p.Minor, r)
- }
-
- if r.HTTPResponse.ProtoMajor < p.Major || r.HTTPResponse.ProtoMinor < p.Minor {
- r.Error = newMinHTTPProtoError(p.Major, p.Minor, r)
- }
-}
-
-// ErrCodeMinimumHTTPProtocolError error code is returned when the target endpoint
-// did not match the required HTTP major and minor protocol version.
-const ErrCodeMinimumHTTPProtocolError = "MinimumHTTPProtocolError"
-
-func newMinHTTPProtoError(major, minor int, r *request.Request) error {
- return awserr.NewRequestFailure(
- awserr.New("MinimumHTTPProtocolError",
- fmt.Sprintf(
- "operation requires minimum HTTP protocol of HTTP/%d.%d, but was %s",
- major, minor, r.HTTPResponse.Proto,
- ),
- nil,
- ),
- r.HTTPResponse.StatusCode, r.RequestID,
- )
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go
deleted file mode 100644
index d40346a7790d..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go
+++ /dev/null
@@ -1,36 +0,0 @@
-// Package query provides serialization of AWS query requests, and responses.
-package query
-
-//go:generate go run -tags codegen ../../../private/model/cli/gen-protocol-tests ../../../models/protocol_tests/input/query.json build_test.go
-
-import (
- "net/url"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol/query/queryutil"
-)
-
-// BuildHandler is a named request handler for building query protocol requests
-var BuildHandler = request.NamedHandler{Name: "awssdk.query.Build", Fn: Build}
-
-// Build builds a request for an AWS Query service.
-func Build(r *request.Request) {
- body := url.Values{
- "Action": {r.Operation.Name},
- "Version": {r.ClientInfo.APIVersion},
- }
- if err := queryutil.Parse(body, r.Params, false); err != nil {
- r.Error = awserr.New(request.ErrCodeSerialization, "failed encoding Query request", err)
- return
- }
-
- if !r.IsPresigned() {
- r.HTTPRequest.Method = "POST"
- r.HTTPRequest.Header.Set("Content-Type", "application/x-www-form-urlencoded; charset=utf-8")
- r.SetBufferBody([]byte(body.Encode()))
- } else { // This is a pre-signed request
- r.HTTPRequest.Method = "GET"
- r.HTTPRequest.URL.RawQuery = body.Encode()
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go
deleted file mode 100644
index 75866d012184..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go
+++ /dev/null
@@ -1,246 +0,0 @@
-package queryutil
-
-import (
- "encoding/base64"
- "fmt"
- "net/url"
- "reflect"
- "sort"
- "strconv"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/private/protocol"
-)
-
-// Parse parses an object i and fills a url.Values object. The isEC2 flag
-// indicates if this is the EC2 Query sub-protocol.
-func Parse(body url.Values, i interface{}, isEC2 bool) error {
- q := queryParser{isEC2: isEC2}
- return q.parseValue(body, reflect.ValueOf(i), "", "")
-}
-
-func elemOf(value reflect.Value) reflect.Value {
- for value.Kind() == reflect.Ptr {
- value = value.Elem()
- }
- return value
-}
-
-type queryParser struct {
- isEC2 bool
-}
-
-func (q *queryParser) parseValue(v url.Values, value reflect.Value, prefix string, tag reflect.StructTag) error {
- value = elemOf(value)
-
- // no need to handle zero values
- if !value.IsValid() {
- return nil
- }
-
- t := tag.Get("type")
- if t == "" {
- switch value.Kind() {
- case reflect.Struct:
- t = "structure"
- case reflect.Slice:
- t = "list"
- case reflect.Map:
- t = "map"
- }
- }
-
- switch t {
- case "structure":
- return q.parseStruct(v, value, prefix)
- case "list":
- return q.parseList(v, value, prefix, tag)
- case "map":
- return q.parseMap(v, value, prefix, tag)
- default:
- return q.parseScalar(v, value, prefix, tag)
- }
-}
-
-func (q *queryParser) parseStruct(v url.Values, value reflect.Value, prefix string) error {
- if !value.IsValid() {
- return nil
- }
-
- t := value.Type()
- for i := 0; i < value.NumField(); i++ {
- elemValue := elemOf(value.Field(i))
- field := t.Field(i)
-
- if field.PkgPath != "" {
- continue // ignore unexported fields
- }
- if field.Tag.Get("ignore") != "" {
- continue
- }
-
- if protocol.CanSetIdempotencyToken(value.Field(i), field) {
- token := protocol.GetIdempotencyToken()
- elemValue = reflect.ValueOf(token)
- }
-
- var name string
- if q.isEC2 {
- name = field.Tag.Get("queryName")
- }
- if name == "" {
- if field.Tag.Get("flattened") != "" && field.Tag.Get("locationNameList") != "" {
- name = field.Tag.Get("locationNameList")
- } else if locName := field.Tag.Get("locationName"); locName != "" {
- name = locName
- }
- if name != "" && q.isEC2 {
- name = strings.ToUpper(name[0:1]) + name[1:]
- }
- }
- if name == "" {
- name = field.Name
- }
-
- if prefix != "" {
- name = prefix + "." + name
- }
-
- if err := q.parseValue(v, elemValue, name, field.Tag); err != nil {
- return err
- }
- }
- return nil
-}
-
-func (q *queryParser) parseList(v url.Values, value reflect.Value, prefix string, tag reflect.StructTag) error {
- // If it's empty, generate an empty value
- if !value.IsNil() && value.Len() == 0 {
- v.Set(prefix, "")
- return nil
- }
-
- if _, ok := value.Interface().([]byte); ok {
- return q.parseScalar(v, value, prefix, tag)
- }
-
- // check for unflattened list member
- if !q.isEC2 && tag.Get("flattened") == "" {
- if listName := tag.Get("locationNameList"); listName == "" {
- prefix += ".member"
- } else {
- prefix += "." + listName
- }
- }
-
- for i := 0; i < value.Len(); i++ {
- slicePrefix := prefix
- if slicePrefix == "" {
- slicePrefix = strconv.Itoa(i + 1)
- } else {
- slicePrefix = slicePrefix + "." + strconv.Itoa(i+1)
- }
- if err := q.parseValue(v, value.Index(i), slicePrefix, ""); err != nil {
- return err
- }
- }
- return nil
-}
-
-func (q *queryParser) parseMap(v url.Values, value reflect.Value, prefix string, tag reflect.StructTag) error {
- // If it's empty, generate an empty value
- if !value.IsNil() && value.Len() == 0 {
- v.Set(prefix, "")
- return nil
- }
-
- // check for unflattened list member
- if !q.isEC2 && tag.Get("flattened") == "" {
- prefix += ".entry"
- }
-
- // sort keys for improved serialization consistency.
- // this is not strictly necessary for protocol support.
- mapKeyValues := value.MapKeys()
- mapKeys := map[string]reflect.Value{}
- mapKeyNames := make([]string, len(mapKeyValues))
- for i, mapKey := range mapKeyValues {
- name := mapKey.String()
- mapKeys[name] = mapKey
- mapKeyNames[i] = name
- }
- sort.Strings(mapKeyNames)
-
- for i, mapKeyName := range mapKeyNames {
- mapKey := mapKeys[mapKeyName]
- mapValue := value.MapIndex(mapKey)
-
- kname := tag.Get("locationNameKey")
- if kname == "" {
- kname = "key"
- }
- vname := tag.Get("locationNameValue")
- if vname == "" {
- vname = "value"
- }
-
- // serialize key
- var keyName string
- if prefix == "" {
- keyName = strconv.Itoa(i+1) + "." + kname
- } else {
- keyName = prefix + "." + strconv.Itoa(i+1) + "." + kname
- }
-
- if err := q.parseValue(v, mapKey, keyName, ""); err != nil {
- return err
- }
-
- // serialize value
- var valueName string
- if prefix == "" {
- valueName = strconv.Itoa(i+1) + "." + vname
- } else {
- valueName = prefix + "." + strconv.Itoa(i+1) + "." + vname
- }
-
- if err := q.parseValue(v, mapValue, valueName, ""); err != nil {
- return err
- }
- }
-
- return nil
-}
-
-func (q *queryParser) parseScalar(v url.Values, r reflect.Value, name string, tag reflect.StructTag) error {
- switch value := r.Interface().(type) {
- case string:
- v.Set(name, value)
- case []byte:
- if !r.IsNil() {
- v.Set(name, base64.StdEncoding.EncodeToString(value))
- }
- case bool:
- v.Set(name, strconv.FormatBool(value))
- case int64:
- v.Set(name, strconv.FormatInt(value, 10))
- case int:
- v.Set(name, strconv.Itoa(value))
- case float64:
- v.Set(name, strconv.FormatFloat(value, 'f', -1, 64))
- case float32:
- v.Set(name, strconv.FormatFloat(float64(value), 'f', -1, 32))
- case time.Time:
- const ISO8601UTC = "2006-01-02T15:04:05Z"
- format := tag.Get("timestampFormat")
- if len(format) == 0 {
- format = protocol.ISO8601TimeFormatName
- }
-
- v.Set(name, protocol.FormatTime(format, value))
- default:
- return fmt.Errorf("unsupported value for param %s: %v (%s)", name, r.Interface(), r.Type().Name())
- }
- return nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal.go
deleted file mode 100644
index 9231e95d1604..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal.go
+++ /dev/null
@@ -1,39 +0,0 @@
-package query
-
-//go:generate go run -tags codegen ../../../private/model/cli/gen-protocol-tests ../../../models/protocol_tests/output/query.json unmarshal_test.go
-
-import (
- "encoding/xml"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil"
-)
-
-// UnmarshalHandler is a named request handler for unmarshaling query protocol requests
-var UnmarshalHandler = request.NamedHandler{Name: "awssdk.query.Unmarshal", Fn: Unmarshal}
-
-// UnmarshalMetaHandler is a named request handler for unmarshaling query protocol request metadata
-var UnmarshalMetaHandler = request.NamedHandler{Name: "awssdk.query.UnmarshalMeta", Fn: UnmarshalMeta}
-
-// Unmarshal unmarshals a response for an AWS Query service.
-func Unmarshal(r *request.Request) {
- defer r.HTTPResponse.Body.Close()
- if r.DataFilled() {
- decoder := xml.NewDecoder(r.HTTPResponse.Body)
- err := xmlutil.UnmarshalXML(r.Data, decoder, r.Operation.Name+"Result")
- if err != nil {
- r.Error = awserr.NewRequestFailure(
- awserr.New(request.ErrCodeSerialization, "failed decoding Query response", err),
- r.HTTPResponse.StatusCode,
- r.RequestID,
- )
- return
- }
- }
-}
-
-// UnmarshalMeta unmarshals header response values for an AWS Query service.
-func UnmarshalMeta(r *request.Request) {
- r.RequestID = r.HTTPResponse.Header.Get("X-Amzn-Requestid")
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal_error.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal_error.go
deleted file mode 100644
index 831b0110c54b..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal_error.go
+++ /dev/null
@@ -1,69 +0,0 @@
-package query
-
-import (
- "encoding/xml"
- "fmt"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil"
-)
-
-// UnmarshalErrorHandler is a name request handler to unmarshal request errors
-var UnmarshalErrorHandler = request.NamedHandler{Name: "awssdk.query.UnmarshalError", Fn: UnmarshalError}
-
-type xmlErrorResponse struct {
- Code string `xml:"Error>Code"`
- Message string `xml:"Error>Message"`
- RequestID string `xml:"RequestId"`
-}
-
-type xmlResponseError struct {
- xmlErrorResponse
-}
-
-func (e *xmlResponseError) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
- const svcUnavailableTagName = "ServiceUnavailableException"
- const errorResponseTagName = "ErrorResponse"
-
- switch start.Name.Local {
- case svcUnavailableTagName:
- e.Code = svcUnavailableTagName
- e.Message = "service is unavailable"
- return d.Skip()
-
- case errorResponseTagName:
- return d.DecodeElement(&e.xmlErrorResponse, &start)
-
- default:
- return fmt.Errorf("unknown error response tag, %v", start)
- }
-}
-
-// UnmarshalError unmarshals an error response for an AWS Query service.
-func UnmarshalError(r *request.Request) {
- defer r.HTTPResponse.Body.Close()
-
- var respErr xmlResponseError
- err := xmlutil.UnmarshalXMLError(&respErr, r.HTTPResponse.Body)
- if err != nil {
- r.Error = awserr.NewRequestFailure(
- awserr.New(request.ErrCodeSerialization,
- "failed to unmarshal error message", err),
- r.HTTPResponse.StatusCode,
- r.RequestID,
- )
- return
- }
-
- reqID := respErr.RequestID
- if len(reqID) == 0 {
- reqID = r.RequestID
- }
-
- r.Error = awserr.NewRequestFailure(
- awserr.New(respErr.Code, respErr.Message, nil),
- r.HTTPResponse.StatusCode,
- reqID,
- )
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/build.go
deleted file mode 100644
index 1301b149d35e..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/build.go
+++ /dev/null
@@ -1,310 +0,0 @@
-// Package rest provides RESTful serialization of AWS requests and responses.
-package rest
-
-import (
- "bytes"
- "encoding/base64"
- "fmt"
- "io"
- "net/http"
- "net/url"
- "path"
- "reflect"
- "strconv"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol"
-)
-
-// Whether the byte value can be sent without escaping in AWS URLs
-var noEscape [256]bool
-
-var errValueNotSet = fmt.Errorf("value not set")
-
-var byteSliceType = reflect.TypeOf([]byte{})
-
-func init() {
- for i := 0; i < len(noEscape); i++ {
- // AWS expects every character except these to be escaped
- noEscape[i] = (i >= 'A' && i <= 'Z') ||
- (i >= 'a' && i <= 'z') ||
- (i >= '0' && i <= '9') ||
- i == '-' ||
- i == '.' ||
- i == '_' ||
- i == '~'
- }
-}
-
-// BuildHandler is a named request handler for building rest protocol requests
-var BuildHandler = request.NamedHandler{Name: "awssdk.rest.Build", Fn: Build}
-
-// Build builds the REST component of a service request.
-func Build(r *request.Request) {
- if r.ParamsFilled() {
- v := reflect.ValueOf(r.Params).Elem()
- buildLocationElements(r, v, false)
- buildBody(r, v)
- }
-}
-
-// BuildAsGET builds the REST component of a service request with the ability to hoist
-// data from the body.
-func BuildAsGET(r *request.Request) {
- if r.ParamsFilled() {
- v := reflect.ValueOf(r.Params).Elem()
- buildLocationElements(r, v, true)
- buildBody(r, v)
- }
-}
-
-func buildLocationElements(r *request.Request, v reflect.Value, buildGETQuery bool) {
- query := r.HTTPRequest.URL.Query()
-
- // Setup the raw path to match the base path pattern. This is needed
- // so that when the path is mutated a custom escaped version can be
- // stored in RawPath that will be used by the Go client.
- r.HTTPRequest.URL.RawPath = r.HTTPRequest.URL.Path
-
- for i := 0; i < v.NumField(); i++ {
- m := v.Field(i)
- if n := v.Type().Field(i).Name; n[0:1] == strings.ToLower(n[0:1]) {
- continue
- }
-
- if m.IsValid() {
- field := v.Type().Field(i)
- name := field.Tag.Get("locationName")
- if name == "" {
- name = field.Name
- }
- if kind := m.Kind(); kind == reflect.Ptr {
- m = m.Elem()
- } else if kind == reflect.Interface {
- if !m.Elem().IsValid() {
- continue
- }
- }
- if !m.IsValid() {
- continue
- }
- if field.Tag.Get("ignore") != "" {
- continue
- }
-
- // Support the ability to customize values to be marshaled as a
- // blob even though they were modeled as a string. Required for S3
- // API operations like SSECustomerKey is modeled as stirng but
- // required to be base64 encoded in request.
- if field.Tag.Get("marshal-as") == "blob" {
- m = m.Convert(byteSliceType)
- }
-
- var err error
- switch field.Tag.Get("location") {
- case "headers": // header maps
- err = buildHeaderMap(&r.HTTPRequest.Header, m, field.Tag)
- case "header":
- err = buildHeader(&r.HTTPRequest.Header, m, name, field.Tag)
- case "uri":
- err = buildURI(r.HTTPRequest.URL, m, name, field.Tag)
- case "querystring":
- err = buildQueryString(query, m, name, field.Tag)
- default:
- if buildGETQuery {
- err = buildQueryString(query, m, name, field.Tag)
- }
- }
- r.Error = err
- }
- if r.Error != nil {
- return
- }
- }
-
- r.HTTPRequest.URL.RawQuery = query.Encode()
- if !aws.BoolValue(r.Config.DisableRestProtocolURICleaning) {
- cleanPath(r.HTTPRequest.URL)
- }
-}
-
-func buildBody(r *request.Request, v reflect.Value) {
- if field, ok := v.Type().FieldByName("_"); ok {
- if payloadName := field.Tag.Get("payload"); payloadName != "" {
- pfield, _ := v.Type().FieldByName(payloadName)
- if ptag := pfield.Tag.Get("type"); ptag != "" && ptag != "structure" {
- payload := reflect.Indirect(v.FieldByName(payloadName))
- if payload.IsValid() && payload.Interface() != nil {
- switch reader := payload.Interface().(type) {
- case io.ReadSeeker:
- r.SetReaderBody(reader)
- case []byte:
- r.SetBufferBody(reader)
- case string:
- r.SetStringBody(reader)
- default:
- r.Error = awserr.New(request.ErrCodeSerialization,
- "failed to encode REST request",
- fmt.Errorf("unknown payload type %s", payload.Type()))
- }
- }
- }
- }
- }
-}
-
-func buildHeader(header *http.Header, v reflect.Value, name string, tag reflect.StructTag) error {
- str, err := convertType(v, tag)
- if err == errValueNotSet {
- return nil
- } else if err != nil {
- return awserr.New(request.ErrCodeSerialization, "failed to encode REST request", err)
- }
-
- name = strings.TrimSpace(name)
- str = strings.TrimSpace(str)
-
- header.Add(name, str)
-
- return nil
-}
-
-func buildHeaderMap(header *http.Header, v reflect.Value, tag reflect.StructTag) error {
- prefix := tag.Get("locationName")
- for _, key := range v.MapKeys() {
- str, err := convertType(v.MapIndex(key), tag)
- if err == errValueNotSet {
- continue
- } else if err != nil {
- return awserr.New(request.ErrCodeSerialization, "failed to encode REST request", err)
-
- }
- keyStr := strings.TrimSpace(key.String())
- str = strings.TrimSpace(str)
-
- header.Add(prefix+keyStr, str)
- }
- return nil
-}
-
-func buildURI(u *url.URL, v reflect.Value, name string, tag reflect.StructTag) error {
- value, err := convertType(v, tag)
- if err == errValueNotSet {
- return nil
- } else if err != nil {
- return awserr.New(request.ErrCodeSerialization, "failed to encode REST request", err)
- }
-
- u.Path = strings.Replace(u.Path, "{"+name+"}", value, -1)
- u.Path = strings.Replace(u.Path, "{"+name+"+}", value, -1)
-
- u.RawPath = strings.Replace(u.RawPath, "{"+name+"}", EscapePath(value, true), -1)
- u.RawPath = strings.Replace(u.RawPath, "{"+name+"+}", EscapePath(value, false), -1)
-
- return nil
-}
-
-func buildQueryString(query url.Values, v reflect.Value, name string, tag reflect.StructTag) error {
- switch value := v.Interface().(type) {
- case []*string:
- for _, item := range value {
- query.Add(name, *item)
- }
- case map[string]*string:
- for key, item := range value {
- query.Add(key, *item)
- }
- case map[string][]*string:
- for key, items := range value {
- for _, item := range items {
- query.Add(key, *item)
- }
- }
- default:
- str, err := convertType(v, tag)
- if err == errValueNotSet {
- return nil
- } else if err != nil {
- return awserr.New(request.ErrCodeSerialization, "failed to encode REST request", err)
- }
- query.Set(name, str)
- }
-
- return nil
-}
-
-func cleanPath(u *url.URL) {
- hasSlash := strings.HasSuffix(u.Path, "/")
-
- // clean up path, removing duplicate `/`
- u.Path = path.Clean(u.Path)
- u.RawPath = path.Clean(u.RawPath)
-
- if hasSlash && !strings.HasSuffix(u.Path, "/") {
- u.Path += "/"
- u.RawPath += "/"
- }
-}
-
-// EscapePath escapes part of a URL path in Amazon style
-func EscapePath(path string, encodeSep bool) string {
- var buf bytes.Buffer
- for i := 0; i < len(path); i++ {
- c := path[i]
- if noEscape[c] || (c == '/' && !encodeSep) {
- buf.WriteByte(c)
- } else {
- fmt.Fprintf(&buf, "%%%02X", c)
- }
- }
- return buf.String()
-}
-
-func convertType(v reflect.Value, tag reflect.StructTag) (str string, err error) {
- v = reflect.Indirect(v)
- if !v.IsValid() {
- return "", errValueNotSet
- }
-
- switch value := v.Interface().(type) {
- case string:
- str = value
- case []byte:
- str = base64.StdEncoding.EncodeToString(value)
- case bool:
- str = strconv.FormatBool(value)
- case int64:
- str = strconv.FormatInt(value, 10)
- case float64:
- str = strconv.FormatFloat(value, 'f', -1, 64)
- case time.Time:
- format := tag.Get("timestampFormat")
- if len(format) == 0 {
- format = protocol.RFC822TimeFormatName
- if tag.Get("location") == "querystring" {
- format = protocol.ISO8601TimeFormatName
- }
- }
- str = protocol.FormatTime(format, value)
- case aws.JSONValue:
- if len(value) == 0 {
- return "", errValueNotSet
- }
- escaping := protocol.NoEscape
- if tag.Get("location") == "header" {
- escaping = protocol.Base64Escape
- }
- str, err = protocol.EncodeJSONValue(value, escaping)
- if err != nil {
- return "", fmt.Errorf("unable to encode JSONValue, %v", err)
- }
- default:
- err := fmt.Errorf("unsupported value for param %v (%s)", v.Interface(), v.Type())
- return "", err
- }
- return str, nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/payload.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/payload.go
deleted file mode 100644
index 4366de2e1e8f..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/payload.go
+++ /dev/null
@@ -1,45 +0,0 @@
-package rest
-
-import "reflect"
-
-// PayloadMember returns the payload field member of i if there is one, or nil.
-func PayloadMember(i interface{}) interface{} {
- if i == nil {
- return nil
- }
-
- v := reflect.ValueOf(i).Elem()
- if !v.IsValid() {
- return nil
- }
- if field, ok := v.Type().FieldByName("_"); ok {
- if payloadName := field.Tag.Get("payload"); payloadName != "" {
- field, _ := v.Type().FieldByName(payloadName)
- if field.Tag.Get("type") != "structure" {
- return nil
- }
-
- payload := v.FieldByName(payloadName)
- if payload.IsValid() || (payload.Kind() == reflect.Ptr && !payload.IsNil()) {
- return payload.Interface()
- }
- }
- }
- return nil
-}
-
-// PayloadType returns the type of a payload field member of i if there is one, or "".
-func PayloadType(i interface{}) string {
- v := reflect.Indirect(reflect.ValueOf(i))
- if !v.IsValid() {
- return ""
- }
- if field, ok := v.Type().FieldByName("_"); ok {
- if payloadName := field.Tag.Get("payload"); payloadName != "" {
- if member, ok := v.Type().FieldByName(payloadName); ok {
- return member.Tag.Get("type")
- }
- }
- }
- return ""
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/unmarshal.go
deleted file mode 100644
index 92f8b4d9a48a..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/unmarshal.go
+++ /dev/null
@@ -1,257 +0,0 @@
-package rest
-
-import (
- "bytes"
- "encoding/base64"
- "fmt"
- "io"
- "io/ioutil"
- "net/http"
- "reflect"
- "strconv"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
- awsStrings "github.com/aws/aws-sdk-go/internal/strings"
- "github.com/aws/aws-sdk-go/private/protocol"
-)
-
-// UnmarshalHandler is a named request handler for unmarshaling rest protocol requests
-var UnmarshalHandler = request.NamedHandler{Name: "awssdk.rest.Unmarshal", Fn: Unmarshal}
-
-// UnmarshalMetaHandler is a named request handler for unmarshaling rest protocol request metadata
-var UnmarshalMetaHandler = request.NamedHandler{Name: "awssdk.rest.UnmarshalMeta", Fn: UnmarshalMeta}
-
-// Unmarshal unmarshals the REST component of a response in a REST service.
-func Unmarshal(r *request.Request) {
- if r.DataFilled() {
- v := reflect.Indirect(reflect.ValueOf(r.Data))
- if err := unmarshalBody(r, v); err != nil {
- r.Error = err
- }
- }
-}
-
-// UnmarshalMeta unmarshals the REST metadata of a response in a REST service
-func UnmarshalMeta(r *request.Request) {
- r.RequestID = r.HTTPResponse.Header.Get("X-Amzn-Requestid")
- if r.RequestID == "" {
- // Alternative version of request id in the header
- r.RequestID = r.HTTPResponse.Header.Get("X-Amz-Request-Id")
- }
- if r.DataFilled() {
- if err := UnmarshalResponse(r.HTTPResponse, r.Data, aws.BoolValue(r.Config.LowerCaseHeaderMaps)); err != nil {
- r.Error = err
- }
- }
-}
-
-// UnmarshalResponse attempts to unmarshal the REST response headers to
-// the data type passed in. The type must be a pointer. An error is returned
-// with any error unmarshaling the response into the target datatype.
-func UnmarshalResponse(resp *http.Response, data interface{}, lowerCaseHeaderMaps bool) error {
- v := reflect.Indirect(reflect.ValueOf(data))
- return unmarshalLocationElements(resp, v, lowerCaseHeaderMaps)
-}
-
-func unmarshalBody(r *request.Request, v reflect.Value) error {
- if field, ok := v.Type().FieldByName("_"); ok {
- if payloadName := field.Tag.Get("payload"); payloadName != "" {
- pfield, _ := v.Type().FieldByName(payloadName)
- if ptag := pfield.Tag.Get("type"); ptag != "" && ptag != "structure" {
- payload := v.FieldByName(payloadName)
- if payload.IsValid() {
- switch payload.Interface().(type) {
- case []byte:
- defer r.HTTPResponse.Body.Close()
- b, err := ioutil.ReadAll(r.HTTPResponse.Body)
- if err != nil {
- return awserr.New(request.ErrCodeSerialization, "failed to decode REST response", err)
- }
-
- payload.Set(reflect.ValueOf(b))
-
- case *string:
- defer r.HTTPResponse.Body.Close()
- b, err := ioutil.ReadAll(r.HTTPResponse.Body)
- if err != nil {
- return awserr.New(request.ErrCodeSerialization, "failed to decode REST response", err)
- }
-
- str := string(b)
- payload.Set(reflect.ValueOf(&str))
-
- default:
- switch payload.Type().String() {
- case "io.ReadCloser":
- payload.Set(reflect.ValueOf(r.HTTPResponse.Body))
-
- case "io.ReadSeeker":
- b, err := ioutil.ReadAll(r.HTTPResponse.Body)
- if err != nil {
- return awserr.New(request.ErrCodeSerialization,
- "failed to read response body", err)
- }
- payload.Set(reflect.ValueOf(ioutil.NopCloser(bytes.NewReader(b))))
-
- default:
- io.Copy(ioutil.Discard, r.HTTPResponse.Body)
- r.HTTPResponse.Body.Close()
- return awserr.New(request.ErrCodeSerialization,
- "failed to decode REST response",
- fmt.Errorf("unknown payload type %s", payload.Type()))
- }
- }
- }
- }
- }
- }
-
- return nil
-}
-
-func unmarshalLocationElements(resp *http.Response, v reflect.Value, lowerCaseHeaderMaps bool) error {
- for i := 0; i < v.NumField(); i++ {
- m, field := v.Field(i), v.Type().Field(i)
- if n := field.Name; n[0:1] == strings.ToLower(n[0:1]) {
- continue
- }
-
- if m.IsValid() {
- name := field.Tag.Get("locationName")
- if name == "" {
- name = field.Name
- }
-
- switch field.Tag.Get("location") {
- case "statusCode":
- unmarshalStatusCode(m, resp.StatusCode)
-
- case "header":
- err := unmarshalHeader(m, resp.Header.Get(name), field.Tag)
- if err != nil {
- return awserr.New(request.ErrCodeSerialization, "failed to decode REST response", err)
- }
-
- case "headers":
- prefix := field.Tag.Get("locationName")
- err := unmarshalHeaderMap(m, resp.Header, prefix, lowerCaseHeaderMaps)
- if err != nil {
- awserr.New(request.ErrCodeSerialization, "failed to decode REST response", err)
- }
- }
- }
- }
-
- return nil
-}
-
-func unmarshalStatusCode(v reflect.Value, statusCode int) {
- if !v.IsValid() {
- return
- }
-
- switch v.Interface().(type) {
- case *int64:
- s := int64(statusCode)
- v.Set(reflect.ValueOf(&s))
- }
-}
-
-func unmarshalHeaderMap(r reflect.Value, headers http.Header, prefix string, normalize bool) error {
- if len(headers) == 0 {
- return nil
- }
- switch r.Interface().(type) {
- case map[string]*string: // we only support string map value types
- out := map[string]*string{}
- for k, v := range headers {
- if awsStrings.HasPrefixFold(k, prefix) {
- if normalize == true {
- k = strings.ToLower(k)
- } else {
- k = http.CanonicalHeaderKey(k)
- }
- out[k[len(prefix):]] = &v[0]
- }
- }
- if len(out) != 0 {
- r.Set(reflect.ValueOf(out))
- }
-
- }
- return nil
-}
-
-func unmarshalHeader(v reflect.Value, header string, tag reflect.StructTag) error {
- switch tag.Get("type") {
- case "jsonvalue":
- if len(header) == 0 {
- return nil
- }
- case "blob":
- if len(header) == 0 {
- return nil
- }
- default:
- if !v.IsValid() || (header == "" && v.Elem().Kind() != reflect.String) {
- return nil
- }
- }
-
- switch v.Interface().(type) {
- case *string:
- v.Set(reflect.ValueOf(&header))
- case []byte:
- b, err := base64.StdEncoding.DecodeString(header)
- if err != nil {
- return err
- }
- v.Set(reflect.ValueOf(b))
- case *bool:
- b, err := strconv.ParseBool(header)
- if err != nil {
- return err
- }
- v.Set(reflect.ValueOf(&b))
- case *int64:
- i, err := strconv.ParseInt(header, 10, 64)
- if err != nil {
- return err
- }
- v.Set(reflect.ValueOf(&i))
- case *float64:
- f, err := strconv.ParseFloat(header, 64)
- if err != nil {
- return err
- }
- v.Set(reflect.ValueOf(&f))
- case *time.Time:
- format := tag.Get("timestampFormat")
- if len(format) == 0 {
- format = protocol.RFC822TimeFormatName
- }
- t, err := protocol.ParseTime(format, header)
- if err != nil {
- return err
- }
- v.Set(reflect.ValueOf(&t))
- case aws.JSONValue:
- escaping := protocol.NoEscape
- if tag.Get("location") == "header" {
- escaping = protocol.Base64Escape
- }
- m, err := protocol.DecodeJSONValue(header, escaping)
- if err != nil {
- return err
- }
- v.Set(reflect.ValueOf(m))
- default:
- err := fmt.Errorf("Unsupported value for param %v (%s)", v.Interface(), v.Type())
- return err
- }
- return nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/timestamp.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/timestamp.go
deleted file mode 100644
index 98f4caed91cc..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/timestamp.go
+++ /dev/null
@@ -1,85 +0,0 @@
-package protocol
-
-import (
- "math"
- "strconv"
- "time"
-
- "github.com/aws/aws-sdk-go/internal/sdkmath"
-)
-
-// Names of time formats supported by the SDK
-const (
- RFC822TimeFormatName = "rfc822"
- ISO8601TimeFormatName = "iso8601"
- UnixTimeFormatName = "unixTimestamp"
-)
-
-// Time formats supported by the SDK
-// Output time is intended to not contain decimals
-const (
- // RFC 7231#section-7.1.1.1 timetamp format. e.g Tue, 29 Apr 2014 18:30:38 GMT
- RFC822TimeFormat = "Mon, 2 Jan 2006 15:04:05 GMT"
-
- // This format is used for output time without seconds precision
- RFC822OutputTimeFormat = "Mon, 02 Jan 2006 15:04:05 GMT"
-
- // RFC3339 a subset of the ISO8601 timestamp format. e.g 2014-04-29T18:30:38Z
- ISO8601TimeFormat = "2006-01-02T15:04:05.999999999Z"
-
- // This format is used for output time with fractional second precision up to milliseconds
- ISO8601OutputTimeFormat = "2006-01-02T15:04:05.999999999Z"
-)
-
-// IsKnownTimestampFormat returns if the timestamp format name
-// is know to the SDK's protocols.
-func IsKnownTimestampFormat(name string) bool {
- switch name {
- case RFC822TimeFormatName:
- fallthrough
- case ISO8601TimeFormatName:
- fallthrough
- case UnixTimeFormatName:
- return true
- default:
- return false
- }
-}
-
-// FormatTime returns a string value of the time.
-func FormatTime(name string, t time.Time) string {
- t = t.UTC().Truncate(time.Millisecond)
-
- switch name {
- case RFC822TimeFormatName:
- return t.Format(RFC822OutputTimeFormat)
- case ISO8601TimeFormatName:
- return t.Format(ISO8601OutputTimeFormat)
- case UnixTimeFormatName:
- ms := t.UnixNano() / int64(time.Millisecond)
- return strconv.FormatFloat(float64(ms)/1e3, 'f', -1, 64)
- default:
- panic("unknown timestamp format name, " + name)
- }
-}
-
-// ParseTime attempts to parse the time given the format. Returns
-// the time if it was able to be parsed, and fails otherwise.
-func ParseTime(formatName, value string) (time.Time, error) {
- switch formatName {
- case RFC822TimeFormatName:
- return time.Parse(RFC822TimeFormat, value)
- case ISO8601TimeFormatName:
- return time.Parse(ISO8601TimeFormat, value)
- case UnixTimeFormatName:
- v, err := strconv.ParseFloat(value, 64)
- _, dec := math.Modf(v)
- dec = sdkmath.Round(dec*1e3) / 1e3 //Rounds 0.1229999 to 0.123
- if err != nil {
- return time.Time{}, err
- }
- return time.Unix(int64(v), int64(dec*(1e9))), nil
- default:
- panic("unknown timestamp format name, " + formatName)
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal.go
deleted file mode 100644
index f614ef898be8..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal.go
+++ /dev/null
@@ -1,27 +0,0 @@
-package protocol
-
-import (
- "io"
- "io/ioutil"
-
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// UnmarshalDiscardBodyHandler is a named request handler to empty and close a response's body
-var UnmarshalDiscardBodyHandler = request.NamedHandler{Name: "awssdk.shared.UnmarshalDiscardBody", Fn: UnmarshalDiscardBody}
-
-// UnmarshalDiscardBody is a request handler to empty a response's body and closing it.
-func UnmarshalDiscardBody(r *request.Request) {
- if r.HTTPResponse == nil || r.HTTPResponse.Body == nil {
- return
- }
-
- io.Copy(ioutil.Discard, r.HTTPResponse.Body)
- r.HTTPResponse.Body.Close()
-}
-
-// ResponseMetadata provides the SDK response metadata attributes.
-type ResponseMetadata struct {
- StatusCode int
- RequestID string
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal_error.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal_error.go
deleted file mode 100644
index cc857f136c53..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/unmarshal_error.go
+++ /dev/null
@@ -1,65 +0,0 @@
-package protocol
-
-import (
- "net/http"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// UnmarshalErrorHandler provides unmarshaling errors API response errors for
-// both typed and untyped errors.
-type UnmarshalErrorHandler struct {
- unmarshaler ErrorUnmarshaler
-}
-
-// ErrorUnmarshaler is an abstract interface for concrete implementations to
-// unmarshal protocol specific response errors.
-type ErrorUnmarshaler interface {
- UnmarshalError(*http.Response, ResponseMetadata) (error, error)
-}
-
-// NewUnmarshalErrorHandler returns an UnmarshalErrorHandler
-// initialized for the set of exception names to the error unmarshalers
-func NewUnmarshalErrorHandler(unmarshaler ErrorUnmarshaler) *UnmarshalErrorHandler {
- return &UnmarshalErrorHandler{
- unmarshaler: unmarshaler,
- }
-}
-
-// UnmarshalErrorHandlerName is the name of the named handler.
-const UnmarshalErrorHandlerName = "awssdk.protocol.UnmarshalError"
-
-// NamedHandler returns a NamedHandler for the unmarshaler using the set of
-// errors the unmarshaler was initialized for.
-func (u *UnmarshalErrorHandler) NamedHandler() request.NamedHandler {
- return request.NamedHandler{
- Name: UnmarshalErrorHandlerName,
- Fn: u.UnmarshalError,
- }
-}
-
-// UnmarshalError will attempt to unmarshal the API response's error message
-// into either a generic SDK error type, or a typed error corresponding to the
-// errors exception name.
-func (u *UnmarshalErrorHandler) UnmarshalError(r *request.Request) {
- defer r.HTTPResponse.Body.Close()
-
- respMeta := ResponseMetadata{
- StatusCode: r.HTTPResponse.StatusCode,
- RequestID: r.RequestID,
- }
-
- v, err := u.unmarshaler.UnmarshalError(r.HTTPResponse, respMeta)
- if err != nil {
- r.Error = awserr.NewRequestFailure(
- awserr.New(request.ErrCodeSerialization,
- "failed to unmarshal response error", err),
- respMeta.StatusCode,
- respMeta.RequestID,
- )
- return
- }
-
- r.Error = v
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go
deleted file mode 100644
index 09ad951595e4..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go
+++ /dev/null
@@ -1,315 +0,0 @@
-// Package xmlutil provides XML serialization of AWS requests and responses.
-package xmlutil
-
-import (
- "encoding/base64"
- "encoding/xml"
- "fmt"
- "reflect"
- "sort"
- "strconv"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/private/protocol"
-)
-
-// BuildXML will serialize params into an xml.Encoder. Error will be returned
-// if the serialization of any of the params or nested values fails.
-func BuildXML(params interface{}, e *xml.Encoder) error {
- return buildXML(params, e, false)
-}
-
-func buildXML(params interface{}, e *xml.Encoder, sorted bool) error {
- b := xmlBuilder{encoder: e, namespaces: map[string]string{}}
- root := NewXMLElement(xml.Name{})
- if err := b.buildValue(reflect.ValueOf(params), root, ""); err != nil {
- return err
- }
- for _, c := range root.Children {
- for _, v := range c {
- return StructToXML(e, v, sorted)
- }
- }
- return nil
-}
-
-// Returns the reflection element of a value, if it is a pointer.
-func elemOf(value reflect.Value) reflect.Value {
- for value.Kind() == reflect.Ptr {
- value = value.Elem()
- }
- return value
-}
-
-// A xmlBuilder serializes values from Go code to XML
-type xmlBuilder struct {
- encoder *xml.Encoder
- namespaces map[string]string
-}
-
-// buildValue generic XMLNode builder for any type. Will build value for their specific type
-// struct, list, map, scalar.
-//
-// Also takes a "type" tag value to set what type a value should be converted to XMLNode as. If
-// type is not provided reflect will be used to determine the value's type.
-func (b *xmlBuilder) buildValue(value reflect.Value, current *XMLNode, tag reflect.StructTag) error {
- value = elemOf(value)
- if !value.IsValid() { // no need to handle zero values
- return nil
- } else if tag.Get("location") != "" { // don't handle non-body location values
- return nil
- }
-
- xml := tag.Get("xml")
- if len(xml) != 0 {
- name := strings.SplitAfterN(xml, ",", 2)[0]
- if name == "-" {
- return nil
- }
- }
-
- t := tag.Get("type")
- if t == "" {
- switch value.Kind() {
- case reflect.Struct:
- t = "structure"
- case reflect.Slice:
- t = "list"
- case reflect.Map:
- t = "map"
- }
- }
-
- switch t {
- case "structure":
- if field, ok := value.Type().FieldByName("_"); ok {
- tag = tag + reflect.StructTag(" ") + field.Tag
- }
- return b.buildStruct(value, current, tag)
- case "list":
- return b.buildList(value, current, tag)
- case "map":
- return b.buildMap(value, current, tag)
- default:
- return b.buildScalar(value, current, tag)
- }
-}
-
-// buildStruct adds a struct and its fields to the current XMLNode. All fields and any nested
-// types are converted to XMLNodes also.
-func (b *xmlBuilder) buildStruct(value reflect.Value, current *XMLNode, tag reflect.StructTag) error {
- if !value.IsValid() {
- return nil
- }
-
- // unwrap payloads
- if payload := tag.Get("payload"); payload != "" {
- field, _ := value.Type().FieldByName(payload)
- tag = field.Tag
- value = elemOf(value.FieldByName(payload))
-
- if !value.IsValid() {
- return nil
- }
- }
-
- child := NewXMLElement(xml.Name{Local: tag.Get("locationName")})
-
- // there is an xmlNamespace associated with this struct
- if prefix, uri := tag.Get("xmlPrefix"), tag.Get("xmlURI"); uri != "" {
- ns := xml.Attr{
- Name: xml.Name{Local: "xmlns"},
- Value: uri,
- }
- if prefix != "" {
- b.namespaces[prefix] = uri // register the namespace
- ns.Name.Local = "xmlns:" + prefix
- }
-
- child.Attr = append(child.Attr, ns)
- }
-
- var payloadFields, nonPayloadFields int
-
- t := value.Type()
- for i := 0; i < value.NumField(); i++ {
- member := elemOf(value.Field(i))
- field := t.Field(i)
-
- if field.PkgPath != "" {
- continue // ignore unexported fields
- }
- if field.Tag.Get("ignore") != "" {
- continue
- }
-
- mTag := field.Tag
- if mTag.Get("location") != "" { // skip non-body members
- nonPayloadFields++
- continue
- }
- payloadFields++
-
- if protocol.CanSetIdempotencyToken(value.Field(i), field) {
- token := protocol.GetIdempotencyToken()
- member = reflect.ValueOf(token)
- }
-
- memberName := mTag.Get("locationName")
- if memberName == "" {
- memberName = field.Name
- mTag = reflect.StructTag(string(mTag) + ` locationName:"` + memberName + `"`)
- }
- if err := b.buildValue(member, child, mTag); err != nil {
- return err
- }
- }
-
- // Only case where the child shape is not added is if the shape only contains
- // non-payload fields, e.g headers/query.
- if !(payloadFields == 0 && nonPayloadFields > 0) {
- current.AddChild(child)
- }
-
- return nil
-}
-
-// buildList adds the value's list items to the current XMLNode as children nodes. All
-// nested values in the list are converted to XMLNodes also.
-func (b *xmlBuilder) buildList(value reflect.Value, current *XMLNode, tag reflect.StructTag) error {
- if value.IsNil() { // don't build omitted lists
- return nil
- }
-
- // check for unflattened list member
- flattened := tag.Get("flattened") != ""
-
- xname := xml.Name{Local: tag.Get("locationName")}
- if flattened {
- for i := 0; i < value.Len(); i++ {
- child := NewXMLElement(xname)
- current.AddChild(child)
- if err := b.buildValue(value.Index(i), child, ""); err != nil {
- return err
- }
- }
- } else {
- list := NewXMLElement(xname)
- current.AddChild(list)
-
- for i := 0; i < value.Len(); i++ {
- iname := tag.Get("locationNameList")
- if iname == "" {
- iname = "member"
- }
-
- child := NewXMLElement(xml.Name{Local: iname})
- list.AddChild(child)
- if err := b.buildValue(value.Index(i), child, ""); err != nil {
- return err
- }
- }
- }
-
- return nil
-}
-
-// buildMap adds the value's key/value pairs to the current XMLNode as children nodes. All
-// nested values in the map are converted to XMLNodes also.
-//
-// Error will be returned if it is unable to build the map's values into XMLNodes
-func (b *xmlBuilder) buildMap(value reflect.Value, current *XMLNode, tag reflect.StructTag) error {
- if value.IsNil() { // don't build omitted maps
- return nil
- }
-
- maproot := NewXMLElement(xml.Name{Local: tag.Get("locationName")})
- current.AddChild(maproot)
- current = maproot
-
- kname, vname := "key", "value"
- if n := tag.Get("locationNameKey"); n != "" {
- kname = n
- }
- if n := tag.Get("locationNameValue"); n != "" {
- vname = n
- }
-
- // sorting is not required for compliance, but it makes testing easier
- keys := make([]string, value.Len())
- for i, k := range value.MapKeys() {
- keys[i] = k.String()
- }
- sort.Strings(keys)
-
- for _, k := range keys {
- v := value.MapIndex(reflect.ValueOf(k))
-
- mapcur := current
- if tag.Get("flattened") == "" { // add "entry" tag to non-flat maps
- child := NewXMLElement(xml.Name{Local: "entry"})
- mapcur.AddChild(child)
- mapcur = child
- }
-
- kchild := NewXMLElement(xml.Name{Local: kname})
- kchild.Text = k
- vchild := NewXMLElement(xml.Name{Local: vname})
- mapcur.AddChild(kchild)
- mapcur.AddChild(vchild)
-
- if err := b.buildValue(v, vchild, ""); err != nil {
- return err
- }
- }
-
- return nil
-}
-
-// buildScalar will convert the value into a string and append it as a attribute or child
-// of the current XMLNode.
-//
-// The value will be added as an attribute if tag contains a "xmlAttribute" attribute value.
-//
-// Error will be returned if the value type is unsupported.
-func (b *xmlBuilder) buildScalar(value reflect.Value, current *XMLNode, tag reflect.StructTag) error {
- var str string
- switch converted := value.Interface().(type) {
- case string:
- str = converted
- case []byte:
- if !value.IsNil() {
- str = base64.StdEncoding.EncodeToString(converted)
- }
- case bool:
- str = strconv.FormatBool(converted)
- case int64:
- str = strconv.FormatInt(converted, 10)
- case int:
- str = strconv.Itoa(converted)
- case float64:
- str = strconv.FormatFloat(converted, 'f', -1, 64)
- case float32:
- str = strconv.FormatFloat(float64(converted), 'f', -1, 32)
- case time.Time:
- format := tag.Get("timestampFormat")
- if len(format) == 0 {
- format = protocol.ISO8601TimeFormatName
- }
-
- str = protocol.FormatTime(format, converted)
- default:
- return fmt.Errorf("unsupported value for param %s: %v (%s)",
- tag.Get("locationName"), value.Interface(), value.Type().Name())
- }
-
- xname := xml.Name{Local: tag.Get("locationName")}
- if tag.Get("xmlAttribute") != "" { // put into current node's attribute list
- attr := xml.Attr{Name: xname, Value: str}
- current.Attr = append(current.Attr, attr)
- } else { // regular text node
- current.AddChild(&XMLNode{Name: xname, Text: str})
- }
- return nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/sort.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/sort.go
deleted file mode 100644
index c1a511851f6e..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/sort.go
+++ /dev/null
@@ -1,32 +0,0 @@
-package xmlutil
-
-import (
- "encoding/xml"
- "strings"
-)
-
-type xmlAttrSlice []xml.Attr
-
-func (x xmlAttrSlice) Len() int {
- return len(x)
-}
-
-func (x xmlAttrSlice) Less(i, j int) bool {
- spaceI, spaceJ := x[i].Name.Space, x[j].Name.Space
- localI, localJ := x[i].Name.Local, x[j].Name.Local
- valueI, valueJ := x[i].Value, x[j].Value
-
- spaceCmp := strings.Compare(spaceI, spaceJ)
- localCmp := strings.Compare(localI, localJ)
- valueCmp := strings.Compare(valueI, valueJ)
-
- if spaceCmp == -1 || (spaceCmp == 0 && (localCmp == -1 || (localCmp == 0 && valueCmp == -1))) {
- return true
- }
-
- return false
-}
-
-func (x xmlAttrSlice) Swap(i, j int) {
- x[i], x[j] = x[j], x[i]
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/unmarshal.go
deleted file mode 100644
index 107c053f8acf..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/unmarshal.go
+++ /dev/null
@@ -1,299 +0,0 @@
-package xmlutil
-
-import (
- "bytes"
- "encoding/base64"
- "encoding/xml"
- "fmt"
- "io"
- "reflect"
- "strconv"
- "strings"
- "time"
-
- "github.com/aws/aws-sdk-go/aws/awserr"
- "github.com/aws/aws-sdk-go/private/protocol"
-)
-
-// UnmarshalXMLError unmarshals the XML error from the stream into the value
-// type specified. The value must be a pointer. If the message fails to
-// unmarshal, the message content will be included in the returned error as a
-// awserr.UnmarshalError.
-func UnmarshalXMLError(v interface{}, stream io.Reader) error {
- var errBuf bytes.Buffer
- body := io.TeeReader(stream, &errBuf)
-
- err := xml.NewDecoder(body).Decode(v)
- if err != nil && err != io.EOF {
- return awserr.NewUnmarshalError(err,
- "failed to unmarshal error message", errBuf.Bytes())
- }
-
- return nil
-}
-
-// UnmarshalXML deserializes an xml.Decoder into the container v. V
-// needs to match the shape of the XML expected to be decoded.
-// If the shape doesn't match unmarshaling will fail.
-func UnmarshalXML(v interface{}, d *xml.Decoder, wrapper string) error {
- n, err := XMLToStruct(d, nil)
- if err != nil {
- return err
- }
- if n.Children != nil {
- for _, root := range n.Children {
- for _, c := range root {
- if wrappedChild, ok := c.Children[wrapper]; ok {
- c = wrappedChild[0] // pull out wrapped element
- }
-
- err = parse(reflect.ValueOf(v), c, "")
- if err != nil {
- if err == io.EOF {
- return nil
- }
- return err
- }
- }
- }
- return nil
- }
- return nil
-}
-
-// parse deserializes any value from the XMLNode. The type tag is used to infer the type, or reflect
-// will be used to determine the type from r.
-func parse(r reflect.Value, node *XMLNode, tag reflect.StructTag) error {
- xml := tag.Get("xml")
- if len(xml) != 0 {
- name := strings.SplitAfterN(xml, ",", 2)[0]
- if name == "-" {
- return nil
- }
- }
-
- rtype := r.Type()
- if rtype.Kind() == reflect.Ptr {
- rtype = rtype.Elem() // check kind of actual element type
- }
-
- t := tag.Get("type")
- if t == "" {
- switch rtype.Kind() {
- case reflect.Struct:
- // also it can't be a time object
- if _, ok := r.Interface().(*time.Time); !ok {
- t = "structure"
- }
- case reflect.Slice:
- // also it can't be a byte slice
- if _, ok := r.Interface().([]byte); !ok {
- t = "list"
- }
- case reflect.Map:
- t = "map"
- }
- }
-
- switch t {
- case "structure":
- if field, ok := rtype.FieldByName("_"); ok {
- tag = field.Tag
- }
- return parseStruct(r, node, tag)
- case "list":
- return parseList(r, node, tag)
- case "map":
- return parseMap(r, node, tag)
- default:
- return parseScalar(r, node, tag)
- }
-}
-
-// parseStruct deserializes a structure and its fields from an XMLNode. Any nested
-// types in the structure will also be deserialized.
-func parseStruct(r reflect.Value, node *XMLNode, tag reflect.StructTag) error {
- t := r.Type()
- if r.Kind() == reflect.Ptr {
- if r.IsNil() { // create the structure if it's nil
- s := reflect.New(r.Type().Elem())
- r.Set(s)
- r = s
- }
-
- r = r.Elem()
- t = t.Elem()
- }
-
- // unwrap any payloads
- if payload := tag.Get("payload"); payload != "" {
- field, _ := t.FieldByName(payload)
- return parseStruct(r.FieldByName(payload), node, field.Tag)
- }
-
- for i := 0; i < t.NumField(); i++ {
- field := t.Field(i)
- if c := field.Name[0:1]; strings.ToLower(c) == c {
- continue // ignore unexported fields
- }
-
- // figure out what this field is called
- name := field.Name
- if field.Tag.Get("flattened") != "" && field.Tag.Get("locationNameList") != "" {
- name = field.Tag.Get("locationNameList")
- } else if locName := field.Tag.Get("locationName"); locName != "" {
- name = locName
- }
-
- // try to find the field by name in elements
- elems := node.Children[name]
-
- if elems == nil { // try to find the field in attributes
- if val, ok := node.findElem(name); ok {
- elems = []*XMLNode{{Text: val}}
- }
- }
-
- member := r.FieldByName(field.Name)
- for _, elem := range elems {
- err := parse(member, elem, field.Tag)
- if err != nil {
- return err
- }
- }
- }
- return nil
-}
-
-// parseList deserializes a list of values from an XML node. Each list entry
-// will also be deserialized.
-func parseList(r reflect.Value, node *XMLNode, tag reflect.StructTag) error {
- t := r.Type()
-
- if tag.Get("flattened") == "" { // look at all item entries
- mname := "member"
- if name := tag.Get("locationNameList"); name != "" {
- mname = name
- }
-
- if Children, ok := node.Children[mname]; ok {
- if r.IsNil() {
- r.Set(reflect.MakeSlice(t, len(Children), len(Children)))
- }
-
- for i, c := range Children {
- err := parse(r.Index(i), c, "")
- if err != nil {
- return err
- }
- }
- }
- } else { // flattened list means this is a single element
- if r.IsNil() {
- r.Set(reflect.MakeSlice(t, 0, 0))
- }
-
- childR := reflect.Zero(t.Elem())
- r.Set(reflect.Append(r, childR))
- err := parse(r.Index(r.Len()-1), node, "")
- if err != nil {
- return err
- }
- }
-
- return nil
-}
-
-// parseMap deserializes a map from an XMLNode. The direct children of the XMLNode
-// will also be deserialized as map entries.
-func parseMap(r reflect.Value, node *XMLNode, tag reflect.StructTag) error {
- if r.IsNil() {
- r.Set(reflect.MakeMap(r.Type()))
- }
-
- if tag.Get("flattened") == "" { // look at all child entries
- for _, entry := range node.Children["entry"] {
- parseMapEntry(r, entry, tag)
- }
- } else { // this element is itself an entry
- parseMapEntry(r, node, tag)
- }
-
- return nil
-}
-
-// parseMapEntry deserializes a map entry from a XML node.
-func parseMapEntry(r reflect.Value, node *XMLNode, tag reflect.StructTag) error {
- kname, vname := "key", "value"
- if n := tag.Get("locationNameKey"); n != "" {
- kname = n
- }
- if n := tag.Get("locationNameValue"); n != "" {
- vname = n
- }
-
- keys, ok := node.Children[kname]
- values := node.Children[vname]
- if ok {
- for i, key := range keys {
- keyR := reflect.ValueOf(key.Text)
- value := values[i]
- valueR := reflect.New(r.Type().Elem()).Elem()
-
- parse(valueR, value, "")
- r.SetMapIndex(keyR, valueR)
- }
- }
- return nil
-}
-
-// parseScaller deserializes an XMLNode value into a concrete type based on the
-// interface type of r.
-//
-// Error is returned if the deserialization fails due to invalid type conversion,
-// or unsupported interface type.
-func parseScalar(r reflect.Value, node *XMLNode, tag reflect.StructTag) error {
- switch r.Interface().(type) {
- case *string:
- r.Set(reflect.ValueOf(&node.Text))
- return nil
- case []byte:
- b, err := base64.StdEncoding.DecodeString(node.Text)
- if err != nil {
- return err
- }
- r.Set(reflect.ValueOf(b))
- case *bool:
- v, err := strconv.ParseBool(node.Text)
- if err != nil {
- return err
- }
- r.Set(reflect.ValueOf(&v))
- case *int64:
- v, err := strconv.ParseInt(node.Text, 10, 64)
- if err != nil {
- return err
- }
- r.Set(reflect.ValueOf(&v))
- case *float64:
- v, err := strconv.ParseFloat(node.Text, 64)
- if err != nil {
- return err
- }
- r.Set(reflect.ValueOf(&v))
- case *time.Time:
- format := tag.Get("timestampFormat")
- if len(format) == 0 {
- format = protocol.ISO8601TimeFormatName
- }
-
- t, err := protocol.ParseTime(format, node.Text)
- if err != nil {
- return err
- }
- r.Set(reflect.ValueOf(&t))
- default:
- return fmt.Errorf("unsupported value: %v (%s)", r.Interface(), r.Type())
- }
- return nil
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/xml_to_struct.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/xml_to_struct.go
deleted file mode 100644
index 42f71648eee3..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/xml_to_struct.go
+++ /dev/null
@@ -1,159 +0,0 @@
-package xmlutil
-
-import (
- "encoding/xml"
- "fmt"
- "io"
- "sort"
-)
-
-// A XMLNode contains the values to be encoded or decoded.
-type XMLNode struct {
- Name xml.Name `json:",omitempty"`
- Children map[string][]*XMLNode `json:",omitempty"`
- Text string `json:",omitempty"`
- Attr []xml.Attr `json:",omitempty"`
-
- namespaces map[string]string
- parent *XMLNode
-}
-
-// NewXMLElement returns a pointer to a new XMLNode initialized to default values.
-func NewXMLElement(name xml.Name) *XMLNode {
- return &XMLNode{
- Name: name,
- Children: map[string][]*XMLNode{},
- Attr: []xml.Attr{},
- }
-}
-
-// AddChild adds child to the XMLNode.
-func (n *XMLNode) AddChild(child *XMLNode) {
- child.parent = n
- if _, ok := n.Children[child.Name.Local]; !ok {
- n.Children[child.Name.Local] = []*XMLNode{}
- }
- n.Children[child.Name.Local] = append(n.Children[child.Name.Local], child)
-}
-
-// XMLToStruct converts a xml.Decoder stream to XMLNode with nested values.
-func XMLToStruct(d *xml.Decoder, s *xml.StartElement) (*XMLNode, error) {
- out := &XMLNode{}
- for {
- tok, err := d.Token()
- if err != nil {
- if err == io.EOF {
- break
- } else {
- return out, err
- }
- }
-
- if tok == nil {
- break
- }
-
- switch typed := tok.(type) {
- case xml.CharData:
- out.Text = string(typed.Copy())
- case xml.StartElement:
- el := typed.Copy()
- out.Attr = el.Attr
- if out.Children == nil {
- out.Children = map[string][]*XMLNode{}
- }
-
- name := typed.Name.Local
- slice := out.Children[name]
- if slice == nil {
- slice = []*XMLNode{}
- }
- node, e := XMLToStruct(d, &el)
- out.findNamespaces()
- if e != nil {
- return out, e
- }
- node.Name = typed.Name
- node.findNamespaces()
- tempOut := *out
- // Save into a temp variable, simply because out gets squashed during
- // loop iterations
- node.parent = &tempOut
- slice = append(slice, node)
- out.Children[name] = slice
- case xml.EndElement:
- if s != nil && s.Name.Local == typed.Name.Local { // matching end token
- return out, nil
- }
- out = &XMLNode{}
- }
- }
- return out, nil
-}
-
-func (n *XMLNode) findNamespaces() {
- ns := map[string]string{}
- for _, a := range n.Attr {
- if a.Name.Space == "xmlns" {
- ns[a.Value] = a.Name.Local
- }
- }
-
- n.namespaces = ns
-}
-
-func (n *XMLNode) findElem(name string) (string, bool) {
- for node := n; node != nil; node = node.parent {
- for _, a := range node.Attr {
- namespace := a.Name.Space
- if v, ok := node.namespaces[namespace]; ok {
- namespace = v
- }
- if name == fmt.Sprintf("%s:%s", namespace, a.Name.Local) {
- return a.Value, true
- }
- }
- }
- return "", false
-}
-
-// StructToXML writes an XMLNode to a xml.Encoder as tokens.
-func StructToXML(e *xml.Encoder, node *XMLNode, sorted bool) error {
- // Sort Attributes
- attrs := node.Attr
- if sorted {
- sortedAttrs := make([]xml.Attr, len(attrs))
- for _, k := range node.Attr {
- sortedAttrs = append(sortedAttrs, k)
- }
- sort.Sort(xmlAttrSlice(sortedAttrs))
- attrs = sortedAttrs
- }
-
- e.EncodeToken(xml.StartElement{Name: node.Name, Attr: attrs})
-
- if node.Text != "" {
- e.EncodeToken(xml.CharData([]byte(node.Text)))
- } else if sorted {
- sortedNames := []string{}
- for k := range node.Children {
- sortedNames = append(sortedNames, k)
- }
- sort.Strings(sortedNames)
-
- for _, k := range sortedNames {
- for _, v := range node.Children[k] {
- StructToXML(e, v, sorted)
- }
- }
- } else {
- for _, c := range node.Children {
- for _, v := range c {
- StructToXML(e, v, sorted)
- }
- }
- }
-
- e.EncodeToken(xml.EndElement{Name: node.Name})
- return e.Flush()
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go b/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go
deleted file mode 100644
index 462b049cc3c5..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go
+++ /dev/null
@@ -1,9194 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-package ecr
-
-import (
- "fmt"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awsutil"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/private/protocol"
- "github.com/aws/aws-sdk-go/private/protocol/jsonrpc"
-)
-
-const opBatchCheckLayerAvailability = "BatchCheckLayerAvailability"
-
-// BatchCheckLayerAvailabilityRequest generates a "aws/request.Request" representing the
-// client's request for the BatchCheckLayerAvailability operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See BatchCheckLayerAvailability for more information on using the BatchCheckLayerAvailability
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the BatchCheckLayerAvailabilityRequest method.
-// req, resp := client.BatchCheckLayerAvailabilityRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/BatchCheckLayerAvailability
-func (c *ECR) BatchCheckLayerAvailabilityRequest(input *BatchCheckLayerAvailabilityInput) (req *request.Request, output *BatchCheckLayerAvailabilityOutput) {
- op := &request.Operation{
- Name: opBatchCheckLayerAvailability,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &BatchCheckLayerAvailabilityInput{}
- }
-
- output = &BatchCheckLayerAvailabilityOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// BatchCheckLayerAvailability API operation for Amazon EC2 Container Registry.
-//
-// Checks the availability of one or more image layers in a repository.
-//
-// When an image is pushed to a repository, each image layer is checked to verify
-// if it has been uploaded before. If it has been uploaded, then the image layer
-// is skipped.
-//
-// This operation is used by the Amazon ECR proxy and is not generally used
-// by customers for pulling and pushing images. In most cases, you should use
-// the docker CLI to pull, tag, and push images.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation BatchCheckLayerAvailability for usage and error information.
-//
-// Returned Error Types:
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/BatchCheckLayerAvailability
-func (c *ECR) BatchCheckLayerAvailability(input *BatchCheckLayerAvailabilityInput) (*BatchCheckLayerAvailabilityOutput, error) {
- req, out := c.BatchCheckLayerAvailabilityRequest(input)
- return out, req.Send()
-}
-
-// BatchCheckLayerAvailabilityWithContext is the same as BatchCheckLayerAvailability with the addition of
-// the ability to pass a context and additional request options.
-//
-// See BatchCheckLayerAvailability for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) BatchCheckLayerAvailabilityWithContext(ctx aws.Context, input *BatchCheckLayerAvailabilityInput, opts ...request.Option) (*BatchCheckLayerAvailabilityOutput, error) {
- req, out := c.BatchCheckLayerAvailabilityRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opBatchDeleteImage = "BatchDeleteImage"
-
-// BatchDeleteImageRequest generates a "aws/request.Request" representing the
-// client's request for the BatchDeleteImage operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See BatchDeleteImage for more information on using the BatchDeleteImage
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the BatchDeleteImageRequest method.
-// req, resp := client.BatchDeleteImageRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/BatchDeleteImage
-func (c *ECR) BatchDeleteImageRequest(input *BatchDeleteImageInput) (req *request.Request, output *BatchDeleteImageOutput) {
- op := &request.Operation{
- Name: opBatchDeleteImage,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &BatchDeleteImageInput{}
- }
-
- output = &BatchDeleteImageOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// BatchDeleteImage API operation for Amazon EC2 Container Registry.
-//
-// Deletes a list of specified images within a repository. Images are specified
-// with either an imageTag or imageDigest.
-//
-// You can remove a tag from an image by specifying the image's tag in your
-// request. When you remove the last tag from an image, the image is deleted
-// from your repository.
-//
-// You can completely delete an image (and all of its tags) by specifying the
-// image's digest in your request.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation BatchDeleteImage for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/BatchDeleteImage
-func (c *ECR) BatchDeleteImage(input *BatchDeleteImageInput) (*BatchDeleteImageOutput, error) {
- req, out := c.BatchDeleteImageRequest(input)
- return out, req.Send()
-}
-
-// BatchDeleteImageWithContext is the same as BatchDeleteImage with the addition of
-// the ability to pass a context and additional request options.
-//
-// See BatchDeleteImage for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) BatchDeleteImageWithContext(ctx aws.Context, input *BatchDeleteImageInput, opts ...request.Option) (*BatchDeleteImageOutput, error) {
- req, out := c.BatchDeleteImageRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opBatchGetImage = "BatchGetImage"
-
-// BatchGetImageRequest generates a "aws/request.Request" representing the
-// client's request for the BatchGetImage operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See BatchGetImage for more information on using the BatchGetImage
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the BatchGetImageRequest method.
-// req, resp := client.BatchGetImageRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/BatchGetImage
-func (c *ECR) BatchGetImageRequest(input *BatchGetImageInput) (req *request.Request, output *BatchGetImageOutput) {
- op := &request.Operation{
- Name: opBatchGetImage,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &BatchGetImageInput{}
- }
-
- output = &BatchGetImageOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// BatchGetImage API operation for Amazon EC2 Container Registry.
-//
-// Gets detailed information for an image. Images are specified with either
-// an imageTag or imageDigest.
-//
-// When an image is pulled, the BatchGetImage API is called once to retrieve
-// the image manifest.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation BatchGetImage for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/BatchGetImage
-func (c *ECR) BatchGetImage(input *BatchGetImageInput) (*BatchGetImageOutput, error) {
- req, out := c.BatchGetImageRequest(input)
- return out, req.Send()
-}
-
-// BatchGetImageWithContext is the same as BatchGetImage with the addition of
-// the ability to pass a context and additional request options.
-//
-// See BatchGetImage for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) BatchGetImageWithContext(ctx aws.Context, input *BatchGetImageInput, opts ...request.Option) (*BatchGetImageOutput, error) {
- req, out := c.BatchGetImageRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opCompleteLayerUpload = "CompleteLayerUpload"
-
-// CompleteLayerUploadRequest generates a "aws/request.Request" representing the
-// client's request for the CompleteLayerUpload operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See CompleteLayerUpload for more information on using the CompleteLayerUpload
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the CompleteLayerUploadRequest method.
-// req, resp := client.CompleteLayerUploadRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/CompleteLayerUpload
-func (c *ECR) CompleteLayerUploadRequest(input *CompleteLayerUploadInput) (req *request.Request, output *CompleteLayerUploadOutput) {
- op := &request.Operation{
- Name: opCompleteLayerUpload,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &CompleteLayerUploadInput{}
- }
-
- output = &CompleteLayerUploadOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// CompleteLayerUpload API operation for Amazon EC2 Container Registry.
-//
-// Informs Amazon ECR that the image layer upload has completed for a specified
-// registry, repository name, and upload ID. You can optionally provide a sha256
-// digest of the image layer for data validation purposes.
-//
-// When an image is pushed, the CompleteLayerUpload API is called once per each
-// new image layer to verify that the upload has completed.
-//
-// This operation is used by the Amazon ECR proxy and is not generally used
-// by customers for pulling and pushing images. In most cases, you should use
-// the docker CLI to pull, tag, and push images.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation CompleteLayerUpload for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * UploadNotFoundException
-// The upload could not be found, or the specified upload ID is not valid for
-// this repository.
-//
-// * InvalidLayerException
-// The layer digest calculation performed by Amazon ECR upon receipt of the
-// image layer does not match the digest specified.
-//
-// * LayerPartTooSmallException
-// Layer parts must be at least 5 MiB in size.
-//
-// * LayerAlreadyExistsException
-// The image layer already exists in the associated repository.
-//
-// * EmptyUploadException
-// The specified layer upload does not contain any layer parts.
-//
-// * KmsException
-// The operation failed due to a KMS exception.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/CompleteLayerUpload
-func (c *ECR) CompleteLayerUpload(input *CompleteLayerUploadInput) (*CompleteLayerUploadOutput, error) {
- req, out := c.CompleteLayerUploadRequest(input)
- return out, req.Send()
-}
-
-// CompleteLayerUploadWithContext is the same as CompleteLayerUpload with the addition of
-// the ability to pass a context and additional request options.
-//
-// See CompleteLayerUpload for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) CompleteLayerUploadWithContext(ctx aws.Context, input *CompleteLayerUploadInput, opts ...request.Option) (*CompleteLayerUploadOutput, error) {
- req, out := c.CompleteLayerUploadRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opCreateRepository = "CreateRepository"
-
-// CreateRepositoryRequest generates a "aws/request.Request" representing the
-// client's request for the CreateRepository operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See CreateRepository for more information on using the CreateRepository
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the CreateRepositoryRequest method.
-// req, resp := client.CreateRepositoryRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/CreateRepository
-func (c *ECR) CreateRepositoryRequest(input *CreateRepositoryInput) (req *request.Request, output *CreateRepositoryOutput) {
- op := &request.Operation{
- Name: opCreateRepository,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &CreateRepositoryInput{}
- }
-
- output = &CreateRepositoryOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// CreateRepository API operation for Amazon EC2 Container Registry.
-//
-// Creates a repository. For more information, see Amazon ECR Repositories (https://docs.aws.amazon.com/AmazonECR/latest/userguide/Repositories.html)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation CreateRepository for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * InvalidTagParameterException
-// An invalid parameter has been specified. Tag keys can have a maximum character
-// length of 128 characters, and tag values can have a maximum length of 256
-// characters.
-//
-// * TooManyTagsException
-// The list of tags on the repository is over the limit. The maximum number
-// of tags that can be applied to a repository is 50.
-//
-// * RepositoryAlreadyExistsException
-// The specified repository already exists in the specified registry.
-//
-// * LimitExceededException
-// The operation did not succeed because it would have exceeded a service limit
-// for your account. For more information, see Amazon ECR Service Quotas (https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// * KmsException
-// The operation failed due to a KMS exception.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/CreateRepository
-func (c *ECR) CreateRepository(input *CreateRepositoryInput) (*CreateRepositoryOutput, error) {
- req, out := c.CreateRepositoryRequest(input)
- return out, req.Send()
-}
-
-// CreateRepositoryWithContext is the same as CreateRepository with the addition of
-// the ability to pass a context and additional request options.
-//
-// See CreateRepository for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) CreateRepositoryWithContext(ctx aws.Context, input *CreateRepositoryInput, opts ...request.Option) (*CreateRepositoryOutput, error) {
- req, out := c.CreateRepositoryRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opDeleteLifecyclePolicy = "DeleteLifecyclePolicy"
-
-// DeleteLifecyclePolicyRequest generates a "aws/request.Request" representing the
-// client's request for the DeleteLifecyclePolicy operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See DeleteLifecyclePolicy for more information on using the DeleteLifecyclePolicy
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the DeleteLifecyclePolicyRequest method.
-// req, resp := client.DeleteLifecyclePolicyRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DeleteLifecyclePolicy
-func (c *ECR) DeleteLifecyclePolicyRequest(input *DeleteLifecyclePolicyInput) (req *request.Request, output *DeleteLifecyclePolicyOutput) {
- op := &request.Operation{
- Name: opDeleteLifecyclePolicy,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &DeleteLifecyclePolicyInput{}
- }
-
- output = &DeleteLifecyclePolicyOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// DeleteLifecyclePolicy API operation for Amazon EC2 Container Registry.
-//
-// Deletes the lifecycle policy associated with the specified repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation DeleteLifecyclePolicy for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * LifecyclePolicyNotFoundException
-// The lifecycle policy could not be found, and no policy is set to the repository.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DeleteLifecyclePolicy
-func (c *ECR) DeleteLifecyclePolicy(input *DeleteLifecyclePolicyInput) (*DeleteLifecyclePolicyOutput, error) {
- req, out := c.DeleteLifecyclePolicyRequest(input)
- return out, req.Send()
-}
-
-// DeleteLifecyclePolicyWithContext is the same as DeleteLifecyclePolicy with the addition of
-// the ability to pass a context and additional request options.
-//
-// See DeleteLifecyclePolicy for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DeleteLifecyclePolicyWithContext(ctx aws.Context, input *DeleteLifecyclePolicyInput, opts ...request.Option) (*DeleteLifecyclePolicyOutput, error) {
- req, out := c.DeleteLifecyclePolicyRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opDeleteRepository = "DeleteRepository"
-
-// DeleteRepositoryRequest generates a "aws/request.Request" representing the
-// client's request for the DeleteRepository operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See DeleteRepository for more information on using the DeleteRepository
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the DeleteRepositoryRequest method.
-// req, resp := client.DeleteRepositoryRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DeleteRepository
-func (c *ECR) DeleteRepositoryRequest(input *DeleteRepositoryInput) (req *request.Request, output *DeleteRepositoryOutput) {
- op := &request.Operation{
- Name: opDeleteRepository,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &DeleteRepositoryInput{}
- }
-
- output = &DeleteRepositoryOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// DeleteRepository API operation for Amazon EC2 Container Registry.
-//
-// Deletes a repository. If the repository contains images, you must either
-// delete all images in the repository or use the force option to delete the
-// repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation DeleteRepository for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * RepositoryNotEmptyException
-// The specified repository contains images. To delete a repository that contains
-// images, you must force the deletion with the force parameter.
-//
-// * KmsException
-// The operation failed due to a KMS exception.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DeleteRepository
-func (c *ECR) DeleteRepository(input *DeleteRepositoryInput) (*DeleteRepositoryOutput, error) {
- req, out := c.DeleteRepositoryRequest(input)
- return out, req.Send()
-}
-
-// DeleteRepositoryWithContext is the same as DeleteRepository with the addition of
-// the ability to pass a context and additional request options.
-//
-// See DeleteRepository for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DeleteRepositoryWithContext(ctx aws.Context, input *DeleteRepositoryInput, opts ...request.Option) (*DeleteRepositoryOutput, error) {
- req, out := c.DeleteRepositoryRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opDeleteRepositoryPolicy = "DeleteRepositoryPolicy"
-
-// DeleteRepositoryPolicyRequest generates a "aws/request.Request" representing the
-// client's request for the DeleteRepositoryPolicy operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See DeleteRepositoryPolicy for more information on using the DeleteRepositoryPolicy
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the DeleteRepositoryPolicyRequest method.
-// req, resp := client.DeleteRepositoryPolicyRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DeleteRepositoryPolicy
-func (c *ECR) DeleteRepositoryPolicyRequest(input *DeleteRepositoryPolicyInput) (req *request.Request, output *DeleteRepositoryPolicyOutput) {
- op := &request.Operation{
- Name: opDeleteRepositoryPolicy,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &DeleteRepositoryPolicyInput{}
- }
-
- output = &DeleteRepositoryPolicyOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// DeleteRepositoryPolicy API operation for Amazon EC2 Container Registry.
-//
-// Deletes the repository policy associated with the specified repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation DeleteRepositoryPolicy for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * RepositoryPolicyNotFoundException
-// The specified repository and registry combination does not have an associated
-// repository policy.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DeleteRepositoryPolicy
-func (c *ECR) DeleteRepositoryPolicy(input *DeleteRepositoryPolicyInput) (*DeleteRepositoryPolicyOutput, error) {
- req, out := c.DeleteRepositoryPolicyRequest(input)
- return out, req.Send()
-}
-
-// DeleteRepositoryPolicyWithContext is the same as DeleteRepositoryPolicy with the addition of
-// the ability to pass a context and additional request options.
-//
-// See DeleteRepositoryPolicy for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DeleteRepositoryPolicyWithContext(ctx aws.Context, input *DeleteRepositoryPolicyInput, opts ...request.Option) (*DeleteRepositoryPolicyOutput, error) {
- req, out := c.DeleteRepositoryPolicyRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opDescribeImageScanFindings = "DescribeImageScanFindings"
-
-// DescribeImageScanFindingsRequest generates a "aws/request.Request" representing the
-// client's request for the DescribeImageScanFindings operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See DescribeImageScanFindings for more information on using the DescribeImageScanFindings
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the DescribeImageScanFindingsRequest method.
-// req, resp := client.DescribeImageScanFindingsRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DescribeImageScanFindings
-func (c *ECR) DescribeImageScanFindingsRequest(input *DescribeImageScanFindingsInput) (req *request.Request, output *DescribeImageScanFindingsOutput) {
- op := &request.Operation{
- Name: opDescribeImageScanFindings,
- HTTPMethod: "POST",
- HTTPPath: "/",
- Paginator: &request.Paginator{
- InputTokens: []string{"nextToken"},
- OutputTokens: []string{"nextToken"},
- LimitToken: "maxResults",
- TruncationToken: "",
- },
- }
-
- if input == nil {
- input = &DescribeImageScanFindingsInput{}
- }
-
- output = &DescribeImageScanFindingsOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// DescribeImageScanFindings API operation for Amazon EC2 Container Registry.
-//
-// Returns the scan findings for the specified image.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation DescribeImageScanFindings for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * ImageNotFoundException
-// The image requested does not exist in the specified repository.
-//
-// * ScanNotFoundException
-// The specified image scan could not be found. Ensure that image scanning is
-// enabled on the repository and try again.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DescribeImageScanFindings
-func (c *ECR) DescribeImageScanFindings(input *DescribeImageScanFindingsInput) (*DescribeImageScanFindingsOutput, error) {
- req, out := c.DescribeImageScanFindingsRequest(input)
- return out, req.Send()
-}
-
-// DescribeImageScanFindingsWithContext is the same as DescribeImageScanFindings with the addition of
-// the ability to pass a context and additional request options.
-//
-// See DescribeImageScanFindings for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DescribeImageScanFindingsWithContext(ctx aws.Context, input *DescribeImageScanFindingsInput, opts ...request.Option) (*DescribeImageScanFindingsOutput, error) {
- req, out := c.DescribeImageScanFindingsRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-// DescribeImageScanFindingsPages iterates over the pages of a DescribeImageScanFindings operation,
-// calling the "fn" function with the response data for each page. To stop
-// iterating, return false from the fn function.
-//
-// See DescribeImageScanFindings method for more information on how to use this operation.
-//
-// Note: This operation can generate multiple requests to a service.
-//
-// // Example iterating over at most 3 pages of a DescribeImageScanFindings operation.
-// pageNum := 0
-// err := client.DescribeImageScanFindingsPages(params,
-// func(page *ecr.DescribeImageScanFindingsOutput, lastPage bool) bool {
-// pageNum++
-// fmt.Println(page)
-// return pageNum <= 3
-// })
-//
-func (c *ECR) DescribeImageScanFindingsPages(input *DescribeImageScanFindingsInput, fn func(*DescribeImageScanFindingsOutput, bool) bool) error {
- return c.DescribeImageScanFindingsPagesWithContext(aws.BackgroundContext(), input, fn)
-}
-
-// DescribeImageScanFindingsPagesWithContext same as DescribeImageScanFindingsPages except
-// it takes a Context and allows setting request options on the pages.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DescribeImageScanFindingsPagesWithContext(ctx aws.Context, input *DescribeImageScanFindingsInput, fn func(*DescribeImageScanFindingsOutput, bool) bool, opts ...request.Option) error {
- p := request.Pagination{
- NewRequest: func() (*request.Request, error) {
- var inCpy *DescribeImageScanFindingsInput
- if input != nil {
- tmp := *input
- inCpy = &tmp
- }
- req, _ := c.DescribeImageScanFindingsRequest(inCpy)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return req, nil
- },
- }
-
- for p.Next() {
- if !fn(p.Page().(*DescribeImageScanFindingsOutput), !p.HasNextPage()) {
- break
- }
- }
-
- return p.Err()
-}
-
-const opDescribeImages = "DescribeImages"
-
-// DescribeImagesRequest generates a "aws/request.Request" representing the
-// client's request for the DescribeImages operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See DescribeImages for more information on using the DescribeImages
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the DescribeImagesRequest method.
-// req, resp := client.DescribeImagesRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DescribeImages
-func (c *ECR) DescribeImagesRequest(input *DescribeImagesInput) (req *request.Request, output *DescribeImagesOutput) {
- op := &request.Operation{
- Name: opDescribeImages,
- HTTPMethod: "POST",
- HTTPPath: "/",
- Paginator: &request.Paginator{
- InputTokens: []string{"nextToken"},
- OutputTokens: []string{"nextToken"},
- LimitToken: "maxResults",
- TruncationToken: "",
- },
- }
-
- if input == nil {
- input = &DescribeImagesInput{}
- }
-
- output = &DescribeImagesOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// DescribeImages API operation for Amazon EC2 Container Registry.
-//
-// Returns metadata about the images in a repository.
-//
-// Beginning with Docker version 1.9, the Docker client compresses image layers
-// before pushing them to a V2 Docker registry. The output of the docker images
-// command shows the uncompressed image size, so it may return a larger image
-// size than the image sizes returned by DescribeImages.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation DescribeImages for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * ImageNotFoundException
-// The image requested does not exist in the specified repository.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DescribeImages
-func (c *ECR) DescribeImages(input *DescribeImagesInput) (*DescribeImagesOutput, error) {
- req, out := c.DescribeImagesRequest(input)
- return out, req.Send()
-}
-
-// DescribeImagesWithContext is the same as DescribeImages with the addition of
-// the ability to pass a context and additional request options.
-//
-// See DescribeImages for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DescribeImagesWithContext(ctx aws.Context, input *DescribeImagesInput, opts ...request.Option) (*DescribeImagesOutput, error) {
- req, out := c.DescribeImagesRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-// DescribeImagesPages iterates over the pages of a DescribeImages operation,
-// calling the "fn" function with the response data for each page. To stop
-// iterating, return false from the fn function.
-//
-// See DescribeImages method for more information on how to use this operation.
-//
-// Note: This operation can generate multiple requests to a service.
-//
-// // Example iterating over at most 3 pages of a DescribeImages operation.
-// pageNum := 0
-// err := client.DescribeImagesPages(params,
-// func(page *ecr.DescribeImagesOutput, lastPage bool) bool {
-// pageNum++
-// fmt.Println(page)
-// return pageNum <= 3
-// })
-//
-func (c *ECR) DescribeImagesPages(input *DescribeImagesInput, fn func(*DescribeImagesOutput, bool) bool) error {
- return c.DescribeImagesPagesWithContext(aws.BackgroundContext(), input, fn)
-}
-
-// DescribeImagesPagesWithContext same as DescribeImagesPages except
-// it takes a Context and allows setting request options on the pages.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DescribeImagesPagesWithContext(ctx aws.Context, input *DescribeImagesInput, fn func(*DescribeImagesOutput, bool) bool, opts ...request.Option) error {
- p := request.Pagination{
- NewRequest: func() (*request.Request, error) {
- var inCpy *DescribeImagesInput
- if input != nil {
- tmp := *input
- inCpy = &tmp
- }
- req, _ := c.DescribeImagesRequest(inCpy)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return req, nil
- },
- }
-
- for p.Next() {
- if !fn(p.Page().(*DescribeImagesOutput), !p.HasNextPage()) {
- break
- }
- }
-
- return p.Err()
-}
-
-const opDescribeRepositories = "DescribeRepositories"
-
-// DescribeRepositoriesRequest generates a "aws/request.Request" representing the
-// client's request for the DescribeRepositories operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See DescribeRepositories for more information on using the DescribeRepositories
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the DescribeRepositoriesRequest method.
-// req, resp := client.DescribeRepositoriesRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DescribeRepositories
-func (c *ECR) DescribeRepositoriesRequest(input *DescribeRepositoriesInput) (req *request.Request, output *DescribeRepositoriesOutput) {
- op := &request.Operation{
- Name: opDescribeRepositories,
- HTTPMethod: "POST",
- HTTPPath: "/",
- Paginator: &request.Paginator{
- InputTokens: []string{"nextToken"},
- OutputTokens: []string{"nextToken"},
- LimitToken: "maxResults",
- TruncationToken: "",
- },
- }
-
- if input == nil {
- input = &DescribeRepositoriesInput{}
- }
-
- output = &DescribeRepositoriesOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// DescribeRepositories API operation for Amazon EC2 Container Registry.
-//
-// Describes image repositories in a registry.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation DescribeRepositories for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DescribeRepositories
-func (c *ECR) DescribeRepositories(input *DescribeRepositoriesInput) (*DescribeRepositoriesOutput, error) {
- req, out := c.DescribeRepositoriesRequest(input)
- return out, req.Send()
-}
-
-// DescribeRepositoriesWithContext is the same as DescribeRepositories with the addition of
-// the ability to pass a context and additional request options.
-//
-// See DescribeRepositories for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DescribeRepositoriesWithContext(ctx aws.Context, input *DescribeRepositoriesInput, opts ...request.Option) (*DescribeRepositoriesOutput, error) {
- req, out := c.DescribeRepositoriesRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-// DescribeRepositoriesPages iterates over the pages of a DescribeRepositories operation,
-// calling the "fn" function with the response data for each page. To stop
-// iterating, return false from the fn function.
-//
-// See DescribeRepositories method for more information on how to use this operation.
-//
-// Note: This operation can generate multiple requests to a service.
-//
-// // Example iterating over at most 3 pages of a DescribeRepositories operation.
-// pageNum := 0
-// err := client.DescribeRepositoriesPages(params,
-// func(page *ecr.DescribeRepositoriesOutput, lastPage bool) bool {
-// pageNum++
-// fmt.Println(page)
-// return pageNum <= 3
-// })
-//
-func (c *ECR) DescribeRepositoriesPages(input *DescribeRepositoriesInput, fn func(*DescribeRepositoriesOutput, bool) bool) error {
- return c.DescribeRepositoriesPagesWithContext(aws.BackgroundContext(), input, fn)
-}
-
-// DescribeRepositoriesPagesWithContext same as DescribeRepositoriesPages except
-// it takes a Context and allows setting request options on the pages.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) DescribeRepositoriesPagesWithContext(ctx aws.Context, input *DescribeRepositoriesInput, fn func(*DescribeRepositoriesOutput, bool) bool, opts ...request.Option) error {
- p := request.Pagination{
- NewRequest: func() (*request.Request, error) {
- var inCpy *DescribeRepositoriesInput
- if input != nil {
- tmp := *input
- inCpy = &tmp
- }
- req, _ := c.DescribeRepositoriesRequest(inCpy)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return req, nil
- },
- }
-
- for p.Next() {
- if !fn(p.Page().(*DescribeRepositoriesOutput), !p.HasNextPage()) {
- break
- }
- }
-
- return p.Err()
-}
-
-const opGetAuthorizationToken = "GetAuthorizationToken"
-
-// GetAuthorizationTokenRequest generates a "aws/request.Request" representing the
-// client's request for the GetAuthorizationToken operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetAuthorizationToken for more information on using the GetAuthorizationToken
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetAuthorizationTokenRequest method.
-// req, resp := client.GetAuthorizationTokenRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetAuthorizationToken
-func (c *ECR) GetAuthorizationTokenRequest(input *GetAuthorizationTokenInput) (req *request.Request, output *GetAuthorizationTokenOutput) {
- op := &request.Operation{
- Name: opGetAuthorizationToken,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &GetAuthorizationTokenInput{}
- }
-
- output = &GetAuthorizationTokenOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetAuthorizationToken API operation for Amazon EC2 Container Registry.
-//
-// Retrieves an authorization token. An authorization token represents your
-// IAM authentication credentials and can be used to access any Amazon ECR registry
-// that your IAM principal has access to. The authorization token is valid for
-// 12 hours.
-//
-// The authorizationToken returned is a base64 encoded string that can be decoded
-// and used in a docker login command to authenticate to a registry. The AWS
-// CLI offers an get-login-password command that simplifies the login process.
-// For more information, see Registry Authentication (https://docs.aws.amazon.com/AmazonECR/latest/userguide/Registries.html#registry_auth)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation GetAuthorizationToken for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetAuthorizationToken
-func (c *ECR) GetAuthorizationToken(input *GetAuthorizationTokenInput) (*GetAuthorizationTokenOutput, error) {
- req, out := c.GetAuthorizationTokenRequest(input)
- return out, req.Send()
-}
-
-// GetAuthorizationTokenWithContext is the same as GetAuthorizationToken with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetAuthorizationToken for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) GetAuthorizationTokenWithContext(ctx aws.Context, input *GetAuthorizationTokenInput, opts ...request.Option) (*GetAuthorizationTokenOutput, error) {
- req, out := c.GetAuthorizationTokenRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opGetDownloadUrlForLayer = "GetDownloadUrlForLayer"
-
-// GetDownloadUrlForLayerRequest generates a "aws/request.Request" representing the
-// client's request for the GetDownloadUrlForLayer operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetDownloadUrlForLayer for more information on using the GetDownloadUrlForLayer
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetDownloadUrlForLayerRequest method.
-// req, resp := client.GetDownloadUrlForLayerRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetDownloadUrlForLayer
-func (c *ECR) GetDownloadUrlForLayerRequest(input *GetDownloadUrlForLayerInput) (req *request.Request, output *GetDownloadUrlForLayerOutput) {
- op := &request.Operation{
- Name: opGetDownloadUrlForLayer,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &GetDownloadUrlForLayerInput{}
- }
-
- output = &GetDownloadUrlForLayerOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetDownloadUrlForLayer API operation for Amazon EC2 Container Registry.
-//
-// Retrieves the pre-signed Amazon S3 download URL corresponding to an image
-// layer. You can only get URLs for image layers that are referenced in an image.
-//
-// When an image is pulled, the GetDownloadUrlForLayer API is called once per
-// image layer that is not already cached.
-//
-// This operation is used by the Amazon ECR proxy and is not generally used
-// by customers for pulling and pushing images. In most cases, you should use
-// the docker CLI to pull, tag, and push images.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation GetDownloadUrlForLayer for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * LayersNotFoundException
-// The specified layers could not be found, or the specified layer is not valid
-// for this repository.
-//
-// * LayerInaccessibleException
-// The specified layer is not available because it is not associated with an
-// image. Unassociated image layers may be cleaned up at any time.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetDownloadUrlForLayer
-func (c *ECR) GetDownloadUrlForLayer(input *GetDownloadUrlForLayerInput) (*GetDownloadUrlForLayerOutput, error) {
- req, out := c.GetDownloadUrlForLayerRequest(input)
- return out, req.Send()
-}
-
-// GetDownloadUrlForLayerWithContext is the same as GetDownloadUrlForLayer with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetDownloadUrlForLayer for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) GetDownloadUrlForLayerWithContext(ctx aws.Context, input *GetDownloadUrlForLayerInput, opts ...request.Option) (*GetDownloadUrlForLayerOutput, error) {
- req, out := c.GetDownloadUrlForLayerRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opGetLifecyclePolicy = "GetLifecyclePolicy"
-
-// GetLifecyclePolicyRequest generates a "aws/request.Request" representing the
-// client's request for the GetLifecyclePolicy operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetLifecyclePolicy for more information on using the GetLifecyclePolicy
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetLifecyclePolicyRequest method.
-// req, resp := client.GetLifecyclePolicyRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetLifecyclePolicy
-func (c *ECR) GetLifecyclePolicyRequest(input *GetLifecyclePolicyInput) (req *request.Request, output *GetLifecyclePolicyOutput) {
- op := &request.Operation{
- Name: opGetLifecyclePolicy,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &GetLifecyclePolicyInput{}
- }
-
- output = &GetLifecyclePolicyOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetLifecyclePolicy API operation for Amazon EC2 Container Registry.
-//
-// Retrieves the lifecycle policy for the specified repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation GetLifecyclePolicy for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * LifecyclePolicyNotFoundException
-// The lifecycle policy could not be found, and no policy is set to the repository.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetLifecyclePolicy
-func (c *ECR) GetLifecyclePolicy(input *GetLifecyclePolicyInput) (*GetLifecyclePolicyOutput, error) {
- req, out := c.GetLifecyclePolicyRequest(input)
- return out, req.Send()
-}
-
-// GetLifecyclePolicyWithContext is the same as GetLifecyclePolicy with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetLifecyclePolicy for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) GetLifecyclePolicyWithContext(ctx aws.Context, input *GetLifecyclePolicyInput, opts ...request.Option) (*GetLifecyclePolicyOutput, error) {
- req, out := c.GetLifecyclePolicyRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opGetLifecyclePolicyPreview = "GetLifecyclePolicyPreview"
-
-// GetLifecyclePolicyPreviewRequest generates a "aws/request.Request" representing the
-// client's request for the GetLifecyclePolicyPreview operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetLifecyclePolicyPreview for more information on using the GetLifecyclePolicyPreview
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetLifecyclePolicyPreviewRequest method.
-// req, resp := client.GetLifecyclePolicyPreviewRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetLifecyclePolicyPreview
-func (c *ECR) GetLifecyclePolicyPreviewRequest(input *GetLifecyclePolicyPreviewInput) (req *request.Request, output *GetLifecyclePolicyPreviewOutput) {
- op := &request.Operation{
- Name: opGetLifecyclePolicyPreview,
- HTTPMethod: "POST",
- HTTPPath: "/",
- Paginator: &request.Paginator{
- InputTokens: []string{"nextToken"},
- OutputTokens: []string{"nextToken"},
- LimitToken: "maxResults",
- TruncationToken: "",
- },
- }
-
- if input == nil {
- input = &GetLifecyclePolicyPreviewInput{}
- }
-
- output = &GetLifecyclePolicyPreviewOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetLifecyclePolicyPreview API operation for Amazon EC2 Container Registry.
-//
-// Retrieves the results of the lifecycle policy preview request for the specified
-// repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation GetLifecyclePolicyPreview for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * LifecyclePolicyPreviewNotFoundException
-// There is no dry run for this repository.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetLifecyclePolicyPreview
-func (c *ECR) GetLifecyclePolicyPreview(input *GetLifecyclePolicyPreviewInput) (*GetLifecyclePolicyPreviewOutput, error) {
- req, out := c.GetLifecyclePolicyPreviewRequest(input)
- return out, req.Send()
-}
-
-// GetLifecyclePolicyPreviewWithContext is the same as GetLifecyclePolicyPreview with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetLifecyclePolicyPreview for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) GetLifecyclePolicyPreviewWithContext(ctx aws.Context, input *GetLifecyclePolicyPreviewInput, opts ...request.Option) (*GetLifecyclePolicyPreviewOutput, error) {
- req, out := c.GetLifecyclePolicyPreviewRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-// GetLifecyclePolicyPreviewPages iterates over the pages of a GetLifecyclePolicyPreview operation,
-// calling the "fn" function with the response data for each page. To stop
-// iterating, return false from the fn function.
-//
-// See GetLifecyclePolicyPreview method for more information on how to use this operation.
-//
-// Note: This operation can generate multiple requests to a service.
-//
-// // Example iterating over at most 3 pages of a GetLifecyclePolicyPreview operation.
-// pageNum := 0
-// err := client.GetLifecyclePolicyPreviewPages(params,
-// func(page *ecr.GetLifecyclePolicyPreviewOutput, lastPage bool) bool {
-// pageNum++
-// fmt.Println(page)
-// return pageNum <= 3
-// })
-//
-func (c *ECR) GetLifecyclePolicyPreviewPages(input *GetLifecyclePolicyPreviewInput, fn func(*GetLifecyclePolicyPreviewOutput, bool) bool) error {
- return c.GetLifecyclePolicyPreviewPagesWithContext(aws.BackgroundContext(), input, fn)
-}
-
-// GetLifecyclePolicyPreviewPagesWithContext same as GetLifecyclePolicyPreviewPages except
-// it takes a Context and allows setting request options on the pages.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) GetLifecyclePolicyPreviewPagesWithContext(ctx aws.Context, input *GetLifecyclePolicyPreviewInput, fn func(*GetLifecyclePolicyPreviewOutput, bool) bool, opts ...request.Option) error {
- p := request.Pagination{
- NewRequest: func() (*request.Request, error) {
- var inCpy *GetLifecyclePolicyPreviewInput
- if input != nil {
- tmp := *input
- inCpy = &tmp
- }
- req, _ := c.GetLifecyclePolicyPreviewRequest(inCpy)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return req, nil
- },
- }
-
- for p.Next() {
- if !fn(p.Page().(*GetLifecyclePolicyPreviewOutput), !p.HasNextPage()) {
- break
- }
- }
-
- return p.Err()
-}
-
-const opGetRepositoryPolicy = "GetRepositoryPolicy"
-
-// GetRepositoryPolicyRequest generates a "aws/request.Request" representing the
-// client's request for the GetRepositoryPolicy operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetRepositoryPolicy for more information on using the GetRepositoryPolicy
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetRepositoryPolicyRequest method.
-// req, resp := client.GetRepositoryPolicyRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetRepositoryPolicy
-func (c *ECR) GetRepositoryPolicyRequest(input *GetRepositoryPolicyInput) (req *request.Request, output *GetRepositoryPolicyOutput) {
- op := &request.Operation{
- Name: opGetRepositoryPolicy,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &GetRepositoryPolicyInput{}
- }
-
- output = &GetRepositoryPolicyOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetRepositoryPolicy API operation for Amazon EC2 Container Registry.
-//
-// Retrieves the repository policy for the specified repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation GetRepositoryPolicy for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * RepositoryPolicyNotFoundException
-// The specified repository and registry combination does not have an associated
-// repository policy.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/GetRepositoryPolicy
-func (c *ECR) GetRepositoryPolicy(input *GetRepositoryPolicyInput) (*GetRepositoryPolicyOutput, error) {
- req, out := c.GetRepositoryPolicyRequest(input)
- return out, req.Send()
-}
-
-// GetRepositoryPolicyWithContext is the same as GetRepositoryPolicy with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetRepositoryPolicy for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) GetRepositoryPolicyWithContext(ctx aws.Context, input *GetRepositoryPolicyInput, opts ...request.Option) (*GetRepositoryPolicyOutput, error) {
- req, out := c.GetRepositoryPolicyRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opInitiateLayerUpload = "InitiateLayerUpload"
-
-// InitiateLayerUploadRequest generates a "aws/request.Request" representing the
-// client's request for the InitiateLayerUpload operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See InitiateLayerUpload for more information on using the InitiateLayerUpload
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the InitiateLayerUploadRequest method.
-// req, resp := client.InitiateLayerUploadRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/InitiateLayerUpload
-func (c *ECR) InitiateLayerUploadRequest(input *InitiateLayerUploadInput) (req *request.Request, output *InitiateLayerUploadOutput) {
- op := &request.Operation{
- Name: opInitiateLayerUpload,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &InitiateLayerUploadInput{}
- }
-
- output = &InitiateLayerUploadOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// InitiateLayerUpload API operation for Amazon EC2 Container Registry.
-//
-// Notifies Amazon ECR that you intend to upload an image layer.
-//
-// When an image is pushed, the InitiateLayerUpload API is called once per image
-// layer that has not already been uploaded. Whether or not an image layer has
-// been uploaded is determined by the BatchCheckLayerAvailability API action.
-//
-// This operation is used by the Amazon ECR proxy and is not generally used
-// by customers for pulling and pushing images. In most cases, you should use
-// the docker CLI to pull, tag, and push images.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation InitiateLayerUpload for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * KmsException
-// The operation failed due to a KMS exception.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/InitiateLayerUpload
-func (c *ECR) InitiateLayerUpload(input *InitiateLayerUploadInput) (*InitiateLayerUploadOutput, error) {
- req, out := c.InitiateLayerUploadRequest(input)
- return out, req.Send()
-}
-
-// InitiateLayerUploadWithContext is the same as InitiateLayerUpload with the addition of
-// the ability to pass a context and additional request options.
-//
-// See InitiateLayerUpload for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) InitiateLayerUploadWithContext(ctx aws.Context, input *InitiateLayerUploadInput, opts ...request.Option) (*InitiateLayerUploadOutput, error) {
- req, out := c.InitiateLayerUploadRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opListImages = "ListImages"
-
-// ListImagesRequest generates a "aws/request.Request" representing the
-// client's request for the ListImages operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See ListImages for more information on using the ListImages
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the ListImagesRequest method.
-// req, resp := client.ListImagesRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/ListImages
-func (c *ECR) ListImagesRequest(input *ListImagesInput) (req *request.Request, output *ListImagesOutput) {
- op := &request.Operation{
- Name: opListImages,
- HTTPMethod: "POST",
- HTTPPath: "/",
- Paginator: &request.Paginator{
- InputTokens: []string{"nextToken"},
- OutputTokens: []string{"nextToken"},
- LimitToken: "maxResults",
- TruncationToken: "",
- },
- }
-
- if input == nil {
- input = &ListImagesInput{}
- }
-
- output = &ListImagesOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// ListImages API operation for Amazon EC2 Container Registry.
-//
-// Lists all the image IDs for the specified repository.
-//
-// You can filter images based on whether or not they are tagged by using the
-// tagStatus filter and specifying either TAGGED, UNTAGGED or ANY. For example,
-// you can filter your results to return only UNTAGGED images and then pipe
-// that result to a BatchDeleteImage operation to delete them. Or, you can filter
-// your results to return only TAGGED images to list all of the tags in your
-// repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation ListImages for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/ListImages
-func (c *ECR) ListImages(input *ListImagesInput) (*ListImagesOutput, error) {
- req, out := c.ListImagesRequest(input)
- return out, req.Send()
-}
-
-// ListImagesWithContext is the same as ListImages with the addition of
-// the ability to pass a context and additional request options.
-//
-// See ListImages for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) ListImagesWithContext(ctx aws.Context, input *ListImagesInput, opts ...request.Option) (*ListImagesOutput, error) {
- req, out := c.ListImagesRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-// ListImagesPages iterates over the pages of a ListImages operation,
-// calling the "fn" function with the response data for each page. To stop
-// iterating, return false from the fn function.
-//
-// See ListImages method for more information on how to use this operation.
-//
-// Note: This operation can generate multiple requests to a service.
-//
-// // Example iterating over at most 3 pages of a ListImages operation.
-// pageNum := 0
-// err := client.ListImagesPages(params,
-// func(page *ecr.ListImagesOutput, lastPage bool) bool {
-// pageNum++
-// fmt.Println(page)
-// return pageNum <= 3
-// })
-//
-func (c *ECR) ListImagesPages(input *ListImagesInput, fn func(*ListImagesOutput, bool) bool) error {
- return c.ListImagesPagesWithContext(aws.BackgroundContext(), input, fn)
-}
-
-// ListImagesPagesWithContext same as ListImagesPages except
-// it takes a Context and allows setting request options on the pages.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) ListImagesPagesWithContext(ctx aws.Context, input *ListImagesInput, fn func(*ListImagesOutput, bool) bool, opts ...request.Option) error {
- p := request.Pagination{
- NewRequest: func() (*request.Request, error) {
- var inCpy *ListImagesInput
- if input != nil {
- tmp := *input
- inCpy = &tmp
- }
- req, _ := c.ListImagesRequest(inCpy)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return req, nil
- },
- }
-
- for p.Next() {
- if !fn(p.Page().(*ListImagesOutput), !p.HasNextPage()) {
- break
- }
- }
-
- return p.Err()
-}
-
-const opListTagsForResource = "ListTagsForResource"
-
-// ListTagsForResourceRequest generates a "aws/request.Request" representing the
-// client's request for the ListTagsForResource operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See ListTagsForResource for more information on using the ListTagsForResource
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the ListTagsForResourceRequest method.
-// req, resp := client.ListTagsForResourceRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/ListTagsForResource
-func (c *ECR) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) {
- op := &request.Operation{
- Name: opListTagsForResource,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &ListTagsForResourceInput{}
- }
-
- output = &ListTagsForResourceOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// ListTagsForResource API operation for Amazon EC2 Container Registry.
-//
-// List the tags for an Amazon ECR resource.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation ListTagsForResource for usage and error information.
-//
-// Returned Error Types:
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/ListTagsForResource
-func (c *ECR) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) {
- req, out := c.ListTagsForResourceRequest(input)
- return out, req.Send()
-}
-
-// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of
-// the ability to pass a context and additional request options.
-//
-// See ListTagsForResource for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) {
- req, out := c.ListTagsForResourceRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opPutImage = "PutImage"
-
-// PutImageRequest generates a "aws/request.Request" representing the
-// client's request for the PutImage operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See PutImage for more information on using the PutImage
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the PutImageRequest method.
-// req, resp := client.PutImageRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutImage
-func (c *ECR) PutImageRequest(input *PutImageInput) (req *request.Request, output *PutImageOutput) {
- op := &request.Operation{
- Name: opPutImage,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &PutImageInput{}
- }
-
- output = &PutImageOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// PutImage API operation for Amazon EC2 Container Registry.
-//
-// Creates or updates the image manifest and tags associated with an image.
-//
-// When an image is pushed and all new image layers have been uploaded, the
-// PutImage API is called once to create or update the image manifest and the
-// tags associated with the image.
-//
-// This operation is used by the Amazon ECR proxy and is not generally used
-// by customers for pulling and pushing images. In most cases, you should use
-// the docker CLI to pull, tag, and push images.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation PutImage for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * ImageAlreadyExistsException
-// The specified image has already been pushed, and there were no changes to
-// the manifest or image tag after the last push.
-//
-// * LayersNotFoundException
-// The specified layers could not be found, or the specified layer is not valid
-// for this repository.
-//
-// * ReferencedImagesNotFoundException
-// The manifest list is referencing an image that does not exist.
-//
-// * LimitExceededException
-// The operation did not succeed because it would have exceeded a service limit
-// for your account. For more information, see Amazon ECR Service Quotas (https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// * ImageTagAlreadyExistsException
-// The specified image is tagged with a tag that already exists. The repository
-// is configured for tag immutability.
-//
-// * ImageDigestDoesNotMatchException
-// The specified image digest does not match the digest that Amazon ECR calculated
-// for the image.
-//
-// * KmsException
-// The operation failed due to a KMS exception.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutImage
-func (c *ECR) PutImage(input *PutImageInput) (*PutImageOutput, error) {
- req, out := c.PutImageRequest(input)
- return out, req.Send()
-}
-
-// PutImageWithContext is the same as PutImage with the addition of
-// the ability to pass a context and additional request options.
-//
-// See PutImage for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) PutImageWithContext(ctx aws.Context, input *PutImageInput, opts ...request.Option) (*PutImageOutput, error) {
- req, out := c.PutImageRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opPutImageScanningConfiguration = "PutImageScanningConfiguration"
-
-// PutImageScanningConfigurationRequest generates a "aws/request.Request" representing the
-// client's request for the PutImageScanningConfiguration operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See PutImageScanningConfiguration for more information on using the PutImageScanningConfiguration
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the PutImageScanningConfigurationRequest method.
-// req, resp := client.PutImageScanningConfigurationRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutImageScanningConfiguration
-func (c *ECR) PutImageScanningConfigurationRequest(input *PutImageScanningConfigurationInput) (req *request.Request, output *PutImageScanningConfigurationOutput) {
- op := &request.Operation{
- Name: opPutImageScanningConfiguration,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &PutImageScanningConfigurationInput{}
- }
-
- output = &PutImageScanningConfigurationOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// PutImageScanningConfiguration API operation for Amazon EC2 Container Registry.
-//
-// Updates the image scanning configuration for the specified repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation PutImageScanningConfiguration for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutImageScanningConfiguration
-func (c *ECR) PutImageScanningConfiguration(input *PutImageScanningConfigurationInput) (*PutImageScanningConfigurationOutput, error) {
- req, out := c.PutImageScanningConfigurationRequest(input)
- return out, req.Send()
-}
-
-// PutImageScanningConfigurationWithContext is the same as PutImageScanningConfiguration with the addition of
-// the ability to pass a context and additional request options.
-//
-// See PutImageScanningConfiguration for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) PutImageScanningConfigurationWithContext(ctx aws.Context, input *PutImageScanningConfigurationInput, opts ...request.Option) (*PutImageScanningConfigurationOutput, error) {
- req, out := c.PutImageScanningConfigurationRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opPutImageTagMutability = "PutImageTagMutability"
-
-// PutImageTagMutabilityRequest generates a "aws/request.Request" representing the
-// client's request for the PutImageTagMutability operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See PutImageTagMutability for more information on using the PutImageTagMutability
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the PutImageTagMutabilityRequest method.
-// req, resp := client.PutImageTagMutabilityRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutImageTagMutability
-func (c *ECR) PutImageTagMutabilityRequest(input *PutImageTagMutabilityInput) (req *request.Request, output *PutImageTagMutabilityOutput) {
- op := &request.Operation{
- Name: opPutImageTagMutability,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &PutImageTagMutabilityInput{}
- }
-
- output = &PutImageTagMutabilityOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// PutImageTagMutability API operation for Amazon EC2 Container Registry.
-//
-// Updates the image tag mutability settings for the specified repository. For
-// more information, see Image Tag Mutability (https://docs.aws.amazon.com/AmazonECR/latest/userguide/image-tag-mutability.html)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation PutImageTagMutability for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutImageTagMutability
-func (c *ECR) PutImageTagMutability(input *PutImageTagMutabilityInput) (*PutImageTagMutabilityOutput, error) {
- req, out := c.PutImageTagMutabilityRequest(input)
- return out, req.Send()
-}
-
-// PutImageTagMutabilityWithContext is the same as PutImageTagMutability with the addition of
-// the ability to pass a context and additional request options.
-//
-// See PutImageTagMutability for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) PutImageTagMutabilityWithContext(ctx aws.Context, input *PutImageTagMutabilityInput, opts ...request.Option) (*PutImageTagMutabilityOutput, error) {
- req, out := c.PutImageTagMutabilityRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opPutLifecyclePolicy = "PutLifecyclePolicy"
-
-// PutLifecyclePolicyRequest generates a "aws/request.Request" representing the
-// client's request for the PutLifecyclePolicy operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See PutLifecyclePolicy for more information on using the PutLifecyclePolicy
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the PutLifecyclePolicyRequest method.
-// req, resp := client.PutLifecyclePolicyRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutLifecyclePolicy
-func (c *ECR) PutLifecyclePolicyRequest(input *PutLifecyclePolicyInput) (req *request.Request, output *PutLifecyclePolicyOutput) {
- op := &request.Operation{
- Name: opPutLifecyclePolicy,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &PutLifecyclePolicyInput{}
- }
-
- output = &PutLifecyclePolicyOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// PutLifecyclePolicy API operation for Amazon EC2 Container Registry.
-//
-// Creates or updates the lifecycle policy for the specified repository. For
-// more information, see Lifecycle Policy Template (https://docs.aws.amazon.com/AmazonECR/latest/userguide/LifecyclePolicies.html).
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation PutLifecyclePolicy for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutLifecyclePolicy
-func (c *ECR) PutLifecyclePolicy(input *PutLifecyclePolicyInput) (*PutLifecyclePolicyOutput, error) {
- req, out := c.PutLifecyclePolicyRequest(input)
- return out, req.Send()
-}
-
-// PutLifecyclePolicyWithContext is the same as PutLifecyclePolicy with the addition of
-// the ability to pass a context and additional request options.
-//
-// See PutLifecyclePolicy for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) PutLifecyclePolicyWithContext(ctx aws.Context, input *PutLifecyclePolicyInput, opts ...request.Option) (*PutLifecyclePolicyOutput, error) {
- req, out := c.PutLifecyclePolicyRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opSetRepositoryPolicy = "SetRepositoryPolicy"
-
-// SetRepositoryPolicyRequest generates a "aws/request.Request" representing the
-// client's request for the SetRepositoryPolicy operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See SetRepositoryPolicy for more information on using the SetRepositoryPolicy
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the SetRepositoryPolicyRequest method.
-// req, resp := client.SetRepositoryPolicyRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/SetRepositoryPolicy
-func (c *ECR) SetRepositoryPolicyRequest(input *SetRepositoryPolicyInput) (req *request.Request, output *SetRepositoryPolicyOutput) {
- op := &request.Operation{
- Name: opSetRepositoryPolicy,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &SetRepositoryPolicyInput{}
- }
-
- output = &SetRepositoryPolicyOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// SetRepositoryPolicy API operation for Amazon EC2 Container Registry.
-//
-// Applies a repository policy to the specified repository to control access
-// permissions. For more information, see Amazon ECR Repository Policies (https://docs.aws.amazon.com/AmazonECR/latest/userguide/repository-policies.html)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation SetRepositoryPolicy for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/SetRepositoryPolicy
-func (c *ECR) SetRepositoryPolicy(input *SetRepositoryPolicyInput) (*SetRepositoryPolicyOutput, error) {
- req, out := c.SetRepositoryPolicyRequest(input)
- return out, req.Send()
-}
-
-// SetRepositoryPolicyWithContext is the same as SetRepositoryPolicy with the addition of
-// the ability to pass a context and additional request options.
-//
-// See SetRepositoryPolicy for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) SetRepositoryPolicyWithContext(ctx aws.Context, input *SetRepositoryPolicyInput, opts ...request.Option) (*SetRepositoryPolicyOutput, error) {
- req, out := c.SetRepositoryPolicyRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opStartImageScan = "StartImageScan"
-
-// StartImageScanRequest generates a "aws/request.Request" representing the
-// client's request for the StartImageScan operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See StartImageScan for more information on using the StartImageScan
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the StartImageScanRequest method.
-// req, resp := client.StartImageScanRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/StartImageScan
-func (c *ECR) StartImageScanRequest(input *StartImageScanInput) (req *request.Request, output *StartImageScanOutput) {
- op := &request.Operation{
- Name: opStartImageScan,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &StartImageScanInput{}
- }
-
- output = &StartImageScanOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// StartImageScan API operation for Amazon EC2 Container Registry.
-//
-// Starts an image vulnerability scan. An image scan can only be started once
-// per day on an individual image. This limit includes if an image was scanned
-// on initial push. For more information, see Image Scanning (https://docs.aws.amazon.com/AmazonECR/latest/userguide/image-scanning.html)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation StartImageScan for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * UnsupportedImageTypeException
-// The image is of a type that cannot be scanned.
-//
-// * LimitExceededException
-// The operation did not succeed because it would have exceeded a service limit
-// for your account. For more information, see Amazon ECR Service Quotas (https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * ImageNotFoundException
-// The image requested does not exist in the specified repository.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/StartImageScan
-func (c *ECR) StartImageScan(input *StartImageScanInput) (*StartImageScanOutput, error) {
- req, out := c.StartImageScanRequest(input)
- return out, req.Send()
-}
-
-// StartImageScanWithContext is the same as StartImageScan with the addition of
-// the ability to pass a context and additional request options.
-//
-// See StartImageScan for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) StartImageScanWithContext(ctx aws.Context, input *StartImageScanInput, opts ...request.Option) (*StartImageScanOutput, error) {
- req, out := c.StartImageScanRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opStartLifecyclePolicyPreview = "StartLifecyclePolicyPreview"
-
-// StartLifecyclePolicyPreviewRequest generates a "aws/request.Request" representing the
-// client's request for the StartLifecyclePolicyPreview operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See StartLifecyclePolicyPreview for more information on using the StartLifecyclePolicyPreview
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the StartLifecyclePolicyPreviewRequest method.
-// req, resp := client.StartLifecyclePolicyPreviewRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/StartLifecyclePolicyPreview
-func (c *ECR) StartLifecyclePolicyPreviewRequest(input *StartLifecyclePolicyPreviewInput) (req *request.Request, output *StartLifecyclePolicyPreviewOutput) {
- op := &request.Operation{
- Name: opStartLifecyclePolicyPreview,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &StartLifecyclePolicyPreviewInput{}
- }
-
- output = &StartLifecyclePolicyPreviewOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// StartLifecyclePolicyPreview API operation for Amazon EC2 Container Registry.
-//
-// Starts a preview of a lifecycle policy for the specified repository. This
-// allows you to see the results before associating the lifecycle policy with
-// the repository.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation StartLifecyclePolicyPreview for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * LifecyclePolicyNotFoundException
-// The lifecycle policy could not be found, and no policy is set to the repository.
-//
-// * LifecyclePolicyPreviewInProgressException
-// The previous lifecycle policy preview request has not completed. Wait and
-// try again.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/StartLifecyclePolicyPreview
-func (c *ECR) StartLifecyclePolicyPreview(input *StartLifecyclePolicyPreviewInput) (*StartLifecyclePolicyPreviewOutput, error) {
- req, out := c.StartLifecyclePolicyPreviewRequest(input)
- return out, req.Send()
-}
-
-// StartLifecyclePolicyPreviewWithContext is the same as StartLifecyclePolicyPreview with the addition of
-// the ability to pass a context and additional request options.
-//
-// See StartLifecyclePolicyPreview for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) StartLifecyclePolicyPreviewWithContext(ctx aws.Context, input *StartLifecyclePolicyPreviewInput, opts ...request.Option) (*StartLifecyclePolicyPreviewOutput, error) {
- req, out := c.StartLifecyclePolicyPreviewRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opTagResource = "TagResource"
-
-// TagResourceRequest generates a "aws/request.Request" representing the
-// client's request for the TagResource operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See TagResource for more information on using the TagResource
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the TagResourceRequest method.
-// req, resp := client.TagResourceRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/TagResource
-func (c *ECR) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) {
- op := &request.Operation{
- Name: opTagResource,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &TagResourceInput{}
- }
-
- output = &TagResourceOutput{}
- req = c.newRequest(op, input, output)
- req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
- return
-}
-
-// TagResource API operation for Amazon EC2 Container Registry.
-//
-// Adds specified tags to a resource with the specified ARN. Existing tags on
-// a resource are not changed if they are not specified in the request parameters.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation TagResource for usage and error information.
-//
-// Returned Error Types:
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * InvalidTagParameterException
-// An invalid parameter has been specified. Tag keys can have a maximum character
-// length of 128 characters, and tag values can have a maximum length of 256
-// characters.
-//
-// * TooManyTagsException
-// The list of tags on the repository is over the limit. The maximum number
-// of tags that can be applied to a repository is 50.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/TagResource
-func (c *ECR) TagResource(input *TagResourceInput) (*TagResourceOutput, error) {
- req, out := c.TagResourceRequest(input)
- return out, req.Send()
-}
-
-// TagResourceWithContext is the same as TagResource with the addition of
-// the ability to pass a context and additional request options.
-//
-// See TagResource for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) {
- req, out := c.TagResourceRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opUntagResource = "UntagResource"
-
-// UntagResourceRequest generates a "aws/request.Request" representing the
-// client's request for the UntagResource operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See UntagResource for more information on using the UntagResource
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the UntagResourceRequest method.
-// req, resp := client.UntagResourceRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/UntagResource
-func (c *ECR) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) {
- op := &request.Operation{
- Name: opUntagResource,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &UntagResourceInput{}
- }
-
- output = &UntagResourceOutput{}
- req = c.newRequest(op, input, output)
- req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
- return
-}
-
-// UntagResource API operation for Amazon EC2 Container Registry.
-//
-// Deletes specified tags from a resource.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation UntagResource for usage and error information.
-//
-// Returned Error Types:
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * InvalidTagParameterException
-// An invalid parameter has been specified. Tag keys can have a maximum character
-// length of 128 characters, and tag values can have a maximum length of 256
-// characters.
-//
-// * TooManyTagsException
-// The list of tags on the repository is over the limit. The maximum number
-// of tags that can be applied to a repository is 50.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/UntagResource
-func (c *ECR) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) {
- req, out := c.UntagResourceRequest(input)
- return out, req.Send()
-}
-
-// UntagResourceWithContext is the same as UntagResource with the addition of
-// the ability to pass a context and additional request options.
-//
-// See UntagResource for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) {
- req, out := c.UntagResourceRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opUploadLayerPart = "UploadLayerPart"
-
-// UploadLayerPartRequest generates a "aws/request.Request" representing the
-// client's request for the UploadLayerPart operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See UploadLayerPart for more information on using the UploadLayerPart
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the UploadLayerPartRequest method.
-// req, resp := client.UploadLayerPartRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/UploadLayerPart
-func (c *ECR) UploadLayerPartRequest(input *UploadLayerPartInput) (req *request.Request, output *UploadLayerPartOutput) {
- op := &request.Operation{
- Name: opUploadLayerPart,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &UploadLayerPartInput{}
- }
-
- output = &UploadLayerPartOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// UploadLayerPart API operation for Amazon EC2 Container Registry.
-//
-// Uploads an image layer part to Amazon ECR.
-//
-// When an image is pushed, each new image layer is uploaded in parts. The maximum
-// size of each image layer part can be 20971520 bytes (or about 20MB). The
-// UploadLayerPart API is called once per each new image layer part.
-//
-// This operation is used by the Amazon ECR proxy and is not generally used
-// by customers for pulling and pushing images. In most cases, you should use
-// the docker CLI to pull, tag, and push images.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for Amazon EC2 Container Registry's
-// API operation UploadLayerPart for usage and error information.
-//
-// Returned Error Types:
-// * ServerException
-// These errors are usually caused by a server-side issue.
-//
-// * InvalidParameterException
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-//
-// * InvalidLayerPartException
-// The layer part size is not valid, or the first byte specified is not consecutive
-// to the last byte of a previous layer part upload.
-//
-// * RepositoryNotFoundException
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-//
-// * UploadNotFoundException
-// The upload could not be found, or the specified upload ID is not valid for
-// this repository.
-//
-// * LimitExceededException
-// The operation did not succeed because it would have exceeded a service limit
-// for your account. For more information, see Amazon ECR Service Quotas (https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html)
-// in the Amazon Elastic Container Registry User Guide.
-//
-// * KmsException
-// The operation failed due to a KMS exception.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/UploadLayerPart
-func (c *ECR) UploadLayerPart(input *UploadLayerPartInput) (*UploadLayerPartOutput, error) {
- req, out := c.UploadLayerPartRequest(input)
- return out, req.Send()
-}
-
-// UploadLayerPartWithContext is the same as UploadLayerPart with the addition of
-// the ability to pass a context and additional request options.
-//
-// See UploadLayerPart for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) UploadLayerPartWithContext(ctx aws.Context, input *UploadLayerPartInput, opts ...request.Option) (*UploadLayerPartOutput, error) {
- req, out := c.UploadLayerPartRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-// This data type is used in the ImageScanFinding data type.
-type Attribute struct {
- _ struct{} `type:"structure"`
-
- // The attribute key.
- //
- // Key is a required field
- Key *string `locationName:"key" min:"1" type:"string" required:"true"`
-
- // The value assigned to the attribute key.
- Value *string `locationName:"value" min:"1" type:"string"`
-}
-
-// String returns the string representation
-func (s Attribute) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s Attribute) GoString() string {
- return s.String()
-}
-
-// SetKey sets the Key field's value.
-func (s *Attribute) SetKey(v string) *Attribute {
- s.Key = &v
- return s
-}
-
-// SetValue sets the Value field's value.
-func (s *Attribute) SetValue(v string) *Attribute {
- s.Value = &v
- return s
-}
-
-// An object representing authorization data for an Amazon ECR registry.
-type AuthorizationData struct {
- _ struct{} `type:"structure"`
-
- // A base64-encoded string that contains authorization data for the specified
- // Amazon ECR registry. When the string is decoded, it is presented in the format
- // user:password for private registry authentication using docker login.
- AuthorizationToken *string `locationName:"authorizationToken" type:"string"`
-
- // The Unix time in seconds and milliseconds when the authorization token expires.
- // Authorization tokens are valid for 12 hours.
- ExpiresAt *time.Time `locationName:"expiresAt" type:"timestamp"`
-
- // The registry URL to use for this authorization token in a docker login command.
- // The Amazon ECR registry URL format is https://aws_account_id.dkr.ecr.region.amazonaws.com.
- // For example, https://012345678910.dkr.ecr.us-east-1.amazonaws.com..
- ProxyEndpoint *string `locationName:"proxyEndpoint" type:"string"`
-}
-
-// String returns the string representation
-func (s AuthorizationData) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s AuthorizationData) GoString() string {
- return s.String()
-}
-
-// SetAuthorizationToken sets the AuthorizationToken field's value.
-func (s *AuthorizationData) SetAuthorizationToken(v string) *AuthorizationData {
- s.AuthorizationToken = &v
- return s
-}
-
-// SetExpiresAt sets the ExpiresAt field's value.
-func (s *AuthorizationData) SetExpiresAt(v time.Time) *AuthorizationData {
- s.ExpiresAt = &v
- return s
-}
-
-// SetProxyEndpoint sets the ProxyEndpoint field's value.
-func (s *AuthorizationData) SetProxyEndpoint(v string) *AuthorizationData {
- s.ProxyEndpoint = &v
- return s
-}
-
-type BatchCheckLayerAvailabilityInput struct {
- _ struct{} `type:"structure"`
-
- // The digests of the image layers to check.
- //
- // LayerDigests is a required field
- LayerDigests []*string `locationName:"layerDigests" min:"1" type:"list" required:"true"`
-
- // The AWS account ID associated with the registry that contains the image layers
- // to check. If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository that is associated with the image layers to check.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s BatchCheckLayerAvailabilityInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s BatchCheckLayerAvailabilityInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *BatchCheckLayerAvailabilityInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "BatchCheckLayerAvailabilityInput"}
- if s.LayerDigests == nil {
- invalidParams.Add(request.NewErrParamRequired("LayerDigests"))
- }
- if s.LayerDigests != nil && len(s.LayerDigests) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("LayerDigests", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetLayerDigests sets the LayerDigests field's value.
-func (s *BatchCheckLayerAvailabilityInput) SetLayerDigests(v []*string) *BatchCheckLayerAvailabilityInput {
- s.LayerDigests = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *BatchCheckLayerAvailabilityInput) SetRegistryId(v string) *BatchCheckLayerAvailabilityInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *BatchCheckLayerAvailabilityInput) SetRepositoryName(v string) *BatchCheckLayerAvailabilityInput {
- s.RepositoryName = &v
- return s
-}
-
-type BatchCheckLayerAvailabilityOutput struct {
- _ struct{} `type:"structure"`
-
- // Any failures associated with the call.
- Failures []*LayerFailure `locationName:"failures" type:"list"`
-
- // A list of image layer objects corresponding to the image layer references
- // in the request.
- Layers []*Layer `locationName:"layers" type:"list"`
-}
-
-// String returns the string representation
-func (s BatchCheckLayerAvailabilityOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s BatchCheckLayerAvailabilityOutput) GoString() string {
- return s.String()
-}
-
-// SetFailures sets the Failures field's value.
-func (s *BatchCheckLayerAvailabilityOutput) SetFailures(v []*LayerFailure) *BatchCheckLayerAvailabilityOutput {
- s.Failures = v
- return s
-}
-
-// SetLayers sets the Layers field's value.
-func (s *BatchCheckLayerAvailabilityOutput) SetLayers(v []*Layer) *BatchCheckLayerAvailabilityOutput {
- s.Layers = v
- return s
-}
-
-// Deletes specified images within a specified repository. Images are specified
-// with either the imageTag or imageDigest.
-type BatchDeleteImageInput struct {
- _ struct{} `type:"structure"`
-
- // A list of image ID references that correspond to images to delete. The format
- // of the imageIds reference is imageTag=tag or imageDigest=digest.
- //
- // ImageIds is a required field
- ImageIds []*ImageIdentifier `locationName:"imageIds" min:"1" type:"list" required:"true"`
-
- // The AWS account ID associated with the registry that contains the image to
- // delete. If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository that contains the image to delete.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s BatchDeleteImageInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s BatchDeleteImageInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *BatchDeleteImageInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "BatchDeleteImageInput"}
- if s.ImageIds == nil {
- invalidParams.Add(request.NewErrParamRequired("ImageIds"))
- }
- if s.ImageIds != nil && len(s.ImageIds) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("ImageIds", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.ImageIds != nil {
- for i, v := range s.ImageIds {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ImageIds", i), err.(request.ErrInvalidParams))
- }
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetImageIds sets the ImageIds field's value.
-func (s *BatchDeleteImageInput) SetImageIds(v []*ImageIdentifier) *BatchDeleteImageInput {
- s.ImageIds = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *BatchDeleteImageInput) SetRegistryId(v string) *BatchDeleteImageInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *BatchDeleteImageInput) SetRepositoryName(v string) *BatchDeleteImageInput {
- s.RepositoryName = &v
- return s
-}
-
-type BatchDeleteImageOutput struct {
- _ struct{} `type:"structure"`
-
- // Any failures associated with the call.
- Failures []*ImageFailure `locationName:"failures" type:"list"`
-
- // The image IDs of the deleted images.
- ImageIds []*ImageIdentifier `locationName:"imageIds" min:"1" type:"list"`
-}
-
-// String returns the string representation
-func (s BatchDeleteImageOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s BatchDeleteImageOutput) GoString() string {
- return s.String()
-}
-
-// SetFailures sets the Failures field's value.
-func (s *BatchDeleteImageOutput) SetFailures(v []*ImageFailure) *BatchDeleteImageOutput {
- s.Failures = v
- return s
-}
-
-// SetImageIds sets the ImageIds field's value.
-func (s *BatchDeleteImageOutput) SetImageIds(v []*ImageIdentifier) *BatchDeleteImageOutput {
- s.ImageIds = v
- return s
-}
-
-type BatchGetImageInput struct {
- _ struct{} `type:"structure"`
-
- // The accepted media types for the request.
- //
- // Valid values: application/vnd.docker.distribution.manifest.v1+json | application/vnd.docker.distribution.manifest.v2+json
- // | application/vnd.oci.image.manifest.v1+json
- AcceptedMediaTypes []*string `locationName:"acceptedMediaTypes" min:"1" type:"list"`
-
- // A list of image ID references that correspond to images to describe. The
- // format of the imageIds reference is imageTag=tag or imageDigest=digest.
- //
- // ImageIds is a required field
- ImageIds []*ImageIdentifier `locationName:"imageIds" min:"1" type:"list" required:"true"`
-
- // The AWS account ID associated with the registry that contains the images
- // to describe. If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository that contains the images to describe.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s BatchGetImageInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s BatchGetImageInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *BatchGetImageInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "BatchGetImageInput"}
- if s.AcceptedMediaTypes != nil && len(s.AcceptedMediaTypes) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("AcceptedMediaTypes", 1))
- }
- if s.ImageIds == nil {
- invalidParams.Add(request.NewErrParamRequired("ImageIds"))
- }
- if s.ImageIds != nil && len(s.ImageIds) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("ImageIds", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.ImageIds != nil {
- for i, v := range s.ImageIds {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ImageIds", i), err.(request.ErrInvalidParams))
- }
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetAcceptedMediaTypes sets the AcceptedMediaTypes field's value.
-func (s *BatchGetImageInput) SetAcceptedMediaTypes(v []*string) *BatchGetImageInput {
- s.AcceptedMediaTypes = v
- return s
-}
-
-// SetImageIds sets the ImageIds field's value.
-func (s *BatchGetImageInput) SetImageIds(v []*ImageIdentifier) *BatchGetImageInput {
- s.ImageIds = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *BatchGetImageInput) SetRegistryId(v string) *BatchGetImageInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *BatchGetImageInput) SetRepositoryName(v string) *BatchGetImageInput {
- s.RepositoryName = &v
- return s
-}
-
-type BatchGetImageOutput struct {
- _ struct{} `type:"structure"`
-
- // Any failures associated with the call.
- Failures []*ImageFailure `locationName:"failures" type:"list"`
-
- // A list of image objects corresponding to the image references in the request.
- Images []*Image `locationName:"images" type:"list"`
-}
-
-// String returns the string representation
-func (s BatchGetImageOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s BatchGetImageOutput) GoString() string {
- return s.String()
-}
-
-// SetFailures sets the Failures field's value.
-func (s *BatchGetImageOutput) SetFailures(v []*ImageFailure) *BatchGetImageOutput {
- s.Failures = v
- return s
-}
-
-// SetImages sets the Images field's value.
-func (s *BatchGetImageOutput) SetImages(v []*Image) *BatchGetImageOutput {
- s.Images = v
- return s
-}
-
-type CompleteLayerUploadInput struct {
- _ struct{} `type:"structure"`
-
- // The sha256 digest of the image layer.
- //
- // LayerDigests is a required field
- LayerDigests []*string `locationName:"layerDigests" min:"1" type:"list" required:"true"`
-
- // The AWS account ID associated with the registry to which to upload layers.
- // If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository to associate with the image layer.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-
- // The upload ID from a previous InitiateLayerUpload operation to associate
- // with the image layer.
- //
- // UploadId is a required field
- UploadId *string `locationName:"uploadId" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s CompleteLayerUploadInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s CompleteLayerUploadInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *CompleteLayerUploadInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "CompleteLayerUploadInput"}
- if s.LayerDigests == nil {
- invalidParams.Add(request.NewErrParamRequired("LayerDigests"))
- }
- if s.LayerDigests != nil && len(s.LayerDigests) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("LayerDigests", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.UploadId == nil {
- invalidParams.Add(request.NewErrParamRequired("UploadId"))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetLayerDigests sets the LayerDigests field's value.
-func (s *CompleteLayerUploadInput) SetLayerDigests(v []*string) *CompleteLayerUploadInput {
- s.LayerDigests = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *CompleteLayerUploadInput) SetRegistryId(v string) *CompleteLayerUploadInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *CompleteLayerUploadInput) SetRepositoryName(v string) *CompleteLayerUploadInput {
- s.RepositoryName = &v
- return s
-}
-
-// SetUploadId sets the UploadId field's value.
-func (s *CompleteLayerUploadInput) SetUploadId(v string) *CompleteLayerUploadInput {
- s.UploadId = &v
- return s
-}
-
-type CompleteLayerUploadOutput struct {
- _ struct{} `type:"structure"`
-
- // The sha256 digest of the image layer.
- LayerDigest *string `locationName:"layerDigest" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-
- // The upload ID associated with the layer.
- UploadId *string `locationName:"uploadId" type:"string"`
-}
-
-// String returns the string representation
-func (s CompleteLayerUploadOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s CompleteLayerUploadOutput) GoString() string {
- return s.String()
-}
-
-// SetLayerDigest sets the LayerDigest field's value.
-func (s *CompleteLayerUploadOutput) SetLayerDigest(v string) *CompleteLayerUploadOutput {
- s.LayerDigest = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *CompleteLayerUploadOutput) SetRegistryId(v string) *CompleteLayerUploadOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *CompleteLayerUploadOutput) SetRepositoryName(v string) *CompleteLayerUploadOutput {
- s.RepositoryName = &v
- return s
-}
-
-// SetUploadId sets the UploadId field's value.
-func (s *CompleteLayerUploadOutput) SetUploadId(v string) *CompleteLayerUploadOutput {
- s.UploadId = &v
- return s
-}
-
-type CreateRepositoryInput struct {
- _ struct{} `type:"structure"`
-
- // The encryption configuration for the repository. This determines how the
- // contents of your repository are encrypted at rest.
- EncryptionConfiguration *EncryptionConfiguration `locationName:"encryptionConfiguration" type:"structure"`
-
- // The image scanning configuration for the repository. This determines whether
- // images are scanned for known vulnerabilities after being pushed to the repository.
- ImageScanningConfiguration *ImageScanningConfiguration `locationName:"imageScanningConfiguration" type:"structure"`
-
- // The tag mutability setting for the repository. If this parameter is omitted,
- // the default setting of MUTABLE will be used which will allow image tags to
- // be overwritten. If IMMUTABLE is specified, all image tags within the repository
- // will be immutable which will prevent them from being overwritten.
- ImageTagMutability *string `locationName:"imageTagMutability" type:"string" enum:"ImageTagMutability"`
-
- // The name to use for the repository. The repository name may be specified
- // on its own (such as nginx-web-app) or it can be prepended with a namespace
- // to group the repository into a category (such as project-a/nginx-web-app).
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-
- // The metadata that you apply to the repository to help you categorize and
- // organize them. Each tag consists of a key and an optional value, both of
- // which you define. Tag keys can have a maximum character length of 128 characters,
- // and tag values can have a maximum length of 256 characters.
- Tags []*Tag `locationName:"tags" type:"list"`
-}
-
-// String returns the string representation
-func (s CreateRepositoryInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s CreateRepositoryInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *CreateRepositoryInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "CreateRepositoryInput"}
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.EncryptionConfiguration != nil {
- if err := s.EncryptionConfiguration.Validate(); err != nil {
- invalidParams.AddNested("EncryptionConfiguration", err.(request.ErrInvalidParams))
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetEncryptionConfiguration sets the EncryptionConfiguration field's value.
-func (s *CreateRepositoryInput) SetEncryptionConfiguration(v *EncryptionConfiguration) *CreateRepositoryInput {
- s.EncryptionConfiguration = v
- return s
-}
-
-// SetImageScanningConfiguration sets the ImageScanningConfiguration field's value.
-func (s *CreateRepositoryInput) SetImageScanningConfiguration(v *ImageScanningConfiguration) *CreateRepositoryInput {
- s.ImageScanningConfiguration = v
- return s
-}
-
-// SetImageTagMutability sets the ImageTagMutability field's value.
-func (s *CreateRepositoryInput) SetImageTagMutability(v string) *CreateRepositoryInput {
- s.ImageTagMutability = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *CreateRepositoryInput) SetRepositoryName(v string) *CreateRepositoryInput {
- s.RepositoryName = &v
- return s
-}
-
-// SetTags sets the Tags field's value.
-func (s *CreateRepositoryInput) SetTags(v []*Tag) *CreateRepositoryInput {
- s.Tags = v
- return s
-}
-
-type CreateRepositoryOutput struct {
- _ struct{} `type:"structure"`
-
- // The repository that was created.
- Repository *Repository `locationName:"repository" type:"structure"`
-}
-
-// String returns the string representation
-func (s CreateRepositoryOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s CreateRepositoryOutput) GoString() string {
- return s.String()
-}
-
-// SetRepository sets the Repository field's value.
-func (s *CreateRepositoryOutput) SetRepository(v *Repository) *CreateRepositoryOutput {
- s.Repository = v
- return s
-}
-
-type DeleteLifecyclePolicyInput struct {
- _ struct{} `type:"structure"`
-
- // The AWS account ID associated with the registry that contains the repository.
- // If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s DeleteLifecyclePolicyInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DeleteLifecyclePolicyInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *DeleteLifecyclePolicyInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DeleteLifecyclePolicyInput"}
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DeleteLifecyclePolicyInput) SetRegistryId(v string) *DeleteLifecyclePolicyInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *DeleteLifecyclePolicyInput) SetRepositoryName(v string) *DeleteLifecyclePolicyInput {
- s.RepositoryName = &v
- return s
-}
-
-type DeleteLifecyclePolicyOutput struct {
- _ struct{} `type:"structure"`
-
- // The time stamp of the last time that the lifecycle policy was run.
- LastEvaluatedAt *time.Time `locationName:"lastEvaluatedAt" type:"timestamp"`
-
- // The JSON lifecycle policy text.
- LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s DeleteLifecyclePolicyOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DeleteLifecyclePolicyOutput) GoString() string {
- return s.String()
-}
-
-// SetLastEvaluatedAt sets the LastEvaluatedAt field's value.
-func (s *DeleteLifecyclePolicyOutput) SetLastEvaluatedAt(v time.Time) *DeleteLifecyclePolicyOutput {
- s.LastEvaluatedAt = &v
- return s
-}
-
-// SetLifecyclePolicyText sets the LifecyclePolicyText field's value.
-func (s *DeleteLifecyclePolicyOutput) SetLifecyclePolicyText(v string) *DeleteLifecyclePolicyOutput {
- s.LifecyclePolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DeleteLifecyclePolicyOutput) SetRegistryId(v string) *DeleteLifecyclePolicyOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *DeleteLifecyclePolicyOutput) SetRepositoryName(v string) *DeleteLifecyclePolicyOutput {
- s.RepositoryName = &v
- return s
-}
-
-type DeleteRepositoryInput struct {
- _ struct{} `type:"structure"`
-
- // If a repository contains images, forces the deletion.
- Force *bool `locationName:"force" type:"boolean"`
-
- // The AWS account ID associated with the registry that contains the repository
- // to delete. If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository to delete.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s DeleteRepositoryInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DeleteRepositoryInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *DeleteRepositoryInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DeleteRepositoryInput"}
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetForce sets the Force field's value.
-func (s *DeleteRepositoryInput) SetForce(v bool) *DeleteRepositoryInput {
- s.Force = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DeleteRepositoryInput) SetRegistryId(v string) *DeleteRepositoryInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *DeleteRepositoryInput) SetRepositoryName(v string) *DeleteRepositoryInput {
- s.RepositoryName = &v
- return s
-}
-
-type DeleteRepositoryOutput struct {
- _ struct{} `type:"structure"`
-
- // The repository that was deleted.
- Repository *Repository `locationName:"repository" type:"structure"`
-}
-
-// String returns the string representation
-func (s DeleteRepositoryOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DeleteRepositoryOutput) GoString() string {
- return s.String()
-}
-
-// SetRepository sets the Repository field's value.
-func (s *DeleteRepositoryOutput) SetRepository(v *Repository) *DeleteRepositoryOutput {
- s.Repository = v
- return s
-}
-
-type DeleteRepositoryPolicyInput struct {
- _ struct{} `type:"structure"`
-
- // The AWS account ID associated with the registry that contains the repository
- // policy to delete. If you do not specify a registry, the default registry
- // is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository that is associated with the repository policy
- // to delete.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s DeleteRepositoryPolicyInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DeleteRepositoryPolicyInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *DeleteRepositoryPolicyInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DeleteRepositoryPolicyInput"}
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DeleteRepositoryPolicyInput) SetRegistryId(v string) *DeleteRepositoryPolicyInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *DeleteRepositoryPolicyInput) SetRepositoryName(v string) *DeleteRepositoryPolicyInput {
- s.RepositoryName = &v
- return s
-}
-
-type DeleteRepositoryPolicyOutput struct {
- _ struct{} `type:"structure"`
-
- // The JSON repository policy that was deleted from the repository.
- PolicyText *string `locationName:"policyText" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s DeleteRepositoryPolicyOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DeleteRepositoryPolicyOutput) GoString() string {
- return s.String()
-}
-
-// SetPolicyText sets the PolicyText field's value.
-func (s *DeleteRepositoryPolicyOutput) SetPolicyText(v string) *DeleteRepositoryPolicyOutput {
- s.PolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DeleteRepositoryPolicyOutput) SetRegistryId(v string) *DeleteRepositoryPolicyOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *DeleteRepositoryPolicyOutput) SetRepositoryName(v string) *DeleteRepositoryPolicyOutput {
- s.RepositoryName = &v
- return s
-}
-
-type DescribeImageScanFindingsInput struct {
- _ struct{} `type:"structure"`
-
- // An object with identifying information for an Amazon ECR image.
- //
- // ImageId is a required field
- ImageId *ImageIdentifier `locationName:"imageId" type:"structure" required:"true"`
-
- // The maximum number of image scan results returned by DescribeImageScanFindings
- // in paginated output. When this parameter is used, DescribeImageScanFindings
- // only returns maxResults results in a single page along with a nextToken response
- // element. The remaining results of the initial request can be seen by sending
- // another DescribeImageScanFindings request with the returned nextToken value.
- // This value can be between 1 and 1000. If this parameter is not used, then
- // DescribeImageScanFindings returns up to 100 results and a nextToken value,
- // if applicable.
- MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"`
-
- // The nextToken value returned from a previous paginated DescribeImageScanFindings
- // request where maxResults was used and the results exceeded the value of that
- // parameter. Pagination continues from the end of the previous results that
- // returned the nextToken value. This value is null when there are no more results
- // to return.
- NextToken *string `locationName:"nextToken" type:"string"`
-
- // The AWS account ID associated with the registry that contains the repository
- // in which to describe the image scan findings for. If you do not specify a
- // registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository for the image for which to describe the scan findings.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s DescribeImageScanFindingsInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DescribeImageScanFindingsInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *DescribeImageScanFindingsInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DescribeImageScanFindingsInput"}
- if s.ImageId == nil {
- invalidParams.Add(request.NewErrParamRequired("ImageId"))
- }
- if s.MaxResults != nil && *s.MaxResults < 1 {
- invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.ImageId != nil {
- if err := s.ImageId.Validate(); err != nil {
- invalidParams.AddNested("ImageId", err.(request.ErrInvalidParams))
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetImageId sets the ImageId field's value.
-func (s *DescribeImageScanFindingsInput) SetImageId(v *ImageIdentifier) *DescribeImageScanFindingsInput {
- s.ImageId = v
- return s
-}
-
-// SetMaxResults sets the MaxResults field's value.
-func (s *DescribeImageScanFindingsInput) SetMaxResults(v int64) *DescribeImageScanFindingsInput {
- s.MaxResults = &v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *DescribeImageScanFindingsInput) SetNextToken(v string) *DescribeImageScanFindingsInput {
- s.NextToken = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DescribeImageScanFindingsInput) SetRegistryId(v string) *DescribeImageScanFindingsInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *DescribeImageScanFindingsInput) SetRepositoryName(v string) *DescribeImageScanFindingsInput {
- s.RepositoryName = &v
- return s
-}
-
-type DescribeImageScanFindingsOutput struct {
- _ struct{} `type:"structure"`
-
- // An object with identifying information for an Amazon ECR image.
- ImageId *ImageIdentifier `locationName:"imageId" type:"structure"`
-
- // The information contained in the image scan findings.
- ImageScanFindings *ImageScanFindings `locationName:"imageScanFindings" type:"structure"`
-
- // The current state of the scan.
- ImageScanStatus *ImageScanStatus `locationName:"imageScanStatus" type:"structure"`
-
- // The nextToken value to include in a future DescribeImageScanFindings request.
- // When the results of a DescribeImageScanFindings request exceed maxResults,
- // this value can be used to retrieve the next page of results. This value is
- // null when there are no more results to return.
- NextToken *string `locationName:"nextToken" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s DescribeImageScanFindingsOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DescribeImageScanFindingsOutput) GoString() string {
- return s.String()
-}
-
-// SetImageId sets the ImageId field's value.
-func (s *DescribeImageScanFindingsOutput) SetImageId(v *ImageIdentifier) *DescribeImageScanFindingsOutput {
- s.ImageId = v
- return s
-}
-
-// SetImageScanFindings sets the ImageScanFindings field's value.
-func (s *DescribeImageScanFindingsOutput) SetImageScanFindings(v *ImageScanFindings) *DescribeImageScanFindingsOutput {
- s.ImageScanFindings = v
- return s
-}
-
-// SetImageScanStatus sets the ImageScanStatus field's value.
-func (s *DescribeImageScanFindingsOutput) SetImageScanStatus(v *ImageScanStatus) *DescribeImageScanFindingsOutput {
- s.ImageScanStatus = v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *DescribeImageScanFindingsOutput) SetNextToken(v string) *DescribeImageScanFindingsOutput {
- s.NextToken = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DescribeImageScanFindingsOutput) SetRegistryId(v string) *DescribeImageScanFindingsOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *DescribeImageScanFindingsOutput) SetRepositoryName(v string) *DescribeImageScanFindingsOutput {
- s.RepositoryName = &v
- return s
-}
-
-// An object representing a filter on a DescribeImages operation.
-type DescribeImagesFilter struct {
- _ struct{} `type:"structure"`
-
- // The tag status with which to filter your DescribeImages results. You can
- // filter results based on whether they are TAGGED or UNTAGGED.
- TagStatus *string `locationName:"tagStatus" type:"string" enum:"TagStatus"`
-}
-
-// String returns the string representation
-func (s DescribeImagesFilter) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DescribeImagesFilter) GoString() string {
- return s.String()
-}
-
-// SetTagStatus sets the TagStatus field's value.
-func (s *DescribeImagesFilter) SetTagStatus(v string) *DescribeImagesFilter {
- s.TagStatus = &v
- return s
-}
-
-type DescribeImagesInput struct {
- _ struct{} `type:"structure"`
-
- // The filter key and value with which to filter your DescribeImages results.
- Filter *DescribeImagesFilter `locationName:"filter" type:"structure"`
-
- // The list of image IDs for the requested repository.
- ImageIds []*ImageIdentifier `locationName:"imageIds" min:"1" type:"list"`
-
- // The maximum number of repository results returned by DescribeImages in paginated
- // output. When this parameter is used, DescribeImages only returns maxResults
- // results in a single page along with a nextToken response element. The remaining
- // results of the initial request can be seen by sending another DescribeImages
- // request with the returned nextToken value. This value can be between 1 and
- // 1000. If this parameter is not used, then DescribeImages returns up to 100
- // results and a nextToken value, if applicable. This option cannot be used
- // when you specify images with imageIds.
- MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"`
-
- // The nextToken value returned from a previous paginated DescribeImages request
- // where maxResults was used and the results exceeded the value of that parameter.
- // Pagination continues from the end of the previous results that returned the
- // nextToken value. This value is null when there are no more results to return.
- // This option cannot be used when you specify images with imageIds.
- NextToken *string `locationName:"nextToken" type:"string"`
-
- // The AWS account ID associated with the registry that contains the repository
- // in which to describe images. If you do not specify a registry, the default
- // registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository that contains the images to describe.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s DescribeImagesInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DescribeImagesInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *DescribeImagesInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DescribeImagesInput"}
- if s.ImageIds != nil && len(s.ImageIds) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("ImageIds", 1))
- }
- if s.MaxResults != nil && *s.MaxResults < 1 {
- invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.ImageIds != nil {
- for i, v := range s.ImageIds {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ImageIds", i), err.(request.ErrInvalidParams))
- }
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetFilter sets the Filter field's value.
-func (s *DescribeImagesInput) SetFilter(v *DescribeImagesFilter) *DescribeImagesInput {
- s.Filter = v
- return s
-}
-
-// SetImageIds sets the ImageIds field's value.
-func (s *DescribeImagesInput) SetImageIds(v []*ImageIdentifier) *DescribeImagesInput {
- s.ImageIds = v
- return s
-}
-
-// SetMaxResults sets the MaxResults field's value.
-func (s *DescribeImagesInput) SetMaxResults(v int64) *DescribeImagesInput {
- s.MaxResults = &v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *DescribeImagesInput) SetNextToken(v string) *DescribeImagesInput {
- s.NextToken = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DescribeImagesInput) SetRegistryId(v string) *DescribeImagesInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *DescribeImagesInput) SetRepositoryName(v string) *DescribeImagesInput {
- s.RepositoryName = &v
- return s
-}
-
-type DescribeImagesOutput struct {
- _ struct{} `type:"structure"`
-
- // A list of ImageDetail objects that contain data about the image.
- ImageDetails []*ImageDetail `locationName:"imageDetails" type:"list"`
-
- // The nextToken value to include in a future DescribeImages request. When the
- // results of a DescribeImages request exceed maxResults, this value can be
- // used to retrieve the next page of results. This value is null when there
- // are no more results to return.
- NextToken *string `locationName:"nextToken" type:"string"`
-}
-
-// String returns the string representation
-func (s DescribeImagesOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DescribeImagesOutput) GoString() string {
- return s.String()
-}
-
-// SetImageDetails sets the ImageDetails field's value.
-func (s *DescribeImagesOutput) SetImageDetails(v []*ImageDetail) *DescribeImagesOutput {
- s.ImageDetails = v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *DescribeImagesOutput) SetNextToken(v string) *DescribeImagesOutput {
- s.NextToken = &v
- return s
-}
-
-type DescribeRepositoriesInput struct {
- _ struct{} `type:"structure"`
-
- // The maximum number of repository results returned by DescribeRepositories
- // in paginated output. When this parameter is used, DescribeRepositories only
- // returns maxResults results in a single page along with a nextToken response
- // element. The remaining results of the initial request can be seen by sending
- // another DescribeRepositories request with the returned nextToken value. This
- // value can be between 1 and 1000. If this parameter is not used, then DescribeRepositories
- // returns up to 100 results and a nextToken value, if applicable. This option
- // cannot be used when you specify repositories with repositoryNames.
- MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"`
-
- // The nextToken value returned from a previous paginated DescribeRepositories
- // request where maxResults was used and the results exceeded the value of that
- // parameter. Pagination continues from the end of the previous results that
- // returned the nextToken value. This value is null when there are no more results
- // to return. This option cannot be used when you specify repositories with
- // repositoryNames.
- //
- // This token should be treated as an opaque identifier that is only used to
- // retrieve the next items in a list and not for other programmatic purposes.
- NextToken *string `locationName:"nextToken" type:"string"`
-
- // The AWS account ID associated with the registry that contains the repositories
- // to be described. If you do not specify a registry, the default registry is
- // assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // A list of repositories to describe. If this parameter is omitted, then all
- // repositories in a registry are described.
- RepositoryNames []*string `locationName:"repositoryNames" min:"1" type:"list"`
-}
-
-// String returns the string representation
-func (s DescribeRepositoriesInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DescribeRepositoriesInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *DescribeRepositoriesInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DescribeRepositoriesInput"}
- if s.MaxResults != nil && *s.MaxResults < 1 {
- invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
- }
- if s.RepositoryNames != nil && len(s.RepositoryNames) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryNames", 1))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetMaxResults sets the MaxResults field's value.
-func (s *DescribeRepositoriesInput) SetMaxResults(v int64) *DescribeRepositoriesInput {
- s.MaxResults = &v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *DescribeRepositoriesInput) SetNextToken(v string) *DescribeRepositoriesInput {
- s.NextToken = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *DescribeRepositoriesInput) SetRegistryId(v string) *DescribeRepositoriesInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryNames sets the RepositoryNames field's value.
-func (s *DescribeRepositoriesInput) SetRepositoryNames(v []*string) *DescribeRepositoriesInput {
- s.RepositoryNames = v
- return s
-}
-
-type DescribeRepositoriesOutput struct {
- _ struct{} `type:"structure"`
-
- // The nextToken value to include in a future DescribeRepositories request.
- // When the results of a DescribeRepositories request exceed maxResults, this
- // value can be used to retrieve the next page of results. This value is null
- // when there are no more results to return.
- NextToken *string `locationName:"nextToken" type:"string"`
-
- // A list of repository objects corresponding to valid repositories.
- Repositories []*Repository `locationName:"repositories" type:"list"`
-}
-
-// String returns the string representation
-func (s DescribeRepositoriesOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DescribeRepositoriesOutput) GoString() string {
- return s.String()
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *DescribeRepositoriesOutput) SetNextToken(v string) *DescribeRepositoriesOutput {
- s.NextToken = &v
- return s
-}
-
-// SetRepositories sets the Repositories field's value.
-func (s *DescribeRepositoriesOutput) SetRepositories(v []*Repository) *DescribeRepositoriesOutput {
- s.Repositories = v
- return s
-}
-
-// The specified layer upload does not contain any layer parts.
-type EmptyUploadException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s EmptyUploadException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s EmptyUploadException) GoString() string {
- return s.String()
-}
-
-func newErrorEmptyUploadException(v protocol.ResponseMetadata) error {
- return &EmptyUploadException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *EmptyUploadException) Code() string {
- return "EmptyUploadException"
-}
-
-// Message returns the exception's message.
-func (s *EmptyUploadException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *EmptyUploadException) OrigErr() error {
- return nil
-}
-
-func (s *EmptyUploadException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *EmptyUploadException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *EmptyUploadException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The encryption configuration for the repository. This determines how the
-// contents of your repository are encrypted at rest.
-//
-// By default, when no encryption configuration is set or the AES256 encryption
-// type is used, Amazon ECR uses server-side encryption with Amazon S3-managed
-// encryption keys which encrypts your data at rest using an AES-256 encryption
-// algorithm. This does not require any action on your part.
-//
-// For more control over the encryption of the contents of your repository,
-// you can use server-side encryption with customer master keys (CMKs) stored
-// in AWS Key Management Service (AWS KMS) to encrypt your images. For more
-// information, see Amazon ECR encryption at rest (https://docs.aws.amazon.com/AmazonECR/latest/userguide/encryption-at-rest.html)
-// in the Amazon Elastic Container Registry User Guide.
-type EncryptionConfiguration struct {
- _ struct{} `type:"structure"`
-
- // The encryption type to use.
- //
- // If you use the KMS encryption type, the contents of the repository will be
- // encrypted using server-side encryption with customer master keys (CMKs) stored
- // in AWS KMS. When you use AWS KMS to encrypt your data, you can either use
- // the default AWS managed CMK for Amazon ECR, or specify your own CMK, which
- // you already created. For more information, see Protecting Data Using Server-Side
- // Encryption with CMKs Stored in AWS Key Management Service (SSE-KMS) (https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingKMSEncryption.html)
- // in the Amazon Simple Storage Service Console Developer Guide..
- //
- // If you use the AES256 encryption type, Amazon ECR uses server-side encryption
- // with Amazon S3-managed encryption keys which encrypts the images in the repository
- // using an AES-256 encryption algorithm. For more information, see Protecting
- // Data Using Server-Side Encryption with Amazon S3-Managed Encryption Keys
- // (SSE-S3) (https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html)
- // in the Amazon Simple Storage Service Console Developer Guide..
- //
- // EncryptionType is a required field
- EncryptionType *string `locationName:"encryptionType" type:"string" required:"true" enum:"EncryptionType"`
-
- // If you use the KMS encryption type, specify the CMK to use for encryption.
- // The alias, key ID, or full ARN of the CMK can be specified. The key must
- // exist in the same Region as the repository. If no key is specified, the default
- // AWS managed CMK for Amazon ECR will be used.
- KmsKey *string `locationName:"kmsKey" min:"1" type:"string"`
-}
-
-// String returns the string representation
-func (s EncryptionConfiguration) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s EncryptionConfiguration) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *EncryptionConfiguration) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "EncryptionConfiguration"}
- if s.EncryptionType == nil {
- invalidParams.Add(request.NewErrParamRequired("EncryptionType"))
- }
- if s.KmsKey != nil && len(*s.KmsKey) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("KmsKey", 1))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetEncryptionType sets the EncryptionType field's value.
-func (s *EncryptionConfiguration) SetEncryptionType(v string) *EncryptionConfiguration {
- s.EncryptionType = &v
- return s
-}
-
-// SetKmsKey sets the KmsKey field's value.
-func (s *EncryptionConfiguration) SetKmsKey(v string) *EncryptionConfiguration {
- s.KmsKey = &v
- return s
-}
-
-type GetAuthorizationTokenInput struct {
- _ struct{} `type:"structure"`
-
- // A list of AWS account IDs that are associated with the registries for which
- // to get AuthorizationData objects. If you do not specify a registry, the default
- // registry is assumed.
- RegistryIds []*string `locationName:"registryIds" min:"1" type:"list"`
-}
-
-// String returns the string representation
-func (s GetAuthorizationTokenInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetAuthorizationTokenInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *GetAuthorizationTokenInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "GetAuthorizationTokenInput"}
- if s.RegistryIds != nil && len(s.RegistryIds) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("RegistryIds", 1))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetRegistryIds sets the RegistryIds field's value.
-func (s *GetAuthorizationTokenInput) SetRegistryIds(v []*string) *GetAuthorizationTokenInput {
- s.RegistryIds = v
- return s
-}
-
-type GetAuthorizationTokenOutput struct {
- _ struct{} `type:"structure"`
-
- // A list of authorization token data objects that correspond to the registryIds
- // values in the request.
- AuthorizationData []*AuthorizationData `locationName:"authorizationData" type:"list"`
-}
-
-// String returns the string representation
-func (s GetAuthorizationTokenOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetAuthorizationTokenOutput) GoString() string {
- return s.String()
-}
-
-// SetAuthorizationData sets the AuthorizationData field's value.
-func (s *GetAuthorizationTokenOutput) SetAuthorizationData(v []*AuthorizationData) *GetAuthorizationTokenOutput {
- s.AuthorizationData = v
- return s
-}
-
-type GetDownloadUrlForLayerInput struct {
- _ struct{} `type:"structure"`
-
- // The digest of the image layer to download.
- //
- // LayerDigest is a required field
- LayerDigest *string `locationName:"layerDigest" type:"string" required:"true"`
-
- // The AWS account ID associated with the registry that contains the image layer
- // to download. If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository that is associated with the image layer to download.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s GetDownloadUrlForLayerInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetDownloadUrlForLayerInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *GetDownloadUrlForLayerInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "GetDownloadUrlForLayerInput"}
- if s.LayerDigest == nil {
- invalidParams.Add(request.NewErrParamRequired("LayerDigest"))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetLayerDigest sets the LayerDigest field's value.
-func (s *GetDownloadUrlForLayerInput) SetLayerDigest(v string) *GetDownloadUrlForLayerInput {
- s.LayerDigest = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *GetDownloadUrlForLayerInput) SetRegistryId(v string) *GetDownloadUrlForLayerInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *GetDownloadUrlForLayerInput) SetRepositoryName(v string) *GetDownloadUrlForLayerInput {
- s.RepositoryName = &v
- return s
-}
-
-type GetDownloadUrlForLayerOutput struct {
- _ struct{} `type:"structure"`
-
- // The pre-signed Amazon S3 download URL for the requested layer.
- DownloadUrl *string `locationName:"downloadUrl" type:"string"`
-
- // The digest of the image layer to download.
- LayerDigest *string `locationName:"layerDigest" type:"string"`
-}
-
-// String returns the string representation
-func (s GetDownloadUrlForLayerOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetDownloadUrlForLayerOutput) GoString() string {
- return s.String()
-}
-
-// SetDownloadUrl sets the DownloadUrl field's value.
-func (s *GetDownloadUrlForLayerOutput) SetDownloadUrl(v string) *GetDownloadUrlForLayerOutput {
- s.DownloadUrl = &v
- return s
-}
-
-// SetLayerDigest sets the LayerDigest field's value.
-func (s *GetDownloadUrlForLayerOutput) SetLayerDigest(v string) *GetDownloadUrlForLayerOutput {
- s.LayerDigest = &v
- return s
-}
-
-type GetLifecyclePolicyInput struct {
- _ struct{} `type:"structure"`
-
- // The AWS account ID associated with the registry that contains the repository.
- // If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s GetLifecyclePolicyInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetLifecyclePolicyInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *GetLifecyclePolicyInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "GetLifecyclePolicyInput"}
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *GetLifecyclePolicyInput) SetRegistryId(v string) *GetLifecyclePolicyInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *GetLifecyclePolicyInput) SetRepositoryName(v string) *GetLifecyclePolicyInput {
- s.RepositoryName = &v
- return s
-}
-
-type GetLifecyclePolicyOutput struct {
- _ struct{} `type:"structure"`
-
- // The time stamp of the last time that the lifecycle policy was run.
- LastEvaluatedAt *time.Time `locationName:"lastEvaluatedAt" type:"timestamp"`
-
- // The JSON lifecycle policy text.
- LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s GetLifecyclePolicyOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetLifecyclePolicyOutput) GoString() string {
- return s.String()
-}
-
-// SetLastEvaluatedAt sets the LastEvaluatedAt field's value.
-func (s *GetLifecyclePolicyOutput) SetLastEvaluatedAt(v time.Time) *GetLifecyclePolicyOutput {
- s.LastEvaluatedAt = &v
- return s
-}
-
-// SetLifecyclePolicyText sets the LifecyclePolicyText field's value.
-func (s *GetLifecyclePolicyOutput) SetLifecyclePolicyText(v string) *GetLifecyclePolicyOutput {
- s.LifecyclePolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *GetLifecyclePolicyOutput) SetRegistryId(v string) *GetLifecyclePolicyOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *GetLifecyclePolicyOutput) SetRepositoryName(v string) *GetLifecyclePolicyOutput {
- s.RepositoryName = &v
- return s
-}
-
-type GetLifecyclePolicyPreviewInput struct {
- _ struct{} `type:"structure"`
-
- // An optional parameter that filters results based on image tag status and
- // all tags, if tagged.
- Filter *LifecyclePolicyPreviewFilter `locationName:"filter" type:"structure"`
-
- // The list of imageIDs to be included.
- ImageIds []*ImageIdentifier `locationName:"imageIds" min:"1" type:"list"`
-
- // The maximum number of repository results returned by GetLifecyclePolicyPreviewRequest
- // in paginated output. When this parameter is used, GetLifecyclePolicyPreviewRequest
- // only returns maxResults results in a single page along with a nextToken response
- // element. The remaining results of the initial request can be seen by sending
- // another GetLifecyclePolicyPreviewRequest request with the returned nextToken
- // value. This value can be between 1 and 1000. If this parameter is not used,
- // then GetLifecyclePolicyPreviewRequest returns up to 100 results and a nextToken
- // value, if applicable. This option cannot be used when you specify images
- // with imageIds.
- MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"`
-
- // The nextToken value returned from a previous paginated GetLifecyclePolicyPreviewRequest
- // request where maxResults was used and the results exceeded the value of that
- // parameter. Pagination continues from the end of the previous results that
- // returned the nextToken value. This value is null when there are no more results
- // to return. This option cannot be used when you specify images with imageIds.
- NextToken *string `locationName:"nextToken" type:"string"`
-
- // The AWS account ID associated with the registry that contains the repository.
- // If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s GetLifecyclePolicyPreviewInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetLifecyclePolicyPreviewInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *GetLifecyclePolicyPreviewInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "GetLifecyclePolicyPreviewInput"}
- if s.ImageIds != nil && len(s.ImageIds) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("ImageIds", 1))
- }
- if s.MaxResults != nil && *s.MaxResults < 1 {
- invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.ImageIds != nil {
- for i, v := range s.ImageIds {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ImageIds", i), err.(request.ErrInvalidParams))
- }
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetFilter sets the Filter field's value.
-func (s *GetLifecyclePolicyPreviewInput) SetFilter(v *LifecyclePolicyPreviewFilter) *GetLifecyclePolicyPreviewInput {
- s.Filter = v
- return s
-}
-
-// SetImageIds sets the ImageIds field's value.
-func (s *GetLifecyclePolicyPreviewInput) SetImageIds(v []*ImageIdentifier) *GetLifecyclePolicyPreviewInput {
- s.ImageIds = v
- return s
-}
-
-// SetMaxResults sets the MaxResults field's value.
-func (s *GetLifecyclePolicyPreviewInput) SetMaxResults(v int64) *GetLifecyclePolicyPreviewInput {
- s.MaxResults = &v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *GetLifecyclePolicyPreviewInput) SetNextToken(v string) *GetLifecyclePolicyPreviewInput {
- s.NextToken = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *GetLifecyclePolicyPreviewInput) SetRegistryId(v string) *GetLifecyclePolicyPreviewInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *GetLifecyclePolicyPreviewInput) SetRepositoryName(v string) *GetLifecyclePolicyPreviewInput {
- s.RepositoryName = &v
- return s
-}
-
-type GetLifecyclePolicyPreviewOutput struct {
- _ struct{} `type:"structure"`
-
- // The JSON lifecycle policy text.
- LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"`
-
- // The nextToken value to include in a future GetLifecyclePolicyPreview request.
- // When the results of a GetLifecyclePolicyPreview request exceed maxResults,
- // this value can be used to retrieve the next page of results. This value is
- // null when there are no more results to return.
- NextToken *string `locationName:"nextToken" type:"string"`
-
- // The results of the lifecycle policy preview request.
- PreviewResults []*LifecyclePolicyPreviewResult `locationName:"previewResults" type:"list"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-
- // The status of the lifecycle policy preview request.
- Status *string `locationName:"status" type:"string" enum:"LifecyclePolicyPreviewStatus"`
-
- // The list of images that is returned as a result of the action.
- Summary *LifecyclePolicyPreviewSummary `locationName:"summary" type:"structure"`
-}
-
-// String returns the string representation
-func (s GetLifecyclePolicyPreviewOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetLifecyclePolicyPreviewOutput) GoString() string {
- return s.String()
-}
-
-// SetLifecyclePolicyText sets the LifecyclePolicyText field's value.
-func (s *GetLifecyclePolicyPreviewOutput) SetLifecyclePolicyText(v string) *GetLifecyclePolicyPreviewOutput {
- s.LifecyclePolicyText = &v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *GetLifecyclePolicyPreviewOutput) SetNextToken(v string) *GetLifecyclePolicyPreviewOutput {
- s.NextToken = &v
- return s
-}
-
-// SetPreviewResults sets the PreviewResults field's value.
-func (s *GetLifecyclePolicyPreviewOutput) SetPreviewResults(v []*LifecyclePolicyPreviewResult) *GetLifecyclePolicyPreviewOutput {
- s.PreviewResults = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *GetLifecyclePolicyPreviewOutput) SetRegistryId(v string) *GetLifecyclePolicyPreviewOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *GetLifecyclePolicyPreviewOutput) SetRepositoryName(v string) *GetLifecyclePolicyPreviewOutput {
- s.RepositoryName = &v
- return s
-}
-
-// SetStatus sets the Status field's value.
-func (s *GetLifecyclePolicyPreviewOutput) SetStatus(v string) *GetLifecyclePolicyPreviewOutput {
- s.Status = &v
- return s
-}
-
-// SetSummary sets the Summary field's value.
-func (s *GetLifecyclePolicyPreviewOutput) SetSummary(v *LifecyclePolicyPreviewSummary) *GetLifecyclePolicyPreviewOutput {
- s.Summary = v
- return s
-}
-
-type GetRepositoryPolicyInput struct {
- _ struct{} `type:"structure"`
-
- // The AWS account ID associated with the registry that contains the repository.
- // If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository with the policy to retrieve.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s GetRepositoryPolicyInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetRepositoryPolicyInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *GetRepositoryPolicyInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "GetRepositoryPolicyInput"}
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *GetRepositoryPolicyInput) SetRegistryId(v string) *GetRepositoryPolicyInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *GetRepositoryPolicyInput) SetRepositoryName(v string) *GetRepositoryPolicyInput {
- s.RepositoryName = &v
- return s
-}
-
-type GetRepositoryPolicyOutput struct {
- _ struct{} `type:"structure"`
-
- // The JSON repository policy text associated with the repository.
- PolicyText *string `locationName:"policyText" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s GetRepositoryPolicyOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetRepositoryPolicyOutput) GoString() string {
- return s.String()
-}
-
-// SetPolicyText sets the PolicyText field's value.
-func (s *GetRepositoryPolicyOutput) SetPolicyText(v string) *GetRepositoryPolicyOutput {
- s.PolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *GetRepositoryPolicyOutput) SetRegistryId(v string) *GetRepositoryPolicyOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *GetRepositoryPolicyOutput) SetRepositoryName(v string) *GetRepositoryPolicyOutput {
- s.RepositoryName = &v
- return s
-}
-
-// An object representing an Amazon ECR image.
-type Image struct {
- _ struct{} `type:"structure"`
-
- // An object containing the image tag and image digest associated with an image.
- ImageId *ImageIdentifier `locationName:"imageId" type:"structure"`
-
- // The image manifest associated with the image.
- ImageManifest *string `locationName:"imageManifest" min:"1" type:"string"`
-
- // The manifest media type of the image.
- ImageManifestMediaType *string `locationName:"imageManifestMediaType" type:"string"`
-
- // The AWS account ID associated with the registry containing the image.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository associated with the image.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s Image) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s Image) GoString() string {
- return s.String()
-}
-
-// SetImageId sets the ImageId field's value.
-func (s *Image) SetImageId(v *ImageIdentifier) *Image {
- s.ImageId = v
- return s
-}
-
-// SetImageManifest sets the ImageManifest field's value.
-func (s *Image) SetImageManifest(v string) *Image {
- s.ImageManifest = &v
- return s
-}
-
-// SetImageManifestMediaType sets the ImageManifestMediaType field's value.
-func (s *Image) SetImageManifestMediaType(v string) *Image {
- s.ImageManifestMediaType = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *Image) SetRegistryId(v string) *Image {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *Image) SetRepositoryName(v string) *Image {
- s.RepositoryName = &v
- return s
-}
-
-// The specified image has already been pushed, and there were no changes to
-// the manifest or image tag after the last push.
-type ImageAlreadyExistsException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s ImageAlreadyExistsException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageAlreadyExistsException) GoString() string {
- return s.String()
-}
-
-func newErrorImageAlreadyExistsException(v protocol.ResponseMetadata) error {
- return &ImageAlreadyExistsException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *ImageAlreadyExistsException) Code() string {
- return "ImageAlreadyExistsException"
-}
-
-// Message returns the exception's message.
-func (s *ImageAlreadyExistsException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *ImageAlreadyExistsException) OrigErr() error {
- return nil
-}
-
-func (s *ImageAlreadyExistsException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *ImageAlreadyExistsException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *ImageAlreadyExistsException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// An object that describes an image returned by a DescribeImages operation.
-type ImageDetail struct {
- _ struct{} `type:"structure"`
-
- // The artifact media type of the image.
- ArtifactMediaType *string `locationName:"artifactMediaType" type:"string"`
-
- // The sha256 digest of the image manifest.
- ImageDigest *string `locationName:"imageDigest" type:"string"`
-
- // The media type of the image manifest.
- ImageManifestMediaType *string `locationName:"imageManifestMediaType" type:"string"`
-
- // The date and time, expressed in standard JavaScript date format, at which
- // the current image was pushed to the repository.
- ImagePushedAt *time.Time `locationName:"imagePushedAt" type:"timestamp"`
-
- // A summary of the last completed image scan.
- ImageScanFindingsSummary *ImageScanFindingsSummary `locationName:"imageScanFindingsSummary" type:"structure"`
-
- // The current state of the scan.
- ImageScanStatus *ImageScanStatus `locationName:"imageScanStatus" type:"structure"`
-
- // The size, in bytes, of the image in the repository.
- //
- // If the image is a manifest list, this will be the max size of all manifests
- // in the list.
- //
- // Beginning with Docker version 1.9, the Docker client compresses image layers
- // before pushing them to a V2 Docker registry. The output of the docker images
- // command shows the uncompressed image size, so it may return a larger image
- // size than the image sizes returned by DescribeImages.
- ImageSizeInBytes *int64 `locationName:"imageSizeInBytes" type:"long"`
-
- // The list of tags associated with this image.
- ImageTags []*string `locationName:"imageTags" type:"list"`
-
- // The AWS account ID associated with the registry to which this image belongs.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository to which this image belongs.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s ImageDetail) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageDetail) GoString() string {
- return s.String()
-}
-
-// SetArtifactMediaType sets the ArtifactMediaType field's value.
-func (s *ImageDetail) SetArtifactMediaType(v string) *ImageDetail {
- s.ArtifactMediaType = &v
- return s
-}
-
-// SetImageDigest sets the ImageDigest field's value.
-func (s *ImageDetail) SetImageDigest(v string) *ImageDetail {
- s.ImageDigest = &v
- return s
-}
-
-// SetImageManifestMediaType sets the ImageManifestMediaType field's value.
-func (s *ImageDetail) SetImageManifestMediaType(v string) *ImageDetail {
- s.ImageManifestMediaType = &v
- return s
-}
-
-// SetImagePushedAt sets the ImagePushedAt field's value.
-func (s *ImageDetail) SetImagePushedAt(v time.Time) *ImageDetail {
- s.ImagePushedAt = &v
- return s
-}
-
-// SetImageScanFindingsSummary sets the ImageScanFindingsSummary field's value.
-func (s *ImageDetail) SetImageScanFindingsSummary(v *ImageScanFindingsSummary) *ImageDetail {
- s.ImageScanFindingsSummary = v
- return s
-}
-
-// SetImageScanStatus sets the ImageScanStatus field's value.
-func (s *ImageDetail) SetImageScanStatus(v *ImageScanStatus) *ImageDetail {
- s.ImageScanStatus = v
- return s
-}
-
-// SetImageSizeInBytes sets the ImageSizeInBytes field's value.
-func (s *ImageDetail) SetImageSizeInBytes(v int64) *ImageDetail {
- s.ImageSizeInBytes = &v
- return s
-}
-
-// SetImageTags sets the ImageTags field's value.
-func (s *ImageDetail) SetImageTags(v []*string) *ImageDetail {
- s.ImageTags = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *ImageDetail) SetRegistryId(v string) *ImageDetail {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *ImageDetail) SetRepositoryName(v string) *ImageDetail {
- s.RepositoryName = &v
- return s
-}
-
-// The specified image digest does not match the digest that Amazon ECR calculated
-// for the image.
-type ImageDigestDoesNotMatchException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s ImageDigestDoesNotMatchException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageDigestDoesNotMatchException) GoString() string {
- return s.String()
-}
-
-func newErrorImageDigestDoesNotMatchException(v protocol.ResponseMetadata) error {
- return &ImageDigestDoesNotMatchException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *ImageDigestDoesNotMatchException) Code() string {
- return "ImageDigestDoesNotMatchException"
-}
-
-// Message returns the exception's message.
-func (s *ImageDigestDoesNotMatchException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *ImageDigestDoesNotMatchException) OrigErr() error {
- return nil
-}
-
-func (s *ImageDigestDoesNotMatchException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *ImageDigestDoesNotMatchException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *ImageDigestDoesNotMatchException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// An object representing an Amazon ECR image failure.
-type ImageFailure struct {
- _ struct{} `type:"structure"`
-
- // The code associated with the failure.
- FailureCode *string `locationName:"failureCode" type:"string" enum:"ImageFailureCode"`
-
- // The reason for the failure.
- FailureReason *string `locationName:"failureReason" type:"string"`
-
- // The image ID associated with the failure.
- ImageId *ImageIdentifier `locationName:"imageId" type:"structure"`
-}
-
-// String returns the string representation
-func (s ImageFailure) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageFailure) GoString() string {
- return s.String()
-}
-
-// SetFailureCode sets the FailureCode field's value.
-func (s *ImageFailure) SetFailureCode(v string) *ImageFailure {
- s.FailureCode = &v
- return s
-}
-
-// SetFailureReason sets the FailureReason field's value.
-func (s *ImageFailure) SetFailureReason(v string) *ImageFailure {
- s.FailureReason = &v
- return s
-}
-
-// SetImageId sets the ImageId field's value.
-func (s *ImageFailure) SetImageId(v *ImageIdentifier) *ImageFailure {
- s.ImageId = v
- return s
-}
-
-// An object with identifying information for an Amazon ECR image.
-type ImageIdentifier struct {
- _ struct{} `type:"structure"`
-
- // The sha256 digest of the image manifest.
- ImageDigest *string `locationName:"imageDigest" type:"string"`
-
- // The tag used for the image.
- ImageTag *string `locationName:"imageTag" min:"1" type:"string"`
-}
-
-// String returns the string representation
-func (s ImageIdentifier) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageIdentifier) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *ImageIdentifier) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "ImageIdentifier"}
- if s.ImageTag != nil && len(*s.ImageTag) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("ImageTag", 1))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetImageDigest sets the ImageDigest field's value.
-func (s *ImageIdentifier) SetImageDigest(v string) *ImageIdentifier {
- s.ImageDigest = &v
- return s
-}
-
-// SetImageTag sets the ImageTag field's value.
-func (s *ImageIdentifier) SetImageTag(v string) *ImageIdentifier {
- s.ImageTag = &v
- return s
-}
-
-// The image requested does not exist in the specified repository.
-type ImageNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s ImageNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorImageNotFoundException(v protocol.ResponseMetadata) error {
- return &ImageNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *ImageNotFoundException) Code() string {
- return "ImageNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *ImageNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *ImageNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *ImageNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *ImageNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *ImageNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// Contains information about an image scan finding.
-type ImageScanFinding struct {
- _ struct{} `type:"structure"`
-
- // A collection of attributes of the host from which the finding is generated.
- Attributes []*Attribute `locationName:"attributes" type:"list"`
-
- // The description of the finding.
- Description *string `locationName:"description" type:"string"`
-
- // The name associated with the finding, usually a CVE number.
- Name *string `locationName:"name" type:"string"`
-
- // The finding severity.
- Severity *string `locationName:"severity" type:"string" enum:"FindingSeverity"`
-
- // A link containing additional details about the security vulnerability.
- Uri *string `locationName:"uri" type:"string"`
-}
-
-// String returns the string representation
-func (s ImageScanFinding) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageScanFinding) GoString() string {
- return s.String()
-}
-
-// SetAttributes sets the Attributes field's value.
-func (s *ImageScanFinding) SetAttributes(v []*Attribute) *ImageScanFinding {
- s.Attributes = v
- return s
-}
-
-// SetDescription sets the Description field's value.
-func (s *ImageScanFinding) SetDescription(v string) *ImageScanFinding {
- s.Description = &v
- return s
-}
-
-// SetName sets the Name field's value.
-func (s *ImageScanFinding) SetName(v string) *ImageScanFinding {
- s.Name = &v
- return s
-}
-
-// SetSeverity sets the Severity field's value.
-func (s *ImageScanFinding) SetSeverity(v string) *ImageScanFinding {
- s.Severity = &v
- return s
-}
-
-// SetUri sets the Uri field's value.
-func (s *ImageScanFinding) SetUri(v string) *ImageScanFinding {
- s.Uri = &v
- return s
-}
-
-// The details of an image scan.
-type ImageScanFindings struct {
- _ struct{} `type:"structure"`
-
- // The image vulnerability counts, sorted by severity.
- FindingSeverityCounts map[string]*int64 `locationName:"findingSeverityCounts" type:"map"`
-
- // The findings from the image scan.
- Findings []*ImageScanFinding `locationName:"findings" type:"list"`
-
- // The time of the last completed image scan.
- ImageScanCompletedAt *time.Time `locationName:"imageScanCompletedAt" type:"timestamp"`
-
- // The time when the vulnerability data was last scanned.
- VulnerabilitySourceUpdatedAt *time.Time `locationName:"vulnerabilitySourceUpdatedAt" type:"timestamp"`
-}
-
-// String returns the string representation
-func (s ImageScanFindings) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageScanFindings) GoString() string {
- return s.String()
-}
-
-// SetFindingSeverityCounts sets the FindingSeverityCounts field's value.
-func (s *ImageScanFindings) SetFindingSeverityCounts(v map[string]*int64) *ImageScanFindings {
- s.FindingSeverityCounts = v
- return s
-}
-
-// SetFindings sets the Findings field's value.
-func (s *ImageScanFindings) SetFindings(v []*ImageScanFinding) *ImageScanFindings {
- s.Findings = v
- return s
-}
-
-// SetImageScanCompletedAt sets the ImageScanCompletedAt field's value.
-func (s *ImageScanFindings) SetImageScanCompletedAt(v time.Time) *ImageScanFindings {
- s.ImageScanCompletedAt = &v
- return s
-}
-
-// SetVulnerabilitySourceUpdatedAt sets the VulnerabilitySourceUpdatedAt field's value.
-func (s *ImageScanFindings) SetVulnerabilitySourceUpdatedAt(v time.Time) *ImageScanFindings {
- s.VulnerabilitySourceUpdatedAt = &v
- return s
-}
-
-// A summary of the last completed image scan.
-type ImageScanFindingsSummary struct {
- _ struct{} `type:"structure"`
-
- // The image vulnerability counts, sorted by severity.
- FindingSeverityCounts map[string]*int64 `locationName:"findingSeverityCounts" type:"map"`
-
- // The time of the last completed image scan.
- ImageScanCompletedAt *time.Time `locationName:"imageScanCompletedAt" type:"timestamp"`
-
- // The time when the vulnerability data was last scanned.
- VulnerabilitySourceUpdatedAt *time.Time `locationName:"vulnerabilitySourceUpdatedAt" type:"timestamp"`
-}
-
-// String returns the string representation
-func (s ImageScanFindingsSummary) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageScanFindingsSummary) GoString() string {
- return s.String()
-}
-
-// SetFindingSeverityCounts sets the FindingSeverityCounts field's value.
-func (s *ImageScanFindingsSummary) SetFindingSeverityCounts(v map[string]*int64) *ImageScanFindingsSummary {
- s.FindingSeverityCounts = v
- return s
-}
-
-// SetImageScanCompletedAt sets the ImageScanCompletedAt field's value.
-func (s *ImageScanFindingsSummary) SetImageScanCompletedAt(v time.Time) *ImageScanFindingsSummary {
- s.ImageScanCompletedAt = &v
- return s
-}
-
-// SetVulnerabilitySourceUpdatedAt sets the VulnerabilitySourceUpdatedAt field's value.
-func (s *ImageScanFindingsSummary) SetVulnerabilitySourceUpdatedAt(v time.Time) *ImageScanFindingsSummary {
- s.VulnerabilitySourceUpdatedAt = &v
- return s
-}
-
-// The current status of an image scan.
-type ImageScanStatus struct {
- _ struct{} `type:"structure"`
-
- // The description of the image scan status.
- Description *string `locationName:"description" type:"string"`
-
- // The current state of an image scan.
- Status *string `locationName:"status" type:"string" enum:"ScanStatus"`
-}
-
-// String returns the string representation
-func (s ImageScanStatus) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageScanStatus) GoString() string {
- return s.String()
-}
-
-// SetDescription sets the Description field's value.
-func (s *ImageScanStatus) SetDescription(v string) *ImageScanStatus {
- s.Description = &v
- return s
-}
-
-// SetStatus sets the Status field's value.
-func (s *ImageScanStatus) SetStatus(v string) *ImageScanStatus {
- s.Status = &v
- return s
-}
-
-// The image scanning configuration for a repository.
-type ImageScanningConfiguration struct {
- _ struct{} `type:"structure"`
-
- // The setting that determines whether images are scanned after being pushed
- // to a repository. If set to true, images will be scanned after being pushed.
- // If this parameter is not specified, it will default to false and images will
- // not be scanned unless a scan is manually started with the StartImageScan
- // API.
- ScanOnPush *bool `locationName:"scanOnPush" type:"boolean"`
-}
-
-// String returns the string representation
-func (s ImageScanningConfiguration) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageScanningConfiguration) GoString() string {
- return s.String()
-}
-
-// SetScanOnPush sets the ScanOnPush field's value.
-func (s *ImageScanningConfiguration) SetScanOnPush(v bool) *ImageScanningConfiguration {
- s.ScanOnPush = &v
- return s
-}
-
-// The specified image is tagged with a tag that already exists. The repository
-// is configured for tag immutability.
-type ImageTagAlreadyExistsException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s ImageTagAlreadyExistsException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ImageTagAlreadyExistsException) GoString() string {
- return s.String()
-}
-
-func newErrorImageTagAlreadyExistsException(v protocol.ResponseMetadata) error {
- return &ImageTagAlreadyExistsException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *ImageTagAlreadyExistsException) Code() string {
- return "ImageTagAlreadyExistsException"
-}
-
-// Message returns the exception's message.
-func (s *ImageTagAlreadyExistsException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *ImageTagAlreadyExistsException) OrigErr() error {
- return nil
-}
-
-func (s *ImageTagAlreadyExistsException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *ImageTagAlreadyExistsException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *ImageTagAlreadyExistsException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-type InitiateLayerUploadInput struct {
- _ struct{} `type:"structure"`
-
- // The AWS account ID associated with the registry to which you intend to upload
- // layers. If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository to which you intend to upload layers.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s InitiateLayerUploadInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s InitiateLayerUploadInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *InitiateLayerUploadInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "InitiateLayerUploadInput"}
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *InitiateLayerUploadInput) SetRegistryId(v string) *InitiateLayerUploadInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *InitiateLayerUploadInput) SetRepositoryName(v string) *InitiateLayerUploadInput {
- s.RepositoryName = &v
- return s
-}
-
-type InitiateLayerUploadOutput struct {
- _ struct{} `type:"structure"`
-
- // The size, in bytes, that Amazon ECR expects future layer part uploads to
- // be.
- PartSize *int64 `locationName:"partSize" type:"long"`
-
- // The upload ID for the layer upload. This parameter is passed to further UploadLayerPart
- // and CompleteLayerUpload operations.
- UploadId *string `locationName:"uploadId" type:"string"`
-}
-
-// String returns the string representation
-func (s InitiateLayerUploadOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s InitiateLayerUploadOutput) GoString() string {
- return s.String()
-}
-
-// SetPartSize sets the PartSize field's value.
-func (s *InitiateLayerUploadOutput) SetPartSize(v int64) *InitiateLayerUploadOutput {
- s.PartSize = &v
- return s
-}
-
-// SetUploadId sets the UploadId field's value.
-func (s *InitiateLayerUploadOutput) SetUploadId(v string) *InitiateLayerUploadOutput {
- s.UploadId = &v
- return s
-}
-
-// The layer digest calculation performed by Amazon ECR upon receipt of the
-// image layer does not match the digest specified.
-type InvalidLayerException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s InvalidLayerException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s InvalidLayerException) GoString() string {
- return s.String()
-}
-
-func newErrorInvalidLayerException(v protocol.ResponseMetadata) error {
- return &InvalidLayerException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *InvalidLayerException) Code() string {
- return "InvalidLayerException"
-}
-
-// Message returns the exception's message.
-func (s *InvalidLayerException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *InvalidLayerException) OrigErr() error {
- return nil
-}
-
-func (s *InvalidLayerException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *InvalidLayerException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *InvalidLayerException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The layer part size is not valid, or the first byte specified is not consecutive
-// to the last byte of a previous layer part upload.
-type InvalidLayerPartException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The last valid byte received from the layer part upload that is associated
- // with the exception.
- LastValidByteReceived *int64 `locationName:"lastValidByteReceived" type:"long"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-
- // The registry ID associated with the exception.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the exception.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-
- // The upload ID associated with the exception.
- UploadId *string `locationName:"uploadId" type:"string"`
-}
-
-// String returns the string representation
-func (s InvalidLayerPartException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s InvalidLayerPartException) GoString() string {
- return s.String()
-}
-
-func newErrorInvalidLayerPartException(v protocol.ResponseMetadata) error {
- return &InvalidLayerPartException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *InvalidLayerPartException) Code() string {
- return "InvalidLayerPartException"
-}
-
-// Message returns the exception's message.
-func (s *InvalidLayerPartException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *InvalidLayerPartException) OrigErr() error {
- return nil
-}
-
-func (s *InvalidLayerPartException) Error() string {
- return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *InvalidLayerPartException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *InvalidLayerPartException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The specified parameter is invalid. Review the available parameters for the
-// API request.
-type InvalidParameterException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s InvalidParameterException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s InvalidParameterException) GoString() string {
- return s.String()
-}
-
-func newErrorInvalidParameterException(v protocol.ResponseMetadata) error {
- return &InvalidParameterException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *InvalidParameterException) Code() string {
- return "InvalidParameterException"
-}
-
-// Message returns the exception's message.
-func (s *InvalidParameterException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *InvalidParameterException) OrigErr() error {
- return nil
-}
-
-func (s *InvalidParameterException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *InvalidParameterException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *InvalidParameterException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// An invalid parameter has been specified. Tag keys can have a maximum character
-// length of 128 characters, and tag values can have a maximum length of 256
-// characters.
-type InvalidTagParameterException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s InvalidTagParameterException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s InvalidTagParameterException) GoString() string {
- return s.String()
-}
-
-func newErrorInvalidTagParameterException(v protocol.ResponseMetadata) error {
- return &InvalidTagParameterException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *InvalidTagParameterException) Code() string {
- return "InvalidTagParameterException"
-}
-
-// Message returns the exception's message.
-func (s *InvalidTagParameterException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *InvalidTagParameterException) OrigErr() error {
- return nil
-}
-
-func (s *InvalidTagParameterException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *InvalidTagParameterException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *InvalidTagParameterException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The operation failed due to a KMS exception.
-type KmsException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error code returned by AWS KMS.
- KmsError *string `locationName:"kmsError" type:"string"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s KmsException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s KmsException) GoString() string {
- return s.String()
-}
-
-func newErrorKmsException(v protocol.ResponseMetadata) error {
- return &KmsException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *KmsException) Code() string {
- return "KmsException"
-}
-
-// Message returns the exception's message.
-func (s *KmsException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *KmsException) OrigErr() error {
- return nil
-}
-
-func (s *KmsException) Error() string {
- return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *KmsException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *KmsException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// An object representing an Amazon ECR image layer.
-type Layer struct {
- _ struct{} `type:"structure"`
-
- // The availability status of the image layer.
- LayerAvailability *string `locationName:"layerAvailability" type:"string" enum:"LayerAvailability"`
-
- // The sha256 digest of the image layer.
- LayerDigest *string `locationName:"layerDigest" type:"string"`
-
- // The size, in bytes, of the image layer.
- LayerSize *int64 `locationName:"layerSize" type:"long"`
-
- // The media type of the layer, such as application/vnd.docker.image.rootfs.diff.tar.gzip
- // or application/vnd.oci.image.layer.v1.tar+gzip.
- MediaType *string `locationName:"mediaType" type:"string"`
-}
-
-// String returns the string representation
-func (s Layer) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s Layer) GoString() string {
- return s.String()
-}
-
-// SetLayerAvailability sets the LayerAvailability field's value.
-func (s *Layer) SetLayerAvailability(v string) *Layer {
- s.LayerAvailability = &v
- return s
-}
-
-// SetLayerDigest sets the LayerDigest field's value.
-func (s *Layer) SetLayerDigest(v string) *Layer {
- s.LayerDigest = &v
- return s
-}
-
-// SetLayerSize sets the LayerSize field's value.
-func (s *Layer) SetLayerSize(v int64) *Layer {
- s.LayerSize = &v
- return s
-}
-
-// SetMediaType sets the MediaType field's value.
-func (s *Layer) SetMediaType(v string) *Layer {
- s.MediaType = &v
- return s
-}
-
-// The image layer already exists in the associated repository.
-type LayerAlreadyExistsException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s LayerAlreadyExistsException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LayerAlreadyExistsException) GoString() string {
- return s.String()
-}
-
-func newErrorLayerAlreadyExistsException(v protocol.ResponseMetadata) error {
- return &LayerAlreadyExistsException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *LayerAlreadyExistsException) Code() string {
- return "LayerAlreadyExistsException"
-}
-
-// Message returns the exception's message.
-func (s *LayerAlreadyExistsException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *LayerAlreadyExistsException) OrigErr() error {
- return nil
-}
-
-func (s *LayerAlreadyExistsException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *LayerAlreadyExistsException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *LayerAlreadyExistsException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// An object representing an Amazon ECR image layer failure.
-type LayerFailure struct {
- _ struct{} `type:"structure"`
-
- // The failure code associated with the failure.
- FailureCode *string `locationName:"failureCode" type:"string" enum:"LayerFailureCode"`
-
- // The reason for the failure.
- FailureReason *string `locationName:"failureReason" type:"string"`
-
- // The layer digest associated with the failure.
- LayerDigest *string `locationName:"layerDigest" type:"string"`
-}
-
-// String returns the string representation
-func (s LayerFailure) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LayerFailure) GoString() string {
- return s.String()
-}
-
-// SetFailureCode sets the FailureCode field's value.
-func (s *LayerFailure) SetFailureCode(v string) *LayerFailure {
- s.FailureCode = &v
- return s
-}
-
-// SetFailureReason sets the FailureReason field's value.
-func (s *LayerFailure) SetFailureReason(v string) *LayerFailure {
- s.FailureReason = &v
- return s
-}
-
-// SetLayerDigest sets the LayerDigest field's value.
-func (s *LayerFailure) SetLayerDigest(v string) *LayerFailure {
- s.LayerDigest = &v
- return s
-}
-
-// The specified layer is not available because it is not associated with an
-// image. Unassociated image layers may be cleaned up at any time.
-type LayerInaccessibleException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s LayerInaccessibleException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LayerInaccessibleException) GoString() string {
- return s.String()
-}
-
-func newErrorLayerInaccessibleException(v protocol.ResponseMetadata) error {
- return &LayerInaccessibleException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *LayerInaccessibleException) Code() string {
- return "LayerInaccessibleException"
-}
-
-// Message returns the exception's message.
-func (s *LayerInaccessibleException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *LayerInaccessibleException) OrigErr() error {
- return nil
-}
-
-func (s *LayerInaccessibleException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *LayerInaccessibleException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *LayerInaccessibleException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// Layer parts must be at least 5 MiB in size.
-type LayerPartTooSmallException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s LayerPartTooSmallException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LayerPartTooSmallException) GoString() string {
- return s.String()
-}
-
-func newErrorLayerPartTooSmallException(v protocol.ResponseMetadata) error {
- return &LayerPartTooSmallException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *LayerPartTooSmallException) Code() string {
- return "LayerPartTooSmallException"
-}
-
-// Message returns the exception's message.
-func (s *LayerPartTooSmallException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *LayerPartTooSmallException) OrigErr() error {
- return nil
-}
-
-func (s *LayerPartTooSmallException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *LayerPartTooSmallException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *LayerPartTooSmallException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The specified layers could not be found, or the specified layer is not valid
-// for this repository.
-type LayersNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s LayersNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LayersNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorLayersNotFoundException(v protocol.ResponseMetadata) error {
- return &LayersNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *LayersNotFoundException) Code() string {
- return "LayersNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *LayersNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *LayersNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *LayersNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *LayersNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *LayersNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The lifecycle policy could not be found, and no policy is set to the repository.
-type LifecyclePolicyNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s LifecyclePolicyNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LifecyclePolicyNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorLifecyclePolicyNotFoundException(v protocol.ResponseMetadata) error {
- return &LifecyclePolicyNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *LifecyclePolicyNotFoundException) Code() string {
- return "LifecyclePolicyNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *LifecyclePolicyNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *LifecyclePolicyNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *LifecyclePolicyNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *LifecyclePolicyNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *LifecyclePolicyNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The filter for the lifecycle policy preview.
-type LifecyclePolicyPreviewFilter struct {
- _ struct{} `type:"structure"`
-
- // The tag status of the image.
- TagStatus *string `locationName:"tagStatus" type:"string" enum:"TagStatus"`
-}
-
-// String returns the string representation
-func (s LifecyclePolicyPreviewFilter) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LifecyclePolicyPreviewFilter) GoString() string {
- return s.String()
-}
-
-// SetTagStatus sets the TagStatus field's value.
-func (s *LifecyclePolicyPreviewFilter) SetTagStatus(v string) *LifecyclePolicyPreviewFilter {
- s.TagStatus = &v
- return s
-}
-
-// The previous lifecycle policy preview request has not completed. Wait and
-// try again.
-type LifecyclePolicyPreviewInProgressException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s LifecyclePolicyPreviewInProgressException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LifecyclePolicyPreviewInProgressException) GoString() string {
- return s.String()
-}
-
-func newErrorLifecyclePolicyPreviewInProgressException(v protocol.ResponseMetadata) error {
- return &LifecyclePolicyPreviewInProgressException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *LifecyclePolicyPreviewInProgressException) Code() string {
- return "LifecyclePolicyPreviewInProgressException"
-}
-
-// Message returns the exception's message.
-func (s *LifecyclePolicyPreviewInProgressException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *LifecyclePolicyPreviewInProgressException) OrigErr() error {
- return nil
-}
-
-func (s *LifecyclePolicyPreviewInProgressException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *LifecyclePolicyPreviewInProgressException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *LifecyclePolicyPreviewInProgressException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// There is no dry run for this repository.
-type LifecyclePolicyPreviewNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s LifecyclePolicyPreviewNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LifecyclePolicyPreviewNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorLifecyclePolicyPreviewNotFoundException(v protocol.ResponseMetadata) error {
- return &LifecyclePolicyPreviewNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *LifecyclePolicyPreviewNotFoundException) Code() string {
- return "LifecyclePolicyPreviewNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *LifecyclePolicyPreviewNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *LifecyclePolicyPreviewNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *LifecyclePolicyPreviewNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *LifecyclePolicyPreviewNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *LifecyclePolicyPreviewNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The result of the lifecycle policy preview.
-type LifecyclePolicyPreviewResult struct {
- _ struct{} `type:"structure"`
-
- // The type of action to be taken.
- Action *LifecyclePolicyRuleAction `locationName:"action" type:"structure"`
-
- // The priority of the applied rule.
- AppliedRulePriority *int64 `locationName:"appliedRulePriority" min:"1" type:"integer"`
-
- // The sha256 digest of the image manifest.
- ImageDigest *string `locationName:"imageDigest" type:"string"`
-
- // The date and time, expressed in standard JavaScript date format, at which
- // the current image was pushed to the repository.
- ImagePushedAt *time.Time `locationName:"imagePushedAt" type:"timestamp"`
-
- // The list of tags associated with this image.
- ImageTags []*string `locationName:"imageTags" type:"list"`
-}
-
-// String returns the string representation
-func (s LifecyclePolicyPreviewResult) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LifecyclePolicyPreviewResult) GoString() string {
- return s.String()
-}
-
-// SetAction sets the Action field's value.
-func (s *LifecyclePolicyPreviewResult) SetAction(v *LifecyclePolicyRuleAction) *LifecyclePolicyPreviewResult {
- s.Action = v
- return s
-}
-
-// SetAppliedRulePriority sets the AppliedRulePriority field's value.
-func (s *LifecyclePolicyPreviewResult) SetAppliedRulePriority(v int64) *LifecyclePolicyPreviewResult {
- s.AppliedRulePriority = &v
- return s
-}
-
-// SetImageDigest sets the ImageDigest field's value.
-func (s *LifecyclePolicyPreviewResult) SetImageDigest(v string) *LifecyclePolicyPreviewResult {
- s.ImageDigest = &v
- return s
-}
-
-// SetImagePushedAt sets the ImagePushedAt field's value.
-func (s *LifecyclePolicyPreviewResult) SetImagePushedAt(v time.Time) *LifecyclePolicyPreviewResult {
- s.ImagePushedAt = &v
- return s
-}
-
-// SetImageTags sets the ImageTags field's value.
-func (s *LifecyclePolicyPreviewResult) SetImageTags(v []*string) *LifecyclePolicyPreviewResult {
- s.ImageTags = v
- return s
-}
-
-// The summary of the lifecycle policy preview request.
-type LifecyclePolicyPreviewSummary struct {
- _ struct{} `type:"structure"`
-
- // The number of expiring images.
- ExpiringImageTotalCount *int64 `locationName:"expiringImageTotalCount" type:"integer"`
-}
-
-// String returns the string representation
-func (s LifecyclePolicyPreviewSummary) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LifecyclePolicyPreviewSummary) GoString() string {
- return s.String()
-}
-
-// SetExpiringImageTotalCount sets the ExpiringImageTotalCount field's value.
-func (s *LifecyclePolicyPreviewSummary) SetExpiringImageTotalCount(v int64) *LifecyclePolicyPreviewSummary {
- s.ExpiringImageTotalCount = &v
- return s
-}
-
-// The type of action to be taken.
-type LifecyclePolicyRuleAction struct {
- _ struct{} `type:"structure"`
-
- // The type of action to be taken.
- Type *string `locationName:"type" type:"string" enum:"ImageActionType"`
-}
-
-// String returns the string representation
-func (s LifecyclePolicyRuleAction) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LifecyclePolicyRuleAction) GoString() string {
- return s.String()
-}
-
-// SetType sets the Type field's value.
-func (s *LifecyclePolicyRuleAction) SetType(v string) *LifecyclePolicyRuleAction {
- s.Type = &v
- return s
-}
-
-// The operation did not succeed because it would have exceeded a service limit
-// for your account. For more information, see Amazon ECR Service Quotas (https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html)
-// in the Amazon Elastic Container Registry User Guide.
-type LimitExceededException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s LimitExceededException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s LimitExceededException) GoString() string {
- return s.String()
-}
-
-func newErrorLimitExceededException(v protocol.ResponseMetadata) error {
- return &LimitExceededException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *LimitExceededException) Code() string {
- return "LimitExceededException"
-}
-
-// Message returns the exception's message.
-func (s *LimitExceededException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *LimitExceededException) OrigErr() error {
- return nil
-}
-
-func (s *LimitExceededException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *LimitExceededException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *LimitExceededException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// An object representing a filter on a ListImages operation.
-type ListImagesFilter struct {
- _ struct{} `type:"structure"`
-
- // The tag status with which to filter your ListImages results. You can filter
- // results based on whether they are TAGGED or UNTAGGED.
- TagStatus *string `locationName:"tagStatus" type:"string" enum:"TagStatus"`
-}
-
-// String returns the string representation
-func (s ListImagesFilter) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ListImagesFilter) GoString() string {
- return s.String()
-}
-
-// SetTagStatus sets the TagStatus field's value.
-func (s *ListImagesFilter) SetTagStatus(v string) *ListImagesFilter {
- s.TagStatus = &v
- return s
-}
-
-type ListImagesInput struct {
- _ struct{} `type:"structure"`
-
- // The filter key and value with which to filter your ListImages results.
- Filter *ListImagesFilter `locationName:"filter" type:"structure"`
-
- // The maximum number of image results returned by ListImages in paginated output.
- // When this parameter is used, ListImages only returns maxResults results in
- // a single page along with a nextToken response element. The remaining results
- // of the initial request can be seen by sending another ListImages request
- // with the returned nextToken value. This value can be between 1 and 1000.
- // If this parameter is not used, then ListImages returns up to 100 results
- // and a nextToken value, if applicable.
- MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"`
-
- // The nextToken value returned from a previous paginated ListImages request
- // where maxResults was used and the results exceeded the value of that parameter.
- // Pagination continues from the end of the previous results that returned the
- // nextToken value. This value is null when there are no more results to return.
- //
- // This token should be treated as an opaque identifier that is only used to
- // retrieve the next items in a list and not for other programmatic purposes.
- NextToken *string `locationName:"nextToken" type:"string"`
-
- // The AWS account ID associated with the registry that contains the repository
- // in which to list images. If you do not specify a registry, the default registry
- // is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository with image IDs to be listed.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s ListImagesInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ListImagesInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *ListImagesInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "ListImagesInput"}
- if s.MaxResults != nil && *s.MaxResults < 1 {
- invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetFilter sets the Filter field's value.
-func (s *ListImagesInput) SetFilter(v *ListImagesFilter) *ListImagesInput {
- s.Filter = v
- return s
-}
-
-// SetMaxResults sets the MaxResults field's value.
-func (s *ListImagesInput) SetMaxResults(v int64) *ListImagesInput {
- s.MaxResults = &v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *ListImagesInput) SetNextToken(v string) *ListImagesInput {
- s.NextToken = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *ListImagesInput) SetRegistryId(v string) *ListImagesInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *ListImagesInput) SetRepositoryName(v string) *ListImagesInput {
- s.RepositoryName = &v
- return s
-}
-
-type ListImagesOutput struct {
- _ struct{} `type:"structure"`
-
- // The list of image IDs for the requested repository.
- ImageIds []*ImageIdentifier `locationName:"imageIds" min:"1" type:"list"`
-
- // The nextToken value to include in a future ListImages request. When the results
- // of a ListImages request exceed maxResults, this value can be used to retrieve
- // the next page of results. This value is null when there are no more results
- // to return.
- NextToken *string `locationName:"nextToken" type:"string"`
-}
-
-// String returns the string representation
-func (s ListImagesOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ListImagesOutput) GoString() string {
- return s.String()
-}
-
-// SetImageIds sets the ImageIds field's value.
-func (s *ListImagesOutput) SetImageIds(v []*ImageIdentifier) *ListImagesOutput {
- s.ImageIds = v
- return s
-}
-
-// SetNextToken sets the NextToken field's value.
-func (s *ListImagesOutput) SetNextToken(v string) *ListImagesOutput {
- s.NextToken = &v
- return s
-}
-
-type ListTagsForResourceInput struct {
- _ struct{} `type:"structure"`
-
- // The Amazon Resource Name (ARN) that identifies the resource for which to
- // list the tags. Currently, the only supported resource is an Amazon ECR repository.
- //
- // ResourceArn is a required field
- ResourceArn *string `locationName:"resourceArn" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s ListTagsForResourceInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ListTagsForResourceInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *ListTagsForResourceInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"}
- if s.ResourceArn == nil {
- invalidParams.Add(request.NewErrParamRequired("ResourceArn"))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetResourceArn sets the ResourceArn field's value.
-func (s *ListTagsForResourceInput) SetResourceArn(v string) *ListTagsForResourceInput {
- s.ResourceArn = &v
- return s
-}
-
-type ListTagsForResourceOutput struct {
- _ struct{} `type:"structure"`
-
- // The tags for the resource.
- Tags []*Tag `locationName:"tags" type:"list"`
-}
-
-// String returns the string representation
-func (s ListTagsForResourceOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ListTagsForResourceOutput) GoString() string {
- return s.String()
-}
-
-// SetTags sets the Tags field's value.
-func (s *ListTagsForResourceOutput) SetTags(v []*Tag) *ListTagsForResourceOutput {
- s.Tags = v
- return s
-}
-
-type PutImageInput struct {
- _ struct{} `type:"structure"`
-
- // The image digest of the image manifest corresponding to the image.
- ImageDigest *string `locationName:"imageDigest" type:"string"`
-
- // The image manifest corresponding to the image to be uploaded.
- //
- // ImageManifest is a required field
- ImageManifest *string `locationName:"imageManifest" min:"1" type:"string" required:"true"`
-
- // The media type of the image manifest. If you push an image manifest that
- // does not contain the mediaType field, you must specify the imageManifestMediaType
- // in the request.
- ImageManifestMediaType *string `locationName:"imageManifestMediaType" type:"string"`
-
- // The tag to associate with the image. This parameter is required for images
- // that use the Docker Image Manifest V2 Schema 2 or Open Container Initiative
- // (OCI) formats.
- ImageTag *string `locationName:"imageTag" min:"1" type:"string"`
-
- // The AWS account ID associated with the registry that contains the repository
- // in which to put the image. If you do not specify a registry, the default
- // registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository in which to put the image.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s PutImageInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PutImageInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *PutImageInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "PutImageInput"}
- if s.ImageManifest == nil {
- invalidParams.Add(request.NewErrParamRequired("ImageManifest"))
- }
- if s.ImageManifest != nil && len(*s.ImageManifest) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("ImageManifest", 1))
- }
- if s.ImageTag != nil && len(*s.ImageTag) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("ImageTag", 1))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetImageDigest sets the ImageDigest field's value.
-func (s *PutImageInput) SetImageDigest(v string) *PutImageInput {
- s.ImageDigest = &v
- return s
-}
-
-// SetImageManifest sets the ImageManifest field's value.
-func (s *PutImageInput) SetImageManifest(v string) *PutImageInput {
- s.ImageManifest = &v
- return s
-}
-
-// SetImageManifestMediaType sets the ImageManifestMediaType field's value.
-func (s *PutImageInput) SetImageManifestMediaType(v string) *PutImageInput {
- s.ImageManifestMediaType = &v
- return s
-}
-
-// SetImageTag sets the ImageTag field's value.
-func (s *PutImageInput) SetImageTag(v string) *PutImageInput {
- s.ImageTag = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *PutImageInput) SetRegistryId(v string) *PutImageInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *PutImageInput) SetRepositoryName(v string) *PutImageInput {
- s.RepositoryName = &v
- return s
-}
-
-type PutImageOutput struct {
- _ struct{} `type:"structure"`
-
- // Details of the image uploaded.
- Image *Image `locationName:"image" type:"structure"`
-}
-
-// String returns the string representation
-func (s PutImageOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PutImageOutput) GoString() string {
- return s.String()
-}
-
-// SetImage sets the Image field's value.
-func (s *PutImageOutput) SetImage(v *Image) *PutImageOutput {
- s.Image = v
- return s
-}
-
-type PutImageScanningConfigurationInput struct {
- _ struct{} `type:"structure"`
-
- // The image scanning configuration for the repository. This setting determines
- // whether images are scanned for known vulnerabilities after being pushed to
- // the repository.
- //
- // ImageScanningConfiguration is a required field
- ImageScanningConfiguration *ImageScanningConfiguration `locationName:"imageScanningConfiguration" type:"structure" required:"true"`
-
- // The AWS account ID associated with the registry that contains the repository
- // in which to update the image scanning configuration setting. If you do not
- // specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository in which to update the image scanning configuration
- // setting.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s PutImageScanningConfigurationInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PutImageScanningConfigurationInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *PutImageScanningConfigurationInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "PutImageScanningConfigurationInput"}
- if s.ImageScanningConfiguration == nil {
- invalidParams.Add(request.NewErrParamRequired("ImageScanningConfiguration"))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetImageScanningConfiguration sets the ImageScanningConfiguration field's value.
-func (s *PutImageScanningConfigurationInput) SetImageScanningConfiguration(v *ImageScanningConfiguration) *PutImageScanningConfigurationInput {
- s.ImageScanningConfiguration = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *PutImageScanningConfigurationInput) SetRegistryId(v string) *PutImageScanningConfigurationInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *PutImageScanningConfigurationInput) SetRepositoryName(v string) *PutImageScanningConfigurationInput {
- s.RepositoryName = &v
- return s
-}
-
-type PutImageScanningConfigurationOutput struct {
- _ struct{} `type:"structure"`
-
- // The image scanning configuration setting for the repository.
- ImageScanningConfiguration *ImageScanningConfiguration `locationName:"imageScanningConfiguration" type:"structure"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s PutImageScanningConfigurationOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PutImageScanningConfigurationOutput) GoString() string {
- return s.String()
-}
-
-// SetImageScanningConfiguration sets the ImageScanningConfiguration field's value.
-func (s *PutImageScanningConfigurationOutput) SetImageScanningConfiguration(v *ImageScanningConfiguration) *PutImageScanningConfigurationOutput {
- s.ImageScanningConfiguration = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *PutImageScanningConfigurationOutput) SetRegistryId(v string) *PutImageScanningConfigurationOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *PutImageScanningConfigurationOutput) SetRepositoryName(v string) *PutImageScanningConfigurationOutput {
- s.RepositoryName = &v
- return s
-}
-
-type PutImageTagMutabilityInput struct {
- _ struct{} `type:"structure"`
-
- // The tag mutability setting for the repository. If MUTABLE is specified, image
- // tags can be overwritten. If IMMUTABLE is specified, all image tags within
- // the repository will be immutable which will prevent them from being overwritten.
- //
- // ImageTagMutability is a required field
- ImageTagMutability *string `locationName:"imageTagMutability" type:"string" required:"true" enum:"ImageTagMutability"`
-
- // The AWS account ID associated with the registry that contains the repository
- // in which to update the image tag mutability settings. If you do not specify
- // a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository in which to update the image tag mutability settings.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s PutImageTagMutabilityInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PutImageTagMutabilityInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *PutImageTagMutabilityInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "PutImageTagMutabilityInput"}
- if s.ImageTagMutability == nil {
- invalidParams.Add(request.NewErrParamRequired("ImageTagMutability"))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetImageTagMutability sets the ImageTagMutability field's value.
-func (s *PutImageTagMutabilityInput) SetImageTagMutability(v string) *PutImageTagMutabilityInput {
- s.ImageTagMutability = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *PutImageTagMutabilityInput) SetRegistryId(v string) *PutImageTagMutabilityInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *PutImageTagMutabilityInput) SetRepositoryName(v string) *PutImageTagMutabilityInput {
- s.RepositoryName = &v
- return s
-}
-
-type PutImageTagMutabilityOutput struct {
- _ struct{} `type:"structure"`
-
- // The image tag mutability setting for the repository.
- ImageTagMutability *string `locationName:"imageTagMutability" type:"string" enum:"ImageTagMutability"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s PutImageTagMutabilityOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PutImageTagMutabilityOutput) GoString() string {
- return s.String()
-}
-
-// SetImageTagMutability sets the ImageTagMutability field's value.
-func (s *PutImageTagMutabilityOutput) SetImageTagMutability(v string) *PutImageTagMutabilityOutput {
- s.ImageTagMutability = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *PutImageTagMutabilityOutput) SetRegistryId(v string) *PutImageTagMutabilityOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *PutImageTagMutabilityOutput) SetRepositoryName(v string) *PutImageTagMutabilityOutput {
- s.RepositoryName = &v
- return s
-}
-
-type PutLifecyclePolicyInput struct {
- _ struct{} `type:"structure"`
-
- // The JSON repository policy text to apply to the repository.
- //
- // LifecyclePolicyText is a required field
- LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string" required:"true"`
-
- // The AWS account ID associated with the registry that contains the repository.
- // If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository to receive the policy.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s PutLifecyclePolicyInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PutLifecyclePolicyInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *PutLifecyclePolicyInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "PutLifecyclePolicyInput"}
- if s.LifecyclePolicyText == nil {
- invalidParams.Add(request.NewErrParamRequired("LifecyclePolicyText"))
- }
- if s.LifecyclePolicyText != nil && len(*s.LifecyclePolicyText) < 100 {
- invalidParams.Add(request.NewErrParamMinLen("LifecyclePolicyText", 100))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetLifecyclePolicyText sets the LifecyclePolicyText field's value.
-func (s *PutLifecyclePolicyInput) SetLifecyclePolicyText(v string) *PutLifecyclePolicyInput {
- s.LifecyclePolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *PutLifecyclePolicyInput) SetRegistryId(v string) *PutLifecyclePolicyInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *PutLifecyclePolicyInput) SetRepositoryName(v string) *PutLifecyclePolicyInput {
- s.RepositoryName = &v
- return s
-}
-
-type PutLifecyclePolicyOutput struct {
- _ struct{} `type:"structure"`
-
- // The JSON repository policy text.
- LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s PutLifecyclePolicyOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PutLifecyclePolicyOutput) GoString() string {
- return s.String()
-}
-
-// SetLifecyclePolicyText sets the LifecyclePolicyText field's value.
-func (s *PutLifecyclePolicyOutput) SetLifecyclePolicyText(v string) *PutLifecyclePolicyOutput {
- s.LifecyclePolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *PutLifecyclePolicyOutput) SetRegistryId(v string) *PutLifecyclePolicyOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *PutLifecyclePolicyOutput) SetRepositoryName(v string) *PutLifecyclePolicyOutput {
- s.RepositoryName = &v
- return s
-}
-
-// The manifest list is referencing an image that does not exist.
-type ReferencedImagesNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s ReferencedImagesNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ReferencedImagesNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorReferencedImagesNotFoundException(v protocol.ResponseMetadata) error {
- return &ReferencedImagesNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *ReferencedImagesNotFoundException) Code() string {
- return "ReferencedImagesNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *ReferencedImagesNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *ReferencedImagesNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *ReferencedImagesNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *ReferencedImagesNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *ReferencedImagesNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// An object representing a repository.
-type Repository struct {
- _ struct{} `type:"structure"`
-
- // The date and time, in JavaScript date format, when the repository was created.
- CreatedAt *time.Time `locationName:"createdAt" type:"timestamp"`
-
- // The encryption configuration for the repository. This determines how the
- // contents of your repository are encrypted at rest.
- EncryptionConfiguration *EncryptionConfiguration `locationName:"encryptionConfiguration" type:"structure"`
-
- // The image scanning configuration for a repository.
- ImageScanningConfiguration *ImageScanningConfiguration `locationName:"imageScanningConfiguration" type:"structure"`
-
- // The tag mutability setting for the repository.
- ImageTagMutability *string `locationName:"imageTagMutability" type:"string" enum:"ImageTagMutability"`
-
- // The AWS account ID associated with the registry that contains the repository.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The Amazon Resource Name (ARN) that identifies the repository. The ARN contains
- // the arn:aws:ecr namespace, followed by the region of the repository, AWS
- // account ID of the repository owner, repository namespace, and repository
- // name. For example, arn:aws:ecr:region:012345678910:repository/test.
- RepositoryArn *string `locationName:"repositoryArn" type:"string"`
-
- // The name of the repository.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-
- // The URI for the repository. You can use this URI for container image push
- // and pull operations.
- RepositoryUri *string `locationName:"repositoryUri" type:"string"`
-}
-
-// String returns the string representation
-func (s Repository) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s Repository) GoString() string {
- return s.String()
-}
-
-// SetCreatedAt sets the CreatedAt field's value.
-func (s *Repository) SetCreatedAt(v time.Time) *Repository {
- s.CreatedAt = &v
- return s
-}
-
-// SetEncryptionConfiguration sets the EncryptionConfiguration field's value.
-func (s *Repository) SetEncryptionConfiguration(v *EncryptionConfiguration) *Repository {
- s.EncryptionConfiguration = v
- return s
-}
-
-// SetImageScanningConfiguration sets the ImageScanningConfiguration field's value.
-func (s *Repository) SetImageScanningConfiguration(v *ImageScanningConfiguration) *Repository {
- s.ImageScanningConfiguration = v
- return s
-}
-
-// SetImageTagMutability sets the ImageTagMutability field's value.
-func (s *Repository) SetImageTagMutability(v string) *Repository {
- s.ImageTagMutability = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *Repository) SetRegistryId(v string) *Repository {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryArn sets the RepositoryArn field's value.
-func (s *Repository) SetRepositoryArn(v string) *Repository {
- s.RepositoryArn = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *Repository) SetRepositoryName(v string) *Repository {
- s.RepositoryName = &v
- return s
-}
-
-// SetRepositoryUri sets the RepositoryUri field's value.
-func (s *Repository) SetRepositoryUri(v string) *Repository {
- s.RepositoryUri = &v
- return s
-}
-
-// The specified repository already exists in the specified registry.
-type RepositoryAlreadyExistsException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s RepositoryAlreadyExistsException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s RepositoryAlreadyExistsException) GoString() string {
- return s.String()
-}
-
-func newErrorRepositoryAlreadyExistsException(v protocol.ResponseMetadata) error {
- return &RepositoryAlreadyExistsException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *RepositoryAlreadyExistsException) Code() string {
- return "RepositoryAlreadyExistsException"
-}
-
-// Message returns the exception's message.
-func (s *RepositoryAlreadyExistsException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *RepositoryAlreadyExistsException) OrigErr() error {
- return nil
-}
-
-func (s *RepositoryAlreadyExistsException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *RepositoryAlreadyExistsException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *RepositoryAlreadyExistsException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The specified repository contains images. To delete a repository that contains
-// images, you must force the deletion with the force parameter.
-type RepositoryNotEmptyException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s RepositoryNotEmptyException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s RepositoryNotEmptyException) GoString() string {
- return s.String()
-}
-
-func newErrorRepositoryNotEmptyException(v protocol.ResponseMetadata) error {
- return &RepositoryNotEmptyException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *RepositoryNotEmptyException) Code() string {
- return "RepositoryNotEmptyException"
-}
-
-// Message returns the exception's message.
-func (s *RepositoryNotEmptyException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *RepositoryNotEmptyException) OrigErr() error {
- return nil
-}
-
-func (s *RepositoryNotEmptyException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *RepositoryNotEmptyException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *RepositoryNotEmptyException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The specified repository could not be found. Check the spelling of the specified
-// repository and ensure that you are performing operations on the correct registry.
-type RepositoryNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s RepositoryNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s RepositoryNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorRepositoryNotFoundException(v protocol.ResponseMetadata) error {
- return &RepositoryNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *RepositoryNotFoundException) Code() string {
- return "RepositoryNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *RepositoryNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *RepositoryNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *RepositoryNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *RepositoryNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *RepositoryNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The specified repository and registry combination does not have an associated
-// repository policy.
-type RepositoryPolicyNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s RepositoryPolicyNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s RepositoryPolicyNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorRepositoryPolicyNotFoundException(v protocol.ResponseMetadata) error {
- return &RepositoryPolicyNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *RepositoryPolicyNotFoundException) Code() string {
- return "RepositoryPolicyNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *RepositoryPolicyNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *RepositoryPolicyNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *RepositoryPolicyNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *RepositoryPolicyNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *RepositoryPolicyNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The specified image scan could not be found. Ensure that image scanning is
-// enabled on the repository and try again.
-type ScanNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s ScanNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ScanNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorScanNotFoundException(v protocol.ResponseMetadata) error {
- return &ScanNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *ScanNotFoundException) Code() string {
- return "ScanNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *ScanNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *ScanNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *ScanNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *ScanNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *ScanNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// These errors are usually caused by a server-side issue.
-type ServerException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s ServerException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s ServerException) GoString() string {
- return s.String()
-}
-
-func newErrorServerException(v protocol.ResponseMetadata) error {
- return &ServerException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *ServerException) Code() string {
- return "ServerException"
-}
-
-// Message returns the exception's message.
-func (s *ServerException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *ServerException) OrigErr() error {
- return nil
-}
-
-func (s *ServerException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *ServerException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *ServerException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-type SetRepositoryPolicyInput struct {
- _ struct{} `type:"structure"`
-
- // If the policy you are attempting to set on a repository policy would prevent
- // you from setting another policy in the future, you must force the SetRepositoryPolicy
- // operation. This is intended to prevent accidental repository lock outs.
- Force *bool `locationName:"force" type:"boolean"`
-
- // The JSON repository policy text to apply to the repository. For more information,
- // see Amazon ECR Repository Policies (https://docs.aws.amazon.com/AmazonECR/latest/userguide/repository-policy-examples.html)
- // in the Amazon Elastic Container Registry User Guide.
- //
- // PolicyText is a required field
- PolicyText *string `locationName:"policyText" type:"string" required:"true"`
-
- // The AWS account ID associated with the registry that contains the repository.
- // If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository to receive the policy.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s SetRepositoryPolicyInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s SetRepositoryPolicyInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *SetRepositoryPolicyInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "SetRepositoryPolicyInput"}
- if s.PolicyText == nil {
- invalidParams.Add(request.NewErrParamRequired("PolicyText"))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetForce sets the Force field's value.
-func (s *SetRepositoryPolicyInput) SetForce(v bool) *SetRepositoryPolicyInput {
- s.Force = &v
- return s
-}
-
-// SetPolicyText sets the PolicyText field's value.
-func (s *SetRepositoryPolicyInput) SetPolicyText(v string) *SetRepositoryPolicyInput {
- s.PolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *SetRepositoryPolicyInput) SetRegistryId(v string) *SetRepositoryPolicyInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *SetRepositoryPolicyInput) SetRepositoryName(v string) *SetRepositoryPolicyInput {
- s.RepositoryName = &v
- return s
-}
-
-type SetRepositoryPolicyOutput struct {
- _ struct{} `type:"structure"`
-
- // The JSON repository policy text applied to the repository.
- PolicyText *string `locationName:"policyText" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s SetRepositoryPolicyOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s SetRepositoryPolicyOutput) GoString() string {
- return s.String()
-}
-
-// SetPolicyText sets the PolicyText field's value.
-func (s *SetRepositoryPolicyOutput) SetPolicyText(v string) *SetRepositoryPolicyOutput {
- s.PolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *SetRepositoryPolicyOutput) SetRegistryId(v string) *SetRepositoryPolicyOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *SetRepositoryPolicyOutput) SetRepositoryName(v string) *SetRepositoryPolicyOutput {
- s.RepositoryName = &v
- return s
-}
-
-type StartImageScanInput struct {
- _ struct{} `type:"structure"`
-
- // An object with identifying information for an Amazon ECR image.
- //
- // ImageId is a required field
- ImageId *ImageIdentifier `locationName:"imageId" type:"structure" required:"true"`
-
- // The AWS account ID associated with the registry that contains the repository
- // in which to start an image scan request. If you do not specify a registry,
- // the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository that contains the images to scan.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s StartImageScanInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s StartImageScanInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *StartImageScanInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "StartImageScanInput"}
- if s.ImageId == nil {
- invalidParams.Add(request.NewErrParamRequired("ImageId"))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.ImageId != nil {
- if err := s.ImageId.Validate(); err != nil {
- invalidParams.AddNested("ImageId", err.(request.ErrInvalidParams))
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetImageId sets the ImageId field's value.
-func (s *StartImageScanInput) SetImageId(v *ImageIdentifier) *StartImageScanInput {
- s.ImageId = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *StartImageScanInput) SetRegistryId(v string) *StartImageScanInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *StartImageScanInput) SetRepositoryName(v string) *StartImageScanInput {
- s.RepositoryName = &v
- return s
-}
-
-type StartImageScanOutput struct {
- _ struct{} `type:"structure"`
-
- // An object with identifying information for an Amazon ECR image.
- ImageId *ImageIdentifier `locationName:"imageId" type:"structure"`
-
- // The current state of the scan.
- ImageScanStatus *ImageScanStatus `locationName:"imageScanStatus" type:"structure"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-}
-
-// String returns the string representation
-func (s StartImageScanOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s StartImageScanOutput) GoString() string {
- return s.String()
-}
-
-// SetImageId sets the ImageId field's value.
-func (s *StartImageScanOutput) SetImageId(v *ImageIdentifier) *StartImageScanOutput {
- s.ImageId = v
- return s
-}
-
-// SetImageScanStatus sets the ImageScanStatus field's value.
-func (s *StartImageScanOutput) SetImageScanStatus(v *ImageScanStatus) *StartImageScanOutput {
- s.ImageScanStatus = v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *StartImageScanOutput) SetRegistryId(v string) *StartImageScanOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *StartImageScanOutput) SetRepositoryName(v string) *StartImageScanOutput {
- s.RepositoryName = &v
- return s
-}
-
-type StartLifecyclePolicyPreviewInput struct {
- _ struct{} `type:"structure"`
-
- // The policy to be evaluated against. If you do not specify a policy, the current
- // policy for the repository is used.
- LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"`
-
- // The AWS account ID associated with the registry that contains the repository.
- // If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository to be evaluated.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s StartLifecyclePolicyPreviewInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s StartLifecyclePolicyPreviewInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *StartLifecyclePolicyPreviewInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "StartLifecyclePolicyPreviewInput"}
- if s.LifecyclePolicyText != nil && len(*s.LifecyclePolicyText) < 100 {
- invalidParams.Add(request.NewErrParamMinLen("LifecyclePolicyText", 100))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetLifecyclePolicyText sets the LifecyclePolicyText field's value.
-func (s *StartLifecyclePolicyPreviewInput) SetLifecyclePolicyText(v string) *StartLifecyclePolicyPreviewInput {
- s.LifecyclePolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *StartLifecyclePolicyPreviewInput) SetRegistryId(v string) *StartLifecyclePolicyPreviewInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *StartLifecyclePolicyPreviewInput) SetRepositoryName(v string) *StartLifecyclePolicyPreviewInput {
- s.RepositoryName = &v
- return s
-}
-
-type StartLifecyclePolicyPreviewOutput struct {
- _ struct{} `type:"structure"`
-
- // The JSON repository policy text.
- LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-
- // The status of the lifecycle policy preview request.
- Status *string `locationName:"status" type:"string" enum:"LifecyclePolicyPreviewStatus"`
-}
-
-// String returns the string representation
-func (s StartLifecyclePolicyPreviewOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s StartLifecyclePolicyPreviewOutput) GoString() string {
- return s.String()
-}
-
-// SetLifecyclePolicyText sets the LifecyclePolicyText field's value.
-func (s *StartLifecyclePolicyPreviewOutput) SetLifecyclePolicyText(v string) *StartLifecyclePolicyPreviewOutput {
- s.LifecyclePolicyText = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *StartLifecyclePolicyPreviewOutput) SetRegistryId(v string) *StartLifecyclePolicyPreviewOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *StartLifecyclePolicyPreviewOutput) SetRepositoryName(v string) *StartLifecyclePolicyPreviewOutput {
- s.RepositoryName = &v
- return s
-}
-
-// SetStatus sets the Status field's value.
-func (s *StartLifecyclePolicyPreviewOutput) SetStatus(v string) *StartLifecyclePolicyPreviewOutput {
- s.Status = &v
- return s
-}
-
-// The metadata that you apply to a resource to help you categorize and organize
-// them. Each tag consists of a key and an optional value, both of which you
-// define. Tag keys can have a maximum character length of 128 characters, and
-// tag values can have a maximum length of 256 characters.
-type Tag struct {
- _ struct{} `type:"structure"`
-
- // One part of a key-value pair that make up a tag. A key is a general label
- // that acts like a category for more specific tag values.
- Key *string `type:"string"`
-
- // The optional part of a key-value pair that make up a tag. A value acts as
- // a descriptor within a tag category (key).
- Value *string `type:"string"`
-}
-
-// String returns the string representation
-func (s Tag) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s Tag) GoString() string {
- return s.String()
-}
-
-// SetKey sets the Key field's value.
-func (s *Tag) SetKey(v string) *Tag {
- s.Key = &v
- return s
-}
-
-// SetValue sets the Value field's value.
-func (s *Tag) SetValue(v string) *Tag {
- s.Value = &v
- return s
-}
-
-type TagResourceInput struct {
- _ struct{} `type:"structure"`
-
- // The Amazon Resource Name (ARN) of the the resource to which to add tags.
- // Currently, the only supported resource is an Amazon ECR repository.
- //
- // ResourceArn is a required field
- ResourceArn *string `locationName:"resourceArn" type:"string" required:"true"`
-
- // The tags to add to the resource. A tag is an array of key-value pairs. Tag
- // keys can have a maximum character length of 128 characters, and tag values
- // can have a maximum length of 256 characters.
- //
- // Tags is a required field
- Tags []*Tag `locationName:"tags" type:"list" required:"true"`
-}
-
-// String returns the string representation
-func (s TagResourceInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s TagResourceInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *TagResourceInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "TagResourceInput"}
- if s.ResourceArn == nil {
- invalidParams.Add(request.NewErrParamRequired("ResourceArn"))
- }
- if s.Tags == nil {
- invalidParams.Add(request.NewErrParamRequired("Tags"))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetResourceArn sets the ResourceArn field's value.
-func (s *TagResourceInput) SetResourceArn(v string) *TagResourceInput {
- s.ResourceArn = &v
- return s
-}
-
-// SetTags sets the Tags field's value.
-func (s *TagResourceInput) SetTags(v []*Tag) *TagResourceInput {
- s.Tags = v
- return s
-}
-
-type TagResourceOutput struct {
- _ struct{} `type:"structure"`
-}
-
-// String returns the string representation
-func (s TagResourceOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s TagResourceOutput) GoString() string {
- return s.String()
-}
-
-// The list of tags on the repository is over the limit. The maximum number
-// of tags that can be applied to a repository is 50.
-type TooManyTagsException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s TooManyTagsException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s TooManyTagsException) GoString() string {
- return s.String()
-}
-
-func newErrorTooManyTagsException(v protocol.ResponseMetadata) error {
- return &TooManyTagsException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *TooManyTagsException) Code() string {
- return "TooManyTagsException"
-}
-
-// Message returns the exception's message.
-func (s *TooManyTagsException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *TooManyTagsException) OrigErr() error {
- return nil
-}
-
-func (s *TooManyTagsException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *TooManyTagsException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *TooManyTagsException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-// The image is of a type that cannot be scanned.
-type UnsupportedImageTypeException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s UnsupportedImageTypeException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s UnsupportedImageTypeException) GoString() string {
- return s.String()
-}
-
-func newErrorUnsupportedImageTypeException(v protocol.ResponseMetadata) error {
- return &UnsupportedImageTypeException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *UnsupportedImageTypeException) Code() string {
- return "UnsupportedImageTypeException"
-}
-
-// Message returns the exception's message.
-func (s *UnsupportedImageTypeException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *UnsupportedImageTypeException) OrigErr() error {
- return nil
-}
-
-func (s *UnsupportedImageTypeException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *UnsupportedImageTypeException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *UnsupportedImageTypeException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-type UntagResourceInput struct {
- _ struct{} `type:"structure"`
-
- // The Amazon Resource Name (ARN) of the resource from which to remove tags.
- // Currently, the only supported resource is an Amazon ECR repository.
- //
- // ResourceArn is a required field
- ResourceArn *string `locationName:"resourceArn" type:"string" required:"true"`
-
- // The keys of the tags to be removed.
- //
- // TagKeys is a required field
- TagKeys []*string `locationName:"tagKeys" type:"list" required:"true"`
-}
-
-// String returns the string representation
-func (s UntagResourceInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s UntagResourceInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *UntagResourceInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "UntagResourceInput"}
- if s.ResourceArn == nil {
- invalidParams.Add(request.NewErrParamRequired("ResourceArn"))
- }
- if s.TagKeys == nil {
- invalidParams.Add(request.NewErrParamRequired("TagKeys"))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetResourceArn sets the ResourceArn field's value.
-func (s *UntagResourceInput) SetResourceArn(v string) *UntagResourceInput {
- s.ResourceArn = &v
- return s
-}
-
-// SetTagKeys sets the TagKeys field's value.
-func (s *UntagResourceInput) SetTagKeys(v []*string) *UntagResourceInput {
- s.TagKeys = v
- return s
-}
-
-type UntagResourceOutput struct {
- _ struct{} `type:"structure"`
-}
-
-// String returns the string representation
-func (s UntagResourceOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s UntagResourceOutput) GoString() string {
- return s.String()
-}
-
-type UploadLayerPartInput struct {
- _ struct{} `type:"structure"`
-
- // The base64-encoded layer part payload.
- //
- // LayerPartBlob is automatically base64 encoded/decoded by the SDK.
- //
- // LayerPartBlob is a required field
- LayerPartBlob []byte `locationName:"layerPartBlob" type:"blob" required:"true"`
-
- // The position of the first byte of the layer part witin the overall image
- // layer.
- //
- // PartFirstByte is a required field
- PartFirstByte *int64 `locationName:"partFirstByte" type:"long" required:"true"`
-
- // The position of the last byte of the layer part within the overall image
- // layer.
- //
- // PartLastByte is a required field
- PartLastByte *int64 `locationName:"partLastByte" type:"long" required:"true"`
-
- // The AWS account ID associated with the registry to which you are uploading
- // layer parts. If you do not specify a registry, the default registry is assumed.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The name of the repository to which you are uploading layer parts.
- //
- // RepositoryName is a required field
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"`
-
- // The upload ID from a previous InitiateLayerUpload operation to associate
- // with the layer part upload.
- //
- // UploadId is a required field
- UploadId *string `locationName:"uploadId" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s UploadLayerPartInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s UploadLayerPartInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *UploadLayerPartInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "UploadLayerPartInput"}
- if s.LayerPartBlob == nil {
- invalidParams.Add(request.NewErrParamRequired("LayerPartBlob"))
- }
- if s.PartFirstByte == nil {
- invalidParams.Add(request.NewErrParamRequired("PartFirstByte"))
- }
- if s.PartLastByte == nil {
- invalidParams.Add(request.NewErrParamRequired("PartLastByte"))
- }
- if s.RepositoryName == nil {
- invalidParams.Add(request.NewErrParamRequired("RepositoryName"))
- }
- if s.RepositoryName != nil && len(*s.RepositoryName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2))
- }
- if s.UploadId == nil {
- invalidParams.Add(request.NewErrParamRequired("UploadId"))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetLayerPartBlob sets the LayerPartBlob field's value.
-func (s *UploadLayerPartInput) SetLayerPartBlob(v []byte) *UploadLayerPartInput {
- s.LayerPartBlob = v
- return s
-}
-
-// SetPartFirstByte sets the PartFirstByte field's value.
-func (s *UploadLayerPartInput) SetPartFirstByte(v int64) *UploadLayerPartInput {
- s.PartFirstByte = &v
- return s
-}
-
-// SetPartLastByte sets the PartLastByte field's value.
-func (s *UploadLayerPartInput) SetPartLastByte(v int64) *UploadLayerPartInput {
- s.PartLastByte = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *UploadLayerPartInput) SetRegistryId(v string) *UploadLayerPartInput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *UploadLayerPartInput) SetRepositoryName(v string) *UploadLayerPartInput {
- s.RepositoryName = &v
- return s
-}
-
-// SetUploadId sets the UploadId field's value.
-func (s *UploadLayerPartInput) SetUploadId(v string) *UploadLayerPartInput {
- s.UploadId = &v
- return s
-}
-
-type UploadLayerPartOutput struct {
- _ struct{} `type:"structure"`
-
- // The integer value of the last byte received in the request.
- LastByteReceived *int64 `locationName:"lastByteReceived" type:"long"`
-
- // The registry ID associated with the request.
- RegistryId *string `locationName:"registryId" type:"string"`
-
- // The repository name associated with the request.
- RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"`
-
- // The upload ID associated with the request.
- UploadId *string `locationName:"uploadId" type:"string"`
-}
-
-// String returns the string representation
-func (s UploadLayerPartOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s UploadLayerPartOutput) GoString() string {
- return s.String()
-}
-
-// SetLastByteReceived sets the LastByteReceived field's value.
-func (s *UploadLayerPartOutput) SetLastByteReceived(v int64) *UploadLayerPartOutput {
- s.LastByteReceived = &v
- return s
-}
-
-// SetRegistryId sets the RegistryId field's value.
-func (s *UploadLayerPartOutput) SetRegistryId(v string) *UploadLayerPartOutput {
- s.RegistryId = &v
- return s
-}
-
-// SetRepositoryName sets the RepositoryName field's value.
-func (s *UploadLayerPartOutput) SetRepositoryName(v string) *UploadLayerPartOutput {
- s.RepositoryName = &v
- return s
-}
-
-// SetUploadId sets the UploadId field's value.
-func (s *UploadLayerPartOutput) SetUploadId(v string) *UploadLayerPartOutput {
- s.UploadId = &v
- return s
-}
-
-// The upload could not be found, or the specified upload ID is not valid for
-// this repository.
-type UploadNotFoundException struct {
- _ struct{} `type:"structure"`
- RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"`
-
- // The error message associated with the exception.
- Message_ *string `locationName:"message" type:"string"`
-}
-
-// String returns the string representation
-func (s UploadNotFoundException) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s UploadNotFoundException) GoString() string {
- return s.String()
-}
-
-func newErrorUploadNotFoundException(v protocol.ResponseMetadata) error {
- return &UploadNotFoundException{
- RespMetadata: v,
- }
-}
-
-// Code returns the exception type name.
-func (s *UploadNotFoundException) Code() string {
- return "UploadNotFoundException"
-}
-
-// Message returns the exception's message.
-func (s *UploadNotFoundException) Message() string {
- if s.Message_ != nil {
- return *s.Message_
- }
- return ""
-}
-
-// OrigErr always returns nil, satisfies awserr.Error interface.
-func (s *UploadNotFoundException) OrigErr() error {
- return nil
-}
-
-func (s *UploadNotFoundException) Error() string {
- return fmt.Sprintf("%s: %s", s.Code(), s.Message())
-}
-
-// Status code returns the HTTP status code for the request's response error.
-func (s *UploadNotFoundException) StatusCode() int {
- return s.RespMetadata.StatusCode
-}
-
-// RequestID returns the service's response RequestID for request.
-func (s *UploadNotFoundException) RequestID() string {
- return s.RespMetadata.RequestID
-}
-
-const (
- // EncryptionTypeAes256 is a EncryptionType enum value
- EncryptionTypeAes256 = "AES256"
-
- // EncryptionTypeKms is a EncryptionType enum value
- EncryptionTypeKms = "KMS"
-)
-
-// EncryptionType_Values returns all elements of the EncryptionType enum
-func EncryptionType_Values() []string {
- return []string{
- EncryptionTypeAes256,
- EncryptionTypeKms,
- }
-}
-
-const (
- // FindingSeverityInformational is a FindingSeverity enum value
- FindingSeverityInformational = "INFORMATIONAL"
-
- // FindingSeverityLow is a FindingSeverity enum value
- FindingSeverityLow = "LOW"
-
- // FindingSeverityMedium is a FindingSeverity enum value
- FindingSeverityMedium = "MEDIUM"
-
- // FindingSeverityHigh is a FindingSeverity enum value
- FindingSeverityHigh = "HIGH"
-
- // FindingSeverityCritical is a FindingSeverity enum value
- FindingSeverityCritical = "CRITICAL"
-
- // FindingSeverityUndefined is a FindingSeverity enum value
- FindingSeverityUndefined = "UNDEFINED"
-)
-
-// FindingSeverity_Values returns all elements of the FindingSeverity enum
-func FindingSeverity_Values() []string {
- return []string{
- FindingSeverityInformational,
- FindingSeverityLow,
- FindingSeverityMedium,
- FindingSeverityHigh,
- FindingSeverityCritical,
- FindingSeverityUndefined,
- }
-}
-
-const (
- // ImageActionTypeExpire is a ImageActionType enum value
- ImageActionTypeExpire = "EXPIRE"
-)
-
-// ImageActionType_Values returns all elements of the ImageActionType enum
-func ImageActionType_Values() []string {
- return []string{
- ImageActionTypeExpire,
- }
-}
-
-const (
- // ImageFailureCodeInvalidImageDigest is a ImageFailureCode enum value
- ImageFailureCodeInvalidImageDigest = "InvalidImageDigest"
-
- // ImageFailureCodeInvalidImageTag is a ImageFailureCode enum value
- ImageFailureCodeInvalidImageTag = "InvalidImageTag"
-
- // ImageFailureCodeImageTagDoesNotMatchDigest is a ImageFailureCode enum value
- ImageFailureCodeImageTagDoesNotMatchDigest = "ImageTagDoesNotMatchDigest"
-
- // ImageFailureCodeImageNotFound is a ImageFailureCode enum value
- ImageFailureCodeImageNotFound = "ImageNotFound"
-
- // ImageFailureCodeMissingDigestAndTag is a ImageFailureCode enum value
- ImageFailureCodeMissingDigestAndTag = "MissingDigestAndTag"
-
- // ImageFailureCodeImageReferencedByManifestList is a ImageFailureCode enum value
- ImageFailureCodeImageReferencedByManifestList = "ImageReferencedByManifestList"
-
- // ImageFailureCodeKmsError is a ImageFailureCode enum value
- ImageFailureCodeKmsError = "KmsError"
-)
-
-// ImageFailureCode_Values returns all elements of the ImageFailureCode enum
-func ImageFailureCode_Values() []string {
- return []string{
- ImageFailureCodeInvalidImageDigest,
- ImageFailureCodeInvalidImageTag,
- ImageFailureCodeImageTagDoesNotMatchDigest,
- ImageFailureCodeImageNotFound,
- ImageFailureCodeMissingDigestAndTag,
- ImageFailureCodeImageReferencedByManifestList,
- ImageFailureCodeKmsError,
- }
-}
-
-const (
- // ImageTagMutabilityMutable is a ImageTagMutability enum value
- ImageTagMutabilityMutable = "MUTABLE"
-
- // ImageTagMutabilityImmutable is a ImageTagMutability enum value
- ImageTagMutabilityImmutable = "IMMUTABLE"
-)
-
-// ImageTagMutability_Values returns all elements of the ImageTagMutability enum
-func ImageTagMutability_Values() []string {
- return []string{
- ImageTagMutabilityMutable,
- ImageTagMutabilityImmutable,
- }
-}
-
-const (
- // LayerAvailabilityAvailable is a LayerAvailability enum value
- LayerAvailabilityAvailable = "AVAILABLE"
-
- // LayerAvailabilityUnavailable is a LayerAvailability enum value
- LayerAvailabilityUnavailable = "UNAVAILABLE"
-)
-
-// LayerAvailability_Values returns all elements of the LayerAvailability enum
-func LayerAvailability_Values() []string {
- return []string{
- LayerAvailabilityAvailable,
- LayerAvailabilityUnavailable,
- }
-}
-
-const (
- // LayerFailureCodeInvalidLayerDigest is a LayerFailureCode enum value
- LayerFailureCodeInvalidLayerDigest = "InvalidLayerDigest"
-
- // LayerFailureCodeMissingLayerDigest is a LayerFailureCode enum value
- LayerFailureCodeMissingLayerDigest = "MissingLayerDigest"
-)
-
-// LayerFailureCode_Values returns all elements of the LayerFailureCode enum
-func LayerFailureCode_Values() []string {
- return []string{
- LayerFailureCodeInvalidLayerDigest,
- LayerFailureCodeMissingLayerDigest,
- }
-}
-
-const (
- // LifecyclePolicyPreviewStatusInProgress is a LifecyclePolicyPreviewStatus enum value
- LifecyclePolicyPreviewStatusInProgress = "IN_PROGRESS"
-
- // LifecyclePolicyPreviewStatusComplete is a LifecyclePolicyPreviewStatus enum value
- LifecyclePolicyPreviewStatusComplete = "COMPLETE"
-
- // LifecyclePolicyPreviewStatusExpired is a LifecyclePolicyPreviewStatus enum value
- LifecyclePolicyPreviewStatusExpired = "EXPIRED"
-
- // LifecyclePolicyPreviewStatusFailed is a LifecyclePolicyPreviewStatus enum value
- LifecyclePolicyPreviewStatusFailed = "FAILED"
-)
-
-// LifecyclePolicyPreviewStatus_Values returns all elements of the LifecyclePolicyPreviewStatus enum
-func LifecyclePolicyPreviewStatus_Values() []string {
- return []string{
- LifecyclePolicyPreviewStatusInProgress,
- LifecyclePolicyPreviewStatusComplete,
- LifecyclePolicyPreviewStatusExpired,
- LifecyclePolicyPreviewStatusFailed,
- }
-}
-
-const (
- // ScanStatusInProgress is a ScanStatus enum value
- ScanStatusInProgress = "IN_PROGRESS"
-
- // ScanStatusComplete is a ScanStatus enum value
- ScanStatusComplete = "COMPLETE"
-
- // ScanStatusFailed is a ScanStatus enum value
- ScanStatusFailed = "FAILED"
-)
-
-// ScanStatus_Values returns all elements of the ScanStatus enum
-func ScanStatus_Values() []string {
- return []string{
- ScanStatusInProgress,
- ScanStatusComplete,
- ScanStatusFailed,
- }
-}
-
-const (
- // TagStatusTagged is a TagStatus enum value
- TagStatusTagged = "TAGGED"
-
- // TagStatusUntagged is a TagStatus enum value
- TagStatusUntagged = "UNTAGGED"
-
- // TagStatusAny is a TagStatus enum value
- TagStatusAny = "ANY"
-)
-
-// TagStatus_Values returns all elements of the TagStatus enum
-func TagStatus_Values() []string {
- return []string{
- TagStatusTagged,
- TagStatusUntagged,
- TagStatusAny,
- }
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecr/doc.go b/vendor/github.com/aws/aws-sdk-go/service/ecr/doc.go
deleted file mode 100644
index 3c3843ae3e57..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/ecr/doc.go
+++ /dev/null
@@ -1,34 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-// Package ecr provides the client and types for making API
-// requests to Amazon EC2 Container Registry.
-//
-// Amazon Elastic Container Registry (Amazon ECR) is a managed container image
-// registry service. Customers can use the familiar Docker CLI, or their preferred
-// client, to push, pull, and manage images. Amazon ECR provides a secure, scalable,
-// and reliable registry for your Docker or Open Container Initiative (OCI)
-// images. Amazon ECR supports private repositories with resource-based permissions
-// using IAM so that specific users or Amazon EC2 instances can access repositories
-// and images.
-//
-// See https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21 for more information on this service.
-//
-// See ecr package documentation for more information.
-// https://docs.aws.amazon.com/sdk-for-go/api/service/ecr/
-//
-// Using the Client
-//
-// To contact Amazon EC2 Container Registry with the SDK use the New function to create
-// a new service client. With that client you can make API requests to the service.
-// These clients are safe to use concurrently.
-//
-// See the SDK's documentation for more information on how to use the SDK.
-// https://docs.aws.amazon.com/sdk-for-go/api/
-//
-// See aws.Config documentation for more information on configuring SDK clients.
-// https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config
-//
-// See the Amazon EC2 Container Registry client ECR for more
-// information on creating client for this service.
-// https://docs.aws.amazon.com/sdk-for-go/api/service/ecr/#New
-package ecr
diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go b/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go
deleted file mode 100644
index 8191013264f1..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go
+++ /dev/null
@@ -1,228 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-package ecr
-
-import (
- "github.com/aws/aws-sdk-go/private/protocol"
-)
-
-const (
-
- // ErrCodeEmptyUploadException for service response error code
- // "EmptyUploadException".
- //
- // The specified layer upload does not contain any layer parts.
- ErrCodeEmptyUploadException = "EmptyUploadException"
-
- // ErrCodeImageAlreadyExistsException for service response error code
- // "ImageAlreadyExistsException".
- //
- // The specified image has already been pushed, and there were no changes to
- // the manifest or image tag after the last push.
- ErrCodeImageAlreadyExistsException = "ImageAlreadyExistsException"
-
- // ErrCodeImageDigestDoesNotMatchException for service response error code
- // "ImageDigestDoesNotMatchException".
- //
- // The specified image digest does not match the digest that Amazon ECR calculated
- // for the image.
- ErrCodeImageDigestDoesNotMatchException = "ImageDigestDoesNotMatchException"
-
- // ErrCodeImageNotFoundException for service response error code
- // "ImageNotFoundException".
- //
- // The image requested does not exist in the specified repository.
- ErrCodeImageNotFoundException = "ImageNotFoundException"
-
- // ErrCodeImageTagAlreadyExistsException for service response error code
- // "ImageTagAlreadyExistsException".
- //
- // The specified image is tagged with a tag that already exists. The repository
- // is configured for tag immutability.
- ErrCodeImageTagAlreadyExistsException = "ImageTagAlreadyExistsException"
-
- // ErrCodeInvalidLayerException for service response error code
- // "InvalidLayerException".
- //
- // The layer digest calculation performed by Amazon ECR upon receipt of the
- // image layer does not match the digest specified.
- ErrCodeInvalidLayerException = "InvalidLayerException"
-
- // ErrCodeInvalidLayerPartException for service response error code
- // "InvalidLayerPartException".
- //
- // The layer part size is not valid, or the first byte specified is not consecutive
- // to the last byte of a previous layer part upload.
- ErrCodeInvalidLayerPartException = "InvalidLayerPartException"
-
- // ErrCodeInvalidParameterException for service response error code
- // "InvalidParameterException".
- //
- // The specified parameter is invalid. Review the available parameters for the
- // API request.
- ErrCodeInvalidParameterException = "InvalidParameterException"
-
- // ErrCodeInvalidTagParameterException for service response error code
- // "InvalidTagParameterException".
- //
- // An invalid parameter has been specified. Tag keys can have a maximum character
- // length of 128 characters, and tag values can have a maximum length of 256
- // characters.
- ErrCodeInvalidTagParameterException = "InvalidTagParameterException"
-
- // ErrCodeKmsException for service response error code
- // "KmsException".
- //
- // The operation failed due to a KMS exception.
- ErrCodeKmsException = "KmsException"
-
- // ErrCodeLayerAlreadyExistsException for service response error code
- // "LayerAlreadyExistsException".
- //
- // The image layer already exists in the associated repository.
- ErrCodeLayerAlreadyExistsException = "LayerAlreadyExistsException"
-
- // ErrCodeLayerInaccessibleException for service response error code
- // "LayerInaccessibleException".
- //
- // The specified layer is not available because it is not associated with an
- // image. Unassociated image layers may be cleaned up at any time.
- ErrCodeLayerInaccessibleException = "LayerInaccessibleException"
-
- // ErrCodeLayerPartTooSmallException for service response error code
- // "LayerPartTooSmallException".
- //
- // Layer parts must be at least 5 MiB in size.
- ErrCodeLayerPartTooSmallException = "LayerPartTooSmallException"
-
- // ErrCodeLayersNotFoundException for service response error code
- // "LayersNotFoundException".
- //
- // The specified layers could not be found, or the specified layer is not valid
- // for this repository.
- ErrCodeLayersNotFoundException = "LayersNotFoundException"
-
- // ErrCodeLifecyclePolicyNotFoundException for service response error code
- // "LifecyclePolicyNotFoundException".
- //
- // The lifecycle policy could not be found, and no policy is set to the repository.
- ErrCodeLifecyclePolicyNotFoundException = "LifecyclePolicyNotFoundException"
-
- // ErrCodeLifecyclePolicyPreviewInProgressException for service response error code
- // "LifecyclePolicyPreviewInProgressException".
- //
- // The previous lifecycle policy preview request has not completed. Wait and
- // try again.
- ErrCodeLifecyclePolicyPreviewInProgressException = "LifecyclePolicyPreviewInProgressException"
-
- // ErrCodeLifecyclePolicyPreviewNotFoundException for service response error code
- // "LifecyclePolicyPreviewNotFoundException".
- //
- // There is no dry run for this repository.
- ErrCodeLifecyclePolicyPreviewNotFoundException = "LifecyclePolicyPreviewNotFoundException"
-
- // ErrCodeLimitExceededException for service response error code
- // "LimitExceededException".
- //
- // The operation did not succeed because it would have exceeded a service limit
- // for your account. For more information, see Amazon ECR Service Quotas (https://docs.aws.amazon.com/AmazonECR/latest/userguide/service-quotas.html)
- // in the Amazon Elastic Container Registry User Guide.
- ErrCodeLimitExceededException = "LimitExceededException"
-
- // ErrCodeReferencedImagesNotFoundException for service response error code
- // "ReferencedImagesNotFoundException".
- //
- // The manifest list is referencing an image that does not exist.
- ErrCodeReferencedImagesNotFoundException = "ReferencedImagesNotFoundException"
-
- // ErrCodeRepositoryAlreadyExistsException for service response error code
- // "RepositoryAlreadyExistsException".
- //
- // The specified repository already exists in the specified registry.
- ErrCodeRepositoryAlreadyExistsException = "RepositoryAlreadyExistsException"
-
- // ErrCodeRepositoryNotEmptyException for service response error code
- // "RepositoryNotEmptyException".
- //
- // The specified repository contains images. To delete a repository that contains
- // images, you must force the deletion with the force parameter.
- ErrCodeRepositoryNotEmptyException = "RepositoryNotEmptyException"
-
- // ErrCodeRepositoryNotFoundException for service response error code
- // "RepositoryNotFoundException".
- //
- // The specified repository could not be found. Check the spelling of the specified
- // repository and ensure that you are performing operations on the correct registry.
- ErrCodeRepositoryNotFoundException = "RepositoryNotFoundException"
-
- // ErrCodeRepositoryPolicyNotFoundException for service response error code
- // "RepositoryPolicyNotFoundException".
- //
- // The specified repository and registry combination does not have an associated
- // repository policy.
- ErrCodeRepositoryPolicyNotFoundException = "RepositoryPolicyNotFoundException"
-
- // ErrCodeScanNotFoundException for service response error code
- // "ScanNotFoundException".
- //
- // The specified image scan could not be found. Ensure that image scanning is
- // enabled on the repository and try again.
- ErrCodeScanNotFoundException = "ScanNotFoundException"
-
- // ErrCodeServerException for service response error code
- // "ServerException".
- //
- // These errors are usually caused by a server-side issue.
- ErrCodeServerException = "ServerException"
-
- // ErrCodeTooManyTagsException for service response error code
- // "TooManyTagsException".
- //
- // The list of tags on the repository is over the limit. The maximum number
- // of tags that can be applied to a repository is 50.
- ErrCodeTooManyTagsException = "TooManyTagsException"
-
- // ErrCodeUnsupportedImageTypeException for service response error code
- // "UnsupportedImageTypeException".
- //
- // The image is of a type that cannot be scanned.
- ErrCodeUnsupportedImageTypeException = "UnsupportedImageTypeException"
-
- // ErrCodeUploadNotFoundException for service response error code
- // "UploadNotFoundException".
- //
- // The upload could not be found, or the specified upload ID is not valid for
- // this repository.
- ErrCodeUploadNotFoundException = "UploadNotFoundException"
-)
-
-var exceptionFromCode = map[string]func(protocol.ResponseMetadata) error{
- "EmptyUploadException": newErrorEmptyUploadException,
- "ImageAlreadyExistsException": newErrorImageAlreadyExistsException,
- "ImageDigestDoesNotMatchException": newErrorImageDigestDoesNotMatchException,
- "ImageNotFoundException": newErrorImageNotFoundException,
- "ImageTagAlreadyExistsException": newErrorImageTagAlreadyExistsException,
- "InvalidLayerException": newErrorInvalidLayerException,
- "InvalidLayerPartException": newErrorInvalidLayerPartException,
- "InvalidParameterException": newErrorInvalidParameterException,
- "InvalidTagParameterException": newErrorInvalidTagParameterException,
- "KmsException": newErrorKmsException,
- "LayerAlreadyExistsException": newErrorLayerAlreadyExistsException,
- "LayerInaccessibleException": newErrorLayerInaccessibleException,
- "LayerPartTooSmallException": newErrorLayerPartTooSmallException,
- "LayersNotFoundException": newErrorLayersNotFoundException,
- "LifecyclePolicyNotFoundException": newErrorLifecyclePolicyNotFoundException,
- "LifecyclePolicyPreviewInProgressException": newErrorLifecyclePolicyPreviewInProgressException,
- "LifecyclePolicyPreviewNotFoundException": newErrorLifecyclePolicyPreviewNotFoundException,
- "LimitExceededException": newErrorLimitExceededException,
- "ReferencedImagesNotFoundException": newErrorReferencedImagesNotFoundException,
- "RepositoryAlreadyExistsException": newErrorRepositoryAlreadyExistsException,
- "RepositoryNotEmptyException": newErrorRepositoryNotEmptyException,
- "RepositoryNotFoundException": newErrorRepositoryNotFoundException,
- "RepositoryPolicyNotFoundException": newErrorRepositoryPolicyNotFoundException,
- "ScanNotFoundException": newErrorScanNotFoundException,
- "ServerException": newErrorServerException,
- "TooManyTagsException": newErrorTooManyTagsException,
- "UnsupportedImageTypeException": newErrorUnsupportedImageTypeException,
- "UploadNotFoundException": newErrorUploadNotFoundException,
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecr/service.go b/vendor/github.com/aws/aws-sdk-go/service/ecr/service.go
deleted file mode 100644
index c4392395cea3..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/ecr/service.go
+++ /dev/null
@@ -1,106 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-package ecr
-
-import (
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/client"
- "github.com/aws/aws-sdk-go/aws/client/metadata"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/aws/signer/v4"
- "github.com/aws/aws-sdk-go/private/protocol"
- "github.com/aws/aws-sdk-go/private/protocol/jsonrpc"
-)
-
-// ECR provides the API operation methods for making requests to
-// Amazon EC2 Container Registry. See this package's package overview docs
-// for details on the service.
-//
-// ECR methods are safe to use concurrently. It is not safe to
-// modify mutate any of the struct's properties though.
-type ECR struct {
- *client.Client
-}
-
-// Used for custom client initialization logic
-var initClient func(*client.Client)
-
-// Used for custom request initialization logic
-var initRequest func(*request.Request)
-
-// Service information constants
-const (
- ServiceName = "ecr" // Name of service.
- EndpointsID = "api.ecr" // ID to lookup a service endpoint with.
- ServiceID = "ECR" // ServiceID is a unique identifier of a specific service.
-)
-
-// New creates a new instance of the ECR client with a session.
-// If additional configuration is needed for the client instance use the optional
-// aws.Config parameter to add your extra config.
-//
-// Example:
-// mySession := session.Must(session.NewSession())
-//
-// // Create a ECR client from just a session.
-// svc := ecr.New(mySession)
-//
-// // Create a ECR client with additional configuration
-// svc := ecr.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
-func New(p client.ConfigProvider, cfgs ...*aws.Config) *ECR {
- c := p.ClientConfig(EndpointsID, cfgs...)
- if c.SigningNameDerived || len(c.SigningName) == 0 {
- c.SigningName = "ecr"
- }
- return newClient(*c.Config, c.Handlers, c.PartitionID, c.Endpoint, c.SigningRegion, c.SigningName)
-}
-
-// newClient creates, initializes and returns a new service client instance.
-func newClient(cfg aws.Config, handlers request.Handlers, partitionID, endpoint, signingRegion, signingName string) *ECR {
- svc := &ECR{
- Client: client.New(
- cfg,
- metadata.ClientInfo{
- ServiceName: ServiceName,
- ServiceID: ServiceID,
- SigningName: signingName,
- SigningRegion: signingRegion,
- PartitionID: partitionID,
- Endpoint: endpoint,
- APIVersion: "2015-09-21",
- JSONVersion: "1.1",
- TargetPrefix: "AmazonEC2ContainerRegistry_V20150921",
- },
- handlers,
- ),
- }
-
- // Handlers
- svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
- svc.Handlers.Build.PushBackNamed(jsonrpc.BuildHandler)
- svc.Handlers.Unmarshal.PushBackNamed(jsonrpc.UnmarshalHandler)
- svc.Handlers.UnmarshalMeta.PushBackNamed(jsonrpc.UnmarshalMetaHandler)
- svc.Handlers.UnmarshalError.PushBackNamed(
- protocol.NewUnmarshalErrorHandler(jsonrpc.NewUnmarshalTypedError(exceptionFromCode)).NamedHandler(),
- )
-
- // Run custom client initialization if present
- if initClient != nil {
- initClient(svc.Client)
- }
-
- return svc
-}
-
-// newRequest creates a new request for a ECR operation and runs any
-// custom request initialization.
-func (c *ECR) newRequest(op *request.Operation, params, data interface{}) *request.Request {
- req := c.NewRequest(op, params, data)
-
- // Run custom request initialization if present
- if initRequest != nil {
- initRequest(req)
- }
-
- return req
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecr/waiters.go b/vendor/github.com/aws/aws-sdk-go/service/ecr/waiters.go
deleted file mode 100644
index 4b6f88e4e151..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/ecr/waiters.go
+++ /dev/null
@@ -1,112 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-package ecr
-
-import (
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-// WaitUntilImageScanComplete uses the Amazon ECR API operation
-// DescribeImageScanFindings to wait for a condition to be met before returning.
-// If the condition is not met within the max attempt window, an error will
-// be returned.
-func (c *ECR) WaitUntilImageScanComplete(input *DescribeImageScanFindingsInput) error {
- return c.WaitUntilImageScanCompleteWithContext(aws.BackgroundContext(), input)
-}
-
-// WaitUntilImageScanCompleteWithContext is an extended version of WaitUntilImageScanComplete.
-// With the support for passing in a context and options to configure the
-// Waiter and the underlying request options.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) WaitUntilImageScanCompleteWithContext(ctx aws.Context, input *DescribeImageScanFindingsInput, opts ...request.WaiterOption) error {
- w := request.Waiter{
- Name: "WaitUntilImageScanComplete",
- MaxAttempts: 60,
- Delay: request.ConstantWaiterDelay(5 * time.Second),
- Acceptors: []request.WaiterAcceptor{
- {
- State: request.SuccessWaiterState,
- Matcher: request.PathWaiterMatch, Argument: "imageScanStatus.status",
- Expected: "COMPLETE",
- },
- {
- State: request.FailureWaiterState,
- Matcher: request.PathWaiterMatch, Argument: "imageScanStatus.status",
- Expected: "FAILED",
- },
- },
- Logger: c.Config.Logger,
- NewRequest: func(opts []request.Option) (*request.Request, error) {
- var inCpy *DescribeImageScanFindingsInput
- if input != nil {
- tmp := *input
- inCpy = &tmp
- }
- req, _ := c.DescribeImageScanFindingsRequest(inCpy)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return req, nil
- },
- }
- w.ApplyOptions(opts...)
-
- return w.WaitWithContext(ctx)
-}
-
-// WaitUntilLifecyclePolicyPreviewComplete uses the Amazon ECR API operation
-// GetLifecyclePolicyPreview to wait for a condition to be met before returning.
-// If the condition is not met within the max attempt window, an error will
-// be returned.
-func (c *ECR) WaitUntilLifecyclePolicyPreviewComplete(input *GetLifecyclePolicyPreviewInput) error {
- return c.WaitUntilLifecyclePolicyPreviewCompleteWithContext(aws.BackgroundContext(), input)
-}
-
-// WaitUntilLifecyclePolicyPreviewCompleteWithContext is an extended version of WaitUntilLifecyclePolicyPreviewComplete.
-// With the support for passing in a context and options to configure the
-// Waiter and the underlying request options.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *ECR) WaitUntilLifecyclePolicyPreviewCompleteWithContext(ctx aws.Context, input *GetLifecyclePolicyPreviewInput, opts ...request.WaiterOption) error {
- w := request.Waiter{
- Name: "WaitUntilLifecyclePolicyPreviewComplete",
- MaxAttempts: 20,
- Delay: request.ConstantWaiterDelay(5 * time.Second),
- Acceptors: []request.WaiterAcceptor{
- {
- State: request.SuccessWaiterState,
- Matcher: request.PathWaiterMatch, Argument: "status",
- Expected: "COMPLETE",
- },
- {
- State: request.FailureWaiterState,
- Matcher: request.PathWaiterMatch, Argument: "status",
- Expected: "FAILED",
- },
- },
- Logger: c.Config.Logger,
- NewRequest: func(opts []request.Option) (*request.Request, error) {
- var inCpy *GetLifecyclePolicyPreviewInput
- if input != nil {
- tmp := *input
- inCpy = &tmp
- }
- req, _ := c.GetLifecyclePolicyPreviewRequest(inCpy)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return req, nil
- },
- }
- w.ApplyOptions(opts...)
-
- return w.WaitWithContext(ctx)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/api.go b/vendor/github.com/aws/aws-sdk-go/service/sts/api.go
deleted file mode 100644
index bfc4372f9fde..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/sts/api.go
+++ /dev/null
@@ -1,3119 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-package sts
-
-import (
- "fmt"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/awsutil"
- "github.com/aws/aws-sdk-go/aws/credentials"
- "github.com/aws/aws-sdk-go/aws/request"
-)
-
-const opAssumeRole = "AssumeRole"
-
-// AssumeRoleRequest generates a "aws/request.Request" representing the
-// client's request for the AssumeRole operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See AssumeRole for more information on using the AssumeRole
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the AssumeRoleRequest method.
-// req, resp := client.AssumeRoleRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRole
-func (c *STS) AssumeRoleRequest(input *AssumeRoleInput) (req *request.Request, output *AssumeRoleOutput) {
- op := &request.Operation{
- Name: opAssumeRole,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &AssumeRoleInput{}
- }
-
- output = &AssumeRoleOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// AssumeRole API operation for AWS Security Token Service.
-//
-// Returns a set of temporary security credentials that you can use to access
-// AWS resources that you might not normally have access to. These temporary
-// credentials consist of an access key ID, a secret access key, and a security
-// token. Typically, you use AssumeRole within your account or for cross-account
-// access. For a comparison of AssumeRole with other API operations that produce
-// temporary credentials, see Requesting Temporary Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
-// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
-// in the IAM User Guide.
-//
-// You cannot use AWS account root user credentials to call AssumeRole. You
-// must use credentials for an IAM user or an IAM role to call AssumeRole.
-//
-// For cross-account access, imagine that you own multiple accounts and need
-// to access resources in each account. You could create long-term credentials
-// in each account to access those resources. However, managing all those credentials
-// and remembering which one can access which account can be time consuming.
-// Instead, you can create one set of long-term credentials in one account.
-// Then use temporary security credentials to access all the other accounts
-// by assuming roles in those accounts. For more information about roles, see
-// IAM Roles (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles.html)
-// in the IAM User Guide.
-//
-// Session Duration
-//
-// By default, the temporary security credentials created by AssumeRole last
-// for one hour. However, you can use the optional DurationSeconds parameter
-// to specify the duration of your session. You can provide a value from 900
-// seconds (15 minutes) up to the maximum session duration setting for the role.
-// This setting can have a value from 1 hour to 12 hours. To learn how to view
-// the maximum value for your role, see View the Maximum Session Duration Setting
-// for a Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
-// in the IAM User Guide. The maximum session duration limit applies when you
-// use the AssumeRole* API operations or the assume-role* CLI commands. However
-// the limit does not apply when you use those operations to create a console
-// URL. For more information, see Using IAM Roles (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html)
-// in the IAM User Guide.
-//
-// Permissions
-//
-// The temporary security credentials created by AssumeRole can be used to make
-// API calls to any AWS service with the following exception: You cannot call
-// the AWS STS GetFederationToken or GetSessionToken API operations.
-//
-// (Optional) You can pass inline or managed session policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
-// to this operation. You can pass a single JSON policy document to use as an
-// inline session policy. You can also specify up to 10 managed policies to
-// use as managed session policies. The plain text that you use for both inline
-// and managed session policies can't exceed 2,048 characters. Passing policies
-// to this operation returns new temporary credentials. The resulting session's
-// permissions are the intersection of the role's identity-based policy and
-// the session policies. You can use the role's temporary credentials in subsequent
-// AWS API calls to access resources in the account that owns the role. You
-// cannot use session policies to grant more permissions than those allowed
-// by the identity-based policy of the role that is being assumed. For more
-// information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
-// in the IAM User Guide.
-//
-// To assume a role from a different account, your AWS account must be trusted
-// by the role. The trust relationship is defined in the role's trust policy
-// when the role is created. That trust policy states which accounts are allowed
-// to delegate that access to users in the account.
-//
-// A user who wants to access a role in a different account must also have permissions
-// that are delegated from the user account administrator. The administrator
-// must attach a policy that allows the user to call AssumeRole for the ARN
-// of the role in the other account. If the user is in the same account as the
-// role, then you can do either of the following:
-//
-// * Attach a policy to the user (identical to the previous user in a different
-// account).
-//
-// * Add the user as a principal directly in the role's trust policy.
-//
-// In this case, the trust policy acts as an IAM resource-based policy. Users
-// in the same account as the role do not need explicit permission to assume
-// the role. For more information about trust policies and resource-based policies,
-// see IAM Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html)
-// in the IAM User Guide.
-//
-// Tags
-//
-// (Optional) You can pass tag key-value pairs to your session. These tags are
-// called session tags. For more information about session tags, see Passing
-// Session Tags in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-//
-// An administrator must grant you the permissions necessary to pass session
-// tags. The administrator can also create granular permissions to allow you
-// to pass only specific session tags. For more information, see Tutorial: Using
-// Tags for Attribute-Based Access Control (https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html)
-// in the IAM User Guide.
-//
-// You can set the session tags as transitive. Transitive tags persist during
-// role chaining. For more information, see Chaining Roles with Session Tags
-// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
-// in the IAM User Guide.
-//
-// Using MFA with AssumeRole
-//
-// (Optional) You can include multi-factor authentication (MFA) information
-// when you call AssumeRole. This is useful for cross-account scenarios to ensure
-// that the user that assumes the role has been authenticated with an AWS MFA
-// device. In that scenario, the trust policy of the role being assumed includes
-// a condition that tests for MFA authentication. If the caller does not include
-// valid MFA information, the request to assume the role is denied. The condition
-// in a trust policy that tests for MFA authentication might look like the following
-// example.
-//
-// "Condition": {"Bool": {"aws:MultiFactorAuthPresent": true}}
-//
-// For more information, see Configuring MFA-Protected API Access (https://docs.aws.amazon.com/IAM/latest/UserGuide/MFAProtectedAPI.html)
-// in the IAM User Guide guide.
-//
-// To use MFA with AssumeRole, you pass values for the SerialNumber and TokenCode
-// parameters. The SerialNumber value identifies the user's hardware or virtual
-// MFA device. The TokenCode is the time-based one-time password (TOTP) that
-// the MFA device produces.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for AWS Security Token Service's
-// API operation AssumeRole for usage and error information.
-//
-// Returned Error Codes:
-// * ErrCodeMalformedPolicyDocumentException "MalformedPolicyDocument"
-// The request was rejected because the policy document was malformed. The error
-// message describes the specific error.
-//
-// * ErrCodePackedPolicyTooLargeException "PackedPolicyTooLarge"
-// The request was rejected because the total packed size of the session policies
-// and session tags combined was too large. An AWS conversion compresses the
-// session policy document, session policy ARNs, and session tags into a packed
-// binary format that has a separate limit. The error message indicates by percentage
-// how close the policies and tags are to the upper size limit. For more information,
-// see Passing Session Tags in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-//
-// You could receive this error even though you meet other defined session policy
-// and session tag limits. For more information, see IAM and STS Entity Character
-// Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// * ErrCodeRegionDisabledException "RegionDisabledException"
-// STS is not activated in the requested region for the account that is being
-// asked to generate credentials. The account administrator must use the IAM
-// console to activate STS in that region. For more information, see Activating
-// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// * ErrCodeExpiredTokenException "ExpiredTokenException"
-// The web identity token that was passed is expired or is not valid. Get a
-// new identity token from the identity provider and then retry the request.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRole
-func (c *STS) AssumeRole(input *AssumeRoleInput) (*AssumeRoleOutput, error) {
- req, out := c.AssumeRoleRequest(input)
- return out, req.Send()
-}
-
-// AssumeRoleWithContext is the same as AssumeRole with the addition of
-// the ability to pass a context and additional request options.
-//
-// See AssumeRole for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *STS) AssumeRoleWithContext(ctx aws.Context, input *AssumeRoleInput, opts ...request.Option) (*AssumeRoleOutput, error) {
- req, out := c.AssumeRoleRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opAssumeRoleWithSAML = "AssumeRoleWithSAML"
-
-// AssumeRoleWithSAMLRequest generates a "aws/request.Request" representing the
-// client's request for the AssumeRoleWithSAML operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See AssumeRoleWithSAML for more information on using the AssumeRoleWithSAML
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the AssumeRoleWithSAMLRequest method.
-// req, resp := client.AssumeRoleWithSAMLRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithSAML
-func (c *STS) AssumeRoleWithSAMLRequest(input *AssumeRoleWithSAMLInput) (req *request.Request, output *AssumeRoleWithSAMLOutput) {
- op := &request.Operation{
- Name: opAssumeRoleWithSAML,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &AssumeRoleWithSAMLInput{}
- }
-
- output = &AssumeRoleWithSAMLOutput{}
- req = c.newRequest(op, input, output)
- req.Config.Credentials = credentials.AnonymousCredentials
- return
-}
-
-// AssumeRoleWithSAML API operation for AWS Security Token Service.
-//
-// Returns a set of temporary security credentials for users who have been authenticated
-// via a SAML authentication response. This operation provides a mechanism for
-// tying an enterprise identity store or directory to role-based AWS access
-// without user-specific credentials or configuration. For a comparison of AssumeRoleWithSAML
-// with the other API operations that produce temporary credentials, see Requesting
-// Temporary Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
-// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
-// in the IAM User Guide.
-//
-// The temporary security credentials returned by this operation consist of
-// an access key ID, a secret access key, and a security token. Applications
-// can use these temporary security credentials to sign calls to AWS services.
-//
-// Session Duration
-//
-// By default, the temporary security credentials created by AssumeRoleWithSAML
-// last for one hour. However, you can use the optional DurationSeconds parameter
-// to specify the duration of your session. Your role session lasts for the
-// duration that you specify, or until the time specified in the SAML authentication
-// response's SessionNotOnOrAfter value, whichever is shorter. You can provide
-// a DurationSeconds value from 900 seconds (15 minutes) up to the maximum session
-// duration setting for the role. This setting can have a value from 1 hour
-// to 12 hours. To learn how to view the maximum value for your role, see View
-// the Maximum Session Duration Setting for a Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
-// in the IAM User Guide. The maximum session duration limit applies when you
-// use the AssumeRole* API operations or the assume-role* CLI commands. However
-// the limit does not apply when you use those operations to create a console
-// URL. For more information, see Using IAM Roles (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html)
-// in the IAM User Guide.
-//
-// Permissions
-//
-// The temporary security credentials created by AssumeRoleWithSAML can be used
-// to make API calls to any AWS service with the following exception: you cannot
-// call the STS GetFederationToken or GetSessionToken API operations.
-//
-// (Optional) You can pass inline or managed session policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
-// to this operation. You can pass a single JSON policy document to use as an
-// inline session policy. You can also specify up to 10 managed policies to
-// use as managed session policies. The plain text that you use for both inline
-// and managed session policies can't exceed 2,048 characters. Passing policies
-// to this operation returns new temporary credentials. The resulting session's
-// permissions are the intersection of the role's identity-based policy and
-// the session policies. You can use the role's temporary credentials in subsequent
-// AWS API calls to access resources in the account that owns the role. You
-// cannot use session policies to grant more permissions than those allowed
-// by the identity-based policy of the role that is being assumed. For more
-// information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
-// in the IAM User Guide.
-//
-// Calling AssumeRoleWithSAML does not require the use of AWS security credentials.
-// The identity of the caller is validated by using keys in the metadata document
-// that is uploaded for the SAML provider entity for your identity provider.
-//
-// Calling AssumeRoleWithSAML can result in an entry in your AWS CloudTrail
-// logs. The entry includes the value in the NameID element of the SAML assertion.
-// We recommend that you use a NameIDType that is not associated with any personally
-// identifiable information (PII). For example, you could instead use the persistent
-// identifier (urn:oasis:names:tc:SAML:2.0:nameid-format:persistent).
-//
-// Tags
-//
-// (Optional) You can configure your IdP to pass attributes into your SAML assertion
-// as session tags. Each session tag consists of a key name and an associated
-// value. For more information about session tags, see Passing Session Tags
-// in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-//
-// You can pass up to 50 session tags. The plain text session tag keys can’t
-// exceed 128 characters and the values can’t exceed 256 characters. For these
-// and additional limits, see IAM and STS Character Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
-// in the IAM User Guide.
-//
-// An AWS conversion compresses the passed session policies and session tags
-// into a packed binary format that has a separate limit. Your request can fail
-// for this limit even if your plain text meets the other requirements. The
-// PackedPolicySize response element indicates by percentage how close the policies
-// and tags for your request are to the upper size limit.
-//
-// You can pass a session tag with the same key as a tag that is attached to
-// the role. When you do, session tags override the role's tags with the same
-// key.
-//
-// An administrator must grant you the permissions necessary to pass session
-// tags. The administrator can also create granular permissions to allow you
-// to pass only specific session tags. For more information, see Tutorial: Using
-// Tags for Attribute-Based Access Control (https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html)
-// in the IAM User Guide.
-//
-// You can set the session tags as transitive. Transitive tags persist during
-// role chaining. For more information, see Chaining Roles with Session Tags
-// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
-// in the IAM User Guide.
-//
-// SAML Configuration
-//
-// Before your application can call AssumeRoleWithSAML, you must configure your
-// SAML identity provider (IdP) to issue the claims required by AWS. Additionally,
-// you must use AWS Identity and Access Management (IAM) to create a SAML provider
-// entity in your AWS account that represents your identity provider. You must
-// also create an IAM role that specifies this SAML provider in its trust policy.
-//
-// For more information, see the following resources:
-//
-// * About SAML 2.0-based Federation (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_saml.html)
-// in the IAM User Guide.
-//
-// * Creating SAML Identity Providers (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml.html)
-// in the IAM User Guide.
-//
-// * Configuring a Relying Party and Claims (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml_relying-party.html)
-// in the IAM User Guide.
-//
-// * Creating a Role for SAML 2.0 Federation (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-idp_saml.html)
-// in the IAM User Guide.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for AWS Security Token Service's
-// API operation AssumeRoleWithSAML for usage and error information.
-//
-// Returned Error Codes:
-// * ErrCodeMalformedPolicyDocumentException "MalformedPolicyDocument"
-// The request was rejected because the policy document was malformed. The error
-// message describes the specific error.
-//
-// * ErrCodePackedPolicyTooLargeException "PackedPolicyTooLarge"
-// The request was rejected because the total packed size of the session policies
-// and session tags combined was too large. An AWS conversion compresses the
-// session policy document, session policy ARNs, and session tags into a packed
-// binary format that has a separate limit. The error message indicates by percentage
-// how close the policies and tags are to the upper size limit. For more information,
-// see Passing Session Tags in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-//
-// You could receive this error even though you meet other defined session policy
-// and session tag limits. For more information, see IAM and STS Entity Character
-// Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// * ErrCodeIDPRejectedClaimException "IDPRejectedClaim"
-// The identity provider (IdP) reported that authentication failed. This might
-// be because the claim is invalid.
-//
-// If this error is returned for the AssumeRoleWithWebIdentity operation, it
-// can also mean that the claim has expired or has been explicitly revoked.
-//
-// * ErrCodeInvalidIdentityTokenException "InvalidIdentityToken"
-// The web identity token that was passed could not be validated by AWS. Get
-// a new identity token from the identity provider and then retry the request.
-//
-// * ErrCodeExpiredTokenException "ExpiredTokenException"
-// The web identity token that was passed is expired or is not valid. Get a
-// new identity token from the identity provider and then retry the request.
-//
-// * ErrCodeRegionDisabledException "RegionDisabledException"
-// STS is not activated in the requested region for the account that is being
-// asked to generate credentials. The account administrator must use the IAM
-// console to activate STS in that region. For more information, see Activating
-// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithSAML
-func (c *STS) AssumeRoleWithSAML(input *AssumeRoleWithSAMLInput) (*AssumeRoleWithSAMLOutput, error) {
- req, out := c.AssumeRoleWithSAMLRequest(input)
- return out, req.Send()
-}
-
-// AssumeRoleWithSAMLWithContext is the same as AssumeRoleWithSAML with the addition of
-// the ability to pass a context and additional request options.
-//
-// See AssumeRoleWithSAML for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *STS) AssumeRoleWithSAMLWithContext(ctx aws.Context, input *AssumeRoleWithSAMLInput, opts ...request.Option) (*AssumeRoleWithSAMLOutput, error) {
- req, out := c.AssumeRoleWithSAMLRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opAssumeRoleWithWebIdentity = "AssumeRoleWithWebIdentity"
-
-// AssumeRoleWithWebIdentityRequest generates a "aws/request.Request" representing the
-// client's request for the AssumeRoleWithWebIdentity operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See AssumeRoleWithWebIdentity for more information on using the AssumeRoleWithWebIdentity
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the AssumeRoleWithWebIdentityRequest method.
-// req, resp := client.AssumeRoleWithWebIdentityRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithWebIdentity
-func (c *STS) AssumeRoleWithWebIdentityRequest(input *AssumeRoleWithWebIdentityInput) (req *request.Request, output *AssumeRoleWithWebIdentityOutput) {
- op := &request.Operation{
- Name: opAssumeRoleWithWebIdentity,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &AssumeRoleWithWebIdentityInput{}
- }
-
- output = &AssumeRoleWithWebIdentityOutput{}
- req = c.newRequest(op, input, output)
- req.Config.Credentials = credentials.AnonymousCredentials
- return
-}
-
-// AssumeRoleWithWebIdentity API operation for AWS Security Token Service.
-//
-// Returns a set of temporary security credentials for users who have been authenticated
-// in a mobile or web application with a web identity provider. Example providers
-// include Amazon Cognito, Login with Amazon, Facebook, Google, or any OpenID
-// Connect-compatible identity provider.
-//
-// For mobile applications, we recommend that you use Amazon Cognito. You can
-// use Amazon Cognito with the AWS SDK for iOS Developer Guide (http://aws.amazon.com/sdkforios/)
-// and the AWS SDK for Android Developer Guide (http://aws.amazon.com/sdkforandroid/)
-// to uniquely identify a user. You can also supply the user with a consistent
-// identity throughout the lifetime of an application.
-//
-// To learn more about Amazon Cognito, see Amazon Cognito Overview (https://docs.aws.amazon.com/mobile/sdkforandroid/developerguide/cognito-auth.html#d0e840)
-// in AWS SDK for Android Developer Guide and Amazon Cognito Overview (https://docs.aws.amazon.com/mobile/sdkforios/developerguide/cognito-auth.html#d0e664)
-// in the AWS SDK for iOS Developer Guide.
-//
-// Calling AssumeRoleWithWebIdentity does not require the use of AWS security
-// credentials. Therefore, you can distribute an application (for example, on
-// mobile devices) that requests temporary security credentials without including
-// long-term AWS credentials in the application. You also don't need to deploy
-// server-based proxy services that use long-term AWS credentials. Instead,
-// the identity of the caller is validated by using a token from the web identity
-// provider. For a comparison of AssumeRoleWithWebIdentity with the other API
-// operations that produce temporary credentials, see Requesting Temporary Security
-// Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
-// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
-// in the IAM User Guide.
-//
-// The temporary security credentials returned by this API consist of an access
-// key ID, a secret access key, and a security token. Applications can use these
-// temporary security credentials to sign calls to AWS service API operations.
-//
-// Session Duration
-//
-// By default, the temporary security credentials created by AssumeRoleWithWebIdentity
-// last for one hour. However, you can use the optional DurationSeconds parameter
-// to specify the duration of your session. You can provide a value from 900
-// seconds (15 minutes) up to the maximum session duration setting for the role.
-// This setting can have a value from 1 hour to 12 hours. To learn how to view
-// the maximum value for your role, see View the Maximum Session Duration Setting
-// for a Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
-// in the IAM User Guide. The maximum session duration limit applies when you
-// use the AssumeRole* API operations or the assume-role* CLI commands. However
-// the limit does not apply when you use those operations to create a console
-// URL. For more information, see Using IAM Roles (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html)
-// in the IAM User Guide.
-//
-// Permissions
-//
-// The temporary security credentials created by AssumeRoleWithWebIdentity can
-// be used to make API calls to any AWS service with the following exception:
-// you cannot call the STS GetFederationToken or GetSessionToken API operations.
-//
-// (Optional) You can pass inline or managed session policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
-// to this operation. You can pass a single JSON policy document to use as an
-// inline session policy. You can also specify up to 10 managed policies to
-// use as managed session policies. The plain text that you use for both inline
-// and managed session policies can't exceed 2,048 characters. Passing policies
-// to this operation returns new temporary credentials. The resulting session's
-// permissions are the intersection of the role's identity-based policy and
-// the session policies. You can use the role's temporary credentials in subsequent
-// AWS API calls to access resources in the account that owns the role. You
-// cannot use session policies to grant more permissions than those allowed
-// by the identity-based policy of the role that is being assumed. For more
-// information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
-// in the IAM User Guide.
-//
-// Tags
-//
-// (Optional) You can configure your IdP to pass attributes into your web identity
-// token as session tags. Each session tag consists of a key name and an associated
-// value. For more information about session tags, see Passing Session Tags
-// in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-//
-// You can pass up to 50 session tags. The plain text session tag keys can’t
-// exceed 128 characters and the values can’t exceed 256 characters. For these
-// and additional limits, see IAM and STS Character Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
-// in the IAM User Guide.
-//
-// An AWS conversion compresses the passed session policies and session tags
-// into a packed binary format that has a separate limit. Your request can fail
-// for this limit even if your plain text meets the other requirements. The
-// PackedPolicySize response element indicates by percentage how close the policies
-// and tags for your request are to the upper size limit.
-//
-// You can pass a session tag with the same key as a tag that is attached to
-// the role. When you do, the session tag overrides the role tag with the same
-// key.
-//
-// An administrator must grant you the permissions necessary to pass session
-// tags. The administrator can also create granular permissions to allow you
-// to pass only specific session tags. For more information, see Tutorial: Using
-// Tags for Attribute-Based Access Control (https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html)
-// in the IAM User Guide.
-//
-// You can set the session tags as transitive. Transitive tags persist during
-// role chaining. For more information, see Chaining Roles with Session Tags
-// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
-// in the IAM User Guide.
-//
-// Identities
-//
-// Before your application can call AssumeRoleWithWebIdentity, you must have
-// an identity token from a supported identity provider and create a role that
-// the application can assume. The role that your application assumes must trust
-// the identity provider that is associated with the identity token. In other
-// words, the identity provider must be specified in the role's trust policy.
-//
-// Calling AssumeRoleWithWebIdentity can result in an entry in your AWS CloudTrail
-// logs. The entry includes the Subject (http://openid.net/specs/openid-connect-core-1_0.html#Claims)
-// of the provided Web Identity Token. We recommend that you avoid using any
-// personally identifiable information (PII) in this field. For example, you
-// could instead use a GUID or a pairwise identifier, as suggested in the OIDC
-// specification (http://openid.net/specs/openid-connect-core-1_0.html#SubjectIDTypes).
-//
-// For more information about how to use web identity federation and the AssumeRoleWithWebIdentity
-// API, see the following resources:
-//
-// * Using Web Identity Federation API Operations for Mobile Apps (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_oidc_manual.html)
-// and Federation Through a Web-based Identity Provider (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity).
-//
-// * Web Identity Federation Playground (https://aws.amazon.com/blogs/aws/the-aws-web-identity-federation-playground/).
-// Walk through the process of authenticating through Login with Amazon,
-// Facebook, or Google, getting temporary security credentials, and then
-// using those credentials to make a request to AWS.
-//
-// * AWS SDK for iOS Developer Guide (http://aws.amazon.com/sdkforios/) and
-// AWS SDK for Android Developer Guide (http://aws.amazon.com/sdkforandroid/).
-// These toolkits contain sample apps that show how to invoke the identity
-// providers. The toolkits then show how to use the information from these
-// providers to get and use temporary security credentials.
-//
-// * Web Identity Federation with Mobile Applications (http://aws.amazon.com/articles/web-identity-federation-with-mobile-applications).
-// This article discusses web identity federation and shows an example of
-// how to use web identity federation to get access to content in Amazon
-// S3.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for AWS Security Token Service's
-// API operation AssumeRoleWithWebIdentity for usage and error information.
-//
-// Returned Error Codes:
-// * ErrCodeMalformedPolicyDocumentException "MalformedPolicyDocument"
-// The request was rejected because the policy document was malformed. The error
-// message describes the specific error.
-//
-// * ErrCodePackedPolicyTooLargeException "PackedPolicyTooLarge"
-// The request was rejected because the total packed size of the session policies
-// and session tags combined was too large. An AWS conversion compresses the
-// session policy document, session policy ARNs, and session tags into a packed
-// binary format that has a separate limit. The error message indicates by percentage
-// how close the policies and tags are to the upper size limit. For more information,
-// see Passing Session Tags in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-//
-// You could receive this error even though you meet other defined session policy
-// and session tag limits. For more information, see IAM and STS Entity Character
-// Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// * ErrCodeIDPRejectedClaimException "IDPRejectedClaim"
-// The identity provider (IdP) reported that authentication failed. This might
-// be because the claim is invalid.
-//
-// If this error is returned for the AssumeRoleWithWebIdentity operation, it
-// can also mean that the claim has expired or has been explicitly revoked.
-//
-// * ErrCodeIDPCommunicationErrorException "IDPCommunicationError"
-// The request could not be fulfilled because the identity provider (IDP) that
-// was asked to verify the incoming identity token could not be reached. This
-// is often a transient error caused by network conditions. Retry the request
-// a limited number of times so that you don't exceed the request rate. If the
-// error persists, the identity provider might be down or not responding.
-//
-// * ErrCodeInvalidIdentityTokenException "InvalidIdentityToken"
-// The web identity token that was passed could not be validated by AWS. Get
-// a new identity token from the identity provider and then retry the request.
-//
-// * ErrCodeExpiredTokenException "ExpiredTokenException"
-// The web identity token that was passed is expired or is not valid. Get a
-// new identity token from the identity provider and then retry the request.
-//
-// * ErrCodeRegionDisabledException "RegionDisabledException"
-// STS is not activated in the requested region for the account that is being
-// asked to generate credentials. The account administrator must use the IAM
-// console to activate STS in that region. For more information, see Activating
-// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithWebIdentity
-func (c *STS) AssumeRoleWithWebIdentity(input *AssumeRoleWithWebIdentityInput) (*AssumeRoleWithWebIdentityOutput, error) {
- req, out := c.AssumeRoleWithWebIdentityRequest(input)
- return out, req.Send()
-}
-
-// AssumeRoleWithWebIdentityWithContext is the same as AssumeRoleWithWebIdentity with the addition of
-// the ability to pass a context and additional request options.
-//
-// See AssumeRoleWithWebIdentity for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *STS) AssumeRoleWithWebIdentityWithContext(ctx aws.Context, input *AssumeRoleWithWebIdentityInput, opts ...request.Option) (*AssumeRoleWithWebIdentityOutput, error) {
- req, out := c.AssumeRoleWithWebIdentityRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opDecodeAuthorizationMessage = "DecodeAuthorizationMessage"
-
-// DecodeAuthorizationMessageRequest generates a "aws/request.Request" representing the
-// client's request for the DecodeAuthorizationMessage operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See DecodeAuthorizationMessage for more information on using the DecodeAuthorizationMessage
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the DecodeAuthorizationMessageRequest method.
-// req, resp := client.DecodeAuthorizationMessageRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/DecodeAuthorizationMessage
-func (c *STS) DecodeAuthorizationMessageRequest(input *DecodeAuthorizationMessageInput) (req *request.Request, output *DecodeAuthorizationMessageOutput) {
- op := &request.Operation{
- Name: opDecodeAuthorizationMessage,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &DecodeAuthorizationMessageInput{}
- }
-
- output = &DecodeAuthorizationMessageOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// DecodeAuthorizationMessage API operation for AWS Security Token Service.
-//
-// Decodes additional information about the authorization status of a request
-// from an encoded message returned in response to an AWS request.
-//
-// For example, if a user is not authorized to perform an operation that he
-// or she has requested, the request returns a Client.UnauthorizedOperation
-// response (an HTTP 403 response). Some AWS operations additionally return
-// an encoded message that can provide details about this authorization failure.
-//
-// Only certain AWS operations return an encoded authorization message. The
-// documentation for an individual operation indicates whether that operation
-// returns an encoded message in addition to returning an HTTP code.
-//
-// The message is encoded because the details of the authorization status can
-// constitute privileged information that the user who requested the operation
-// should not see. To decode an authorization status message, a user must be
-// granted permissions via an IAM policy to request the DecodeAuthorizationMessage
-// (sts:DecodeAuthorizationMessage) action.
-//
-// The decoded message includes the following type of information:
-//
-// * Whether the request was denied due to an explicit deny or due to the
-// absence of an explicit allow. For more information, see Determining Whether
-// a Request is Allowed or Denied (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html#policy-eval-denyallow)
-// in the IAM User Guide.
-//
-// * The principal who made the request.
-//
-// * The requested action.
-//
-// * The requested resource.
-//
-// * The values of condition keys in the context of the user's request.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for AWS Security Token Service's
-// API operation DecodeAuthorizationMessage for usage and error information.
-//
-// Returned Error Codes:
-// * ErrCodeInvalidAuthorizationMessageException "InvalidAuthorizationMessageException"
-// The error returned if the message passed to DecodeAuthorizationMessage was
-// invalid. This can happen if the token contains invalid characters, such as
-// linebreaks.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/DecodeAuthorizationMessage
-func (c *STS) DecodeAuthorizationMessage(input *DecodeAuthorizationMessageInput) (*DecodeAuthorizationMessageOutput, error) {
- req, out := c.DecodeAuthorizationMessageRequest(input)
- return out, req.Send()
-}
-
-// DecodeAuthorizationMessageWithContext is the same as DecodeAuthorizationMessage with the addition of
-// the ability to pass a context and additional request options.
-//
-// See DecodeAuthorizationMessage for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *STS) DecodeAuthorizationMessageWithContext(ctx aws.Context, input *DecodeAuthorizationMessageInput, opts ...request.Option) (*DecodeAuthorizationMessageOutput, error) {
- req, out := c.DecodeAuthorizationMessageRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opGetAccessKeyInfo = "GetAccessKeyInfo"
-
-// GetAccessKeyInfoRequest generates a "aws/request.Request" representing the
-// client's request for the GetAccessKeyInfo operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetAccessKeyInfo for more information on using the GetAccessKeyInfo
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetAccessKeyInfoRequest method.
-// req, resp := client.GetAccessKeyInfoRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetAccessKeyInfo
-func (c *STS) GetAccessKeyInfoRequest(input *GetAccessKeyInfoInput) (req *request.Request, output *GetAccessKeyInfoOutput) {
- op := &request.Operation{
- Name: opGetAccessKeyInfo,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &GetAccessKeyInfoInput{}
- }
-
- output = &GetAccessKeyInfoOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetAccessKeyInfo API operation for AWS Security Token Service.
-//
-// Returns the account identifier for the specified access key ID.
-//
-// Access keys consist of two parts: an access key ID (for example, AKIAIOSFODNN7EXAMPLE)
-// and a secret access key (for example, wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY).
-// For more information about access keys, see Managing Access Keys for IAM
-// Users (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html)
-// in the IAM User Guide.
-//
-// When you pass an access key ID to this operation, it returns the ID of the
-// AWS account to which the keys belong. Access key IDs beginning with AKIA
-// are long-term credentials for an IAM user or the AWS account root user. Access
-// key IDs beginning with ASIA are temporary credentials that are created using
-// STS operations. If the account in the response belongs to you, you can sign
-// in as the root user and review your root user access keys. Then, you can
-// pull a credentials report (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_getting-report.html)
-// to learn which IAM user owns the keys. To learn who requested the temporary
-// credentials for an ASIA access key, view the STS events in your CloudTrail
-// logs (https://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail-integration.html)
-// in the IAM User Guide.
-//
-// This operation does not indicate the state of the access key. The key might
-// be active, inactive, or deleted. Active keys might not have permissions to
-// perform an operation. Providing a deleted access key might return an error
-// that the key doesn't exist.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for AWS Security Token Service's
-// API operation GetAccessKeyInfo for usage and error information.
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetAccessKeyInfo
-func (c *STS) GetAccessKeyInfo(input *GetAccessKeyInfoInput) (*GetAccessKeyInfoOutput, error) {
- req, out := c.GetAccessKeyInfoRequest(input)
- return out, req.Send()
-}
-
-// GetAccessKeyInfoWithContext is the same as GetAccessKeyInfo with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetAccessKeyInfo for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *STS) GetAccessKeyInfoWithContext(ctx aws.Context, input *GetAccessKeyInfoInput, opts ...request.Option) (*GetAccessKeyInfoOutput, error) {
- req, out := c.GetAccessKeyInfoRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opGetCallerIdentity = "GetCallerIdentity"
-
-// GetCallerIdentityRequest generates a "aws/request.Request" representing the
-// client's request for the GetCallerIdentity operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetCallerIdentity for more information on using the GetCallerIdentity
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetCallerIdentityRequest method.
-// req, resp := client.GetCallerIdentityRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetCallerIdentity
-func (c *STS) GetCallerIdentityRequest(input *GetCallerIdentityInput) (req *request.Request, output *GetCallerIdentityOutput) {
- op := &request.Operation{
- Name: opGetCallerIdentity,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &GetCallerIdentityInput{}
- }
-
- output = &GetCallerIdentityOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetCallerIdentity API operation for AWS Security Token Service.
-//
-// Returns details about the IAM user or role whose credentials are used to
-// call the operation.
-//
-// No permissions are required to perform this operation. If an administrator
-// adds a policy to your IAM user or role that explicitly denies access to the
-// sts:GetCallerIdentity action, you can still perform this operation. Permissions
-// are not required because the same information is returned when an IAM user
-// or role is denied access. To view an example response, see I Am Not Authorized
-// to Perform: iam:DeleteVirtualMFADevice (https://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_access-denied-delete-mfa)
-// in the IAM User Guide.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for AWS Security Token Service's
-// API operation GetCallerIdentity for usage and error information.
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetCallerIdentity
-func (c *STS) GetCallerIdentity(input *GetCallerIdentityInput) (*GetCallerIdentityOutput, error) {
- req, out := c.GetCallerIdentityRequest(input)
- return out, req.Send()
-}
-
-// GetCallerIdentityWithContext is the same as GetCallerIdentity with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetCallerIdentity for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *STS) GetCallerIdentityWithContext(ctx aws.Context, input *GetCallerIdentityInput, opts ...request.Option) (*GetCallerIdentityOutput, error) {
- req, out := c.GetCallerIdentityRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opGetFederationToken = "GetFederationToken"
-
-// GetFederationTokenRequest generates a "aws/request.Request" representing the
-// client's request for the GetFederationToken operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetFederationToken for more information on using the GetFederationToken
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetFederationTokenRequest method.
-// req, resp := client.GetFederationTokenRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetFederationToken
-func (c *STS) GetFederationTokenRequest(input *GetFederationTokenInput) (req *request.Request, output *GetFederationTokenOutput) {
- op := &request.Operation{
- Name: opGetFederationToken,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &GetFederationTokenInput{}
- }
-
- output = &GetFederationTokenOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetFederationToken API operation for AWS Security Token Service.
-//
-// Returns a set of temporary security credentials (consisting of an access
-// key ID, a secret access key, and a security token) for a federated user.
-// A typical use is in a proxy application that gets temporary security credentials
-// on behalf of distributed applications inside a corporate network. You must
-// call the GetFederationToken operation using the long-term security credentials
-// of an IAM user. As a result, this call is appropriate in contexts where those
-// credentials can be safely stored, usually in a server-based application.
-// For a comparison of GetFederationToken with the other API operations that
-// produce temporary credentials, see Requesting Temporary Security Credentials
-// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
-// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
-// in the IAM User Guide.
-//
-// You can create a mobile-based or browser-based app that can authenticate
-// users using a web identity provider like Login with Amazon, Facebook, Google,
-// or an OpenID Connect-compatible identity provider. In this case, we recommend
-// that you use Amazon Cognito (http://aws.amazon.com/cognito/) or AssumeRoleWithWebIdentity.
-// For more information, see Federation Through a Web-based Identity Provider
-// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity)
-// in the IAM User Guide.
-//
-// You can also call GetFederationToken using the security credentials of an
-// AWS account root user, but we do not recommend it. Instead, we recommend
-// that you create an IAM user for the purpose of the proxy application. Then
-// attach a policy to the IAM user that limits federated users to only the actions
-// and resources that they need to access. For more information, see IAM Best
-// Practices (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html)
-// in the IAM User Guide.
-//
-// Session duration
-//
-// The temporary credentials are valid for the specified duration, from 900
-// seconds (15 minutes) up to a maximum of 129,600 seconds (36 hours). The default
-// session duration is 43,200 seconds (12 hours). Temporary credentials that
-// are obtained by using AWS account root user credentials have a maximum duration
-// of 3,600 seconds (1 hour).
-//
-// Permissions
-//
-// You can use the temporary credentials created by GetFederationToken in any
-// AWS service except the following:
-//
-// * You cannot call any IAM operations using the AWS CLI or the AWS API.
-//
-// * You cannot call any STS operations except GetCallerIdentity.
-//
-// You must pass an inline or managed session policy (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
-// to this operation. You can pass a single JSON policy document to use as an
-// inline session policy. You can also specify up to 10 managed policies to
-// use as managed session policies. The plain text that you use for both inline
-// and managed session policies can't exceed 2,048 characters.
-//
-// Though the session policy parameters are optional, if you do not pass a policy,
-// then the resulting federated user session has no permissions. When you pass
-// session policies, the session permissions are the intersection of the IAM
-// user policies and the session policies that you pass. This gives you a way
-// to further restrict the permissions for a federated user. You cannot use
-// session policies to grant more permissions than those that are defined in
-// the permissions policy of the IAM user. For more information, see Session
-// Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
-// in the IAM User Guide. For information about using GetFederationToken to
-// create temporary security credentials, see GetFederationToken—Federation
-// Through a Custom Identity Broker (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getfederationtoken).
-//
-// You can use the credentials to access a resource that has a resource-based
-// policy. If that policy specifically references the federated user session
-// in the Principal element of the policy, the session has the permissions allowed
-// by the policy. These permissions are granted in addition to the permissions
-// granted by the session policies.
-//
-// Tags
-//
-// (Optional) You can pass tag key-value pairs to your session. These are called
-// session tags. For more information about session tags, see Passing Session
-// Tags in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-//
-// An administrator must grant you the permissions necessary to pass session
-// tags. The administrator can also create granular permissions to allow you
-// to pass only specific session tags. For more information, see Tutorial: Using
-// Tags for Attribute-Based Access Control (https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html)
-// in the IAM User Guide.
-//
-// Tag key–value pairs are not case sensitive, but case is preserved. This
-// means that you cannot have separate Department and department tag keys. Assume
-// that the user that you are federating has the Department=Marketing tag and
-// you pass the department=engineering session tag. Department and department
-// are not saved as separate tags, and the session tag passed in the request
-// takes precedence over the user tag.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for AWS Security Token Service's
-// API operation GetFederationToken for usage and error information.
-//
-// Returned Error Codes:
-// * ErrCodeMalformedPolicyDocumentException "MalformedPolicyDocument"
-// The request was rejected because the policy document was malformed. The error
-// message describes the specific error.
-//
-// * ErrCodePackedPolicyTooLargeException "PackedPolicyTooLarge"
-// The request was rejected because the total packed size of the session policies
-// and session tags combined was too large. An AWS conversion compresses the
-// session policy document, session policy ARNs, and session tags into a packed
-// binary format that has a separate limit. The error message indicates by percentage
-// how close the policies and tags are to the upper size limit. For more information,
-// see Passing Session Tags in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-//
-// You could receive this error even though you meet other defined session policy
-// and session tag limits. For more information, see IAM and STS Entity Character
-// Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// * ErrCodeRegionDisabledException "RegionDisabledException"
-// STS is not activated in the requested region for the account that is being
-// asked to generate credentials. The account administrator must use the IAM
-// console to activate STS in that region. For more information, see Activating
-// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetFederationToken
-func (c *STS) GetFederationToken(input *GetFederationTokenInput) (*GetFederationTokenOutput, error) {
- req, out := c.GetFederationTokenRequest(input)
- return out, req.Send()
-}
-
-// GetFederationTokenWithContext is the same as GetFederationToken with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetFederationToken for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *STS) GetFederationTokenWithContext(ctx aws.Context, input *GetFederationTokenInput, opts ...request.Option) (*GetFederationTokenOutput, error) {
- req, out := c.GetFederationTokenRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-const opGetSessionToken = "GetSessionToken"
-
-// GetSessionTokenRequest generates a "aws/request.Request" representing the
-// client's request for the GetSessionToken operation. The "output" return
-// value will be populated with the request's response once the request completes
-// successfully.
-//
-// Use "Send" method on the returned Request to send the API call to the service.
-// the "output" return value is not valid until after Send returns without error.
-//
-// See GetSessionToken for more information on using the GetSessionToken
-// API call, and error handling.
-//
-// This method is useful when you want to inject custom logic or configuration
-// into the SDK's request lifecycle. Such as custom headers, or retry logic.
-//
-//
-// // Example sending a request using the GetSessionTokenRequest method.
-// req, resp := client.GetSessionTokenRequest(params)
-//
-// err := req.Send()
-// if err == nil { // resp is now filled
-// fmt.Println(resp)
-// }
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetSessionToken
-func (c *STS) GetSessionTokenRequest(input *GetSessionTokenInput) (req *request.Request, output *GetSessionTokenOutput) {
- op := &request.Operation{
- Name: opGetSessionToken,
- HTTPMethod: "POST",
- HTTPPath: "/",
- }
-
- if input == nil {
- input = &GetSessionTokenInput{}
- }
-
- output = &GetSessionTokenOutput{}
- req = c.newRequest(op, input, output)
- return
-}
-
-// GetSessionToken API operation for AWS Security Token Service.
-//
-// Returns a set of temporary credentials for an AWS account or IAM user. The
-// credentials consist of an access key ID, a secret access key, and a security
-// token. Typically, you use GetSessionToken if you want to use MFA to protect
-// programmatic calls to specific AWS API operations like Amazon EC2 StopInstances.
-// MFA-enabled IAM users would need to call GetSessionToken and submit an MFA
-// code that is associated with their MFA device. Using the temporary security
-// credentials that are returned from the call, IAM users can then make programmatic
-// calls to API operations that require MFA authentication. If you do not supply
-// a correct MFA code, then the API returns an access denied error. For a comparison
-// of GetSessionToken with the other API operations that produce temporary credentials,
-// see Requesting Temporary Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
-// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
-// in the IAM User Guide.
-//
-// Session Duration
-//
-// The GetSessionToken operation must be called by using the long-term AWS security
-// credentials of the AWS account root user or an IAM user. Credentials that
-// are created by IAM users are valid for the duration that you specify. This
-// duration can range from 900 seconds (15 minutes) up to a maximum of 129,600
-// seconds (36 hours), with a default of 43,200 seconds (12 hours). Credentials
-// based on account credentials can range from 900 seconds (15 minutes) up to
-// 3,600 seconds (1 hour), with a default of 1 hour.
-//
-// Permissions
-//
-// The temporary security credentials created by GetSessionToken can be used
-// to make API calls to any AWS service with the following exceptions:
-//
-// * You cannot call any IAM API operations unless MFA authentication information
-// is included in the request.
-//
-// * You cannot call any STS API except AssumeRole or GetCallerIdentity.
-//
-// We recommend that you do not call GetSessionToken with AWS account root user
-// credentials. Instead, follow our best practices (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#create-iam-users)
-// by creating one or more IAM users, giving them the necessary permissions,
-// and using IAM users for everyday interaction with AWS.
-//
-// The credentials that are returned by GetSessionToken are based on permissions
-// associated with the user whose credentials were used to call the operation.
-// If GetSessionToken is called using AWS account root user credentials, the
-// temporary credentials have root user permissions. Similarly, if GetSessionToken
-// is called using the credentials of an IAM user, the temporary credentials
-// have the same permissions as the IAM user.
-//
-// For more information about using GetSessionToken to create temporary credentials,
-// go to Temporary Credentials for Users in Untrusted Environments (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getsessiontoken)
-// in the IAM User Guide.
-//
-// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
-// with awserr.Error's Code and Message methods to get detailed information about
-// the error.
-//
-// See the AWS API reference guide for AWS Security Token Service's
-// API operation GetSessionToken for usage and error information.
-//
-// Returned Error Codes:
-// * ErrCodeRegionDisabledException "RegionDisabledException"
-// STS is not activated in the requested region for the account that is being
-// asked to generate credentials. The account administrator must use the IAM
-// console to activate STS in that region. For more information, see Activating
-// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
-// in the IAM User Guide.
-//
-// See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetSessionToken
-func (c *STS) GetSessionToken(input *GetSessionTokenInput) (*GetSessionTokenOutput, error) {
- req, out := c.GetSessionTokenRequest(input)
- return out, req.Send()
-}
-
-// GetSessionTokenWithContext is the same as GetSessionToken with the addition of
-// the ability to pass a context and additional request options.
-//
-// See GetSessionToken for details on how to use this API operation.
-//
-// The context must be non-nil and will be used for request cancellation. If
-// the context is nil a panic will occur. In the future the SDK may create
-// sub-contexts for http.Requests. See https://golang.org/pkg/context/
-// for more information on using Contexts.
-func (c *STS) GetSessionTokenWithContext(ctx aws.Context, input *GetSessionTokenInput, opts ...request.Option) (*GetSessionTokenOutput, error) {
- req, out := c.GetSessionTokenRequest(input)
- req.SetContext(ctx)
- req.ApplyOptions(opts...)
- return out, req.Send()
-}
-
-type AssumeRoleInput struct {
- _ struct{} `type:"structure"`
-
- // The duration, in seconds, of the role session. The value can range from 900
- // seconds (15 minutes) up to the maximum session duration setting for the role.
- // This setting can have a value from 1 hour to 12 hours. If you specify a value
- // higher than this setting, the operation fails. For example, if you specify
- // a session duration of 12 hours, but your administrator set the maximum session
- // duration to 6 hours, your operation fails. To learn how to view the maximum
- // value for your role, see View the Maximum Session Duration Setting for a
- // Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
- // in the IAM User Guide.
- //
- // By default, the value is set to 3600 seconds.
- //
- // The DurationSeconds parameter is separate from the duration of a console
- // session that you might request using the returned credentials. The request
- // to the federation endpoint for a console sign-in token takes a SessionDuration
- // parameter that specifies the maximum length of the console session. For more
- // information, see Creating a URL that Enables Federated Users to Access the
- // AWS Management Console (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html)
- // in the IAM User Guide.
- DurationSeconds *int64 `min:"900" type:"integer"`
-
- // A unique identifier that might be required when you assume a role in another
- // account. If the administrator of the account to which the role belongs provided
- // you with an external ID, then provide that value in the ExternalId parameter.
- // This value can be any string, such as a passphrase or account number. A cross-account
- // role is usually set up to trust everyone in an account. Therefore, the administrator
- // of the trusting account might send an external ID to the administrator of
- // the trusted account. That way, only someone with the ID can assume the role,
- // rather than everyone in the account. For more information about the external
- // ID, see How to Use an External ID When Granting Access to Your AWS Resources
- // to a Third Party (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-user_externalid.html)
- // in the IAM User Guide.
- //
- // The regex used to validate this parameter is a string of characters consisting
- // of upper- and lower-case alphanumeric characters with no spaces. You can
- // also include underscores or any of the following characters: =,.@:/-
- ExternalId *string `min:"2" type:"string"`
-
- // An IAM policy in JSON format that you want to use as an inline session policy.
- //
- // This parameter is optional. Passing policies to this operation returns new
- // temporary credentials. The resulting session's permissions are the intersection
- // of the role's identity-based policy and the session policies. You can use
- // the role's temporary credentials in subsequent AWS API calls to access resources
- // in the account that owns the role. You cannot use session policies to grant
- // more permissions than those allowed by the identity-based policy of the role
- // that is being assumed. For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- //
- // The plain text that you use for both inline and managed session policies
- // can't exceed 2,048 characters. The JSON policy characters can be any ASCII
- // character from the space character to the end of the valid character list
- // (\u0020 through \u00FF). It can also include the tab (\u0009), linefeed (\u000A),
- // and carriage return (\u000D) characters.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- Policy *string `min:"1" type:"string"`
-
- // The Amazon Resource Names (ARNs) of the IAM managed policies that you want
- // to use as managed session policies. The policies must exist in the same account
- // as the role.
- //
- // This parameter is optional. You can provide up to 10 managed policy ARNs.
- // However, the plain text that you use for both inline and managed session
- // policies can't exceed 2,048 characters. For more information about ARNs,
- // see Amazon Resource Names (ARNs) and AWS Service Namespaces (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
- // in the AWS General Reference.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- //
- // Passing policies to this operation returns new temporary credentials. The
- // resulting session's permissions are the intersection of the role's identity-based
- // policy and the session policies. You can use the role's temporary credentials
- // in subsequent AWS API calls to access resources in the account that owns
- // the role. You cannot use session policies to grant more permissions than
- // those allowed by the identity-based policy of the role that is being assumed.
- // For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- PolicyArns []*PolicyDescriptorType `type:"list"`
-
- // The Amazon Resource Name (ARN) of the role to assume.
- //
- // RoleArn is a required field
- RoleArn *string `min:"20" type:"string" required:"true"`
-
- // An identifier for the assumed role session.
- //
- // Use the role session name to uniquely identify a session when the same role
- // is assumed by different principals or for different reasons. In cross-account
- // scenarios, the role session name is visible to, and can be logged by the
- // account that owns the role. The role session name is also used in the ARN
- // of the assumed role principal. This means that subsequent cross-account API
- // requests that use the temporary security credentials will expose the role
- // session name to the external account in their AWS CloudTrail logs.
- //
- // The regex used to validate this parameter is a string of characters consisting
- // of upper- and lower-case alphanumeric characters with no spaces. You can
- // also include underscores or any of the following characters: =,.@-
- //
- // RoleSessionName is a required field
- RoleSessionName *string `min:"2" type:"string" required:"true"`
-
- // The identification number of the MFA device that is associated with the user
- // who is making the AssumeRole call. Specify this value if the trust policy
- // of the role being assumed includes a condition that requires MFA authentication.
- // The value is either the serial number for a hardware device (such as GAHT12345678)
- // or an Amazon Resource Name (ARN) for a virtual device (such as arn:aws:iam::123456789012:mfa/user).
- //
- // The regex used to validate this parameter is a string of characters consisting
- // of upper- and lower-case alphanumeric characters with no spaces. You can
- // also include underscores or any of the following characters: =,.@-
- SerialNumber *string `min:"9" type:"string"`
-
- // A list of session tags that you want to pass. Each session tag consists of
- // a key name and an associated value. For more information about session tags,
- // see Tagging AWS STS Sessions (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
- // in the IAM User Guide.
- //
- // This parameter is optional. You can pass up to 50 session tags. The plain
- // text session tag keys can’t exceed 128 characters, and the values can’t
- // exceed 256 characters. For these and additional limits, see IAM and STS Character
- // Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
- // in the IAM User Guide.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- //
- // You can pass a session tag with the same key as a tag that is already attached
- // to the role. When you do, session tags override a role tag with the same
- // key.
- //
- // Tag key–value pairs are not case sensitive, but case is preserved. This
- // means that you cannot have separate Department and department tag keys. Assume
- // that the role has the Department=Marketing tag and you pass the department=engineering
- // session tag. Department and department are not saved as separate tags, and
- // the session tag passed in the request takes precedence over the role tag.
- //
- // Additionally, if you used temporary credentials to perform this operation,
- // the new session inherits any transitive session tags from the calling session.
- // If you pass a session tag with the same key as an inherited tag, the operation
- // fails. To view the inherited tags for a session, see the AWS CloudTrail logs.
- // For more information, see Viewing Session Tags in CloudTrail (https://docs.aws.amazon.com/IAM/latest/UserGuide/session-tags.html#id_session-tags_ctlogs)
- // in the IAM User Guide.
- Tags []*Tag `type:"list"`
-
- // The value provided by the MFA device, if the trust policy of the role being
- // assumed requires MFA (that is, if the policy includes a condition that tests
- // for MFA). If the role being assumed requires MFA and if the TokenCode value
- // is missing or expired, the AssumeRole call returns an "access denied" error.
- //
- // The format for this parameter, as described by its regex pattern, is a sequence
- // of six numeric digits.
- TokenCode *string `min:"6" type:"string"`
-
- // A list of keys for session tags that you want to set as transitive. If you
- // set a tag key as transitive, the corresponding key and value passes to subsequent
- // sessions in a role chain. For more information, see Chaining Roles with Session
- // Tags (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining)
- // in the IAM User Guide.
- //
- // This parameter is optional. When you set session tags as transitive, the
- // session policy and session tags packed binary limit is not affected.
- //
- // If you choose not to specify a transitive tag key, then no tags are passed
- // from this session to any subsequent sessions.
- TransitiveTagKeys []*string `type:"list"`
-}
-
-// String returns the string representation
-func (s AssumeRoleInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s AssumeRoleInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *AssumeRoleInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "AssumeRoleInput"}
- if s.DurationSeconds != nil && *s.DurationSeconds < 900 {
- invalidParams.Add(request.NewErrParamMinValue("DurationSeconds", 900))
- }
- if s.ExternalId != nil && len(*s.ExternalId) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("ExternalId", 2))
- }
- if s.Policy != nil && len(*s.Policy) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("Policy", 1))
- }
- if s.RoleArn == nil {
- invalidParams.Add(request.NewErrParamRequired("RoleArn"))
- }
- if s.RoleArn != nil && len(*s.RoleArn) < 20 {
- invalidParams.Add(request.NewErrParamMinLen("RoleArn", 20))
- }
- if s.RoleSessionName == nil {
- invalidParams.Add(request.NewErrParamRequired("RoleSessionName"))
- }
- if s.RoleSessionName != nil && len(*s.RoleSessionName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RoleSessionName", 2))
- }
- if s.SerialNumber != nil && len(*s.SerialNumber) < 9 {
- invalidParams.Add(request.NewErrParamMinLen("SerialNumber", 9))
- }
- if s.TokenCode != nil && len(*s.TokenCode) < 6 {
- invalidParams.Add(request.NewErrParamMinLen("TokenCode", 6))
- }
- if s.PolicyArns != nil {
- for i, v := range s.PolicyArns {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PolicyArns", i), err.(request.ErrInvalidParams))
- }
- }
- }
- if s.Tags != nil {
- for i, v := range s.Tags {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams))
- }
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetDurationSeconds sets the DurationSeconds field's value.
-func (s *AssumeRoleInput) SetDurationSeconds(v int64) *AssumeRoleInput {
- s.DurationSeconds = &v
- return s
-}
-
-// SetExternalId sets the ExternalId field's value.
-func (s *AssumeRoleInput) SetExternalId(v string) *AssumeRoleInput {
- s.ExternalId = &v
- return s
-}
-
-// SetPolicy sets the Policy field's value.
-func (s *AssumeRoleInput) SetPolicy(v string) *AssumeRoleInput {
- s.Policy = &v
- return s
-}
-
-// SetPolicyArns sets the PolicyArns field's value.
-func (s *AssumeRoleInput) SetPolicyArns(v []*PolicyDescriptorType) *AssumeRoleInput {
- s.PolicyArns = v
- return s
-}
-
-// SetRoleArn sets the RoleArn field's value.
-func (s *AssumeRoleInput) SetRoleArn(v string) *AssumeRoleInput {
- s.RoleArn = &v
- return s
-}
-
-// SetRoleSessionName sets the RoleSessionName field's value.
-func (s *AssumeRoleInput) SetRoleSessionName(v string) *AssumeRoleInput {
- s.RoleSessionName = &v
- return s
-}
-
-// SetSerialNumber sets the SerialNumber field's value.
-func (s *AssumeRoleInput) SetSerialNumber(v string) *AssumeRoleInput {
- s.SerialNumber = &v
- return s
-}
-
-// SetTags sets the Tags field's value.
-func (s *AssumeRoleInput) SetTags(v []*Tag) *AssumeRoleInput {
- s.Tags = v
- return s
-}
-
-// SetTokenCode sets the TokenCode field's value.
-func (s *AssumeRoleInput) SetTokenCode(v string) *AssumeRoleInput {
- s.TokenCode = &v
- return s
-}
-
-// SetTransitiveTagKeys sets the TransitiveTagKeys field's value.
-func (s *AssumeRoleInput) SetTransitiveTagKeys(v []*string) *AssumeRoleInput {
- s.TransitiveTagKeys = v
- return s
-}
-
-// Contains the response to a successful AssumeRole request, including temporary
-// AWS credentials that can be used to make AWS requests.
-type AssumeRoleOutput struct {
- _ struct{} `type:"structure"`
-
- // The Amazon Resource Name (ARN) and the assumed role ID, which are identifiers
- // that you can use to refer to the resulting temporary security credentials.
- // For example, you can reference these credentials as a principal in a resource-based
- // policy by using the ARN or assumed role ID. The ARN and ID include the RoleSessionName
- // that you specified when you called AssumeRole.
- AssumedRoleUser *AssumedRoleUser `type:"structure"`
-
- // The temporary security credentials, which include an access key ID, a secret
- // access key, and a security (or session) token.
- //
- // The size of the security token that STS API operations return is not fixed.
- // We strongly recommend that you make no assumptions about the maximum size.
- Credentials *Credentials `type:"structure"`
-
- // A percentage value that indicates the packed size of the session policies
- // and session tags combined passed in the request. The request fails if the
- // packed size is greater than 100 percent, which means the policies and tags
- // exceeded the allowed space.
- PackedPolicySize *int64 `type:"integer"`
-}
-
-// String returns the string representation
-func (s AssumeRoleOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s AssumeRoleOutput) GoString() string {
- return s.String()
-}
-
-// SetAssumedRoleUser sets the AssumedRoleUser field's value.
-func (s *AssumeRoleOutput) SetAssumedRoleUser(v *AssumedRoleUser) *AssumeRoleOutput {
- s.AssumedRoleUser = v
- return s
-}
-
-// SetCredentials sets the Credentials field's value.
-func (s *AssumeRoleOutput) SetCredentials(v *Credentials) *AssumeRoleOutput {
- s.Credentials = v
- return s
-}
-
-// SetPackedPolicySize sets the PackedPolicySize field's value.
-func (s *AssumeRoleOutput) SetPackedPolicySize(v int64) *AssumeRoleOutput {
- s.PackedPolicySize = &v
- return s
-}
-
-type AssumeRoleWithSAMLInput struct {
- _ struct{} `type:"structure"`
-
- // The duration, in seconds, of the role session. Your role session lasts for
- // the duration that you specify for the DurationSeconds parameter, or until
- // the time specified in the SAML authentication response's SessionNotOnOrAfter
- // value, whichever is shorter. You can provide a DurationSeconds value from
- // 900 seconds (15 minutes) up to the maximum session duration setting for the
- // role. This setting can have a value from 1 hour to 12 hours. If you specify
- // a value higher than this setting, the operation fails. For example, if you
- // specify a session duration of 12 hours, but your administrator set the maximum
- // session duration to 6 hours, your operation fails. To learn how to view the
- // maximum value for your role, see View the Maximum Session Duration Setting
- // for a Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
- // in the IAM User Guide.
- //
- // By default, the value is set to 3600 seconds.
- //
- // The DurationSeconds parameter is separate from the duration of a console
- // session that you might request using the returned credentials. The request
- // to the federation endpoint for a console sign-in token takes a SessionDuration
- // parameter that specifies the maximum length of the console session. For more
- // information, see Creating a URL that Enables Federated Users to Access the
- // AWS Management Console (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html)
- // in the IAM User Guide.
- DurationSeconds *int64 `min:"900" type:"integer"`
-
- // An IAM policy in JSON format that you want to use as an inline session policy.
- //
- // This parameter is optional. Passing policies to this operation returns new
- // temporary credentials. The resulting session's permissions are the intersection
- // of the role's identity-based policy and the session policies. You can use
- // the role's temporary credentials in subsequent AWS API calls to access resources
- // in the account that owns the role. You cannot use session policies to grant
- // more permissions than those allowed by the identity-based policy of the role
- // that is being assumed. For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- //
- // The plain text that you use for both inline and managed session policies
- // can't exceed 2,048 characters. The JSON policy characters can be any ASCII
- // character from the space character to the end of the valid character list
- // (\u0020 through \u00FF). It can also include the tab (\u0009), linefeed (\u000A),
- // and carriage return (\u000D) characters.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- Policy *string `min:"1" type:"string"`
-
- // The Amazon Resource Names (ARNs) of the IAM managed policies that you want
- // to use as managed session policies. The policies must exist in the same account
- // as the role.
- //
- // This parameter is optional. You can provide up to 10 managed policy ARNs.
- // However, the plain text that you use for both inline and managed session
- // policies can't exceed 2,048 characters. For more information about ARNs,
- // see Amazon Resource Names (ARNs) and AWS Service Namespaces (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
- // in the AWS General Reference.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- //
- // Passing policies to this operation returns new temporary credentials. The
- // resulting session's permissions are the intersection of the role's identity-based
- // policy and the session policies. You can use the role's temporary credentials
- // in subsequent AWS API calls to access resources in the account that owns
- // the role. You cannot use session policies to grant more permissions than
- // those allowed by the identity-based policy of the role that is being assumed.
- // For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- PolicyArns []*PolicyDescriptorType `type:"list"`
-
- // The Amazon Resource Name (ARN) of the SAML provider in IAM that describes
- // the IdP.
- //
- // PrincipalArn is a required field
- PrincipalArn *string `min:"20" type:"string" required:"true"`
-
- // The Amazon Resource Name (ARN) of the role that the caller is assuming.
- //
- // RoleArn is a required field
- RoleArn *string `min:"20" type:"string" required:"true"`
-
- // The base-64 encoded SAML authentication response provided by the IdP.
- //
- // For more information, see Configuring a Relying Party and Adding Claims (https://docs.aws.amazon.com/IAM/latest/UserGuide/create-role-saml-IdP-tasks.html)
- // in the IAM User Guide.
- //
- // SAMLAssertion is a required field
- SAMLAssertion *string `min:"4" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s AssumeRoleWithSAMLInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s AssumeRoleWithSAMLInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *AssumeRoleWithSAMLInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "AssumeRoleWithSAMLInput"}
- if s.DurationSeconds != nil && *s.DurationSeconds < 900 {
- invalidParams.Add(request.NewErrParamMinValue("DurationSeconds", 900))
- }
- if s.Policy != nil && len(*s.Policy) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("Policy", 1))
- }
- if s.PrincipalArn == nil {
- invalidParams.Add(request.NewErrParamRequired("PrincipalArn"))
- }
- if s.PrincipalArn != nil && len(*s.PrincipalArn) < 20 {
- invalidParams.Add(request.NewErrParamMinLen("PrincipalArn", 20))
- }
- if s.RoleArn == nil {
- invalidParams.Add(request.NewErrParamRequired("RoleArn"))
- }
- if s.RoleArn != nil && len(*s.RoleArn) < 20 {
- invalidParams.Add(request.NewErrParamMinLen("RoleArn", 20))
- }
- if s.SAMLAssertion == nil {
- invalidParams.Add(request.NewErrParamRequired("SAMLAssertion"))
- }
- if s.SAMLAssertion != nil && len(*s.SAMLAssertion) < 4 {
- invalidParams.Add(request.NewErrParamMinLen("SAMLAssertion", 4))
- }
- if s.PolicyArns != nil {
- for i, v := range s.PolicyArns {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PolicyArns", i), err.(request.ErrInvalidParams))
- }
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetDurationSeconds sets the DurationSeconds field's value.
-func (s *AssumeRoleWithSAMLInput) SetDurationSeconds(v int64) *AssumeRoleWithSAMLInput {
- s.DurationSeconds = &v
- return s
-}
-
-// SetPolicy sets the Policy field's value.
-func (s *AssumeRoleWithSAMLInput) SetPolicy(v string) *AssumeRoleWithSAMLInput {
- s.Policy = &v
- return s
-}
-
-// SetPolicyArns sets the PolicyArns field's value.
-func (s *AssumeRoleWithSAMLInput) SetPolicyArns(v []*PolicyDescriptorType) *AssumeRoleWithSAMLInput {
- s.PolicyArns = v
- return s
-}
-
-// SetPrincipalArn sets the PrincipalArn field's value.
-func (s *AssumeRoleWithSAMLInput) SetPrincipalArn(v string) *AssumeRoleWithSAMLInput {
- s.PrincipalArn = &v
- return s
-}
-
-// SetRoleArn sets the RoleArn field's value.
-func (s *AssumeRoleWithSAMLInput) SetRoleArn(v string) *AssumeRoleWithSAMLInput {
- s.RoleArn = &v
- return s
-}
-
-// SetSAMLAssertion sets the SAMLAssertion field's value.
-func (s *AssumeRoleWithSAMLInput) SetSAMLAssertion(v string) *AssumeRoleWithSAMLInput {
- s.SAMLAssertion = &v
- return s
-}
-
-// Contains the response to a successful AssumeRoleWithSAML request, including
-// temporary AWS credentials that can be used to make AWS requests.
-type AssumeRoleWithSAMLOutput struct {
- _ struct{} `type:"structure"`
-
- // The identifiers for the temporary security credentials that the operation
- // returns.
- AssumedRoleUser *AssumedRoleUser `type:"structure"`
-
- // The value of the Recipient attribute of the SubjectConfirmationData element
- // of the SAML assertion.
- Audience *string `type:"string"`
-
- // The temporary security credentials, which include an access key ID, a secret
- // access key, and a security (or session) token.
- //
- // The size of the security token that STS API operations return is not fixed.
- // We strongly recommend that you make no assumptions about the maximum size.
- Credentials *Credentials `type:"structure"`
-
- // The value of the Issuer element of the SAML assertion.
- Issuer *string `type:"string"`
-
- // A hash value based on the concatenation of the Issuer response value, the
- // AWS account ID, and the friendly name (the last part of the ARN) of the SAML
- // provider in IAM. The combination of NameQualifier and Subject can be used
- // to uniquely identify a federated user.
- //
- // The following pseudocode shows how the hash value is calculated:
- //
- // BASE64 ( SHA1 ( "https://example.com/saml" + "123456789012" + "/MySAMLIdP"
- // ) )
- NameQualifier *string `type:"string"`
-
- // A percentage value that indicates the packed size of the session policies
- // and session tags combined passed in the request. The request fails if the
- // packed size is greater than 100 percent, which means the policies and tags
- // exceeded the allowed space.
- PackedPolicySize *int64 `type:"integer"`
-
- // The value of the NameID element in the Subject element of the SAML assertion.
- Subject *string `type:"string"`
-
- // The format of the name ID, as defined by the Format attribute in the NameID
- // element of the SAML assertion. Typical examples of the format are transient
- // or persistent.
- //
- // If the format includes the prefix urn:oasis:names:tc:SAML:2.0:nameid-format,
- // that prefix is removed. For example, urn:oasis:names:tc:SAML:2.0:nameid-format:transient
- // is returned as transient. If the format includes any other prefix, the format
- // is returned with no modifications.
- SubjectType *string `type:"string"`
-}
-
-// String returns the string representation
-func (s AssumeRoleWithSAMLOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s AssumeRoleWithSAMLOutput) GoString() string {
- return s.String()
-}
-
-// SetAssumedRoleUser sets the AssumedRoleUser field's value.
-func (s *AssumeRoleWithSAMLOutput) SetAssumedRoleUser(v *AssumedRoleUser) *AssumeRoleWithSAMLOutput {
- s.AssumedRoleUser = v
- return s
-}
-
-// SetAudience sets the Audience field's value.
-func (s *AssumeRoleWithSAMLOutput) SetAudience(v string) *AssumeRoleWithSAMLOutput {
- s.Audience = &v
- return s
-}
-
-// SetCredentials sets the Credentials field's value.
-func (s *AssumeRoleWithSAMLOutput) SetCredentials(v *Credentials) *AssumeRoleWithSAMLOutput {
- s.Credentials = v
- return s
-}
-
-// SetIssuer sets the Issuer field's value.
-func (s *AssumeRoleWithSAMLOutput) SetIssuer(v string) *AssumeRoleWithSAMLOutput {
- s.Issuer = &v
- return s
-}
-
-// SetNameQualifier sets the NameQualifier field's value.
-func (s *AssumeRoleWithSAMLOutput) SetNameQualifier(v string) *AssumeRoleWithSAMLOutput {
- s.NameQualifier = &v
- return s
-}
-
-// SetPackedPolicySize sets the PackedPolicySize field's value.
-func (s *AssumeRoleWithSAMLOutput) SetPackedPolicySize(v int64) *AssumeRoleWithSAMLOutput {
- s.PackedPolicySize = &v
- return s
-}
-
-// SetSubject sets the Subject field's value.
-func (s *AssumeRoleWithSAMLOutput) SetSubject(v string) *AssumeRoleWithSAMLOutput {
- s.Subject = &v
- return s
-}
-
-// SetSubjectType sets the SubjectType field's value.
-func (s *AssumeRoleWithSAMLOutput) SetSubjectType(v string) *AssumeRoleWithSAMLOutput {
- s.SubjectType = &v
- return s
-}
-
-type AssumeRoleWithWebIdentityInput struct {
- _ struct{} `type:"structure"`
-
- // The duration, in seconds, of the role session. The value can range from 900
- // seconds (15 minutes) up to the maximum session duration setting for the role.
- // This setting can have a value from 1 hour to 12 hours. If you specify a value
- // higher than this setting, the operation fails. For example, if you specify
- // a session duration of 12 hours, but your administrator set the maximum session
- // duration to 6 hours, your operation fails. To learn how to view the maximum
- // value for your role, see View the Maximum Session Duration Setting for a
- // Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session)
- // in the IAM User Guide.
- //
- // By default, the value is set to 3600 seconds.
- //
- // The DurationSeconds parameter is separate from the duration of a console
- // session that you might request using the returned credentials. The request
- // to the federation endpoint for a console sign-in token takes a SessionDuration
- // parameter that specifies the maximum length of the console session. For more
- // information, see Creating a URL that Enables Federated Users to Access the
- // AWS Management Console (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html)
- // in the IAM User Guide.
- DurationSeconds *int64 `min:"900" type:"integer"`
-
- // An IAM policy in JSON format that you want to use as an inline session policy.
- //
- // This parameter is optional. Passing policies to this operation returns new
- // temporary credentials. The resulting session's permissions are the intersection
- // of the role's identity-based policy and the session policies. You can use
- // the role's temporary credentials in subsequent AWS API calls to access resources
- // in the account that owns the role. You cannot use session policies to grant
- // more permissions than those allowed by the identity-based policy of the role
- // that is being assumed. For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- //
- // The plain text that you use for both inline and managed session policies
- // can't exceed 2,048 characters. The JSON policy characters can be any ASCII
- // character from the space character to the end of the valid character list
- // (\u0020 through \u00FF). It can also include the tab (\u0009), linefeed (\u000A),
- // and carriage return (\u000D) characters.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- Policy *string `min:"1" type:"string"`
-
- // The Amazon Resource Names (ARNs) of the IAM managed policies that you want
- // to use as managed session policies. The policies must exist in the same account
- // as the role.
- //
- // This parameter is optional. You can provide up to 10 managed policy ARNs.
- // However, the plain text that you use for both inline and managed session
- // policies can't exceed 2,048 characters. For more information about ARNs,
- // see Amazon Resource Names (ARNs) and AWS Service Namespaces (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
- // in the AWS General Reference.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- //
- // Passing policies to this operation returns new temporary credentials. The
- // resulting session's permissions are the intersection of the role's identity-based
- // policy and the session policies. You can use the role's temporary credentials
- // in subsequent AWS API calls to access resources in the account that owns
- // the role. You cannot use session policies to grant more permissions than
- // those allowed by the identity-based policy of the role that is being assumed.
- // For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- PolicyArns []*PolicyDescriptorType `type:"list"`
-
- // The fully qualified host component of the domain name of the identity provider.
- //
- // Specify this value only for OAuth 2.0 access tokens. Currently www.amazon.com
- // and graph.facebook.com are the only supported identity providers for OAuth
- // 2.0 access tokens. Do not include URL schemes and port numbers.
- //
- // Do not specify this value for OpenID Connect ID tokens.
- ProviderId *string `min:"4" type:"string"`
-
- // The Amazon Resource Name (ARN) of the role that the caller is assuming.
- //
- // RoleArn is a required field
- RoleArn *string `min:"20" type:"string" required:"true"`
-
- // An identifier for the assumed role session. Typically, you pass the name
- // or identifier that is associated with the user who is using your application.
- // That way, the temporary security credentials that your application will use
- // are associated with that user. This session name is included as part of the
- // ARN and assumed role ID in the AssumedRoleUser response element.
- //
- // The regex used to validate this parameter is a string of characters consisting
- // of upper- and lower-case alphanumeric characters with no spaces. You can
- // also include underscores or any of the following characters: =,.@-
- //
- // RoleSessionName is a required field
- RoleSessionName *string `min:"2" type:"string" required:"true"`
-
- // The OAuth 2.0 access token or OpenID Connect ID token that is provided by
- // the identity provider. Your application must get this token by authenticating
- // the user who is using your application with a web identity provider before
- // the application makes an AssumeRoleWithWebIdentity call.
- //
- // WebIdentityToken is a required field
- WebIdentityToken *string `min:"4" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s AssumeRoleWithWebIdentityInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s AssumeRoleWithWebIdentityInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *AssumeRoleWithWebIdentityInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "AssumeRoleWithWebIdentityInput"}
- if s.DurationSeconds != nil && *s.DurationSeconds < 900 {
- invalidParams.Add(request.NewErrParamMinValue("DurationSeconds", 900))
- }
- if s.Policy != nil && len(*s.Policy) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("Policy", 1))
- }
- if s.ProviderId != nil && len(*s.ProviderId) < 4 {
- invalidParams.Add(request.NewErrParamMinLen("ProviderId", 4))
- }
- if s.RoleArn == nil {
- invalidParams.Add(request.NewErrParamRequired("RoleArn"))
- }
- if s.RoleArn != nil && len(*s.RoleArn) < 20 {
- invalidParams.Add(request.NewErrParamMinLen("RoleArn", 20))
- }
- if s.RoleSessionName == nil {
- invalidParams.Add(request.NewErrParamRequired("RoleSessionName"))
- }
- if s.RoleSessionName != nil && len(*s.RoleSessionName) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("RoleSessionName", 2))
- }
- if s.WebIdentityToken == nil {
- invalidParams.Add(request.NewErrParamRequired("WebIdentityToken"))
- }
- if s.WebIdentityToken != nil && len(*s.WebIdentityToken) < 4 {
- invalidParams.Add(request.NewErrParamMinLen("WebIdentityToken", 4))
- }
- if s.PolicyArns != nil {
- for i, v := range s.PolicyArns {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PolicyArns", i), err.(request.ErrInvalidParams))
- }
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetDurationSeconds sets the DurationSeconds field's value.
-func (s *AssumeRoleWithWebIdentityInput) SetDurationSeconds(v int64) *AssumeRoleWithWebIdentityInput {
- s.DurationSeconds = &v
- return s
-}
-
-// SetPolicy sets the Policy field's value.
-func (s *AssumeRoleWithWebIdentityInput) SetPolicy(v string) *AssumeRoleWithWebIdentityInput {
- s.Policy = &v
- return s
-}
-
-// SetPolicyArns sets the PolicyArns field's value.
-func (s *AssumeRoleWithWebIdentityInput) SetPolicyArns(v []*PolicyDescriptorType) *AssumeRoleWithWebIdentityInput {
- s.PolicyArns = v
- return s
-}
-
-// SetProviderId sets the ProviderId field's value.
-func (s *AssumeRoleWithWebIdentityInput) SetProviderId(v string) *AssumeRoleWithWebIdentityInput {
- s.ProviderId = &v
- return s
-}
-
-// SetRoleArn sets the RoleArn field's value.
-func (s *AssumeRoleWithWebIdentityInput) SetRoleArn(v string) *AssumeRoleWithWebIdentityInput {
- s.RoleArn = &v
- return s
-}
-
-// SetRoleSessionName sets the RoleSessionName field's value.
-func (s *AssumeRoleWithWebIdentityInput) SetRoleSessionName(v string) *AssumeRoleWithWebIdentityInput {
- s.RoleSessionName = &v
- return s
-}
-
-// SetWebIdentityToken sets the WebIdentityToken field's value.
-func (s *AssumeRoleWithWebIdentityInput) SetWebIdentityToken(v string) *AssumeRoleWithWebIdentityInput {
- s.WebIdentityToken = &v
- return s
-}
-
-// Contains the response to a successful AssumeRoleWithWebIdentity request,
-// including temporary AWS credentials that can be used to make AWS requests.
-type AssumeRoleWithWebIdentityOutput struct {
- _ struct{} `type:"structure"`
-
- // The Amazon Resource Name (ARN) and the assumed role ID, which are identifiers
- // that you can use to refer to the resulting temporary security credentials.
- // For example, you can reference these credentials as a principal in a resource-based
- // policy by using the ARN or assumed role ID. The ARN and ID include the RoleSessionName
- // that you specified when you called AssumeRole.
- AssumedRoleUser *AssumedRoleUser `type:"structure"`
-
- // The intended audience (also known as client ID) of the web identity token.
- // This is traditionally the client identifier issued to the application that
- // requested the web identity token.
- Audience *string `type:"string"`
-
- // The temporary security credentials, which include an access key ID, a secret
- // access key, and a security token.
- //
- // The size of the security token that STS API operations return is not fixed.
- // We strongly recommend that you make no assumptions about the maximum size.
- Credentials *Credentials `type:"structure"`
-
- // A percentage value that indicates the packed size of the session policies
- // and session tags combined passed in the request. The request fails if the
- // packed size is greater than 100 percent, which means the policies and tags
- // exceeded the allowed space.
- PackedPolicySize *int64 `type:"integer"`
-
- // The issuing authority of the web identity token presented. For OpenID Connect
- // ID tokens, this contains the value of the iss field. For OAuth 2.0 access
- // tokens, this contains the value of the ProviderId parameter that was passed
- // in the AssumeRoleWithWebIdentity request.
- Provider *string `type:"string"`
-
- // The unique user identifier that is returned by the identity provider. This
- // identifier is associated with the WebIdentityToken that was submitted with
- // the AssumeRoleWithWebIdentity call. The identifier is typically unique to
- // the user and the application that acquired the WebIdentityToken (pairwise
- // identifier). For OpenID Connect ID tokens, this field contains the value
- // returned by the identity provider as the token's sub (Subject) claim.
- SubjectFromWebIdentityToken *string `min:"6" type:"string"`
-}
-
-// String returns the string representation
-func (s AssumeRoleWithWebIdentityOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s AssumeRoleWithWebIdentityOutput) GoString() string {
- return s.String()
-}
-
-// SetAssumedRoleUser sets the AssumedRoleUser field's value.
-func (s *AssumeRoleWithWebIdentityOutput) SetAssumedRoleUser(v *AssumedRoleUser) *AssumeRoleWithWebIdentityOutput {
- s.AssumedRoleUser = v
- return s
-}
-
-// SetAudience sets the Audience field's value.
-func (s *AssumeRoleWithWebIdentityOutput) SetAudience(v string) *AssumeRoleWithWebIdentityOutput {
- s.Audience = &v
- return s
-}
-
-// SetCredentials sets the Credentials field's value.
-func (s *AssumeRoleWithWebIdentityOutput) SetCredentials(v *Credentials) *AssumeRoleWithWebIdentityOutput {
- s.Credentials = v
- return s
-}
-
-// SetPackedPolicySize sets the PackedPolicySize field's value.
-func (s *AssumeRoleWithWebIdentityOutput) SetPackedPolicySize(v int64) *AssumeRoleWithWebIdentityOutput {
- s.PackedPolicySize = &v
- return s
-}
-
-// SetProvider sets the Provider field's value.
-func (s *AssumeRoleWithWebIdentityOutput) SetProvider(v string) *AssumeRoleWithWebIdentityOutput {
- s.Provider = &v
- return s
-}
-
-// SetSubjectFromWebIdentityToken sets the SubjectFromWebIdentityToken field's value.
-func (s *AssumeRoleWithWebIdentityOutput) SetSubjectFromWebIdentityToken(v string) *AssumeRoleWithWebIdentityOutput {
- s.SubjectFromWebIdentityToken = &v
- return s
-}
-
-// The identifiers for the temporary security credentials that the operation
-// returns.
-type AssumedRoleUser struct {
- _ struct{} `type:"structure"`
-
- // The ARN of the temporary security credentials that are returned from the
- // AssumeRole action. For more information about ARNs and how to use them in
- // policies, see IAM Identifiers (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html)
- // in the IAM User Guide.
- //
- // Arn is a required field
- Arn *string `min:"20" type:"string" required:"true"`
-
- // A unique identifier that contains the role ID and the role session name of
- // the role that is being assumed. The role ID is generated by AWS when the
- // role is created.
- //
- // AssumedRoleId is a required field
- AssumedRoleId *string `min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s AssumedRoleUser) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s AssumedRoleUser) GoString() string {
- return s.String()
-}
-
-// SetArn sets the Arn field's value.
-func (s *AssumedRoleUser) SetArn(v string) *AssumedRoleUser {
- s.Arn = &v
- return s
-}
-
-// SetAssumedRoleId sets the AssumedRoleId field's value.
-func (s *AssumedRoleUser) SetAssumedRoleId(v string) *AssumedRoleUser {
- s.AssumedRoleId = &v
- return s
-}
-
-// AWS credentials for API authentication.
-type Credentials struct {
- _ struct{} `type:"structure"`
-
- // The access key ID that identifies the temporary security credentials.
- //
- // AccessKeyId is a required field
- AccessKeyId *string `min:"16" type:"string" required:"true"`
-
- // The date on which the current credentials expire.
- //
- // Expiration is a required field
- Expiration *time.Time `type:"timestamp" required:"true"`
-
- // The secret access key that can be used to sign requests.
- //
- // SecretAccessKey is a required field
- SecretAccessKey *string `type:"string" required:"true"`
-
- // The token that users must pass to the service API to use the temporary credentials.
- //
- // SessionToken is a required field
- SessionToken *string `type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s Credentials) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s Credentials) GoString() string {
- return s.String()
-}
-
-// SetAccessKeyId sets the AccessKeyId field's value.
-func (s *Credentials) SetAccessKeyId(v string) *Credentials {
- s.AccessKeyId = &v
- return s
-}
-
-// SetExpiration sets the Expiration field's value.
-func (s *Credentials) SetExpiration(v time.Time) *Credentials {
- s.Expiration = &v
- return s
-}
-
-// SetSecretAccessKey sets the SecretAccessKey field's value.
-func (s *Credentials) SetSecretAccessKey(v string) *Credentials {
- s.SecretAccessKey = &v
- return s
-}
-
-// SetSessionToken sets the SessionToken field's value.
-func (s *Credentials) SetSessionToken(v string) *Credentials {
- s.SessionToken = &v
- return s
-}
-
-type DecodeAuthorizationMessageInput struct {
- _ struct{} `type:"structure"`
-
- // The encoded message that was returned with the response.
- //
- // EncodedMessage is a required field
- EncodedMessage *string `min:"1" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s DecodeAuthorizationMessageInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DecodeAuthorizationMessageInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *DecodeAuthorizationMessageInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "DecodeAuthorizationMessageInput"}
- if s.EncodedMessage == nil {
- invalidParams.Add(request.NewErrParamRequired("EncodedMessage"))
- }
- if s.EncodedMessage != nil && len(*s.EncodedMessage) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("EncodedMessage", 1))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetEncodedMessage sets the EncodedMessage field's value.
-func (s *DecodeAuthorizationMessageInput) SetEncodedMessage(v string) *DecodeAuthorizationMessageInput {
- s.EncodedMessage = &v
- return s
-}
-
-// A document that contains additional information about the authorization status
-// of a request from an encoded message that is returned in response to an AWS
-// request.
-type DecodeAuthorizationMessageOutput struct {
- _ struct{} `type:"structure"`
-
- // An XML document that contains the decoded message.
- DecodedMessage *string `type:"string"`
-}
-
-// String returns the string representation
-func (s DecodeAuthorizationMessageOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s DecodeAuthorizationMessageOutput) GoString() string {
- return s.String()
-}
-
-// SetDecodedMessage sets the DecodedMessage field's value.
-func (s *DecodeAuthorizationMessageOutput) SetDecodedMessage(v string) *DecodeAuthorizationMessageOutput {
- s.DecodedMessage = &v
- return s
-}
-
-// Identifiers for the federated user that is associated with the credentials.
-type FederatedUser struct {
- _ struct{} `type:"structure"`
-
- // The ARN that specifies the federated user that is associated with the credentials.
- // For more information about ARNs and how to use them in policies, see IAM
- // Identifiers (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html)
- // in the IAM User Guide.
- //
- // Arn is a required field
- Arn *string `min:"20" type:"string" required:"true"`
-
- // The string that identifies the federated user associated with the credentials,
- // similar to the unique ID of an IAM user.
- //
- // FederatedUserId is a required field
- FederatedUserId *string `min:"2" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s FederatedUser) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s FederatedUser) GoString() string {
- return s.String()
-}
-
-// SetArn sets the Arn field's value.
-func (s *FederatedUser) SetArn(v string) *FederatedUser {
- s.Arn = &v
- return s
-}
-
-// SetFederatedUserId sets the FederatedUserId field's value.
-func (s *FederatedUser) SetFederatedUserId(v string) *FederatedUser {
- s.FederatedUserId = &v
- return s
-}
-
-type GetAccessKeyInfoInput struct {
- _ struct{} `type:"structure"`
-
- // The identifier of an access key.
- //
- // This parameter allows (through its regex pattern) a string of characters
- // that can consist of any upper- or lowercase letter or digit.
- //
- // AccessKeyId is a required field
- AccessKeyId *string `min:"16" type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s GetAccessKeyInfoInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetAccessKeyInfoInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *GetAccessKeyInfoInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "GetAccessKeyInfoInput"}
- if s.AccessKeyId == nil {
- invalidParams.Add(request.NewErrParamRequired("AccessKeyId"))
- }
- if s.AccessKeyId != nil && len(*s.AccessKeyId) < 16 {
- invalidParams.Add(request.NewErrParamMinLen("AccessKeyId", 16))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetAccessKeyId sets the AccessKeyId field's value.
-func (s *GetAccessKeyInfoInput) SetAccessKeyId(v string) *GetAccessKeyInfoInput {
- s.AccessKeyId = &v
- return s
-}
-
-type GetAccessKeyInfoOutput struct {
- _ struct{} `type:"structure"`
-
- // The number used to identify the AWS account.
- Account *string `type:"string"`
-}
-
-// String returns the string representation
-func (s GetAccessKeyInfoOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetAccessKeyInfoOutput) GoString() string {
- return s.String()
-}
-
-// SetAccount sets the Account field's value.
-func (s *GetAccessKeyInfoOutput) SetAccount(v string) *GetAccessKeyInfoOutput {
- s.Account = &v
- return s
-}
-
-type GetCallerIdentityInput struct {
- _ struct{} `type:"structure"`
-}
-
-// String returns the string representation
-func (s GetCallerIdentityInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetCallerIdentityInput) GoString() string {
- return s.String()
-}
-
-// Contains the response to a successful GetCallerIdentity request, including
-// information about the entity making the request.
-type GetCallerIdentityOutput struct {
- _ struct{} `type:"structure"`
-
- // The AWS account ID number of the account that owns or contains the calling
- // entity.
- Account *string `type:"string"`
-
- // The AWS ARN associated with the calling entity.
- Arn *string `min:"20" type:"string"`
-
- // The unique identifier of the calling entity. The exact value depends on the
- // type of entity that is making the call. The values returned are those listed
- // in the aws:userid column in the Principal table (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_variables.html#principaltable)
- // found on the Policy Variables reference page in the IAM User Guide.
- UserId *string `type:"string"`
-}
-
-// String returns the string representation
-func (s GetCallerIdentityOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetCallerIdentityOutput) GoString() string {
- return s.String()
-}
-
-// SetAccount sets the Account field's value.
-func (s *GetCallerIdentityOutput) SetAccount(v string) *GetCallerIdentityOutput {
- s.Account = &v
- return s
-}
-
-// SetArn sets the Arn field's value.
-func (s *GetCallerIdentityOutput) SetArn(v string) *GetCallerIdentityOutput {
- s.Arn = &v
- return s
-}
-
-// SetUserId sets the UserId field's value.
-func (s *GetCallerIdentityOutput) SetUserId(v string) *GetCallerIdentityOutput {
- s.UserId = &v
- return s
-}
-
-type GetFederationTokenInput struct {
- _ struct{} `type:"structure"`
-
- // The duration, in seconds, that the session should last. Acceptable durations
- // for federation sessions range from 900 seconds (15 minutes) to 129,600 seconds
- // (36 hours), with 43,200 seconds (12 hours) as the default. Sessions obtained
- // using AWS account root user credentials are restricted to a maximum of 3,600
- // seconds (one hour). If the specified duration is longer than one hour, the
- // session obtained by using root user credentials defaults to one hour.
- DurationSeconds *int64 `min:"900" type:"integer"`
-
- // The name of the federated user. The name is used as an identifier for the
- // temporary security credentials (such as Bob). For example, you can reference
- // the federated user name in a resource-based policy, such as in an Amazon
- // S3 bucket policy.
- //
- // The regex used to validate this parameter is a string of characters consisting
- // of upper- and lower-case alphanumeric characters with no spaces. You can
- // also include underscores or any of the following characters: =,.@-
- //
- // Name is a required field
- Name *string `min:"2" type:"string" required:"true"`
-
- // An IAM policy in JSON format that you want to use as an inline session policy.
- //
- // You must pass an inline or managed session policy (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // to this operation. You can pass a single JSON policy document to use as an
- // inline session policy. You can also specify up to 10 managed policies to
- // use as managed session policies.
- //
- // This parameter is optional. However, if you do not pass any session policies,
- // then the resulting federated user session has no permissions.
- //
- // When you pass session policies, the session permissions are the intersection
- // of the IAM user policies and the session policies that you pass. This gives
- // you a way to further restrict the permissions for a federated user. You cannot
- // use session policies to grant more permissions than those that are defined
- // in the permissions policy of the IAM user. For more information, see Session
- // Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- //
- // The resulting credentials can be used to access a resource that has a resource-based
- // policy. If that policy specifically references the federated user session
- // in the Principal element of the policy, the session has the permissions allowed
- // by the policy. These permissions are granted in addition to the permissions
- // that are granted by the session policies.
- //
- // The plain text that you use for both inline and managed session policies
- // can't exceed 2,048 characters. The JSON policy characters can be any ASCII
- // character from the space character to the end of the valid character list
- // (\u0020 through \u00FF). It can also include the tab (\u0009), linefeed (\u000A),
- // and carriage return (\u000D) characters.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- Policy *string `min:"1" type:"string"`
-
- // The Amazon Resource Names (ARNs) of the IAM managed policies that you want
- // to use as a managed session policy. The policies must exist in the same account
- // as the IAM user that is requesting federated access.
- //
- // You must pass an inline or managed session policy (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // to this operation. You can pass a single JSON policy document to use as an
- // inline session policy. You can also specify up to 10 managed policies to
- // use as managed session policies. The plain text that you use for both inline
- // and managed session policies can't exceed 2,048 characters. You can provide
- // up to 10 managed policy ARNs. For more information about ARNs, see Amazon
- // Resource Names (ARNs) and AWS Service Namespaces (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
- // in the AWS General Reference.
- //
- // This parameter is optional. However, if you do not pass any session policies,
- // then the resulting federated user session has no permissions.
- //
- // When you pass session policies, the session permissions are the intersection
- // of the IAM user policies and the session policies that you pass. This gives
- // you a way to further restrict the permissions for a federated user. You cannot
- // use session policies to grant more permissions than those that are defined
- // in the permissions policy of the IAM user. For more information, see Session
- // Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
- // in the IAM User Guide.
- //
- // The resulting credentials can be used to access a resource that has a resource-based
- // policy. If that policy specifically references the federated user session
- // in the Principal element of the policy, the session has the permissions allowed
- // by the policy. These permissions are granted in addition to the permissions
- // that are granted by the session policies.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- PolicyArns []*PolicyDescriptorType `type:"list"`
-
- // A list of session tags. Each session tag consists of a key name and an associated
- // value. For more information about session tags, see Passing Session Tags
- // in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
- // in the IAM User Guide.
- //
- // This parameter is optional. You can pass up to 50 session tags. The plain
- // text session tag keys can’t exceed 128 characters and the values can’t
- // exceed 256 characters. For these and additional limits, see IAM and STS Character
- // Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
- // in the IAM User Guide.
- //
- // An AWS conversion compresses the passed session policies and session tags
- // into a packed binary format that has a separate limit. Your request can fail
- // for this limit even if your plain text meets the other requirements. The
- // PackedPolicySize response element indicates by percentage how close the policies
- // and tags for your request are to the upper size limit.
- //
- // You can pass a session tag with the same key as a tag that is already attached
- // to the user you are federating. When you do, session tags override a user
- // tag with the same key.
- //
- // Tag key–value pairs are not case sensitive, but case is preserved. This
- // means that you cannot have separate Department and department tag keys. Assume
- // that the role has the Department=Marketing tag and you pass the department=engineering
- // session tag. Department and department are not saved as separate tags, and
- // the session tag passed in the request takes precedence over the role tag.
- Tags []*Tag `type:"list"`
-}
-
-// String returns the string representation
-func (s GetFederationTokenInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetFederationTokenInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *GetFederationTokenInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "GetFederationTokenInput"}
- if s.DurationSeconds != nil && *s.DurationSeconds < 900 {
- invalidParams.Add(request.NewErrParamMinValue("DurationSeconds", 900))
- }
- if s.Name == nil {
- invalidParams.Add(request.NewErrParamRequired("Name"))
- }
- if s.Name != nil && len(*s.Name) < 2 {
- invalidParams.Add(request.NewErrParamMinLen("Name", 2))
- }
- if s.Policy != nil && len(*s.Policy) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("Policy", 1))
- }
- if s.PolicyArns != nil {
- for i, v := range s.PolicyArns {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PolicyArns", i), err.(request.ErrInvalidParams))
- }
- }
- }
- if s.Tags != nil {
- for i, v := range s.Tags {
- if v == nil {
- continue
- }
- if err := v.Validate(); err != nil {
- invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams))
- }
- }
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetDurationSeconds sets the DurationSeconds field's value.
-func (s *GetFederationTokenInput) SetDurationSeconds(v int64) *GetFederationTokenInput {
- s.DurationSeconds = &v
- return s
-}
-
-// SetName sets the Name field's value.
-func (s *GetFederationTokenInput) SetName(v string) *GetFederationTokenInput {
- s.Name = &v
- return s
-}
-
-// SetPolicy sets the Policy field's value.
-func (s *GetFederationTokenInput) SetPolicy(v string) *GetFederationTokenInput {
- s.Policy = &v
- return s
-}
-
-// SetPolicyArns sets the PolicyArns field's value.
-func (s *GetFederationTokenInput) SetPolicyArns(v []*PolicyDescriptorType) *GetFederationTokenInput {
- s.PolicyArns = v
- return s
-}
-
-// SetTags sets the Tags field's value.
-func (s *GetFederationTokenInput) SetTags(v []*Tag) *GetFederationTokenInput {
- s.Tags = v
- return s
-}
-
-// Contains the response to a successful GetFederationToken request, including
-// temporary AWS credentials that can be used to make AWS requests.
-type GetFederationTokenOutput struct {
- _ struct{} `type:"structure"`
-
- // The temporary security credentials, which include an access key ID, a secret
- // access key, and a security (or session) token.
- //
- // The size of the security token that STS API operations return is not fixed.
- // We strongly recommend that you make no assumptions about the maximum size.
- Credentials *Credentials `type:"structure"`
-
- // Identifiers for the federated user associated with the credentials (such
- // as arn:aws:sts::123456789012:federated-user/Bob or 123456789012:Bob). You
- // can use the federated user's ARN in your resource-based policies, such as
- // an Amazon S3 bucket policy.
- FederatedUser *FederatedUser `type:"structure"`
-
- // A percentage value that indicates the packed size of the session policies
- // and session tags combined passed in the request. The request fails if the
- // packed size is greater than 100 percent, which means the policies and tags
- // exceeded the allowed space.
- PackedPolicySize *int64 `type:"integer"`
-}
-
-// String returns the string representation
-func (s GetFederationTokenOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetFederationTokenOutput) GoString() string {
- return s.String()
-}
-
-// SetCredentials sets the Credentials field's value.
-func (s *GetFederationTokenOutput) SetCredentials(v *Credentials) *GetFederationTokenOutput {
- s.Credentials = v
- return s
-}
-
-// SetFederatedUser sets the FederatedUser field's value.
-func (s *GetFederationTokenOutput) SetFederatedUser(v *FederatedUser) *GetFederationTokenOutput {
- s.FederatedUser = v
- return s
-}
-
-// SetPackedPolicySize sets the PackedPolicySize field's value.
-func (s *GetFederationTokenOutput) SetPackedPolicySize(v int64) *GetFederationTokenOutput {
- s.PackedPolicySize = &v
- return s
-}
-
-type GetSessionTokenInput struct {
- _ struct{} `type:"structure"`
-
- // The duration, in seconds, that the credentials should remain valid. Acceptable
- // durations for IAM user sessions range from 900 seconds (15 minutes) to 129,600
- // seconds (36 hours), with 43,200 seconds (12 hours) as the default. Sessions
- // for AWS account owners are restricted to a maximum of 3,600 seconds (one
- // hour). If the duration is longer than one hour, the session for AWS account
- // owners defaults to one hour.
- DurationSeconds *int64 `min:"900" type:"integer"`
-
- // The identification number of the MFA device that is associated with the IAM
- // user who is making the GetSessionToken call. Specify this value if the IAM
- // user has a policy that requires MFA authentication. The value is either the
- // serial number for a hardware device (such as GAHT12345678) or an Amazon Resource
- // Name (ARN) for a virtual device (such as arn:aws:iam::123456789012:mfa/user).
- // You can find the device for an IAM user by going to the AWS Management Console
- // and viewing the user's security credentials.
- //
- // The regex used to validate this parameter is a string of characters consisting
- // of upper- and lower-case alphanumeric characters with no spaces. You can
- // also include underscores or any of the following characters: =,.@:/-
- SerialNumber *string `min:"9" type:"string"`
-
- // The value provided by the MFA device, if MFA is required. If any policy requires
- // the IAM user to submit an MFA code, specify this value. If MFA authentication
- // is required, the user must provide a code when requesting a set of temporary
- // security credentials. A user who fails to provide the code receives an "access
- // denied" response when requesting resources that require MFA authentication.
- //
- // The format for this parameter, as described by its regex pattern, is a sequence
- // of six numeric digits.
- TokenCode *string `min:"6" type:"string"`
-}
-
-// String returns the string representation
-func (s GetSessionTokenInput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetSessionTokenInput) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *GetSessionTokenInput) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "GetSessionTokenInput"}
- if s.DurationSeconds != nil && *s.DurationSeconds < 900 {
- invalidParams.Add(request.NewErrParamMinValue("DurationSeconds", 900))
- }
- if s.SerialNumber != nil && len(*s.SerialNumber) < 9 {
- invalidParams.Add(request.NewErrParamMinLen("SerialNumber", 9))
- }
- if s.TokenCode != nil && len(*s.TokenCode) < 6 {
- invalidParams.Add(request.NewErrParamMinLen("TokenCode", 6))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetDurationSeconds sets the DurationSeconds field's value.
-func (s *GetSessionTokenInput) SetDurationSeconds(v int64) *GetSessionTokenInput {
- s.DurationSeconds = &v
- return s
-}
-
-// SetSerialNumber sets the SerialNumber field's value.
-func (s *GetSessionTokenInput) SetSerialNumber(v string) *GetSessionTokenInput {
- s.SerialNumber = &v
- return s
-}
-
-// SetTokenCode sets the TokenCode field's value.
-func (s *GetSessionTokenInput) SetTokenCode(v string) *GetSessionTokenInput {
- s.TokenCode = &v
- return s
-}
-
-// Contains the response to a successful GetSessionToken request, including
-// temporary AWS credentials that can be used to make AWS requests.
-type GetSessionTokenOutput struct {
- _ struct{} `type:"structure"`
-
- // The temporary security credentials, which include an access key ID, a secret
- // access key, and a security (or session) token.
- //
- // The size of the security token that STS API operations return is not fixed.
- // We strongly recommend that you make no assumptions about the maximum size.
- Credentials *Credentials `type:"structure"`
-}
-
-// String returns the string representation
-func (s GetSessionTokenOutput) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s GetSessionTokenOutput) GoString() string {
- return s.String()
-}
-
-// SetCredentials sets the Credentials field's value.
-func (s *GetSessionTokenOutput) SetCredentials(v *Credentials) *GetSessionTokenOutput {
- s.Credentials = v
- return s
-}
-
-// A reference to the IAM managed policy that is passed as a session policy
-// for a role session or a federated user session.
-type PolicyDescriptorType struct {
- _ struct{} `type:"structure"`
-
- // The Amazon Resource Name (ARN) of the IAM managed policy to use as a session
- // policy for the role. For more information about ARNs, see Amazon Resource
- // Names (ARNs) and AWS Service Namespaces (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
- // in the AWS General Reference.
- Arn *string `locationName:"arn" min:"20" type:"string"`
-}
-
-// String returns the string representation
-func (s PolicyDescriptorType) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s PolicyDescriptorType) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *PolicyDescriptorType) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "PolicyDescriptorType"}
- if s.Arn != nil && len(*s.Arn) < 20 {
- invalidParams.Add(request.NewErrParamMinLen("Arn", 20))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetArn sets the Arn field's value.
-func (s *PolicyDescriptorType) SetArn(v string) *PolicyDescriptorType {
- s.Arn = &v
- return s
-}
-
-// You can pass custom key-value pair attributes when you assume a role or federate
-// a user. These are called session tags. You can then use the session tags
-// to control access to resources. For more information, see Tagging AWS STS
-// Sessions (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
-// in the IAM User Guide.
-type Tag struct {
- _ struct{} `type:"structure"`
-
- // The key for a session tag.
- //
- // You can pass up to 50 session tags. The plain text session tag keys can’t
- // exceed 128 characters. For these and additional limits, see IAM and STS Character
- // Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
- // in the IAM User Guide.
- //
- // Key is a required field
- Key *string `min:"1" type:"string" required:"true"`
-
- // The value for a session tag.
- //
- // You can pass up to 50 session tags. The plain text session tag values can’t
- // exceed 256 characters. For these and additional limits, see IAM and STS Character
- // Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length)
- // in the IAM User Guide.
- //
- // Value is a required field
- Value *string `type:"string" required:"true"`
-}
-
-// String returns the string representation
-func (s Tag) String() string {
- return awsutil.Prettify(s)
-}
-
-// GoString returns the string representation
-func (s Tag) GoString() string {
- return s.String()
-}
-
-// Validate inspects the fields of the type to determine if they are valid.
-func (s *Tag) Validate() error {
- invalidParams := request.ErrInvalidParams{Context: "Tag"}
- if s.Key == nil {
- invalidParams.Add(request.NewErrParamRequired("Key"))
- }
- if s.Key != nil && len(*s.Key) < 1 {
- invalidParams.Add(request.NewErrParamMinLen("Key", 1))
- }
- if s.Value == nil {
- invalidParams.Add(request.NewErrParamRequired("Value"))
- }
-
- if invalidParams.Len() > 0 {
- return invalidParams
- }
- return nil
-}
-
-// SetKey sets the Key field's value.
-func (s *Tag) SetKey(v string) *Tag {
- s.Key = &v
- return s
-}
-
-// SetValue sets the Value field's value.
-func (s *Tag) SetValue(v string) *Tag {
- s.Value = &v
- return s
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/customizations.go b/vendor/github.com/aws/aws-sdk-go/service/sts/customizations.go
deleted file mode 100644
index d5307fcaa0f3..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/sts/customizations.go
+++ /dev/null
@@ -1,11 +0,0 @@
-package sts
-
-import "github.com/aws/aws-sdk-go/aws/request"
-
-func init() {
- initRequest = customizeRequest
-}
-
-func customizeRequest(r *request.Request) {
- r.RetryErrorCodes = append(r.RetryErrorCodes, ErrCodeIDPCommunicationErrorException)
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go b/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go
deleted file mode 100644
index cb1debbaa45c..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go
+++ /dev/null
@@ -1,32 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-// Package sts provides the client and types for making API
-// requests to AWS Security Token Service.
-//
-// AWS Security Token Service (STS) enables you to request temporary, limited-privilege
-// credentials for AWS Identity and Access Management (IAM) users or for users
-// that you authenticate (federated users). This guide provides descriptions
-// of the STS API. For more information about using this service, see Temporary
-// Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html).
-//
-// See https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15 for more information on this service.
-//
-// See sts package documentation for more information.
-// https://docs.aws.amazon.com/sdk-for-go/api/service/sts/
-//
-// Using the Client
-//
-// To contact AWS Security Token Service with the SDK use the New function to create
-// a new service client. With that client you can make API requests to the service.
-// These clients are safe to use concurrently.
-//
-// See the SDK's documentation for more information on how to use the SDK.
-// https://docs.aws.amazon.com/sdk-for-go/api/
-//
-// See aws.Config documentation for more information on configuring SDK clients.
-// https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config
-//
-// See the AWS Security Token Service client STS for more
-// information on creating client for this service.
-// https://docs.aws.amazon.com/sdk-for-go/api/service/sts/#New
-package sts
diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/errors.go b/vendor/github.com/aws/aws-sdk-go/service/sts/errors.go
deleted file mode 100644
index a233f542ef29..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/sts/errors.go
+++ /dev/null
@@ -1,82 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-package sts
-
-const (
-
- // ErrCodeExpiredTokenException for service response error code
- // "ExpiredTokenException".
- //
- // The web identity token that was passed is expired or is not valid. Get a
- // new identity token from the identity provider and then retry the request.
- ErrCodeExpiredTokenException = "ExpiredTokenException"
-
- // ErrCodeIDPCommunicationErrorException for service response error code
- // "IDPCommunicationError".
- //
- // The request could not be fulfilled because the identity provider (IDP) that
- // was asked to verify the incoming identity token could not be reached. This
- // is often a transient error caused by network conditions. Retry the request
- // a limited number of times so that you don't exceed the request rate. If the
- // error persists, the identity provider might be down or not responding.
- ErrCodeIDPCommunicationErrorException = "IDPCommunicationError"
-
- // ErrCodeIDPRejectedClaimException for service response error code
- // "IDPRejectedClaim".
- //
- // The identity provider (IdP) reported that authentication failed. This might
- // be because the claim is invalid.
- //
- // If this error is returned for the AssumeRoleWithWebIdentity operation, it
- // can also mean that the claim has expired or has been explicitly revoked.
- ErrCodeIDPRejectedClaimException = "IDPRejectedClaim"
-
- // ErrCodeInvalidAuthorizationMessageException for service response error code
- // "InvalidAuthorizationMessageException".
- //
- // The error returned if the message passed to DecodeAuthorizationMessage was
- // invalid. This can happen if the token contains invalid characters, such as
- // linebreaks.
- ErrCodeInvalidAuthorizationMessageException = "InvalidAuthorizationMessageException"
-
- // ErrCodeInvalidIdentityTokenException for service response error code
- // "InvalidIdentityToken".
- //
- // The web identity token that was passed could not be validated by AWS. Get
- // a new identity token from the identity provider and then retry the request.
- ErrCodeInvalidIdentityTokenException = "InvalidIdentityToken"
-
- // ErrCodeMalformedPolicyDocumentException for service response error code
- // "MalformedPolicyDocument".
- //
- // The request was rejected because the policy document was malformed. The error
- // message describes the specific error.
- ErrCodeMalformedPolicyDocumentException = "MalformedPolicyDocument"
-
- // ErrCodePackedPolicyTooLargeException for service response error code
- // "PackedPolicyTooLarge".
- //
- // The request was rejected because the total packed size of the session policies
- // and session tags combined was too large. An AWS conversion compresses the
- // session policy document, session policy ARNs, and session tags into a packed
- // binary format that has a separate limit. The error message indicates by percentage
- // how close the policies and tags are to the upper size limit. For more information,
- // see Passing Session Tags in STS (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html)
- // in the IAM User Guide.
- //
- // You could receive this error even though you meet other defined session policy
- // and session tag limits. For more information, see IAM and STS Entity Character
- // Limits (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
- // in the IAM User Guide.
- ErrCodePackedPolicyTooLargeException = "PackedPolicyTooLarge"
-
- // ErrCodeRegionDisabledException for service response error code
- // "RegionDisabledException".
- //
- // STS is not activated in the requested region for the account that is being
- // asked to generate credentials. The account administrator must use the IAM
- // console to activate STS in that region. For more information, see Activating
- // and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html)
- // in the IAM User Guide.
- ErrCodeRegionDisabledException = "RegionDisabledException"
-)
diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/service.go b/vendor/github.com/aws/aws-sdk-go/service/sts/service.go
deleted file mode 100644
index d34a6855331b..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/sts/service.go
+++ /dev/null
@@ -1,98 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-package sts
-
-import (
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/client"
- "github.com/aws/aws-sdk-go/aws/client/metadata"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/aws/signer/v4"
- "github.com/aws/aws-sdk-go/private/protocol/query"
-)
-
-// STS provides the API operation methods for making requests to
-// AWS Security Token Service. See this package's package overview docs
-// for details on the service.
-//
-// STS methods are safe to use concurrently. It is not safe to
-// modify mutate any of the struct's properties though.
-type STS struct {
- *client.Client
-}
-
-// Used for custom client initialization logic
-var initClient func(*client.Client)
-
-// Used for custom request initialization logic
-var initRequest func(*request.Request)
-
-// Service information constants
-const (
- ServiceName = "sts" // Name of service.
- EndpointsID = ServiceName // ID to lookup a service endpoint with.
- ServiceID = "STS" // ServiceID is a unique identifier of a specific service.
-)
-
-// New creates a new instance of the STS client with a session.
-// If additional configuration is needed for the client instance use the optional
-// aws.Config parameter to add your extra config.
-//
-// Example:
-// mySession := session.Must(session.NewSession())
-//
-// // Create a STS client from just a session.
-// svc := sts.New(mySession)
-//
-// // Create a STS client with additional configuration
-// svc := sts.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
-func New(p client.ConfigProvider, cfgs ...*aws.Config) *STS {
- c := p.ClientConfig(EndpointsID, cfgs...)
- return newClient(*c.Config, c.Handlers, c.PartitionID, c.Endpoint, c.SigningRegion, c.SigningName)
-}
-
-// newClient creates, initializes and returns a new service client instance.
-func newClient(cfg aws.Config, handlers request.Handlers, partitionID, endpoint, signingRegion, signingName string) *STS {
- svc := &STS{
- Client: client.New(
- cfg,
- metadata.ClientInfo{
- ServiceName: ServiceName,
- ServiceID: ServiceID,
- SigningName: signingName,
- SigningRegion: signingRegion,
- PartitionID: partitionID,
- Endpoint: endpoint,
- APIVersion: "2011-06-15",
- },
- handlers,
- ),
- }
-
- // Handlers
- svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
- svc.Handlers.Build.PushBackNamed(query.BuildHandler)
- svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
- svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
- svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
-
- // Run custom client initialization if present
- if initClient != nil {
- initClient(svc.Client)
- }
-
- return svc
-}
-
-// newRequest creates a new request for a STS operation and runs any
-// custom request initialization.
-func (c *STS) newRequest(op *request.Operation, params, data interface{}) *request.Request {
- req := c.NewRequest(op, params, data)
-
- // Run custom request initialization if present
- if initRequest != nil {
- initRequest(req)
- }
-
- return req
-}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/stsiface/interface.go b/vendor/github.com/aws/aws-sdk-go/service/sts/stsiface/interface.go
deleted file mode 100644
index e2e1d6efe55f..000000000000
--- a/vendor/github.com/aws/aws-sdk-go/service/sts/stsiface/interface.go
+++ /dev/null
@@ -1,96 +0,0 @@
-// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
-
-// Package stsiface provides an interface to enable mocking the AWS Security Token Service service client
-// for testing your code.
-//
-// It is important to note that this interface will have breaking changes
-// when the service model is updated and adds new API operations, paginators,
-// and waiters.
-package stsiface
-
-import (
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/service/sts"
-)
-
-// STSAPI provides an interface to enable mocking the
-// sts.STS service client's API operation,
-// paginators, and waiters. This make unit testing your code that calls out
-// to the SDK's service client's calls easier.
-//
-// The best way to use this interface is so the SDK's service client's calls
-// can be stubbed out for unit testing your code with the SDK without needing
-// to inject custom request handlers into the SDK's request pipeline.
-//
-// // myFunc uses an SDK service client to make a request to
-// // AWS Security Token Service.
-// func myFunc(svc stsiface.STSAPI) bool {
-// // Make svc.AssumeRole request
-// }
-//
-// func main() {
-// sess := session.New()
-// svc := sts.New(sess)
-//
-// myFunc(svc)
-// }
-//
-// In your _test.go file:
-//
-// // Define a mock struct to be used in your unit tests of myFunc.
-// type mockSTSClient struct {
-// stsiface.STSAPI
-// }
-// func (m *mockSTSClient) AssumeRole(input *sts.AssumeRoleInput) (*sts.AssumeRoleOutput, error) {
-// // mock response/functionality
-// }
-//
-// func TestMyFunc(t *testing.T) {
-// // Setup Test
-// mockSvc := &mockSTSClient{}
-//
-// myfunc(mockSvc)
-//
-// // Verify myFunc's functionality
-// }
-//
-// It is important to note that this interface will have breaking changes
-// when the service model is updated and adds new API operations, paginators,
-// and waiters. Its suggested to use the pattern above for testing, or using
-// tooling to generate mocks to satisfy the interfaces.
-type STSAPI interface {
- AssumeRole(*sts.AssumeRoleInput) (*sts.AssumeRoleOutput, error)
- AssumeRoleWithContext(aws.Context, *sts.AssumeRoleInput, ...request.Option) (*sts.AssumeRoleOutput, error)
- AssumeRoleRequest(*sts.AssumeRoleInput) (*request.Request, *sts.AssumeRoleOutput)
-
- AssumeRoleWithSAML(*sts.AssumeRoleWithSAMLInput) (*sts.AssumeRoleWithSAMLOutput, error)
- AssumeRoleWithSAMLWithContext(aws.Context, *sts.AssumeRoleWithSAMLInput, ...request.Option) (*sts.AssumeRoleWithSAMLOutput, error)
- AssumeRoleWithSAMLRequest(*sts.AssumeRoleWithSAMLInput) (*request.Request, *sts.AssumeRoleWithSAMLOutput)
-
- AssumeRoleWithWebIdentity(*sts.AssumeRoleWithWebIdentityInput) (*sts.AssumeRoleWithWebIdentityOutput, error)
- AssumeRoleWithWebIdentityWithContext(aws.Context, *sts.AssumeRoleWithWebIdentityInput, ...request.Option) (*sts.AssumeRoleWithWebIdentityOutput, error)
- AssumeRoleWithWebIdentityRequest(*sts.AssumeRoleWithWebIdentityInput) (*request.Request, *sts.AssumeRoleWithWebIdentityOutput)
-
- DecodeAuthorizationMessage(*sts.DecodeAuthorizationMessageInput) (*sts.DecodeAuthorizationMessageOutput, error)
- DecodeAuthorizationMessageWithContext(aws.Context, *sts.DecodeAuthorizationMessageInput, ...request.Option) (*sts.DecodeAuthorizationMessageOutput, error)
- DecodeAuthorizationMessageRequest(*sts.DecodeAuthorizationMessageInput) (*request.Request, *sts.DecodeAuthorizationMessageOutput)
-
- GetAccessKeyInfo(*sts.GetAccessKeyInfoInput) (*sts.GetAccessKeyInfoOutput, error)
- GetAccessKeyInfoWithContext(aws.Context, *sts.GetAccessKeyInfoInput, ...request.Option) (*sts.GetAccessKeyInfoOutput, error)
- GetAccessKeyInfoRequest(*sts.GetAccessKeyInfoInput) (*request.Request, *sts.GetAccessKeyInfoOutput)
-
- GetCallerIdentity(*sts.GetCallerIdentityInput) (*sts.GetCallerIdentityOutput, error)
- GetCallerIdentityWithContext(aws.Context, *sts.GetCallerIdentityInput, ...request.Option) (*sts.GetCallerIdentityOutput, error)
- GetCallerIdentityRequest(*sts.GetCallerIdentityInput) (*request.Request, *sts.GetCallerIdentityOutput)
-
- GetFederationToken(*sts.GetFederationTokenInput) (*sts.GetFederationTokenOutput, error)
- GetFederationTokenWithContext(aws.Context, *sts.GetFederationTokenInput, ...request.Option) (*sts.GetFederationTokenOutput, error)
- GetFederationTokenRequest(*sts.GetFederationTokenInput) (*request.Request, *sts.GetFederationTokenOutput)
-
- GetSessionToken(*sts.GetSessionTokenInput) (*sts.GetSessionTokenOutput, error)
- GetSessionTokenWithContext(aws.Context, *sts.GetSessionTokenInput, ...request.Option) (*sts.GetSessionTokenOutput, error)
- GetSessionTokenRequest(*sts.GetSessionTokenInput) (*request.Request, *sts.GetSessionTokenOutput)
-}
-
-var _ STSAPI = (*sts.STS)(nil)
diff --git a/vendor/github.com/aws/smithy-go/.gitignore b/vendor/github.com/aws/smithy-go/.gitignore
new file mode 100644
index 000000000000..c01141aa450d
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/.gitignore
@@ -0,0 +1,22 @@
+# Eclipse
+.classpath
+.project
+.settings/
+
+# Intellij
+.idea/
+*.iml
+*.iws
+
+# Mac
+.DS_Store
+
+# Maven
+target/
+**/dependency-reduced-pom.xml
+
+# Gradle
+/.gradle
+build/
+*/out/
+*/*/out/
diff --git a/vendor/github.com/aws/smithy-go/.travis.yml b/vendor/github.com/aws/smithy-go/.travis.yml
new file mode 100644
index 000000000000..f8d1035cc332
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/.travis.yml
@@ -0,0 +1,28 @@
+language: go
+sudo: true
+dist: bionic
+
+branches:
+ only:
+ - main
+
+os:
+ - linux
+ - osx
+ # Travis doesn't work with windows and Go tip
+ #- windows
+
+go:
+ - tip
+
+matrix:
+ allow_failures:
+ - go: tip
+
+before_install:
+ - if [ "$TRAVIS_OS_NAME" = "windows" ]; then choco install make; fi
+ - (cd /tmp/; go get golang.org/x/lint/golint)
+
+script:
+ - make go test -v ./...;
+
diff --git a/vendor/github.com/aws/smithy-go/CHANGELOG.md b/vendor/github.com/aws/smithy-go/CHANGELOG.md
new file mode 100644
index 000000000000..919becce9626
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/CHANGELOG.md
@@ -0,0 +1,99 @@
+# Release (v1.9.1)
+
+## Module Highlights
+* `github.com/aws/smithy-go`: v1.9.1
+ * **Documentation**: Fixes various typos in Go package documentation.
+
+# Release (v1.9.0)
+
+## Module Highlights
+* `github.com/aws/smithy-go`: v1.9.0
+ * **Feature**: sync: OnceErr, can be used to concurrently record a signal when an error has occurred.
+ * **Bug Fix**: `transport/http`: CloseResponseBody and ErrorCloseResponseBody middleware have been updated to ensure that the body is fully drained before closing.
+
+# Release v1.8.1
+
+### Smithy Go Module
+* **Bug Fix**: Fixed an issue that would cause the HTTP Content-Length to be set to 0 if the stream body was not set.
+ * Fixes [aws/aws-sdk-go-v2#1418](https://github.com/aws/aws-sdk-go-v2/issues/1418)
+
+# Release v1.8.0
+
+### Smithy Go Module
+
+* `time`: Add support for parsing additional DateTime timestamp format ([#324](https://github.com/aws/smithy-go/pull/324))
+ * Adds support for parsing DateTime timestamp formatted time similar to RFC 3339, but without the `Z` character, nor UTC offset.
+ * Fixes [#1387](https://github.com/aws/aws-sdk-go-v2/issues/1387)
+
+# Release v1.7.0
+
+### Smithy Go Module
+* `ptr`: Handle error for deferred file close call ([#314](https://github.com/aws/smithy-go/pull/314))
+ * Handle error for defer close call
+* `middleware`: Add Clone to Metadata ([#318](https://github.com/aws/smithy-go/pull/318))
+ * Adds a new Clone method to the middleware Metadata type. This provides a shallow clone of the entries in the Metadata.
+* `document`: Add new package for document shape serialization support ([#310](https://github.com/aws/smithy-go/pull/310))
+
+### Codegen
+* Add Smithy Document Shape Support ([#310](https://github.com/aws/smithy-go/pull/310))
+ * Adds support for Smithy Document shapes and supporting types for protocols to implement support
+
+# Release v1.6.0 (2021-07-15)
+
+### Smithy Go Module
+* `encoding/httpbinding`: Support has been added for encoding `float32` and `float64` values that are `NaN`, `Infinity`, or `-Infinity`. ([#316](https://github.com/aws/smithy-go/pull/316))
+
+### Codegen
+* Adds support for handling `float32` and `float64` `NaN` values in HTTP Protocol Unit Tests. ([#316](https://github.com/aws/smithy-go/pull/316))
+* Adds support protocol generator implementations to override the error code string returned by `ErrorCode` methods on generated error types. ([#315](https://github.com/aws/smithy-go/pull/315))
+
+# Release v1.5.0 (2021-06-25)
+
+### Smithy Go module
+* `time`: Update time parsing to not be as strict for HTTPDate and DateTime ([#307](https://github.com/aws/smithy-go/pull/307))
+ * Fixes [#302](https://github.com/aws/smithy-go/issues/302) by changing time to UTC before formatting so no local offset time is lost.
+
+### Codegen
+* Adds support for integrating client members via plugins ([#301](https://github.com/aws/smithy-go/pull/301))
+* Fix serialization of enum types marked with payload trait ([#296](https://github.com/aws/smithy-go/pull/296))
+* Update generation of API client modules to include a manifest of files generated ([#283](https://github.com/aws/smithy-go/pull/283))
+* Update Group Java group ID for smithy-go generator ([#298](https://github.com/aws/smithy-go/pull/298))
+* Support the delegation of determining the errors that can occur for an operation ([#304](https://github.com/aws/smithy-go/pull/304))
+* Support for marking and documenting deprecated client config fields. ([#303](https://github.com/aws/smithy-go/pull/303))
+
+# Release v1.4.0 (2021-05-06)
+
+### Smithy Go module
+* `encoding/xml`: Fix escaping of Next Line and Line Start in XML Encoder ([#267](https://github.com/aws/smithy-go/pull/267))
+
+### Codegen
+* Add support for Smithy 1.7 ([#289](https://github.com/aws/smithy-go/pull/289))
+* Add support for httpQueryParams location
+* Add support for model renaming conflict resolution with service closure
+
+# Release v1.3.1 (2021-04-08)
+
+### Smithy Go module
+* `transport/http`: Loosen endpoint hostname validation to allow specifying port numbers. ([#279](https://github.com/aws/smithy-go/pull/279))
+* `io`: Fix RingBuffer panics due to out of bounds index. ([#282](https://github.com/aws/smithy-go/pull/282))
+
+# Release v1.3.0 (2021-04-01)
+
+### Smithy Go module
+* `transport/http`: Add utility to safely join string to url path, and url raw query.
+
+### Codegen
+* Update HttpBindingProtocolGenerator to use http/transport JoinPath and JoinQuery utility.
+
+# Release v1.2.0 (2021-03-12)
+
+### Smithy Go module
+* Fix support for parsing shortened year format in HTTP Date header.
+* Fix GitHub APIDiff action workflow to get gorelease tool correctly.
+* Fix codegen artifact unit test for Go 1.16
+
+### Codegen
+* Fix generating paginator nil parameter handling before usage.
+* Fix Serialize unboxed members decorated as required.
+* Add ability to define resolvers at both client construction and operation invocation.
+* Support for extending paginators with custom runtime trait
diff --git a/vendor/github.com/aws/smithy-go/CODE_OF_CONDUCT.md b/vendor/github.com/aws/smithy-go/CODE_OF_CONDUCT.md
new file mode 100644
index 000000000000..5b627cfa60b5
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/CODE_OF_CONDUCT.md
@@ -0,0 +1,4 @@
+## Code of Conduct
+This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct).
+For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact
+opensource-codeofconduct@amazon.com with any additional questions or comments.
diff --git a/vendor/github.com/aws/smithy-go/CONTRIBUTING.md b/vendor/github.com/aws/smithy-go/CONTRIBUTING.md
new file mode 100644
index 000000000000..c4b6a1c5081a
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/CONTRIBUTING.md
@@ -0,0 +1,59 @@
+# Contributing Guidelines
+
+Thank you for your interest in contributing to our project. Whether it's a bug report, new feature, correction, or additional
+documentation, we greatly value feedback and contributions from our community.
+
+Please read through this document before submitting any issues or pull requests to ensure we have all the necessary
+information to effectively respond to your bug report or contribution.
+
+
+## Reporting Bugs/Feature Requests
+
+We welcome you to use the GitHub issue tracker to report bugs or suggest features.
+
+When filing an issue, please check existing open, or recently closed, issues to make sure somebody else hasn't already
+reported the issue. Please try to include as much information as you can. Details like these are incredibly useful:
+
+* A reproducible test case or series of steps
+* The version of our code being used
+* Any modifications you've made relevant to the bug
+* Anything unusual about your environment or deployment
+
+
+## Contributing via Pull Requests
+Contributions via pull requests are much appreciated. Before sending us a pull request, please ensure that:
+
+1. You are working against the latest source on the *main* branch.
+2. You check existing open, and recently merged, pull requests to make sure someone else hasn't addressed the problem already.
+3. You open an issue to discuss any significant work - we would hate for your time to be wasted.
+
+To send us a pull request, please:
+
+1. Fork the repository.
+2. Modify the source; please focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change.
+3. Ensure local tests pass.
+4. Commit to your fork using clear commit messages.
+5. Send us a pull request, answering any default questions in the pull request interface.
+6. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation.
+
+GitHub provides additional document on [forking a repository](https://help.github.com/articles/fork-a-repo/) and
+[creating a pull request](https://help.github.com/articles/creating-a-pull-request/).
+
+
+## Finding contributions to work on
+Looking at the existing issues is a great way to find something to contribute on. As our projects, by default, use the default GitHub issue labels (enhancement/bug/duplicate/help wanted/invalid/question/wontfix), looking at any 'help wanted' issues is a great place to start.
+
+
+## Code of Conduct
+This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct).
+For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact
+opensource-codeofconduct@amazon.com with any additional questions or comments.
+
+
+## Security issue notifications
+If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](http://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public github issue.
+
+
+## Licensing
+
+See the [LICENSE](LICENSE) file for our project's licensing. We will ask you to confirm the licensing of your contribution.
diff --git a/vendor/github.com/aws/smithy-go/LICENSE b/vendor/github.com/aws/smithy-go/LICENSE
new file mode 100644
index 000000000000..67db8588217f
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/LICENSE
@@ -0,0 +1,175 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
diff --git a/vendor/github.com/aws/smithy-go/Makefile b/vendor/github.com/aws/smithy-go/Makefile
new file mode 100644
index 000000000000..b8c657435ee5
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/Makefile
@@ -0,0 +1,63 @@
+PRE_RELEASE_VERSION ?=
+
+RELEASE_MANIFEST_FILE ?=
+RELEASE_CHGLOG_DESC_FILE ?=
+
+REPOTOOLS_VERSION ?= latest
+REPOTOOLS_MODULE = github.com/awslabs/aws-go-multi-module-repository-tools
+REPOTOOLS_CMD_CALCULATE_RELEASE = ${REPOTOOLS_MODULE}/cmd/calculaterelease@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_CALCULATE_RELEASE_ADDITIONAL_ARGS ?=
+REPOTOOLS_CMD_UPDATE_REQUIRES = ${REPOTOOLS_MODULE}/cmd/updaterequires@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_UPDATE_MODULE_METADATA = ${REPOTOOLS_MODULE}/cmd/updatemodulemeta@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_GENERATE_CHANGELOG = ${REPOTOOLS_MODULE}/cmd/generatechangelog@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_CHANGELOG = ${REPOTOOLS_MODULE}/cmd/changelog@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_TAG_RELEASE = ${REPOTOOLS_MODULE}/cmd/tagrelease@${REPOTOOLS_VERSION}
+REPOTOOLS_CMD_MODULE_VERSION = ${REPOTOOLS_MODULE}/cmd/moduleversion@${REPOTOOLS_VERSION}
+
+ifneq ($(PRE_RELEASE_VERSION),)
+ REPOTOOLS_CMD_CALCULATE_RELEASE_ADDITIONAL_ARGS += -preview=${PRE_RELEASE_VERSION}
+endif
+
+smithy-publish-local:
+ cd codegen && ./gradlew publishToMavenLocal
+
+smithy-build:
+ cd codegen && ./gradlew build
+
+smithy-clean:
+ cd codegen && ./gradlew clean
+
+#####################
+# Release Process #
+#####################
+.PHONY: preview-release pre-release-validation release
+
+preview-release:
+ go run ${REPOTOOLS_CMD_CALCULATE_RELEASE} ${REPOTOOLS_CMD_CALCULATE_RELEASE_ADDITIONAL_ARGS}
+
+pre-release-validation:
+ @if [[ -z "${RELEASE_MANIFEST_FILE}" ]]; then \
+ echo "RELEASE_MANIFEST_FILE is required to specify the file to write the release manifest" && false; \
+ fi
+ @if [[ -z "${RELEASE_CHGLOG_DESC_FILE}" ]]; then \
+ echo "RELEASE_CHGLOG_DESC_FILE is required to specify the file to write the release notes" && false; \
+ fi
+
+release: pre-release-validation
+ go run ${REPOTOOLS_CMD_CALCULATE_RELEASE} -o ${RELEASE_MANIFEST_FILE} ${REPOTOOLS_CMD_CALCULATE_RELEASE_ADDITIONAL_ARGS}
+ go run ${REPOTOOLS_CMD_UPDATE_REQUIRES} -release ${RELEASE_MANIFEST_FILE}
+ go run ${REPOTOOLS_CMD_UPDATE_MODULE_METADATA} -release ${RELEASE_MANIFEST_FILE}
+ go run ${REPOTOOLS_CMD_GENERATE_CHANGELOG} -release ${RELEASE_MANIFEST_FILE} -o ${RELEASE_CHGLOG_DESC_FILE}
+ go run ${REPOTOOLS_CMD_CHANGELOG} rm -all
+ go run ${REPOTOOLS_CMD_TAG_RELEASE} -release ${RELEASE_MANIFEST_FILE}
+
+module-version:
+ @go run ${REPOTOOLS_CMD_MODULE_VERSION} .
+
+##############
+# Repo Tools #
+##############
+.PHONY: install-changelog
+
+install-changelog:
+ go install ${REPOTOOLS_MODULE}/cmd/changelog@${REPOTOOLS_VERSION}
diff --git a/vendor/github.com/aws/smithy-go/NOTICE b/vendor/github.com/aws/smithy-go/NOTICE
new file mode 100644
index 000000000000..616fc5889451
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/NOTICE
@@ -0,0 +1 @@
+Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
diff --git a/vendor/github.com/aws/smithy-go/README.md b/vendor/github.com/aws/smithy-go/README.md
new file mode 100644
index 000000000000..789b37889606
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/README.md
@@ -0,0 +1,12 @@
+## Smithy Go
+
+[](https://github.com/aws/smithy-go/actions/workflows/go.yml)[](https://github.com/aws/smithy-go/actions/workflows/codegen.yml)
+
+Smithy code generators for Go.
+
+**WARNING: All interfaces are subject to change.**
+
+## License
+
+This project is licensed under the Apache-2.0 License.
+
diff --git a/vendor/github.com/aws/smithy-go/doc.go b/vendor/github.com/aws/smithy-go/doc.go
new file mode 100644
index 000000000000..87b0c74b75c6
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/doc.go
@@ -0,0 +1,2 @@
+// Package smithy provides the core components for a Smithy SDK.
+package smithy
diff --git a/vendor/github.com/aws/smithy-go/document.go b/vendor/github.com/aws/smithy-go/document.go
new file mode 100644
index 000000000000..dec498c57bf9
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/document.go
@@ -0,0 +1,10 @@
+package smithy
+
+// Document provides access to loosely structured data in a document-like
+// format.
+//
+// Deprecated: See the github.com/aws/smithy-go/document package.
+type Document interface {
+ UnmarshalDocument(interface{}) error
+ GetValue() (interface{}, error)
+}
diff --git a/vendor/github.com/aws/smithy-go/document/doc.go b/vendor/github.com/aws/smithy-go/document/doc.go
new file mode 100644
index 000000000000..03055b7a1c2e
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/document/doc.go
@@ -0,0 +1,12 @@
+// Package document provides interface definitions and error types for document types.
+//
+// A document is a protocol-agnostic type which supports a JSON-like data-model. You can use this type to send
+// UTF-8 strings, arbitrary precision numbers, booleans, nulls, a list of these values, and a map of UTF-8
+// strings to these values.
+//
+// API Clients expose document constructors in their respective client document packages which must be used to
+// Marshal and Unmarshal Go types to and from their respective protocol representations.
+//
+// See the Marshaler and Unmarshaler type documentation for more details on how to Go types can be converted to and from
+// document types.
+package document
diff --git a/vendor/github.com/aws/smithy-go/document/document.go b/vendor/github.com/aws/smithy-go/document/document.go
new file mode 100644
index 000000000000..8f852d95c699
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/document/document.go
@@ -0,0 +1,153 @@
+package document
+
+import (
+ "fmt"
+ "math/big"
+ "strconv"
+)
+
+// Marshaler is an interface for a type that marshals a document to its protocol-specific byte representation and
+// returns the resulting bytes. A non-nil error will be returned if an error is encountered during marshaling.
+//
+// Marshal supports basic scalars (int,uint,float,bool,string), big.Int, and big.Float, maps, slices, and structs.
+// Anonymous nested types are flattened based on Go anonymous type visibility.
+//
+// When defining struct types. the `document` struct tag can be used to control how the value will be
+// marshaled into the resulting protocol document.
+//
+// // Field is ignored
+// Field int `document:"-"`
+//
+// // Field object of key "myName"
+// Field int `document:"myName"`
+//
+// // Field object key of key "myName", and
+// // Field is omitted if the field is a zero value for the type.
+// Field int `document:"myName,omitempty"`
+//
+// // Field object key of "Field", and
+// // Field is omitted if the field is a zero value for the type.
+// Field int `document:",omitempty"`
+//
+// All struct fields, including anonymous fields, are marshaled unless the
+// any of the following conditions are meet.
+//
+// - the field is not exported
+// - document field tag is "-"
+// - document field tag specifies "omitempty", and is a zero value.
+//
+// Pointer and interface values are encoded as the value pointed to or
+// contained in the interface. A nil value encodes as a null
+// value unless `omitempty` struct tag is provided.
+//
+// Channel, complex, and function values are not encoded and will be skipped
+// when walking the value to be marshaled.
+//
+// time.Time is not supported and will cause the Marshaler to return an error. These values should be represented
+// by your application as a string or numerical representation.
+//
+// Errors that occur when marshaling will stop the marshaler, and return the error.
+//
+// Marshal cannot represent cyclic data structures and will not handle them.
+// Passing cyclic structures to Marshal will result in an infinite recursion.
+type Marshaler interface {
+ MarshalSmithyDocument() ([]byte, error)
+}
+
+// Unmarshaler is an interface for a type that unmarshals a document from its protocol-specific representation, and
+// stores the result into the value pointed by v. If v is nil or not a pointer then InvalidUnmarshalError will be
+// returned.
+//
+// Unmarshaler supports the same encodings produced by a document Marshaler. This includes support for the `document`
+// struct field tag for controlling how struct fields are unmarshaled.
+//
+// Both generic interface{} and concrete types are valid unmarshal destination types. When unmarshaling a document
+// into an empty interface the Unmarshaler will store one of these values:
+// bool, for boolean values
+// document.Number, for arbitrary-precision numbers (int64, float64, big.Int, big.Float)
+// string, for string values
+// []interface{}, for array values
+// map[string]interface{}, for objects
+// nil, for null values
+//
+// When unmarshaling, any error that occurs will halt the unmarshal and return the error.
+type Unmarshaler interface {
+ UnmarshalSmithyDocument(v interface{}) error
+}
+
+type noSerde interface {
+ noSmithyDocumentSerde()
+}
+
+// NoSerde is a sentinel value to indicate that a given type should not be marshaled or unmarshaled
+// into a protocol document.
+type NoSerde struct{}
+
+func (n NoSerde) noSmithyDocumentSerde() {}
+
+var _ noSerde = (*NoSerde)(nil)
+
+// IsNoSerde returns whether the given type implements the no smithy document serde interface.
+func IsNoSerde(x interface{}) bool {
+ _, ok := x.(noSerde)
+ return ok
+}
+
+// Number is an arbitrary precision numerical value
+type Number string
+
+// Int64 returns the number as a string.
+func (n Number) String() string {
+ return string(n)
+}
+
+// Int64 returns the number as an int64.
+func (n Number) Int64() (int64, error) {
+ return n.intOfBitSize(64)
+}
+
+func (n Number) intOfBitSize(bitSize int) (int64, error) {
+ return strconv.ParseInt(string(n), 10, bitSize)
+}
+
+// Uint64 returns the number as a uint64.
+func (n Number) Uint64() (uint64, error) {
+ return n.uintOfBitSize(64)
+}
+
+func (n Number) uintOfBitSize(bitSize int) (uint64, error) {
+ return strconv.ParseUint(string(n), 10, bitSize)
+}
+
+// Float32 returns the number parsed as a 32-bit float, returns a float64.
+func (n Number) Float32() (float64, error) {
+ return n.floatOfBitSize(32)
+}
+
+// Float64 returns the number as a float64.
+func (n Number) Float64() (float64, error) {
+ return n.floatOfBitSize(64)
+}
+
+// Float64 returns the number as a float64.
+func (n Number) floatOfBitSize(bitSize int) (float64, error) {
+ return strconv.ParseFloat(string(n), bitSize)
+}
+
+// BigFloat attempts to convert the number to a big.Float, returns an error if the operation fails.
+func (n Number) BigFloat() (*big.Float, error) {
+ f, ok := (&big.Float{}).SetString(string(n))
+ if !ok {
+ return nil, fmt.Errorf("failed to convert to big.Float")
+ }
+ return f, nil
+}
+
+// BigInt attempts to convert the number to a big.Int, returns an error if the operation fails.
+func (n Number) BigInt() (*big.Int, error) {
+ f, ok := (&big.Int{}).SetString(string(n), 10)
+ if !ok {
+ return nil, fmt.Errorf("failed to convert to big.Float")
+ }
+ return f, nil
+}
diff --git a/vendor/github.com/aws/smithy-go/document/errors.go b/vendor/github.com/aws/smithy-go/document/errors.go
new file mode 100644
index 000000000000..046a7a765318
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/document/errors.go
@@ -0,0 +1,75 @@
+package document
+
+import (
+ "fmt"
+ "reflect"
+)
+
+// UnmarshalTypeError is an error type representing an error
+// unmarshaling a Smithy document to a Go value type. This is different
+// from UnmarshalError in that it does not wrap an underlying error type.
+type UnmarshalTypeError struct {
+ Value string
+ Type reflect.Type
+}
+
+// Error returns the string representation of the error.
+// Satisfying the error interface.
+func (e *UnmarshalTypeError) Error() string {
+ return fmt.Sprintf("unmarshal failed, cannot unmarshal %s into Go value type %s",
+ e.Value, e.Type.String())
+}
+
+// An InvalidUnmarshalError is an error type representing an invalid type
+// encountered while unmarshaling a Smithy document to a Go value type.
+type InvalidUnmarshalError struct {
+ Type reflect.Type
+}
+
+// Error returns the string representation of the error.
+// Satisfying the error interface.
+func (e *InvalidUnmarshalError) Error() string {
+ var msg string
+ if e.Type == nil {
+ msg = "cannot unmarshal to nil value"
+ } else if e.Type.Kind() != reflect.Ptr {
+ msg = fmt.Sprintf("cannot unmarshal to non-pointer value, got %s", e.Type.String())
+ } else {
+ msg = fmt.Sprintf("cannot unmarshal to nil value, %s", e.Type.String())
+ }
+
+ return fmt.Sprintf("unmarshal failed, %s", msg)
+}
+
+// An UnmarshalError wraps an error that occurred while unmarshaling a
+// Smithy document into a Go type. This is different from
+// UnmarshalTypeError in that it wraps the underlying error that occurred.
+type UnmarshalError struct {
+ Err error
+ Value string
+ Type reflect.Type
+}
+
+// Unwrap returns the underlying unmarshaling error
+func (e *UnmarshalError) Unwrap() error {
+ return e.Err
+}
+
+// Error returns the string representation of the error.
+// Satisfying the error interface.
+func (e *UnmarshalError) Error() string {
+ return fmt.Sprintf("unmarshal failed, cannot unmarshal %q into %s, %v",
+ e.Value, e.Type.String(), e.Err)
+}
+
+// An InvalidMarshalError is an error type representing an error
+// occurring when marshaling a Go value type.
+type InvalidMarshalError struct {
+ Message string
+}
+
+// Error returns the string representation of the error.
+// Satisfying the error interface.
+func (e *InvalidMarshalError) Error() string {
+ return fmt.Sprintf("marshal failed, %s", e.Message)
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/doc.go b/vendor/github.com/aws/smithy-go/encoding/doc.go
new file mode 100644
index 000000000000..792fdfa08b39
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/doc.go
@@ -0,0 +1,4 @@
+// Package encoding provides utilities for encoding values for specific
+// document encodings.
+
+package encoding
diff --git a/vendor/github.com/aws/smithy-go/encoding/encoding.go b/vendor/github.com/aws/smithy-go/encoding/encoding.go
new file mode 100644
index 000000000000..2fdfb5225027
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/encoding.go
@@ -0,0 +1,40 @@
+package encoding
+
+import (
+ "fmt"
+ "math"
+ "strconv"
+)
+
+// EncodeFloat encodes a float value as per the stdlib encoder for json and xml protocol
+// This encodes a float value into dst while attempting to conform to ES6 ToString for Numbers
+//
+// Based on encoding/json floatEncoder from the Go Standard Library
+// https://golang.org/src/encoding/json/encode.go
+func EncodeFloat(dst []byte, v float64, bits int) []byte {
+ if math.IsInf(v, 0) || math.IsNaN(v) {
+ panic(fmt.Sprintf("invalid float value: %s", strconv.FormatFloat(v, 'g', -1, bits)))
+ }
+
+ abs := math.Abs(v)
+ fmt := byte('f')
+
+ if abs != 0 {
+ if bits == 64 && (abs < 1e-6 || abs >= 1e21) || bits == 32 && (float32(abs) < 1e-6 || float32(abs) >= 1e21) {
+ fmt = 'e'
+ }
+ }
+
+ dst = strconv.AppendFloat(dst, v, fmt, -1, bits)
+
+ if fmt == 'e' {
+ // clean up e-09 to e-9
+ n := len(dst)
+ if n >= 4 && dst[n-4] == 'e' && dst[n-3] == '-' && dst[n-2] == '0' {
+ dst[n-2] = dst[n-1]
+ dst = dst[:n-1]
+ }
+ }
+
+ return dst
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/httpbinding/encode.go b/vendor/github.com/aws/smithy-go/encoding/httpbinding/encode.go
new file mode 100644
index 000000000000..96abd073ab1c
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/httpbinding/encode.go
@@ -0,0 +1,116 @@
+package httpbinding
+
+import (
+ "fmt"
+ "net/http"
+ "net/url"
+ "strconv"
+ "strings"
+)
+
+const (
+ contentLengthHeader = "Content-Length"
+ floatNaN = "NaN"
+ floatInfinity = "Infinity"
+ floatNegInfinity = "-Infinity"
+)
+
+// An Encoder provides encoding of REST URI path, query, and header components
+// of an HTTP request. Can also encode a stream as the payload.
+//
+// Does not support SetFields.
+type Encoder struct {
+ path, rawPath, pathBuffer []byte
+
+ query url.Values
+ header http.Header
+}
+
+// NewEncoder creates a new encoder from the passed in request. All query and
+// header values will be added on top of the request's existing values. Overwriting
+// duplicate values.
+func NewEncoder(path, query string, headers http.Header) (*Encoder, error) {
+ parseQuery, err := url.ParseQuery(query)
+ if err != nil {
+ return nil, fmt.Errorf("failed to parse query string: %w", err)
+ }
+
+ e := &Encoder{
+ path: []byte(path),
+ rawPath: []byte(path),
+ query: parseQuery,
+ header: headers.Clone(),
+ }
+
+ return e, nil
+}
+
+// Encode returns a REST protocol encoder for encoding HTTP bindings.
+//
+// Due net/http requiring `Content-Length` to be specified on the http.Request#ContentLength directly. Encode
+// will look for whether the header is present, and if so will remove it and set the respective value on http.Request.
+//
+// Returns any error occurring during encoding.
+func (e *Encoder) Encode(req *http.Request) (*http.Request, error) {
+ req.URL.Path, req.URL.RawPath = string(e.path), string(e.rawPath)
+ req.URL.RawQuery = e.query.Encode()
+
+ // net/http ignores Content-Length header and requires it to be set on http.Request
+ if v := e.header.Get(contentLengthHeader); len(v) > 0 {
+ iv, err := strconv.ParseInt(v, 10, 64)
+ if err != nil {
+ return nil, err
+ }
+ req.ContentLength = iv
+ e.header.Del(contentLengthHeader)
+ }
+
+ req.Header = e.header
+
+ return req, nil
+}
+
+// AddHeader returns a HeaderValue for appending to the given header name
+func (e *Encoder) AddHeader(key string) HeaderValue {
+ return newHeaderValue(e.header, key, true)
+}
+
+// SetHeader returns a HeaderValue for setting the given header name
+func (e *Encoder) SetHeader(key string) HeaderValue {
+ return newHeaderValue(e.header, key, false)
+}
+
+// Headers returns a Header used for encoding headers with the given prefix
+func (e *Encoder) Headers(prefix string) Headers {
+ return Headers{
+ header: e.header,
+ prefix: strings.TrimSpace(prefix),
+ }
+}
+
+// HasHeader returns if a header with the key specified exists with one or
+// more value.
+func (e Encoder) HasHeader(key string) bool {
+ return len(e.header[key]) != 0
+}
+
+// SetURI returns a URIValue used for setting the given path key
+func (e *Encoder) SetURI(key string) URIValue {
+ return newURIValue(&e.path, &e.rawPath, &e.pathBuffer, key)
+}
+
+// SetQuery returns a QueryValue used for setting the given query key
+func (e *Encoder) SetQuery(key string) QueryValue {
+ return NewQueryValue(e.query, key, false)
+}
+
+// AddQuery returns a QueryValue used for appending the given query key
+func (e *Encoder) AddQuery(key string) QueryValue {
+ return NewQueryValue(e.query, key, true)
+}
+
+// HasQuery returns if a query with the key specified exists with one or
+// more values.
+func (e *Encoder) HasQuery(key string) bool {
+ return len(e.query.Get(key)) != 0
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/httpbinding/header.go b/vendor/github.com/aws/smithy-go/encoding/httpbinding/header.go
new file mode 100644
index 000000000000..f9256e175fc9
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/httpbinding/header.go
@@ -0,0 +1,122 @@
+package httpbinding
+
+import (
+ "encoding/base64"
+ "math"
+ "math/big"
+ "net/http"
+ "strconv"
+ "strings"
+)
+
+// Headers is used to encode header keys using a provided prefix
+type Headers struct {
+ header http.Header
+ prefix string
+}
+
+// AddHeader returns a HeaderValue used to append values to prefix+key
+func (h Headers) AddHeader(key string) HeaderValue {
+ return h.newHeaderValue(key, true)
+}
+
+// SetHeader returns a HeaderValue used to set the value of prefix+key
+func (h Headers) SetHeader(key string) HeaderValue {
+ return h.newHeaderValue(key, false)
+}
+
+func (h Headers) newHeaderValue(key string, append bool) HeaderValue {
+ return newHeaderValue(h.header, h.prefix+strings.TrimSpace(key), append)
+}
+
+// HeaderValue is used to encode values to an HTTP header
+type HeaderValue struct {
+ header http.Header
+ key string
+ append bool
+}
+
+func newHeaderValue(header http.Header, key string, append bool) HeaderValue {
+ return HeaderValue{header: header, key: strings.TrimSpace(key), append: append}
+}
+
+func (h HeaderValue) modifyHeader(value string) {
+ if h.append {
+ h.header[h.key] = append(h.header[h.key], value)
+ } else {
+ h.header[h.key] = append(h.header[h.key][:0], value)
+ }
+}
+
+// String encodes the value v as the header string value
+func (h HeaderValue) String(v string) {
+ h.modifyHeader(v)
+}
+
+// Byte encodes the value v as a query string value
+func (h HeaderValue) Byte(v int8) {
+ h.Long(int64(v))
+}
+
+// Short encodes the value v as a query string value
+func (h HeaderValue) Short(v int16) {
+ h.Long(int64(v))
+}
+
+// Integer encodes the value v as the header string value
+func (h HeaderValue) Integer(v int32) {
+ h.Long(int64(v))
+}
+
+// Long encodes the value v as the header string value
+func (h HeaderValue) Long(v int64) {
+ h.modifyHeader(strconv.FormatInt(v, 10))
+}
+
+// Boolean encodes the value v as a query string value
+func (h HeaderValue) Boolean(v bool) {
+ h.modifyHeader(strconv.FormatBool(v))
+}
+
+// Float encodes the value v as a query string value
+func (h HeaderValue) Float(v float32) {
+ h.float(float64(v), 32)
+}
+
+// Double encodes the value v as a query string value
+func (h HeaderValue) Double(v float64) {
+ h.float(v, 64)
+}
+
+func (h HeaderValue) float(v float64, bitSize int) {
+ switch {
+ case math.IsNaN(v):
+ h.String(floatNaN)
+ case math.IsInf(v, 1):
+ h.String(floatInfinity)
+ case math.IsInf(v, -1):
+ h.String(floatNegInfinity)
+ default:
+ h.modifyHeader(strconv.FormatFloat(v, 'f', -1, bitSize))
+ }
+}
+
+// BigInteger encodes the value v as a query string value
+func (h HeaderValue) BigInteger(v *big.Int) {
+ h.modifyHeader(v.String())
+}
+
+// BigDecimal encodes the value v as a query string value
+func (h HeaderValue) BigDecimal(v *big.Float) {
+ if i, accuracy := v.Int64(); accuracy == big.Exact {
+ h.Long(i)
+ return
+ }
+ h.modifyHeader(v.Text('e', -1))
+}
+
+// Blob encodes the value v as a base64 header string value
+func (h HeaderValue) Blob(v []byte) {
+ encodeToString := base64.StdEncoding.EncodeToString(v)
+ h.modifyHeader(encodeToString)
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/httpbinding/path_replace.go b/vendor/github.com/aws/smithy-go/encoding/httpbinding/path_replace.go
new file mode 100644
index 000000000000..e78926c9a562
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/httpbinding/path_replace.go
@@ -0,0 +1,108 @@
+package httpbinding
+
+import (
+ "bytes"
+ "fmt"
+)
+
+const (
+ uriTokenStart = '{'
+ uriTokenStop = '}'
+ uriTokenSkip = '+'
+)
+
+func bufCap(b []byte, n int) []byte {
+ if cap(b) < n {
+ return make([]byte, 0, n)
+ }
+
+ return b[0:0]
+}
+
+// replacePathElement replaces a single element in the path []byte.
+// Escape is used to control whether the value will be escaped using Amazon path escape style.
+func replacePathElement(path, fieldBuf []byte, key, val string, escape bool) ([]byte, []byte, error) {
+ fieldBuf = bufCap(fieldBuf, len(key)+3) // { [+] }
+ fieldBuf = append(fieldBuf, uriTokenStart)
+ fieldBuf = append(fieldBuf, key...)
+
+ start := bytes.Index(path, fieldBuf)
+ end := start + len(fieldBuf)
+ if start < 0 || len(path[end:]) == 0 {
+ // TODO what to do about error?
+ return path, fieldBuf, fmt.Errorf("invalid path index, start=%d,end=%d. %s", start, end, path)
+ }
+
+ encodeSep := true
+ if path[end] == uriTokenSkip {
+ // '+' token means do not escape slashes
+ encodeSep = false
+ end++
+ }
+
+ if escape {
+ val = EscapePath(val, encodeSep)
+ }
+
+ if path[end] != uriTokenStop {
+ return path, fieldBuf, fmt.Errorf("invalid path element, does not contain token stop, %s", path)
+ }
+ end++
+
+ fieldBuf = bufCap(fieldBuf, len(val))
+ fieldBuf = append(fieldBuf, val...)
+
+ keyLen := end - start
+ valLen := len(fieldBuf)
+
+ if keyLen == valLen {
+ copy(path[start:], fieldBuf)
+ return path, fieldBuf, nil
+ }
+
+ newLen := len(path) + (valLen - keyLen)
+ if len(path) < newLen {
+ path = path[:cap(path)]
+ }
+ if cap(path) < newLen {
+ newURI := make([]byte, newLen)
+ copy(newURI, path)
+ path = newURI
+ }
+
+ // shift
+ copy(path[start+valLen:], path[end:])
+ path = path[:newLen]
+ copy(path[start:], fieldBuf)
+
+ return path, fieldBuf, nil
+}
+
+// EscapePath escapes part of a URL path in Amazon style.
+func EscapePath(path string, encodeSep bool) string {
+ var buf bytes.Buffer
+ for i := 0; i < len(path); i++ {
+ c := path[i]
+ if noEscape[c] || (c == '/' && !encodeSep) {
+ buf.WriteByte(c)
+ } else {
+ fmt.Fprintf(&buf, "%%%02X", c)
+ }
+ }
+ return buf.String()
+}
+
+var noEscape [256]bool
+
+func init() {
+ for i := 0; i < len(noEscape); i++ {
+ // AWS expects every character except these to be escaped
+ noEscape[i] = (i >= 'A' && i <= 'Z') ||
+ (i >= 'a' && i <= 'z') ||
+ (i >= '0' && i <= '9') ||
+ i == '-' ||
+ i == '.' ||
+ i == '_' ||
+ i == '~'
+ }
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/httpbinding/query.go b/vendor/github.com/aws/smithy-go/encoding/httpbinding/query.go
new file mode 100644
index 000000000000..c2e7d0a20f45
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/httpbinding/query.go
@@ -0,0 +1,107 @@
+package httpbinding
+
+import (
+ "encoding/base64"
+ "math"
+ "math/big"
+ "net/url"
+ "strconv"
+)
+
+// QueryValue is used to encode query key values
+type QueryValue struct {
+ query url.Values
+ key string
+ append bool
+}
+
+// NewQueryValue creates a new QueryValue which enables encoding
+// a query value into the given url.Values.
+func NewQueryValue(query url.Values, key string, append bool) QueryValue {
+ return QueryValue{
+ query: query,
+ key: key,
+ append: append,
+ }
+}
+
+func (qv QueryValue) updateKey(value string) {
+ if qv.append {
+ qv.query.Add(qv.key, value)
+ } else {
+ qv.query.Set(qv.key, value)
+ }
+}
+
+// Blob encodes v as a base64 query string value
+func (qv QueryValue) Blob(v []byte) {
+ encodeToString := base64.StdEncoding.EncodeToString(v)
+ qv.updateKey(encodeToString)
+}
+
+// Boolean encodes v as a query string value
+func (qv QueryValue) Boolean(v bool) {
+ qv.updateKey(strconv.FormatBool(v))
+}
+
+// String encodes v as a query string value
+func (qv QueryValue) String(v string) {
+ qv.updateKey(v)
+}
+
+// Byte encodes v as a query string value
+func (qv QueryValue) Byte(v int8) {
+ qv.Long(int64(v))
+}
+
+// Short encodes v as a query string value
+func (qv QueryValue) Short(v int16) {
+ qv.Long(int64(v))
+}
+
+// Integer encodes v as a query string value
+func (qv QueryValue) Integer(v int32) {
+ qv.Long(int64(v))
+}
+
+// Long encodes v as a query string value
+func (qv QueryValue) Long(v int64) {
+ qv.updateKey(strconv.FormatInt(v, 10))
+}
+
+// Float encodes v as a query string value
+func (qv QueryValue) Float(v float32) {
+ qv.float(float64(v), 32)
+}
+
+// Double encodes v as a query string value
+func (qv QueryValue) Double(v float64) {
+ qv.float(v, 64)
+}
+
+func (qv QueryValue) float(v float64, bitSize int) {
+ switch {
+ case math.IsNaN(v):
+ qv.String(floatNaN)
+ case math.IsInf(v, 1):
+ qv.String(floatInfinity)
+ case math.IsInf(v, -1):
+ qv.String(floatNegInfinity)
+ default:
+ qv.updateKey(strconv.FormatFloat(v, 'f', -1, bitSize))
+ }
+}
+
+// BigInteger encodes v as a query string value
+func (qv QueryValue) BigInteger(v *big.Int) {
+ qv.updateKey(v.String())
+}
+
+// BigDecimal encodes v as a query string value
+func (qv QueryValue) BigDecimal(v *big.Float) {
+ if i, accuracy := v.Int64(); accuracy == big.Exact {
+ qv.Long(i)
+ return
+ }
+ qv.updateKey(v.Text('e', -1))
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/httpbinding/uri.go b/vendor/github.com/aws/smithy-go/encoding/httpbinding/uri.go
new file mode 100644
index 000000000000..64e40121e1e8
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/httpbinding/uri.go
@@ -0,0 +1,108 @@
+package httpbinding
+
+import (
+ "math"
+ "math/big"
+ "strconv"
+ "strings"
+)
+
+// URIValue is used to encode named URI parameters
+type URIValue struct {
+ path, rawPath, buffer *[]byte
+
+ key string
+}
+
+func newURIValue(path *[]byte, rawPath *[]byte, buffer *[]byte, key string) URIValue {
+ return URIValue{path: path, rawPath: rawPath, buffer: buffer, key: key}
+}
+
+func (u URIValue) modifyURI(value string) (err error) {
+ *u.path, *u.buffer, err = replacePathElement(*u.path, *u.buffer, u.key, value, false)
+ *u.rawPath, *u.buffer, err = replacePathElement(*u.rawPath, *u.buffer, u.key, value, true)
+ return err
+}
+
+// Boolean encodes v as a URI string value
+func (u URIValue) Boolean(v bool) error {
+ return u.modifyURI(strconv.FormatBool(v))
+}
+
+// String encodes v as a URI string value
+func (u URIValue) String(v string) error {
+ return u.modifyURI(v)
+}
+
+// Byte encodes v as a URI string value
+func (u URIValue) Byte(v int8) error {
+ return u.Long(int64(v))
+}
+
+// Short encodes v as a URI string value
+func (u URIValue) Short(v int16) error {
+ return u.Long(int64(v))
+}
+
+// Integer encodes v as a URI string value
+func (u URIValue) Integer(v int32) error {
+ return u.Long(int64(v))
+}
+
+// Long encodes v as a URI string value
+func (u URIValue) Long(v int64) error {
+ return u.modifyURI(strconv.FormatInt(v, 10))
+}
+
+// Float encodes v as a query string value
+func (u URIValue) Float(v float32) error {
+ return u.float(float64(v), 32)
+}
+
+// Double encodes v as a query string value
+func (u URIValue) Double(v float64) error {
+ return u.float(v, 64)
+}
+
+func (u URIValue) float(v float64, bitSize int) error {
+ switch {
+ case math.IsNaN(v):
+ return u.String(floatNaN)
+ case math.IsInf(v, 1):
+ return u.String(floatInfinity)
+ case math.IsInf(v, -1):
+ return u.String(floatNegInfinity)
+ default:
+ return u.modifyURI(strconv.FormatFloat(v, 'f', -1, bitSize))
+ }
+}
+
+// BigInteger encodes v as a query string value
+func (u URIValue) BigInteger(v *big.Int) error {
+ return u.modifyURI(v.String())
+}
+
+// BigDecimal encodes v as a query string value
+func (u URIValue) BigDecimal(v *big.Float) error {
+ if i, accuracy := v.Int64(); accuracy == big.Exact {
+ return u.Long(i)
+ }
+ return u.modifyURI(v.Text('e', -1))
+}
+
+// SplitURI parses a Smithy HTTP binding trait URI
+func SplitURI(uri string) (path, query string) {
+ queryStart := strings.IndexRune(uri, '?')
+ if queryStart == -1 {
+ path = uri
+ return path, query
+ }
+
+ path = uri[:queryStart]
+ if queryStart+1 >= len(uri) {
+ return path, query
+ }
+ query = uri[queryStart+1:]
+
+ return path, query
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/json/array.go b/vendor/github.com/aws/smithy-go/encoding/json/array.go
new file mode 100644
index 000000000000..7a232f660f19
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/json/array.go
@@ -0,0 +1,35 @@
+package json
+
+import (
+ "bytes"
+)
+
+// Array represents the encoding of a JSON Array
+type Array struct {
+ w *bytes.Buffer
+ writeComma bool
+ scratch *[]byte
+}
+
+func newArray(w *bytes.Buffer, scratch *[]byte) *Array {
+ w.WriteRune(leftBracket)
+ return &Array{w: w, scratch: scratch}
+}
+
+// Value adds a new element to the JSON Array.
+// Returns a Value type that is used to encode
+// the array element.
+func (a *Array) Value() Value {
+ if a.writeComma {
+ a.w.WriteRune(comma)
+ } else {
+ a.writeComma = true
+ }
+
+ return newValue(a.w, a.scratch)
+}
+
+// Close encodes the end of the JSON Array
+func (a *Array) Close() {
+ a.w.WriteRune(rightBracket)
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/json/constants.go b/vendor/github.com/aws/smithy-go/encoding/json/constants.go
new file mode 100644
index 000000000000..91044092aef6
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/json/constants.go
@@ -0,0 +1,15 @@
+package json
+
+const (
+ leftBrace = '{'
+ rightBrace = '}'
+
+ leftBracket = '['
+ rightBracket = ']'
+
+ comma = ','
+ quote = '"'
+ colon = ':'
+
+ null = "null"
+)
diff --git a/vendor/github.com/aws/smithy-go/encoding/json/decoder_util.go b/vendor/github.com/aws/smithy-go/encoding/json/decoder_util.go
new file mode 100644
index 000000000000..7050c85b3c61
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/json/decoder_util.go
@@ -0,0 +1,139 @@
+package json
+
+import (
+ "bytes"
+ "encoding/json"
+ "fmt"
+ "io"
+)
+
+// DiscardUnknownField discards unknown fields from a decoder body.
+// This function is useful while deserializing a JSON body with additional
+// unknown information that should be discarded.
+func DiscardUnknownField(decoder *json.Decoder) error {
+ // This deliberately does not share logic with CollectUnknownField, even
+ // though it could, because if we were to delegate to that then we'd incur
+ // extra allocations and general memory usage.
+ v, err := decoder.Token()
+ if err == io.EOF {
+ return nil
+ }
+ if err != nil {
+ return err
+ }
+
+ if _, ok := v.(json.Delim); ok {
+ for decoder.More() {
+ err = DiscardUnknownField(decoder)
+ }
+ endToken, err := decoder.Token()
+ if err != nil {
+ return err
+ }
+ if _, ok := endToken.(json.Delim); !ok {
+ return fmt.Errorf("invalid JSON : expected json delimiter, found %T %v",
+ endToken, endToken)
+ }
+ }
+
+ return nil
+}
+
+// CollectUnknownField grabs the contents of unknown fields from the decoder body
+// and returns them as a byte slice. This is useful for skipping unknown fields without
+// completely discarding them.
+func CollectUnknownField(decoder *json.Decoder) ([]byte, error) {
+ result, err := collectUnknownField(decoder)
+ if err != nil {
+ return nil, err
+ }
+
+ buff := bytes.NewBuffer(nil)
+ encoder := json.NewEncoder(buff)
+
+ if err := encoder.Encode(result); err != nil {
+ return nil, err
+ }
+
+ return buff.Bytes(), nil
+}
+
+func collectUnknownField(decoder *json.Decoder) (interface{}, error) {
+ // Grab the initial value. This could either be a concrete value like a string or a a
+ // delimiter.
+ token, err := decoder.Token()
+ if err == io.EOF {
+ return nil, nil
+ }
+ if err != nil {
+ return nil, err
+ }
+
+ // If it's an array or object, we'll need to recurse.
+ delim, ok := token.(json.Delim)
+ if ok {
+ var result interface{}
+ if delim == '{' {
+ result, err = collectUnknownObject(decoder)
+ if err != nil {
+ return nil, err
+ }
+ } else {
+ result, err = collectUnknownArray(decoder)
+ if err != nil {
+ return nil, err
+ }
+ }
+
+ // Discard the closing token. decoder.Token handles checking for matching delimiters
+ if _, err := decoder.Token(); err != nil {
+ return nil, err
+ }
+ return result, nil
+ }
+
+ return token, nil
+}
+
+func collectUnknownArray(decoder *json.Decoder) ([]interface{}, error) {
+ // We need to create an empty array here instead of a nil array, since by getting
+ // into this function at all we necessarily have seen a non-nil list.
+ array := []interface{}{}
+
+ for decoder.More() {
+ value, err := collectUnknownField(decoder)
+ if err != nil {
+ return nil, err
+ }
+ array = append(array, value)
+ }
+
+ return array, nil
+}
+
+func collectUnknownObject(decoder *json.Decoder) (map[string]interface{}, error) {
+ object := make(map[string]interface{})
+
+ for decoder.More() {
+ key, err := collectUnknownField(decoder)
+ if err != nil {
+ return nil, err
+ }
+
+ // Keys have to be strings, which is particularly important as the encoder
+ // won't except a map with interface{} keys
+ stringKey, ok := key.(string)
+ if !ok {
+ return nil, fmt.Errorf("expected string key, found %T", key)
+ }
+
+ value, err := collectUnknownField(decoder)
+ if err != nil {
+ return nil, err
+ }
+
+ object[stringKey] = value
+ }
+
+ return object, nil
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/json/encoder.go b/vendor/github.com/aws/smithy-go/encoding/json/encoder.go
new file mode 100644
index 000000000000..8772953f1e6f
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/json/encoder.go
@@ -0,0 +1,30 @@
+package json
+
+import (
+ "bytes"
+)
+
+// Encoder is JSON encoder that supports construction of JSON values
+// using methods.
+type Encoder struct {
+ w *bytes.Buffer
+ Value
+}
+
+// NewEncoder returns a new JSON encoder
+func NewEncoder() *Encoder {
+ writer := bytes.NewBuffer(nil)
+ scratch := make([]byte, 64)
+
+ return &Encoder{w: writer, Value: newValue(writer, &scratch)}
+}
+
+// String returns the String output of the JSON encoder
+func (e Encoder) String() string {
+ return e.w.String()
+}
+
+// Bytes returns the []byte slice of the JSON encoder
+func (e Encoder) Bytes() []byte {
+ return e.w.Bytes()
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/json/escape.go b/vendor/github.com/aws/smithy-go/encoding/json/escape.go
new file mode 100644
index 000000000000..d984d0cdca12
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/json/escape.go
@@ -0,0 +1,198 @@
+// Copyright 2016 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Copied and modified from Go 1.8 stdlib's encoding/json/#safeSet
+
+package json
+
+import (
+ "bytes"
+ "unicode/utf8"
+)
+
+// safeSet holds the value true if the ASCII character with the given array
+// position can be represented inside a JSON string without any further
+// escaping.
+//
+// All values are true except for the ASCII control characters (0-31), the
+// double quote ("), and the backslash character ("\").
+var safeSet = [utf8.RuneSelf]bool{
+ ' ': true,
+ '!': true,
+ '"': false,
+ '#': true,
+ '$': true,
+ '%': true,
+ '&': true,
+ '\'': true,
+ '(': true,
+ ')': true,
+ '*': true,
+ '+': true,
+ ',': true,
+ '-': true,
+ '.': true,
+ '/': true,
+ '0': true,
+ '1': true,
+ '2': true,
+ '3': true,
+ '4': true,
+ '5': true,
+ '6': true,
+ '7': true,
+ '8': true,
+ '9': true,
+ ':': true,
+ ';': true,
+ '<': true,
+ '=': true,
+ '>': true,
+ '?': true,
+ '@': true,
+ 'A': true,
+ 'B': true,
+ 'C': true,
+ 'D': true,
+ 'E': true,
+ 'F': true,
+ 'G': true,
+ 'H': true,
+ 'I': true,
+ 'J': true,
+ 'K': true,
+ 'L': true,
+ 'M': true,
+ 'N': true,
+ 'O': true,
+ 'P': true,
+ 'Q': true,
+ 'R': true,
+ 'S': true,
+ 'T': true,
+ 'U': true,
+ 'V': true,
+ 'W': true,
+ 'X': true,
+ 'Y': true,
+ 'Z': true,
+ '[': true,
+ '\\': false,
+ ']': true,
+ '^': true,
+ '_': true,
+ '`': true,
+ 'a': true,
+ 'b': true,
+ 'c': true,
+ 'd': true,
+ 'e': true,
+ 'f': true,
+ 'g': true,
+ 'h': true,
+ 'i': true,
+ 'j': true,
+ 'k': true,
+ 'l': true,
+ 'm': true,
+ 'n': true,
+ 'o': true,
+ 'p': true,
+ 'q': true,
+ 'r': true,
+ 's': true,
+ 't': true,
+ 'u': true,
+ 'v': true,
+ 'w': true,
+ 'x': true,
+ 'y': true,
+ 'z': true,
+ '{': true,
+ '|': true,
+ '}': true,
+ '~': true,
+ '\u007f': true,
+}
+
+// copied from Go 1.8 stdlib's encoding/json/#hex
+var hex = "0123456789abcdef"
+
+// escapeStringBytes escapes and writes the passed in string bytes to the dst
+// buffer
+//
+// Copied and modifed from Go 1.8 stdlib's encodeing/json/#encodeState.stringBytes
+func escapeStringBytes(e *bytes.Buffer, s []byte) {
+ e.WriteByte('"')
+ start := 0
+ for i := 0; i < len(s); {
+ if b := s[i]; b < utf8.RuneSelf {
+ if safeSet[b] {
+ i++
+ continue
+ }
+ if start < i {
+ e.Write(s[start:i])
+ }
+ switch b {
+ case '\\', '"':
+ e.WriteByte('\\')
+ e.WriteByte(b)
+ case '\n':
+ e.WriteByte('\\')
+ e.WriteByte('n')
+ case '\r':
+ e.WriteByte('\\')
+ e.WriteByte('r')
+ case '\t':
+ e.WriteByte('\\')
+ e.WriteByte('t')
+ default:
+ // This encodes bytes < 0x20 except for \t, \n and \r.
+ // If escapeHTML is set, it also escapes <, >, and &
+ // because they can lead to security holes when
+ // user-controlled strings are rendered into JSON
+ // and served to some browsers.
+ e.WriteString(`\u00`)
+ e.WriteByte(hex[b>>4])
+ e.WriteByte(hex[b&0xF])
+ }
+ i++
+ start = i
+ continue
+ }
+ c, size := utf8.DecodeRune(s[i:])
+ if c == utf8.RuneError && size == 1 {
+ if start < i {
+ e.Write(s[start:i])
+ }
+ e.WriteString(`\ufffd`)
+ i += size
+ start = i
+ continue
+ }
+ // U+2028 is LINE SEPARATOR.
+ // U+2029 is PARAGRAPH SEPARATOR.
+ // They are both technically valid characters in JSON strings,
+ // but don't work in JSONP, which has to be evaluated as JavaScript,
+ // and can lead to security holes there. It is valid JSON to
+ // escape them, so we do so unconditionally.
+ // See http://timelessrepo.com/json-isnt-a-javascript-subset for discussion.
+ if c == '\u2028' || c == '\u2029' {
+ if start < i {
+ e.Write(s[start:i])
+ }
+ e.WriteString(`\u202`)
+ e.WriteByte(hex[c&0xF])
+ i += size
+ start = i
+ continue
+ }
+ i += size
+ }
+ if start < len(s) {
+ e.Write(s[start:])
+ }
+ e.WriteByte('"')
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/json/object.go b/vendor/github.com/aws/smithy-go/encoding/json/object.go
new file mode 100644
index 000000000000..15fb6478ce41
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/json/object.go
@@ -0,0 +1,42 @@
+package json
+
+import (
+ "bytes"
+)
+
+// Object represents the encoding of a JSON Object type
+type Object struct {
+ w *bytes.Buffer
+ writeComma bool
+ scratch *[]byte
+}
+
+func newObject(w *bytes.Buffer, scratch *[]byte) *Object {
+ w.WriteRune(leftBrace)
+ return &Object{w: w, scratch: scratch}
+}
+
+func (o *Object) writeKey(key string) {
+ o.w.WriteRune(quote)
+ o.w.Write([]byte(key))
+ o.w.WriteRune(quote)
+ o.w.WriteRune(colon)
+}
+
+// Key adds the given named key to the JSON object.
+// Returns a Value encoder that should be used to encode
+// a JSON value type.
+func (o *Object) Key(name string) Value {
+ if o.writeComma {
+ o.w.WriteRune(comma)
+ } else {
+ o.writeComma = true
+ }
+ o.writeKey(name)
+ return newValue(o.w, o.scratch)
+}
+
+// Close encodes the end of the JSON Object
+func (o *Object) Close() {
+ o.w.WriteRune(rightBrace)
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/json/value.go b/vendor/github.com/aws/smithy-go/encoding/json/value.go
new file mode 100644
index 000000000000..b41ff1e15c2c
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/json/value.go
@@ -0,0 +1,149 @@
+package json
+
+import (
+ "bytes"
+ "encoding/base64"
+ "math/big"
+ "strconv"
+
+ "github.com/aws/smithy-go/encoding"
+)
+
+// Value represents a JSON Value type
+// JSON Value types: Object, Array, String, Number, Boolean, and Null
+type Value struct {
+ w *bytes.Buffer
+ scratch *[]byte
+}
+
+// newValue returns a new Value encoder
+func newValue(w *bytes.Buffer, scratch *[]byte) Value {
+ return Value{w: w, scratch: scratch}
+}
+
+// String encodes v as a JSON string
+func (jv Value) String(v string) {
+ escapeStringBytes(jv.w, []byte(v))
+}
+
+// Byte encodes v as a JSON number
+func (jv Value) Byte(v int8) {
+ jv.Long(int64(v))
+}
+
+// Short encodes v as a JSON number
+func (jv Value) Short(v int16) {
+ jv.Long(int64(v))
+}
+
+// Integer encodes v as a JSON number
+func (jv Value) Integer(v int32) {
+ jv.Long(int64(v))
+}
+
+// Long encodes v as a JSON number
+func (jv Value) Long(v int64) {
+ *jv.scratch = strconv.AppendInt((*jv.scratch)[:0], v, 10)
+ jv.w.Write(*jv.scratch)
+}
+
+// ULong encodes v as a JSON number
+func (jv Value) ULong(v uint64) {
+ *jv.scratch = strconv.AppendUint((*jv.scratch)[:0], v, 10)
+ jv.w.Write(*jv.scratch)
+}
+
+// Float encodes v as a JSON number
+func (jv Value) Float(v float32) {
+ jv.float(float64(v), 32)
+}
+
+// Double encodes v as a JSON number
+func (jv Value) Double(v float64) {
+ jv.float(v, 64)
+}
+
+func (jv Value) float(v float64, bits int) {
+ *jv.scratch = encoding.EncodeFloat((*jv.scratch)[:0], v, bits)
+ jv.w.Write(*jv.scratch)
+}
+
+// Boolean encodes v as a JSON boolean
+func (jv Value) Boolean(v bool) {
+ *jv.scratch = strconv.AppendBool((*jv.scratch)[:0], v)
+ jv.w.Write(*jv.scratch)
+}
+
+// Base64EncodeBytes writes v as a base64 value in JSON string
+func (jv Value) Base64EncodeBytes(v []byte) {
+ encodeByteSlice(jv.w, (*jv.scratch)[:0], v)
+}
+
+// Write writes v directly to the JSON document
+func (jv Value) Write(v []byte) {
+ jv.w.Write(v)
+}
+
+// Array returns a new Array encoder
+func (jv Value) Array() *Array {
+ return newArray(jv.w, jv.scratch)
+}
+
+// Object returns a new Object encoder
+func (jv Value) Object() *Object {
+ return newObject(jv.w, jv.scratch)
+}
+
+// Null encodes a null JSON value
+func (jv Value) Null() {
+ jv.w.WriteString(null)
+}
+
+// BigInteger encodes v as JSON value
+func (jv Value) BigInteger(v *big.Int) {
+ jv.w.Write([]byte(v.Text(10)))
+}
+
+// BigDecimal encodes v as JSON value
+func (jv Value) BigDecimal(v *big.Float) {
+ if i, accuracy := v.Int64(); accuracy == big.Exact {
+ jv.Long(i)
+ return
+ }
+ // TODO: Should this try to match ES6 ToString similar to stdlib JSON?
+ jv.w.Write([]byte(v.Text('e', -1)))
+}
+
+// Based on encoding/json encodeByteSlice from the Go Standard Library
+// https://golang.org/src/encoding/json/encode.go
+func encodeByteSlice(w *bytes.Buffer, scratch []byte, v []byte) {
+ if v == nil {
+ w.WriteString(null)
+ return
+ }
+
+ w.WriteRune(quote)
+
+ encodedLen := base64.StdEncoding.EncodedLen(len(v))
+ if encodedLen <= len(scratch) {
+ // If the encoded bytes fit in e.scratch, avoid an extra
+ // allocation and use the cheaper Encoding.Encode.
+ dst := scratch[:encodedLen]
+ base64.StdEncoding.Encode(dst, v)
+ w.Write(dst)
+ } else if encodedLen <= 1024 {
+ // The encoded bytes are short enough to allocate for, and
+ // Encoding.Encode is still cheaper.
+ dst := make([]byte, encodedLen)
+ base64.StdEncoding.Encode(dst, v)
+ w.Write(dst)
+ } else {
+ // The encoded bytes are too long to cheaply allocate, and
+ // Encoding.Encode is no longer noticeably cheaper.
+ enc := base64.NewEncoder(base64.StdEncoding, w)
+ enc.Write(v)
+ enc.Close()
+ }
+
+ w.WriteRune(quote)
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/array.go b/vendor/github.com/aws/smithy-go/encoding/xml/array.go
new file mode 100644
index 000000000000..508f3c997ec5
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/array.go
@@ -0,0 +1,49 @@
+package xml
+
+// arrayMemberWrapper is the default member wrapper tag name for XML Array type
+var arrayMemberWrapper = StartElement{
+ Name: Name{Local: "member"},
+}
+
+// Array represents the encoding of a XML array type
+type Array struct {
+ w writer
+ scratch *[]byte
+
+ // member start element is the array member wrapper start element
+ memberStartElement StartElement
+
+ // isFlattened indicates if the array is a flattened array.
+ isFlattened bool
+}
+
+// newArray returns an array encoder.
+// It also takes in the member start element, array start element.
+// It takes in a isFlattened bool, indicating that an array is flattened array.
+//
+// A wrapped array ["value1", "value2"] is represented as
+// `value1value2 `.
+
+// A flattened array `someList: ["value1", "value2"]` is represented as
+// `value1value2`.
+func newArray(w writer, scratch *[]byte, memberStartElement StartElement, arrayStartElement StartElement, isFlattened bool) *Array {
+ var memberWrapper = memberStartElement
+ if isFlattened {
+ memberWrapper = arrayStartElement
+ }
+
+ return &Array{
+ w: w,
+ scratch: scratch,
+ memberStartElement: memberWrapper,
+ isFlattened: isFlattened,
+ }
+}
+
+// Member adds a new member to the XML array.
+// It returns a Value encoder.
+func (a *Array) Member() Value {
+ v := newValue(a.w, a.scratch, a.memberStartElement)
+ v.isFlattened = a.isFlattened
+ return v
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/constants.go b/vendor/github.com/aws/smithy-go/encoding/xml/constants.go
new file mode 100644
index 000000000000..ccee90a636bb
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/constants.go
@@ -0,0 +1,10 @@
+package xml
+
+const (
+ leftAngleBracket = '<'
+ rightAngleBracket = '>'
+ forwardSlash = '/'
+ colon = ':'
+ equals = '='
+ quote = '"'
+)
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/doc.go b/vendor/github.com/aws/smithy-go/encoding/xml/doc.go
new file mode 100644
index 000000000000..d6e1e41e164d
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/doc.go
@@ -0,0 +1,49 @@
+/*
+Package xml holds the XMl encoder utility. This utility is written in accordance to our design to delegate to
+shape serializer function in which a xml.Value will be passed around.
+
+Resources followed: https://awslabs.github.io/smithy/1.0/spec/core/xml-traits.html#
+
+Member Element
+
+Member element should be used to encode xml shapes into xml elements except for flattened xml shapes. Member element
+write their own element start tag. These elements should always be closed.
+
+Flattened Element
+
+Flattened element should be used to encode shapes marked with flattened trait into xml elements. Flattened element
+do not write a start tag, and thus should not be closed.
+
+Simple types encoding
+
+All simple type methods on value such as String(), Long() etc; auto close the associated member element.
+
+Array
+
+Array returns the collection encoder. It has two modes, wrapped and flattened encoding.
+
+Wrapped arrays have two methods Array() and ArrayWithCustomName() which facilitate array member wrapping.
+By default, a wrapped array members are wrapped with `member` named start element.
+
+ appletree
+
+Flattened arrays rely on Value being marked as flattened.
+If a shape is marked as flattened, Array() will use the shape element name as wrapper for array elements.
+
+ appletree
+
+Map
+
+Map is the map encoder. It has two modes, wrapped and flattened encoding.
+
+Wrapped map has Array() method, which facilitate map member wrapping.
+By default, a wrapped map members are wrapped with `entry` named start element.
+
+ appletreesnowice
+
+Flattened map rely on Value being marked as flattened.
+If a shape is marked as flattened, Map() will use the shape element name as wrapper for map entry elements.
+
+ appletreesnowice
+*/
+package xml
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/element.go b/vendor/github.com/aws/smithy-go/encoding/xml/element.go
new file mode 100644
index 000000000000..ae84e7999edb
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/element.go
@@ -0,0 +1,91 @@
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Copied and modified from Go 1.14 stdlib's encoding/xml
+
+package xml
+
+// A Name represents an XML name (Local) annotated
+// with a name space identifier (Space).
+// In tokens returned by Decoder.Token, the Space identifier
+// is given as a canonical URL, not the short prefix used
+// in the document being parsed.
+type Name struct {
+ Space, Local string
+}
+
+// An Attr represents an attribute in an XML element (Name=Value).
+type Attr struct {
+ Name Name
+ Value string
+}
+
+/*
+NewAttribute returns a pointer to an attribute.
+It takes in a local name aka attribute name, and value
+representing the attribute value.
+*/
+func NewAttribute(local, value string) Attr {
+ return Attr{
+ Name: Name{
+ Local: local,
+ },
+ Value: value,
+ }
+}
+
+/*
+NewNamespaceAttribute returns a pointer to an attribute.
+It takes in a local name aka attribute name, and value
+representing the attribute value.
+
+NewNamespaceAttribute appends `xmlns:` in front of namespace
+prefix.
+
+For creating a name space attribute representing
+`xmlns:prefix="http://example.com`, the breakdown would be:
+local = "prefix"
+value = "http://example.com"
+*/
+func NewNamespaceAttribute(local, value string) Attr {
+ attr := NewAttribute(local, value)
+
+ // default name space identifier
+ attr.Name.Space = "xmlns"
+ return attr
+}
+
+// A StartElement represents an XML start element.
+type StartElement struct {
+ Name Name
+ Attr []Attr
+}
+
+// Copy creates a new copy of StartElement.
+func (e StartElement) Copy() StartElement {
+ attrs := make([]Attr, len(e.Attr))
+ copy(attrs, e.Attr)
+ e.Attr = attrs
+ return e
+}
+
+// End returns the corresponding XML end element.
+func (e StartElement) End() EndElement {
+ return EndElement{e.Name}
+}
+
+// returns true if start element local name is empty
+func (e StartElement) isZero() bool {
+ return len(e.Name.Local) == 0
+}
+
+// An EndElement represents an XML end element.
+type EndElement struct {
+ Name Name
+}
+
+// returns true if end element local name is empty
+func (e EndElement) isZero() bool {
+ return len(e.Name.Local) == 0
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/encoder.go b/vendor/github.com/aws/smithy-go/encoding/xml/encoder.go
new file mode 100644
index 000000000000..16fb3dddb0a8
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/encoder.go
@@ -0,0 +1,51 @@
+package xml
+
+// writer interface used by the xml encoder to write an encoded xml
+// document in a writer.
+type writer interface {
+
+ // Write takes in a byte slice and returns number of bytes written and error
+ Write(p []byte) (n int, err error)
+
+ // WriteRune takes in a rune and returns number of bytes written and error
+ WriteRune(r rune) (n int, err error)
+
+ // WriteString takes in a string and returns number of bytes written and error
+ WriteString(s string) (n int, err error)
+
+ // String method returns a string
+ String() string
+
+ // Bytes return a byte slice.
+ Bytes() []byte
+}
+
+// Encoder is an XML encoder that supports construction of XML values
+// using methods. The encoder takes in a writer and maintains a scratch buffer.
+type Encoder struct {
+ w writer
+ scratch *[]byte
+}
+
+// NewEncoder returns an XML encoder
+func NewEncoder(w writer) *Encoder {
+ scratch := make([]byte, 64)
+
+ return &Encoder{w: w, scratch: &scratch}
+}
+
+// String returns the string output of the XML encoder
+func (e Encoder) String() string {
+ return e.w.String()
+}
+
+// Bytes returns the []byte slice of the XML encoder
+func (e Encoder) Bytes() []byte {
+ return e.w.Bytes()
+}
+
+// RootElement builds a root element encoding
+// It writes it's start element tag. The value should be closed.
+func (e Encoder) RootElement(element StartElement) Value {
+ return newValue(e.w, e.scratch, element)
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/error_utils.go b/vendor/github.com/aws/smithy-go/encoding/xml/error_utils.go
new file mode 100644
index 000000000000..f3db6ccca85c
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/error_utils.go
@@ -0,0 +1,51 @@
+package xml
+
+import (
+ "encoding/xml"
+ "fmt"
+ "io"
+)
+
+// ErrorComponents represents the error response fields
+// that will be deserialized from an xml error response body
+type ErrorComponents struct {
+ Code string
+ Message string
+}
+
+// GetErrorResponseComponents returns the error fields from an xml error response body
+func GetErrorResponseComponents(r io.Reader, noErrorWrapping bool) (ErrorComponents, error) {
+ if noErrorWrapping {
+ var errResponse noWrappedErrorResponse
+ if err := xml.NewDecoder(r).Decode(&errResponse); err != nil && err != io.EOF {
+ return ErrorComponents{}, fmt.Errorf("error while deserializing xml error response: %w", err)
+ }
+ return ErrorComponents{
+ Code: errResponse.Code,
+ Message: errResponse.Message,
+ }, nil
+ }
+
+ var errResponse wrappedErrorResponse
+ if err := xml.NewDecoder(r).Decode(&errResponse); err != nil && err != io.EOF {
+ return ErrorComponents{}, fmt.Errorf("error while deserializing xml error response: %w", err)
+ }
+ return ErrorComponents{
+ Code: errResponse.Code,
+ Message: errResponse.Message,
+ }, nil
+}
+
+// noWrappedErrorResponse represents the error response body with
+// no internal ...
+type wrappedErrorResponse struct {
+ Code string `xml:"Error>Code"`
+ Message string `xml:"Error>Message"`
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/escape.go b/vendor/github.com/aws/smithy-go/encoding/xml/escape.go
new file mode 100644
index 000000000000..1c5479af677d
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/escape.go
@@ -0,0 +1,137 @@
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Copied and modified from Go 1.14 stdlib's encoding/xml
+
+package xml
+
+import (
+ "unicode/utf8"
+)
+
+// Copied from Go 1.14 stdlib's encoding/xml
+var (
+ escQuot = []byte(""") // shorter than """
+ escApos = []byte("'") // shorter than "'"
+ escAmp = []byte("&")
+ escLT = []byte("<")
+ escGT = []byte(">")
+ escTab = []byte(" ")
+ escNL = []byte("
")
+ escCR = []byte("
")
+ escFFFD = []byte("\uFFFD") // Unicode replacement character
+
+ // Additional Escapes
+ escNextLine = []byte("
")
+ escLS = []byte("
")
+)
+
+// Decide whether the given rune is in the XML Character Range, per
+// the Char production of https://www.xml.com/axml/testaxml.htm,
+// Section 2.2 Characters.
+func isInCharacterRange(r rune) (inrange bool) {
+ return r == 0x09 ||
+ r == 0x0A ||
+ r == 0x0D ||
+ r >= 0x20 && r <= 0xD7FF ||
+ r >= 0xE000 && r <= 0xFFFD ||
+ r >= 0x10000 && r <= 0x10FFFF
+}
+
+// TODO: When do we need to escape the string?
+// Based on encoding/xml escapeString from the Go Standard Library.
+// https://golang.org/src/encoding/xml/xml.go
+func escapeString(e writer, s string) {
+ var esc []byte
+ last := 0
+ for i := 0; i < len(s); {
+ r, width := utf8.DecodeRuneInString(s[i:])
+ i += width
+ switch r {
+ case '"':
+ esc = escQuot
+ case '\'':
+ esc = escApos
+ case '&':
+ esc = escAmp
+ case '<':
+ esc = escLT
+ case '>':
+ esc = escGT
+ case '\t':
+ esc = escTab
+ case '\n':
+ esc = escNL
+ case '\r':
+ esc = escCR
+ case '\u0085':
+ // Not escaped by stdlib
+ esc = escNextLine
+ case '\u2028':
+ // Not escaped by stdlib
+ esc = escLS
+ default:
+ if !isInCharacterRange(r) || (r == 0xFFFD && width == 1) {
+ esc = escFFFD
+ break
+ }
+ continue
+ }
+ e.WriteString(s[last : i-width])
+ e.Write(esc)
+ last = i
+ }
+ e.WriteString(s[last:])
+}
+
+// escapeText writes to w the properly escaped XML equivalent
+// of the plain text data s. If escapeNewline is true, newline
+// characters will be escaped.
+//
+// Based on encoding/xml escapeText from the Go Standard Library.
+// https://golang.org/src/encoding/xml/xml.go
+func escapeText(e writer, s []byte) {
+ var esc []byte
+ last := 0
+ for i := 0; i < len(s); {
+ r, width := utf8.DecodeRune(s[i:])
+ i += width
+ switch r {
+ case '"':
+ esc = escQuot
+ case '\'':
+ esc = escApos
+ case '&':
+ esc = escAmp
+ case '<':
+ esc = escLT
+ case '>':
+ esc = escGT
+ case '\t':
+ esc = escTab
+ case '\n':
+ // This always escapes newline, which is different than stdlib's optional
+ // escape of new line.
+ esc = escNL
+ case '\r':
+ esc = escCR
+ case '\u0085':
+ // Not escaped by stdlib
+ esc = escNextLine
+ case '\u2028':
+ // Not escaped by stdlib
+ esc = escLS
+ default:
+ if !isInCharacterRange(r) || (r == 0xFFFD && width == 1) {
+ esc = escFFFD
+ break
+ }
+ continue
+ }
+ e.Write(s[last : i-width])
+ e.Write(esc)
+ last = i
+ }
+ e.Write(s[last:])
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/map.go b/vendor/github.com/aws/smithy-go/encoding/xml/map.go
new file mode 100644
index 000000000000..e42858965ccc
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/map.go
@@ -0,0 +1,53 @@
+package xml
+
+// mapEntryWrapper is the default member wrapper start element for XML Map entry
+var mapEntryWrapper = StartElement{
+ Name: Name{Local: "entry"},
+}
+
+// Map represents the encoding of a XML map type
+type Map struct {
+ w writer
+ scratch *[]byte
+
+ // member start element is the map entry wrapper start element
+ memberStartElement StartElement
+
+ // isFlattened returns true if the map is a flattened map
+ isFlattened bool
+}
+
+// newMap returns a map encoder which sets the default map
+// entry wrapper to `entry`.
+//
+// A map `someMap : {{key:"abc", value:"123"}}` is represented as
+// `abc123`.
+func newMap(w writer, scratch *[]byte) *Map {
+ return &Map{
+ w: w,
+ scratch: scratch,
+ memberStartElement: mapEntryWrapper,
+ }
+}
+
+// newFlattenedMap returns a map encoder which sets the map
+// entry wrapper to the passed in memberWrapper`.
+//
+// A flattened map `someMap : {{key:"abc", value:"123"}}` is represented as
+// `abc123`.
+func newFlattenedMap(w writer, scratch *[]byte, memberWrapper StartElement) *Map {
+ return &Map{
+ w: w,
+ scratch: scratch,
+ memberStartElement: memberWrapper,
+ isFlattened: true,
+ }
+}
+
+// Entry returns a Value encoder with map's element.
+// It writes the member wrapper start tag for each entry.
+func (m *Map) Entry() Value {
+ v := newValue(m.w, m.scratch, m.memberStartElement)
+ v.isFlattened = m.isFlattened
+ return v
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/value.go b/vendor/github.com/aws/smithy-go/encoding/xml/value.go
new file mode 100644
index 000000000000..09434b2c0b55
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/value.go
@@ -0,0 +1,302 @@
+package xml
+
+import (
+ "encoding/base64"
+ "fmt"
+ "math/big"
+ "strconv"
+
+ "github.com/aws/smithy-go/encoding"
+)
+
+// Value represents an XML Value type
+// XML Value types: Object, Array, Map, String, Number, Boolean.
+type Value struct {
+ w writer
+ scratch *[]byte
+
+ // xml start element is the associated start element for the Value
+ startElement StartElement
+
+ // indicates if the Value represents a flattened shape
+ isFlattened bool
+}
+
+// newFlattenedValue returns a Value encoder. newFlattenedValue does NOT write the start element tag
+func newFlattenedValue(w writer, scratch *[]byte, startElement StartElement) Value {
+ return Value{
+ w: w,
+ scratch: scratch,
+ startElement: startElement,
+ }
+}
+
+// newValue writes the start element xml tag and returns a Value
+func newValue(w writer, scratch *[]byte, startElement StartElement) Value {
+ writeStartElement(w, startElement)
+ return Value{w: w, scratch: scratch, startElement: startElement}
+}
+
+// writeStartElement takes in a start element and writes it.
+// It handles namespace, attributes in start element.
+func writeStartElement(w writer, el StartElement) error {
+ if el.isZero() {
+ return fmt.Errorf("xml start element cannot be nil")
+ }
+
+ w.WriteRune(leftAngleBracket)
+
+ if len(el.Name.Space) != 0 {
+ escapeString(w, el.Name.Space)
+ w.WriteRune(colon)
+ }
+ escapeString(w, el.Name.Local)
+ for _, attr := range el.Attr {
+ w.WriteRune(' ')
+ writeAttribute(w, &attr)
+ }
+
+ w.WriteRune(rightAngleBracket)
+ return nil
+}
+
+// writeAttribute writes an attribute from a provided Attribute
+// For a namespace attribute, the attr.Name.Space must be defined as "xmlns".
+// https://www.w3.org/TR/REC-xml-names/#NT-DefaultAttName
+func writeAttribute(w writer, attr *Attr) {
+ // if local, space both are not empty
+ if len(attr.Name.Space) != 0 && len(attr.Name.Local) != 0 {
+ escapeString(w, attr.Name.Space)
+ w.WriteRune(colon)
+ }
+
+ // if prefix is empty, the default `xmlns` space should be used as prefix.
+ if len(attr.Name.Local) == 0 {
+ attr.Name.Local = attr.Name.Space
+ }
+
+ escapeString(w, attr.Name.Local)
+ w.WriteRune(equals)
+ w.WriteRune(quote)
+ escapeString(w, attr.Value)
+ w.WriteRune(quote)
+}
+
+// writeEndElement takes in a end element and writes it.
+func writeEndElement(w writer, el EndElement) error {
+ if el.isZero() {
+ return fmt.Errorf("xml end element cannot be nil")
+ }
+
+ w.WriteRune(leftAngleBracket)
+ w.WriteRune(forwardSlash)
+
+ if len(el.Name.Space) != 0 {
+ escapeString(w, el.Name.Space)
+ w.WriteRune(colon)
+ }
+ escapeString(w, el.Name.Local)
+ w.WriteRune(rightAngleBracket)
+
+ return nil
+}
+
+// String encodes v as a XML string.
+// It will auto close the parent xml element tag.
+func (xv Value) String(v string) {
+ escapeString(xv.w, v)
+ xv.Close()
+}
+
+// Byte encodes v as a XML number.
+// It will auto close the parent xml element tag.
+func (xv Value) Byte(v int8) {
+ xv.Long(int64(v))
+}
+
+// Short encodes v as a XML number.
+// It will auto close the parent xml element tag.
+func (xv Value) Short(v int16) {
+ xv.Long(int64(v))
+}
+
+// Integer encodes v as a XML number.
+// It will auto close the parent xml element tag.
+func (xv Value) Integer(v int32) {
+ xv.Long(int64(v))
+}
+
+// Long encodes v as a XML number.
+// It will auto close the parent xml element tag.
+func (xv Value) Long(v int64) {
+ *xv.scratch = strconv.AppendInt((*xv.scratch)[:0], v, 10)
+ xv.w.Write(*xv.scratch)
+
+ xv.Close()
+}
+
+// Float encodes v as a XML number.
+// It will auto close the parent xml element tag.
+func (xv Value) Float(v float32) {
+ xv.float(float64(v), 32)
+ xv.Close()
+}
+
+// Double encodes v as a XML number.
+// It will auto close the parent xml element tag.
+func (xv Value) Double(v float64) {
+ xv.float(v, 64)
+ xv.Close()
+}
+
+func (xv Value) float(v float64, bits int) {
+ *xv.scratch = encoding.EncodeFloat((*xv.scratch)[:0], v, bits)
+ xv.w.Write(*xv.scratch)
+}
+
+// Boolean encodes v as a XML boolean.
+// It will auto close the parent xml element tag.
+func (xv Value) Boolean(v bool) {
+ *xv.scratch = strconv.AppendBool((*xv.scratch)[:0], v)
+ xv.w.Write(*xv.scratch)
+
+ xv.Close()
+}
+
+// Base64EncodeBytes writes v as a base64 value in XML string.
+// It will auto close the parent xml element tag.
+func (xv Value) Base64EncodeBytes(v []byte) {
+ encodeByteSlice(xv.w, (*xv.scratch)[:0], v)
+ xv.Close()
+}
+
+// BigInteger encodes v big.Int as XML value.
+// It will auto close the parent xml element tag.
+func (xv Value) BigInteger(v *big.Int) {
+ xv.w.Write([]byte(v.Text(10)))
+ xv.Close()
+}
+
+// BigDecimal encodes v big.Float as XML value.
+// It will auto close the parent xml element tag.
+func (xv Value) BigDecimal(v *big.Float) {
+ if i, accuracy := v.Int64(); accuracy == big.Exact {
+ xv.Long(i)
+ return
+ }
+
+ xv.w.Write([]byte(v.Text('e', -1)))
+ xv.Close()
+}
+
+// Write writes v directly to the xml document
+// if escapeXMLText is set to true, write will escape text.
+// It will auto close the parent xml element tag.
+func (xv Value) Write(v []byte, escapeXMLText bool) {
+ // escape and write xml text
+ if escapeXMLText {
+ escapeText(xv.w, v)
+ } else {
+ // write xml directly
+ xv.w.Write(v)
+ }
+
+ xv.Close()
+}
+
+// MemberElement does member element encoding. It returns a Value.
+// Member Element method should be used for all shapes except flattened shapes.
+//
+// A call to MemberElement will write nested element tags directly using the
+// provided start element. The value returned by MemberElement should be closed.
+func (xv Value) MemberElement(element StartElement) Value {
+ return newValue(xv.w, xv.scratch, element)
+}
+
+// FlattenedElement returns flattened element encoding. It returns a Value.
+// This method should be used for flattened shapes.
+//
+// Unlike MemberElement, flattened element will NOT write element tags
+// directly for the associated start element.
+//
+// The value returned by the FlattenedElement does not need to be closed.
+func (xv Value) FlattenedElement(element StartElement) Value {
+ v := newFlattenedValue(xv.w, xv.scratch, element)
+ v.isFlattened = true
+ return v
+}
+
+// Array returns an array encoder. By default, the members of array are
+// wrapped with `` element tag.
+// If value is marked as flattened, the start element is used to wrap the members instead of
+// the `` element.
+func (xv Value) Array() *Array {
+ return newArray(xv.w, xv.scratch, arrayMemberWrapper, xv.startElement, xv.isFlattened)
+}
+
+/*
+ArrayWithCustomName returns an array encoder.
+
+It takes named start element as an argument, the named start element will used to wrap xml array entries.
+for eg, `entry1`
+Here `customName` named start element will be wrapped on each array member.
+*/
+func (xv Value) ArrayWithCustomName(element StartElement) *Array {
+ return newArray(xv.w, xv.scratch, element, xv.startElement, xv.isFlattened)
+}
+
+/*
+Map returns a map encoder. By default, the map entries are
+wrapped with `` element tag.
+
+If value is marked as flattened, the start element is used to wrap the entry instead of
+the `` element.
+*/
+func (xv Value) Map() *Map {
+ // flattened map
+ if xv.isFlattened {
+ return newFlattenedMap(xv.w, xv.scratch, xv.startElement)
+ }
+
+ // un-flattened map
+ return newMap(xv.w, xv.scratch)
+}
+
+// encodeByteSlice is modified copy of json encoder's encodeByteSlice.
+// It is used to base64 encode a byte slice.
+func encodeByteSlice(w writer, scratch []byte, v []byte) {
+ if v == nil {
+ return
+ }
+
+ encodedLen := base64.StdEncoding.EncodedLen(len(v))
+ if encodedLen <= len(scratch) {
+ // If the encoded bytes fit in e.scratch, avoid an extra
+ // allocation and use the cheaper Encoding.Encode.
+ dst := scratch[:encodedLen]
+ base64.StdEncoding.Encode(dst, v)
+ w.Write(dst)
+ } else if encodedLen <= 1024 {
+ // The encoded bytes are short enough to allocate for, and
+ // Encoding.Encode is still cheaper.
+ dst := make([]byte, encodedLen)
+ base64.StdEncoding.Encode(dst, v)
+ w.Write(dst)
+ } else {
+ // The encoded bytes are too long to cheaply allocate, and
+ // Encoding.Encode is no longer noticeably cheaper.
+ enc := base64.NewEncoder(base64.StdEncoding, w)
+ enc.Write(v)
+ enc.Close()
+ }
+}
+
+// IsFlattened returns true if value is for flattened shape.
+func (xv Value) IsFlattened() bool {
+ return xv.isFlattened
+}
+
+// Close closes the value.
+func (xv Value) Close() {
+ writeEndElement(xv.w, xv.startElement.End())
+}
diff --git a/vendor/github.com/aws/smithy-go/encoding/xml/xml_decoder.go b/vendor/github.com/aws/smithy-go/encoding/xml/xml_decoder.go
new file mode 100644
index 000000000000..dc4eebdffa72
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/encoding/xml/xml_decoder.go
@@ -0,0 +1,154 @@
+package xml
+
+import (
+ "encoding/xml"
+ "fmt"
+ "strings"
+)
+
+// NodeDecoder is a XML decoder wrapper that is responsible to decoding
+// a single XML Node element and it's nested member elements. This wrapper decoder
+// takes in the start element of the top level node being decoded.
+type NodeDecoder struct {
+ Decoder *xml.Decoder
+ StartEl xml.StartElement
+}
+
+// WrapNodeDecoder returns an initialized XMLNodeDecoder
+func WrapNodeDecoder(decoder *xml.Decoder, startEl xml.StartElement) NodeDecoder {
+ return NodeDecoder{
+ Decoder: decoder,
+ StartEl: startEl,
+ }
+}
+
+// Token on a Node Decoder returns a xml StartElement. It returns a boolean that indicates the
+// a token is the node decoder's end node token; and an error which indicates any error
+// that occurred while retrieving the start element
+func (d NodeDecoder) Token() (t xml.StartElement, done bool, err error) {
+ for {
+ token, e := d.Decoder.Token()
+ if e != nil {
+ return t, done, e
+ }
+
+ // check if we reach end of the node being decoded
+ if el, ok := token.(xml.EndElement); ok {
+ return t, el == d.StartEl.End(), err
+ }
+
+ if t, ok := token.(xml.StartElement); ok {
+ return restoreAttrNamespaces(t), false, err
+ }
+
+ // skip token if it is a comment or preamble or empty space value due to indentation
+ // or if it's a value and is not expected
+ }
+}
+
+// restoreAttrNamespaces update XML attributes to restore the short namespaces found within
+// the raw XML document.
+func restoreAttrNamespaces(node xml.StartElement) xml.StartElement {
+ if len(node.Attr) == 0 {
+ return node
+ }
+
+ // Generate a mapping of XML namespace values to their short names.
+ ns := map[string]string{}
+ for _, a := range node.Attr {
+ if a.Name.Space == "xmlns" {
+ ns[a.Value] = a.Name.Local
+ break
+ }
+ }
+
+ for i, a := range node.Attr {
+ if a.Name.Space == "xmlns" {
+ continue
+ }
+ // By default, xml.Decoder will fully resolve these namespaces. So if you had
+ // then by default the second attribute would have the `Name.Space` resolved to `baz`. But we need it to
+ // continue to resolve as `bar` so we can easily identify it later on.
+ if v, ok := ns[node.Attr[i].Name.Space]; ok {
+ node.Attr[i].Name.Space = v
+ }
+ }
+ return node
+}
+
+// GetElement looks for the given tag name at the current level, and returns the element if found, and
+// skipping over non-matching elements. Returns an error if the node is not found, or if an error occurs while walking
+// the document.
+func (d NodeDecoder) GetElement(name string) (t xml.StartElement, err error) {
+ for {
+ token, done, err := d.Token()
+ if err != nil {
+ return t, err
+ }
+ if done {
+ return t, fmt.Errorf("%s node not found", name)
+ }
+ switch {
+ case strings.EqualFold(name, token.Name.Local):
+ return token, nil
+ default:
+ err = d.Decoder.Skip()
+ if err != nil {
+ return t, err
+ }
+ }
+ }
+}
+
+// Value provides an abstraction to retrieve char data value within an xml element.
+// The method will return an error if it encounters a nested xml element instead of char data.
+// This method should only be used to retrieve simple type or blob shape values as []byte.
+func (d NodeDecoder) Value() (c []byte, err error) {
+ t, e := d.Decoder.Token()
+ if e != nil {
+ return c, e
+ }
+
+ endElement := d.StartEl.End()
+
+ switch ev := t.(type) {
+ case xml.CharData:
+ c = ev.Copy()
+ case xml.EndElement: // end tag or self-closing
+ if ev == endElement {
+ return []byte{}, err
+ }
+ return c, fmt.Errorf("expected value for %v element, got %T type %v instead", d.StartEl.Name.Local, t, t)
+ default:
+ return c, fmt.Errorf("expected value for %v element, got %T type %v instead", d.StartEl.Name.Local, t, t)
+ }
+
+ t, e = d.Decoder.Token()
+ if e != nil {
+ return c, e
+ }
+
+ if ev, ok := t.(xml.EndElement); ok {
+ if ev == endElement {
+ return c, err
+ }
+ }
+
+ return c, fmt.Errorf("expected end element %v, got %T type %v instead", endElement, t, t)
+}
+
+// FetchRootElement takes in a decoder and returns the first start element within the xml body.
+// This function is useful in fetching the start element of an XML response and ignore the
+// comments and preamble
+func FetchRootElement(decoder *xml.Decoder) (startElement xml.StartElement, err error) {
+ for {
+ t, e := decoder.Token()
+ if e != nil {
+ return startElement, e
+ }
+
+ if startElement, ok := t.(xml.StartElement); ok {
+ return startElement, err
+ }
+ }
+}
diff --git a/vendor/github.com/aws/smithy-go/errors.go b/vendor/github.com/aws/smithy-go/errors.go
new file mode 100644
index 000000000000..d6948d020623
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/errors.go
@@ -0,0 +1,137 @@
+package smithy
+
+import "fmt"
+
+// APIError provides the generic API and protocol agnostic error type all SDK
+// generated exception types will implement.
+type APIError interface {
+ error
+
+ // ErrorCode returns the error code for the API exception.
+ ErrorCode() string
+ // ErrorMessage returns the error message for the API exception.
+ ErrorMessage() string
+ // ErrorFault returns the fault for the API exception.
+ ErrorFault() ErrorFault
+}
+
+// GenericAPIError provides a generic concrete API error type that SDKs can use
+// to deserialize error responses into. Should be used for unmodeled or untyped
+// errors.
+type GenericAPIError struct {
+ Code string
+ Message string
+ Fault ErrorFault
+}
+
+// ErrorCode returns the error code for the API exception.
+func (e *GenericAPIError) ErrorCode() string { return e.Code }
+
+// ErrorMessage returns the error message for the API exception.
+func (e *GenericAPIError) ErrorMessage() string { return e.Message }
+
+// ErrorFault returns the fault for the API exception.
+func (e *GenericAPIError) ErrorFault() ErrorFault { return e.Fault }
+
+func (e *GenericAPIError) Error() string {
+ return fmt.Sprintf("api error %s: %s", e.Code, e.Message)
+}
+
+var _ APIError = (*GenericAPIError)(nil)
+
+// OperationError decorates an underlying error which occurred while invoking
+// an operation with names of the operation and API.
+type OperationError struct {
+ ServiceID string
+ OperationName string
+ Err error
+}
+
+// Service returns the name of the API service the error occurred with.
+func (e *OperationError) Service() string { return e.ServiceID }
+
+// Operation returns the name of the API operation the error occurred with.
+func (e *OperationError) Operation() string { return e.OperationName }
+
+// Unwrap returns the nested error if any, or nil.
+func (e *OperationError) Unwrap() error { return e.Err }
+
+func (e *OperationError) Error() string {
+ return fmt.Sprintf("operation error %s: %s, %v", e.ServiceID, e.OperationName, e.Err)
+}
+
+// DeserializationError provides a wrapper for an error that occurs during
+// deserialization.
+type DeserializationError struct {
+ Err error // original error
+ Snapshot []byte
+}
+
+// Error returns a formatted error for DeserializationError
+func (e *DeserializationError) Error() string {
+ const msg = "deserialization failed"
+ if e.Err == nil {
+ return msg
+ }
+ return fmt.Sprintf("%s, %v", msg, e.Err)
+}
+
+// Unwrap returns the underlying Error in DeserializationError
+func (e *DeserializationError) Unwrap() error { return e.Err }
+
+// ErrorFault provides the type for a Smithy API error fault.
+type ErrorFault int
+
+// ErrorFault enumeration values
+const (
+ FaultUnknown ErrorFault = iota
+ FaultServer
+ FaultClient
+)
+
+func (f ErrorFault) String() string {
+ switch f {
+ case FaultServer:
+ return "server"
+ case FaultClient:
+ return "client"
+ default:
+ return "unknown"
+ }
+}
+
+// SerializationError represents an error that occurred while attempting to serialize a request
+type SerializationError struct {
+ Err error // original error
+}
+
+// Error returns a formatted error for SerializationError
+func (e *SerializationError) Error() string {
+ const msg = "serialization failed"
+ if e.Err == nil {
+ return msg
+ }
+ return fmt.Sprintf("%s: %v", msg, e.Err)
+}
+
+// Unwrap returns the underlying Error in SerializationError
+func (e *SerializationError) Unwrap() error { return e.Err }
+
+// CanceledError is the error that will be returned by an API request that was
+// canceled. API operations given a Context may return this error when
+// canceled.
+type CanceledError struct {
+ Err error
+}
+
+// CanceledError returns true to satisfy interfaces checking for canceled errors.
+func (*CanceledError) CanceledError() bool { return true }
+
+// Unwrap returns the underlying error, if there was one.
+func (e *CanceledError) Unwrap() error {
+ return e.Err
+}
+
+func (e *CanceledError) Error() string {
+ return fmt.Sprintf("canceled, %v", e.Err)
+}
diff --git a/vendor/github.com/aws/smithy-go/go.mod b/vendor/github.com/aws/smithy-go/go.mod
new file mode 100644
index 000000000000..02a91c4a829f
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/go.mod
@@ -0,0 +1,5 @@
+module github.com/aws/smithy-go
+
+go 1.15
+
+require github.com/google/go-cmp v0.5.4
diff --git a/vendor/github.com/aws/smithy-go/go.sum b/vendor/github.com/aws/smithy-go/go.sum
new file mode 100644
index 000000000000..1ffcbdbe2e12
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/go.sum
@@ -0,0 +1,4 @@
+github.com/google/go-cmp v0.5.4 h1:L8R9j+yAqZuZjsqh/z+F1NCffTKKLShY6zXTItVIZ8M=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
diff --git a/vendor/github.com/aws/smithy-go/go_module_metadata.go b/vendor/github.com/aws/smithy-go/go_module_metadata.go
new file mode 100644
index 000000000000..4f3706fa75ba
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/go_module_metadata.go
@@ -0,0 +1,6 @@
+// Code generated by internal/repotools/cmd/updatemodulemeta DO NOT EDIT.
+
+package smithy
+
+// goModuleVersion is the tagged release for this module
+const goModuleVersion = "1.9.1"
diff --git a/vendor/github.com/aws/smithy-go/io/byte.go b/vendor/github.com/aws/smithy-go/io/byte.go
new file mode 100644
index 000000000000..f8417c15b85b
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/io/byte.go
@@ -0,0 +1,12 @@
+package io
+
+const (
+ // Byte is 8 bits
+ Byte int64 = 1
+ // KibiByte (KiB) is 1024 Bytes
+ KibiByte = Byte * 1024
+ // MebiByte (MiB) is 1024 KiB
+ MebiByte = KibiByte * 1024
+ // GibiByte (GiB) is 1024 MiB
+ GibiByte = MebiByte * 1024
+)
diff --git a/vendor/github.com/aws/smithy-go/io/doc.go b/vendor/github.com/aws/smithy-go/io/doc.go
new file mode 100644
index 000000000000..a6a33eaf5672
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/io/doc.go
@@ -0,0 +1,2 @@
+// Package io provides utilities for Smithy generated API clients.
+package io
diff --git a/vendor/github.com/aws/smithy-go/io/reader.go b/vendor/github.com/aws/smithy-go/io/reader.go
new file mode 100644
index 000000000000..07063f2960d8
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/io/reader.go
@@ -0,0 +1,16 @@
+package io
+
+import (
+ "io"
+)
+
+// ReadSeekNopCloser wraps an io.ReadSeeker with an additional Close method
+// that does nothing.
+type ReadSeekNopCloser struct {
+ io.ReadSeeker
+}
+
+// Close does nothing.
+func (ReadSeekNopCloser) Close() error {
+ return nil
+}
diff --git a/vendor/github.com/aws/smithy-go/io/ringbuffer.go b/vendor/github.com/aws/smithy-go/io/ringbuffer.go
new file mode 100644
index 000000000000..06b476add8a2
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/io/ringbuffer.go
@@ -0,0 +1,94 @@
+package io
+
+import (
+ "bytes"
+ "io"
+)
+
+// RingBuffer struct satisfies io.ReadWrite interface.
+//
+// ReadBuffer is a revolving buffer data structure, which can be used to store snapshots of data in a
+// revolving window.
+type RingBuffer struct {
+ slice []byte
+ start int
+ end int
+ size int
+}
+
+// NewRingBuffer method takes in a byte slice as an input and returns a RingBuffer.
+func NewRingBuffer(slice []byte) *RingBuffer {
+ ringBuf := RingBuffer{
+ slice: slice,
+ }
+ return &ringBuf
+}
+
+// Write method inserts the elements in a byte slice, and returns the number of bytes written along with any error.
+func (r *RingBuffer) Write(p []byte) (int, error) {
+ for _, b := range p {
+ // check if end points to invalid index, we need to circle back
+ if r.end == len(r.slice) {
+ r.end = 0
+ }
+ // check if start points to invalid index, we need to circle back
+ if r.start == len(r.slice) {
+ r.start = 0
+ }
+ // if ring buffer is filled, increment the start index
+ if r.size == len(r.slice) {
+ r.size--
+ r.start++
+ }
+
+ r.slice[r.end] = b
+ r.end++
+ r.size++
+ }
+ return len(p), nil
+}
+
+// Read copies the data on the ring buffer into the byte slice provided to the method.
+// Returns the read count along with any error encountered while reading.
+func (r *RingBuffer) Read(p []byte) (int, error) {
+ // readCount keeps track of the number of bytes read
+ var readCount int
+ for j := 0; j < len(p); j++ {
+ // if ring buffer is empty or completely read
+ // return EOF error.
+ if r.size == 0 {
+ return readCount, io.EOF
+ }
+
+ if r.start == len(r.slice) {
+ r.start = 0
+ }
+
+ p[j] = r.slice[r.start]
+ readCount++
+ // increment the start pointer for ring buffer
+ r.start++
+ // decrement the size of ring buffer
+ r.size--
+ }
+ return readCount, nil
+}
+
+// Len returns the number of unread bytes in the buffer.
+func (r *RingBuffer) Len() int {
+ return r.size
+}
+
+// Bytes returns a copy of the RingBuffer's bytes.
+func (r RingBuffer) Bytes() []byte {
+ var b bytes.Buffer
+ io.Copy(&b, &r)
+ return b.Bytes()
+}
+
+// Reset resets the ring buffer.
+func (r *RingBuffer) Reset() {
+ *r = RingBuffer{
+ slice: r.slice,
+ }
+}
diff --git a/vendor/github.com/aws/smithy-go/local-mod-replace.sh b/vendor/github.com/aws/smithy-go/local-mod-replace.sh
new file mode 100644
index 000000000000..800bf3769542
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/local-mod-replace.sh
@@ -0,0 +1,39 @@
+#1/usr/bin/env bash
+
+PROJECT_DIR=""
+SMITHY_SOURCE_DIR=$(cd `dirname $0` && pwd)
+
+usage() {
+ echo "Usage: $0 [-s SMITHY_SOURCE_DIR] [-d PROJECT_DIR]" 1>&2
+ exit 1
+}
+
+while getopts "hs:d:" options; do
+ case "${options}" in
+ s)
+ SMITHY_SOURCE_DIR=${OPTARG}
+ if [ "$SMITHY_SOURCE_DIR" == "" ]; then
+ echo "path to smithy-go source directory is required" || exit
+ usage
+ fi
+ ;;
+ d)
+ PROJECT_DIR=${OPTARG}
+ ;;
+ h)
+ usage
+ ;;
+ *)
+ usage
+ ;;
+ esac
+done
+
+if [ "$PROJECT_DIR" != "" ]; then
+ cd $PROJECT_DIR || exit
+fi
+
+go mod graph | awk '{print $1}' | cut -d '@' -f 1 | sort | uniq | grep "github.com/aws/smithy-go" | while read x; do
+ repPath=${x/github.com\/aws\/smithy-go/${SMITHY_SOURCE_DIR}}
+ echo -replace $x=$repPath
+done | xargs go mod edit
diff --git a/vendor/github.com/aws/smithy-go/logging/logger.go b/vendor/github.com/aws/smithy-go/logging/logger.go
new file mode 100644
index 000000000000..2071924bd306
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/logging/logger.go
@@ -0,0 +1,82 @@
+package logging
+
+import (
+ "context"
+ "io"
+ "log"
+)
+
+// Classification is the type of the log entry's classification name.
+type Classification string
+
+// Set of standard classifications that can be used by clients and middleware
+const (
+ Warn Classification = "WARN"
+ Debug Classification = "DEBUG"
+)
+
+// Logger is an interface for logging entries at certain classifications.
+type Logger interface {
+ // Logf is expected to support the standard fmt package "verbs".
+ Logf(classification Classification, format string, v ...interface{})
+}
+
+// LoggerFunc is a wrapper around a function to satisfy the Logger interface.
+type LoggerFunc func(classification Classification, format string, v ...interface{})
+
+// Logf delegates the logging request to the wrapped function.
+func (f LoggerFunc) Logf(classification Classification, format string, v ...interface{}) {
+ f(classification, format, v...)
+}
+
+// ContextLogger is an optional interface a Logger implementation may expose that provides
+// the ability to create context aware log entries.
+type ContextLogger interface {
+ WithContext(context.Context) Logger
+}
+
+// WithContext will pass the provided context to logger if it implements the ContextLogger interface and return the resulting
+// logger. Otherwise the logger will be returned as is. As a special case if a nil logger is provided, a Nop logger will
+// be returned to the caller.
+func WithContext(ctx context.Context, logger Logger) Logger {
+ if logger == nil {
+ return Nop{}
+ }
+
+ cl, ok := logger.(ContextLogger)
+ if !ok {
+ return logger
+ }
+
+ return cl.WithContext(ctx)
+}
+
+// Nop is a Logger implementation that simply does not perform any logging.
+type Nop struct{}
+
+// Logf simply returns without performing any action
+func (n Nop) Logf(Classification, string, ...interface{}) {
+ return
+}
+
+// StandardLogger is a Logger implementation that wraps the standard library logger, and delegates logging to it's
+// Printf method.
+type StandardLogger struct {
+ Logger *log.Logger
+}
+
+// Logf logs the given classification and message to the underlying logger.
+func (s StandardLogger) Logf(classification Classification, format string, v ...interface{}) {
+ if len(classification) != 0 {
+ format = string(classification) + " " + format
+ }
+
+ s.Logger.Printf(format, v...)
+}
+
+// NewStandardLogger returns a new StandardLogger
+func NewStandardLogger(writer io.Writer) *StandardLogger {
+ return &StandardLogger{
+ Logger: log.New(writer, "SDK ", log.LstdFlags),
+ }
+}
diff --git a/vendor/github.com/aws/smithy-go/middleware/doc.go b/vendor/github.com/aws/smithy-go/middleware/doc.go
new file mode 100644
index 000000000000..9858928a7f83
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/doc.go
@@ -0,0 +1,67 @@
+// Package middleware provides transport agnostic middleware for decorating SDK
+// handlers.
+//
+// The Smithy middleware stack provides ordered behavior to be invoked on an
+// underlying handler. The stack is separated into steps that are invoked in a
+// static order. A step is a collection of middleware that are injected into a
+// ordered list defined by the user. The user may add, insert, swap, and remove a
+// step's middleware. When the stack is invoked the step middleware become static,
+// and their order cannot be modified.
+//
+// A stack and its step middleware are **not** safe to modify concurrently.
+//
+// A stack will use the ordered list of middleware to decorate a underlying
+// handler. A handler could be something like an HTTP Client that round trips an
+// API operation over HTTP.
+//
+// Smithy Middleware Stack
+//
+// A Stack is a collection of middleware that wrap a handler. The stack can be
+// broken down into discreet steps. Each step may contain zero or more middleware
+// specific to that stack's step.
+//
+// A Stack Step is a predefined set of middleware that are invoked in a static
+// order by the Stack. These steps represent fixed points in the middleware stack
+// for organizing specific behavior, such as serialize and build. A Stack Step is
+// composed of zero or more middleware that are specific to that step. A step may
+// define its own set of input/output parameters the generic input/output
+// parameters are cast from. A step calls its middleware recursively, before
+// calling the next step in the stack returning the result or error of the step
+// middleware decorating the underlying handler.
+//
+// * Initialize: Prepares the input, and sets any default parameters as needed,
+// (e.g. idempotency token, and presigned URLs).
+//
+// * Serialize: Serializes the prepared input into a data structure that can be
+// consumed by the target transport's message, (e.g. REST-JSON serialization).
+//
+// * Build: Adds additional metadata to the serialized transport message, (e.g.
+// HTTP's Content-Length header, or body checksum). Decorations and
+// modifications to the message should be copied to all message attempts.
+//
+// * Finalize: Performs final preparations needed before sending the message. The
+// message should already be complete by this stage, and is only alternated to
+// meet the expectations of the recipient, (e.g. Retry and AWS SigV4 request
+// signing).
+//
+// * Deserialize: Reacts to the handler's response returned by the recipient of
+// the request message. Deserializes the response into a structured type or
+// error above stacks can react to.
+//
+// Adding Middleware to a Stack Step
+//
+// Middleware can be added to a step front or back, or relative, by name, to an
+// existing middleware in that stack. If a middleware does not have a name, a
+// unique name will be generated at the middleware and be added to the step.
+//
+// // Create middleware stack
+// stack := middleware.NewStack()
+//
+// // Add middleware to stack steps
+// stack.Initialize.Add(paramValidationMiddleware, middleware.After)
+// stack.Serialize.Add(marshalOperationFoo, middleware.After)
+// stack.Deserialize.Add(unmarshalOperationFoo, middleware.After)
+//
+// // Invoke middleware on handler.
+// resp, err := stack.HandleMiddleware(ctx, req.Input, clientHandler)
+package middleware
diff --git a/vendor/github.com/aws/smithy-go/middleware/logging.go b/vendor/github.com/aws/smithy-go/middleware/logging.go
new file mode 100644
index 000000000000..c2f0dbb6bda9
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/logging.go
@@ -0,0 +1,46 @@
+package middleware
+
+import (
+ "context"
+
+ "github.com/aws/smithy-go/logging"
+)
+
+// loggerKey is the context value key for which the logger is associated with.
+type loggerKey struct{}
+
+// GetLogger takes a context to retrieve a Logger from. If no logger is present on the context a logging.Nop logger
+// is returned. If the logger retrieved from context supports the ContextLogger interface, the context will be passed
+// to the WithContext method and the resulting logger will be returned. Otherwise the stored logger is returned as is.
+func GetLogger(ctx context.Context) logging.Logger {
+ logger, ok := ctx.Value(loggerKey{}).(logging.Logger)
+ if !ok || logger == nil {
+ return logging.Nop{}
+ }
+
+ return logging.WithContext(ctx, logger)
+}
+
+// SetLogger sets the provided logger value on the provided ctx.
+func SetLogger(ctx context.Context, logger logging.Logger) context.Context {
+ return context.WithValue(ctx, loggerKey{}, logger)
+}
+
+type setLogger struct {
+ Logger logging.Logger
+}
+
+// AddSetLoggerMiddleware adds a middleware that will add the provided logger to the middleware context.
+func AddSetLoggerMiddleware(stack *Stack, logger logging.Logger) error {
+ return stack.Initialize.Add(&setLogger{Logger: logger}, After)
+}
+
+func (a *setLogger) ID() string {
+ return "SetLogger"
+}
+
+func (a *setLogger) HandleInitialize(ctx context.Context, in InitializeInput, next InitializeHandler) (
+ out InitializeOutput, metadata Metadata, err error,
+) {
+ return next.HandleInitialize(SetLogger(ctx, a.Logger), in)
+}
diff --git a/vendor/github.com/aws/smithy-go/middleware/metadata.go b/vendor/github.com/aws/smithy-go/middleware/metadata.go
new file mode 100644
index 000000000000..7bb7dbcf5a05
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/metadata.go
@@ -0,0 +1,65 @@
+package middleware
+
+// MetadataReader provides an interface for reading metadata from the
+// underlying metadata container.
+type MetadataReader interface {
+ Get(key interface{}) interface{}
+}
+
+// Metadata provides storing and reading metadata values. Keys may be any
+// comparable value type. Get and set will panic if key is not a comparable
+// value type.
+//
+// Metadata uses lazy initialization, and Set method must be called as an
+// addressable value, or pointer. Not doing so may cause key/value pair to not
+// be set.
+type Metadata struct {
+ values map[interface{}]interface{}
+}
+
+// Get attempts to retrieve the value the key points to. Returns nil if the
+// key was not found.
+//
+// Panics if key type is not comparable.
+func (m Metadata) Get(key interface{}) interface{} {
+ return m.values[key]
+}
+
+// Clone creates a shallow copy of Metadata entries, returning a new Metadata
+// value with the original entries copied into it.
+func (m Metadata) Clone() Metadata {
+ vs := make(map[interface{}]interface{}, len(m.values))
+ for k, v := range m.values {
+ vs[k] = v
+ }
+
+ return Metadata{
+ values: vs,
+ }
+}
+
+// Set stores the value pointed to by the key. If a value already exists at
+// that key it will be replaced with the new value.
+//
+// Set method must be called as an addressable value, or pointer. If Set is not
+// called as an addressable value or pointer, the key value pair being set may
+// be lost.
+//
+// Panics if the key type is not comparable.
+func (m *Metadata) Set(key, value interface{}) {
+ if m.values == nil {
+ m.values = map[interface{}]interface{}{}
+ }
+ m.values[key] = value
+}
+
+// Has returns whether the key exists in the metadata.
+//
+// Panics if the key type is not comparable.
+func (m Metadata) Has(key interface{}) bool {
+ if m.values == nil {
+ return false
+ }
+ _, ok := m.values[key]
+ return ok
+}
diff --git a/vendor/github.com/aws/smithy-go/middleware/middleware.go b/vendor/github.com/aws/smithy-go/middleware/middleware.go
new file mode 100644
index 000000000000..803b7c751840
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/middleware.go
@@ -0,0 +1,71 @@
+package middleware
+
+import (
+ "context"
+)
+
+// Handler provides the interface for performing the logic to obtain an output,
+// or error for the given input.
+type Handler interface {
+ // Handle performs logic to obtain an output for the given input. Handler
+ // should be decorated with middleware to perform input specific behavior.
+ Handle(ctx context.Context, input interface{}) (
+ output interface{}, metadata Metadata, err error,
+ )
+}
+
+// HandlerFunc provides a wrapper around a function pointer to be used as a
+// middleware handler.
+type HandlerFunc func(ctx context.Context, input interface{}) (
+ output interface{}, metadata Metadata, err error,
+)
+
+// Handle invokes the underlying function, returning the result.
+func (fn HandlerFunc) Handle(ctx context.Context, input interface{}) (
+ output interface{}, metadata Metadata, err error,
+) {
+ return fn(ctx, input)
+}
+
+// Middleware provides the interface to call handlers in a chain.
+type Middleware interface {
+ // ID provides a unique identifier for the middleware.
+ ID() string
+
+ // Performs the middleware's handling of the input, returning the output,
+ // or error. The middleware can invoke the next Handler if handling should
+ // continue.
+ HandleMiddleware(ctx context.Context, input interface{}, next Handler) (
+ output interface{}, metadata Metadata, err error,
+ )
+}
+
+// decoratedHandler wraps a middleware in order to to call the next handler in
+// the chain.
+type decoratedHandler struct {
+ // The next handler to be called.
+ Next Handler
+
+ // The current middleware decorating the handler.
+ With Middleware
+}
+
+// Handle implements the Handler interface to handle a operation invocation.
+func (m decoratedHandler) Handle(ctx context.Context, input interface{}) (
+ output interface{}, metadata Metadata, err error,
+) {
+ return m.With.HandleMiddleware(ctx, input, m.Next)
+}
+
+// DecorateHandler decorates a handler with a middleware. Wrapping the handler
+// with the middleware.
+func DecorateHandler(h Handler, with ...Middleware) Handler {
+ for i := len(with) - 1; i >= 0; i-- {
+ h = decoratedHandler{
+ Next: h,
+ With: with[i],
+ }
+ }
+
+ return h
+}
diff --git a/vendor/github.com/aws/smithy-go/middleware/ordered_group.go b/vendor/github.com/aws/smithy-go/middleware/ordered_group.go
new file mode 100644
index 000000000000..4b195308c599
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/ordered_group.go
@@ -0,0 +1,268 @@
+package middleware
+
+import "fmt"
+
+// RelativePosition provides specifying the relative position of a middleware
+// in an ordered group.
+type RelativePosition int
+
+// Relative position for middleware in steps.
+const (
+ After RelativePosition = iota
+ Before
+)
+
+type ider interface {
+ ID() string
+}
+
+// orderedIDs provides an ordered collection of items with relative ordering
+// by name.
+type orderedIDs struct {
+ order *relativeOrder
+ items map[string]ider
+}
+
+const baseOrderedItems = 5
+
+func newOrderedIDs() *orderedIDs {
+ return &orderedIDs{
+ order: newRelativeOrder(),
+ items: make(map[string]ider, baseOrderedItems),
+ }
+}
+
+// Add injects the item to the relative position of the item group. Returns an
+// error if the item already exists.
+func (g *orderedIDs) Add(m ider, pos RelativePosition) error {
+ id := m.ID()
+ if len(id) == 0 {
+ return fmt.Errorf("empty ID, ID must not be empty")
+ }
+
+ if err := g.order.Add(pos, id); err != nil {
+ return err
+ }
+
+ g.items[id] = m
+ return nil
+}
+
+// Insert injects the item relative to an existing item id. Returns an error if
+// the original item does not exist, or the item being added already exists.
+func (g *orderedIDs) Insert(m ider, relativeTo string, pos RelativePosition) error {
+ if len(m.ID()) == 0 {
+ return fmt.Errorf("insert ID must not be empty")
+ }
+ if len(relativeTo) == 0 {
+ return fmt.Errorf("relative to ID must not be empty")
+ }
+
+ if err := g.order.Insert(relativeTo, pos, m.ID()); err != nil {
+ return err
+ }
+
+ g.items[m.ID()] = m
+ return nil
+}
+
+// Get returns the ider identified by id. If ider is not present, returns false.
+func (g *orderedIDs) Get(id string) (ider, bool) {
+ v, ok := g.items[id]
+ return v, ok
+}
+
+// Swap removes the item by id, replacing it with the new item. Returns an error
+// if the original item doesn't exist.
+func (g *orderedIDs) Swap(id string, m ider) (ider, error) {
+ if len(id) == 0 {
+ return nil, fmt.Errorf("swap from ID must not be empty")
+ }
+
+ iderID := m.ID()
+ if len(iderID) == 0 {
+ return nil, fmt.Errorf("swap to ID must not be empty")
+ }
+
+ if err := g.order.Swap(id, iderID); err != nil {
+ return nil, err
+ }
+
+ removed := g.items[id]
+
+ delete(g.items, id)
+ g.items[iderID] = m
+
+ return removed, nil
+}
+
+// Remove removes the item by id. Returns an error if the item
+// doesn't exist.
+func (g *orderedIDs) Remove(id string) (ider, error) {
+ if len(id) == 0 {
+ return nil, fmt.Errorf("remove ID must not be empty")
+ }
+
+ if err := g.order.Remove(id); err != nil {
+ return nil, err
+ }
+
+ removed := g.items[id]
+ delete(g.items, id)
+ return removed, nil
+}
+
+func (g *orderedIDs) List() []string {
+ items := g.order.List()
+ order := make([]string, len(items))
+ copy(order, items)
+ return order
+}
+
+// Clear removes all entries and slots.
+func (g *orderedIDs) Clear() {
+ g.order.Clear()
+ g.items = map[string]ider{}
+}
+
+// GetOrder returns the item in the order it should be invoked in.
+func (g *orderedIDs) GetOrder() []interface{} {
+ order := g.order.List()
+ ordered := make([]interface{}, len(order))
+ for i := 0; i < len(order); i++ {
+ ordered[i] = g.items[order[i]]
+ }
+
+ return ordered
+}
+
+// relativeOrder provides ordering of item
+type relativeOrder struct {
+ order []string
+}
+
+func newRelativeOrder() *relativeOrder {
+ return &relativeOrder{
+ order: make([]string, 0, baseOrderedItems),
+ }
+}
+
+// Add inserts an item into the order relative to the position provided.
+func (s *relativeOrder) Add(pos RelativePosition, ids ...string) error {
+ if len(ids) == 0 {
+ return nil
+ }
+
+ for _, id := range ids {
+ if _, ok := s.has(id); ok {
+ return fmt.Errorf("already exists, %v", id)
+ }
+ }
+
+ switch pos {
+ case Before:
+ return s.insert(0, Before, ids...)
+
+ case After:
+ s.order = append(s.order, ids...)
+
+ default:
+ return fmt.Errorf("invalid position, %v", int(pos))
+ }
+
+ return nil
+}
+
+// Insert injects an item before or after the relative item. Returns
+// an error if the relative item does not exist.
+func (s *relativeOrder) Insert(relativeTo string, pos RelativePosition, ids ...string) error {
+ if len(ids) == 0 {
+ return nil
+ }
+
+ for _, id := range ids {
+ if _, ok := s.has(id); ok {
+ return fmt.Errorf("already exists, %v", id)
+ }
+ }
+
+ i, ok := s.has(relativeTo)
+ if !ok {
+ return fmt.Errorf("not found, %v", relativeTo)
+ }
+
+ return s.insert(i, pos, ids...)
+}
+
+// Swap will replace the item id with the to item. Returns an
+// error if the original item id does not exist. Allows swapping out an
+// item for another item with the same id.
+func (s *relativeOrder) Swap(id, to string) error {
+ i, ok := s.has(id)
+ if !ok {
+ return fmt.Errorf("not found, %v", id)
+ }
+
+ if _, ok = s.has(to); ok && id != to {
+ return fmt.Errorf("already exists, %v", to)
+ }
+
+ s.order[i] = to
+ return nil
+}
+
+func (s *relativeOrder) Remove(id string) error {
+ i, ok := s.has(id)
+ if !ok {
+ return fmt.Errorf("not found, %v", id)
+ }
+
+ s.order = append(s.order[:i], s.order[i+1:]...)
+ return nil
+}
+
+func (s *relativeOrder) List() []string {
+ return s.order
+}
+
+func (s *relativeOrder) Clear() {
+ s.order = s.order[0:0]
+}
+
+func (s *relativeOrder) insert(i int, pos RelativePosition, ids ...string) error {
+ switch pos {
+ case Before:
+ n := len(ids)
+ var src []string
+ if n <= cap(s.order)-len(s.order) {
+ s.order = s.order[:len(s.order)+n]
+ src = s.order
+ } else {
+ src = s.order
+ s.order = make([]string, len(s.order)+n)
+ copy(s.order[:i], src[:i]) // only when allocating a new slice do we need to copy the front half
+ }
+ copy(s.order[i+n:], src[i:])
+ copy(s.order[i:], ids)
+ case After:
+ if i == len(s.order)-1 || len(s.order) == 0 {
+ s.order = append(s.order, ids...)
+ } else {
+ s.order = append(s.order[:i+1], append(ids, s.order[i+1:]...)...)
+ }
+
+ default:
+ return fmt.Errorf("invalid position, %v", int(pos))
+ }
+
+ return nil
+}
+
+func (s *relativeOrder) has(id string) (i int, found bool) {
+ for i := 0; i < len(s.order); i++ {
+ if s.order[i] == id {
+ return i, true
+ }
+ }
+ return 0, false
+}
diff --git a/vendor/github.com/aws/smithy-go/middleware/stack.go b/vendor/github.com/aws/smithy-go/middleware/stack.go
new file mode 100644
index 000000000000..45ccb5b93c9f
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/stack.go
@@ -0,0 +1,209 @@
+package middleware
+
+import (
+ "context"
+ "io"
+ "strings"
+)
+
+// Stack provides protocol and transport agnostic set of middleware split into
+// distinct steps. Steps have specific transitions between them, that are
+// managed by the individual step.
+//
+// Steps are composed as middleware around the underlying handler in the
+// following order:
+//
+// Initialize -> Serialize -> Build -> Finalize -> Deserialize -> Handler
+//
+// Any middleware within the chain may choose to stop and return an error or
+// response. Since the middleware decorate the handler like a call stack, each
+// middleware will receive the result of the next middleware in the chain.
+// Middleware that does not need to react to an input, or result must forward
+// along the input down the chain, or return the result back up the chain.
+//
+// Initialize <- Serialize -> Build -> Finalize <- Deserialize <- Handler
+type Stack struct {
+ // Initialize prepares the input, and sets any default parameters as
+ // needed, (e.g. idempotency token, and presigned URLs).
+ //
+ // Takes Input Parameters, and returns result or error.
+ //
+ // Receives result or error from Serialize step.
+ Initialize *InitializeStep
+
+ // Serialize serializes the prepared input into a data structure that can be consumed
+ // by the target transport's message, (e.g. REST-JSON serialization)
+ //
+ // Converts Input Parameters into a Request, and returns the result or error.
+ //
+ // Receives result or error from Build step.
+ Serialize *SerializeStep
+
+ // Build adds additional metadata to the serialized transport message
+ // (e.g. HTTP's Content-Length header, or body checksum). Decorations and
+ // modifications to the message should be copied to all message attempts.
+ //
+ // Takes Request, and returns result or error.
+ //
+ // Receives result or error from Finalize step.
+ Build *BuildStep
+
+ // Finalize performs final preparations needed before sending the message. The
+ // message should already be complete by this stage, and is only alternated
+ // to meet the expectations of the recipient (e.g. Retry and AWS SigV4
+ // request signing)
+ //
+ // Takes Request, and returns result or error.
+ //
+ // Receives result or error from Deserialize step.
+ Finalize *FinalizeStep
+
+ // Deserialize reacts to the handler's response returned by the recipient of the request
+ // message. Deserializes the response into a structured type or error above
+ // stacks can react to.
+ //
+ // Should only forward Request to underlying handler.
+ //
+ // Takes Request, and returns result or error.
+ //
+ // Receives raw response, or error from underlying handler.
+ Deserialize *DeserializeStep
+
+ id string
+}
+
+// NewStack returns an initialize empty stack.
+func NewStack(id string, newRequestFn func() interface{}) *Stack {
+ return &Stack{
+ id: id,
+ Initialize: NewInitializeStep(),
+ Serialize: NewSerializeStep(newRequestFn),
+ Build: NewBuildStep(),
+ Finalize: NewFinalizeStep(),
+ Deserialize: NewDeserializeStep(),
+ }
+}
+
+// ID returns the unique ID for the stack as a middleware.
+func (s *Stack) ID() string { return s.id }
+
+// HandleMiddleware invokes the middleware stack decorating the next handler.
+// Each step of stack will be invoked in order before calling the next step.
+// With the next handler call last.
+//
+// The input value must be the input parameters of the operation being
+// performed.
+//
+// Will return the result of the operation, or error.
+func (s *Stack) HandleMiddleware(ctx context.Context, input interface{}, next Handler) (
+ output interface{}, metadata Metadata, err error,
+) {
+ h := DecorateHandler(next,
+ s.Initialize,
+ s.Serialize,
+ s.Build,
+ s.Finalize,
+ s.Deserialize,
+ )
+
+ return h.Handle(ctx, input)
+}
+
+// List returns a list of all middleware in the stack by step.
+func (s *Stack) List() []string {
+ var l []string
+ l = append(l, s.id)
+
+ l = append(l, s.Initialize.ID())
+ l = append(l, s.Initialize.List()...)
+
+ l = append(l, s.Serialize.ID())
+ l = append(l, s.Serialize.List()...)
+
+ l = append(l, s.Build.ID())
+ l = append(l, s.Build.List()...)
+
+ l = append(l, s.Finalize.ID())
+ l = append(l, s.Finalize.List()...)
+
+ l = append(l, s.Deserialize.ID())
+ l = append(l, s.Deserialize.List()...)
+
+ return l
+}
+
+func (s *Stack) String() string {
+ var b strings.Builder
+
+ w := &indentWriter{w: &b}
+
+ w.WriteLine(s.id)
+ w.Push()
+
+ writeStepItems(w, s.Initialize)
+ writeStepItems(w, s.Serialize)
+ writeStepItems(w, s.Build)
+ writeStepItems(w, s.Finalize)
+ writeStepItems(w, s.Deserialize)
+
+ return b.String()
+}
+
+type stackStepper interface {
+ ID() string
+ List() []string
+}
+
+func writeStepItems(w *indentWriter, s stackStepper) {
+ type lister interface {
+ List() []string
+ }
+
+ w.WriteLine(s.ID())
+ w.Push()
+
+ defer w.Pop()
+
+ // ignore stack to prevent circular iterations
+ if _, ok := s.(*Stack); ok {
+ return
+ }
+
+ for _, id := range s.List() {
+ w.WriteLine(id)
+ }
+}
+
+type stringWriter interface {
+ io.Writer
+ WriteString(string) (int, error)
+ WriteRune(rune) (int, error)
+}
+
+type indentWriter struct {
+ w stringWriter
+ depth int
+}
+
+const indentDepth = "\t\t\t\t\t\t\t\t\t\t"
+
+func (w *indentWriter) Push() {
+ w.depth++
+}
+
+func (w *indentWriter) Pop() {
+ w.depth--
+ if w.depth < 0 {
+ w.depth = 0
+ }
+}
+
+func (w *indentWriter) WriteLine(v string) {
+ w.w.WriteString(indentDepth[:w.depth])
+
+ v = strings.ReplaceAll(v, "\n", "\\n")
+ v = strings.ReplaceAll(v, "\r", "\\r")
+
+ w.w.WriteString(v)
+ w.w.WriteRune('\n')
+}
diff --git a/vendor/github.com/aws/smithy-go/middleware/stack_values.go b/vendor/github.com/aws/smithy-go/middleware/stack_values.go
new file mode 100644
index 000000000000..ef96009ba182
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/stack_values.go
@@ -0,0 +1,100 @@
+package middleware
+
+import (
+ "context"
+ "reflect"
+ "strings"
+)
+
+// WithStackValue adds a key value pair to the context that is intended to be
+// scoped to a stack. Use ClearStackValues to get a new context with all stack
+// values cleared.
+func WithStackValue(ctx context.Context, key, value interface{}) context.Context {
+ md, _ := ctx.Value(stackValuesKey{}).(*stackValues)
+
+ md = withStackValue(md, key, value)
+ return context.WithValue(ctx, stackValuesKey{}, md)
+}
+
+// ClearStackValues returns a context without any stack values.
+func ClearStackValues(ctx context.Context) context.Context {
+ return context.WithValue(ctx, stackValuesKey{}, nil)
+}
+
+// GetStackValues returns the value pointed to by the key within the stack
+// values, if it is present.
+func GetStackValue(ctx context.Context, key interface{}) interface{} {
+ md, _ := ctx.Value(stackValuesKey{}).(*stackValues)
+ if md == nil {
+ return nil
+ }
+
+ return md.Value(key)
+}
+
+type stackValuesKey struct{}
+
+type stackValues struct {
+ key interface{}
+ value interface{}
+ parent *stackValues
+}
+
+func withStackValue(parent *stackValues, key, value interface{}) *stackValues {
+ if key == nil {
+ panic("nil key")
+ }
+ if !reflect.TypeOf(key).Comparable() {
+ panic("key is not comparable")
+ }
+ return &stackValues{key: key, value: value, parent: parent}
+}
+
+func (m *stackValues) Value(key interface{}) interface{} {
+ if key == m.key {
+ return m.value
+ }
+
+ if m.parent == nil {
+ return nil
+ }
+
+ return m.parent.Value(key)
+}
+
+func (c *stackValues) String() string {
+ var str strings.Builder
+
+ cc := c
+ for cc == nil {
+ str.WriteString("(" +
+ reflect.TypeOf(c.key).String() +
+ ": " +
+ stringify(cc.value) +
+ ")")
+ if cc.parent != nil {
+ str.WriteString(" -> ")
+ }
+ cc = cc.parent
+ }
+ str.WriteRune('}')
+
+ return str.String()
+}
+
+type stringer interface {
+ String() string
+}
+
+// stringify tries a bit to stringify v, without using fmt, since we don't
+// want context depending on the unicode tables. This is only used by
+// *valueCtx.String().
+func stringify(v interface{}) string {
+ switch s := v.(type) {
+ case stringer:
+ return s.String()
+ case string:
+ return s
+ }
+ return ""
+}
diff --git a/vendor/github.com/aws/smithy-go/middleware/step_build.go b/vendor/github.com/aws/smithy-go/middleware/step_build.go
new file mode 100644
index 000000000000..7e1d94caeef9
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/step_build.go
@@ -0,0 +1,211 @@
+package middleware
+
+import (
+ "context"
+)
+
+// BuildInput provides the input parameters for the BuildMiddleware to consume.
+// BuildMiddleware may modify the Request value before forwarding the input
+// along to the next BuildHandler.
+type BuildInput struct {
+ Request interface{}
+}
+
+// BuildOutput provides the result returned by the next BuildHandler.
+type BuildOutput struct {
+ Result interface{}
+}
+
+// BuildHandler provides the interface for the next handler the
+// BuildMiddleware will call in the middleware chain.
+type BuildHandler interface {
+ HandleBuild(ctx context.Context, in BuildInput) (
+ out BuildOutput, metadata Metadata, err error,
+ )
+}
+
+// BuildMiddleware provides the interface for middleware specific to the
+// serialize step. Delegates to the next BuildHandler for further
+// processing.
+type BuildMiddleware interface {
+ // Unique ID for the middleware in theBuildStep. The step does not allow
+ // duplicate IDs.
+ ID() string
+
+ // Invokes the middleware behavior which must delegate to the next handler
+ // for the middleware chain to continue. The method must return a result or
+ // error to its caller.
+ HandleBuild(ctx context.Context, in BuildInput, next BuildHandler) (
+ out BuildOutput, metadata Metadata, err error,
+ )
+}
+
+// BuildMiddlewareFunc returns a BuildMiddleware with the unique ID provided,
+// and the func to be invoked.
+func BuildMiddlewareFunc(id string, fn func(context.Context, BuildInput, BuildHandler) (BuildOutput, Metadata, error)) BuildMiddleware {
+ return buildMiddlewareFunc{
+ id: id,
+ fn: fn,
+ }
+}
+
+type buildMiddlewareFunc struct {
+ // Unique ID for the middleware.
+ id string
+
+ // Middleware function to be called.
+ fn func(context.Context, BuildInput, BuildHandler) (BuildOutput, Metadata, error)
+}
+
+// ID returns the unique ID for the middleware.
+func (s buildMiddlewareFunc) ID() string { return s.id }
+
+// HandleBuild invokes the middleware Fn.
+func (s buildMiddlewareFunc) HandleBuild(ctx context.Context, in BuildInput, next BuildHandler) (
+ out BuildOutput, metadata Metadata, err error,
+) {
+ return s.fn(ctx, in, next)
+}
+
+var _ BuildMiddleware = (buildMiddlewareFunc{})
+
+// BuildStep provides the ordered grouping of BuildMiddleware to be invoked on
+// a handler.
+type BuildStep struct {
+ ids *orderedIDs
+}
+
+// NewBuildStep returns a BuildStep ready to have middleware for
+// initialization added to it.
+func NewBuildStep() *BuildStep {
+ return &BuildStep{
+ ids: newOrderedIDs(),
+ }
+}
+
+var _ Middleware = (*BuildStep)(nil)
+
+// ID returns the unique name of the step as a middleware.
+func (s *BuildStep) ID() string {
+ return "Build stack step"
+}
+
+// HandleMiddleware invokes the middleware by decorating the next handler
+// provided. Returns the result of the middleware and handler being invoked.
+//
+// Implements Middleware interface.
+func (s *BuildStep) HandleMiddleware(ctx context.Context, in interface{}, next Handler) (
+ out interface{}, metadata Metadata, err error,
+) {
+ order := s.ids.GetOrder()
+
+ var h BuildHandler = buildWrapHandler{Next: next}
+ for i := len(order) - 1; i >= 0; i-- {
+ h = decoratedBuildHandler{
+ Next: h,
+ With: order[i].(BuildMiddleware),
+ }
+ }
+
+ sIn := BuildInput{
+ Request: in,
+ }
+
+ res, metadata, err := h.HandleBuild(ctx, sIn)
+ return res.Result, metadata, err
+}
+
+// Get retrieves the middleware identified by id. If the middleware is not present, returns false.
+func (s *BuildStep) Get(id string) (BuildMiddleware, bool) {
+ get, ok := s.ids.Get(id)
+ if !ok {
+ return nil, false
+ }
+ return get.(BuildMiddleware), ok
+}
+
+// Add injects the middleware to the relative position of the middleware group.
+// Returns an error if the middleware already exists.
+func (s *BuildStep) Add(m BuildMiddleware, pos RelativePosition) error {
+ return s.ids.Add(m, pos)
+}
+
+// Insert injects the middleware relative to an existing middleware id.
+// Returns an error if the original middleware does not exist, or the middleware
+// being added already exists.
+func (s *BuildStep) Insert(m BuildMiddleware, relativeTo string, pos RelativePosition) error {
+ return s.ids.Insert(m, relativeTo, pos)
+}
+
+// Swap removes the middleware by id, replacing it with the new middleware.
+// Returns the middleware removed, or an error if the middleware to be removed
+// doesn't exist.
+func (s *BuildStep) Swap(id string, m BuildMiddleware) (BuildMiddleware, error) {
+ removed, err := s.ids.Swap(id, m)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(BuildMiddleware), nil
+}
+
+// Remove removes the middleware by id. Returns error if the middleware
+// doesn't exist.
+func (s *BuildStep) Remove(id string) (BuildMiddleware, error) {
+ removed, err := s.ids.Remove(id)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(BuildMiddleware), nil
+}
+
+// List returns a list of the middleware in the step.
+func (s *BuildStep) List() []string {
+ return s.ids.List()
+}
+
+// Clear removes all middleware in the step.
+func (s *BuildStep) Clear() {
+ s.ids.Clear()
+}
+
+type buildWrapHandler struct {
+ Next Handler
+}
+
+var _ BuildHandler = (*buildWrapHandler)(nil)
+
+// Implements BuildHandler, converts types and delegates to underlying
+// generic handler.
+func (w buildWrapHandler) HandleBuild(ctx context.Context, in BuildInput) (
+ out BuildOutput, metadata Metadata, err error,
+) {
+ res, metadata, err := w.Next.Handle(ctx, in.Request)
+ return BuildOutput{
+ Result: res,
+ }, metadata, err
+}
+
+type decoratedBuildHandler struct {
+ Next BuildHandler
+ With BuildMiddleware
+}
+
+var _ BuildHandler = (*decoratedBuildHandler)(nil)
+
+func (h decoratedBuildHandler) HandleBuild(ctx context.Context, in BuildInput) (
+ out BuildOutput, metadata Metadata, err error,
+) {
+ return h.With.HandleBuild(ctx, in, h.Next)
+}
+
+// BuildHandlerFunc provides a wrapper around a function to be used as a build middleware handler.
+type BuildHandlerFunc func(context.Context, BuildInput) (BuildOutput, Metadata, error)
+
+// HandleBuild invokes the wrapped function with the provided arguments.
+func (b BuildHandlerFunc) HandleBuild(ctx context.Context, in BuildInput) (BuildOutput, Metadata, error) {
+ return b(ctx, in)
+}
+
+var _ BuildHandler = BuildHandlerFunc(nil)
diff --git a/vendor/github.com/aws/smithy-go/middleware/step_deserialize.go b/vendor/github.com/aws/smithy-go/middleware/step_deserialize.go
new file mode 100644
index 000000000000..44860721571c
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/step_deserialize.go
@@ -0,0 +1,217 @@
+package middleware
+
+import (
+ "context"
+)
+
+// DeserializeInput provides the input parameters for the DeserializeInput to
+// consume. DeserializeMiddleware should not modify the Request, and instead
+// forward it along to the next DeserializeHandler.
+type DeserializeInput struct {
+ Request interface{}
+}
+
+// DeserializeOutput provides the result returned by the next
+// DeserializeHandler. The DeserializeMiddleware should deserialize the
+// RawResponse into a Result that can be consumed by middleware higher up in
+// the stack.
+type DeserializeOutput struct {
+ RawResponse interface{}
+ Result interface{}
+}
+
+// DeserializeHandler provides the interface for the next handler the
+// DeserializeMiddleware will call in the middleware chain.
+type DeserializeHandler interface {
+ HandleDeserialize(ctx context.Context, in DeserializeInput) (
+ out DeserializeOutput, metadata Metadata, err error,
+ )
+}
+
+// DeserializeMiddleware provides the interface for middleware specific to the
+// serialize step. Delegates to the next DeserializeHandler for further
+// processing.
+type DeserializeMiddleware interface {
+ // ID returns a unique ID for the middleware in the DeserializeStep. The step does not
+ // allow duplicate IDs.
+ ID() string
+
+ // HandleDeserialize invokes the middleware behavior which must delegate to the next handler
+ // for the middleware chain to continue. The method must return a result or
+ // error to its caller.
+ HandleDeserialize(ctx context.Context, in DeserializeInput, next DeserializeHandler) (
+ out DeserializeOutput, metadata Metadata, err error,
+ )
+}
+
+// DeserializeMiddlewareFunc returns a DeserializeMiddleware with the unique ID
+// provided, and the func to be invoked.
+func DeserializeMiddlewareFunc(id string, fn func(context.Context, DeserializeInput, DeserializeHandler) (DeserializeOutput, Metadata, error)) DeserializeMiddleware {
+ return deserializeMiddlewareFunc{
+ id: id,
+ fn: fn,
+ }
+}
+
+type deserializeMiddlewareFunc struct {
+ // Unique ID for the middleware.
+ id string
+
+ // Middleware function to be called.
+ fn func(context.Context, DeserializeInput, DeserializeHandler) (
+ DeserializeOutput, Metadata, error,
+ )
+}
+
+// ID returns the unique ID for the middleware.
+func (s deserializeMiddlewareFunc) ID() string { return s.id }
+
+// HandleDeserialize invokes the middleware Fn.
+func (s deserializeMiddlewareFunc) HandleDeserialize(ctx context.Context, in DeserializeInput, next DeserializeHandler) (
+ out DeserializeOutput, metadata Metadata, err error,
+) {
+ return s.fn(ctx, in, next)
+}
+
+var _ DeserializeMiddleware = (deserializeMiddlewareFunc{})
+
+// DeserializeStep provides the ordered grouping of DeserializeMiddleware to be
+// invoked on a handler.
+type DeserializeStep struct {
+ ids *orderedIDs
+}
+
+// NewDeserializeStep returns a DeserializeStep ready to have middleware for
+// initialization added to it.
+func NewDeserializeStep() *DeserializeStep {
+ return &DeserializeStep{
+ ids: newOrderedIDs(),
+ }
+}
+
+var _ Middleware = (*DeserializeStep)(nil)
+
+// ID returns the unique ID of the step as a middleware.
+func (s *DeserializeStep) ID() string {
+ return "Deserialize stack step"
+}
+
+// HandleMiddleware invokes the middleware by decorating the next handler
+// provided. Returns the result of the middleware and handler being invoked.
+//
+// Implements Middleware interface.
+func (s *DeserializeStep) HandleMiddleware(ctx context.Context, in interface{}, next Handler) (
+ out interface{}, metadata Metadata, err error,
+) {
+ order := s.ids.GetOrder()
+
+ var h DeserializeHandler = deserializeWrapHandler{Next: next}
+ for i := len(order) - 1; i >= 0; i-- {
+ h = decoratedDeserializeHandler{
+ Next: h,
+ With: order[i].(DeserializeMiddleware),
+ }
+ }
+
+ sIn := DeserializeInput{
+ Request: in,
+ }
+
+ res, metadata, err := h.HandleDeserialize(ctx, sIn)
+ return res.Result, metadata, err
+}
+
+// Get retrieves the middleware identified by id. If the middleware is not present, returns false.
+func (s *DeserializeStep) Get(id string) (DeserializeMiddleware, bool) {
+ get, ok := s.ids.Get(id)
+ if !ok {
+ return nil, false
+ }
+ return get.(DeserializeMiddleware), ok
+}
+
+// Add injects the middleware to the relative position of the middleware group.
+// Returns an error if the middleware already exists.
+func (s *DeserializeStep) Add(m DeserializeMiddleware, pos RelativePosition) error {
+ return s.ids.Add(m, pos)
+}
+
+// Insert injects the middleware relative to an existing middleware ID.
+// Returns error if the original middleware does not exist, or the middleware
+// being added already exists.
+func (s *DeserializeStep) Insert(m DeserializeMiddleware, relativeTo string, pos RelativePosition) error {
+ return s.ids.Insert(m, relativeTo, pos)
+}
+
+// Swap removes the middleware by id, replacing it with the new middleware.
+// Returns the middleware removed, or error if the middleware to be removed
+// doesn't exist.
+func (s *DeserializeStep) Swap(id string, m DeserializeMiddleware) (DeserializeMiddleware, error) {
+ removed, err := s.ids.Swap(id, m)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(DeserializeMiddleware), nil
+}
+
+// Remove removes the middleware by id. Returns error if the middleware
+// doesn't exist.
+func (s *DeserializeStep) Remove(id string) (DeserializeMiddleware, error) {
+ removed, err := s.ids.Remove(id)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(DeserializeMiddleware), nil
+}
+
+// List returns a list of the middleware in the step.
+func (s *DeserializeStep) List() []string {
+ return s.ids.List()
+}
+
+// Clear removes all middleware in the step.
+func (s *DeserializeStep) Clear() {
+ s.ids.Clear()
+}
+
+type deserializeWrapHandler struct {
+ Next Handler
+}
+
+var _ DeserializeHandler = (*deserializeWrapHandler)(nil)
+
+// HandleDeserialize implements DeserializeHandler, converts types and delegates to underlying
+// generic handler.
+func (w deserializeWrapHandler) HandleDeserialize(ctx context.Context, in DeserializeInput) (
+ out DeserializeOutput, metadata Metadata, err error,
+) {
+ resp, metadata, err := w.Next.Handle(ctx, in.Request)
+ return DeserializeOutput{
+ RawResponse: resp,
+ }, metadata, err
+}
+
+type decoratedDeserializeHandler struct {
+ Next DeserializeHandler
+ With DeserializeMiddleware
+}
+
+var _ DeserializeHandler = (*decoratedDeserializeHandler)(nil)
+
+func (h decoratedDeserializeHandler) HandleDeserialize(ctx context.Context, in DeserializeInput) (
+ out DeserializeOutput, metadata Metadata, err error,
+) {
+ return h.With.HandleDeserialize(ctx, in, h.Next)
+}
+
+// DeserializeHandlerFunc provides a wrapper around a function to be used as a deserialize middleware handler.
+type DeserializeHandlerFunc func(context.Context, DeserializeInput) (DeserializeOutput, Metadata, error)
+
+// HandleDeserialize invokes the wrapped function with the given arguments.
+func (d DeserializeHandlerFunc) HandleDeserialize(ctx context.Context, in DeserializeInput) (DeserializeOutput, Metadata, error) {
+ return d(ctx, in)
+}
+
+var _ DeserializeHandler = DeserializeHandlerFunc(nil)
diff --git a/vendor/github.com/aws/smithy-go/middleware/step_finalize.go b/vendor/github.com/aws/smithy-go/middleware/step_finalize.go
new file mode 100644
index 000000000000..065e3885de92
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/step_finalize.go
@@ -0,0 +1,211 @@
+package middleware
+
+import "context"
+
+// FinalizeInput provides the input parameters for the FinalizeMiddleware to
+// consume. FinalizeMiddleware may modify the Request value before forwarding
+// the FinalizeInput along to the next next FinalizeHandler.
+type FinalizeInput struct {
+ Request interface{}
+}
+
+// FinalizeOutput provides the result returned by the next FinalizeHandler.
+type FinalizeOutput struct {
+ Result interface{}
+}
+
+// FinalizeHandler provides the interface for the next handler the
+// FinalizeMiddleware will call in the middleware chain.
+type FinalizeHandler interface {
+ HandleFinalize(ctx context.Context, in FinalizeInput) (
+ out FinalizeOutput, metadata Metadata, err error,
+ )
+}
+
+// FinalizeMiddleware provides the interface for middleware specific to the
+// serialize step. Delegates to the next FinalizeHandler for further
+// processing.
+type FinalizeMiddleware interface {
+ // ID returns a unique ID for the middleware in the FinalizeStep. The step does not
+ // allow duplicate IDs.
+ ID() string
+
+ // HandleFinalize invokes the middleware behavior which must delegate to the next handler
+ // for the middleware chain to continue. The method must return a result or
+ // error to its caller.
+ HandleFinalize(ctx context.Context, in FinalizeInput, next FinalizeHandler) (
+ out FinalizeOutput, metadata Metadata, err error,
+ )
+}
+
+// FinalizeMiddlewareFunc returns a FinalizeMiddleware with the unique ID
+// provided, and the func to be invoked.
+func FinalizeMiddlewareFunc(id string, fn func(context.Context, FinalizeInput, FinalizeHandler) (FinalizeOutput, Metadata, error)) FinalizeMiddleware {
+ return finalizeMiddlewareFunc{
+ id: id,
+ fn: fn,
+ }
+}
+
+type finalizeMiddlewareFunc struct {
+ // Unique ID for the middleware.
+ id string
+
+ // Middleware function to be called.
+ fn func(context.Context, FinalizeInput, FinalizeHandler) (
+ FinalizeOutput, Metadata, error,
+ )
+}
+
+// ID returns the unique ID for the middleware.
+func (s finalizeMiddlewareFunc) ID() string { return s.id }
+
+// HandleFinalize invokes the middleware Fn.
+func (s finalizeMiddlewareFunc) HandleFinalize(ctx context.Context, in FinalizeInput, next FinalizeHandler) (
+ out FinalizeOutput, metadata Metadata, err error,
+) {
+ return s.fn(ctx, in, next)
+}
+
+var _ FinalizeMiddleware = (finalizeMiddlewareFunc{})
+
+// FinalizeStep provides the ordered grouping of FinalizeMiddleware to be
+// invoked on a handler.
+type FinalizeStep struct {
+ ids *orderedIDs
+}
+
+// NewFinalizeStep returns a FinalizeStep ready to have middleware for
+// initialization added to it.
+func NewFinalizeStep() *FinalizeStep {
+ return &FinalizeStep{
+ ids: newOrderedIDs(),
+ }
+}
+
+var _ Middleware = (*FinalizeStep)(nil)
+
+// ID returns the unique id of the step as a middleware.
+func (s *FinalizeStep) ID() string {
+ return "Finalize stack step"
+}
+
+// HandleMiddleware invokes the middleware by decorating the next handler
+// provided. Returns the result of the middleware and handler being invoked.
+//
+// Implements Middleware interface.
+func (s *FinalizeStep) HandleMiddleware(ctx context.Context, in interface{}, next Handler) (
+ out interface{}, metadata Metadata, err error,
+) {
+ order := s.ids.GetOrder()
+
+ var h FinalizeHandler = finalizeWrapHandler{Next: next}
+ for i := len(order) - 1; i >= 0; i-- {
+ h = decoratedFinalizeHandler{
+ Next: h,
+ With: order[i].(FinalizeMiddleware),
+ }
+ }
+
+ sIn := FinalizeInput{
+ Request: in,
+ }
+
+ res, metadata, err := h.HandleFinalize(ctx, sIn)
+ return res.Result, metadata, err
+}
+
+// Get retrieves the middleware identified by id. If the middleware is not present, returns false.
+func (s *FinalizeStep) Get(id string) (FinalizeMiddleware, bool) {
+ get, ok := s.ids.Get(id)
+ if !ok {
+ return nil, false
+ }
+ return get.(FinalizeMiddleware), ok
+}
+
+// Add injects the middleware to the relative position of the middleware group.
+// Returns an error if the middleware already exists.
+func (s *FinalizeStep) Add(m FinalizeMiddleware, pos RelativePosition) error {
+ return s.ids.Add(m, pos)
+}
+
+// Insert injects the middleware relative to an existing middleware ID.
+// Returns error if the original middleware does not exist, or the middleware
+// being added already exists.
+func (s *FinalizeStep) Insert(m FinalizeMiddleware, relativeTo string, pos RelativePosition) error {
+ return s.ids.Insert(m, relativeTo, pos)
+}
+
+// Swap removes the middleware by id, replacing it with the new middleware.
+// Returns the middleware removed, or error if the middleware to be removed
+// doesn't exist.
+func (s *FinalizeStep) Swap(id string, m FinalizeMiddleware) (FinalizeMiddleware, error) {
+ removed, err := s.ids.Swap(id, m)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(FinalizeMiddleware), nil
+}
+
+// Remove removes the middleware by id. Returns error if the middleware
+// doesn't exist.
+func (s *FinalizeStep) Remove(id string) (FinalizeMiddleware, error) {
+ removed, err := s.ids.Remove(id)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(FinalizeMiddleware), nil
+}
+
+// List returns a list of the middleware in the step.
+func (s *FinalizeStep) List() []string {
+ return s.ids.List()
+}
+
+// Clear removes all middleware in the step.
+func (s *FinalizeStep) Clear() {
+ s.ids.Clear()
+}
+
+type finalizeWrapHandler struct {
+ Next Handler
+}
+
+var _ FinalizeHandler = (*finalizeWrapHandler)(nil)
+
+// HandleFinalize implements FinalizeHandler, converts types and delegates to underlying
+// generic handler.
+func (w finalizeWrapHandler) HandleFinalize(ctx context.Context, in FinalizeInput) (
+ out FinalizeOutput, metadata Metadata, err error,
+) {
+ res, metadata, err := w.Next.Handle(ctx, in.Request)
+ return FinalizeOutput{
+ Result: res,
+ }, metadata, err
+}
+
+type decoratedFinalizeHandler struct {
+ Next FinalizeHandler
+ With FinalizeMiddleware
+}
+
+var _ FinalizeHandler = (*decoratedFinalizeHandler)(nil)
+
+func (h decoratedFinalizeHandler) HandleFinalize(ctx context.Context, in FinalizeInput) (
+ out FinalizeOutput, metadata Metadata, err error,
+) {
+ return h.With.HandleFinalize(ctx, in, h.Next)
+}
+
+// FinalizeHandlerFunc provides a wrapper around a function to be used as a finalize middleware handler.
+type FinalizeHandlerFunc func(context.Context, FinalizeInput) (FinalizeOutput, Metadata, error)
+
+// HandleFinalize invokes the wrapped function with the given arguments.
+func (f FinalizeHandlerFunc) HandleFinalize(ctx context.Context, in FinalizeInput) (FinalizeOutput, Metadata, error) {
+ return f(ctx, in)
+}
+
+var _ FinalizeHandler = FinalizeHandlerFunc(nil)
diff --git a/vendor/github.com/aws/smithy-go/middleware/step_initialize.go b/vendor/github.com/aws/smithy-go/middleware/step_initialize.go
new file mode 100644
index 000000000000..fe359144d243
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/step_initialize.go
@@ -0,0 +1,211 @@
+package middleware
+
+import "context"
+
+// InitializeInput wraps the input parameters for the InitializeMiddlewares to
+// consume. InitializeMiddleware may modify the parameter value before
+// forwarding it along to the next InitializeHandler.
+type InitializeInput struct {
+ Parameters interface{}
+}
+
+// InitializeOutput provides the result returned by the next InitializeHandler.
+type InitializeOutput struct {
+ Result interface{}
+}
+
+// InitializeHandler provides the interface for the next handler the
+// InitializeMiddleware will call in the middleware chain.
+type InitializeHandler interface {
+ HandleInitialize(ctx context.Context, in InitializeInput) (
+ out InitializeOutput, metadata Metadata, err error,
+ )
+}
+
+// InitializeMiddleware provides the interface for middleware specific to the
+// initialize step. Delegates to the next InitializeHandler for further
+// processing.
+type InitializeMiddleware interface {
+ // ID returns a unique ID for the middleware in the InitializeStep. The step does not
+ // allow duplicate IDs.
+ ID() string
+
+ // HandleInitialize invokes the middleware behavior which must delegate to the next handler
+ // for the middleware chain to continue. The method must return a result or
+ // error to its caller.
+ HandleInitialize(ctx context.Context, in InitializeInput, next InitializeHandler) (
+ out InitializeOutput, metadata Metadata, err error,
+ )
+}
+
+// InitializeMiddlewareFunc returns a InitializeMiddleware with the unique ID provided,
+// and the func to be invoked.
+func InitializeMiddlewareFunc(id string, fn func(context.Context, InitializeInput, InitializeHandler) (InitializeOutput, Metadata, error)) InitializeMiddleware {
+ return initializeMiddlewareFunc{
+ id: id,
+ fn: fn,
+ }
+}
+
+type initializeMiddlewareFunc struct {
+ // Unique ID for the middleware.
+ id string
+
+ // Middleware function to be called.
+ fn func(context.Context, InitializeInput, InitializeHandler) (
+ InitializeOutput, Metadata, error,
+ )
+}
+
+// ID returns the unique ID for the middleware.
+func (s initializeMiddlewareFunc) ID() string { return s.id }
+
+// HandleInitialize invokes the middleware Fn.
+func (s initializeMiddlewareFunc) HandleInitialize(ctx context.Context, in InitializeInput, next InitializeHandler) (
+ out InitializeOutput, metadata Metadata, err error,
+) {
+ return s.fn(ctx, in, next)
+}
+
+var _ InitializeMiddleware = (initializeMiddlewareFunc{})
+
+// InitializeStep provides the ordered grouping of InitializeMiddleware to be
+// invoked on a handler.
+type InitializeStep struct {
+ ids *orderedIDs
+}
+
+// NewInitializeStep returns an InitializeStep ready to have middleware for
+// initialization added to it.
+func NewInitializeStep() *InitializeStep {
+ return &InitializeStep{
+ ids: newOrderedIDs(),
+ }
+}
+
+var _ Middleware = (*InitializeStep)(nil)
+
+// ID returns the unique ID of the step as a middleware.
+func (s *InitializeStep) ID() string {
+ return "Initialize stack step"
+}
+
+// HandleMiddleware invokes the middleware by decorating the next handler
+// provided. Returns the result of the middleware and handler being invoked.
+//
+// Implements Middleware interface.
+func (s *InitializeStep) HandleMiddleware(ctx context.Context, in interface{}, next Handler) (
+ out interface{}, metadata Metadata, err error,
+) {
+ order := s.ids.GetOrder()
+
+ var h InitializeHandler = initializeWrapHandler{Next: next}
+ for i := len(order) - 1; i >= 0; i-- {
+ h = decoratedInitializeHandler{
+ Next: h,
+ With: order[i].(InitializeMiddleware),
+ }
+ }
+
+ sIn := InitializeInput{
+ Parameters: in,
+ }
+
+ res, metadata, err := h.HandleInitialize(ctx, sIn)
+ return res.Result, metadata, err
+}
+
+// Get retrieves the middleware identified by id. If the middleware is not present, returns false.
+func (s *InitializeStep) Get(id string) (InitializeMiddleware, bool) {
+ get, ok := s.ids.Get(id)
+ if !ok {
+ return nil, false
+ }
+ return get.(InitializeMiddleware), ok
+}
+
+// Add injects the middleware to the relative position of the middleware group.
+// Returns an error if the middleware already exists.
+func (s *InitializeStep) Add(m InitializeMiddleware, pos RelativePosition) error {
+ return s.ids.Add(m, pos)
+}
+
+// Insert injects the middleware relative to an existing middleware ID.
+// Returns error if the original middleware does not exist, or the middleware
+// being added already exists.
+func (s *InitializeStep) Insert(m InitializeMiddleware, relativeTo string, pos RelativePosition) error {
+ return s.ids.Insert(m, relativeTo, pos)
+}
+
+// Swap removes the middleware by id, replacing it with the new middleware.
+// Returns the middleware removed, or error if the middleware to be removed
+// doesn't exist.
+func (s *InitializeStep) Swap(id string, m InitializeMiddleware) (InitializeMiddleware, error) {
+ removed, err := s.ids.Swap(id, m)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(InitializeMiddleware), nil
+}
+
+// Remove removes the middleware by id. Returns error if the middleware
+// doesn't exist.
+func (s *InitializeStep) Remove(id string) (InitializeMiddleware, error) {
+ removed, err := s.ids.Remove(id)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(InitializeMiddleware), nil
+}
+
+// List returns a list of the middleware in the step.
+func (s *InitializeStep) List() []string {
+ return s.ids.List()
+}
+
+// Clear removes all middleware in the step.
+func (s *InitializeStep) Clear() {
+ s.ids.Clear()
+}
+
+type initializeWrapHandler struct {
+ Next Handler
+}
+
+var _ InitializeHandler = (*initializeWrapHandler)(nil)
+
+// HandleInitialize implements InitializeHandler, converts types and delegates to underlying
+// generic handler.
+func (w initializeWrapHandler) HandleInitialize(ctx context.Context, in InitializeInput) (
+ out InitializeOutput, metadata Metadata, err error,
+) {
+ res, metadata, err := w.Next.Handle(ctx, in.Parameters)
+ return InitializeOutput{
+ Result: res,
+ }, metadata, err
+}
+
+type decoratedInitializeHandler struct {
+ Next InitializeHandler
+ With InitializeMiddleware
+}
+
+var _ InitializeHandler = (*decoratedInitializeHandler)(nil)
+
+func (h decoratedInitializeHandler) HandleInitialize(ctx context.Context, in InitializeInput) (
+ out InitializeOutput, metadata Metadata, err error,
+) {
+ return h.With.HandleInitialize(ctx, in, h.Next)
+}
+
+// InitializeHandlerFunc provides a wrapper around a function to be used as an initialize middleware handler.
+type InitializeHandlerFunc func(context.Context, InitializeInput) (InitializeOutput, Metadata, error)
+
+// HandleInitialize calls the wrapped function with the provided arguments.
+func (i InitializeHandlerFunc) HandleInitialize(ctx context.Context, in InitializeInput) (InitializeOutput, Metadata, error) {
+ return i(ctx, in)
+}
+
+var _ InitializeHandler = InitializeHandlerFunc(nil)
diff --git a/vendor/github.com/aws/smithy-go/middleware/step_serialize.go b/vendor/github.com/aws/smithy-go/middleware/step_serialize.go
new file mode 100644
index 000000000000..114bafcedea8
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/middleware/step_serialize.go
@@ -0,0 +1,219 @@
+package middleware
+
+import "context"
+
+// SerializeInput provides the input parameters for the SerializeMiddleware to
+// consume. SerializeMiddleware may modify the Request value before forwarding
+// SerializeInput along to the next SerializeHandler. The Parameters member
+// should not be modified by SerializeMiddleware, InitializeMiddleware should
+// be responsible for modifying the provided Parameter value.
+type SerializeInput struct {
+ Parameters interface{}
+ Request interface{}
+}
+
+// SerializeOutput provides the result returned by the next SerializeHandler.
+type SerializeOutput struct {
+ Result interface{}
+}
+
+// SerializeHandler provides the interface for the next handler the
+// SerializeMiddleware will call in the middleware chain.
+type SerializeHandler interface {
+ HandleSerialize(ctx context.Context, in SerializeInput) (
+ out SerializeOutput, metadata Metadata, err error,
+ )
+}
+
+// SerializeMiddleware provides the interface for middleware specific to the
+// serialize step. Delegates to the next SerializeHandler for further
+// processing.
+type SerializeMiddleware interface {
+ // ID returns a unique ID for the middleware in the SerializeStep. The step does not
+ // allow duplicate IDs.
+ ID() string
+
+ // HandleSerialize invokes the middleware behavior which must delegate to the next handler
+ // for the middleware chain to continue. The method must return a result or
+ // error to its caller.
+ HandleSerialize(ctx context.Context, in SerializeInput, next SerializeHandler) (
+ out SerializeOutput, metadata Metadata, err error,
+ )
+}
+
+// SerializeMiddlewareFunc returns a SerializeMiddleware with the unique ID
+// provided, and the func to be invoked.
+func SerializeMiddlewareFunc(id string, fn func(context.Context, SerializeInput, SerializeHandler) (SerializeOutput, Metadata, error)) SerializeMiddleware {
+ return serializeMiddlewareFunc{
+ id: id,
+ fn: fn,
+ }
+}
+
+type serializeMiddlewareFunc struct {
+ // Unique ID for the middleware.
+ id string
+
+ // Middleware function to be called.
+ fn func(context.Context, SerializeInput, SerializeHandler) (
+ SerializeOutput, Metadata, error,
+ )
+}
+
+// ID returns the unique ID for the middleware.
+func (s serializeMiddlewareFunc) ID() string { return s.id }
+
+// HandleSerialize invokes the middleware Fn.
+func (s serializeMiddlewareFunc) HandleSerialize(ctx context.Context, in SerializeInput, next SerializeHandler) (
+ out SerializeOutput, metadata Metadata, err error,
+) {
+ return s.fn(ctx, in, next)
+}
+
+var _ SerializeMiddleware = (serializeMiddlewareFunc{})
+
+// SerializeStep provides the ordered grouping of SerializeMiddleware to be
+// invoked on a handler.
+type SerializeStep struct {
+ newRequest func() interface{}
+ ids *orderedIDs
+}
+
+// NewSerializeStep returns a SerializeStep ready to have middleware for
+// initialization added to it. The newRequest func parameter is used to
+// initialize the transport specific request for the stack SerializeStep to
+// serialize the input parameters into.
+func NewSerializeStep(newRequest func() interface{}) *SerializeStep {
+ return &SerializeStep{
+ ids: newOrderedIDs(),
+ newRequest: newRequest,
+ }
+}
+
+var _ Middleware = (*SerializeStep)(nil)
+
+// ID returns the unique ID of the step as a middleware.
+func (s *SerializeStep) ID() string {
+ return "Serialize stack step"
+}
+
+// HandleMiddleware invokes the middleware by decorating the next handler
+// provided. Returns the result of the middleware and handler being invoked.
+//
+// Implements Middleware interface.
+func (s *SerializeStep) HandleMiddleware(ctx context.Context, in interface{}, next Handler) (
+ out interface{}, metadata Metadata, err error,
+) {
+ order := s.ids.GetOrder()
+
+ var h SerializeHandler = serializeWrapHandler{Next: next}
+ for i := len(order) - 1; i >= 0; i-- {
+ h = decoratedSerializeHandler{
+ Next: h,
+ With: order[i].(SerializeMiddleware),
+ }
+ }
+
+ sIn := SerializeInput{
+ Parameters: in,
+ Request: s.newRequest(),
+ }
+
+ res, metadata, err := h.HandleSerialize(ctx, sIn)
+ return res.Result, metadata, err
+}
+
+// Get retrieves the middleware identified by id. If the middleware is not present, returns false.
+func (s *SerializeStep) Get(id string) (SerializeMiddleware, bool) {
+ get, ok := s.ids.Get(id)
+ if !ok {
+ return nil, false
+ }
+ return get.(SerializeMiddleware), ok
+}
+
+// Add injects the middleware to the relative position of the middleware group.
+// Returns an error if the middleware already exists.
+func (s *SerializeStep) Add(m SerializeMiddleware, pos RelativePosition) error {
+ return s.ids.Add(m, pos)
+}
+
+// Insert injects the middleware relative to an existing middleware ID.
+// Returns error if the original middleware does not exist, or the middleware
+// being added already exists.
+func (s *SerializeStep) Insert(m SerializeMiddleware, relativeTo string, pos RelativePosition) error {
+ return s.ids.Insert(m, relativeTo, pos)
+}
+
+// Swap removes the middleware by id, replacing it with the new middleware.
+// Returns the middleware removed, or error if the middleware to be removed
+// doesn't exist.
+func (s *SerializeStep) Swap(id string, m SerializeMiddleware) (SerializeMiddleware, error) {
+ removed, err := s.ids.Swap(id, m)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(SerializeMiddleware), nil
+}
+
+// Remove removes the middleware by id. Returns error if the middleware
+// doesn't exist.
+func (s *SerializeStep) Remove(id string) (SerializeMiddleware, error) {
+ removed, err := s.ids.Remove(id)
+ if err != nil {
+ return nil, err
+ }
+
+ return removed.(SerializeMiddleware), nil
+}
+
+// List returns a list of the middleware in the step.
+func (s *SerializeStep) List() []string {
+ return s.ids.List()
+}
+
+// Clear removes all middleware in the step.
+func (s *SerializeStep) Clear() {
+ s.ids.Clear()
+}
+
+type serializeWrapHandler struct {
+ Next Handler
+}
+
+var _ SerializeHandler = (*serializeWrapHandler)(nil)
+
+// Implements SerializeHandler, converts types and delegates to underlying
+// generic handler.
+func (w serializeWrapHandler) HandleSerialize(ctx context.Context, in SerializeInput) (
+ out SerializeOutput, metadata Metadata, err error,
+) {
+ res, metadata, err := w.Next.Handle(ctx, in.Request)
+ return SerializeOutput{
+ Result: res,
+ }, metadata, err
+}
+
+type decoratedSerializeHandler struct {
+ Next SerializeHandler
+ With SerializeMiddleware
+}
+
+var _ SerializeHandler = (*decoratedSerializeHandler)(nil)
+
+func (h decoratedSerializeHandler) HandleSerialize(ctx context.Context, in SerializeInput) (
+ out SerializeOutput, metadata Metadata, err error,
+) {
+ return h.With.HandleSerialize(ctx, in, h.Next)
+}
+
+// SerializeHandlerFunc provides a wrapper around a function to be used as a serialize middleware handler.
+type SerializeHandlerFunc func(context.Context, SerializeInput) (SerializeOutput, Metadata, error)
+
+// HandleSerialize calls the wrapped function with the provided arguments.
+func (s SerializeHandlerFunc) HandleSerialize(ctx context.Context, in SerializeInput) (SerializeOutput, Metadata, error) {
+ return s(ctx, in)
+}
+
+var _ SerializeHandler = SerializeHandlerFunc(nil)
diff --git a/vendor/github.com/aws/smithy-go/ptr/doc.go b/vendor/github.com/aws/smithy-go/ptr/doc.go
new file mode 100644
index 000000000000..bc1f6996161a
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/ptr/doc.go
@@ -0,0 +1,5 @@
+// Package ptr provides utilities for converting scalar literal type values to and from pointers inline.
+package ptr
+
+//go:generate go run -tags codegen generate.go
+//go:generate gofmt -w -s .
diff --git a/vendor/github.com/aws/smithy-go/ptr/from_ptr.go b/vendor/github.com/aws/smithy-go/ptr/from_ptr.go
new file mode 100644
index 000000000000..5d5a9b3b0a8d
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/ptr/from_ptr.go
@@ -0,0 +1,566 @@
+// Code generated by smithy-go/ptr/generate.go DO NOT EDIT.
+package ptr
+
+import (
+ "time"
+)
+
+// ToBool returns bool value dereferenced if the passed
+// in pointer was not nil. Returns a bool zero value if the
+// pointer was nil.
+func ToBool(p *bool) (v bool) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToBoolSlice returns a slice of bool values, that are
+// dereferenced if the passed in pointer was not nil. Returns a bool
+// zero value if the pointer was nil.
+func ToBoolSlice(vs []*bool) []bool {
+ ps := make([]bool, len(vs))
+ for i, v := range vs {
+ ps[i] = ToBool(v)
+ }
+
+ return ps
+}
+
+// ToBoolMap returns a map of bool values, that are
+// dereferenced if the passed in pointer was not nil. The bool
+// zero value is used if the pointer was nil.
+func ToBoolMap(vs map[string]*bool) map[string]bool {
+ ps := make(map[string]bool, len(vs))
+ for k, v := range vs {
+ ps[k] = ToBool(v)
+ }
+
+ return ps
+}
+
+// ToByte returns byte value dereferenced if the passed
+// in pointer was not nil. Returns a byte zero value if the
+// pointer was nil.
+func ToByte(p *byte) (v byte) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToByteSlice returns a slice of byte values, that are
+// dereferenced if the passed in pointer was not nil. Returns a byte
+// zero value if the pointer was nil.
+func ToByteSlice(vs []*byte) []byte {
+ ps := make([]byte, len(vs))
+ for i, v := range vs {
+ ps[i] = ToByte(v)
+ }
+
+ return ps
+}
+
+// ToByteMap returns a map of byte values, that are
+// dereferenced if the passed in pointer was not nil. The byte
+// zero value is used if the pointer was nil.
+func ToByteMap(vs map[string]*byte) map[string]byte {
+ ps := make(map[string]byte, len(vs))
+ for k, v := range vs {
+ ps[k] = ToByte(v)
+ }
+
+ return ps
+}
+
+// ToString returns string value dereferenced if the passed
+// in pointer was not nil. Returns a string zero value if the
+// pointer was nil.
+func ToString(p *string) (v string) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToStringSlice returns a slice of string values, that are
+// dereferenced if the passed in pointer was not nil. Returns a string
+// zero value if the pointer was nil.
+func ToStringSlice(vs []*string) []string {
+ ps := make([]string, len(vs))
+ for i, v := range vs {
+ ps[i] = ToString(v)
+ }
+
+ return ps
+}
+
+// ToStringMap returns a map of string values, that are
+// dereferenced if the passed in pointer was not nil. The string
+// zero value is used if the pointer was nil.
+func ToStringMap(vs map[string]*string) map[string]string {
+ ps := make(map[string]string, len(vs))
+ for k, v := range vs {
+ ps[k] = ToString(v)
+ }
+
+ return ps
+}
+
+// ToInt returns int value dereferenced if the passed
+// in pointer was not nil. Returns a int zero value if the
+// pointer was nil.
+func ToInt(p *int) (v int) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToIntSlice returns a slice of int values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int
+// zero value if the pointer was nil.
+func ToIntSlice(vs []*int) []int {
+ ps := make([]int, len(vs))
+ for i, v := range vs {
+ ps[i] = ToInt(v)
+ }
+
+ return ps
+}
+
+// ToIntMap returns a map of int values, that are
+// dereferenced if the passed in pointer was not nil. The int
+// zero value is used if the pointer was nil.
+func ToIntMap(vs map[string]*int) map[string]int {
+ ps := make(map[string]int, len(vs))
+ for k, v := range vs {
+ ps[k] = ToInt(v)
+ }
+
+ return ps
+}
+
+// ToInt8 returns int8 value dereferenced if the passed
+// in pointer was not nil. Returns a int8 zero value if the
+// pointer was nil.
+func ToInt8(p *int8) (v int8) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToInt8Slice returns a slice of int8 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int8
+// zero value if the pointer was nil.
+func ToInt8Slice(vs []*int8) []int8 {
+ ps := make([]int8, len(vs))
+ for i, v := range vs {
+ ps[i] = ToInt8(v)
+ }
+
+ return ps
+}
+
+// ToInt8Map returns a map of int8 values, that are
+// dereferenced if the passed in pointer was not nil. The int8
+// zero value is used if the pointer was nil.
+func ToInt8Map(vs map[string]*int8) map[string]int8 {
+ ps := make(map[string]int8, len(vs))
+ for k, v := range vs {
+ ps[k] = ToInt8(v)
+ }
+
+ return ps
+}
+
+// ToInt16 returns int16 value dereferenced if the passed
+// in pointer was not nil. Returns a int16 zero value if the
+// pointer was nil.
+func ToInt16(p *int16) (v int16) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToInt16Slice returns a slice of int16 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int16
+// zero value if the pointer was nil.
+func ToInt16Slice(vs []*int16) []int16 {
+ ps := make([]int16, len(vs))
+ for i, v := range vs {
+ ps[i] = ToInt16(v)
+ }
+
+ return ps
+}
+
+// ToInt16Map returns a map of int16 values, that are
+// dereferenced if the passed in pointer was not nil. The int16
+// zero value is used if the pointer was nil.
+func ToInt16Map(vs map[string]*int16) map[string]int16 {
+ ps := make(map[string]int16, len(vs))
+ for k, v := range vs {
+ ps[k] = ToInt16(v)
+ }
+
+ return ps
+}
+
+// ToInt32 returns int32 value dereferenced if the passed
+// in pointer was not nil. Returns a int32 zero value if the
+// pointer was nil.
+func ToInt32(p *int32) (v int32) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToInt32Slice returns a slice of int32 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int32
+// zero value if the pointer was nil.
+func ToInt32Slice(vs []*int32) []int32 {
+ ps := make([]int32, len(vs))
+ for i, v := range vs {
+ ps[i] = ToInt32(v)
+ }
+
+ return ps
+}
+
+// ToInt32Map returns a map of int32 values, that are
+// dereferenced if the passed in pointer was not nil. The int32
+// zero value is used if the pointer was nil.
+func ToInt32Map(vs map[string]*int32) map[string]int32 {
+ ps := make(map[string]int32, len(vs))
+ for k, v := range vs {
+ ps[k] = ToInt32(v)
+ }
+
+ return ps
+}
+
+// ToInt64 returns int64 value dereferenced if the passed
+// in pointer was not nil. Returns a int64 zero value if the
+// pointer was nil.
+func ToInt64(p *int64) (v int64) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToInt64Slice returns a slice of int64 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a int64
+// zero value if the pointer was nil.
+func ToInt64Slice(vs []*int64) []int64 {
+ ps := make([]int64, len(vs))
+ for i, v := range vs {
+ ps[i] = ToInt64(v)
+ }
+
+ return ps
+}
+
+// ToInt64Map returns a map of int64 values, that are
+// dereferenced if the passed in pointer was not nil. The int64
+// zero value is used if the pointer was nil.
+func ToInt64Map(vs map[string]*int64) map[string]int64 {
+ ps := make(map[string]int64, len(vs))
+ for k, v := range vs {
+ ps[k] = ToInt64(v)
+ }
+
+ return ps
+}
+
+// ToUint returns uint value dereferenced if the passed
+// in pointer was not nil. Returns a uint zero value if the
+// pointer was nil.
+func ToUint(p *uint) (v uint) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToUintSlice returns a slice of uint values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint
+// zero value if the pointer was nil.
+func ToUintSlice(vs []*uint) []uint {
+ ps := make([]uint, len(vs))
+ for i, v := range vs {
+ ps[i] = ToUint(v)
+ }
+
+ return ps
+}
+
+// ToUintMap returns a map of uint values, that are
+// dereferenced if the passed in pointer was not nil. The uint
+// zero value is used if the pointer was nil.
+func ToUintMap(vs map[string]*uint) map[string]uint {
+ ps := make(map[string]uint, len(vs))
+ for k, v := range vs {
+ ps[k] = ToUint(v)
+ }
+
+ return ps
+}
+
+// ToUint8 returns uint8 value dereferenced if the passed
+// in pointer was not nil. Returns a uint8 zero value if the
+// pointer was nil.
+func ToUint8(p *uint8) (v uint8) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToUint8Slice returns a slice of uint8 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint8
+// zero value if the pointer was nil.
+func ToUint8Slice(vs []*uint8) []uint8 {
+ ps := make([]uint8, len(vs))
+ for i, v := range vs {
+ ps[i] = ToUint8(v)
+ }
+
+ return ps
+}
+
+// ToUint8Map returns a map of uint8 values, that are
+// dereferenced if the passed in pointer was not nil. The uint8
+// zero value is used if the pointer was nil.
+func ToUint8Map(vs map[string]*uint8) map[string]uint8 {
+ ps := make(map[string]uint8, len(vs))
+ for k, v := range vs {
+ ps[k] = ToUint8(v)
+ }
+
+ return ps
+}
+
+// ToUint16 returns uint16 value dereferenced if the passed
+// in pointer was not nil. Returns a uint16 zero value if the
+// pointer was nil.
+func ToUint16(p *uint16) (v uint16) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToUint16Slice returns a slice of uint16 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint16
+// zero value if the pointer was nil.
+func ToUint16Slice(vs []*uint16) []uint16 {
+ ps := make([]uint16, len(vs))
+ for i, v := range vs {
+ ps[i] = ToUint16(v)
+ }
+
+ return ps
+}
+
+// ToUint16Map returns a map of uint16 values, that are
+// dereferenced if the passed in pointer was not nil. The uint16
+// zero value is used if the pointer was nil.
+func ToUint16Map(vs map[string]*uint16) map[string]uint16 {
+ ps := make(map[string]uint16, len(vs))
+ for k, v := range vs {
+ ps[k] = ToUint16(v)
+ }
+
+ return ps
+}
+
+// ToUint32 returns uint32 value dereferenced if the passed
+// in pointer was not nil. Returns a uint32 zero value if the
+// pointer was nil.
+func ToUint32(p *uint32) (v uint32) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToUint32Slice returns a slice of uint32 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint32
+// zero value if the pointer was nil.
+func ToUint32Slice(vs []*uint32) []uint32 {
+ ps := make([]uint32, len(vs))
+ for i, v := range vs {
+ ps[i] = ToUint32(v)
+ }
+
+ return ps
+}
+
+// ToUint32Map returns a map of uint32 values, that are
+// dereferenced if the passed in pointer was not nil. The uint32
+// zero value is used if the pointer was nil.
+func ToUint32Map(vs map[string]*uint32) map[string]uint32 {
+ ps := make(map[string]uint32, len(vs))
+ for k, v := range vs {
+ ps[k] = ToUint32(v)
+ }
+
+ return ps
+}
+
+// ToUint64 returns uint64 value dereferenced if the passed
+// in pointer was not nil. Returns a uint64 zero value if the
+// pointer was nil.
+func ToUint64(p *uint64) (v uint64) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToUint64Slice returns a slice of uint64 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a uint64
+// zero value if the pointer was nil.
+func ToUint64Slice(vs []*uint64) []uint64 {
+ ps := make([]uint64, len(vs))
+ for i, v := range vs {
+ ps[i] = ToUint64(v)
+ }
+
+ return ps
+}
+
+// ToUint64Map returns a map of uint64 values, that are
+// dereferenced if the passed in pointer was not nil. The uint64
+// zero value is used if the pointer was nil.
+func ToUint64Map(vs map[string]*uint64) map[string]uint64 {
+ ps := make(map[string]uint64, len(vs))
+ for k, v := range vs {
+ ps[k] = ToUint64(v)
+ }
+
+ return ps
+}
+
+// ToFloat32 returns float32 value dereferenced if the passed
+// in pointer was not nil. Returns a float32 zero value if the
+// pointer was nil.
+func ToFloat32(p *float32) (v float32) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToFloat32Slice returns a slice of float32 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a float32
+// zero value if the pointer was nil.
+func ToFloat32Slice(vs []*float32) []float32 {
+ ps := make([]float32, len(vs))
+ for i, v := range vs {
+ ps[i] = ToFloat32(v)
+ }
+
+ return ps
+}
+
+// ToFloat32Map returns a map of float32 values, that are
+// dereferenced if the passed in pointer was not nil. The float32
+// zero value is used if the pointer was nil.
+func ToFloat32Map(vs map[string]*float32) map[string]float32 {
+ ps := make(map[string]float32, len(vs))
+ for k, v := range vs {
+ ps[k] = ToFloat32(v)
+ }
+
+ return ps
+}
+
+// ToFloat64 returns float64 value dereferenced if the passed
+// in pointer was not nil. Returns a float64 zero value if the
+// pointer was nil.
+func ToFloat64(p *float64) (v float64) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToFloat64Slice returns a slice of float64 values, that are
+// dereferenced if the passed in pointer was not nil. Returns a float64
+// zero value if the pointer was nil.
+func ToFloat64Slice(vs []*float64) []float64 {
+ ps := make([]float64, len(vs))
+ for i, v := range vs {
+ ps[i] = ToFloat64(v)
+ }
+
+ return ps
+}
+
+// ToFloat64Map returns a map of float64 values, that are
+// dereferenced if the passed in pointer was not nil. The float64
+// zero value is used if the pointer was nil.
+func ToFloat64Map(vs map[string]*float64) map[string]float64 {
+ ps := make(map[string]float64, len(vs))
+ for k, v := range vs {
+ ps[k] = ToFloat64(v)
+ }
+
+ return ps
+}
+
+// ToTime returns time.Time value dereferenced if the passed
+// in pointer was not nil. Returns a time.Time zero value if the
+// pointer was nil.
+func ToTime(p *time.Time) (v time.Time) {
+ if p == nil {
+ return v
+ }
+
+ return *p
+}
+
+// ToTimeSlice returns a slice of time.Time values, that are
+// dereferenced if the passed in pointer was not nil. Returns a time.Time
+// zero value if the pointer was nil.
+func ToTimeSlice(vs []*time.Time) []time.Time {
+ ps := make([]time.Time, len(vs))
+ for i, v := range vs {
+ ps[i] = ToTime(v)
+ }
+
+ return ps
+}
+
+// ToTimeMap returns a map of time.Time values, that are
+// dereferenced if the passed in pointer was not nil. The time.Time
+// zero value is used if the pointer was nil.
+func ToTimeMap(vs map[string]*time.Time) map[string]time.Time {
+ ps := make(map[string]time.Time, len(vs))
+ for k, v := range vs {
+ ps[k] = ToTime(v)
+ }
+
+ return ps
+}
diff --git a/vendor/github.com/aws/smithy-go/ptr/gen_scalars.go b/vendor/github.com/aws/smithy-go/ptr/gen_scalars.go
new file mode 100644
index 000000000000..0c5352c88242
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/ptr/gen_scalars.go
@@ -0,0 +1,82 @@
+//go:build codegen
+// +build codegen
+
+package ptr
+
+import "strings"
+
+func GetScalars() Scalars {
+ return Scalars{
+ {Type: "bool"},
+ {Type: "byte"},
+ {Type: "string"},
+ {Type: "int"},
+ {Type: "int8"},
+ {Type: "int16"},
+ {Type: "int32"},
+ {Type: "int64"},
+ {Type: "uint"},
+ {Type: "uint8"},
+ {Type: "uint16"},
+ {Type: "uint32"},
+ {Type: "uint64"},
+ {Type: "float32"},
+ {Type: "float64"},
+ {Type: "Time", Import: &Import{Path: "time"}},
+ }
+}
+
+// Import provides the import path and optional alias
+type Import struct {
+ Path string
+ Alias string
+}
+
+// Package returns the Go package name for the import. Returns alias if set.
+func (i Import) Package() string {
+ if v := i.Alias; len(v) != 0 {
+ return v
+ }
+
+ if v := i.Path; len(v) != 0 {
+ parts := strings.Split(v, "/")
+ pkg := parts[len(parts)-1]
+ return pkg
+ }
+
+ return ""
+}
+
+// Scalar provides the definition of a type to generate pointer utilities for.
+type Scalar struct {
+ Type string
+ Import *Import
+}
+
+// Name returns the exported function name for the type.
+func (t Scalar) Name() string {
+ return strings.Title(t.Type)
+}
+
+// Symbol returns the scalar's Go symbol with path if needed.
+func (t Scalar) Symbol() string {
+ if t.Import != nil {
+ return t.Import.Package() + "." + t.Type
+ }
+ return t.Type
+}
+
+// Scalars is a list of scalars.
+type Scalars []Scalar
+
+// Imports returns all imports for the scalars.
+func (ts Scalars) Imports() []*Import {
+ imports := []*Import{}
+ for _, t := range ts {
+ if v := t.Import; v != nil {
+ imports = append(imports, v)
+ }
+ }
+
+ return imports
+}
diff --git a/vendor/github.com/aws/smithy-go/ptr/to_ptr.go b/vendor/github.com/aws/smithy-go/ptr/to_ptr.go
new file mode 100644
index 000000000000..a57d13015f0c
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/ptr/to_ptr.go
@@ -0,0 +1,470 @@
+// Code generated by smithy-go/ptr/generate.go DO NOT EDIT.
+package ptr
+
+import (
+ "time"
+)
+
+// Bool returns a pointer value for the bool value passed in.
+func Bool(v bool) *bool {
+ return &v
+}
+
+// BoolSlice returns a slice of bool pointers from the values
+// passed in.
+func BoolSlice(vs []bool) []*bool {
+ ps := make([]*bool, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// BoolMap returns a map of bool pointers from the values
+// passed in.
+func BoolMap(vs map[string]bool) map[string]*bool {
+ ps := make(map[string]*bool, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Byte returns a pointer value for the byte value passed in.
+func Byte(v byte) *byte {
+ return &v
+}
+
+// ByteSlice returns a slice of byte pointers from the values
+// passed in.
+func ByteSlice(vs []byte) []*byte {
+ ps := make([]*byte, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// ByteMap returns a map of byte pointers from the values
+// passed in.
+func ByteMap(vs map[string]byte) map[string]*byte {
+ ps := make(map[string]*byte, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// String returns a pointer value for the string value passed in.
+func String(v string) *string {
+ return &v
+}
+
+// StringSlice returns a slice of string pointers from the values
+// passed in.
+func StringSlice(vs []string) []*string {
+ ps := make([]*string, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// StringMap returns a map of string pointers from the values
+// passed in.
+func StringMap(vs map[string]string) map[string]*string {
+ ps := make(map[string]*string, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Int returns a pointer value for the int value passed in.
+func Int(v int) *int {
+ return &v
+}
+
+// IntSlice returns a slice of int pointers from the values
+// passed in.
+func IntSlice(vs []int) []*int {
+ ps := make([]*int, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// IntMap returns a map of int pointers from the values
+// passed in.
+func IntMap(vs map[string]int) map[string]*int {
+ ps := make(map[string]*int, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Int8 returns a pointer value for the int8 value passed in.
+func Int8(v int8) *int8 {
+ return &v
+}
+
+// Int8Slice returns a slice of int8 pointers from the values
+// passed in.
+func Int8Slice(vs []int8) []*int8 {
+ ps := make([]*int8, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Int8Map returns a map of int8 pointers from the values
+// passed in.
+func Int8Map(vs map[string]int8) map[string]*int8 {
+ ps := make(map[string]*int8, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Int16 returns a pointer value for the int16 value passed in.
+func Int16(v int16) *int16 {
+ return &v
+}
+
+// Int16Slice returns a slice of int16 pointers from the values
+// passed in.
+func Int16Slice(vs []int16) []*int16 {
+ ps := make([]*int16, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Int16Map returns a map of int16 pointers from the values
+// passed in.
+func Int16Map(vs map[string]int16) map[string]*int16 {
+ ps := make(map[string]*int16, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Int32 returns a pointer value for the int32 value passed in.
+func Int32(v int32) *int32 {
+ return &v
+}
+
+// Int32Slice returns a slice of int32 pointers from the values
+// passed in.
+func Int32Slice(vs []int32) []*int32 {
+ ps := make([]*int32, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Int32Map returns a map of int32 pointers from the values
+// passed in.
+func Int32Map(vs map[string]int32) map[string]*int32 {
+ ps := make(map[string]*int32, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Int64 returns a pointer value for the int64 value passed in.
+func Int64(v int64) *int64 {
+ return &v
+}
+
+// Int64Slice returns a slice of int64 pointers from the values
+// passed in.
+func Int64Slice(vs []int64) []*int64 {
+ ps := make([]*int64, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Int64Map returns a map of int64 pointers from the values
+// passed in.
+func Int64Map(vs map[string]int64) map[string]*int64 {
+ ps := make(map[string]*int64, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Uint returns a pointer value for the uint value passed in.
+func Uint(v uint) *uint {
+ return &v
+}
+
+// UintSlice returns a slice of uint pointers from the values
+// passed in.
+func UintSlice(vs []uint) []*uint {
+ ps := make([]*uint, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// UintMap returns a map of uint pointers from the values
+// passed in.
+func UintMap(vs map[string]uint) map[string]*uint {
+ ps := make(map[string]*uint, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Uint8 returns a pointer value for the uint8 value passed in.
+func Uint8(v uint8) *uint8 {
+ return &v
+}
+
+// Uint8Slice returns a slice of uint8 pointers from the values
+// passed in.
+func Uint8Slice(vs []uint8) []*uint8 {
+ ps := make([]*uint8, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Uint8Map returns a map of uint8 pointers from the values
+// passed in.
+func Uint8Map(vs map[string]uint8) map[string]*uint8 {
+ ps := make(map[string]*uint8, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Uint16 returns a pointer value for the uint16 value passed in.
+func Uint16(v uint16) *uint16 {
+ return &v
+}
+
+// Uint16Slice returns a slice of uint16 pointers from the values
+// passed in.
+func Uint16Slice(vs []uint16) []*uint16 {
+ ps := make([]*uint16, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Uint16Map returns a map of uint16 pointers from the values
+// passed in.
+func Uint16Map(vs map[string]uint16) map[string]*uint16 {
+ ps := make(map[string]*uint16, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Uint32 returns a pointer value for the uint32 value passed in.
+func Uint32(v uint32) *uint32 {
+ return &v
+}
+
+// Uint32Slice returns a slice of uint32 pointers from the values
+// passed in.
+func Uint32Slice(vs []uint32) []*uint32 {
+ ps := make([]*uint32, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Uint32Map returns a map of uint32 pointers from the values
+// passed in.
+func Uint32Map(vs map[string]uint32) map[string]*uint32 {
+ ps := make(map[string]*uint32, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Uint64 returns a pointer value for the uint64 value passed in.
+func Uint64(v uint64) *uint64 {
+ return &v
+}
+
+// Uint64Slice returns a slice of uint64 pointers from the values
+// passed in.
+func Uint64Slice(vs []uint64) []*uint64 {
+ ps := make([]*uint64, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Uint64Map returns a map of uint64 pointers from the values
+// passed in.
+func Uint64Map(vs map[string]uint64) map[string]*uint64 {
+ ps := make(map[string]*uint64, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Float32 returns a pointer value for the float32 value passed in.
+func Float32(v float32) *float32 {
+ return &v
+}
+
+// Float32Slice returns a slice of float32 pointers from the values
+// passed in.
+func Float32Slice(vs []float32) []*float32 {
+ ps := make([]*float32, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Float32Map returns a map of float32 pointers from the values
+// passed in.
+func Float32Map(vs map[string]float32) map[string]*float32 {
+ ps := make(map[string]*float32, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Float64 returns a pointer value for the float64 value passed in.
+func Float64(v float64) *float64 {
+ return &v
+}
+
+// Float64Slice returns a slice of float64 pointers from the values
+// passed in.
+func Float64Slice(vs []float64) []*float64 {
+ ps := make([]*float64, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// Float64Map returns a map of float64 pointers from the values
+// passed in.
+func Float64Map(vs map[string]float64) map[string]*float64 {
+ ps := make(map[string]*float64, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
+
+// Time returns a pointer value for the time.Time value passed in.
+func Time(v time.Time) *time.Time {
+ return &v
+}
+
+// TimeSlice returns a slice of time.Time pointers from the values
+// passed in.
+func TimeSlice(vs []time.Time) []*time.Time {
+ ps := make([]*time.Time, len(vs))
+ for i, v := range vs {
+ vv := v
+ ps[i] = &vv
+ }
+
+ return ps
+}
+
+// TimeMap returns a map of time.Time pointers from the values
+// passed in.
+func TimeMap(vs map[string]time.Time) map[string]*time.Time {
+ ps := make(map[string]*time.Time, len(vs))
+ for k, v := range vs {
+ vv := v
+ ps[k] = &vv
+ }
+
+ return ps
+}
diff --git a/vendor/github.com/aws/smithy-go/rand/doc.go b/vendor/github.com/aws/smithy-go/rand/doc.go
new file mode 100644
index 000000000000..f8b25d56259e
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/rand/doc.go
@@ -0,0 +1,3 @@
+// Package rand provides utilities for creating and working with random value
+// generators.
+package rand
diff --git a/vendor/github.com/aws/smithy-go/rand/rand.go b/vendor/github.com/aws/smithy-go/rand/rand.go
new file mode 100644
index 000000000000..9c479f62b59f
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/rand/rand.go
@@ -0,0 +1,31 @@
+package rand
+
+import (
+ "crypto/rand"
+ "fmt"
+ "io"
+ "math/big"
+)
+
+func init() {
+ Reader = rand.Reader
+}
+
+// Reader provides a random reader that can reset during testing.
+var Reader io.Reader
+
+// Int63n returns a int64 between zero and value of max, read from an io.Reader source.
+func Int63n(reader io.Reader, max int64) (int64, error) {
+ bi, err := rand.Int(reader, big.NewInt(max))
+ if err != nil {
+ return 0, fmt.Errorf("failed to read random value, %w", err)
+ }
+
+ return bi.Int64(), nil
+}
+
+// CryptoRandInt63n returns a random int64 between zero and value of max
+// obtained from the crypto rand source.
+func CryptoRandInt63n(max int64) (int64, error) {
+ return Int63n(Reader, max)
+}
diff --git a/vendor/github.com/aws/smithy-go/rand/uuid.go b/vendor/github.com/aws/smithy-go/rand/uuid.go
new file mode 100644
index 000000000000..dc81cbc68ac0
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/rand/uuid.go
@@ -0,0 +1,87 @@
+package rand
+
+import (
+ "encoding/hex"
+ "io"
+)
+
+const dash byte = '-'
+
+// UUIDIdempotencyToken provides a utility to get idempotency tokens in the
+// UUID format.
+type UUIDIdempotencyToken struct {
+ uuid *UUID
+}
+
+// NewUUIDIdempotencyToken returns a idempotency token provider returning
+// tokens in the UUID random format using the reader provided.
+func NewUUIDIdempotencyToken(r io.Reader) *UUIDIdempotencyToken {
+ return &UUIDIdempotencyToken{uuid: NewUUID(r)}
+}
+
+// GetIdempotencyToken returns a random UUID value for Idempotency token.
+func (u UUIDIdempotencyToken) GetIdempotencyToken() (string, error) {
+ return u.uuid.GetUUID()
+}
+
+// UUID provides computing random UUID version 4 values from a random source
+// reader.
+type UUID struct {
+ randSrc io.Reader
+}
+
+// NewUUID returns an initialized UUID value that can be used to retrieve
+// random UUID version 4 values.
+func NewUUID(r io.Reader) *UUID {
+ return &UUID{randSrc: r}
+}
+
+// GetUUID returns a random UUID version 4 string representation sourced from the random reader the
+// UUID was created with. Returns an error if unable to compute the UUID.
+func (r *UUID) GetUUID() (string, error) {
+ var b [16]byte
+ if _, err := io.ReadFull(r.randSrc, b[:]); err != nil {
+ return "", err
+ }
+ r.makeUUIDv4(b[:])
+ return format(b), nil
+}
+
+// GetBytes returns a byte slice containing a random UUID version 4 sourced from the random reader the
+// UUID was created with. Returns an error if unable to compute the UUID.
+func (r *UUID) GetBytes() (u []byte, err error) {
+ u = make([]byte, 16)
+ if _, err = io.ReadFull(r.randSrc, u); err != nil {
+ return u, err
+ }
+ r.makeUUIDv4(u)
+ return u, nil
+}
+
+func (r *UUID) makeUUIDv4(u []byte) {
+ // 13th character is "4"
+ u[6] = (u[6] & 0x0f) | 0x40 // Version 4
+ // 17th character is "8", "9", "a", or "b"
+ u[8] = (u[8] & 0x3f) | 0x80 // Variant most significant bits are 10x where x can be either 1 or 0
+}
+
+// Format returns the canonical text representation of a UUID.
+// This implementation is optimized to not use fmt.
+// Example: 82e42f16-b6cc-4d5b-95f5-d403c4befd3d
+func format(u [16]byte) string {
+ // https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_4_.28random.29
+
+ var scratch [36]byte
+
+ hex.Encode(scratch[:8], u[0:4])
+ scratch[8] = dash
+ hex.Encode(scratch[9:13], u[4:6])
+ scratch[13] = dash
+ hex.Encode(scratch[14:18], u[6:8])
+ scratch[18] = dash
+ hex.Encode(scratch[19:23], u[8:10])
+ scratch[23] = dash
+ hex.Encode(scratch[24:], u[10:])
+
+ return string(scratch[:])
+}
diff --git a/vendor/github.com/aws/smithy-go/time/time.go b/vendor/github.com/aws/smithy-go/time/time.go
new file mode 100644
index 000000000000..b552a09f8a8b
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/time/time.go
@@ -0,0 +1,134 @@
+package time
+
+import (
+ "context"
+ "fmt"
+ "math/big"
+ "strings"
+ "time"
+)
+
+const (
+ // dateTimeFormat is a IMF-fixdate formatted RFC3339 section 5.6
+ dateTimeFormatInput = "2006-01-02T15:04:05.999999999Z"
+ dateTimeFormatInputNoZ = "2006-01-02T15:04:05.999999999"
+ dateTimeFormatOutput = "2006-01-02T15:04:05.999Z"
+
+ // httpDateFormat is a date time defined by RFC 7231#section-7.1.1.1
+ // IMF-fixdate with no UTC offset.
+ httpDateFormat = "Mon, 02 Jan 2006 15:04:05 GMT"
+ // Additional formats needed for compatibility.
+ httpDateFormatSingleDigitDay = "Mon, _2 Jan 2006 15:04:05 GMT"
+ httpDateFormatSingleDigitDayTwoDigitYear = "Mon, _2 Jan 06 15:04:05 GMT"
+)
+
+var millisecondFloat = big.NewFloat(1e3)
+
+// FormatDateTime formats value as a date-time, (RFC3339 section 5.6)
+//
+// Example: 1985-04-12T23:20:50.52Z
+func FormatDateTime(value time.Time) string {
+ return value.UTC().Format(dateTimeFormatOutput)
+}
+
+// ParseDateTime parses a string as a date-time, (RFC3339 section 5.6)
+//
+// Example: 1985-04-12T23:20:50.52Z
+func ParseDateTime(value string) (time.Time, error) {
+ return tryParse(value,
+ dateTimeFormatInput,
+ dateTimeFormatInputNoZ,
+ time.RFC3339Nano,
+ time.RFC3339,
+ )
+}
+
+// FormatHTTPDate formats value as a http-date, (RFC 7231#section-7.1.1.1 IMF-fixdate)
+//
+// Example: Tue, 29 Apr 2014 18:30:38 GMT
+func FormatHTTPDate(value time.Time) string {
+ return value.UTC().Format(httpDateFormat)
+}
+
+// ParseHTTPDate parses a string as a http-date, (RFC 7231#section-7.1.1.1 IMF-fixdate)
+//
+// Example: Tue, 29 Apr 2014 18:30:38 GMT
+func ParseHTTPDate(value string) (time.Time, error) {
+ return tryParse(value,
+ httpDateFormat,
+ httpDateFormatSingleDigitDay,
+ httpDateFormatSingleDigitDayTwoDigitYear,
+ time.RFC850,
+ time.ANSIC,
+ )
+}
+
+// FormatEpochSeconds returns value as a Unix time in seconds with with decimal precision
+//
+// Example: 1515531081.123
+func FormatEpochSeconds(value time.Time) float64 {
+ ms := value.UnixNano() / int64(time.Millisecond)
+ return float64(ms) / 1e3
+}
+
+// ParseEpochSeconds returns value as a Unix time in seconds with with decimal precision
+//
+// Example: 1515531081.123
+func ParseEpochSeconds(value float64) time.Time {
+ f := big.NewFloat(value)
+ f = f.Mul(f, millisecondFloat)
+ i, _ := f.Int64()
+ // Offset to `UTC` because time.Unix returns the time value based on system
+ // local setting.
+ return time.Unix(0, i*1e6).UTC()
+}
+
+func tryParse(v string, formats ...string) (time.Time, error) {
+ var errs parseErrors
+ for _, f := range formats {
+ t, err := time.Parse(f, v)
+ if err != nil {
+ errs = append(errs, parseError{
+ Format: f,
+ Err: err,
+ })
+ continue
+ }
+ return t, nil
+ }
+
+ return time.Time{}, fmt.Errorf("unable to parse time string, %w", errs)
+}
+
+type parseErrors []parseError
+
+func (es parseErrors) Error() string {
+ var s strings.Builder
+ for _, e := range es {
+ fmt.Fprintf(&s, "\n * %q: %v", e.Format, e.Err)
+ }
+
+ return "parse errors:" + s.String()
+}
+
+type parseError struct {
+ Format string
+ Err error
+}
+
+// SleepWithContext will wait for the timer duration to expire, or until the context
+// is canceled. Whichever happens first. If the context is canceled the
+// Context's error will be returned.
+func SleepWithContext(ctx context.Context, dur time.Duration) error {
+ t := time.NewTimer(dur)
+ defer t.Stop()
+
+ select {
+ case <-t.C:
+ break
+ case <-ctx.Done():
+ return ctx.Err()
+ }
+
+ return nil
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/checksum_middleware.go b/vendor/github.com/aws/smithy-go/transport/http/checksum_middleware.go
new file mode 100644
index 000000000000..2ec7cbaee5fd
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/checksum_middleware.go
@@ -0,0 +1,65 @@
+package http
+
+import (
+ "context"
+ "fmt"
+
+ "github.com/aws/smithy-go/middleware"
+)
+
+const contentMD5Header = "Content-Md5"
+
+// contentMD5Checksum provides a middleware to compute and set
+// content-md5 checksum for a http request
+type contentMD5Checksum struct {
+}
+
+// AddContentChecksumMiddleware adds checksum middleware to middleware's
+// build step.
+func AddContentChecksumMiddleware(stack *middleware.Stack) error {
+ // This middleware must be executed before request body is set.
+ return stack.Build.Add(&contentMD5Checksum{}, middleware.Before)
+}
+
+// ID returns the identifier for the checksum middleware
+func (m *contentMD5Checksum) ID() string { return "ContentChecksum" }
+
+// HandleBuild adds behavior to compute md5 checksum and add content-md5 header
+// on http request
+func (m *contentMD5Checksum) HandleBuild(
+ ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler,
+) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown request type %T", req)
+ }
+
+ // if Content-MD5 header is already present, return
+ if v := req.Header.Get(contentMD5Header); len(v) != 0 {
+ return next.HandleBuild(ctx, in)
+ }
+
+ // fetch the request stream.
+ stream := req.GetStream()
+ // compute checksum if payload is explicit
+ if stream != nil {
+ v, err := computeMD5Checksum(stream)
+ if err != nil {
+ return out, metadata, fmt.Errorf("error computing md5 checksum, %w", err)
+ }
+
+ // reset the request stream
+ if err := req.RewindStream(); err != nil {
+ return out, metadata, fmt.Errorf(
+ "error rewinding request stream after computing md5 checksum, %w", err)
+ }
+
+ // set the 'Content-MD5' header
+ req.Header.Set(contentMD5Header, string(v))
+ }
+
+ // set md5 header value
+ return next.HandleBuild(ctx, in)
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/client.go b/vendor/github.com/aws/smithy-go/transport/http/client.go
new file mode 100644
index 000000000000..e691c69bf444
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/client.go
@@ -0,0 +1,120 @@
+package http
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+
+ smithy "github.com/aws/smithy-go"
+ "github.com/aws/smithy-go/middleware"
+)
+
+// ClientDo provides the interface for custom HTTP client implementations.
+type ClientDo interface {
+ Do(*http.Request) (*http.Response, error)
+}
+
+// ClientDoFunc provides a helper to wrap a function as an HTTP client for
+// round tripping requests.
+type ClientDoFunc func(*http.Request) (*http.Response, error)
+
+// Do will invoke the underlying func, returning the result.
+func (fn ClientDoFunc) Do(r *http.Request) (*http.Response, error) {
+ return fn(r)
+}
+
+// ClientHandler wraps a client that implements the HTTP Do method. Standard
+// implementation is http.Client.
+type ClientHandler struct {
+ client ClientDo
+}
+
+// NewClientHandler returns an initialized middleware handler for the client.
+func NewClientHandler(client ClientDo) ClientHandler {
+ return ClientHandler{
+ client: client,
+ }
+}
+
+// Handle implements the middleware Handler interface, that will invoke the
+// underlying HTTP client. Requires the input to be a Smithy *Request. Returns
+// a smithy *Response, or error if the request failed.
+func (c ClientHandler) Handle(ctx context.Context, input interface{}) (
+ out interface{}, metadata middleware.Metadata, err error,
+) {
+ req, ok := input.(*Request)
+ if !ok {
+ return nil, metadata, fmt.Errorf("expect Smithy http.Request value as input, got unsupported type %T", input)
+ }
+
+ builtRequest := req.Build(ctx)
+ if err := ValidateEndpointHost(builtRequest.Host); err != nil {
+ return nil, metadata, err
+ }
+
+ resp, err := c.client.Do(builtRequest)
+ if resp == nil {
+ // Ensure a http response value is always present to prevent unexpected
+ // panics.
+ resp = &http.Response{
+ Header: http.Header{},
+ Body: http.NoBody,
+ }
+ }
+ if err != nil {
+ err = &RequestSendError{Err: err}
+
+ // Override the error with a context canceled error, if that was canceled.
+ select {
+ case <-ctx.Done():
+ err = &smithy.CanceledError{Err: ctx.Err()}
+ default:
+ }
+ }
+
+ // HTTP RoundTripper *should* close the request body. But this may not happen in a timely manner.
+ // So instead Smithy *Request Build wraps the body to be sent in a safe closer that will clear the
+ // stream reference so that it can be safely reused.
+ if builtRequest.Body != nil {
+ _ = builtRequest.Body.Close()
+ }
+
+ return &Response{Response: resp}, metadata, err
+}
+
+// RequestSendError provides a generic request transport error. This error
+// should wrap errors making HTTP client requests.
+//
+// The ClientHandler will wrap the HTTP client's error if the client request
+// fails, and did not fail because of context canceled.
+type RequestSendError struct {
+ Err error
+}
+
+// ConnectionError returns that the error is related to not being able to send
+// the request, or receive a response from the service.
+func (e *RequestSendError) ConnectionError() bool {
+ return true
+}
+
+// Unwrap returns the underlying error, if there was one.
+func (e *RequestSendError) Unwrap() error {
+ return e.Err
+}
+
+func (e *RequestSendError) Error() string {
+ return fmt.Sprintf("request send failed, %v", e.Err)
+}
+
+// NopClient provides a client that ignores the request, and returns an empty
+// successful HTTP response value.
+type NopClient struct{}
+
+// Do ignores the request and returns a 200 status empty response.
+func (NopClient) Do(r *http.Request) (*http.Response, error) {
+ return &http.Response{
+ StatusCode: 200,
+ Header: http.Header{},
+ Body: http.NoBody,
+ }, nil
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/doc.go b/vendor/github.com/aws/smithy-go/transport/http/doc.go
new file mode 100644
index 000000000000..07366ac85a88
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/doc.go
@@ -0,0 +1,5 @@
+/*
+Package http provides the HTTP transport client and request/response types
+needed to round trip API operation calls with an service.
+*/
+package http
diff --git a/vendor/github.com/aws/smithy-go/transport/http/headerlist.go b/vendor/github.com/aws/smithy-go/transport/http/headerlist.go
new file mode 100644
index 000000000000..1f91ca84ba64
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/headerlist.go
@@ -0,0 +1,90 @@
+package http
+
+import (
+ "fmt"
+ "strings"
+)
+
+func splitHeaderListValues(vs []string, splitFn func(string) ([]string, error)) ([]string, error) {
+ for i := 0; i < len(vs); i++ {
+ if len(vs[i]) == 0 {
+ continue
+ }
+
+ parts, err := splitFn(vs[i])
+ if err != nil {
+ return nil, err
+ }
+ if len(parts) < 2 {
+ continue
+ }
+
+ tmp := make([]string, len(vs)+len(parts)-1)
+ copy(tmp, vs[:i])
+
+ for j, p := range parts {
+ tmp[i+j] = strings.TrimSpace(p)
+ }
+
+ copy(tmp[i+len(parts):], vs[i+1:])
+
+ vs = tmp
+ i += len(parts) - 1
+ }
+
+ return vs, nil
+}
+
+// SplitHeaderListValues attempts to split the elements of the slice by commas,
+// and return a list of all values separated. Returns error if unable to
+// separate the values.
+func SplitHeaderListValues(vs []string) ([]string, error) {
+ return splitHeaderListValues(vs, commaSplit)
+}
+
+func commaSplit(v string) ([]string, error) {
+ return strings.Split(v, ","), nil
+}
+
+// SplitHTTPDateTimestampHeaderListValues attempts to split the HTTP-Date
+// timestamp values in the slice by commas, and return a list of all values
+// separated. The split is aware of the HTTP-Date timestamp format, and will skip
+// comma within the timestamp value. Returns an error if unable to split the
+// timestamp values.
+func SplitHTTPDateTimestampHeaderListValues(vs []string) ([]string, error) {
+ return splitHeaderListValues(vs, splitHTTPDateHeaderValue)
+}
+
+func splitHTTPDateHeaderValue(v string) ([]string, error) {
+ if n := strings.Count(v, ","); n == 1 {
+ // Skip values with only a single HTTPDate value
+ return nil, nil
+ } else if n == 0 || n%2 == 0 {
+ return nil, fmt.Errorf("invalid timestamp HTTPDate header comma separations, %q", v)
+ }
+
+ var parts []string
+ var i, j int
+
+ var doSplit bool
+ for ; i < len(v); i++ {
+ if v[i] == ',' {
+ if doSplit {
+ doSplit = false
+ parts = append(parts, v[j:i])
+ j = i + 1
+ } else {
+ // Skip the first comma in the timestamp value since that
+ // separates the day from the rest of the timestamp.
+ //
+ // Tue, 17 Dec 2019 23:48:18 GMT
+ doSplit = true
+ }
+ }
+ }
+ if j < len(v) {
+ parts = append(parts, v[j:])
+ }
+
+ return parts, nil
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/host.go b/vendor/github.com/aws/smithy-go/transport/http/host.go
new file mode 100644
index 000000000000..6b290fec030f
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/host.go
@@ -0,0 +1,89 @@
+package http
+
+import (
+ "fmt"
+ "net"
+ "strconv"
+ "strings"
+)
+
+// ValidateEndpointHost validates that the host string passed in is a valid RFC
+// 3986 host. Returns error if the host is not valid.
+func ValidateEndpointHost(host string) error {
+ var errors strings.Builder
+ var hostname string
+ var port string
+ var err error
+
+ if strings.Contains(host, ":") {
+ hostname, port, err = net.SplitHostPort(host)
+ if err != nil {
+ errors.WriteString(fmt.Sprintf("\n endpoint %v, failed to parse, got ", host))
+ errors.WriteString(err.Error())
+ }
+
+ if !ValidPortNumber(port) {
+ errors.WriteString(fmt.Sprintf("port number should be in range [0-65535], got %v", port))
+ }
+ } else {
+ hostname = host
+ }
+
+ labels := strings.Split(hostname, ".")
+ for i, label := range labels {
+ if i == len(labels)-1 && len(label) == 0 {
+ // Allow trailing dot for FQDN hosts.
+ continue
+ }
+
+ if !ValidHostLabel(label) {
+ errors.WriteString("\nendpoint host domain labels must match \"[a-zA-Z0-9-]{1,63}\", but found: ")
+ errors.WriteString(label)
+ }
+ }
+
+ if len(hostname) == 0 && len(port) != 0 {
+ errors.WriteString("\nendpoint host with port must not be empty")
+ }
+
+ if len(hostname) > 255 {
+ errors.WriteString(fmt.Sprintf("\nendpoint host must be less than 255 characters, but was %d", len(hostname)))
+ }
+
+ if len(errors.String()) > 0 {
+ return fmt.Errorf("invalid endpoint host%s", errors.String())
+ }
+ return nil
+}
+
+// ValidPortNumber returns whether the port is valid RFC 3986 port.
+func ValidPortNumber(port string) bool {
+ i, err := strconv.Atoi(port)
+ if err != nil {
+ return false
+ }
+
+ if i < 0 || i > 65535 {
+ return false
+ }
+ return true
+}
+
+// ValidHostLabel returns whether the label is a valid RFC 3986 host abel.
+func ValidHostLabel(label string) bool {
+ if l := len(label); l == 0 || l > 63 {
+ return false
+ }
+ for _, r := range label {
+ switch {
+ case r >= '0' && r <= '9':
+ case r >= 'A' && r <= 'Z':
+ case r >= 'a' && r <= 'z':
+ case r == '-':
+ default:
+ return false
+ }
+ }
+
+ return true
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/internal/io/safe.go b/vendor/github.com/aws/smithy-go/transport/http/internal/io/safe.go
new file mode 100644
index 000000000000..941a8d6b5123
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/internal/io/safe.go
@@ -0,0 +1,75 @@
+package io
+
+import (
+ "io"
+ "sync"
+)
+
+// NewSafeReadCloser returns a new safeReadCloser that wraps readCloser.
+func NewSafeReadCloser(readCloser io.ReadCloser) io.ReadCloser {
+ sr := &safeReadCloser{
+ readCloser: readCloser,
+ }
+
+ if _, ok := readCloser.(io.WriterTo); ok {
+ return &safeWriteToReadCloser{safeReadCloser: sr}
+ }
+
+ return sr
+}
+
+// safeWriteToReadCloser wraps a safeReadCloser but exposes a WriteTo interface implementation. This will panic
+// if the underlying io.ReadClose does not support WriteTo. Use NewSafeReadCloser to ensure the proper handling of this
+// type.
+type safeWriteToReadCloser struct {
+ *safeReadCloser
+}
+
+// WriteTo implements the io.WriteTo interface.
+func (r *safeWriteToReadCloser) WriteTo(w io.Writer) (int64, error) {
+ r.safeReadCloser.mtx.Lock()
+ defer r.safeReadCloser.mtx.Unlock()
+
+ if r.safeReadCloser.closed {
+ return 0, io.EOF
+ }
+
+ return r.safeReadCloser.readCloser.(io.WriterTo).WriteTo(w)
+}
+
+// safeReadCloser wraps a io.ReadCloser and presents an io.ReadCloser interface. When Close is called on safeReadCloser
+// the underlying Close method will be executed, and then the reference to the reader will be dropped. This type
+// is meant to be used with the net/http library which will retain a reference to the request body for the lifetime
+// of a goroutine connection. Wrapping in this manner will ensure that no data race conditions are falsely reported.
+// This type is thread-safe.
+type safeReadCloser struct {
+ readCloser io.ReadCloser
+ closed bool
+ mtx sync.Mutex
+}
+
+// Read reads up to len(p) bytes into p from the underlying read. If the reader is closed io.EOF will be returned.
+func (r *safeReadCloser) Read(p []byte) (n int, err error) {
+ r.mtx.Lock()
+ defer r.mtx.Unlock()
+ if r.closed {
+ return 0, io.EOF
+ }
+
+ return r.readCloser.Read(p)
+}
+
+// Close calls the underlying io.ReadCloser's Close method, removes the reference to the reader, and returns any error
+// reported from Close. Subsequent calls to Close will always return a nil error.
+func (r *safeReadCloser) Close() error {
+ r.mtx.Lock()
+ defer r.mtx.Unlock()
+ if r.closed {
+ return nil
+ }
+
+ r.closed = true
+ rc := r.readCloser
+ r.readCloser = nil
+ return rc.Close()
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/md5_checksum.go b/vendor/github.com/aws/smithy-go/transport/http/md5_checksum.go
new file mode 100644
index 000000000000..5d6a4b23a27a
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/md5_checksum.go
@@ -0,0 +1,25 @@
+package http
+
+import (
+ "crypto/md5"
+ "encoding/base64"
+ "fmt"
+ "io"
+)
+
+// computeMD5Checksum computes base64 md5 checksum of an io.Reader's contents.
+// Returns the byte slice of md5 checksum and an error.
+func computeMD5Checksum(r io.Reader) ([]byte, error) {
+ h := md5.New()
+ // copy errors may be assumed to be from the body.
+ _, err := io.Copy(h, r)
+ if err != nil {
+ return nil, fmt.Errorf("failed to read body: %w", err)
+ }
+
+ // encode the md5 checksum in base64.
+ sum := h.Sum(nil)
+ sum64 := make([]byte, base64.StdEncoding.EncodedLen(len(sum)))
+ base64.StdEncoding.Encode(sum64, sum)
+ return sum64, nil
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/middleware_close_response_body.go b/vendor/github.com/aws/smithy-go/transport/http/middleware_close_response_body.go
new file mode 100644
index 000000000000..1d3b218a1274
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/middleware_close_response_body.go
@@ -0,0 +1,79 @@
+package http
+
+import (
+ "context"
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+ "io"
+ "io/ioutil"
+)
+
+// AddErrorCloseResponseBodyMiddleware adds the middleware to automatically
+// close the response body of an operation request if the request response
+// failed.
+func AddErrorCloseResponseBodyMiddleware(stack *middleware.Stack) error {
+ return stack.Deserialize.Insert(&errorCloseResponseBodyMiddleware{}, "OperationDeserializer", middleware.Before)
+}
+
+type errorCloseResponseBodyMiddleware struct{}
+
+func (*errorCloseResponseBodyMiddleware) ID() string {
+ return "ErrorCloseResponseBody"
+}
+
+func (m *errorCloseResponseBodyMiddleware) HandleDeserialize(
+ ctx context.Context, input middleware.DeserializeInput, next middleware.DeserializeHandler,
+) (
+ output middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err := next.HandleDeserialize(ctx, input)
+ if err != nil {
+ if resp, ok := out.RawResponse.(*Response); ok && resp != nil && resp.Body != nil {
+ // Consume the full body to prevent TCP connection resets on some platforms
+ _, _ = io.Copy(ioutil.Discard, resp.Body)
+ // Do not validate that the response closes successfully.
+ resp.Body.Close()
+ }
+ }
+
+ return out, metadata, err
+}
+
+// AddCloseResponseBodyMiddleware adds the middleware to automatically close
+// the response body of an operation request, after the response had been
+// deserialized.
+func AddCloseResponseBodyMiddleware(stack *middleware.Stack) error {
+ return stack.Deserialize.Insert(&closeResponseBody{}, "OperationDeserializer", middleware.Before)
+}
+
+type closeResponseBody struct{}
+
+func (*closeResponseBody) ID() string {
+ return "CloseResponseBody"
+}
+
+func (m *closeResponseBody) HandleDeserialize(
+ ctx context.Context, input middleware.DeserializeInput, next middleware.DeserializeHandler,
+) (
+ output middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err := next.HandleDeserialize(ctx, input)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ if resp, ok := out.RawResponse.(*Response); ok {
+ // Consume the full body to prevent TCP connection resets on some platforms
+ _, copyErr := io.Copy(ioutil.Discard, resp.Body)
+ if copyErr != nil {
+ middleware.GetLogger(ctx).Logf(logging.Warn, "failed to discard remaining HTTP response body, this may affect connection reuse")
+ }
+
+ closeErr := resp.Body.Close()
+ if closeErr != nil {
+ middleware.GetLogger(ctx).Logf(logging.Warn, "failed to close HTTP response body, this may affect connection reuse")
+ }
+ }
+
+ return out, metadata, err
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/middleware_content_length.go b/vendor/github.com/aws/smithy-go/transport/http/middleware_content_length.go
new file mode 100644
index 000000000000..fa2c827559dd
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/middleware_content_length.go
@@ -0,0 +1,90 @@
+package http
+
+import (
+ "context"
+ "fmt"
+
+ "github.com/aws/smithy-go/middleware"
+)
+
+// ComputeContentLength provides a middleware to set the content-length
+// header for the length of a serialize request body.
+type ComputeContentLength struct {
+}
+
+// AddComputeContentLengthMiddleware adds ComputeContentLength to the middleware
+// stack's Build step.
+func AddComputeContentLengthMiddleware(stack *middleware.Stack) error {
+ return stack.Build.Add(&ComputeContentLength{}, middleware.After)
+}
+
+// ID returns the identifier for the ComputeContentLength.
+func (m *ComputeContentLength) ID() string { return "ComputeContentLength" }
+
+// HandleBuild adds the length of the serialized request to the HTTP header
+// if the length can be determined.
+func (m *ComputeContentLength) HandleBuild(
+ ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler,
+) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown request type %T", req)
+ }
+
+ // do nothing if request content-length was set to 0 or above.
+ if req.ContentLength >= 0 {
+ return next.HandleBuild(ctx, in)
+ }
+
+ // attempt to compute stream length
+ if n, ok, err := req.StreamLength(); err != nil {
+ return out, metadata, fmt.Errorf(
+ "failed getting length of request stream, %w", err)
+ } else if ok {
+ req.ContentLength = n
+ if n == 0 {
+ // If the content length could be determined, and the body is empty
+ // the stream must be cleared to prevent unexpected chunk encoding.
+ req, _ = req.SetStream(nil)
+ in.Request = req
+ }
+ }
+
+ return next.HandleBuild(ctx, in)
+}
+
+// validateContentLength provides a middleware to validate the content-length
+// is valid (greater than zero), for the serialized request payload.
+type validateContentLength struct{}
+
+// ValidateContentLengthHeader adds middleware that validates request content-length
+// is set to value greater than zero.
+func ValidateContentLengthHeader(stack *middleware.Stack) error {
+ return stack.Build.Add(&validateContentLength{}, middleware.After)
+}
+
+// ID returns the identifier for the ComputeContentLength.
+func (m *validateContentLength) ID() string { return "ValidateContentLength" }
+
+// HandleBuild adds the length of the serialized request to the HTTP header
+// if the length can be determined.
+func (m *validateContentLength) HandleBuild(
+ ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler,
+) (
+ out middleware.BuildOutput, metadata middleware.Metadata, err error,
+) {
+ req, ok := in.Request.(*Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown request type %T", req)
+ }
+
+ // if request content-length was set to less than 0, return an error
+ if req.ContentLength < 0 {
+ return out, metadata, fmt.Errorf(
+ "content length for payload is required and must be at least 0")
+ }
+
+ return next.HandleBuild(ctx, in)
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/middleware_headers.go b/vendor/github.com/aws/smithy-go/transport/http/middleware_headers.go
new file mode 100644
index 000000000000..49884e6afb03
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/middleware_headers.go
@@ -0,0 +1,88 @@
+package http
+
+import (
+ "context"
+ "fmt"
+
+ "github.com/aws/smithy-go/middleware"
+)
+
+type headerValue struct {
+ header string
+ value string
+ append bool
+}
+
+type headerValueHelper struct {
+ headerValues []headerValue
+}
+
+func (h *headerValueHelper) addHeaderValue(value headerValue) {
+ h.headerValues = append(h.headerValues, value)
+}
+
+func (h *headerValueHelper) ID() string {
+ return "HTTPHeaderHelper"
+}
+
+func (h *headerValueHelper) HandleBuild(ctx context.Context, in middleware.BuildInput, next middleware.BuildHandler) (out middleware.BuildOutput, metadata middleware.Metadata, err error) {
+ req, ok := in.Request.(*Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in.Request)
+ }
+
+ for _, value := range h.headerValues {
+ if value.append {
+ req.Header.Add(value.header, value.value)
+ } else {
+ req.Header.Set(value.header, value.value)
+ }
+ }
+
+ return next.HandleBuild(ctx, in)
+}
+
+func getOrAddHeaderValueHelper(stack *middleware.Stack) (*headerValueHelper, error) {
+ id := (*headerValueHelper)(nil).ID()
+ m, ok := stack.Build.Get(id)
+ if !ok {
+ m = &headerValueHelper{}
+ err := stack.Build.Add(m, middleware.After)
+ if err != nil {
+ return nil, err
+ }
+ }
+
+ requestUserAgent, ok := m.(*headerValueHelper)
+ if !ok {
+ return nil, fmt.Errorf("%T for %s middleware did not match expected type", m, id)
+ }
+
+ return requestUserAgent, nil
+}
+
+// AddHeaderValue returns a stack mutator that adds the header value pair to header.
+// Appends to any existing values if present.
+func AddHeaderValue(header string, value string) func(stack *middleware.Stack) error {
+ return func(stack *middleware.Stack) error {
+ helper, err := getOrAddHeaderValueHelper(stack)
+ if err != nil {
+ return err
+ }
+ helper.addHeaderValue(headerValue{header: header, value: value, append: true})
+ return nil
+ }
+}
+
+// SetHeaderValue returns a stack mutator that adds the header value pair to header.
+// Replaces any existing values if present.
+func SetHeaderValue(header string, value string) func(stack *middleware.Stack) error {
+ return func(stack *middleware.Stack) error {
+ helper, err := getOrAddHeaderValueHelper(stack)
+ if err != nil {
+ return err
+ }
+ helper.addHeaderValue(headerValue{header: header, value: value, append: false})
+ return nil
+ }
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/middleware_http_logging.go b/vendor/github.com/aws/smithy-go/transport/http/middleware_http_logging.go
new file mode 100644
index 000000000000..d5909b0a242a
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/middleware_http_logging.go
@@ -0,0 +1,75 @@
+package http
+
+import (
+ "context"
+ "fmt"
+ "net/http/httputil"
+
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+)
+
+// RequestResponseLogger is a deserialize middleware that will log the request and response HTTP messages and optionally
+// their respective bodies. Will not perform any logging if none of the options are set.
+type RequestResponseLogger struct {
+ LogRequest bool
+ LogRequestWithBody bool
+
+ LogResponse bool
+ LogResponseWithBody bool
+}
+
+// ID is the middleware identifier.
+func (r *RequestResponseLogger) ID() string {
+ return "RequestResponseLogger"
+}
+
+// HandleDeserialize will log the request and response HTTP messages if configured accordingly.
+func (r *RequestResponseLogger) HandleDeserialize(
+ ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler,
+) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ logger := middleware.GetLogger(ctx)
+
+ if r.LogRequest || r.LogRequestWithBody {
+ smithyRequest, ok := in.Request.(*Request)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", in)
+ }
+
+ rc := smithyRequest.Build(ctx)
+ reqBytes, err := httputil.DumpRequestOut(rc, r.LogRequestWithBody)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ logger.Logf(logging.Debug, "Request\n%v", string(reqBytes))
+
+ if r.LogRequestWithBody {
+ smithyRequest, err = smithyRequest.SetStream(rc.Body)
+ if err != nil {
+ return out, metadata, err
+ }
+ in.Request = smithyRequest
+ }
+ }
+
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+
+ if (err == nil) && (r.LogResponse || r.LogResponseWithBody) {
+ smithyResponse, ok := out.RawResponse.(*Response)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type %T", out.RawResponse)
+ }
+
+ respBytes, err := httputil.DumpResponse(smithyResponse.Response, r.LogResponseWithBody)
+ if err != nil {
+ return out, metadata, fmt.Errorf("failed to dump response %w", err)
+ }
+
+ logger.Logf(logging.Debug, "Response\n%v", string(respBytes))
+ }
+
+ return out, metadata, err
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/middleware_metadata.go b/vendor/github.com/aws/smithy-go/transport/http/middleware_metadata.go
new file mode 100644
index 000000000000..d6079b25950c
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/middleware_metadata.go
@@ -0,0 +1,51 @@
+package http
+
+import (
+ "context"
+
+ "github.com/aws/smithy-go/middleware"
+)
+
+type (
+ hostnameImmutableKey struct{}
+ hostPrefixDisableKey struct{}
+)
+
+// GetHostnameImmutable retrieves whether the endpoint hostname should be considered
+// immutable or not.
+//
+// Scoped to stack values. Use middleware#ClearStackValues to clear all stack
+// values.
+func GetHostnameImmutable(ctx context.Context) (v bool) {
+ v, _ = middleware.GetStackValue(ctx, hostnameImmutableKey{}).(bool)
+ return v
+}
+
+// SetHostnameImmutable sets or modifies whether the request's endpoint hostname
+// should be considered immutable or not.
+//
+// Scoped to stack values. Use middleware#ClearStackValues to clear all stack
+// values.
+func SetHostnameImmutable(ctx context.Context, value bool) context.Context {
+ return middleware.WithStackValue(ctx, hostnameImmutableKey{}, value)
+}
+
+// IsEndpointHostPrefixDisabled retrieves whether the hostname prefixing is
+// disabled.
+//
+// Scoped to stack values. Use middleware#ClearStackValues to clear all stack
+// values.
+func IsEndpointHostPrefixDisabled(ctx context.Context) (v bool) {
+ v, _ = middleware.GetStackValue(ctx, hostPrefixDisableKey{}).(bool)
+ return v
+}
+
+// DisableEndpointHostPrefix sets or modifies whether the request's endpoint host
+// prefixing should be disabled. If value is true, endpoint host prefixing
+// will be disabled.
+//
+// Scoped to stack values. Use middleware#ClearStackValues to clear all stack
+// values.
+func DisableEndpointHostPrefix(ctx context.Context, value bool) context.Context {
+ return middleware.WithStackValue(ctx, hostPrefixDisableKey{}, value)
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/middleware_min_proto.go b/vendor/github.com/aws/smithy-go/transport/http/middleware_min_proto.go
new file mode 100644
index 000000000000..326cb8a6cab9
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/middleware_min_proto.go
@@ -0,0 +1,79 @@
+package http
+
+import (
+ "context"
+ "fmt"
+ "github.com/aws/smithy-go/middleware"
+ "strings"
+)
+
+// MinimumProtocolError is an error type indicating that the established connection did not meet the expected minimum
+// HTTP protocol version.
+type MinimumProtocolError struct {
+ proto string
+ expectedProtoMajor int
+ expectedProtoMinor int
+}
+
+// Error returns the error message.
+func (m *MinimumProtocolError) Error() string {
+ return fmt.Sprintf("operation requires minimum HTTP protocol of HTTP/%d.%d, but was %s",
+ m.expectedProtoMajor, m.expectedProtoMinor, m.proto)
+}
+
+// RequireMinimumProtocol is a deserialization middleware that asserts that the established HTTP connection
+// meets the minimum major ad minor version.
+type RequireMinimumProtocol struct {
+ ProtoMajor int
+ ProtoMinor int
+}
+
+// AddRequireMinimumProtocol adds the RequireMinimumProtocol middleware to the stack using the provided minimum
+// protocol major and minor version.
+func AddRequireMinimumProtocol(stack *middleware.Stack, major, minor int) error {
+ return stack.Deserialize.Insert(&RequireMinimumProtocol{
+ ProtoMajor: major,
+ ProtoMinor: minor,
+ }, "OperationDeserializer", middleware.Before)
+}
+
+// ID returns the middleware identifier string.
+func (r *RequireMinimumProtocol) ID() string {
+ return "RequireMinimumProtocol"
+}
+
+// HandleDeserialize asserts that the established connection is a HTTP connection with the minimum major and minor
+// protocol version.
+func (r *RequireMinimumProtocol) HandleDeserialize(
+ ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler,
+) (
+ out middleware.DeserializeOutput, metadata middleware.Metadata, err error,
+) {
+ out, metadata, err = next.HandleDeserialize(ctx, in)
+ if err != nil {
+ return out, metadata, err
+ }
+
+ response, ok := out.RawResponse.(*Response)
+ if !ok {
+ return out, metadata, fmt.Errorf("unknown transport type: %T", out.RawResponse)
+ }
+
+ if !strings.HasPrefix(response.Proto, "HTTP") {
+ return out, metadata, &MinimumProtocolError{
+ proto: response.Proto,
+ expectedProtoMajor: r.ProtoMajor,
+ expectedProtoMinor: r.ProtoMinor,
+ }
+ }
+
+ if response.ProtoMajor < r.ProtoMajor || response.ProtoMinor < r.ProtoMinor {
+ return out, metadata, &MinimumProtocolError{
+ proto: response.Proto,
+ expectedProtoMajor: r.ProtoMajor,
+ expectedProtoMinor: r.ProtoMinor,
+ }
+ }
+
+ return out, metadata, err
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/request.go b/vendor/github.com/aws/smithy-go/transport/http/request.go
new file mode 100644
index 000000000000..5796a689c025
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/request.go
@@ -0,0 +1,154 @@
+package http
+
+import (
+ "context"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "net/http"
+ "net/url"
+
+ iointernal "github.com/aws/smithy-go/transport/http/internal/io"
+)
+
+// Request provides the HTTP specific request structure for HTTP specific
+// middleware steps to use to serialize input, and send an operation's request.
+type Request struct {
+ *http.Request
+ stream io.Reader
+ isStreamSeekable bool
+ streamStartPos int64
+}
+
+// NewStackRequest returns an initialized request ready to be populated with the
+// HTTP request details. Returns empty interface so the function can be used as
+// a parameter to the Smithy middleware Stack constructor.
+func NewStackRequest() interface{} {
+ return &Request{
+ Request: &http.Request{
+ URL: &url.URL{},
+ Header: http.Header{},
+ ContentLength: -1, // default to unknown length
+ },
+ }
+}
+
+// Clone returns a deep copy of the Request for the new context. A reference to
+// the Stream is copied, but the underlying stream is not copied.
+func (r *Request) Clone() *Request {
+ rc := *r
+ rc.Request = rc.Request.Clone(context.TODO())
+ return &rc
+}
+
+// StreamLength returns the number of bytes of the serialized stream attached
+// to the request and ok set. If the length cannot be determined, an error will
+// be returned.
+func (r *Request) StreamLength() (size int64, ok bool, err error) {
+ if r.stream == nil {
+ return 0, true, nil
+ }
+
+ if l, ok := r.stream.(interface{ Len() int }); ok {
+ return int64(l.Len()), true, nil
+ }
+
+ if !r.isStreamSeekable {
+ return 0, false, nil
+ }
+
+ s := r.stream.(io.Seeker)
+ endOffset, err := s.Seek(0, io.SeekEnd)
+ if err != nil {
+ return 0, false, err
+ }
+
+ // The reason to seek to streamStartPos instead of 0 is to ensure that the
+ // SDK only sends the stream from the starting position the user's
+ // application provided it to the SDK at. For example application opens a
+ // file, and wants to skip the first N bytes uploading the rest. The
+ // application would move the file's offset N bytes, then hand it off to
+ // the SDK to send the remaining. The SDK should respect that initial offset.
+ _, err = s.Seek(r.streamStartPos, io.SeekStart)
+ if err != nil {
+ return 0, false, err
+ }
+
+ return endOffset - r.streamStartPos, true, nil
+}
+
+// RewindStream will rewind the io.Reader to the relative start position if it
+// is an io.Seeker.
+func (r *Request) RewindStream() error {
+ // If there is no stream there is nothing to rewind.
+ if r.stream == nil {
+ return nil
+ }
+
+ if !r.isStreamSeekable {
+ return fmt.Errorf("request stream is not seekable")
+ }
+ _, err := r.stream.(io.Seeker).Seek(r.streamStartPos, io.SeekStart)
+ return err
+}
+
+// GetStream returns the request stream io.Reader if a stream is set. If no
+// stream is present nil will be returned.
+func (r *Request) GetStream() io.Reader {
+ return r.stream
+}
+
+// IsStreamSeekable returns whether the stream is seekable.
+func (r *Request) IsStreamSeekable() bool {
+ return r.isStreamSeekable
+}
+
+// SetStream returns a clone of the request with the stream set to the provided reader.
+// May return an error if the provided reader is seekable but returns an error.
+func (r *Request) SetStream(reader io.Reader) (rc *Request, err error) {
+ rc = r.Clone()
+
+ switch v := reader.(type) {
+ case io.Seeker:
+ n, err := v.Seek(0, io.SeekCurrent)
+ if err != nil {
+ return r, err
+ }
+ rc.isStreamSeekable = true
+ rc.streamStartPos = n
+ default:
+ rc.isStreamSeekable = false
+ }
+ rc.stream = reader
+
+ return rc, err
+}
+
+// Build returns a build standard HTTP request value from the Smithy request.
+// The request's stream is wrapped in a safe container that allows it to be
+// reused for subsequent attempts.
+func (r *Request) Build(ctx context.Context) *http.Request {
+ req := r.Request.Clone(ctx)
+
+ if r.stream == nil && req.ContentLength == -1 {
+ req.ContentLength = 0
+ }
+
+ switch stream := r.stream.(type) {
+ case *io.PipeReader:
+ req.Body = ioutil.NopCloser(stream)
+ req.ContentLength = -1
+ default:
+ if r.stream != nil {
+ req.Body = iointernal.NewSafeReadCloser(ioutil.NopCloser(stream))
+ }
+ }
+
+ return req
+}
+
+// RequestCloner is a function that can take an input request type and clone the request
+// for use in a subsequent retry attempt.
+func RequestCloner(v interface{}) interface{} {
+ return v.(*Request).Clone()
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/response.go b/vendor/github.com/aws/smithy-go/transport/http/response.go
new file mode 100644
index 000000000000..0c13bfcc8e2c
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/response.go
@@ -0,0 +1,34 @@
+package http
+
+import (
+ "fmt"
+ "net/http"
+)
+
+// Response provides the HTTP specific response structure for HTTP specific
+// middleware steps to use to deserialize the response from an operation call.
+type Response struct {
+ *http.Response
+}
+
+// ResponseError provides the HTTP centric error type wrapping the underlying
+// error with the HTTP response value.
+type ResponseError struct {
+ Response *Response
+ Err error
+}
+
+// HTTPStatusCode returns the HTTP response status code received from the service.
+func (e *ResponseError) HTTPStatusCode() int { return e.Response.StatusCode }
+
+// HTTPResponse returns the HTTP response received from the service.
+func (e *ResponseError) HTTPResponse() *Response { return e.Response }
+
+// Unwrap returns the nested error if any, or nil.
+func (e *ResponseError) Unwrap() error { return e.Err }
+
+func (e *ResponseError) Error() string {
+ return fmt.Sprintf(
+ "http response error StatusCode: %d, %v",
+ e.Response.StatusCode, e.Err)
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/time.go b/vendor/github.com/aws/smithy-go/transport/http/time.go
new file mode 100644
index 000000000000..607b196a8bdd
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/time.go
@@ -0,0 +1,13 @@
+package http
+
+import (
+ "time"
+
+ smithytime "github.com/aws/smithy-go/time"
+)
+
+// ParseTime parses a time string like the HTTP Date header. This uses a more
+// relaxed rule set for date parsing compared to the standard library.
+func ParseTime(text string) (t time.Time, err error) {
+ return smithytime.ParseHTTPDate(text)
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/url.go b/vendor/github.com/aws/smithy-go/transport/http/url.go
new file mode 100644
index 000000000000..60a5fc1002a9
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/url.go
@@ -0,0 +1,44 @@
+package http
+
+import "strings"
+
+// JoinPath returns an absolute URL path composed of the two paths provided.
+// Enforces that the returned path begins with '/'. If added path is empty the
+// returned path suffix will match the first parameter suffix.
+func JoinPath(a, b string) string {
+ if len(a) == 0 {
+ a = "/"
+ } else if a[0] != '/' {
+ a = "/" + a
+ }
+
+ if len(b) != 0 && b[0] == '/' {
+ b = b[1:]
+ }
+
+ if len(b) != 0 && len(a) > 1 && a[len(a)-1] != '/' {
+ a = a + "/"
+ }
+
+ return a + b
+}
+
+// JoinRawQuery returns an absolute raw query expression. Any duplicate '&'
+// will be collapsed to single separator between values.
+func JoinRawQuery(a, b string) string {
+ a = strings.TrimFunc(a, isAmpersand)
+ b = strings.TrimFunc(b, isAmpersand)
+
+ if len(a) == 0 {
+ return b
+ }
+ if len(b) == 0 {
+ return a
+ }
+
+ return a + "&" + b
+}
+
+func isAmpersand(v rune) bool {
+ return v == '&'
+}
diff --git a/vendor/github.com/aws/smithy-go/transport/http/user_agent.go b/vendor/github.com/aws/smithy-go/transport/http/user_agent.go
new file mode 100644
index 000000000000..71a7e0d8af55
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/transport/http/user_agent.go
@@ -0,0 +1,37 @@
+package http
+
+import (
+ "strings"
+)
+
+// UserAgentBuilder is a builder for a HTTP User-Agent string.
+type UserAgentBuilder struct {
+ sb strings.Builder
+}
+
+// NewUserAgentBuilder returns a new UserAgentBuilder.
+func NewUserAgentBuilder() *UserAgentBuilder {
+ return &UserAgentBuilder{sb: strings.Builder{}}
+}
+
+// AddKey adds the named component/product to the agent string
+func (u *UserAgentBuilder) AddKey(key string) {
+ u.appendTo(key)
+}
+
+// AddKeyValue adds the named key to the agent string with the given value.
+func (u *UserAgentBuilder) AddKeyValue(key, value string) {
+ u.appendTo(key + "/" + value)
+}
+
+// Build returns the constructed User-Agent string. May be called multiple times.
+func (u *UserAgentBuilder) Build() string {
+ return u.sb.String()
+}
+
+func (u *UserAgentBuilder) appendTo(value string) {
+ if u.sb.Len() > 0 {
+ u.sb.WriteRune(' ')
+ }
+ u.sb.WriteString(value)
+}
diff --git a/vendor/github.com/aws/smithy-go/validation.go b/vendor/github.com/aws/smithy-go/validation.go
new file mode 100644
index 000000000000..b5eedc1f90ab
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/validation.go
@@ -0,0 +1,140 @@
+package smithy
+
+import (
+ "bytes"
+ "fmt"
+ "strings"
+)
+
+// An InvalidParamsError provides wrapping of invalid parameter errors found when
+// validating API operation input parameters.
+type InvalidParamsError struct {
+ // Context is the base context of the invalid parameter group.
+ Context string
+ errs []InvalidParamError
+}
+
+// Add adds a new invalid parameter error to the collection of invalid
+// parameters. The context of the invalid parameter will be updated to reflect
+// this collection.
+func (e *InvalidParamsError) Add(err InvalidParamError) {
+ err.SetContext(e.Context)
+ e.errs = append(e.errs, err)
+}
+
+// AddNested adds the invalid parameter errors from another InvalidParamsError
+// value into this collection. The nested errors will have their nested context
+// updated and base context to reflect the merging.
+//
+// Use for nested validations errors.
+func (e *InvalidParamsError) AddNested(nestedCtx string, nested InvalidParamsError) {
+ for _, err := range nested.errs {
+ err.SetContext(e.Context)
+ err.AddNestedContext(nestedCtx)
+ e.errs = append(e.errs, err)
+ }
+}
+
+// Len returns the number of invalid parameter errors
+func (e *InvalidParamsError) Len() int {
+ return len(e.errs)
+}
+
+// Error returns the string formatted form of the invalid parameters.
+func (e InvalidParamsError) Error() string {
+ w := &bytes.Buffer{}
+ fmt.Fprintf(w, "%d validation error(s) found.\n", len(e.errs))
+
+ for _, err := range e.errs {
+ fmt.Fprintf(w, "- %s\n", err.Error())
+ }
+
+ return w.String()
+}
+
+// Errs returns a slice of the invalid parameters
+func (e InvalidParamsError) Errs() []error {
+ errs := make([]error, len(e.errs))
+ for i := 0; i < len(errs); i++ {
+ errs[i] = e.errs[i]
+ }
+
+ return errs
+}
+
+// An InvalidParamError represents an invalid parameter error type.
+type InvalidParamError interface {
+ error
+
+ // Field name the error occurred on.
+ Field() string
+
+ // SetContext updates the context of the error.
+ SetContext(string)
+
+ // AddNestedContext updates the error's context to include a nested level.
+ AddNestedContext(string)
+}
+
+type invalidParamError struct {
+ context string
+ nestedContext string
+ field string
+ reason string
+}
+
+// Error returns the string version of the invalid parameter error.
+func (e invalidParamError) Error() string {
+ return fmt.Sprintf("%s, %s.", e.reason, e.Field())
+}
+
+// Field Returns the field and context the error occurred.
+func (e invalidParamError) Field() string {
+ sb := &strings.Builder{}
+ sb.WriteString(e.context)
+ if sb.Len() > 0 {
+ if len(e.nestedContext) == 0 || (len(e.nestedContext) > 0 && e.nestedContext[:1] != "[") {
+ sb.WriteRune('.')
+ }
+ }
+ if len(e.nestedContext) > 0 {
+ sb.WriteString(e.nestedContext)
+ sb.WriteRune('.')
+ }
+ sb.WriteString(e.field)
+ return sb.String()
+}
+
+// SetContext updates the base context of the error.
+func (e *invalidParamError) SetContext(ctx string) {
+ e.context = ctx
+}
+
+// AddNestedContext prepends a context to the field's path.
+func (e *invalidParamError) AddNestedContext(ctx string) {
+ if len(e.nestedContext) == 0 {
+ e.nestedContext = ctx
+ return
+ }
+ // Check if our nested context is an index into a slice or map
+ if e.nestedContext[:1] != "[" {
+ e.nestedContext = fmt.Sprintf("%s.%s", ctx, e.nestedContext)
+ return
+ }
+ e.nestedContext = ctx + e.nestedContext
+}
+
+// An ParamRequiredError represents an required parameter error.
+type ParamRequiredError struct {
+ invalidParamError
+}
+
+// NewErrParamRequired creates a new required parameter error.
+func NewErrParamRequired(field string) *ParamRequiredError {
+ return &ParamRequiredError{
+ invalidParamError{
+ field: field,
+ reason: fmt.Sprintf("missing required field"),
+ },
+ }
+}
diff --git a/vendor/github.com/aws/smithy-go/waiter/logger.go b/vendor/github.com/aws/smithy-go/waiter/logger.go
new file mode 100644
index 000000000000..8d70a03ff2f4
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/waiter/logger.go
@@ -0,0 +1,36 @@
+package waiter
+
+import (
+ "context"
+ "fmt"
+
+ "github.com/aws/smithy-go/logging"
+ "github.com/aws/smithy-go/middleware"
+)
+
+// Logger is the Logger middleware used by the waiter to log an attempt
+type Logger struct {
+ // Attempt is the current attempt to be logged
+ Attempt int64
+}
+
+// ID representing the Logger middleware
+func (*Logger) ID() string {
+ return "WaiterLogger"
+}
+
+// HandleInitialize performs handling of request in initialize stack step
+func (m *Logger) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) (
+ out middleware.InitializeOutput, metadata middleware.Metadata, err error,
+) {
+ logger := middleware.GetLogger(ctx)
+
+ logger.Logf(logging.Debug, fmt.Sprintf("attempting waiter request, attempt count: %d", m.Attempt))
+
+ return next.HandleInitialize(ctx, in)
+}
+
+// AddLogger is a helper util to add waiter logger after `SetLogger` middleware in
+func (m Logger) AddLogger(stack *middleware.Stack) error {
+ return stack.Initialize.Insert(&m, "SetLogger", middleware.After)
+}
diff --git a/vendor/github.com/aws/smithy-go/waiter/waiter.go b/vendor/github.com/aws/smithy-go/waiter/waiter.go
new file mode 100644
index 000000000000..03e46e2ee72c
--- /dev/null
+++ b/vendor/github.com/aws/smithy-go/waiter/waiter.go
@@ -0,0 +1,66 @@
+package waiter
+
+import (
+ "fmt"
+ "math"
+ "time"
+
+ "github.com/aws/smithy-go/rand"
+)
+
+// ComputeDelay computes delay between waiter attempts. The function takes in a current attempt count,
+// minimum delay, maximum delay, and remaining wait time for waiter as input. The inputs minDelay and maxDelay
+// must always be greater than 0, along with minDelay lesser than or equal to maxDelay.
+//
+// Returns the computed delay and if next attempt count is possible within the given input time constraints.
+// Note that the zeroth attempt results in no delay.
+func ComputeDelay(attempt int64, minDelay, maxDelay, remainingTime time.Duration) (delay time.Duration, err error) {
+ // zeroth attempt, no delay
+ if attempt <= 0 {
+ return 0, nil
+ }
+
+ // remainingTime is zero or less, no delay
+ if remainingTime <= 0 {
+ return 0, nil
+ }
+
+ // validate min delay is greater than 0
+ if minDelay == 0 {
+ return 0, fmt.Errorf("minDelay must be greater than zero when computing Delay")
+ }
+
+ // validate max delay is greater than 0
+ if maxDelay == 0 {
+ return 0, fmt.Errorf("maxDelay must be greater than zero when computing Delay")
+ }
+
+ // Get attempt ceiling to prevent integer overflow.
+ attemptCeiling := (math.Log(float64(maxDelay/minDelay)) / math.Log(2)) + 1
+
+ if attempt > int64(attemptCeiling) {
+ delay = maxDelay
+ } else {
+ // Compute exponential delay based on attempt.
+ ri := 1 << uint64(attempt-1)
+ // compute delay
+ delay = minDelay * time.Duration(ri)
+ }
+
+ if delay != minDelay {
+ // randomize to get jitter between min delay and delay value
+ d, err := rand.CryptoRandInt63n(int64(delay - minDelay))
+ if err != nil {
+ return 0, fmt.Errorf("error computing retry jitter, %w", err)
+ }
+
+ delay = time.Duration(d) + minDelay
+ }
+
+ // check if this is the last attempt possible and compute delay accordingly
+ if remainingTime-delay <= minDelay {
+ delay = remainingTime - minDelay
+ }
+
+ return delay, nil
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/LICENSE b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/LICENSE
new file mode 100644
index 000000000000..bb3f49d69bc7
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/LICENSE
@@ -0,0 +1,51 @@
+Apache License
+
+Version 2.0, January 2004
+
+http://www.apache.org/licenses/
+TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+1. Definitions.
+"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.
+"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.
+"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
+"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.
+"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.
+"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.
+"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).
+"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.
+"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution."
+"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.
+2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.
+3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.
+4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
+1. You must give any other recipients of the Work or Derivative Works a copy of this License; and
+2. You must cause any modified files to carry prominent notices stating that You changed the files; and
+3. You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
+4. If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License.
+
+You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.
+5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.
+6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.
+7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.
+8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.
+9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.
+END OF TERMS AND CONDITIONS
+APPENDIX: How to apply the Apache License to your work
+To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives.
+Copyright [yyyy] [name of copyright owner]
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+***
+
+Note: Other license terms may apply to certain, identified software files contained within or distributed with the accompanying software if such terms are included in the directory containing the accompanying software. Such other license terms will then apply in lieu of the terms of the software license above.
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api/client.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api/client.go
new file mode 100644
index 000000000000..2289ef6d9a0c
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api/client.go
@@ -0,0 +1,302 @@
+// Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package api
+
+import (
+ "context"
+ "encoding/base64"
+ "fmt"
+ "net/url"
+ "regexp"
+ "strings"
+ "time"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/service/ecr"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic"
+ "github.com/pkg/errors"
+ "github.com/sirupsen/logrus"
+
+ "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache"
+)
+
+const (
+ proxyEndpointScheme = "https://"
+ programName = "docker-credential-ecr-login"
+ ecrPublicName = "public.ecr.aws"
+ ecrPublicEndpoint = proxyEndpointScheme + ecrPublicName
+)
+
+var ecrPattern = regexp.MustCompile(`(^[a-zA-Z0-9][a-zA-Z0-9-_]*)\.dkr\.ecr(-fips)?\.([a-zA-Z0-9][a-zA-Z0-9-_]*)\.amazonaws\.com(\.cn)?$`)
+
+type Service string
+
+const (
+ ServiceECR Service = "ecr"
+ ServiceECRPublic Service = "ecr-public"
+)
+
+// Registry in ECR
+type Registry struct {
+ Service Service
+ ID string
+ FIPS bool
+ Region string
+}
+
+// ExtractRegistry returns the ECR registry behind a given service endpoint
+func ExtractRegistry(input string) (*Registry, error) {
+ if strings.HasPrefix(input, proxyEndpointScheme) {
+ input = strings.TrimPrefix(input, proxyEndpointScheme)
+ }
+ serverURL, err := url.Parse(proxyEndpointScheme + input)
+ if err != nil {
+ return nil, err
+ }
+ if serverURL.Hostname() == ecrPublicName {
+ return &Registry{
+ Service: ServiceECRPublic,
+ }, nil
+ }
+ matches := ecrPattern.FindStringSubmatch(serverURL.Hostname())
+ if len(matches) == 0 {
+ return nil, fmt.Errorf(programName + " can only be used with Amazon Elastic Container Registry.")
+ } else if len(matches) < 3 {
+ return nil, fmt.Errorf("%q is not a valid repository URI for Amazon Elastic Container Registry.", input)
+ }
+ return &Registry{
+ Service: ServiceECR,
+ ID: matches[1],
+ FIPS: matches[2] == "-fips",
+ Region: matches[3],
+ }, nil
+}
+
+// Client used for calling ECR service
+type Client interface {
+ GetCredentials(serverURL string) (*Auth, error)
+ GetCredentialsByRegistryID(registryID string) (*Auth, error)
+ ListCredentials() ([]*Auth, error)
+}
+
+// Auth credentials returned by ECR service to allow docker login
+type Auth struct {
+ ProxyEndpoint string
+ Username string
+ Password string
+}
+
+type defaultClient struct {
+ ecrClient ECRAPI
+ ecrPublicClient ECRPublicAPI
+ credentialCache cache.CredentialsCache
+}
+
+type ECRAPI interface {
+ GetAuthorizationToken(context.Context, *ecr.GetAuthorizationTokenInput, ...func(*ecr.Options)) (*ecr.GetAuthorizationTokenOutput, error)
+}
+
+type ECRPublicAPI interface {
+ GetAuthorizationToken(context.Context, *ecrpublic.GetAuthorizationTokenInput, ...func(*ecrpublic.Options)) (*ecrpublic.GetAuthorizationTokenOutput, error)
+}
+
+// GetCredentials returns username, password, and proxyEndpoint
+func (c *defaultClient) GetCredentials(serverURL string) (*Auth, error) {
+ registry, err := ExtractRegistry(serverURL)
+ if err != nil {
+ return nil, err
+ }
+ logrus.
+ WithField("service", registry.Service).
+ WithField("registry", registry.ID).
+ WithField("region", registry.Region).
+ WithField("serverURL", serverURL).
+ Debug("Retrieving credentials")
+ switch registry.Service {
+ case ServiceECR:
+ return c.GetCredentialsByRegistryID(registry.ID)
+ case ServiceECRPublic:
+ return c.GetPublicCredentials()
+ }
+ return nil, fmt.Errorf("unknown service %q", registry.Service)
+}
+
+// GetCredentialsByRegistryID returns username, password, and proxyEndpoint
+func (c *defaultClient) GetCredentialsByRegistryID(registryID string) (*Auth, error) {
+ cachedEntry := c.credentialCache.Get(registryID)
+ if cachedEntry != nil {
+ if cachedEntry.IsValid(time.Now()) {
+ logrus.WithField("registry", registryID).Debug("Using cached token")
+ return extractToken(cachedEntry.AuthorizationToken, cachedEntry.ProxyEndpoint)
+ }
+ logrus.
+ WithField("requestedAt", cachedEntry.RequestedAt).
+ WithField("expiresAt", cachedEntry.ExpiresAt).
+ Debug("Cached token is no longer valid")
+ }
+
+ auth, err := c.getAuthorizationToken(registryID)
+
+ // if we have a cached token, fall back to avoid failing the request. This may result an expired token
+ // being returned, but if there is a 500 or timeout from the service side, we'd like to attempt to re-use an
+ // old token. We invalidate tokens prior to their expiration date to help mitigate this scenario.
+ if err != nil && cachedEntry != nil {
+ logrus.WithError(err).Info("Got error fetching authorization token. Falling back to cached token.")
+ return extractToken(cachedEntry.AuthorizationToken, cachedEntry.ProxyEndpoint)
+ }
+ return auth, err
+}
+
+func (c *defaultClient) GetPublicCredentials() (*Auth, error) {
+ cachedEntry := c.credentialCache.GetPublic()
+ if cachedEntry != nil {
+ if cachedEntry.IsValid(time.Now()) {
+ logrus.WithField("registry", ecrPublicName).Debug("Using cached token")
+ return extractToken(cachedEntry.AuthorizationToken, cachedEntry.ProxyEndpoint)
+ }
+ logrus.
+ WithField("requestedAt", cachedEntry.RequestedAt).
+ WithField("expiresAt", cachedEntry.ExpiresAt).
+ Debug("Cached token is no longer valid")
+ }
+
+ auth, err := c.getPublicAuthorizationToken()
+ // if we have a cached token, fall back to avoid failing the request. This may result an expired token
+ // being returned, but if there is a 500 or timeout from the service side, we'd like to attempt to re-use an
+ // old token. We invalidate tokens prior to their expiration date to help mitigate this scenario.
+ if err != nil && cachedEntry != nil {
+ logrus.WithError(err).Info("Got error fetching authorization token. Falling back to cached token.")
+ return extractToken(cachedEntry.AuthorizationToken, cachedEntry.ProxyEndpoint)
+ }
+ return auth, err
+}
+
+func (c *defaultClient) ListCredentials() ([]*Auth, error) {
+ // prime the cache with default authorization tokens
+ _, err := c.GetCredentialsByRegistryID("")
+ if err != nil {
+ logrus.WithError(err).Debug("couldn't get authorization token for default registry")
+ }
+ _, err = c.GetPublicCredentials()
+ if err != nil {
+ logrus.WithError(err).Debug("couldn't get authorization token for public registry")
+ }
+
+ auths := make([]*Auth, 0)
+ for _, authEntry := range c.credentialCache.List() {
+ auth, err := extractToken(authEntry.AuthorizationToken, authEntry.ProxyEndpoint)
+ if err != nil {
+ logrus.WithError(err).Debug("Could not extract token")
+ } else {
+ auths = append(auths, auth)
+ }
+ }
+
+ return auths, nil
+}
+
+func (c *defaultClient) getAuthorizationToken(registryID string) (*Auth, error) {
+ var input *ecr.GetAuthorizationTokenInput
+ if registryID == "" {
+ logrus.Debug("Calling ECR.GetAuthorizationToken for default registry")
+ input = &ecr.GetAuthorizationTokenInput{}
+ } else {
+ logrus.WithField("registry", registryID).Debug("Calling ECR.GetAuthorizationToken")
+ input = &ecr.GetAuthorizationTokenInput{
+ RegistryIds: []string{registryID},
+ }
+ }
+
+ output, err := c.ecrClient.GetAuthorizationToken(context.TODO(), input)
+ if err != nil || output == nil {
+ if err == nil {
+ if registryID == "" {
+ err = fmt.Errorf("missing AuthorizationData in ECR response for default registry")
+ } else {
+ err = fmt.Errorf("missing AuthorizationData in ECR response for %s", registryID)
+ }
+ }
+ return nil, errors.Wrap(err, "ecr: Failed to get authorization token")
+ }
+
+ for _, authData := range output.AuthorizationData {
+ if authData.ProxyEndpoint != nil && authData.AuthorizationToken != nil {
+ authEntry := cache.AuthEntry{
+ AuthorizationToken: aws.ToString(authData.AuthorizationToken),
+ RequestedAt: time.Now(),
+ ExpiresAt: aws.ToTime(authData.ExpiresAt),
+ ProxyEndpoint: aws.ToString(authData.ProxyEndpoint),
+ Service: cache.ServiceECR,
+ }
+ registry, err := ExtractRegistry(authEntry.ProxyEndpoint)
+ if err != nil {
+ return nil, fmt.Errorf("Invalid ProxyEndpoint returned by ECR: %s", authEntry.ProxyEndpoint)
+ }
+ auth, err := extractToken(authEntry.AuthorizationToken, authEntry.ProxyEndpoint)
+ if err != nil {
+ return nil, err
+ }
+ c.credentialCache.Set(registry.ID, &authEntry)
+ return auth, nil
+ }
+ }
+ if registryID == "" {
+ return nil, fmt.Errorf("No AuthorizationToken found for default registry")
+ }
+ return nil, fmt.Errorf("No AuthorizationToken found for %s", registryID)
+}
+
+func (c *defaultClient) getPublicAuthorizationToken() (*Auth, error) {
+ var input *ecrpublic.GetAuthorizationTokenInput
+
+ output, err := c.ecrPublicClient.GetAuthorizationToken(context.TODO(), input)
+ if err != nil {
+ return nil, errors.Wrap(err, "ecr: failed to get authorization token")
+ }
+ if output == nil || output.AuthorizationData == nil {
+ return nil, fmt.Errorf("ecr: missing AuthorizationData in ECR Public response")
+ }
+ authData := output.AuthorizationData
+ token, err := extractToken(aws.ToString(authData.AuthorizationToken), ecrPublicEndpoint)
+ if err != nil {
+ return nil, err
+ }
+ authEntry := cache.AuthEntry{
+ AuthorizationToken: aws.ToString(authData.AuthorizationToken),
+ RequestedAt: time.Now(),
+ ExpiresAt: aws.ToTime(authData.ExpiresAt),
+ ProxyEndpoint: ecrPublicEndpoint,
+ Service: cache.ServiceECRPublic,
+ }
+ c.credentialCache.Set(ecrPublicName, &authEntry)
+ return token, nil
+}
+
+func extractToken(token string, proxyEndpoint string) (*Auth, error) {
+ decodedToken, err := base64.StdEncoding.DecodeString(token)
+ if err != nil {
+ return nil, errors.Wrap(err, "invalid token")
+ }
+
+ parts := strings.SplitN(string(decodedToken), ":", 2)
+ if len(parts) < 2 {
+ return nil, fmt.Errorf("invalid token: expected two parts, got %d", len(parts))
+ }
+
+ return &Auth{
+ Username: parts[0],
+ Password: parts[1],
+ ProxyEndpoint: proxyEndpoint,
+ }, nil
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api/factory.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api/factory.go
new file mode 100644
index 000000000000..110a6c3bdd2f
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api/factory.go
@@ -0,0 +1,107 @@
+// Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package api
+
+import (
+ "context"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/aws/aws-sdk-go-v2/config"
+ "github.com/aws/aws-sdk-go-v2/service/ecr"
+ "github.com/aws/aws-sdk-go-v2/service/ecrpublic"
+ "github.com/aws/smithy-go/middleware"
+ "github.com/aws/smithy-go/transport/http"
+ "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache"
+ "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/version"
+)
+
+// Options makes the constructors more configurable
+type Options struct {
+ Config aws.Config
+ CacheDir string
+}
+
+// ClientFactory is a factory for creating clients to interact with ECR
+type ClientFactory interface {
+ NewClient(awsConfig aws.Config) Client
+ NewClientWithOptions(opts Options) Client
+ NewClientFromRegion(region string) Client
+ NewClientWithFipsEndpoint(region string) (Client, error)
+ NewClientWithDefaults() Client
+}
+
+// DefaultClientFactory is a default implementation of the ClientFactory
+type DefaultClientFactory struct{}
+
+var userAgentLoadOption = config.WithAPIOptions([]func(*middleware.Stack) error{
+ http.AddHeaderValue("User-Agent", "amazon-ecr-credential-helper/"+version.Version),
+})
+
+// NewClientWithDefaults creates the client and defaults region
+func (defaultClientFactory DefaultClientFactory) NewClientWithDefaults() Client {
+ awsConfig, err := config.LoadDefaultConfig(context.TODO(), userAgentLoadOption)
+ if err != nil {
+ panic(err)
+ }
+
+ return defaultClientFactory.NewClientWithOptions(Options{Config: awsConfig})
+}
+
+// NewClientWithFipsEndpoint overrides the default ECR service endpoint in a given region to use the FIPS endpoint
+func (defaultClientFactory DefaultClientFactory) NewClientWithFipsEndpoint(region string) (Client, error) {
+ awsConfig, err := config.LoadDefaultConfig(
+ context.TODO(),
+ userAgentLoadOption,
+ config.WithRegion(region),
+ config.WithEndpointDiscovery(aws.EndpointDiscoveryEnabled),
+ )
+ if err != nil {
+ return nil, err
+ }
+
+ return defaultClientFactory.NewClientWithOptions(Options{Config: awsConfig}), nil
+}
+
+// NewClientFromRegion uses the region to create the client
+func (defaultClientFactory DefaultClientFactory) NewClientFromRegion(region string) Client {
+ awsConfig, err := config.LoadDefaultConfig(
+ context.TODO(),
+ userAgentLoadOption,
+ config.WithRegion(region),
+ )
+ if err != nil {
+ panic(err)
+ }
+
+ return defaultClientFactory.NewClientWithOptions(Options{
+ Config: awsConfig,
+ })
+}
+
+// NewClient Create new client with AWS Config
+func (defaultClientFactory DefaultClientFactory) NewClient(awsConfig aws.Config) Client {
+ return defaultClientFactory.NewClientWithOptions(Options{Config: awsConfig})
+}
+
+// NewClientWithOptions Create new client with Options
+func (defaultClientFactory DefaultClientFactory) NewClientWithOptions(opts Options) Client {
+ // The ECR Public API is only available in us-east-1 today
+ publicConfig := opts.Config.Copy()
+ publicConfig.Region = "us-east-1"
+ return &defaultClient{
+ ecrClient: ecr.NewFromConfig(opts.Config),
+ ecrPublicClient: ecrpublic.NewFromConfig(publicConfig),
+ credentialCache: cache.BuildCredentialsCache(opts.Config, opts.CacheDir),
+ }
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/build.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/build.go
new file mode 100644
index 000000000000..8aa21287dcee
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/build.go
@@ -0,0 +1,73 @@
+// Copyright 2017 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package cache
+
+import (
+ "context"
+ "crypto/md5"
+ "encoding/base64"
+ "fmt"
+ "os"
+
+ "github.com/aws/aws-sdk-go-v2/aws"
+ "github.com/mitchellh/go-homedir"
+ "github.com/sirupsen/logrus"
+
+ ecrconfig "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config"
+)
+
+func BuildCredentialsCache(config aws.Config, cacheDir string) CredentialsCache {
+ if os.Getenv("AWS_ECR_DISABLE_CACHE") != "" {
+ logrus.Debug("Cache disabled due to AWS_ECR_DISABLE_CACHE")
+ return NewNullCredentialsCache()
+ }
+
+ if cacheDir == "" {
+ //Get cacheDir from env var "AWS_ECR_CACHE_DIR" or set to default
+ cacheDir = ecrconfig.GetCacheDir()
+ }
+
+ cacheDir, err := homedir.Expand(cacheDir)
+ if err != nil {
+ logrus.WithError(err).Debug("Could not expand cache path, disabling cache")
+ return NewNullCredentialsCache()
+ }
+
+ cacheFilename := "cache.json"
+
+ credentials, err := config.Credentials.Retrieve(context.TODO())
+ if err != nil {
+ logrus.WithError(err).Debug("Could not fetch credentials for cache prefix, disabling cache")
+ return NewNullCredentialsCache()
+ }
+
+ return NewFileCredentialsCache(cacheDir, cacheFilename, credentialsCachePrefix(config.Region, credentials), credentialsPublicCacheKey(credentials))
+}
+
+// Determine a key prefix for a credentials cache. Because auth tokens are scoped to an account and region, rely on provided
+// region, as well as hash of the access key.
+func credentialsCachePrefix(region string, credentials aws.Credentials) string {
+ return fmt.Sprintf("%s-%s-", region, checksum(credentials.AccessKeyID))
+}
+
+func credentialsPublicCacheKey(credentials aws.Credentials) string {
+ return fmt.Sprintf("%s-%s", ServiceECRPublic, checksum(credentials.AccessKeyID))
+}
+
+// Base64 encodes an MD5 checksum. Relied on for uniqueness, and not for cryptographic security.
+func checksum(text string) string {
+ hasher := md5.New()
+ data := hasher.Sum([]byte(text))
+ return base64.StdEncoding.EncodeToString(data)
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/credentials.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/credentials.go
new file mode 100644
index 000000000000..0b74c0f31034
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/credentials.go
@@ -0,0 +1,49 @@
+// Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package cache
+
+import (
+ "time"
+)
+
+type CredentialsCache interface {
+ Get(registry string) *AuthEntry
+ GetPublic() *AuthEntry
+ Set(registry string, entry *AuthEntry)
+ List() []*AuthEntry
+ Clear()
+}
+
+type Service string
+
+const (
+ ServiceECR Service = "ecr"
+ ServiceECRPublic Service = "ecr-public"
+)
+
+type AuthEntry struct {
+ AuthorizationToken string
+ RequestedAt time.Time
+ ExpiresAt time.Time
+ ProxyEndpoint string
+ Service Service
+}
+
+// IsValid checks if AuthEntry is still valid at testTime. AuthEntries expire at 1/2 of their original
+// requested window.
+func (authEntry *AuthEntry) IsValid(testTime time.Time) bool {
+ validWindow := authEntry.ExpiresAt.Sub(authEntry.RequestedAt)
+ refreshTime := authEntry.ExpiresAt.Add(-1 * validWindow / time.Duration(2))
+ return testTime.Before(refreshTime)
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/file.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/file.go
new file mode 100644
index 000000000000..bc70693b8186
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/file.go
@@ -0,0 +1,195 @@
+// Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package cache
+
+import (
+ "encoding/json"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "path/filepath"
+
+ "github.com/sirupsen/logrus"
+)
+
+const registryCacheVersion = "1.0"
+
+type RegistryCache struct {
+ Registries map[string]*AuthEntry
+ Version string
+}
+
+type fileCredentialCache struct {
+ path string
+ filename string
+ cachePrefixKey string
+ publicCacheKey string
+}
+
+func newRegistryCache() *RegistryCache {
+ return &RegistryCache{
+ Registries: make(map[string]*AuthEntry),
+ Version: registryCacheVersion,
+ }
+}
+
+// NewFileCredentialsCache returns a new file credentials cache.
+//
+// path is used for temporary files during save, and filename should be a relative filename
+// in the same directory where the cache is serialized and deserialized.
+//
+// cachePrefixKey is used for scoping credentials for a given credential cache (i.e. region and
+// accessKey).
+func NewFileCredentialsCache(path string, filename string, cachePrefixKey string, publicCacheKey string) CredentialsCache {
+ if _, err := os.Stat(path); err != nil {
+ os.MkdirAll(path, 0700)
+ }
+ return &fileCredentialCache{
+ path: path,
+ filename: filename,
+ cachePrefixKey: cachePrefixKey,
+ publicCacheKey: publicCacheKey,
+ }
+}
+
+func (f *fileCredentialCache) Get(registry string) *AuthEntry {
+ logrus.WithField("registry", registry).Debug("Checking file cache")
+ registryCache := f.init()
+ return registryCache.Registries[f.cachePrefixKey+registry]
+}
+
+func (f *fileCredentialCache) GetPublic() *AuthEntry {
+ logrus.Debug("Checking file cache for ECR Public")
+ registryCache := f.init()
+ return registryCache.Registries[f.publicCacheKey]
+}
+
+func (f *fileCredentialCache) Set(registry string, entry *AuthEntry) {
+ logrus.
+ WithField("registry", registry).
+ WithField("service", entry.Service).
+ Debug("Saving credentials to file cache")
+ registryCache := f.init()
+
+ key := f.cachePrefixKey + registry
+ if entry.Service == ServiceECRPublic {
+ key = f.publicCacheKey
+ }
+ registryCache.Registries[key] = entry
+
+ err := f.save(registryCache)
+ if err != nil {
+ logrus.WithError(err).Info("Could not save cache")
+ }
+}
+
+// List returns all of the available AuthEntries (regardless of prefix)
+func (f *fileCredentialCache) List() []*AuthEntry {
+ registryCache := f.init()
+
+ // optimize allocation for copy
+ entries := make([]*AuthEntry, 0, len(registryCache.Registries))
+
+ for _, entry := range registryCache.Registries {
+ entries = append(entries, entry)
+ }
+
+ return entries
+}
+
+func (f *fileCredentialCache) Clear() {
+ err := os.Remove(f.fullFilePath())
+ if err != nil {
+ logrus.WithError(err).Info("Could not clear cache")
+ }
+}
+
+func (f *fileCredentialCache) fullFilePath() string {
+ return filepath.Join(f.path, f.filename)
+}
+
+// Saves credential cache to disk. This writes to a temporary file first, then moves the file to the config location.
+// This eliminates from reading partially written credential files, and reduces (but does not eliminate) concurrent
+// file access. There is not guarantee here for handling multiple writes at once since there is no out of process locking.
+func (f *fileCredentialCache) save(registryCache *RegistryCache) error {
+ file, err := ioutil.TempFile(f.path, ".config.json.tmp")
+ if err != nil {
+ return err
+ }
+
+ buff, err := json.MarshalIndent(registryCache, "", " ")
+ if err != nil {
+ file.Close()
+ os.Remove(file.Name())
+ return err
+ }
+
+ _, err = file.Write(buff)
+
+ if err != nil {
+ file.Close()
+ os.Remove(file.Name())
+ return err
+ }
+
+ file.Close()
+ // note this is only atomic when relying on linux syscalls
+ os.Rename(file.Name(), f.fullFilePath())
+ return err
+}
+
+func (f *fileCredentialCache) init() *RegistryCache {
+ registryCache, err := f.load()
+ if err != nil {
+ logrus.WithError(err).Info("Could not load existing cache")
+ f.Clear()
+ registryCache = newRegistryCache()
+ }
+ return registryCache
+}
+
+// Loading a cache from disk will return errors for malformed or incompatible cache files.
+func (f *fileCredentialCache) load() (*RegistryCache, error) {
+ registryCache := newRegistryCache()
+
+ file, err := os.Open(f.fullFilePath())
+ if os.IsNotExist(err) {
+ return registryCache, nil
+ }
+
+ if err != nil {
+ return nil, err
+ }
+
+ defer file.Close()
+
+ if err = json.NewDecoder(file).Decode(®istryCache); err != nil {
+ return nil, err
+ }
+
+ if registryCache.Version != registryCacheVersion {
+ return nil, fmt.Errorf("ecr: Registry cache version %#v is not compatible with %#v, ignoring existing cache",
+ registryCache.Version,
+ registryCacheVersion)
+ }
+
+ // migrate entries
+ for key := range registryCache.Registries {
+ if registryCache.Registries[key].Service == "" {
+ registryCache.Registries[key].Service = ServiceECR
+ }
+ }
+
+ return registryCache, nil
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/null.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/null.go
new file mode 100644
index 000000000000..64a7212bd371
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache/null.go
@@ -0,0 +1,38 @@
+// Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package cache
+
+type nullCredentialsCache struct{}
+
+func NewNullCredentialsCache() CredentialsCache {
+ return &nullCredentialsCache{}
+}
+
+func (n *nullCredentialsCache) Get(_ string) *AuthEntry {
+ return nil
+}
+
+func (n *nullCredentialsCache) GetPublic() *AuthEntry {
+ return nil
+}
+
+func (n *nullCredentialsCache) Set(_ string, _ *AuthEntry) {
+}
+
+func (n *nullCredentialsCache) List() []*AuthEntry {
+ return []*AuthEntry{}
+}
+
+func (n *nullCredentialsCache) Clear() {
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config/cache_dir.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config/cache_dir.go
new file mode 100644
index 000000000000..d7c2ee644690
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config/cache_dir.go
@@ -0,0 +1,23 @@
+// Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package config
+
+import "os"
+
+func GetCacheDir() string {
+ if cacheDir := os.Getenv("AWS_ECR_CACHE_DIR"); cacheDir != "" {
+ return cacheDir
+ }
+ return "~/.ecr"
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config/log.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config/log.go
new file mode 100644
index 000000000000..771611bad228
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config/log.go
@@ -0,0 +1,48 @@
+// Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package config
+
+import (
+ "fmt"
+ "os"
+ "path/filepath"
+
+ "github.com/mitchellh/go-homedir"
+ "github.com/sirupsen/logrus"
+)
+
+func SetupLogger() {
+ logrusConfig()
+}
+
+func logrusConfig() {
+ logdir, err := homedir.Expand(GetCacheDir() + "/log")
+ if err != nil {
+ fmt.Fprintf(os.Stderr, "log: failed to find directory: %v", err)
+ logdir = os.TempDir()
+ }
+ // Clean the path to replace with OS-specific separators
+ logdir = filepath.Clean(logdir)
+ err = os.MkdirAll(logdir, os.ModeDir|0700)
+ if err != nil {
+ fmt.Fprintf(os.Stderr, "log: failed to create directory: %v", err)
+ logdir = os.TempDir()
+ }
+ file, err := os.OpenFile(filepath.Join(logdir, "ecr-login.log"), os.O_RDWR|os.O_CREATE|os.O_APPEND, 0664)
+ if err != nil {
+ return
+ }
+ logrus.SetLevel(logrus.DebugLevel)
+ logrus.SetOutput(file)
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/ecr.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/ecr.go
new file mode 100644
index 000000000000..fb9156164342
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/ecr.go
@@ -0,0 +1,91 @@
+// Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License"). You may
+// not use this file except in compliance with the License. A copy of the
+// License is located at
+//
+// http://aws.amazon.com/apache2.0/
+//
+// or in the "license" file accompanying this file. This file is distributed
+// on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+// express or implied. See the License for the specific language governing
+// permissions and limitations under the License.
+
+package ecr
+
+import (
+ "errors"
+ "fmt"
+
+ "github.com/sirupsen/logrus"
+
+ "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api"
+ "github.com/docker/docker-credential-helpers/credentials"
+)
+
+var notImplemented = errors.New("not implemented")
+
+type ECRHelper struct {
+ ClientFactory api.ClientFactory
+}
+
+// ensure ECRHelper adheres to the credentials.Helper interface
+var _ credentials.Helper = (*ECRHelper)(nil)
+
+func (ECRHelper) Add(creds *credentials.Credentials) error {
+ // This does not seem to get called
+ return notImplemented
+}
+
+func (ECRHelper) Delete(serverURL string) error {
+ // This does not seem to get called
+ return notImplemented
+}
+
+func (self ECRHelper) Get(serverURL string) (string, string, error) {
+ registry, err := api.ExtractRegistry(serverURL)
+ if err != nil {
+ logrus.
+ WithError(err).
+ WithField("serverURL", serverURL).
+ Error("Error parsing the serverURL")
+ return "", "", credentials.NewErrCredentialsNotFound()
+ }
+
+ var client api.Client
+ if registry.FIPS {
+ client, err = self.ClientFactory.NewClientWithFipsEndpoint(registry.Region)
+ if err != nil {
+ logrus.WithError(err).Error("Error resolving FIPS endpoint")
+ return "", "", credentials.NewErrCredentialsNotFound()
+ }
+ } else {
+ client = self.ClientFactory.NewClientFromRegion(registry.Region)
+ }
+
+ auth, err := client.GetCredentials(serverURL)
+ if err != nil {
+ logrus.WithError(err).Error("Error retrieving credentials")
+ return "", "", credentials.NewErrCredentialsNotFound()
+ }
+ return auth.Username, auth.Password, nil
+}
+
+func (self ECRHelper) List() (map[string]string, error) {
+ logrus.Debug("Listing credentials")
+ client := self.ClientFactory.NewClientWithDefaults()
+
+ auths, err := client.ListCredentials()
+ if err != nil {
+ logrus.WithError(err).Error("Error listing credentials")
+ return nil, fmt.Errorf("ecr: could not list credentials: %v", err)
+ }
+
+ result := map[string]string{}
+
+ for _, auth := range auths {
+ serverURL := auth.ProxyEndpoint
+ result[serverURL] = auth.Username
+ }
+ return result, nil
+}
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/go.mod b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/go.mod
new file mode 100644
index 000000000000..aa14bcf35872
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/go.mod
@@ -0,0 +1,19 @@
+module github.com/awslabs/amazon-ecr-credential-helper/ecr-login
+
+require (
+ github.com/aws/aws-sdk-go-v2 v1.7.1
+ github.com/aws/aws-sdk-go-v2/config v1.5.0
+ github.com/aws/aws-sdk-go-v2/credentials v1.3.1
+ github.com/aws/aws-sdk-go-v2/service/ecr v1.4.1
+ github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.4.1
+ github.com/aws/smithy-go v1.6.0
+ github.com/docker/docker-credential-helpers v0.6.3
+ github.com/konsorten/go-windows-terminal-sequences v1.0.2 // indirect
+ github.com/mitchellh/go-homedir v1.1.0
+ github.com/pkg/errors v0.9.1
+ github.com/sirupsen/logrus v1.4.2
+ github.com/stretchr/testify v1.3.0
+ golang.org/x/sys v0.0.0-20210423082822-04245dca01da // indirect
+)
+
+go 1.13
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/go.sum b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/go.sum
new file mode 100644
index 000000000000..4ffe7c9783fa
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/go.sum
@@ -0,0 +1,59 @@
+github.com/aws/aws-sdk-go-v2 v1.7.1 h1:TswSc7KNqZ/K1Ijt3IkpXk/2+62vi3Q82Yrr5wSbRBQ=
+github.com/aws/aws-sdk-go-v2 v1.7.1/go.mod h1:L5LuPC1ZgDr2xQS7AmIec/Jlc7O/Y1u2KxJyNVab250=
+github.com/aws/aws-sdk-go-v2/config v1.5.0 h1:tRQcWXVmO7wC+ApwYc2LiYKfIBoIrdzcJ+7HIh6AlR0=
+github.com/aws/aws-sdk-go-v2/config v1.5.0/go.mod h1:RWlPOAW3E3tbtNAqTwvSW54Of/yP3oiZXMI0xfUdjyA=
+github.com/aws/aws-sdk-go-v2/credentials v1.3.1 h1:fFeqL5+9kwFKsCb2oci5yAIDsWYqn/Nga8oQ5bIasI8=
+github.com/aws/aws-sdk-go-v2/credentials v1.3.1/go.mod h1:r0n73xwsIVagq8RsxmZbGSRQFj9As3je72C2WzUIToc=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.3.0 h1:s4vtv3Mv1CisI3qm2HGHi1Ls9ZtbCOEqeQn6oz7fTyU=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.3.0/go.mod h1:2LAuqPx1I6jNfaGDucWfA2zqQCYCOMCDHiCOciALyNw=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.1.1 h1:SDLwr1NKyowP7uqxuLNdvFZhjnoVWxNv456zAp+ZFjU=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.1.1/go.mod h1:Zy8smImhTdOETZqfyn01iNOe0CNggVbPjCajyaz6Gvg=
+github.com/aws/aws-sdk-go-v2/service/ecr v1.4.1 h1:0JhMzx6rao6tGEwXQcv9SZiUOfYOZlgsfqWeRwgSa7w=
+github.com/aws/aws-sdk-go-v2/service/ecr v1.4.1/go.mod h1:FglZcyeiBqcbvyinl+n14aT/EWC7S1MIH+Gan2iizt0=
+github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.4.1 h1:zoktIoJ+S7mJpABtSYzcVCFosRK1zehO78Lc86AbOQk=
+github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.4.1/go.mod h1:eD5Eo4drVP2FLTw0G+SMIPWNWvQRGGTtIZR2XeAagoA=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.2.1 h1:VJe/XEhrfyfBLupcGg1BfUSK2VMZNdbDcZQ49jnp+h0=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.2.1/go.mod h1:zceowr5Z1Nh2WVP8bf/3ikB41IZW59E4yIYbg+pC6mw=
+github.com/aws/aws-sdk-go-v2/service/sso v1.3.1 h1:H2ZLWHUbbeYtghuqCY5s/7tbBM99PAwCioRJF8QvV/U=
+github.com/aws/aws-sdk-go-v2/service/sso v1.3.1/go.mod h1:J3A3RGUvuCZjvSuZEcOpHDnzZP/sKbhDWV2T1EOzFIM=
+github.com/aws/aws-sdk-go-v2/service/sts v1.6.0 h1:Y9r6mrzOyAYz4qKaluSH19zqH1236il/nGbsPKOUT0s=
+github.com/aws/aws-sdk-go-v2/service/sts v1.6.0/go.mod h1:q7o0j7d7HrJk/vr9uUt3BVRASvcU7gYZB9PUgPiByXg=
+github.com/aws/smithy-go v1.6.0 h1:T6puApfBcYiTIsaI+SYWqanjMt5pc3aoyyDrI+0YH54=
+github.com/aws/smithy-go v1.6.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
+github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/docker/docker-credential-helpers v0.6.3 h1:zI2p9+1NQYdnG6sMU26EX4aVGlqbInSQxQXLvzJ4RPQ=
+github.com/docker/docker-credential-helpers v0.6.3/go.mod h1:WRaJzqw3CTB9bk10avuGsjVBZsD05qeibJ1/TYlvc0Y=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg=
+github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8=
+github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
+github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
+github.com/konsorten/go-windows-terminal-sequences v1.0.2 h1:DB17ag19krx9CFsz4o3enTrPXyIXCl+2iCXH/aMAp9s=
+github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
+github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
+github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
+github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
+github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
+github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/sirupsen/logrus v1.4.2 h1:SPIRibHv4MatM3XXNO2BJeFLZwZ2LvZgfQ5+UNI2im4=
+github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
+github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
+github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
+golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210423082822-04245dca01da h1:b3NXsE2LusjYGGjL5bxEVZZORm/YEFFrWFjR8eFrw/c=
+golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/yaml.v2 v2.2.8 h1:obN1ZagJSUGI0Ek/LBmuj4SNLPfIny3KsKFopxRdj10=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
diff --git a/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/version/version.go b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/version/version.go
new file mode 100644
index 000000000000..a02a670aa658
--- /dev/null
+++ b/vendor/github.com/awslabs/amazon-ecr-credential-helper/ecr-login/version/version.go
@@ -0,0 +1,7 @@
+package version
+
+// Version indicates which version of the binary is running.
+var Version = "development"
+
+// GitCommitSHA indicates which git shorthash the binary was built off of
+var GitCommitSHA string
diff --git a/vendor/github.com/cespare/xxhash/v2/.travis.yml b/vendor/github.com/cespare/xxhash/v2/.travis.yml
deleted file mode 100644
index c516ea88da73..000000000000
--- a/vendor/github.com/cespare/xxhash/v2/.travis.yml
+++ /dev/null
@@ -1,8 +0,0 @@
-language: go
-go:
- - "1.x"
- - master
-env:
- - TAGS=""
- - TAGS="-tags purego"
-script: go test $TAGS -v ./...
diff --git a/vendor/github.com/cespare/xxhash/v2/README.md b/vendor/github.com/cespare/xxhash/v2/README.md
index 2fd8693c21b2..792b4a60b346 100644
--- a/vendor/github.com/cespare/xxhash/v2/README.md
+++ b/vendor/github.com/cespare/xxhash/v2/README.md
@@ -1,7 +1,7 @@
# xxhash
-[](https://godoc.org/github.com/cespare/xxhash)
-[](https://travis-ci.org/cespare/xxhash)
+[](https://pkg.go.dev/github.com/cespare/xxhash/v2)
+[](https://github.com/cespare/xxhash/actions/workflows/test.yml)
xxhash is a Go implementation of the 64-bit
[xxHash](http://cyan4973.github.io/xxHash/) algorithm, XXH64. This is a
@@ -64,4 +64,6 @@ $ go test -benchtime 10s -bench '/xxhash,direct,bytes'
- [InfluxDB](https://github.com/influxdata/influxdb)
- [Prometheus](https://github.com/prometheus/prometheus)
+- [VictoriaMetrics](https://github.com/VictoriaMetrics/VictoriaMetrics)
- [FreeCache](https://github.com/coocood/freecache)
+- [FastCache](https://github.com/VictoriaMetrics/fastcache)
diff --git a/vendor/github.com/cespare/xxhash/v2/xxhash.go b/vendor/github.com/cespare/xxhash/v2/xxhash.go
index db0b35fbe39f..15c835d5417c 100644
--- a/vendor/github.com/cespare/xxhash/v2/xxhash.go
+++ b/vendor/github.com/cespare/xxhash/v2/xxhash.go
@@ -193,7 +193,6 @@ func (d *Digest) UnmarshalBinary(b []byte) error {
b, d.v4 = consumeUint64(b)
b, d.total = consumeUint64(b)
copy(d.mem[:], b)
- b = b[len(d.mem):]
d.n = int(d.total % uint64(len(d.mem)))
return nil
}
diff --git a/vendor/github.com/cespare/xxhash/v2/xxhash_amd64.s b/vendor/github.com/cespare/xxhash/v2/xxhash_amd64.s
index d580e32aed4a..be8db5bf7960 100644
--- a/vendor/github.com/cespare/xxhash/v2/xxhash_amd64.s
+++ b/vendor/github.com/cespare/xxhash/v2/xxhash_amd64.s
@@ -6,7 +6,7 @@
// Register allocation:
// AX h
-// CX pointer to advance through b
+// SI pointer to advance through b
// DX n
// BX loop end
// R8 v1, k1
@@ -16,39 +16,39 @@
// R12 tmp
// R13 prime1v
// R14 prime2v
-// R15 prime4v
+// DI prime4v
-// round reads from and advances the buffer pointer in CX.
+// round reads from and advances the buffer pointer in SI.
// It assumes that R13 has prime1v and R14 has prime2v.
#define round(r) \
- MOVQ (CX), R12 \
- ADDQ $8, CX \
+ MOVQ (SI), R12 \
+ ADDQ $8, SI \
IMULQ R14, R12 \
ADDQ R12, r \
ROLQ $31, r \
IMULQ R13, r
// mergeRound applies a merge round on the two registers acc and val.
-// It assumes that R13 has prime1v, R14 has prime2v, and R15 has prime4v.
+// It assumes that R13 has prime1v, R14 has prime2v, and DI has prime4v.
#define mergeRound(acc, val) \
IMULQ R14, val \
ROLQ $31, val \
IMULQ R13, val \
XORQ val, acc \
IMULQ R13, acc \
- ADDQ R15, acc
+ ADDQ DI, acc
// func Sum64(b []byte) uint64
TEXT ·Sum64(SB), NOSPLIT, $0-32
// Load fixed primes.
MOVQ ·prime1v(SB), R13
MOVQ ·prime2v(SB), R14
- MOVQ ·prime4v(SB), R15
+ MOVQ ·prime4v(SB), DI
// Load slice.
- MOVQ b_base+0(FP), CX
+ MOVQ b_base+0(FP), SI
MOVQ b_len+8(FP), DX
- LEAQ (CX)(DX*1), BX
+ LEAQ (SI)(DX*1), BX
// The first loop limit will be len(b)-32.
SUBQ $32, BX
@@ -65,14 +65,14 @@ TEXT ·Sum64(SB), NOSPLIT, $0-32
XORQ R11, R11
SUBQ R13, R11
- // Loop until CX > BX.
+ // Loop until SI > BX.
blockLoop:
round(R8)
round(R9)
round(R10)
round(R11)
- CMPQ CX, BX
+ CMPQ SI, BX
JLE blockLoop
MOVQ R8, AX
@@ -100,16 +100,16 @@ noBlocks:
afterBlocks:
ADDQ DX, AX
- // Right now BX has len(b)-32, and we want to loop until CX > len(b)-8.
+ // Right now BX has len(b)-32, and we want to loop until SI > len(b)-8.
ADDQ $24, BX
- CMPQ CX, BX
+ CMPQ SI, BX
JG fourByte
wordLoop:
// Calculate k1.
- MOVQ (CX), R8
- ADDQ $8, CX
+ MOVQ (SI), R8
+ ADDQ $8, SI
IMULQ R14, R8
ROLQ $31, R8
IMULQ R13, R8
@@ -117,18 +117,18 @@ wordLoop:
XORQ R8, AX
ROLQ $27, AX
IMULQ R13, AX
- ADDQ R15, AX
+ ADDQ DI, AX
- CMPQ CX, BX
+ CMPQ SI, BX
JLE wordLoop
fourByte:
ADDQ $4, BX
- CMPQ CX, BX
+ CMPQ SI, BX
JG singles
- MOVL (CX), R8
- ADDQ $4, CX
+ MOVL (SI), R8
+ ADDQ $4, SI
IMULQ R13, R8
XORQ R8, AX
@@ -138,19 +138,19 @@ fourByte:
singles:
ADDQ $4, BX
- CMPQ CX, BX
+ CMPQ SI, BX
JGE finalize
singlesLoop:
- MOVBQZX (CX), R12
- ADDQ $1, CX
+ MOVBQZX (SI), R12
+ ADDQ $1, SI
IMULQ ·prime5v(SB), R12
XORQ R12, AX
ROLQ $11, AX
IMULQ R13, AX
- CMPQ CX, BX
+ CMPQ SI, BX
JL singlesLoop
finalize:
@@ -179,9 +179,9 @@ TEXT ·writeBlocks(SB), NOSPLIT, $0-40
MOVQ ·prime2v(SB), R14
// Load slice.
- MOVQ b_base+8(FP), CX
+ MOVQ b_base+8(FP), SI
MOVQ b_len+16(FP), DX
- LEAQ (CX)(DX*1), BX
+ LEAQ (SI)(DX*1), BX
SUBQ $32, BX
// Load vN from d.
@@ -199,7 +199,7 @@ blockLoop:
round(R10)
round(R11)
- CMPQ CX, BX
+ CMPQ SI, BX
JLE blockLoop
// Copy vN back to d.
@@ -208,8 +208,8 @@ blockLoop:
MOVQ R10, 16(AX)
MOVQ R11, 24(AX)
- // The number of bytes written is CX minus the old base pointer.
- SUBQ b_base+8(FP), CX
- MOVQ CX, ret+32(FP)
+ // The number of bytes written is SI minus the old base pointer.
+ SUBQ b_base+8(FP), SI
+ MOVQ SI, ret+32(FP)
RET
diff --git a/vendor/github.com/cespare/xxhash/v2/xxhash_unsafe.go b/vendor/github.com/cespare/xxhash/v2/xxhash_unsafe.go
index 53bf76efbc24..376e0ca2e497 100644
--- a/vendor/github.com/cespare/xxhash/v2/xxhash_unsafe.go
+++ b/vendor/github.com/cespare/xxhash/v2/xxhash_unsafe.go
@@ -6,41 +6,52 @@
package xxhash
import (
- "reflect"
"unsafe"
)
-// Notes:
+// In the future it's possible that compiler optimizations will make these
+// XxxString functions unnecessary by realizing that calls such as
+// Sum64([]byte(s)) don't need to copy s. See https://golang.org/issue/2205.
+// If that happens, even if we keep these functions they can be replaced with
+// the trivial safe code.
+
+// NOTE: The usual way of doing an unsafe string-to-[]byte conversion is:
//
-// See https://groups.google.com/d/msg/golang-nuts/dcjzJy-bSpw/tcZYBzQqAQAJ
-// for some discussion about these unsafe conversions.
+// var b []byte
+// bh := (*reflect.SliceHeader)(unsafe.Pointer(&b))
+// bh.Data = (*reflect.StringHeader)(unsafe.Pointer(&s)).Data
+// bh.Len = len(s)
+// bh.Cap = len(s)
//
-// In the future it's possible that compiler optimizations will make these
-// unsafe operations unnecessary: https://golang.org/issue/2205.
+// Unfortunately, as of Go 1.15.3 the inliner's cost model assigns a high enough
+// weight to this sequence of expressions that any function that uses it will
+// not be inlined. Instead, the functions below use a different unsafe
+// conversion designed to minimize the inliner weight and allow both to be
+// inlined. There is also a test (TestInlining) which verifies that these are
+// inlined.
//
-// Both of these wrapper functions still incur function call overhead since they
-// will not be inlined. We could write Go/asm copies of Sum64 and Digest.Write
-// for strings to squeeze out a bit more speed. Mid-stack inlining should
-// eventually fix this.
+// See https://github.com/golang/go/issues/42739 for discussion.
// Sum64String computes the 64-bit xxHash digest of s.
// It may be faster than Sum64([]byte(s)) by avoiding a copy.
func Sum64String(s string) uint64 {
- var b []byte
- bh := (*reflect.SliceHeader)(unsafe.Pointer(&b))
- bh.Data = (*reflect.StringHeader)(unsafe.Pointer(&s)).Data
- bh.Len = len(s)
- bh.Cap = len(s)
+ b := *(*[]byte)(unsafe.Pointer(&sliceHeader{s, len(s)}))
return Sum64(b)
}
// WriteString adds more data to d. It always returns len(s), nil.
// It may be faster than Write([]byte(s)) by avoiding a copy.
func (d *Digest) WriteString(s string) (n int, err error) {
- var b []byte
- bh := (*reflect.SliceHeader)(unsafe.Pointer(&b))
- bh.Data = (*reflect.StringHeader)(unsafe.Pointer(&s)).Data
- bh.Len = len(s)
- bh.Cap = len(s)
- return d.Write(b)
+ d.Write(*(*[]byte)(unsafe.Pointer(&sliceHeader{s, len(s)})))
+ // d.Write always returns len(s), nil.
+ // Ignoring the return output and returning these fixed values buys a
+ // savings of 6 in the inliner's cost model.
+ return len(s), nil
+}
+
+// sliceHeader is similar to reflect.SliceHeader, but it assumes that the layout
+// of the first two words is the same as the layout of a string.
+type sliceHeader struct {
+ s string
+ cap int
}
diff --git a/third_party/VENDOR-LICENSE/github.com/vdemeester/k8s-pkg-credentialprovider/LICENSE b/vendor/github.com/chrismellard/docker-credential-acr-env/LICENSE
similarity index 99%
rename from third_party/VENDOR-LICENSE/github.com/vdemeester/k8s-pkg-credentialprovider/LICENSE
rename to vendor/github.com/chrismellard/docker-credential-acr-env/LICENSE
index 3de5f349011a..d64569567334 100644
--- a/third_party/VENDOR-LICENSE/github.com/vdemeester/k8s-pkg-credentialprovider/LICENSE
+++ b/vendor/github.com/chrismellard/docker-credential-acr-env/LICENSE
@@ -1,3 +1,4 @@
+
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
@@ -178,7 +179,7 @@
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "{}"
+ boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
@@ -186,7 +187,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
- Copyright 2019-2020 Vincent Demeester
+ Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
diff --git a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/credhelper/helper.go b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/credhelper/helper.go
new file mode 100644
index 000000000000..87e8345aadfe
--- /dev/null
+++ b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/credhelper/helper.go
@@ -0,0 +1,59 @@
+/*
+Copyright © 2020 Chris Mellard chris.mellard@icloud.com
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+package credhelper
+
+import (
+ "errors"
+ "fmt"
+
+ "github.com/Azure/go-autorest/autorest/azure/auth"
+ "github.com/chrismellard/docker-credential-acr-env/pkg/registry"
+ "github.com/chrismellard/docker-credential-acr-env/pkg/token"
+ "github.com/docker/docker-credential-helpers/credentials"
+)
+
+const tokenUsername = ""
+
+type ACRCredHelper struct {
+}
+
+func NewACRCredentialsHelper() credentials.Helper {
+ return &ACRCredHelper{}
+}
+
+func (a ACRCredHelper) Add(_ *credentials.Credentials) error {
+ return errors.New("list is unimplemented")
+}
+
+func (a ACRCredHelper) Delete(_ string) error {
+ return errors.New("list is unimplemented")
+}
+
+func (a ACRCredHelper) Get(serverURL string) (string, string, error) {
+ spToken, settings, err := token.GetServicePrincipalTokenFromEnvironment()
+ if err != nil {
+ return "", "", fmt.Errorf("failed to acquire sp token %w", err)
+ }
+ refreshToken, err := registry.GetRegistryRefreshTokenFromAADExchange(serverURL, spToken, settings.Values[auth.TenantID])
+ if err != nil {
+ return "", "", fmt.Errorf("failed to acquire refresh token %w", err)
+ }
+ return tokenUsername, refreshToken, nil
+}
+
+func (a ACRCredHelper) List() (map[string]string, error) {
+ return nil, errors.New("list is unimplemented")
+}
diff --git a/vendor/k8s.io/legacy-cloud-providers/azure/auth/doc.go b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/const.go
similarity index 69%
rename from vendor/k8s.io/legacy-cloud-providers/azure/auth/doc.go
rename to vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/const.go
index 073f70a41824..4d29da79b12c 100644
--- a/vendor/k8s.io/legacy-cloud-providers/azure/auth/doc.go
+++ b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/const.go
@@ -1,5 +1,5 @@
/*
-Copyright 2019 The Kubernetes Authors.
+Copyright © 2020 Chris Mellard chris.mellard@icloud.com
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
@@ -13,6 +13,14 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
+package registry
-// Package auth provides a general libraty to authorize Azure ARM clients.
-package auth // import "k8s.io/legacy-cloud-providers/azure/auth"
+import (
+ "context"
+ "time"
+)
+
+const secureScheme = "https://"
+
+var defaultTimeOut = time.Duration(30) * time.Second
+var OAuthHTTPContext = context.Background()
diff --git a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/registry.go b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/registry.go
new file mode 100644
index 000000000000..e546ac1e632f
--- /dev/null
+++ b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/registry.go
@@ -0,0 +1,63 @@
+/*
+Copyright © 2020 Chris Mellard chris.mellard@icloud.com
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+package registry
+
+import (
+ "context"
+ "fmt"
+ "net/url"
+
+ "github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/adal"
+)
+
+// GetRegistryRefreshTokenFromAADExchange retrieves an OAuth2 refresh token for the registry specified by serverURL
+func GetRegistryRefreshTokenFromAADExchange(serverURL string, principalToken *adal.ServicePrincipalToken, tenantID string) (string, error) {
+
+ err := principalToken.EnsureFresh()
+ if err != nil {
+ return "", fmt.Errorf("error refreshing sp token - %w", err)
+ }
+
+ registryName, err := getRegistryURL(serverURL)
+ if err != nil {
+ return "", fmt.Errorf("failed to parse server URL - %w", err)
+ }
+ refreshTokenClient := containerregistry.NewRefreshTokensClient(registryName.String())
+ authorizer := autorest.NewBearerAuthorizer(principalToken)
+ refreshTokenClient.Authorizer = authorizer
+ ctx, cancel := context.WithTimeout(OAuthHTTPContext, defaultTimeOut)
+ defer cancel()
+
+ rt, err := refreshTokenClient.GetFromExchange(ctx, "access_token", serverURL, tenantID, "", principalToken.Token().AccessToken)
+
+ if err != nil {
+ return "", fmt.Errorf("failed to get refresh token for container registry - %w", err)
+ }
+
+ return *rt.RefreshToken, nil
+}
+
+// parseRegistryName parses a serverURL and returns the registry name (i.e. minus transport scheme)
+func getRegistryURL(serverURL string) (*url.URL, error) {
+ sURL, err := url.Parse(secureScheme + serverURL)
+ if err != nil {
+ return &url.URL{}, fmt.Errorf("failed to parse server URL - %w", err)
+ }
+
+ return sURL, nil
+}
diff --git a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/token/token.go b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/token/token.go
new file mode 100644
index 000000000000..a76be1e4ff16
--- /dev/null
+++ b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/token/token.go
@@ -0,0 +1,72 @@
+/*
+Copyright © 2020 Chris Mellard chris.mellard@icloud.com
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+package token
+
+import (
+ "fmt"
+
+ "github.com/Azure/go-autorest/autorest/adal"
+ "github.com/Azure/go-autorest/autorest/azure/auth"
+)
+
+func GetServicePrincipalTokenFromEnvironment() (*adal.ServicePrincipalToken, auth.EnvironmentSettings, error) {
+ settings, err := auth.GetSettingsFromEnvironment()
+ if err != nil {
+ return &adal.ServicePrincipalToken{}, auth.EnvironmentSettings{}, fmt.Errorf("failed to get auth settings from environment - %w", err)
+ }
+
+ spToken, err := getServicePrincipalToken(settings, settings.Environment.ResourceManagerEndpoint)
+ if err != nil {
+ return &adal.ServicePrincipalToken{}, auth.EnvironmentSettings{}, fmt.Errorf("failed to initialise sp token config %w", err)
+ }
+
+ return spToken, settings, nil
+}
+
+// getServicePrincipalToken retrieves an Azure AD OAuth2 token from the supplied environment settings for the specified resource
+func getServicePrincipalToken(settings auth.EnvironmentSettings, resource string) (*adal.ServicePrincipalToken, error) {
+
+ //1.Client Credentials
+ if _, e := settings.GetClientCredentials(); e == nil {
+ clientCredentialsConfig, err := settings.GetClientCredentials()
+ if err != nil {
+ return &adal.ServicePrincipalToken{}, fmt.Errorf("failed to get client credentials settings from environment - %w", err)
+ }
+ oAuthConfig, err := adal.NewOAuthConfig(settings.Environment.ActiveDirectoryEndpoint, clientCredentialsConfig.TenantID)
+ if err != nil {
+ return &adal.ServicePrincipalToken{}, fmt.Errorf("failed to initialise OAuthConfig - %w", err)
+ }
+ return adal.NewServicePrincipalToken(*oAuthConfig, clientCredentialsConfig.ClientID, clientCredentialsConfig.ClientSecret, clientCredentialsConfig.Resource)
+ }
+
+ //2. Client Certificate
+ if _, e := settings.GetClientCertificate(); e == nil {
+ return &adal.ServicePrincipalToken{}, fmt.Errorf("authentication method currently unsupported")
+ }
+
+ //3. Username Password
+ if _, e := settings.GetUsernamePassword(); e == nil {
+ return &adal.ServicePrincipalToken{}, fmt.Errorf("authentication method currently unsupported")
+ }
+
+ // 4. MSI
+ msiEndpoint, err := adal.GetMSIEndpoint()
+ if err != nil {
+ return &adal.ServicePrincipalToken{}, fmt.Errorf("unable to determine MSIEndpoint %w", err)
+ }
+
+ return adal.NewServicePrincipalTokenFromMSI(msiEndpoint, resource)
+}
diff --git a/vendor/github.com/dimchansky/utfbom/.gitignore b/vendor/github.com/dimchansky/utfbom/.gitignore
new file mode 100644
index 000000000000..d7ec5cebb98d
--- /dev/null
+++ b/vendor/github.com/dimchansky/utfbom/.gitignore
@@ -0,0 +1,37 @@
+# Binaries for programs and plugins
+*.exe
+*.dll
+*.so
+*.dylib
+*.o
+*.a
+
+# Folders
+_obj
+_test
+
+# Architecture specific extensions/prefixes
+*.[568vq]
+[568vq].out
+
+*.cgo1.go
+*.cgo2.c
+_cgo_defun.c
+_cgo_gotypes.go
+_cgo_export.*
+
+_testmain.go
+
+*.prof
+
+# Test binary, build with `go test -c`
+*.test
+
+# Output of the go coverage tool, specifically when used with LiteIDE
+*.out
+
+# Project-local glide cache, RE: https://github.com/Masterminds/glide/issues/736
+.glide/
+
+# Gogland
+.idea/
\ No newline at end of file
diff --git a/vendor/github.com/dimchansky/utfbom/.travis.yml b/vendor/github.com/dimchansky/utfbom/.travis.yml
new file mode 100644
index 000000000000..3512c85190d7
--- /dev/null
+++ b/vendor/github.com/dimchansky/utfbom/.travis.yml
@@ -0,0 +1,18 @@
+language: go
+
+go:
+ - '1.10'
+ - '1.11'
+
+# sudo=false makes the build run using a container
+sudo: false
+
+before_install:
+ - go get github.com/mattn/goveralls
+ - go get golang.org/x/tools/cmd/cover
+ - go get golang.org/x/tools/cmd/goimports
+ - go get github.com/golang/lint/golint
+script:
+ - gofiles=$(find ./ -name '*.go') && [ -z "$gofiles" ] || unformatted=$(goimports -l $gofiles) && [ -z "$unformatted" ] || (echo >&2 "Go files must be formatted with gofmt. Following files has problem:\n $unformatted" && false)
+ - golint ./... # This won't break the build, just show warnings
+ - $HOME/gopath/bin/goveralls -service=travis-ci
diff --git a/third_party/VENDOR-LICENSE/k8s.io/legacy-cloud-providers/LICENSE b/vendor/github.com/dimchansky/utfbom/LICENSE
similarity index 100%
rename from third_party/VENDOR-LICENSE/k8s.io/legacy-cloud-providers/LICENSE
rename to vendor/github.com/dimchansky/utfbom/LICENSE
diff --git a/vendor/github.com/dimchansky/utfbom/README.md b/vendor/github.com/dimchansky/utfbom/README.md
new file mode 100644
index 000000000000..8ece280089a5
--- /dev/null
+++ b/vendor/github.com/dimchansky/utfbom/README.md
@@ -0,0 +1,66 @@
+# utfbom [](https://godoc.org/github.com/dimchansky/utfbom) [](https://opensource.org/licenses/Apache-2.0) [](https://travis-ci.org/dimchansky/utfbom) [](https://goreportcard.com/report/github.com/dimchansky/utfbom) [](https://coveralls.io/github/dimchansky/utfbom?branch=master)
+
+The package utfbom implements the detection of the BOM (Unicode Byte Order Mark) and removing as necessary. It can also return the encoding detected by the BOM.
+
+## Installation
+
+ go get -u github.com/dimchansky/utfbom
+
+## Example
+
+```go
+package main
+
+import (
+ "bytes"
+ "fmt"
+ "io/ioutil"
+
+ "github.com/dimchansky/utfbom"
+)
+
+func main() {
+ trySkip([]byte("\xEF\xBB\xBFhello"))
+ trySkip([]byte("hello"))
+}
+
+func trySkip(byteData []byte) {
+ fmt.Println("Input:", byteData)
+
+ // just skip BOM
+ output, err := ioutil.ReadAll(utfbom.SkipOnly(bytes.NewReader(byteData)))
+ if err != nil {
+ fmt.Println(err)
+ return
+ }
+ fmt.Println("ReadAll with BOM skipping", output)
+
+ // skip BOM and detect encoding
+ sr, enc := utfbom.Skip(bytes.NewReader(byteData))
+ fmt.Printf("Detected encoding: %s\n", enc)
+ output, err = ioutil.ReadAll(sr)
+ if err != nil {
+ fmt.Println(err)
+ return
+ }
+ fmt.Println("ReadAll with BOM detection and skipping", output)
+ fmt.Println()
+}
+```
+
+Output:
+
+```
+$ go run main.go
+Input: [239 187 191 104 101 108 108 111]
+ReadAll with BOM skipping [104 101 108 108 111]
+Detected encoding: UTF8
+ReadAll with BOM detection and skipping [104 101 108 108 111]
+
+Input: [104 101 108 108 111]
+ReadAll with BOM skipping [104 101 108 108 111]
+Detected encoding: Unknown
+ReadAll with BOM detection and skipping [104 101 108 108 111]
+```
+
+
diff --git a/vendor/github.com/dimchansky/utfbom/go.mod b/vendor/github.com/dimchansky/utfbom/go.mod
new file mode 100644
index 000000000000..4b9ecc6f545e
--- /dev/null
+++ b/vendor/github.com/dimchansky/utfbom/go.mod
@@ -0,0 +1 @@
+module github.com/dimchansky/utfbom
\ No newline at end of file
diff --git a/vendor/github.com/dimchansky/utfbom/utfbom.go b/vendor/github.com/dimchansky/utfbom/utfbom.go
new file mode 100644
index 000000000000..77a303e564b1
--- /dev/null
+++ b/vendor/github.com/dimchansky/utfbom/utfbom.go
@@ -0,0 +1,192 @@
+// Package utfbom implements the detection of the BOM (Unicode Byte Order Mark) and removing as necessary.
+// It wraps an io.Reader object, creating another object (Reader) that also implements the io.Reader
+// interface but provides automatic BOM checking and removing as necessary.
+package utfbom
+
+import (
+ "errors"
+ "io"
+)
+
+// Encoding is type alias for detected UTF encoding.
+type Encoding int
+
+// Constants to identify detected UTF encodings.
+const (
+ // Unknown encoding, returned when no BOM was detected
+ Unknown Encoding = iota
+
+ // UTF8, BOM bytes: EF BB BF
+ UTF8
+
+ // UTF-16, big-endian, BOM bytes: FE FF
+ UTF16BigEndian
+
+ // UTF-16, little-endian, BOM bytes: FF FE
+ UTF16LittleEndian
+
+ // UTF-32, big-endian, BOM bytes: 00 00 FE FF
+ UTF32BigEndian
+
+ // UTF-32, little-endian, BOM bytes: FF FE 00 00
+ UTF32LittleEndian
+)
+
+// String returns a user-friendly string representation of the encoding. Satisfies fmt.Stringer interface.
+func (e Encoding) String() string {
+ switch e {
+ case UTF8:
+ return "UTF8"
+ case UTF16BigEndian:
+ return "UTF16BigEndian"
+ case UTF16LittleEndian:
+ return "UTF16LittleEndian"
+ case UTF32BigEndian:
+ return "UTF32BigEndian"
+ case UTF32LittleEndian:
+ return "UTF32LittleEndian"
+ default:
+ return "Unknown"
+ }
+}
+
+const maxConsecutiveEmptyReads = 100
+
+// Skip creates Reader which automatically detects BOM (Unicode Byte Order Mark) and removes it as necessary.
+// It also returns the encoding detected by the BOM.
+// If the detected encoding is not needed, you can call the SkipOnly function.
+func Skip(rd io.Reader) (*Reader, Encoding) {
+ // Is it already a Reader?
+ b, ok := rd.(*Reader)
+ if ok {
+ return b, Unknown
+ }
+
+ enc, left, err := detectUtf(rd)
+ return &Reader{
+ rd: rd,
+ buf: left,
+ err: err,
+ }, enc
+}
+
+// SkipOnly creates Reader which automatically detects BOM (Unicode Byte Order Mark) and removes it as necessary.
+func SkipOnly(rd io.Reader) *Reader {
+ r, _ := Skip(rd)
+ return r
+}
+
+// Reader implements automatic BOM (Unicode Byte Order Mark) checking and
+// removing as necessary for an io.Reader object.
+type Reader struct {
+ rd io.Reader // reader provided by the client
+ buf []byte // buffered data
+ err error // last error
+}
+
+// Read is an implementation of io.Reader interface.
+// The bytes are taken from the underlying Reader, but it checks for BOMs, removing them as necessary.
+func (r *Reader) Read(p []byte) (n int, err error) {
+ if len(p) == 0 {
+ return 0, nil
+ }
+
+ if r.buf == nil {
+ if r.err != nil {
+ return 0, r.readErr()
+ }
+
+ return r.rd.Read(p)
+ }
+
+ // copy as much as we can
+ n = copy(p, r.buf)
+ r.buf = nilIfEmpty(r.buf[n:])
+ return n, nil
+}
+
+func (r *Reader) readErr() error {
+ err := r.err
+ r.err = nil
+ return err
+}
+
+var errNegativeRead = errors.New("utfbom: reader returned negative count from Read")
+
+func detectUtf(rd io.Reader) (enc Encoding, buf []byte, err error) {
+ buf, err = readBOM(rd)
+
+ if len(buf) >= 4 {
+ if isUTF32BigEndianBOM4(buf) {
+ return UTF32BigEndian, nilIfEmpty(buf[4:]), err
+ }
+ if isUTF32LittleEndianBOM4(buf) {
+ return UTF32LittleEndian, nilIfEmpty(buf[4:]), err
+ }
+ }
+
+ if len(buf) > 2 && isUTF8BOM3(buf) {
+ return UTF8, nilIfEmpty(buf[3:]), err
+ }
+
+ if (err != nil && err != io.EOF) || (len(buf) < 2) {
+ return Unknown, nilIfEmpty(buf), err
+ }
+
+ if isUTF16BigEndianBOM2(buf) {
+ return UTF16BigEndian, nilIfEmpty(buf[2:]), err
+ }
+ if isUTF16LittleEndianBOM2(buf) {
+ return UTF16LittleEndian, nilIfEmpty(buf[2:]), err
+ }
+
+ return Unknown, nilIfEmpty(buf), err
+}
+
+func readBOM(rd io.Reader) (buf []byte, err error) {
+ const maxBOMSize = 4
+ var bom [maxBOMSize]byte // used to read BOM
+
+ // read as many bytes as possible
+ for nEmpty, n := 0, 0; err == nil && len(buf) < maxBOMSize; buf = bom[:len(buf)+n] {
+ if n, err = rd.Read(bom[len(buf):]); n < 0 {
+ panic(errNegativeRead)
+ }
+ if n > 0 {
+ nEmpty = 0
+ } else {
+ nEmpty++
+ if nEmpty >= maxConsecutiveEmptyReads {
+ err = io.ErrNoProgress
+ }
+ }
+ }
+ return
+}
+
+func isUTF32BigEndianBOM4(buf []byte) bool {
+ return buf[0] == 0x00 && buf[1] == 0x00 && buf[2] == 0xFE && buf[3] == 0xFF
+}
+
+func isUTF32LittleEndianBOM4(buf []byte) bool {
+ return buf[0] == 0xFF && buf[1] == 0xFE && buf[2] == 0x00 && buf[3] == 0x00
+}
+
+func isUTF8BOM3(buf []byte) bool {
+ return buf[0] == 0xEF && buf[1] == 0xBB && buf[2] == 0xBF
+}
+
+func isUTF16BigEndianBOM2(buf []byte) bool {
+ return buf[0] == 0xFE && buf[1] == 0xFF
+}
+
+func isUTF16LittleEndianBOM2(buf []byte) bool {
+ return buf[0] == 0xFF && buf[1] == 0xFE
+}
+
+func nilIfEmpty(buf []byte) (res []byte) {
+ if len(buf) > 0 {
+ res = buf
+ }
+ return
+}
diff --git a/vendor/github.com/evanphx/json-patch/.gitignore b/vendor/github.com/evanphx/json-patch/.gitignore
new file mode 100644
index 000000000000..b7ed7f956df8
--- /dev/null
+++ b/vendor/github.com/evanphx/json-patch/.gitignore
@@ -0,0 +1,6 @@
+# editor and IDE paraphernalia
+.idea
+.vscode
+
+# macOS paraphernalia
+.DS_Store
diff --git a/vendor/github.com/evanphx/json-patch/patch.go b/vendor/github.com/evanphx/json-patch/patch.go
index 18298549076e..dc2b7e51e60b 100644
--- a/vendor/github.com/evanphx/json-patch/patch.go
+++ b/vendor/github.com/evanphx/json-patch/patch.go
@@ -412,6 +412,17 @@ func (d *partialArray) set(key string, val *lazyNode) error {
if err != nil {
return err
}
+
+ if idx < 0 {
+ if !SupportNegativeIndices {
+ return errors.Wrapf(ErrInvalidIndex, "Unable to access invalid index: %d", idx)
+ }
+ if idx < -len(*d) {
+ return errors.Wrapf(ErrInvalidIndex, "Unable to access invalid index: %d", idx)
+ }
+ idx += len(*d)
+ }
+
(*d)[idx] = val
return nil
}
@@ -462,6 +473,16 @@ func (d *partialArray) get(key string) (*lazyNode, error) {
return nil, err
}
+ if idx < 0 {
+ if !SupportNegativeIndices {
+ return nil, errors.Wrapf(ErrInvalidIndex, "Unable to access invalid index: %d", idx)
+ }
+ if idx < -len(*d) {
+ return nil, errors.Wrapf(ErrInvalidIndex, "Unable to access invalid index: %d", idx)
+ }
+ idx += len(*d)
+ }
+
if idx >= len(*d) {
return nil, errors.Wrapf(ErrInvalidIndex, "Unable to access invalid index: %d", idx)
}
@@ -547,6 +568,29 @@ func (p Patch) replace(doc *container, op Operation) error {
return errors.Wrapf(err, "replace operation failed to decode path")
}
+ if path == "" {
+ val := op.value()
+
+ if val.which == eRaw {
+ if !val.tryDoc() {
+ if !val.tryAry() {
+ return errors.Wrapf(err, "replace operation value must be object or array")
+ }
+ }
+ }
+
+ switch val.which {
+ case eAry:
+ *doc = &val.ary
+ case eDoc:
+ *doc = &val.doc
+ case eRaw:
+ return errors.Wrapf(err, "replace operation hit impossible case")
+ }
+
+ return nil
+ }
+
con, key := findObject(doc, path)
if con == nil {
@@ -613,6 +657,25 @@ func (p Patch) test(doc *container, op Operation) error {
return errors.Wrapf(err, "test operation failed to decode path")
}
+ if path == "" {
+ var self lazyNode
+
+ switch sv := (*doc).(type) {
+ case *partialDoc:
+ self.doc = *sv
+ self.which = eDoc
+ case *partialArray:
+ self.ary = *sv
+ self.which = eAry
+ }
+
+ if self.equal(op.value()) {
+ return nil
+ }
+
+ return errors.Wrapf(ErrTestFailed, "testing value %s failed", path)
+ }
+
con, key := findObject(doc, path)
if con == nil {
diff --git a/vendor/github.com/google/go-containerregistry/internal/gzip/zip.go b/vendor/github.com/google/go-containerregistry/internal/gzip/zip.go
index e7d673ff6b5b..1a52694e8d91 100644
--- a/vendor/github.com/google/go-containerregistry/internal/gzip/zip.go
+++ b/vendor/github.com/google/go-containerregistry/internal/gzip/zip.go
@@ -115,3 +115,32 @@ func Is(r io.Reader) (bool, error) {
}
return bytes.Equal(magicHeader, gzipMagicHeader), nil
}
+
+// PeekReader is an io.Reader that also implements Peek a la bufio.Reader.
+type PeekReader interface {
+ io.Reader
+ Peek(n int) ([]byte, error)
+}
+
+// Peek detects whether the input stream is gzip compressed.
+//
+// If r implements Peek, we will use that directly, otherwise a small number
+// of bytes are buffered to Peek at the gzip header, and the returned
+// PeekReader can be used as a replacement for the consumed input io.Reader.
+func Peek(r io.Reader) (bool, PeekReader, error) {
+ var pr PeekReader
+ if p, ok := r.(PeekReader); ok {
+ pr = p
+ } else {
+ pr = bufio.NewReader(r)
+ }
+ header, err := pr.Peek(2)
+ if err != nil {
+ // https://github.com/google/go-containerregistry/issues/367
+ if err == io.EOF {
+ return false, pr, nil
+ }
+ return false, pr, err
+ }
+ return bytes.Equal(header, gzipMagicHeader), pr, nil
+}
diff --git a/vendor/github.com/google/go-containerregistry/internal/verify/verify.go b/vendor/github.com/google/go-containerregistry/internal/verify/verify.go
index 9d62214f6f63..463f7e4b39c3 100644
--- a/vendor/github.com/google/go-containerregistry/internal/verify/verify.go
+++ b/vendor/github.com/google/go-containerregistry/internal/verify/verify.go
@@ -38,6 +38,18 @@ type verifyReader struct {
gotSize, wantSize int64
}
+// Error provides information about the failed hash verification.
+type Error struct {
+ got string
+ want v1.Hash
+ gotSize int64
+}
+
+func (v Error) Error() string {
+ return fmt.Sprintf("error verifying %s checksum after reading %d bytes; got %q, want %q",
+ v.want.Algorithm, v.gotSize, v.got, v.want)
+}
+
// Read implements io.Reader
func (vc *verifyReader) Read(b []byte) (int, error) {
n, err := vc.inner.Read(b)
@@ -46,10 +58,13 @@ func (vc *verifyReader) Read(b []byte) (int, error) {
if vc.wantSize != SizeUnknown && vc.gotSize != vc.wantSize {
return n, fmt.Errorf("error verifying size; got %d, want %d", vc.gotSize, vc.wantSize)
}
- got := hex.EncodeToString(vc.hasher.Sum(make([]byte, 0, vc.hasher.Size())))
+ got := hex.EncodeToString(vc.hasher.Sum(nil))
if want := vc.expected.Hex; got != want {
- return n, fmt.Errorf("error verifying %s checksum after reading %d bytes; got %q, want %q",
- vc.expected.Algorithm, vc.gotSize, got, want)
+ return n, Error{
+ got: vc.expected.Algorithm + ":" + got,
+ want: vc.expected,
+ gotSize: vc.gotSize,
+ }
}
}
return n, err
@@ -69,9 +84,9 @@ func ReadCloser(r io.ReadCloser, size int64, h v1.Hash) (io.ReadCloser, error) {
if err != nil {
return nil, err
}
- var r2 io.Reader = r
+ r2 := io.TeeReader(r, w) // pass all writes to the hasher.
if size != SizeUnknown {
- r2 = io.LimitReader(io.TeeReader(r, w), size)
+ r2 = io.LimitReader(r2, size) // if we know the size, limit to that size.
}
return &and.ReadCloser{
Reader: &verifyReader{
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/README.md b/vendor/github.com/google/go-containerregistry/pkg/authn/README.md
index 1eb17c7ab15e..0b46b322d038 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/README.md
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/README.md
@@ -4,15 +4,15 @@
This README outlines how we acquire and use credentials when interacting with a registry.
-As much as possible, we attempt to emulate docker's authentication behavior and configuration so that this library "just works" if you've already configured credentials that work with docker; however, when things don't work, a basic understanding of what's going on can help with debugging.
+As much as possible, we attempt to emulate `docker`'s authentication behavior and configuration so that this library "just works" if you've already configured credentials that work with `docker`; however, when things don't work, a basic understanding of what's going on can help with debugging.
-The official documentation for how docker authentication works is (reasonably) scattered across several different sites and GitHub repositories, so we've tried to summarize the relevant bits here.
+The official documentation for how authentication with `docker` works is (reasonably) scattered across several different sites and GitHub repositories, so we've tried to summarize the relevant bits here.
## tl;dr for consumers of this package
By default, [`pkg/v1/remote`](https://godoc.org/github.com/google/go-containerregistry/pkg/v1/remote) uses [`Anonymous`](https://godoc.org/github.com/google/go-containerregistry/pkg/authn#Anonymous) credentials (i.e. _none_), which for most registries will only allow read access to public images.
-To use the credentials found in your docker config file, you can use the [`DefaultKeychain`](https://godoc.org/github.com/google/go-containerregistry/pkg/authn#DefaultKeychain), e.g.:
+To use the credentials found in your Docker config file, you can use the [`DefaultKeychain`](https://godoc.org/github.com/google/go-containerregistry/pkg/authn#DefaultKeychain), e.g.:
```go
package main
@@ -42,15 +42,95 @@ func main() {
}
```
-(If you're only using [gcr.io](https://gcr.io), see the [`pkg/v1/google.Keychain`](https://godoc.org/github.com/google/go-containerregistry/pkg/v1/google#Keychain), which emulates [`docker-credential-gcr`](https://github.com/GoogleCloudPlatform/docker-credential-gcr).)
+The `DefaultKeychain` will use credentials as described in your Docker config file -- usually `~/.docker/config.json`, or `%USERPROFILE%\.docker\config.json` on Windows -- or the location described by the `DOCKER_CONFIG` environment variable, if set.
-## The Config File
+If those are not found, `DefaultKeychain` will look for credentials configured using [Podman's expectation](https://docs.podman.io/en/latest/markdown/podman-login.1.html) that these are found in `${XDG_RUNTIME_DIR}/containers/auth.json`.
-This file contains various configuration options for docker and is (by default) located at:
-* `$HOME/.docker/config.json` (on linux and darwin), or
-* `%USERPROFILE%\.docker\config.json` (on windows).
+[See below](#docker-config-auth) for more information about what is configured in this file.
-You can override this location with the `DOCKER_CONFIG` environment variable.
+## Emulating Cloud Provider Credential Helpers
+
+[`pkg/v1/google.Keychain`](https://pkg.go.dev/github.com/google/go-containerregistry/pkg/v1/google#Keychain) provides a `Keychain` implementation that emulates [`docker-credential-gcr`](https://github.com/GoogleCloudPlatform/docker-credential-gcr) to find credentials in the environment.
+See [`google.NewEnvAuthenticator`](https://pkg.go.dev/github.com/google/go-containerregistry/pkg/v1/google#NewEnvAuthenticator) and [`google.NewGcloudAuthenticator`](https://pkg.go.dev/github.com/google/go-containerregistry/pkg/v1/google#NewGcloudAuthenticator) for more information.
+
+To emulate other credential helpers without requiring them to be available as executables, [`NewKeychainFromHelper`](https://pkg.go.dev/github.com/google/go-containerregistry/pkg/authn#NewKeychainFromHelper) provides an adapter that takes a Go implementation satisfying a subset of the [`credentials.Helper`](https://pkg.go.dev/github.com/docker/docker-credential-helpers/credentials#Helper) interface, and makes it available as a `Keychain`.
+
+This means that you can emulate, for example, [Amazon ECR's `docker-credential-ecr-login` credential helper](https://github.com/awslabs/amazon-ecr-credential-helper) using the same implementation:
+
+```go
+import (
+ ecr "github.com/awslabs/amazon-ecr-credential-helper/ecr-login"
+ "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api"
+
+ "github.com/google/go-containerregistry/pkg/authn"
+ "github.com/google/go-containerregistry/pkg/v1/remote"
+)
+
+func main() {
+ // ...
+ ecrHelper := ecr.ECRHelper{ClientFactory: api.DefaultClientFactory{}}
+ img, err := remote.Get(ref, remote.WithAuthFromKeychain(authn.NewKeychainFromHelper(ecrHelper)))
+ if err != nil {
+ panic(err)
+ }
+ // ...
+}
+```
+
+Likewise, you can emulate [Azure's ACR `docker-credential-acr-env` credential helper](https://github.com/chrismellard/docker-credential-acr-env):
+
+```go
+import (
+ "github.com/chrismellard/docker-credential-acr-env/pkg/credhelper"
+
+ "github.com/google/go-containerregistry/pkg/authn"
+ "github.com/google/go-containerregistry/pkg/v1/remote"
+)
+
+func main() {
+ // ...
+ acrHelper := credhelper.NewACRCredentialsHelper()
+ img, err := remote.Get(ref, remote.WithAuthFromKeychain(authn.NewKeychainFromHelper(acrHelper)))
+ if err != nil {
+ panic(err)
+ }
+ // ...
+}
+```
+
+
+
+## Using Multiple `Keychain`s
+
+[`NewMultiKeychain`](https://pkg.go.dev/github.com/google/go-containerregistry/pkg/authn#NewMultiKeychain) allows you to specify multiple `Keychain` implementations, which will be checked in order when credentials are needed.
+
+For example:
+
+```go
+kc := authn.NewMultiKeychain(
+ authn.DefaultKeychain,
+ google.Keychain,
+ authn.NewFromHelper(ecr.ECRHelper{ClientFactory: api.DefaultClientFactory{}}),
+ authn.NewFromHelper(acr.ACRCredHelper{}),
+)
+```
+
+This multi-keychain will:
+
+- first check for credentials found in the Docker config file, as describe above, then
+- check for GCP credentials available in the environment, as described above, then
+- check for ECR credentials by emulating the ECR credential helper, then
+- check for ACR credentials by emulating the ACR credential helper.
+
+If any keychain implementation is able to provide credentials for the request, they will be used, and further keychain implementations will not be consulted.
+
+If no implementations are able to provide credentials, `Anonymous` credentials will be used.
+
+## Docker Config Auth
+
+What follows attempts to gather useful information about Docker's config.json and make it available in one place.
+
+If you have questions, please [file an issue](https://github.com/google/go-containerregistry/issues/new).
### Plaintext
@@ -92,7 +172,7 @@ For what it's worth, this config file is equivalent to:
### Helpers
-If you log in like this, docker will warn you that you should use a [credential helper](https://docs.docker.com/engine/reference/commandline/login/#credentials-store), and you should!
+If you log in like this, `docker` will warn you that you should use a [credential helper](https://docs.docker.com/engine/reference/commandline/login/#credentials-store), and you should!
To configure a global credential helper:
```json
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.mod b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.mod
index 10bbb5a0dc47..d725ccbcbfb5 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.mod
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.mod
@@ -3,12 +3,19 @@ module github.com/google/go-containerregistry/pkg/authn/k8schain
go 1.14
require (
- github.com/google/go-containerregistry v0.5.2-0.20210609162550-f0ce2270b3b4
- github.com/vdemeester/k8s-pkg-credentialprovider v1.21.0-1
- golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d // indirect
- k8s.io/api v0.21.1
- k8s.io/apimachinery v0.21.1
- k8s.io/client-go v0.21.1
+ github.com/aws/aws-sdk-go-v2/config v1.12.0 // indirect
+ github.com/aws/aws-sdk-go-v2/service/ecr v1.13.0 // indirect
+ github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.10.0 // indirect
+ github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20211215200129-69c85dc22db6
+ github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86
+ github.com/google/go-containerregistry v0.8.1-0.20220110151055-a61fd0a8e2bb
+ github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20220110151055-a61fd0a8e2bb
+ golang.org/x/sys v0.0.0-20220111092808-5a964db01320 // indirect
+ k8s.io/api v0.22.5
+ k8s.io/client-go v0.22.5
)
-replace github.com/google/go-containerregistry => ../../..
+replace (
+ github.com/google/go-containerregistry => ../../../
+ github.com/google/go-containerregistry/pkg/authn/kubernetes => ../kubernetes/
+)
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.sum b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.sum
index 1ef28799bfc1..51049edf5b21 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.sum
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.sum
@@ -7,7 +7,6 @@ cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxK
cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc=
cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0=
cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To=
-cloud.google.com/go v0.51.0/go.mod h1:hWtGJ6gnXH+KgDv+V0zFGDvpi07n3z8ZNj3T1RW0Gcw=
cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4=
cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M=
cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc=
@@ -27,6 +26,9 @@ cloud.google.com/go v0.90.0/go.mod h1:kRX0mNRHe0e2rC6oNakvwQqzyDmg57xJ+SZU1eT2aD
cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+YI=
cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4=
cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc=
+cloud.google.com/go v0.98.0/go.mod h1:ua6Ush4NALrHk5QXDWnjvZHN93OuF0HfuEPq9I1X0cM=
+cloud.google.com/go v0.99.0 h1:y/cM2iqGgGi5D5DQZl6D9STN/3dR/Vx5Mp8s752oJTY=
+cloud.google.com/go v0.99.0/go.mod h1:w0Xx2nLzqWJPuozYQX+hFfCSI8WioryfRDzkoI/Y2ZA=
cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o=
cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE=
cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc=
@@ -36,6 +38,7 @@ cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM7
cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE=
cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk=
cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk=
+cloud.google.com/go/firestore v1.6.1/go.mod h1:asNXNOzBdyVQmEU+ggO8UPodTkEVFW5Qx+rwHnAz+EY=
cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I=
cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw=
cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA=
@@ -47,42 +50,39 @@ cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RX
cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0=
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
github.com/Azure/azure-sdk-for-go v16.2.1+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
-github.com/Azure/azure-sdk-for-go v43.0.0+incompatible h1:/wSNCu0e6EsHFR4Qa3vBEBbicaprEHMyyga9g8RTULI=
-github.com/Azure/azure-sdk-for-go v43.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
+github.com/Azure/azure-sdk-for-go v46.4.0+incompatible h1:fCN6Pi+tEiEwFa8RSmtVlFHRXEZ+DJm9gfx/MKqYWw4=
+github.com/Azure/azure-sdk-for-go v46.4.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
github.com/Azure/go-autorest v10.8.1+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
-github.com/Azure/go-autorest/autorest v0.9.0/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+BFDTQ8rEZB0s4Yfa6bI=
github.com/Azure/go-autorest/autorest v0.11.1/go.mod h1:JFgpikqFJ/MleTTxwepExTKnFUKKszPS8UavbQYUMuw=
-github.com/Azure/go-autorest/autorest v0.11.12 h1:gI8ytXbxMfI+IVbI9mP2JGCTXIuhHLgRlvQ9X4PsnHE=
-github.com/Azure/go-autorest/autorest v0.11.12/go.mod h1:eipySxLmqSyC5s5k1CLupqet0PSENBEDP93LQ9a8QYw=
-github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEgQTmVqjGhiHBW7RJJEciWzS0=
+github.com/Azure/go-autorest/autorest v0.11.6/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
+github.com/Azure/go-autorest/autorest v0.11.8/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
+github.com/Azure/go-autorest/autorest v0.11.18 h1:90Y4srNYrwOtAgVo3ndrQkTYn6kf1Eg/AjTFJ8Is2aM=
+github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA=
github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg=
-github.com/Azure/go-autorest/autorest/adal v0.9.5 h1:Y3bBUV4rTuxenJJs41HU3qmqsb+auo+a3Lz+PlJPpL0=
+github.com/Azure/go-autorest/autorest/adal v0.9.4/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
-github.com/Azure/go-autorest/autorest/date v0.1.0/go.mod h1:plvfp3oPSKwf2DNjlBjWF/7vwR+cUD/ELuzDCXwHUVA=
+github.com/Azure/go-autorest/autorest/adal v0.9.13 h1:Mp5hbtOePIzM8pJVRa3YLrWWmZtoxRXqUEzCfJt3+/Q=
+github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M=
+github.com/Azure/go-autorest/autorest/azure/auth v0.5.2 h1:R1pgoZkhXuv4+0ky9r3e5pcnRXWcXGIuPXpC/xkc7uI=
+github.com/Azure/go-autorest/autorest/azure/auth v0.5.2/go.mod h1:q98IH4qgc3eWM4/WOeR5+YPmBuy8Lq0jNRDwSM0CuFk=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.1 h1:jwcD1wURu0+hKceV04MubZmKLzwEYOCz6q4aOtVZ+Ng=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.1/go.mod h1:JfDgiIO1/RPu6z42AdQTyjOoCM2MFhLqSBDvMEkDgcg=
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
-github.com/Azure/go-autorest/autorest/mocks v0.1.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0=
-github.com/Azure/go-autorest/autorest/mocks v0.2.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0=
github.com/Azure/go-autorest/autorest/mocks v0.4.0/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
-github.com/Azure/go-autorest/autorest/to v0.2.0/go.mod h1:GunWKJp1AEqgMaGLV+iocmRAJWqST1wQYhyyjXJ3SJc=
-github.com/Azure/go-autorest/autorest/to v0.3.0 h1:zebkZaadz7+wIQYgC7GXaz3Wb28yKYfVkkBKwc38VF8=
-github.com/Azure/go-autorest/autorest/to v0.3.0/go.mod h1:MgwOyqaIuKdG4TL/2ywSsIWKAfJfgHDo8ObuUk3t5sA=
-github.com/Azure/go-autorest/autorest/validation v0.1.0 h1:ISSNzGUh+ZSzizJWOWzs8bwpXIePbGLW4z/AmUFGH5A=
-github.com/Azure/go-autorest/autorest/validation v0.1.0/go.mod h1:Ha3z/SqBeaalWQvokg3NZAlQTalVMtOIAs1aGK7G6u8=
-github.com/Azure/go-autorest/logger v0.1.0/go.mod h1:oExouG+K6PryycPJfVSxi/koC6LSNgds39diKLz7Vrc=
-github.com/Azure/go-autorest/logger v0.2.0 h1:e4RVHVZKC5p6UANLJHkM4OfR1UKZPj8Wt8Pcx+3oqrE=
github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
-github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbtp2fGCgRFtBroKn4Dk=
+github.com/Azure/go-autorest/logger v0.2.1 h1:IG7i4p/mDa2Ce4TRyAO8IHnVhAVF3RFU+ZtXWSmf4Tg=
+github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
-github.com/GoogleCloudPlatform/k8s-cloud-provider v0.0.0-20200415212048-7901bc822317/go.mod h1:DF8FZRxMHMGv/vP2lQP6h+dYzzjpuRn24VeRiYn3qjQ=
+github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ=
github.com/Microsoft/go-winio v0.4.11/go.mod h1:VhR8bwka0BXejwEJY73c50VrPtXAaKcyvVC4A4RozmA=
github.com/Microsoft/go-winio v0.4.14/go.mod h1:qXqCSQ3Xa7+6tgxaGTIe4Kpcdsi+P8jBhyzoq1bpyYA=
github.com/Microsoft/go-winio v0.4.15-0.20190919025122-fc70bd9a86b5/go.mod h1:tTuCMEN+UleMWgg9dVx4Hu52b1bJo+59jBh3ajtinzw=
@@ -91,7 +91,6 @@ github.com/Microsoft/go-winio v0.4.16/go.mod h1:XB6nPKklQyQ7GC9LdcBEcBl8PF76WugX
github.com/Microsoft/go-winio v0.4.17-0.20210211115548-6eac466e5fa3/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
github.com/Microsoft/go-winio v0.4.17-0.20210324224401-5516f17a5958/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
github.com/Microsoft/go-winio v0.4.17/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
-github.com/Microsoft/go-winio v0.5.0/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
github.com/Microsoft/go-winio v0.5.1/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
github.com/Microsoft/hcsshim v0.8.6/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg=
github.com/Microsoft/hcsshim v0.8.7-0.20190325164909-8abdbb8205e4/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg=
@@ -100,12 +99,10 @@ github.com/Microsoft/hcsshim v0.8.9/go.mod h1:5692vkUqntj1idxauYlpoINNKeqCiG6Sg3
github.com/Microsoft/hcsshim v0.8.14/go.mod h1:NtVKoYxQuTLx6gEq0L96c9Ju4JbRJ4nY2ow3VK6a9Lg=
github.com/Microsoft/hcsshim v0.8.15/go.mod h1:x38A4YbHbdxJtc0sF6oIz+RG0npwSCAvn69iY6URG00=
github.com/Microsoft/hcsshim v0.8.16/go.mod h1:o5/SZqmR7x9JNKsW3pu+nqHm0MF8vbA+VxGOoXdC600=
-github.com/Microsoft/hcsshim v0.8.21/go.mod h1:+w2gRZ5ReXQhFOrvSQeNfhrYB/dg3oDwTOcER2fw4I4=
github.com/Microsoft/hcsshim v0.8.23/go.mod h1:4zegtUJth7lAvFyc6cH2gGQ5B3OFQim01nnU2M8jKDg=
github.com/Microsoft/hcsshim/test v0.0.0-20201218223536-d3e5debf77da/go.mod h1:5hlzMzRKMLyo42nCZ9oml8AdTlq/0cvIaBv6tK1RehU=
github.com/Microsoft/hcsshim/test v0.0.0-20210227013316-43a75bb4edd3/go.mod h1:mw7qgWloBUl75W/gVH3cQszUg1+gUITj7D6NY7ywVnY=
github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ=
-github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c=
github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU=
github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0=
github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE=
@@ -119,11 +116,50 @@ github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kd
github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o=
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY=
+github.com/armon/go-metrics v0.3.10/go.mod h1:4O98XIr/9W0sxpJ8UaYkvjk10Iff7SnFrb4QAOwNTFc=
github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
+github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY=
github.com/aws/aws-sdk-go v1.15.11/go.mod h1:mFuSZ37Z9YOHbQEwBWztmVzqXrEkub65tZoCYDt7FT0=
-github.com/aws/aws-sdk-go v1.35.24 h1:U3GNTg8+7xSM6OAJ8zksiSM4bRqxBWmVwwehvOSNG3A=
-github.com/aws/aws-sdk-go v1.35.24/go.mod h1:tlPOdRjfxPBpNIwqDj61rmsnA85v9jc0Ps9+muhnW+k=
+github.com/aws/aws-sdk-go-v2 v1.7.1/go.mod h1:L5LuPC1ZgDr2xQS7AmIec/Jlc7O/Y1u2KxJyNVab250=
+github.com/aws/aws-sdk-go-v2 v1.12.0 h1:z5bijqy+eXLK/QqF6eQcwCN2qw1k+m9OUDicqCZygu0=
+github.com/aws/aws-sdk-go-v2 v1.12.0/go.mod h1:tWhQI5N5SiMawto3uMAQJU5OUN/1ivhDDHq7HTsJvZ0=
+github.com/aws/aws-sdk-go-v2/config v1.5.0/go.mod h1:RWlPOAW3E3tbtNAqTwvSW54Of/yP3oiZXMI0xfUdjyA=
+github.com/aws/aws-sdk-go-v2/config v1.12.0 h1:WOhIzj5HdixjlvQ4SLYAOk6OUUsuu88RwcsTzexa9cg=
+github.com/aws/aws-sdk-go-v2/config v1.12.0/go.mod h1:GQONFVSDdG6RRho1C730SGNyDhS1kSTnxpOE76ptBqo=
+github.com/aws/aws-sdk-go-v2/credentials v1.3.1/go.mod h1:r0n73xwsIVagq8RsxmZbGSRQFj9As3je72C2WzUIToc=
+github.com/aws/aws-sdk-go-v2/credentials v1.7.0 h1:KFuKwPs7i5SE5a0LxqAxz75qxSjr2HnHnhu0UPGlvpM=
+github.com/aws/aws-sdk-go-v2/credentials v1.7.0/go.mod h1:Kmq64kahHJtXfmnEwnvRKeNjLBqkdP++Itln9BmQerE=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.3.0/go.mod h1:2LAuqPx1I6jNfaGDucWfA2zqQCYCOMCDHiCOciALyNw=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.9.0 h1:fPq3oloONbHaA0O8KX/KYUQk7pG9JjKBwYQvQsQDK84=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.9.0/go.mod h1:19SxQ+9zANyJCnNaoF3ovl8bFil4TaqCYEDdqNGKM+A=
+github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3 h1:YPNiEXnuWdkpNOwBFHhcLwkSmewwQRcPFO9dHmxU0qg=
+github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3/go.mod h1:L72JSFj9OwHwyukeuKFFyTj6uFWE4AjB0IQp97bd9Lc=
+github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0 h1:ArRd27pSm66f7cCBDPS77wvxiS4IRjFatpzVBD7Aojc=
+github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0/go.mod h1:KdVvdk4gb7iatuHZgIkIqvJlWHBtjCJLUtD/uO/FkWw=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.1.1/go.mod h1:Zy8smImhTdOETZqfyn01iNOe0CNggVbPjCajyaz6Gvg=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.3.3 h1:fmGqMNlFTHr9Y48qmYYv2qIo+TAsST3qZa2d1HcwBeo=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.3.3/go.mod h1:N4dv+zawriMFZBO/6UKg3zt+XO6xWOQo1neAA0lFbo4=
+github.com/aws/aws-sdk-go-v2/service/ecr v1.4.1/go.mod h1:FglZcyeiBqcbvyinl+n14aT/EWC7S1MIH+Gan2iizt0=
+github.com/aws/aws-sdk-go-v2/service/ecr v1.13.0 h1:2XQbjtiOokE9jq2CSQv2wMBMYUEZ/UXwQ0jkLsTW0lk=
+github.com/aws/aws-sdk-go-v2/service/ecr v1.13.0/go.mod h1:X9rkClmo0/dXh2fwvhkMoXR5zxirrzCqMgfU+Z0HIgs=
+github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.4.1/go.mod h1:eD5Eo4drVP2FLTw0G+SMIPWNWvQRGGTtIZR2XeAagoA=
+github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.10.0 h1:d+uTsVjpo8MNNjr+7+1axbFNr0BiLoITecb2cQwofJI=
+github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.10.0/go.mod h1:wlxlU/f1AOpsYIxt86LyrztTAIhyp/6HRNHcZjLzHjg=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.2.1/go.mod h1:zceowr5Z1Nh2WVP8bf/3ikB41IZW59E4yIYbg+pC6mw=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.6.0 h1:rwE0kWa5qm0yEoNPwC3zhrt1tFVXTmkWRlUxLayAwyc=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.6.0/go.mod h1:wTgFkG6t7jS/6Y0SILXwfspV3IXowb6ngsAlSajW0Kc=
+github.com/aws/aws-sdk-go-v2/service/sso v1.3.1/go.mod h1:J3A3RGUvuCZjvSuZEcOpHDnzZP/sKbhDWV2T1EOzFIM=
+github.com/aws/aws-sdk-go-v2/service/sso v1.8.0 h1:X77LUt6Djy3Z02r6tW7Z+4FNr6GCnEG54EXfskc19M4=
+github.com/aws/aws-sdk-go-v2/service/sso v1.8.0/go.mod h1:AB6v3BedyhVRIbPQbJnUsBmtup2pFiikpp5n3YyB6Ac=
+github.com/aws/aws-sdk-go-v2/service/sts v1.6.0/go.mod h1:q7o0j7d7HrJk/vr9uUt3BVRASvcU7gYZB9PUgPiByXg=
+github.com/aws/aws-sdk-go-v2/service/sts v1.13.0 h1:n8+dZMOvwkGtmhub8B2wYvRHut45/NB7DeNhNcUnBpg=
+github.com/aws/aws-sdk-go-v2/service/sts v1.13.0/go.mod h1:jQto17aC9pJ6xRa1g29uXZhbcS6qNT3PSnKfPShq4sY=
+github.com/aws/smithy-go v1.6.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/aws/smithy-go v1.9.1 h1:5vetTooLk4hPWV8q6ym6+lXKAT1Urnm49YkrRKo2J8o=
+github.com/aws/smithy-go v1.9.1/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20211215200129-69c85dc22db6 h1:eZSlkTaUtlhgnbn4gOl2Y248cXT+T/jtOww+pQ8m3ow=
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20211215200129-69c85dc22db6/go.mod h1:8vJsEZ4iRqG+Vx6pKhWK6U00qcj0KC37IsfszMkY6UE=
github.com/beorn7/perks v0.0.0-20160804104726-4c0e84591b9a/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
@@ -132,7 +168,6 @@ github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kB
github.com/bitly/go-simplejson v0.5.0/go.mod h1:cXHtHw4XUPsvGaxgjIAn8PhEWG9NfngEKAMDJEczWVA=
github.com/bits-and-blooms/bitset v1.2.0/go.mod h1:gIdJ4wp64HaoK2YrL1Q5/N7Y16edYb8uY+O0FJTyyDA=
github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84=
-github.com/bketelsen/crypt v0.0.4/go.mod h1:aI6NrJ0pMGgvZKL1iVgXLnfIFJtfV+bKCoqOes/6LfM=
github.com/blang/semver v3.1.0+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869/go.mod h1:Ekp36dRnpXw/yCqJaO+ZrUyxD+3VXMFFr56k5XYrpB4=
@@ -143,10 +178,14 @@ github.com/bugsnag/osext v0.0.0-20130617224835-0dd3f918b21b/go.mod h1:obH5gd0Bsq
github.com/bugsnag/panicwrap v0.0.0-20151223152923-e2c28503fcd0/go.mod h1:D/8v3kj0zr8ZAKg1AQ6crr+5VwKN5eIywRkfhyM/+dE=
github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw=
github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
+github.com/census-instrumentation/opencensus-proto v0.3.0/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc=
github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
+github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
github.com/checkpoint-restore/go-criu/v4 v4.1.0/go.mod h1:xUQBLp4RLc5zJtWY++yjOoMoB5lihDt7fai+75m+rGw=
github.com/checkpoint-restore/go-criu/v5 v5.0.0/go.mod h1:cfwC0EG7HMUenopBsUf9d89JlCLQIfgVcNsNN0t6T2M=
+github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86 h1:VZogJ199yfR3BRTzpDcejsFrBCJKLgi9V37K74/YWC8=
+github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86/go.mod h1:Zlre/PVxuSI9y6/UV4NwGixQ48RHQDSPiUkofr6rbMU=
github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
@@ -155,6 +194,8 @@ github.com/cilium/ebpf v0.0.0-20200702112145-1c8d4c9ef775/go.mod h1:7cR51M8ViRLI
github.com/cilium/ebpf v0.2.0/go.mod h1:To2CFviqOWL/M0gIMsvSMlqe7em/l1ALkX1PyjrX2Qs=
github.com/cilium/ebpf v0.4.0/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs=
github.com/cilium/ebpf v0.6.2/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs=
+github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag=
+github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I=
github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc=
github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
@@ -163,7 +204,9 @@ github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4/go.mod h1:6pvJx4me5XP
github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20211130200136-a8f946100490/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8=
github.com/containerd/aufs v0.0.0-20200908144142-dab0cbea06f4/go.mod h1:nukgQABAEopAHvB6j7cnP5zJ+/3aVcE7hCYqvIwAHyE=
github.com/containerd/aufs v0.0.0-20201003224125-76a6863f2989/go.mod h1:AkGGQs9NM2vtYHaUen+NljV0/baGCAPELGm2q9ZXpWU=
@@ -197,8 +240,6 @@ github.com/containerd/containerd v1.5.0-beta.1/go.mod h1:5HfvG1V2FsKesEGQ17k5/T7
github.com/containerd/containerd v1.5.0-beta.3/go.mod h1:/wr9AVtEM7x9c+n0+stptlo/uBBoBORwEx6ardVcmKU=
github.com/containerd/containerd v1.5.0-beta.4/go.mod h1:GmdgZd2zA2GYIBZ0w09ZvgqEq8EfBp/m3lcVZIvPHhI=
github.com/containerd/containerd v1.5.0-rc.0/go.mod h1:V/IXoMqNGgBlabz3tHD2TWDoTJseu1FGOKuoA4nNb2s=
-github.com/containerd/containerd v1.5.1/go.mod h1:0DOxVqwDy2iZvrZp2JUx/E+hS0UNTVn7dJnIOwtYR4g=
-github.com/containerd/containerd v1.5.7/go.mod h1:gyvv6+ugqY25TiXxcZC3L5yOeYgEw0QMhscqVp1AR9c=
github.com/containerd/containerd v1.5.8/go.mod h1:YdFSv5bTFLpG2HIYmfqDpSYYTDX+mc5qtSuYx1YUb/s=
github.com/containerd/continuity v0.0.0-20190426062206-aaeac12a7ffc/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y=
github.com/containerd/continuity v0.0.0-20190815185530-f2a389ac0a02/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y=
@@ -227,9 +268,7 @@ github.com/containerd/imgcrypt v1.1.1/go.mod h1:xpLnwiQmEUJPvQoAapeb2SNCxz7Xr6PJ
github.com/containerd/nri v0.0.0-20201007170849-eb1350a75164/go.mod h1:+2wGSDGFYfE5+So4M5syatU0N0f0LbWpuqyMi4/BE8c=
github.com/containerd/nri v0.0.0-20210316161719-dbaa18c31c14/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY=
github.com/containerd/nri v0.1.0/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY=
-github.com/containerd/stargz-snapshotter/estargz v0.9.0 h1:PkB6BSTfOKX23erT2GkoUKkJEcXfNcyKskIViK770v8=
-github.com/containerd/stargz-snapshotter/estargz v0.9.0/go.mod h1:aE5PCyhFMwR8sbrErO5eM2GcvkyXTTJremG883D4qF0=
-github.com/containerd/stargz-snapshotter/estargz v0.10.0/go.mod h1:aE5PCyhFMwR8sbrErO5eM2GcvkyXTTJremG883D4qF0=
+github.com/containerd/stargz-snapshotter/estargz v0.10.1 h1:hd1EoVjI2Ax8Cr64tdYqnJ4i4pZU49FkEf5kU8KxQng=
github.com/containerd/stargz-snapshotter/estargz v0.10.1/go.mod h1:aE5PCyhFMwR8sbrErO5eM2GcvkyXTTJremG883D4qF0=
github.com/containerd/ttrpc v0.0.0-20190828154514-0e0f228740de/go.mod h1:PvCDdDGpgqzQIzDW1TphrGLssLDZp2GuS+X5DkEJB8o=
github.com/containerd/ttrpc v0.0.0-20190828172938-92c8520ef9f8/go.mod h1:PvCDdDGpgqzQIzDW1TphrGLssLDZp2GuS+X5DkEJB8o=
@@ -289,21 +328,18 @@ github.com/denverdino/aliyungo v0.0.0-20190125010748-a747050bb1ba/go.mod h1:dV8l
github.com/dgrijalva/jwt-go v0.0.0-20170104182250-a601269ab70c/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
+github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
+github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
github.com/dnaeon/go-vcr v1.0.1/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E=
-github.com/docker/cli v20.10.9+incompatible h1:OJ7YkwQA+k2Oi51lmCojpjiygKpi76P7bg91b2eJxYU=
-github.com/docker/cli v20.10.9+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
-github.com/docker/cli v20.10.10+incompatible h1:kcbwdgWbrBOH8QwQzaJmyriHwF7XIl4HT1qh0HTRys4=
-github.com/docker/cli v20.10.10+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
-github.com/docker/cli v20.10.11+incompatible h1:tXU1ezXcruZQRrMP8RN2z9N91h+6egZTS1gsPsKantc=
-github.com/docker/cli v20.10.11+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
+github.com/docker/cli v20.10.12+incompatible h1:lZlz0uzG+GH+c0plStMUdF/qk3ppmgnswpR5EbqzVGA=
+github.com/docker/cli v20.10.12+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
github.com/docker/distribution v0.0.0-20190905152932-14b96e55d84c/go.mod h1:0+TTO4EOBfRPhZXAeF1Vu+W3hHZ8eLp8PgKVZlcvtFY=
github.com/docker/distribution v2.7.1-0.20190205005809-0d3efadf0154+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w=
github.com/docker/distribution v2.7.1+incompatible h1:a5mlkVzth6W5A4fOsS3D2EO5BUmsJpcB+cRlLU7cSug=
github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w=
-github.com/docker/docker v20.10.10+incompatible h1:GKkP0T7U4ks6X3lmmHKC2QDprnpRJor2Z5a8m62R9ZM=
-github.com/docker/docker v20.10.10+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
-github.com/docker/docker v20.10.11+incompatible h1:OqzI/g/W54LczvhnccGqniFoQghHx3pklbLuhfXpqGo=
-github.com/docker/docker v20.10.11+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
+github.com/docker/docker v20.10.12+incompatible h1:CEeNmFM0QZIsJCZKMkZx0ZcahTiewkrgiwfYD+dfl1U=
+github.com/docker/docker v20.10.12+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
+github.com/docker/docker-credential-helpers v0.6.3/go.mod h1:WRaJzqw3CTB9bk10avuGsjVBZsD05qeibJ1/TYlvc0Y=
github.com/docker/docker-credential-helpers v0.6.4 h1:axCks+yV+2MR3/kZhAmy07yC56WZ2Pwu/fKWtKuZB0o=
github.com/docker/docker-credential-helpers v0.6.4/go.mod h1:ofX3UI0Gz1TteYBjtgs07O36Pyasyp66D2uKT7H8W1c=
github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec=
@@ -328,18 +364,27 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.m
github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk=
github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ=
github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0=
+github.com/envoyproxy/go-control-plane v0.10.1/go.mod h1:AY7fTTXNdv/aJ2O5jwpxAPOWUZ7hQAEvzN5Pf27BkQQ=
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
-github.com/evanphx/json-patch v4.9.0+incompatible h1:kLcOMZeuLAJvL2BPWLMIj5oaZQobrkAqrL+WFZwQses=
+github.com/envoyproxy/protoc-gen-validate v0.6.2/go.mod h1:2t7qjJNvHPx8IjnBOzl9E9/baC+qXE/TeeyBRzgJDws=
github.com/evanphx/json-patch v4.9.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
+github.com/evanphx/json-patch v4.11.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
+github.com/evanphx/json-patch v4.12.0+incompatible h1:4onqiflcdA9EOZ4RxV643DvftH5pOlLGNtQ5lPWQu84=
+github.com/evanphx/json-patch v4.12.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
-github.com/form3tech-oss/jwt-go v3.2.2+incompatible h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=
+github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU=
+github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
+github.com/form3tech-oss/jwt-go v3.2.3+incompatible h1:7ZaBxOI7TMoYBfyA3cQHErNNyAWIKUMIwqxEtgHOs5c=
+github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
-github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4=
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
+github.com/fsnotify/fsnotify v1.5.1 h1:mZcQUHVQUQWoPXXtuf9yuEXKudkV2sx1E06UadKWpgI=
+github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU=
github.com/fullsailor/pkcs7 v0.0.0-20190404230743-d7302db945fa/go.mod h1:KnogPXtdwXqoenmZCw6S+25EAm2MkxbG0deNDu4cbSA=
github.com/garyburd/redigo v0.0.0-20150301180006-535138d7bcd7/go.mod h1:NR3MbYisc3/PwhQ00EMzDiPmrwpPxAn5GI05/YaO1SY=
+github.com/getkin/kin-openapi v0.76.0/go.mod h1:660oXbgy5JFMKreazJaQTw7o+X00qeSyhcnluiMv+Xg=
github.com/ghodss/yaml v0.0.0-20150909031657-73d445a93680/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
@@ -352,14 +397,15 @@ github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9
github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas=
github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
-github.com/go-logr/logr v0.4.0 h1:K7/B1jt6fIBQVd4Owv2MqGQClcgf0R266+7C/QjRcLc=
github.com/go-logr/logr v0.4.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
+github.com/go-logr/logr v1.2.0 h1:QK40JKJyMdUDz+h+xvCsru/bJhvG0UxvePV0ufL/AcE=
+github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
github.com/go-openapi/jsonpointer v0.19.2/go.mod h1:3akKfEdA7DF1sugOqz1dVQHBcuDBPKZGEoHC/NkiQRg=
github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
+github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
github.com/go-openapi/jsonreference v0.19.2/go.mod h1:jMjeRr2HHw6nAVajTXJ4eiUwohSTlpa0o73RUL1owJc=
github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL98+wF9xc8zWvFonSJ8=
github.com/go-openapi/spec v0.19.3/go.mod h1:FpwSN1ksY1eteniUU7X0N/BgJ7a4WvBFVA8Lj9mJglo=
-github.com/go-openapi/spec v0.19.5/go.mod h1:Hm2Jr4jv8G1ciIAo+frC/Ft+rR2kQDh8JHKHb3gWUSk=
github.com/go-openapi/swag v0.19.2/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
@@ -382,8 +428,8 @@ github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4er
github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
-github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e h1:1r7pUrabqp18hOBcwBwiTsbnFeTZHV9eER/QT5JVZxY=
github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
+github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y=
@@ -414,6 +460,7 @@ github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiu
github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
+github.com/google/btree v1.0.1/go.mod h1:xXMiIv4Fb/0kKde4SpL7qlzvu5cMJDRkFDxJfI9uaxA=
github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
@@ -452,14 +499,15 @@ github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm4
github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
-github.com/google/uuid v1.2.0 h1:qJYtXnJRWmpe7m/3XlyhrsLrEURqHRM2kxzoxXqyUDs=
github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0=
-github.com/googleapis/gnostic v0.4.1 h1:DLJCy1n/vrD4HPjOvYcT8aYQXpPIzoRZONaYwyycI+I=
+github.com/googleapis/gax-go/v2 v2.1.1/go.mod h1:hddJymUZASv3XPyGkUpKj8pPO47Rmb0eJc8R6ouapiM=
github.com/googleapis/gnostic v0.4.1/go.mod h1:LRhVm6pbyptWbWbuZ38d1eyptfvIytN3ir6b65WBswg=
-github.com/gophercloud/gophercloud v0.1.0/go.mod h1:vxM41WHh5uqHVBMZHzuwNOHh8XEoIEcSTewFxm1c5g8=
+github.com/googleapis/gnostic v0.5.1/go.mod h1:6U4PtQXGIEt/Z3h5MAT7FNofLnw9vXk2cUuW7uA/OeU=
+github.com/googleapis/gnostic v0.5.5 h1:9fHAtK0uDfpveeqqo1hkEZJcFvYXAiCN3UutL8F9xHw=
+github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA=
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
github.com/gorilla/handlers v0.0.0-20150720190736-60c7bfde3e33/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ=
github.com/gorilla/mux v1.7.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
@@ -475,29 +523,46 @@ github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t
github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw=
github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q=
+github.com/hashicorp/consul/api v1.11.0/go.mod h1:XjsvQN+RJGWI2TWy1/kqaE16HrR2J/FWgkYjdZQsX9M=
github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8=
+github.com/hashicorp/consul/sdk v0.8.0/go.mod h1:GBvyrGALthsZObzUGsfgHZQDXjg4lOjagTIwIR1vPms=
github.com/hashicorp/errwrap v0.0.0-20141028054710-7554cd9344ce/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
+github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
+github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48=
+github.com/hashicorp/go-hclog v0.12.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
+github.com/hashicorp/go-hclog v1.0.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
+github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM=
github.com/hashicorp/go-multierror v0.0.0-20161216184304-ed905158d874/go.mod h1:JMRHfdO9jKNzS/+BTlxCjKNQHg/jZAft8U7LloJvN7I=
github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk=
+github.com/hashicorp/go-multierror v1.1.0/go.mod h1:spPvp8C1qA32ftKqdAHm4hHTbPw+vmowP0z+KUhOZdA=
+github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs=
github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU=
+github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8=
github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU=
github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4=
github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90=
github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
-github.com/hashicorp/golang-lru v0.5.1 h1:0hERBMJE1eitiLkihrMvRVBYAkpHzc/J3QdDN+dAcgU=
github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
+github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64=
github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ=
+github.com/hashicorp/mdns v1.0.1/go.mod h1:4gW7WsVCke5TE7EPeYliwHlRUyBtfCwuFwuMg2DmyNY=
+github.com/hashicorp/mdns v1.0.4/go.mod h1:mtBihi+LeNXGtG8L9dX59gAEa12BDtBQSp4v/YAJqrc=
github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I=
+github.com/hashicorp/memberlist v0.2.2/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOnAH9VT3Sh9MUE=
+github.com/hashicorp/memberlist v0.3.0/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOnAH9VT3Sh9MUE=
github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc=
+github.com/hashicorp/serf v0.9.5/go.mod h1:UWDWwZeL5cuWDJdl0C6wrvrUwEqtQ4ZKBKKENpqIUyk=
+github.com/hashicorp/serf v0.9.6/go.mod h1:TXZNMjZQijwlDvp+r0b63xZ45H7JmCmgg4gpTwn9UV4=
github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
+github.com/iancoleman/strcase v0.2.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho=
github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
@@ -516,9 +581,11 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfC
github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo=
github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
+github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
-github.com/json-iterator/go v1.1.11 h1:uVUAXhF2To8cbw/3xN3pxj6kk7TYKs98NIrTqPlMWAQ=
github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
+github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM=
+github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo=
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU=
github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk=
github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
@@ -545,24 +612,38 @@ github.com/kr/pty v1.1.5/go.mod h1:9r2w37qlBe7rQ6e1fg1S/9xpWHSnaqNdHD3WcMdbPDA=
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
+github.com/lyft/protoc-gen-star v0.5.3/go.mod h1:V0xaHgaf5oCCqmcxYcWiDfTiKsZsRc87/1qhoTACD8w=
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
+github.com/magiconair/properties v1.8.4/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
github.com/mailru/easyjson v0.7.0/go.mod h1:KAzv3t3aY1NaHWoQz1+4F1ccyAH66Jk7yos7ldAVICs=
github.com/marstr/guid v1.1.0/go.mod h1:74gB1z2wpxxInTG6yaqA7KrtM0NZ+RbrcqDvYHefzho=
github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
+github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE=
+github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
+github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
+github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4=
github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
+github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
+github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84=
+github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE=
+github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
+github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU=
github.com/mattn/go-shellwords v1.0.3/go.mod h1:3xCvwCdWdlDJUrvuMn7Wuy9eWs4pE8vqg+NOMyg4B2o=
github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4=
github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg=
+github.com/miekg/dns v1.1.26/go.mod h1:bPDLeHnStXmXAq1m/Ch/hvfNHr14JKNPMBo3VZKjuso=
+github.com/miekg/dns v1.1.41/go.mod h1:p6aan82bvRIyn+zDIv9xYNUpwa73JcSh9BKwknJysuI=
github.com/miekg/pkcs11 v1.0.3/go.mod h1:XsNlhZGX73bx86s2hdc/FuaLm2CPZJemRLMA+WTFxgs=
github.com/mistifyio/go-zfs v2.1.2-0.20190413222219-f784269be439+incompatible/go.mod h1:8AuVvqP/mXw1px98n46wfvcGfQ4ci2FwoAjKYxuo3Z4=
github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc=
+github.com/mitchellh/cli v1.1.0/go.mod h1:xcISNoH86gajksDmfB23e/pu+B+GeFRMYmoHXxx3xhI=
github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
@@ -571,7 +652,8 @@ github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS4
github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY=
github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
-github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
+github.com/mitchellh/mapstructure v1.3.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
+github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/mitchellh/osext v0.0.0-20151018003038-5e2d6d41470f/go.mod h1:OkQIRizQZAeMln+1tSwduZz7+Af5oFlKirV/MSYes2A=
github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQppc=
github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c=
@@ -584,8 +666,9 @@ github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJ
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
-github.com/modern-go/reflect2 v1.0.1 h1:9f412s+6RmYXLWZSEzVVgPGK7C2PphHj5RJrvfx9AWI=
github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
+github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M=
+github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc=
github.com/mrunalp/fileutils v0.5.0/go.mod h1:M1WthSahJixYnrXQl/DFQuteStB1weuxD2QJNHXfbSQ=
github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
@@ -604,12 +687,14 @@ github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+W
github.com/onsi/ginkgo v1.10.1/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
github.com/onsi/ginkgo v1.10.3/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
github.com/onsi/ginkgo v1.11.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
-github.com/onsi/ginkgo v1.12.1 h1:mFwc4LvZ0xpSvDZ3E+k8Yte0hLOMxXUlP+yXtJqkYfQ=
github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk=
+github.com/onsi/ginkgo v1.14.0 h1:2mOpI4JVVPBN+WQRa0WKH2eXR+Ey+uK4n7Zj0aYpIQA=
+github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY=
github.com/onsi/gomega v0.0.0-20151007035656-2152b45fa28a/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY=
+github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo=
github.com/onsi/gomega v1.10.3 h1:gph6h/qe9GSUw1NhH1gp+qb+h8rXD8Cy60Z32Qw3ELA=
github.com/onsi/gomega v1.10.3/go.mod h1:V9xEwhxec5O8UDM77eCW8vLymOMltsqPVYWrpDsH8xc=
github.com/opencontainers/go-digest v0.0.0-20170106003457-a6d0ee40d420/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s=
@@ -620,8 +705,6 @@ github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8
github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM=
github.com/opencontainers/image-spec v1.0.0/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0=
github.com/opencontainers/image-spec v1.0.1/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0=
-github.com/opencontainers/image-spec v1.0.2-0.20210730191737-8e42a01fb1b7 h1:axgApq2XShTLwQii2zAnIkMPlhGVHbAXHUcHezu5G/k=
-github.com/opencontainers/image-spec v1.0.2-0.20210730191737-8e42a01fb1b7/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0=
github.com/opencontainers/image-spec v1.0.2-0.20211117181255-693428a734f5 h1:q37d91F6BO4Jp1UqWiun0dUFYaqv6WsKTLTCaWv+8LY=
github.com/opencontainers/image-spec v1.0.2-0.20211117181255-693428a734f5/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0=
github.com/opencontainers/runc v0.0.0-20190115041553-12f6a991201f/go.mod h1:qT5XzbpPznkRYVz/mWwUaVBUv2rmF59PVA73FjuZG0U=
@@ -641,9 +724,10 @@ github.com/opencontainers/selinux v1.6.0/go.mod h1:VVGKuOLlE7v4PJyT6h7mNWvq1rzqi
github.com/opencontainers/selinux v1.8.0/go.mod h1:RScLhm78qiWa2gbVCcGkC7tCGdgk3ogry1nUQF8Evvo=
github.com/opencontainers/selinux v1.8.2/go.mod h1:MUIHuUEvKB1wtJjQdOyYRgOnLD2xAPP8dBsCoU0KuF8=
github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
+github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc=
-github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c=
+github.com/pelletier/go-toml v1.9.4/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c=
github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU=
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/errors v0.8.1-0.20171018195549-f15c970de5b7/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
@@ -654,12 +738,14 @@ github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZ
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
+github.com/posener/complete v1.2.3/go.mod h1:WZIdtGGp+qx0sLrYKtIRAruyNpv6hFCicSgv7Sy7s/s=
github.com/pquerna/cachecontrol v0.0.0-20171018203845-0dec1b30a021/go.mod h1:prYjPmNq4d1NPVmpShWobRqXY3q7Vp+80DqgxxUrUIA=
github.com/prometheus/client_golang v0.0.0-20180209125602-c332b6f63c06/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso=
github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo=
github.com/prometheus/client_golang v1.1.0/go.mod h1:I1FGZT9+L76gKKOs5djB6ezCbFQP1xR9D75/vuwEF3g=
+github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU=
github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M=
github.com/prometheus/client_model v0.0.0-20171117100541-99fa1f4be8e5/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
@@ -671,6 +757,7 @@ github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7q
github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc=
+github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4=
github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo=
github.com/prometheus/procfs v0.0.0-20180125133057-cb4147076ac7/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
@@ -687,11 +774,11 @@ github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40T
github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg=
github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ=
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
-github.com/rubiojr/go-vhd v0.0.0-20200706105327-02e210299021/go.mod h1:DM5xW0nvfNNm2uytzsvhI3OnX8uzaRAg8UX/CnDqbto=
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
github.com/safchain/ethtool v0.0.0-20190326074333-42ed695e3de8/go.mod h1:Z0q5wiBQGYcxhMZ6gUqHn6pYNLypFAvaL3UvgZLR0U4=
+github.com/sagikazarmark/crypt v0.3.0/go.mod h1:uD/D+6UF4SrIR1uGEv7bBNkNqLGqUr43MRiaGWX1Nig=
github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
github.com/seccomp/libseccomp-golang v0.9.1/go.mod h1:GbW5+tmTXfcxTToHLXlScSlAvWlF4P2Ca7zGrPiEpWo=
@@ -712,14 +799,16 @@ github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4k
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
+github.com/spf13/afero v1.3.3/go.mod h1:5KUK8ByomD5Ti5Artl0RtHeI5pTF7MIDuXL3yY520V4=
+github.com/spf13/afero v1.4.1/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
+github.com/spf13/cast v1.4.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cobra v0.0.2-0.20171109065643-2da4a54c5cee/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE=
-github.com/spf13/cobra v1.1.1/go.mod h1:WnodtKOvamDL/PwE2M4iKs8aMDBZ5Q5klgD3qfVJQMI=
-github.com/spf13/cobra v1.2.1/go.mod h1:ExllRjgxM/piMAM+3tAZvg8fsklGAf3tPfi+i8t68Nk=
+github.com/spf13/cobra v1.3.0/go.mod h1:BrRVncBjOJa/eUcVVm9CE+oC6as8k+VYr4NY7WCi9V4=
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
@@ -729,9 +818,10 @@ github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnIn
github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE=
-github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg=
-github.com/spf13/viper v1.8.1/go.mod h1:o0Pch8wJ9BVSWGQMbra6iw0oQ5oktSIBaujf1rJH9Ns=
+github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg=
+github.com/spf13/viper v1.10.0/go.mod h1:SoyBPwAtKDzypXNDFKN5kzH7ppppbGZtls1UpIy5AsM=
github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980/go.mod h1:AO3tvPzVZ/ayst6UlUKUv6rcPQInYe3IknH3jYhAKu8=
+github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8=
github.com/stretchr/objx v0.0.0-20180129172003-8a3f7159479f/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
@@ -751,6 +841,7 @@ github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635/go.mod h1:hkRG
github.com/tchap/go-patricia v2.2.6+incompatible/go.mod h1:bmLyhP68RS6kStMGxByiQ23RP/odRBOTVjwp2cDyi6I=
github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
+github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM=
github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc=
github.com/urfave/cli v0.0.0-20171014202726-7bc6a0acffa5/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
@@ -759,15 +850,12 @@ github.com/urfave/cli v1.22.2/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtX
github.com/urfave/cli v1.22.4/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
github.com/vbatts/tar-split v0.11.2 h1:Via6XqJr0hceW4wff3QRzD5gAk/tatMw/4ZA7cTlIME=
github.com/vbatts/tar-split v0.11.2/go.mod h1:vV3ZuO2yWSVsz+pfFzDG/upWH1JhjOiEaWq6kXyQ3VI=
-github.com/vdemeester/k8s-pkg-credentialprovider v1.21.0-1 h1:7Ajl3rjeYoB5V47jPknnLbyxYlhMXTTJiQsye5aT7f0=
-github.com/vdemeester/k8s-pkg-credentialprovider v1.21.0-1/go.mod h1:l4LxiP0cmEcc5q4BTDE8tZSyIiyXe0T28x37yHpMzoM=
github.com/vishvananda/netlink v0.0.0-20181108222139-023a6dafdcdf/go.mod h1:+SR5DhBJrl6ZM7CoCKvpw5BKroDKQ+PJqOg65H/2ktk=
github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE=
github.com/vishvananda/netlink v1.1.1-0.20201029203352-d40f9887b852/go.mod h1:twkDnbuQxJYemMlGd4JFIcuhgX83tXhKS2B/PRMpOho=
github.com/vishvananda/netns v0.0.0-20180720170159-13995c7128cc/go.mod h1:ZjcWmFBXmLKZu9Nxj3WKYEafiSqer2rnvPr0en9UNpI=
github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df/go.mod h1:JP3t17pCcGlemwknint6hfoeCVQrEMVwxRLRjXpq+BU=
github.com/vishvananda/netns v0.0.0-20200728191858-db3c7e526aae/go.mod h1:DD4vA1DwXk04H54A1oHXtwZmA0grkVMdPxx/VGLCah0=
-github.com/vmware/govmomi v0.20.3/go.mod h1:URlwyTFZX72RmxtxuaFL2Uj3fD1JTvZdx59bHWk6aFU=
github.com/willf/bitset v1.1.11-0.20200630133818-d5bec3311243/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4=
github.com/willf/bitset v1.1.11/go.mod h1:83CECat5yLh5zVOf4P1ErAgKA5UDvKtgyUABdr3+MjI=
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU=
@@ -780,6 +868,7 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de
github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
+github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
github.com/yvasiyarov/go-metrics v0.0.0-20140926110328-57bccd1ccd43/go.mod h1:aX5oPXxHm3bOH+xeAttToC8pqch2ScQN/JoXYupl6xs=
github.com/yvasiyarov/gorelic v0.0.0-20141212073537-a9bba5b9ab50/go.mod h1:NUSPSUX/bi6SeDMUh6brw0nXpxHnc96TguQh0+r/ssA=
github.com/yvasiyarov/newrelic_platform_go v0.0.0-20140908184405-b21fdbd4370f/go.mod h1:GlGEuHIJweS1mbCqG+7vt2nvWLzLLnRHbXz5JKd/Qbg=
@@ -787,9 +876,9 @@ go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
go.etcd.io/bbolt v1.3.5/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ=
go.etcd.io/etcd v0.5.0-alpha.5.0.20200910180754-dd1b699fc489/go.mod h1:yVHk9ub3CSBatqGNg7GRmsnfLWtoW60w4eDYfh7vHDg=
-go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
-go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
-go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ=
+go.etcd.io/etcd/api/v3 v3.5.1/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
+go.etcd.io/etcd/client/pkg/v3 v3.5.1/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
+go.etcd.io/etcd/client/v2 v2.305.1/go.mod h1:pMEacxZW7o8pg4CrFE7pquyCJJzZvkvdD2RibOCCCGs=
go.mozilla.org/pkcs7 v0.0.0-20200128120323-432b2356ecb1/go.mod h1:SNgMg+EgDFwmvSmLRTNKC5fegJjB7v23qTQ0XLGUNHk=
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
@@ -810,20 +899,21 @@ golang.org/x/crypto v0.0.0-20171113213409-9f005a07e0d3/go.mod h1:6SG95UA2DQfeDnf
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/crypto v0.0.0-20181009213950-7c1a557ab941/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
-golang.org/x/crypto v0.0.0-20190211182817-74369b46fc67/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY=
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
-golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2 h1:It14KIkyBFYkHkwZ7k45minvA9aorojkyjGk9KJ5B/w=
golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
+golang.org/x/crypto v0.0.0-20210817164053-32db794688a5 h1:HWj/xjIHfjYU5nVXpTM0s39J9CbLn7Cc5a7IC5rwsMQ=
+golang.org/x/crypto v0.0.0-20210817164053-32db794688a5/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
@@ -859,6 +949,9 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
+golang.org/x/mod v0.5.0/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
+golang.org/x/mod v0.5.1 h1:OJxoQ/rynoF0dcCdI7cLPktw/hR2cueqYfjm43oqK38=
+golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
@@ -882,6 +975,7 @@ golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLL
golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20191004110552-13f9640d40b9/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
@@ -893,6 +987,7 @@ golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/
golang.org/x/net v0.0.0-20200501053045-e0ff5e5a1de5/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
golang.org/x/net v0.0.0-20200506145744-7e3656a0809f/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
golang.org/x/net v0.0.0-20200513185701-a91f0712d120/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
+golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
@@ -904,17 +999,16 @@ golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwY
golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
-golang.org/x/net v0.0.0-20210224082022-3d97a244fca7/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc=
golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM=
+golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8=
golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
-golang.org/x/net v0.0.0-20211005215030-d2e5035098b3 h1:G64nFNerDErBd2KdvHvIn3Ee6ccUQBTfhDZEO0DccfU=
-golang.org/x/net v0.0.0-20211005215030-d2e5035098b3/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
-golang.org/x/net v0.0.0-20211111160137-58aab5ef257a h1:c83jeVQW0KGKNaKBRfelNYNHaev+qawl9yaA825s8XE=
-golang.org/x/net v0.0.0-20211111160137-58aab5ef257a/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
-golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4 h1:DZshvxDdVoeKIbudAdFEKi+f70l51luSy/7b76ibTY0=
-golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20210813160813-60bc85c4be6d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211209124913-491a49abca63/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211216030914-fe4d6282115f h1:hEYJvxw1lSnWIl8X9ofsYMklzaDs90JI2az5YMd4fPM=
+golang.org/x/net v0.0.0-20211216030914-fe4d6282115f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
@@ -926,13 +1020,10 @@ golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ
golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
-golang.org/x/oauth2 v0.0.0-20210402161424-2e8d93401602/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
-golang.org/x/oauth2 v0.0.0-20210427180440-81ed05c6b58c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210628180205-a41e5a781914/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210805134026-6f1e6394065a/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
-golang.org/x/oauth2 v0.0.0-20211005180243-6b3c2da341f1 h1:B333XXssMuKQeBwiNODx4TupZy7bf4sxFZnN2ZOcvUE=
golang.org/x/oauth2 v0.0.0-20211005180243-6b3c2da341f1/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 h1:RerP+noqYHUQ8CMRcPlC2nvTa4dcBIjegkuWdcUDuqg=
golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
@@ -955,8 +1046,8 @@ golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5h
golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190209173611-3b5209105503/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -975,8 +1066,11 @@ golang.org/x/sys v0.0.0-20190812073006-9eafafc0a87e/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190922100055-0a153f010e69/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191022100944-742c48ecaeb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191115151921-52ab43148777/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1000,6 +1094,7 @@ golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200622214017-ed371f2e16b4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1012,6 +1107,7 @@ golang.org/x/sys v0.0.0-20200909081042-eff7692f9009/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20200916030750-2334cc1a136f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200922070232-aee5d888a860/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20201005172224-997123666555/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201112073958-5cba982894dd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201117170446-d9b008d0a637/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1021,7 +1117,7 @@ golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1033,21 +1129,26 @@ golang.org/x/sys v0.0.0-20210426230700-d19ff857e887/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.0.0-20211004093028-2c5d950f24ef h1:fPxZ3Umkct3LZ8gK9nbk+DWDJ9fstZa2grBn+lWVKPs=
-golang.org/x/sys v0.0.0-20211004093028-2c5d950f24ef/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.0.0-20211110154304-99a53858aa08 h1:WecRHqgE09JBkh/584XIE6PMz5KKE/vER4izNUi30AQ=
-golang.org/x/sys v0.0.0-20211110154304-99a53858aa08/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.0.0-20211117180635-dee7805ff2e1 h1:kwrAHlwJ0DUBZwQ238v+Uod/3eZ8B2K5rYsUHBQvzmI=
-golang.org/x/sys v0.0.0-20211117180635-dee7805ff2e1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211205182925-97ca703d548d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20220111092808-5a964db01320 h1:0jf+tOCoZ3LyutmCOWpVni1chK4VfFLhRsDK7MhqGRY=
+golang.org/x/sys v0.0.0-20220111092808-5a964db01320/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
-golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d h1:SZxvLBoTP5yHO3Frd4z4vrF+DBX9vMVanchswa69toE=
golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
+golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b h1:9zKuko04nR4gjZ4+DNjHqRlAJqbJETHwiNKDqTfOjfE=
+golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
@@ -1055,15 +1156,17 @@ golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
-golang.org/x/text v0.3.6 h1:aRYxNxv6iGQlyVaZmk6ZgYEDa+Jg18DxebPSrd6bg1M=
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk=
+golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20200630173020-3af7569d3a1e/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
-golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba h1:O8mE0/t419eoIwhTFpKVkHiTs/Igowgfkj25AcZrtiE=
golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
+golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac h1:7zkz7BUtwNFFqcowJ+RIgu2MaV/MapERkDIy+mwPyjs=
+golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
@@ -1082,6 +1185,7 @@ golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgw
golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20190907020128-2ca718005c18/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20191112195655-aa38f8e97acc/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
@@ -1104,6 +1208,7 @@ golang.org/x/tools v0.0.0-20200304193943-95d2e580d8eb/go.mod h1:o4KQGtdN14AW+yjs
golang.org/x/tools v0.0.0-20200312045724-11d5b4c81c7d/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw=
golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8=
golang.org/x/tools v0.0.0-20200501065659-ab2804fb9c9d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
+golang.org/x/tools v0.0.0-20200505023115-26f46d2f7ef8/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
golang.org/x/tools v0.0.0-20200512131952-2bc93b1c0c88/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
golang.org/x/tools v0.0.0-20200515010526-7d3b6ebf133d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
@@ -1123,6 +1228,8 @@ golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
+golang.org/x/tools v0.1.8 h1:P1HhGGuLW4aAclzjtmJdf0mJOjVUZUzOTqkAkWL+l6w=
+golang.org/x/tools v0.1.8/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
@@ -1136,7 +1243,6 @@ google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEn
google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
google.golang.org/api v0.14.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
-google.golang.org/api v0.15.1-0.20200106000736-b8fc810ca6b5/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
google.golang.org/api v0.17.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
google.golang.org/api v0.18.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
google.golang.org/api v0.19.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
@@ -1151,14 +1257,17 @@ google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34q
google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8=
google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU=
google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94=
-google.golang.org/api v0.44.0/go.mod h1:EBOGZqzyhtvMDoxwS97ctnh0zUmYY6CxqXsc1AvkYD8=
google.golang.org/api v0.47.0/go.mod h1:Wbvgpq1HddcWVtzsVLyfLp8lDg6AA241LmgIL59tHXo=
google.golang.org/api v0.48.0/go.mod h1:71Pr1vy+TAZRPkPs/xlCf5SsU8WjuAWv1Pfjbtukyy4=
google.golang.org/api v0.50.0/go.mod h1:4bNT5pAuq5ji4SRZm+5QIkjny9JAyVD/3gaSihNefaw=
google.golang.org/api v0.51.0/go.mod h1:t4HdrdoNgyN5cbEfm7Lum0lcLDLiise1F8qDKX00sOU=
google.golang.org/api v0.54.0/go.mod h1:7C4bFFOvVDGXjfDTAsgGwDgAxRDeQ4X8NvUedIt6z3k=
google.golang.org/api v0.55.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE=
+google.golang.org/api v0.56.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE=
google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdrMgI=
+google.golang.org/api v0.59.0/go.mod h1:sT2boj7M9YJxZzgeZqXogmhfmRWDtPzT31xkieUbuZU=
+google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I=
+google.golang.org/api v0.62.0/go.mod h1:dKmwPCydfsad4qCH08MSdgWjfHOyfpd4VtDGgRFdavw=
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
@@ -1201,6 +1310,7 @@ google.golang.org/genproto v0.0.0-20200729003335-053ba62fc06f/go.mod h1:FWY/as6D
google.golang.org/genproto v0.0.0-20200804131852-c06518451d9c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20201019141844-1ed22bb0c154/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201109203340-2640f1f9cdfb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201110150050-8816d57aaa9a/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
@@ -1225,10 +1335,15 @@ google.golang.org/genproto v0.0.0-20210821163610-241b8fcbd6c8/go.mod h1:eFjDcFEc
google.golang.org/genproto v0.0.0-20210828152312-66f60bf46e71/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
google.golang.org/genproto v0.0.0-20210831024726-fe130286e0e2/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
google.golang.org/genproto v0.0.0-20210903162649-d08c68adba83/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
+google.golang.org/genproto v0.0.0-20210909211513-a8c4777a87af/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
google.golang.org/genproto v0.0.0-20210924002016-3dee208752a0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
-google.golang.org/genproto v0.0.0-20211005153810-c76a74d43a8e/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
-google.golang.org/genproto v0.0.0-20211111162719-482062a4217b/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211008145708-270636b82663/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211028162531-8db9c33dc351/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
google.golang.org/genproto v0.0.0-20211118181313-81c1377c94b1/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211129164237-f09f9a12af12/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211203200212-54befc351ae9/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211206160659-862468c7d6e0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
google.golang.org/grpc v0.0.0-20160317175043-d3ddb4469d5a/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw=
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
@@ -1258,8 +1373,9 @@ google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQ
google.golang.org/grpc v1.39.0/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE=
google.golang.org/grpc v1.39.1/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE=
google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34=
-google.golang.org/grpc v1.41.0/go.mod h1:U3l9uK9J0sini8mHphKoXyaqDA/8VyGnDee1zzIUK6k=
+google.golang.org/grpc v1.40.1/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34=
google.golang.org/grpc v1.42.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU=
+google.golang.org/grpc v1.43.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU=
google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw=
google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0=
@@ -1287,12 +1403,12 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EV
gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw=
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
-gopkg.in/gcfg.v1 v1.2.0/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o=
gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2/go.mod h1:Xk6kEKp8OKb+X14hQBKWaSkCsqBpgog8nAV2xsGOxlo=
gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc=
gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
gopkg.in/ini.v1 v1.62.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
+gopkg.in/ini.v1 v1.66.2/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k=
gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo=
gopkg.in/square/go-jose.v2 v2.2.2/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
@@ -1300,7 +1416,6 @@ gopkg.in/square/go-jose.v2 v2.3.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76
gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ=
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
-gopkg.in/warnings.v0 v0.1.1/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI=
gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74=
gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
@@ -1312,6 +1427,7 @@ gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=
gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
+gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo=
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo=
@@ -1326,54 +1442,50 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh
honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
+honnef.co/go/tools v0.0.1-2020.1.5/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
k8s.io/api v0.20.1/go.mod h1:KqwcCVogGxQY3nBlRpwt+wpAMF/KjaCc7RpywacvqUo=
k8s.io/api v0.20.4/go.mod h1:++lNL1AJMkDymriNniQsWRkMDzRaX2Y/POTUi8yvqYQ=
k8s.io/api v0.20.6/go.mod h1:X9e8Qag6JV/bL5G6bU8sdVRltWKmdHsFUGS3eVndqE8=
-k8s.io/api v0.21.0/go.mod h1:+YbrhBBGgsxbF6o6Kj4KJPJnBmAKuXDeS3E18bgHNVU=
-k8s.io/api v0.21.1 h1:94bbZ5NTjdINJEdzOkpS4vdPhkb1VFpTYC9zh43f75c=
-k8s.io/api v0.21.1/go.mod h1:FstGROTmsSHBarKc8bylzXih8BLNYTiS3TZcsoEDg2s=
+k8s.io/api v0.22.5 h1:xk7C+rMjF/EGELiD560jdmwzrB788mfcHiNbMQLIVI8=
+k8s.io/api v0.22.5/go.mod h1:mEhXyLaSD1qTOf40rRiKXkc+2iCem09rWLlFwhCEiAs=
k8s.io/apimachinery v0.20.1/go.mod h1:WlLqWAHZGg07AeltaI0MV5uk1Omp8xaN0JGLY6gkRpU=
k8s.io/apimachinery v0.20.4/go.mod h1:WlLqWAHZGg07AeltaI0MV5uk1Omp8xaN0JGLY6gkRpU=
k8s.io/apimachinery v0.20.6/go.mod h1:ejZXtW1Ra6V1O5H8xPBGz+T3+4gfkTCeExAHKU57MAc=
-k8s.io/apimachinery v0.21.0/go.mod h1:jbreFvJo3ov9rj7eWT7+sYiRx+qZuCYXwWT1bcDswPY=
-k8s.io/apimachinery v0.21.1 h1:Q6XuHGlj2xc+hlMCvqyYfbv3H7SRGn2c8NycxJquDVs=
-k8s.io/apimachinery v0.21.1/go.mod h1:jbreFvJo3ov9rj7eWT7+sYiRx+qZuCYXwWT1bcDswPY=
+k8s.io/apimachinery v0.22.5 h1:cIPwldOYm1Slq9VLBRPtEYpyhjIm1C6aAMAoENuvN9s=
+k8s.io/apimachinery v0.22.5/go.mod h1:xziclGKwuuJ2RM5/rSFQSYAj0zdbci3DH8kj+WvyN0U=
k8s.io/apiserver v0.20.1/go.mod h1:ro5QHeQkgMS7ZGpvf4tSMx6bBOgPfE+f52KwvXfScaU=
k8s.io/apiserver v0.20.4/go.mod h1:Mc80thBKOyy7tbvFtB4kJv1kbdD0eIH8k8vianJcbFM=
k8s.io/apiserver v0.20.6/go.mod h1:QIJXNt6i6JB+0YQRNcS0hdRHJlMhflFmsBDeSgT1r8Q=
-k8s.io/apiserver v0.21.0/go.mod h1:w2YSn4/WIwYuxG5zJmcqtRdtqgW/J2JRgFAqps3bBpg=
k8s.io/client-go v0.20.1/go.mod h1:/zcHdt1TeWSd5HoUe6elJmHSQ6uLLgp4bIJHVEuy+/Y=
k8s.io/client-go v0.20.4/go.mod h1:LiMv25ND1gLUdBeYxBIwKpkSC5IsozMMmOOeSJboP+k=
k8s.io/client-go v0.20.6/go.mod h1:nNQMnOvEUEsOzRRFIIkdmYOjAZrC8bgq0ExboWSU1I0=
-k8s.io/client-go v0.21.0/go.mod h1:nNBytTF9qPFDEhoqgEPaarobC8QPae13bElIVHzIglA=
-k8s.io/client-go v0.21.1 h1:bhblWYLZKUu+pm50plvQF8WpY6TXdRRtcS/K9WauOj4=
-k8s.io/client-go v0.21.1/go.mod h1:/kEw4RgW+3xnBGzvp9IWxKSNA+lXn3A7AuH3gdOAzLs=
-k8s.io/cloud-provider v0.21.0 h1:NSTS+czpv6LQAaIpY/VUghsT4oj62hYmQPErkDKTzKU=
-k8s.io/cloud-provider v0.21.0/go.mod h1:z17TQgu3JgUFjcgby8sj5X86YdVK5Pbt+jm/eYMZU9M=
+k8s.io/client-go v0.22.5 h1:I8Zn/UqIdi2r02aZmhaJ1hqMxcpfJ3t5VqvHtctHYFo=
+k8s.io/client-go v0.22.5/go.mod h1:cs6yf/61q2T1SdQL5Rdcjg9J1ElXSwbjSrW2vFImM4Y=
k8s.io/component-base v0.20.1/go.mod h1:guxkoJnNoh8LNrbtiQOlyp2Y2XFCZQmrcg2n/DeYNLk=
k8s.io/component-base v0.20.4/go.mod h1:t4p9EdiagbVCJKrQ1RsA5/V4rFQNDfRlevJajlGwgjI=
k8s.io/component-base v0.20.6/go.mod h1:6f1MPBAeI+mvuts3sIdtpjljHWBQ2cIy38oBIWMYnrM=
-k8s.io/component-base v0.21.0 h1:tLLGp4BBjQaCpS/KiuWh7m2xqvAdsxLm4ATxHSe5Zpg=
-k8s.io/component-base v0.21.0/go.mod h1:qvtjz6X0USWXbgmbfXR+Agik4RZ3jv2Bgr5QnZzdPYw=
-k8s.io/controller-manager v0.21.0/go.mod h1:Ohy0GRNRKPVjB8C8G+dV+4aPn26m8HYUI6ejloUBvUA=
k8s.io/cri-api v0.17.3/go.mod h1:X1sbHmuXhwaHs9xxYffLqJogVsnI+f6cPRcgPel7ywM=
k8s.io/cri-api v0.20.1/go.mod h1:2JRbKt+BFLTjtrILYVqQK5jqhI+XNdF6UiGMgczeBCI=
k8s.io/cri-api v0.20.4/go.mod h1:2JRbKt+BFLTjtrILYVqQK5jqhI+XNdF6UiGMgczeBCI=
k8s.io/cri-api v0.20.6/go.mod h1:ew44AjNXwyn1s0U4xCKGodU7J1HzBeZ1MpGrpa5r8Yc=
-k8s.io/csi-translation-lib v0.21.0/go.mod h1:edq+UMpgqEx3roTuGF/03uIuSOsI986jtu65+ytLlkA=
k8s.io/gengo v0.0.0-20200413195148-3a45101e95ac/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0=
+k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE=
+k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
k8s.io/klog/v2 v2.4.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
-k8s.io/klog/v2 v2.8.0 h1:Q3gmuM9hKEjefWFFYF0Mat+YyFJvsUyYuwyNNJ5C9Ts=
-k8s.io/klog/v2 v2.8.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
+k8s.io/klog/v2 v2.9.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
+k8s.io/klog/v2 v2.30.0 h1:bUO6drIvCIsvZ/XFgfxoGFQU/a4Qkh0iAlvUR7vlHJw=
+k8s.io/klog/v2 v2.30.0/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
k8s.io/kube-openapi v0.0.0-20201113171705-d219536bb9fd/go.mod h1:WOJ3KddDSol4tAGcJo0Tvi+dK12EcqSLqcWsryKMpfM=
-k8s.io/kube-openapi v0.0.0-20210305001622-591a79e4bda7 h1:vEx13qjvaZ4yfObSSXW7BrMc/KQBBT/Jyee8XtLf4x0=
-k8s.io/kube-openapi v0.0.0-20210305001622-591a79e4bda7/go.mod h1:wXW5VT87nVfh/iLV8FpR2uDvrFyomxbtb1KivDbvPTE=
+k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c/go.mod h1:vHXdDvt9+2spS2Rx9ql3I8tycm3H9FDfdUoIuKCefvw=
+k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65 h1:E3J9oCLlaobFUqsjG9DfKbP2BmgwBL2p7pn0A3dG9W4=
+k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65/go.mod h1:sX9MT8g7NVZM5lVL/j8QyCCJe8YSMW30QvGZWaCIDIk=
k8s.io/kubernetes v1.13.0/go.mod h1:ocZa8+6APFNC2tX1DZASIbocyYT5jHzqFVsY5aoB7Jk=
-k8s.io/legacy-cloud-providers v0.21.0 h1:iWf5xaX9yvYT5mkz8UB96UtISQ5IkrWeuMPMhRp01ZY=
-k8s.io/legacy-cloud-providers v0.21.0/go.mod h1:bNxo7gDg+PGkBmT/MFZswLTWdSWK9kAlS1s8DJca5q4=
-k8s.io/utils v0.0.0-20201110183641-67b214c5f920 h1:CbnUZsM497iRC5QMVkHwyl8s2tB3g7yaSHkYPkpgelw=
k8s.io/utils v0.0.0-20201110183641-67b214c5f920/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
+k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
+k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
+k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b h1:wxEMGetGMur3J1xuGLQY7GEQYg9bZxKn3tKo5k/eYcs=
+k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0=
rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA=
@@ -1381,8 +1493,8 @@ sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.14/go.mod h1:LEScyz
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.15/go.mod h1:LEScyzhFmoF5pso/YSeBstl57mOzx9xlU9n85RGrDQg=
sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
sigs.k8s.io/structured-merge-diff/v4 v4.0.3/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
-sigs.k8s.io/structured-merge-diff/v4 v4.1.0 h1:C4r9BgJ98vrKnnVCjwCSXcWjWe0NKcUQkmzDXZXGwH8=
-sigs.k8s.io/structured-merge-diff/v4 v4.1.0/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
+sigs.k8s.io/structured-merge-diff/v4 v4.1.2 h1:Hr/htKFmJEbtMgS/UD0N+gtgctAqz81t3nu+sPzynno=
+sigs.k8s.io/structured-merge-diff/v4 v4.1.2/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4=
sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o=
sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=
sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain.go b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain.go
index 7055e51d8e7a..8760316a5974 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain.go
@@ -16,81 +16,42 @@ package k8schain
import (
"context"
- "fmt"
- "sync"
+ ecr "github.com/awslabs/amazon-ecr-credential-helper/ecr-login"
+ "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api"
+ "github.com/chrismellard/docker-credential-acr-env/pkg/credhelper"
"github.com/google/go-containerregistry/pkg/authn"
- "github.com/google/go-containerregistry/pkg/name"
- credentialprovider "github.com/vdemeester/k8s-pkg-credentialprovider"
- credentialprovidersecrets "github.com/vdemeester/k8s-pkg-credentialprovider/secrets"
+ kauth "github.com/google/go-containerregistry/pkg/authn/kubernetes"
+ "github.com/google/go-containerregistry/pkg/v1/google"
corev1 "k8s.io/api/core/v1"
- metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/client-go/kubernetes"
"k8s.io/client-go/rest"
)
-// Options holds configuration data for guiding credential resolution.
-type Options struct {
- // Namespace holds the namespace inside of which we are resolving the
- // image reference. If empty, "default" is assumed.
- Namespace string
- // ServiceAccountName holds the serviceaccount as which the container
- // will run (scoped to Namespace). If empty, "default" is assumed.
- ServiceAccountName string
- // ImagePullSecrets holds the names of the Kubernetes secrets (scoped to
- // Namespace) containing credential data to use for the image pull.
- ImagePullSecrets []string
-}
-
var (
- keyring credentialprovider.DockerKeyring
- once sync.Once
+ amazonKeychain authn.Keychain = authn.NewKeychainFromHelper(ecr.ECRHelper{ClientFactory: api.DefaultClientFactory{}})
+ azureKeychain authn.Keychain = authn.NewKeychainFromHelper(credhelper.NewACRCredentialsHelper())
)
+// Options holds configuration data for guiding credential resolution.
+type Options = kauth.Options
+
// New returns a new authn.Keychain suitable for resolving image references as
// scoped by the provided Options. It speaks to Kubernetes through the provided
// client interface.
func New(ctx context.Context, client kubernetes.Interface, opt Options) (authn.Keychain, error) {
- if opt.Namespace == "" {
- opt.Namespace = "default"
- }
- if opt.ServiceAccountName == "" {
- opt.ServiceAccountName = "default"
- }
-
- // Implement a Kubernetes-style authentication keychain.
- // This needs to support roughly the following kinds of authentication:
- // 1) The implicit authentication from k8s.io/kubernetes/pkg/credentialprovider
- // 2) The explicit authentication from imagePullSecrets on Pod
- // 3) The semi-implicit authentication where imagePullSecrets are on the
- // Pod's service account.
-
- // First, fetch all of the explicitly declared pull secrets
- var pullSecrets []corev1.Secret
- if client != nil {
- for _, name := range opt.ImagePullSecrets {
- ps, err := client.CoreV1().Secrets(opt.Namespace).Get(ctx, name, metav1.GetOptions{})
- if err != nil {
- return nil, err
- }
- pullSecrets = append(pullSecrets, *ps)
- }
-
- // Second, fetch all of the pull secrets attached to our service account.
- sa, err := client.CoreV1().ServiceAccounts(opt.Namespace).Get(ctx, opt.ServiceAccountName, metav1.GetOptions{})
- if err != nil {
- return nil, err
- }
- for _, localObj := range sa.ImagePullSecrets {
- ps, err := client.CoreV1().Secrets(opt.Namespace).Get(ctx, localObj.Name, metav1.GetOptions{})
- if err != nil {
- return nil, err
- }
- pullSecrets = append(pullSecrets, *ps)
- }
+ k8s, err := kauth.New(ctx, client, kauth.Options(opt))
+ if err != nil {
+ return nil, err
}
- return NewFromPullSecrets(ctx, pullSecrets)
+ return authn.NewMultiKeychain(
+ authn.DefaultKeychain,
+ google.Keychain,
+ amazonKeychain,
+ azureKeychain,
+ k8s,
+ ), nil
}
// NewInCluster returns a new authn.Keychain suitable for resolving image references as
@@ -118,67 +79,27 @@ func NewInCluster(ctx context.Context, opt Options) (authn.Keychain, error) {
// remains is an interesting sweet spot: this variant can serve as a credential provider
// for all of the major public clouds, but in library form (vs. an executable you exec).
func NewNoClient(ctx context.Context) (authn.Keychain, error) {
- return New(ctx, nil, Options{})
+ return authn.NewMultiKeychain(
+ authn.DefaultKeychain,
+ google.Keychain,
+ amazonKeychain,
+ azureKeychain,
+ ), nil
}
// NewFromPullSecrets returns a new authn.Keychain suitable for resolving image references as
// scoped by the pull secrets.
func NewFromPullSecrets(ctx context.Context, pullSecrets []corev1.Secret) (authn.Keychain, error) {
- once.Do(func() {
- keyring = credentialprovider.NewDockerKeyring()
- })
-
- // Extend the default keyring with the pull secrets.
- kr, err := credentialprovidersecrets.MakeDockerKeyring(pullSecrets, keyring)
+ k8s, err := kauth.NewFromPullSecrets(ctx, pullSecrets)
if err != nil {
return nil, err
}
- return &keychain{
- keyring: kr,
- }, nil
-}
-
-type lazyProvider struct {
- kc *keychain
- image string
-}
-
-// Authorization implements Authenticator.
-func (lp lazyProvider) Authorization() (*authn.AuthConfig, error) {
- creds, found := lp.kc.keyring.Lookup(lp.image)
- if !found || len(creds) < 1 {
- return nil, fmt.Errorf("keychain returned no credentials for %q", lp.image)
- }
- authConfig := creds[0]
- return &authn.AuthConfig{
- Username: authConfig.Username,
- Password: authConfig.Password,
- Auth: authConfig.Auth,
- IdentityToken: authConfig.IdentityToken,
- RegistryToken: authConfig.RegistryToken,
- }, nil
-}
-
-type keychain struct {
- keyring credentialprovider.DockerKeyring
-}
-// Resolve implements authn.Keychain
-func (kc *keychain) Resolve(target authn.Resource) (authn.Authenticator, error) {
- var image string
- if repo, ok := target.(name.Repository); ok {
- image = repo.String()
- } else {
- // Lookup expects an image reference and we only have a registry.
- image = target.RegistryStr() + "/foo/bar"
- }
-
- if creds, found := kc.keyring.Lookup(image); !found || len(creds) < 1 {
- return authn.Anonymous, nil
- }
- // TODO(mattmoor): How to support multiple credentials?
- return lazyProvider{
- kc: kc,
- image: image,
- }, nil
+ return authn.NewMultiKeychain(
+ authn.DefaultKeychain,
+ google.Keychain,
+ amazonKeychain,
+ azureKeychain,
+ k8s,
+ ), nil
}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_azure.go b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_azure.go
deleted file mode 100644
index d00074ec2785..000000000000
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_azure.go
+++ /dev/null
@@ -1,23 +0,0 @@
-//go:build !disable_azure
-// +build !disable_azure
-
-// Copyright 2019 Google LLC All Rights Reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package k8schain
-
-import (
- // azure credential provider
- _ "github.com/vdemeester/k8s-pkg-credentialprovider/azure"
-)
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_gcp.go b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_gcp.go
deleted file mode 100644
index f413e60e5ec8..000000000000
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_gcp.go
+++ /dev/null
@@ -1,23 +0,0 @@
-//go:build !disable_gcp
-// +build !disable_gcp
-
-// Copyright 2019 Google LLC All Rights Reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-package k8schain
-
-import (
- // gcp credential provider
- _ "github.com/vdemeester/k8s-pkg-credentialprovider/gcp"
-)
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/keychain.go b/vendor/github.com/google/go-containerregistry/pkg/authn/keychain.go
index 4917d39d66d7..f79b7260e855 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/keychain.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/keychain.go
@@ -138,3 +138,27 @@ func (dk *defaultKeychain) Resolve(target Resource) (Authenticator, error) {
RegistryToken: cfg.RegistryToken,
}), nil
}
+
+// Helper is a subset of the Docker credential helper credentials.Helper
+// interface used by NewKeychainFromHelper.
+//
+// See:
+// https://pkg.go.dev/github.com/docker/docker-credential-helpers/credentials#Helper
+type Helper interface {
+ Get(serverURL string) (string, string, error)
+}
+
+// NewKeychainFromHelper returns a Keychain based on a Docker credential helper
+// implementation that can Get username and password credentials for a given
+// server URL.
+func NewKeychainFromHelper(h Helper) Keychain { return wrapper{h} }
+
+type wrapper struct{ h Helper }
+
+func (w wrapper) Resolve(r Resource) (Authenticator, error) {
+ u, p, err := w.h.Get(r.String())
+ if err != nil {
+ return Anonymous, nil
+ }
+ return FromConfig(AuthConfig{Username: u, Password: p}), nil
+}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/LICENSE b/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/LICENSE
new file mode 100644
index 000000000000..7a4a3ea2424c
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
\ No newline at end of file
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/go.mod b/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/go.mod
new file mode 100644
index 000000000000..54f36c0a2b80
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/go.mod
@@ -0,0 +1,46 @@
+module github.com/google/go-containerregistry/pkg/authn/kubernetes
+
+go 1.17
+
+require (
+ github.com/google/go-containerregistry v0.8.0
+ k8s.io/api v0.22.5
+ k8s.io/apimachinery v0.22.5
+ k8s.io/client-go v0.22.5
+)
+
+require (
+ github.com/davecgh/go-spew v1.1.1 // indirect
+ github.com/docker/cli v20.10.12+incompatible // indirect
+ github.com/docker/docker v20.10.12+incompatible // indirect
+ github.com/docker/docker-credential-helpers v0.6.4 // indirect
+ github.com/evanphx/json-patch v4.12.0+incompatible // indirect
+ github.com/go-logr/logr v1.2.0 // indirect
+ github.com/gogo/protobuf v1.3.2 // indirect
+ github.com/golang/protobuf v1.5.2 // indirect
+ github.com/google/go-cmp v0.5.6 // indirect
+ github.com/google/gofuzz v1.1.0 // indirect
+ github.com/googleapis/gnostic v0.5.5 // indirect
+ github.com/json-iterator/go v1.1.12 // indirect
+ github.com/mitchellh/go-homedir v1.1.0 // indirect
+ github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
+ github.com/modern-go/reflect2 v1.0.2 // indirect
+ github.com/pkg/errors v0.9.1 // indirect
+ github.com/sirupsen/logrus v1.8.1 // indirect
+ golang.org/x/net v0.0.0-20211216030914-fe4d6282115f // indirect
+ golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 // indirect
+ golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e // indirect
+ golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b // indirect
+ golang.org/x/text v0.3.7 // indirect
+ golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac // indirect
+ google.golang.org/appengine v1.6.7 // indirect
+ google.golang.org/protobuf v1.27.1 // indirect
+ gopkg.in/inf.v0 v0.9.1 // indirect
+ gopkg.in/yaml.v2 v2.4.0 // indirect
+ gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
+ k8s.io/klog/v2 v2.30.0 // indirect
+ k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65 // indirect
+ k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b // indirect
+ sigs.k8s.io/structured-merge-diff/v4 v4.1.2 // indirect
+ sigs.k8s.io/yaml v1.2.0 // indirect
+)
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/go.sum b/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/go.sum
new file mode 100644
index 000000000000..7bd7258439de
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/go.sum
@@ -0,0 +1,1398 @@
+bazil.org/fuse v0.0.0-20160811212531-371fbbdaa898/go.mod h1:Xbm+BRKSBEpa4q4hTSxohYNQpsxXPbPry4JJWOB3LB8=
+cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
+cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
+cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU=
+cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU=
+cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
+cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc=
+cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0=
+cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To=
+cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4=
+cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M=
+cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc=
+cloud.google.com/go v0.56.0/go.mod h1:jr7tqZxxKOVYizybht9+26Z/gUq7tiRzu+ACVAMbKVk=
+cloud.google.com/go v0.57.0/go.mod h1:oXiQ6Rzq3RAkkY7N6t3TcE6jE+CIBBbA36lwQ1JyzZs=
+cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOYc=
+cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY=
+cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI=
+cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk=
+cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg=
+cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8=
+cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0=
+cloud.google.com/go v0.83.0/go.mod h1:Z7MJUsANfY0pYPdw0lbnivPx4/vhy/e2FEkSkF7vAVY=
+cloud.google.com/go v0.84.0/go.mod h1:RazrYuxIK6Kb7YrzzhPoLmCVzl7Sup4NrbKPg8KHSUM=
+cloud.google.com/go v0.87.0/go.mod h1:TpDYlFy7vuLzZMMZ+B6iRiELaY7z/gJPaqbMx6mlWcY=
+cloud.google.com/go v0.90.0/go.mod h1:kRX0mNRHe0e2rC6oNakvwQqzyDmg57xJ+SZU1eT2aDQ=
+cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+YI=
+cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4=
+cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc=
+cloud.google.com/go v0.98.0/go.mod h1:ua6Ush4NALrHk5QXDWnjvZHN93OuF0HfuEPq9I1X0cM=
+cloud.google.com/go v0.99.0/go.mod h1:w0Xx2nLzqWJPuozYQX+hFfCSI8WioryfRDzkoI/Y2ZA=
+cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o=
+cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE=
+cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc=
+cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg=
+cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc=
+cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ=
+cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE=
+cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk=
+cloud.google.com/go/firestore v1.6.1/go.mod h1:asNXNOzBdyVQmEU+ggO8UPodTkEVFW5Qx+rwHnAz+EY=
+cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I=
+cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw=
+cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA=
+cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU=
+cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw=
+cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos=
+cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk=
+cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs=
+cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0=
+dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
+github.com/Azure/azure-sdk-for-go v16.2.1+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
+github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
+github.com/Azure/go-autorest v10.8.1+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
+github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
+github.com/Azure/go-autorest/autorest v0.11.1/go.mod h1:JFgpikqFJ/MleTTxwepExTKnFUKKszPS8UavbQYUMuw=
+github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA=
+github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg=
+github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
+github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M=
+github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
+github.com/Azure/go-autorest/autorest/mocks v0.4.0/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
+github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
+github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
+github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
+github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
+github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
+github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
+github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ=
+github.com/Microsoft/go-winio v0.4.11/go.mod h1:VhR8bwka0BXejwEJY73c50VrPtXAaKcyvVC4A4RozmA=
+github.com/Microsoft/go-winio v0.4.14/go.mod h1:qXqCSQ3Xa7+6tgxaGTIe4Kpcdsi+P8jBhyzoq1bpyYA=
+github.com/Microsoft/go-winio v0.4.15-0.20190919025122-fc70bd9a86b5/go.mod h1:tTuCMEN+UleMWgg9dVx4Hu52b1bJo+59jBh3ajtinzw=
+github.com/Microsoft/go-winio v0.4.16-0.20201130162521-d1ffc52c7331/go.mod h1:XB6nPKklQyQ7GC9LdcBEcBl8PF76WugXOPRXwdLnMv0=
+github.com/Microsoft/go-winio v0.4.16/go.mod h1:XB6nPKklQyQ7GC9LdcBEcBl8PF76WugXOPRXwdLnMv0=
+github.com/Microsoft/go-winio v0.4.17-0.20210211115548-6eac466e5fa3/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
+github.com/Microsoft/go-winio v0.4.17-0.20210324224401-5516f17a5958/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
+github.com/Microsoft/go-winio v0.4.17/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
+github.com/Microsoft/go-winio v0.5.1/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84=
+github.com/Microsoft/hcsshim v0.8.6/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg=
+github.com/Microsoft/hcsshim v0.8.7-0.20190325164909-8abdbb8205e4/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg=
+github.com/Microsoft/hcsshim v0.8.7/go.mod h1:OHd7sQqRFrYd3RmSgbgji+ctCwkbq2wbEYNSzOYtcBQ=
+github.com/Microsoft/hcsshim v0.8.9/go.mod h1:5692vkUqntj1idxauYlpoINNKeqCiG6Sg38RRsjT5y8=
+github.com/Microsoft/hcsshim v0.8.14/go.mod h1:NtVKoYxQuTLx6gEq0L96c9Ju4JbRJ4nY2ow3VK6a9Lg=
+github.com/Microsoft/hcsshim v0.8.15/go.mod h1:x38A4YbHbdxJtc0sF6oIz+RG0npwSCAvn69iY6URG00=
+github.com/Microsoft/hcsshim v0.8.16/go.mod h1:o5/SZqmR7x9JNKsW3pu+nqHm0MF8vbA+VxGOoXdC600=
+github.com/Microsoft/hcsshim v0.8.23/go.mod h1:4zegtUJth7lAvFyc6cH2gGQ5B3OFQim01nnU2M8jKDg=
+github.com/Microsoft/hcsshim/test v0.0.0-20201218223536-d3e5debf77da/go.mod h1:5hlzMzRKMLyo42nCZ9oml8AdTlq/0cvIaBv6tK1RehU=
+github.com/Microsoft/hcsshim/test v0.0.0-20210227013316-43a75bb4edd3/go.mod h1:mw7qgWloBUl75W/gVH3cQszUg1+gUITj7D6NY7ywVnY=
+github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ=
+github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU=
+github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0=
+github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE=
+github.com/Shopify/logrus-bugsnag v0.0.0-20171204204709-577dee27f20d/go.mod h1:HI8ITrYtUY+O+ZhtlqUnD8+KwNPOyugEhfP9fdUIaEQ=
+github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc=
+github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc=
+github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
+github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
+github.com/alexflint/go-filemutex v0.0.0-20171022225611-72bdc8eae2ae/go.mod h1:CgnQgUtFrFz9mxFNtED3jI5tLDjKlOM+oUF/sTk6ps0=
+github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY=
+github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o=
+github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
+github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY=
+github.com/armon/go-metrics v0.3.10/go.mod h1:4O98XIr/9W0sxpJ8UaYkvjk10Iff7SnFrb4QAOwNTFc=
+github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
+github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
+github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY=
+github.com/aws/aws-sdk-go v1.15.11/go.mod h1:mFuSZ37Z9YOHbQEwBWztmVzqXrEkub65tZoCYDt7FT0=
+github.com/beorn7/perks v0.0.0-20160804104726-4c0e84591b9a/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
+github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
+github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
+github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
+github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs=
+github.com/bitly/go-simplejson v0.5.0/go.mod h1:cXHtHw4XUPsvGaxgjIAn8PhEWG9NfngEKAMDJEczWVA=
+github.com/bits-and-blooms/bitset v1.2.0/go.mod h1:gIdJ4wp64HaoK2YrL1Q5/N7Y16edYb8uY+O0FJTyyDA=
+github.com/blang/semver v3.1.0+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
+github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
+github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869/go.mod h1:Ekp36dRnpXw/yCqJaO+ZrUyxD+3VXMFFr56k5XYrpB4=
+github.com/bshuster-repo/logrus-logstash-hook v0.4.1/go.mod h1:zsTqEiSzDgAa/8GZR7E1qaXrhYNDKBYy5/dWPTIflbk=
+github.com/buger/jsonparser v0.0.0-20180808090653-f4dd9f5a6b44/go.mod h1:bbYlZJ7hK1yFx9hf58LP0zeX7UjIGs20ufpu3evjr+s=
+github.com/bugsnag/bugsnag-go v0.0.0-20141110184014-b1d153021fcd/go.mod h1:2oa8nejYd4cQ/b0hMIopN0lCRxU0bueqREvZLWFrtK8=
+github.com/bugsnag/osext v0.0.0-20130617224835-0dd3f918b21b/go.mod h1:obH5gd0BsqsP2LwDJ9aOkm/6J86V6lyAXCoQWGw3K50=
+github.com/bugsnag/panicwrap v0.0.0-20151223152923-e2c28503fcd0/go.mod h1:D/8v3kj0zr8ZAKg1AQ6crr+5VwKN5eIywRkfhyM/+dE=
+github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw=
+github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
+github.com/census-instrumentation/opencensus-proto v0.3.0/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
+github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc=
+github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
+github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
+github.com/checkpoint-restore/go-criu/v4 v4.1.0/go.mod h1:xUQBLp4RLc5zJtWY++yjOoMoB5lihDt7fai+75m+rGw=
+github.com/checkpoint-restore/go-criu/v5 v5.0.0/go.mod h1:cfwC0EG7HMUenopBsUf9d89JlCLQIfgVcNsNN0t6T2M=
+github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
+github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
+github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
+github.com/cilium/ebpf v0.0.0-20200110133405-4032b1d8aae3/go.mod h1:MA5e5Lr8slmEg9bt0VpxxWqJlO4iwu3FBdHUzV7wQVg=
+github.com/cilium/ebpf v0.0.0-20200702112145-1c8d4c9ef775/go.mod h1:7cR51M8ViRLIdUjrmSXlK9pkrsDlLHbO8jiB8X8JnOc=
+github.com/cilium/ebpf v0.2.0/go.mod h1:To2CFviqOWL/M0gIMsvSMlqe7em/l1ALkX1PyjrX2Qs=
+github.com/cilium/ebpf v0.4.0/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs=
+github.com/cilium/ebpf v0.6.2/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs=
+github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag=
+github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I=
+github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
+github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc=
+github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
+github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk=
+github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI=
+github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cncf/xds/go v0.0.0-20211130200136-a8f946100490/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
+github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8=
+github.com/containerd/aufs v0.0.0-20200908144142-dab0cbea06f4/go.mod h1:nukgQABAEopAHvB6j7cnP5zJ+/3aVcE7hCYqvIwAHyE=
+github.com/containerd/aufs v0.0.0-20201003224125-76a6863f2989/go.mod h1:AkGGQs9NM2vtYHaUen+NljV0/baGCAPELGm2q9ZXpWU=
+github.com/containerd/aufs v0.0.0-20210316121734-20793ff83c97/go.mod h1:kL5kd6KM5TzQjR79jljyi4olc1Vrx6XBlcyj3gNv2PU=
+github.com/containerd/aufs v1.0.0/go.mod h1:kL5kd6KM5TzQjR79jljyi4olc1Vrx6XBlcyj3gNv2PU=
+github.com/containerd/btrfs v0.0.0-20201111183144-404b9149801e/go.mod h1:jg2QkJcsabfHugurUvvPhS3E08Oxiuh5W/g1ybB4e0E=
+github.com/containerd/btrfs v0.0.0-20210316141732-918d888fb676/go.mod h1:zMcX3qkXTAi9GI50+0HOeuV8LU2ryCE/V2vG/ZBiTss=
+github.com/containerd/btrfs v1.0.0/go.mod h1:zMcX3qkXTAi9GI50+0HOeuV8LU2ryCE/V2vG/ZBiTss=
+github.com/containerd/cgroups v0.0.0-20190717030353-c4b9ac5c7601/go.mod h1:X9rLEHIqSf/wfK8NsPqxJmeZgW4pcfzdXITDrUSJ6uI=
+github.com/containerd/cgroups v0.0.0-20190919134610-bf292b21730f/go.mod h1:OApqhQ4XNSNC13gXIwDjhOQxjWa/NxkwZXJ1EvqT0ko=
+github.com/containerd/cgroups v0.0.0-20200531161412-0dbf7f05ba59/go.mod h1:pA0z1pT8KYB3TCXK/ocprsh7MAkoW8bZVzPdih9snmM=
+github.com/containerd/cgroups v0.0.0-20200710171044-318312a37340/go.mod h1:s5q4SojHctfxANBDvMeIaIovkq29IP48TKAxnhYRxvo=
+github.com/containerd/cgroups v0.0.0-20200824123100-0b889c03f102/go.mod h1:s5q4SojHctfxANBDvMeIaIovkq29IP48TKAxnhYRxvo=
+github.com/containerd/cgroups v0.0.0-20210114181951-8a68de567b68/go.mod h1:ZJeTFisyysqgcCdecO57Dj79RfL0LNeGiFUqLYQRYLE=
+github.com/containerd/cgroups v1.0.1/go.mod h1:0SJrPIenamHDcZhEcJMNBB85rHcUsw4f25ZfBiPYRkU=
+github.com/containerd/console v0.0.0-20180822173158-c12b1e7919c1/go.mod h1:Tj/on1eG8kiEhd0+fhSDzsPAFESxzBBvdyEgyryXffw=
+github.com/containerd/console v0.0.0-20181022165439-0650fd9eeb50/go.mod h1:Tj/on1eG8kiEhd0+fhSDzsPAFESxzBBvdyEgyryXffw=
+github.com/containerd/console v0.0.0-20191206165004-02ecf6a7291e/go.mod h1:8Pf4gM6VEbTNRIT26AyyU7hxdQU3MvAvxVI0sc00XBE=
+github.com/containerd/console v1.0.1/go.mod h1:XUsP6YE/mKtz6bxc+I8UiKKTP04qjQL4qcS3XoQ5xkw=
+github.com/containerd/console v1.0.2/go.mod h1:ytZPjGgY2oeTkAONYafi2kSj0aYggsf8acV1PGKCbzQ=
+github.com/containerd/containerd v1.2.10/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.3.0-beta.2.0.20190828155532-0293cbd26c69/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.3.0/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.3.1-0.20191213020239-082f7e3aed57/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.3.2/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.4.0-beta.2.0.20200729163537-40b22ef07410/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.4.1/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.4.3/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.4.9/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/containerd/containerd v1.5.0-beta.1/go.mod h1:5HfvG1V2FsKesEGQ17k5/T7V960Tmcumvqn8Mc+pCYQ=
+github.com/containerd/containerd v1.5.0-beta.3/go.mod h1:/wr9AVtEM7x9c+n0+stptlo/uBBoBORwEx6ardVcmKU=
+github.com/containerd/containerd v1.5.0-beta.4/go.mod h1:GmdgZd2zA2GYIBZ0w09ZvgqEq8EfBp/m3lcVZIvPHhI=
+github.com/containerd/containerd v1.5.0-rc.0/go.mod h1:V/IXoMqNGgBlabz3tHD2TWDoTJseu1FGOKuoA4nNb2s=
+github.com/containerd/containerd v1.5.8/go.mod h1:YdFSv5bTFLpG2HIYmfqDpSYYTDX+mc5qtSuYx1YUb/s=
+github.com/containerd/continuity v0.0.0-20190426062206-aaeac12a7ffc/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y=
+github.com/containerd/continuity v0.0.0-20190815185530-f2a389ac0a02/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y=
+github.com/containerd/continuity v0.0.0-20191127005431-f65d91d395eb/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y=
+github.com/containerd/continuity v0.0.0-20200710164510-efbc4488d8fe/go.mod h1:cECdGN1O8G9bgKTlLhuPJimka6Xb/Gg7vYzCTNVxhvo=
+github.com/containerd/continuity v0.0.0-20201208142359-180525291bb7/go.mod h1:kR3BEg7bDFaEddKm54WSmrol1fKWDU1nKYkgrcgZT7Y=
+github.com/containerd/continuity v0.0.0-20210208174643-50096c924a4e/go.mod h1:EXlVlkqNba9rJe3j7w3Xa924itAMLgZH4UD/Q4PExuQ=
+github.com/containerd/continuity v0.1.0/go.mod h1:ICJu0PwR54nI0yPEnJ6jcS+J7CZAUXrLh8lPo2knzsM=
+github.com/containerd/fifo v0.0.0-20180307165137-3d5202aec260/go.mod h1:ODA38xgv3Kuk8dQz2ZQXpnv/UZZUHUCL7pnLehbXgQI=
+github.com/containerd/fifo v0.0.0-20190226154929-a9fb20d87448/go.mod h1:ODA38xgv3Kuk8dQz2ZQXpnv/UZZUHUCL7pnLehbXgQI=
+github.com/containerd/fifo v0.0.0-20200410184934-f15a3290365b/go.mod h1:jPQ2IAeZRCYxpS/Cm1495vGFww6ecHmMk1YJH2Q5ln0=
+github.com/containerd/fifo v0.0.0-20201026212402-0724c46b320c/go.mod h1:jPQ2IAeZRCYxpS/Cm1495vGFww6ecHmMk1YJH2Q5ln0=
+github.com/containerd/fifo v0.0.0-20210316144830-115abcc95a1d/go.mod h1:ocF/ME1SX5b1AOlWi9r677YJmCPSwwWnQ9O123vzpE4=
+github.com/containerd/fifo v1.0.0/go.mod h1:ocF/ME1SX5b1AOlWi9r677YJmCPSwwWnQ9O123vzpE4=
+github.com/containerd/go-cni v1.0.1/go.mod h1:+vUpYxKvAF72G9i1WoDOiPGRtQpqsNW/ZHtSlv++smU=
+github.com/containerd/go-cni v1.0.2/go.mod h1:nrNABBHzu0ZwCug9Ije8hL2xBCYh/pjfMb1aZGrrohk=
+github.com/containerd/go-runc v0.0.0-20180907222934-5a6d9f37cfa3/go.mod h1:IV7qH3hrUgRmyYrtgEeGWJfWbgcHL9CSRruz2Vqcph0=
+github.com/containerd/go-runc v0.0.0-20190911050354-e029b79d8cda/go.mod h1:IV7qH3hrUgRmyYrtgEeGWJfWbgcHL9CSRruz2Vqcph0=
+github.com/containerd/go-runc v0.0.0-20200220073739-7016d3ce2328/go.mod h1:PpyHrqVs8FTi9vpyHwPwiNEGaACDxT/N/pLcvMSRA9g=
+github.com/containerd/go-runc v0.0.0-20201020171139-16b287bc67d0/go.mod h1:cNU0ZbCgCQVZK4lgG3P+9tn9/PaJNmoDXPpoJhDR+Ok=
+github.com/containerd/go-runc v1.0.0/go.mod h1:cNU0ZbCgCQVZK4lgG3P+9tn9/PaJNmoDXPpoJhDR+Ok=
+github.com/containerd/imgcrypt v1.0.1/go.mod h1:mdd8cEPW7TPgNG4FpuP3sGBiQ7Yi/zak9TYCG3juvb0=
+github.com/containerd/imgcrypt v1.0.4-0.20210301171431-0ae5c75f59ba/go.mod h1:6TNsg0ctmizkrOgXRNQjAPFWpMYRWuiB6dSF4Pfa5SA=
+github.com/containerd/imgcrypt v1.1.1-0.20210312161619-7ed62a527887/go.mod h1:5AZJNI6sLHJljKuI9IHnw1pWqo/F0nGDOuR9zgTs7ow=
+github.com/containerd/imgcrypt v1.1.1/go.mod h1:xpLnwiQmEUJPvQoAapeb2SNCxz7Xr6PJrXQb0Dpc4ms=
+github.com/containerd/nri v0.0.0-20201007170849-eb1350a75164/go.mod h1:+2wGSDGFYfE5+So4M5syatU0N0f0LbWpuqyMi4/BE8c=
+github.com/containerd/nri v0.0.0-20210316161719-dbaa18c31c14/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY=
+github.com/containerd/nri v0.1.0/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY=
+github.com/containerd/stargz-snapshotter/estargz v0.10.1/go.mod h1:aE5PCyhFMwR8sbrErO5eM2GcvkyXTTJremG883D4qF0=
+github.com/containerd/ttrpc v0.0.0-20190828154514-0e0f228740de/go.mod h1:PvCDdDGpgqzQIzDW1TphrGLssLDZp2GuS+X5DkEJB8o=
+github.com/containerd/ttrpc v0.0.0-20190828172938-92c8520ef9f8/go.mod h1:PvCDdDGpgqzQIzDW1TphrGLssLDZp2GuS+X5DkEJB8o=
+github.com/containerd/ttrpc v0.0.0-20191028202541-4f1b8fe65a5c/go.mod h1:LPm1u0xBw8r8NOKoOdNMeVHSawSsltak+Ihv+etqsE8=
+github.com/containerd/ttrpc v1.0.1/go.mod h1:UAxOpgT9ziI0gJrmKvgcZivgxOp8iFPSk8httJEt98Y=
+github.com/containerd/ttrpc v1.0.2/go.mod h1:UAxOpgT9ziI0gJrmKvgcZivgxOp8iFPSk8httJEt98Y=
+github.com/containerd/ttrpc v1.1.0/go.mod h1:XX4ZTnoOId4HklF4edwc4DcqskFZuvXB1Evzy5KFQpQ=
+github.com/containerd/typeurl v0.0.0-20180627222232-a93fcdb778cd/go.mod h1:Cm3kwCdlkCfMSHURc+r6fwoGH6/F1hH3S4sg0rLFWPc=
+github.com/containerd/typeurl v0.0.0-20190911142611-5eb25027c9fd/go.mod h1:GeKYzf2pQcqv7tJ0AoCuuhtnqhva5LNU3U+OyKxxJpk=
+github.com/containerd/typeurl v1.0.1/go.mod h1:TB1hUtrpaiO88KEK56ijojHS1+NeF0izUACaJW2mdXg=
+github.com/containerd/typeurl v1.0.2/go.mod h1:9trJWW2sRlGub4wZJRTW83VtbOLS6hwcDZXTn6oPz9s=
+github.com/containerd/zfs v0.0.0-20200918131355-0a33824f23a2/go.mod h1:8IgZOBdv8fAgXddBT4dBXJPtxyRsejFIpXoklgxgEjw=
+github.com/containerd/zfs v0.0.0-20210301145711-11e8f1707f62/go.mod h1:A9zfAbMlQwE+/is6hi0Xw8ktpL+6glmqZYtevJgaB8Y=
+github.com/containerd/zfs v0.0.0-20210315114300-dde8f0fda960/go.mod h1:m+m51S1DvAP6r3FcmYCp54bQ34pyOwTieQDNRIRHsFY=
+github.com/containerd/zfs v0.0.0-20210324211415-d5c4544f0433/go.mod h1:m+m51S1DvAP6r3FcmYCp54bQ34pyOwTieQDNRIRHsFY=
+github.com/containerd/zfs v1.0.0/go.mod h1:m+m51S1DvAP6r3FcmYCp54bQ34pyOwTieQDNRIRHsFY=
+github.com/containernetworking/cni v0.7.1/go.mod h1:LGwApLUm2FpoOfxTDEeq8T9ipbpZ61X79hmU3w8FmsY=
+github.com/containernetworking/cni v0.8.0/go.mod h1:LGwApLUm2FpoOfxTDEeq8T9ipbpZ61X79hmU3w8FmsY=
+github.com/containernetworking/cni v0.8.1/go.mod h1:LGwApLUm2FpoOfxTDEeq8T9ipbpZ61X79hmU3w8FmsY=
+github.com/containernetworking/plugins v0.8.6/go.mod h1:qnw5mN19D8fIwkqW7oHHYDHVlzhJpcY6TQxn/fUyDDM=
+github.com/containernetworking/plugins v0.9.1/go.mod h1:xP/idU2ldlzN6m4p5LmGiwRDjeJr6FLK6vuiUwoH7P8=
+github.com/containers/ocicrypt v1.0.1/go.mod h1:MeJDzk1RJHv89LjsH0Sp5KTY3ZYkjXO/C+bKAeWFIrc=
+github.com/containers/ocicrypt v1.1.0/go.mod h1:b8AOe0YR67uU8OqfVNcznfFpAzu3rdgUV4GP9qXPfu4=
+github.com/containers/ocicrypt v1.1.1/go.mod h1:Dm55fwWm1YZAjYRaJ94z2mfZikIyIN4B0oB3dj3jFxY=
+github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
+github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
+github.com/coreos/go-iptables v0.4.5/go.mod h1:/mVI274lEDI2ns62jHCDnCyBF9Iwsmekav8Dbxlm1MU=
+github.com/coreos/go-iptables v0.5.0/go.mod h1:/mVI274lEDI2ns62jHCDnCyBF9Iwsmekav8Dbxlm1MU=
+github.com/coreos/go-oidc v2.1.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc=
+github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
+github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
+github.com/coreos/go-systemd v0.0.0-20161114122254-48702e0da86b/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
+github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
+github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
+github.com/coreos/go-systemd/v22 v22.0.0/go.mod h1:xO0FLkIi5MaZafQlIrOotqXZ90ih+1atmu1JpKERPPk=
+github.com/coreos/go-systemd/v22 v22.1.0/go.mod h1:xO0FLkIi5MaZafQlIrOotqXZ90ih+1atmu1JpKERPPk=
+github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc=
+github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
+github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
+github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
+github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
+github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
+github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY=
+github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
+github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
+github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4=
+github.com/d2g/dhcp4 v0.0.0-20170904100407-a1d1b6c41b1c/go.mod h1:Ct2BUK8SB0YC1SMSibvLzxjeJLnrYEVLULFNiHY9YfQ=
+github.com/d2g/dhcp4client v1.0.0/go.mod h1:j0hNfjhrt2SxUOw55nL0ATM/z4Yt3t2Kd1mW34z5W5s=
+github.com/d2g/dhcp4server v0.0.0-20181031114812-7d4a0a7f59a5/go.mod h1:Eo87+Kg/IX2hfWJfwxMzLyuSZyxSoAug2nGa1G2QAi8=
+github.com/d2g/hardwareaddr v0.0.0-20190221164911-e7d9fbe030e4/go.mod h1:bMl4RjIciD2oAxI7DmWRx6gbeqrkoLqv3MV0vzNad+I=
+github.com/danieljoos/wincred v1.1.0/go.mod h1:XYlo+eRTsVA9aHGp7NGjFkPla4m+DCL7hqDjlFjiygg=
+github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
+github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
+github.com/denverdino/aliyungo v0.0.0-20190125010748-a747050bb1ba/go.mod h1:dV8lFg6daOBZbT6/BDGIz6Y3WFGn8juu6G+CQ6LHtl0=
+github.com/dgrijalva/jwt-go v0.0.0-20170104182250-a601269ab70c/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
+github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
+github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
+github.com/dnaeon/go-vcr v1.0.1/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E=
+github.com/docker/cli v20.10.12+incompatible h1:lZlz0uzG+GH+c0plStMUdF/qk3ppmgnswpR5EbqzVGA=
+github.com/docker/cli v20.10.12+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
+github.com/docker/distribution v0.0.0-20190905152932-14b96e55d84c/go.mod h1:0+TTO4EOBfRPhZXAeF1Vu+W3hHZ8eLp8PgKVZlcvtFY=
+github.com/docker/distribution v2.7.1-0.20190205005809-0d3efadf0154+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w=
+github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w=
+github.com/docker/docker v20.10.12+incompatible h1:CEeNmFM0QZIsJCZKMkZx0ZcahTiewkrgiwfYD+dfl1U=
+github.com/docker/docker v20.10.12+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
+github.com/docker/docker-credential-helpers v0.6.4 h1:axCks+yV+2MR3/kZhAmy07yC56WZ2Pwu/fKWtKuZB0o=
+github.com/docker/docker-credential-helpers v0.6.4/go.mod h1:ofX3UI0Gz1TteYBjtgs07O36Pyasyp66D2uKT7H8W1c=
+github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec=
+github.com/docker/go-events v0.0.0-20170721190031-9461782956ad/go.mod h1:Uw6UezgYA44ePAFQYUehOuCzmy5zmg/+nl2ZfMWGkpA=
+github.com/docker/go-events v0.0.0-20190806004212-e31b211e4f1c/go.mod h1:Uw6UezgYA44ePAFQYUehOuCzmy5zmg/+nl2ZfMWGkpA=
+github.com/docker/go-metrics v0.0.0-20180209012529-399ea8c73916/go.mod h1:/u0gXw0Gay3ceNrsHubL3BtdOL2fHf93USgMTe0W5dI=
+github.com/docker/go-metrics v0.0.1/go.mod h1:cG1hvH2utMXtqgqqYE9plW6lDxS3/5ayHzueweSI3Vw=
+github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
+github.com/docker/libtrust v0.0.0-20150114040149-fa567046d9b1/go.mod h1:cyGadeNEkKy96OOhEzfZl+yxihPEzKnqJwvfuSUqbZE=
+github.com/docker/spdystream v0.0.0-20160310174837-449fdfce4d96/go.mod h1:Qh8CwZgvJUkLughtfhJv5dyTYa91l1fOUCrgjqmcifM=
+github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE=
+github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
+github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
+github.com/elazarl/goproxy v0.0.0-20180725130230-947c36da3153/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc=
+github.com/emicklei/go-restful v0.0.0-20170410110728-ff4f55a20633/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs=
+github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs=
+github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
+github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
+github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98=
+github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po=
+github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk=
+github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk=
+github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ=
+github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0=
+github.com/envoyproxy/go-control-plane v0.10.1/go.mod h1:AY7fTTXNdv/aJ2O5jwpxAPOWUZ7hQAEvzN5Pf27BkQQ=
+github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
+github.com/envoyproxy/protoc-gen-validate v0.6.2/go.mod h1:2t7qjJNvHPx8IjnBOzl9E9/baC+qXE/TeeyBRzgJDws=
+github.com/evanphx/json-patch v4.9.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
+github.com/evanphx/json-patch v4.11.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
+github.com/evanphx/json-patch v4.12.0+incompatible h1:4onqiflcdA9EOZ4RxV643DvftH5pOlLGNtQ5lPWQu84=
+github.com/evanphx/json-patch v4.12.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
+github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
+github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU=
+github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
+github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
+github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
+github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
+github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
+github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
+github.com/fsnotify/fsnotify v1.5.1 h1:mZcQUHVQUQWoPXXtuf9yuEXKudkV2sx1E06UadKWpgI=
+github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU=
+github.com/fullsailor/pkcs7 v0.0.0-20190404230743-d7302db945fa/go.mod h1:KnogPXtdwXqoenmZCw6S+25EAm2MkxbG0deNDu4cbSA=
+github.com/garyburd/redigo v0.0.0-20150301180006-535138d7bcd7/go.mod h1:NR3MbYisc3/PwhQ00EMzDiPmrwpPxAn5GI05/YaO1SY=
+github.com/getkin/kin-openapi v0.76.0/go.mod h1:660oXbgy5JFMKreazJaQTw7o+X00qeSyhcnluiMv+Xg=
+github.com/ghodss/yaml v0.0.0-20150909031657-73d445a93680/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
+github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
+github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
+github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
+github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
+github.com/go-ini/ini v1.25.4/go.mod h1:ByCAeIL28uOIIG0E3PJtZPDL8WnHpFKFOtgjp+3Ies8=
+github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
+github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
+github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
+github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
+github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas=
+github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
+github.com/go-logr/logr v0.4.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
+github.com/go-logr/logr v1.2.0 h1:QK40JKJyMdUDz+h+xvCsru/bJhvG0UxvePV0ufL/AcE=
+github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
+github.com/go-openapi/jsonpointer v0.19.2/go.mod h1:3akKfEdA7DF1sugOqz1dVQHBcuDBPKZGEoHC/NkiQRg=
+github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
+github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
+github.com/go-openapi/jsonreference v0.19.2/go.mod h1:jMjeRr2HHw6nAVajTXJ4eiUwohSTlpa0o73RUL1owJc=
+github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL98+wF9xc8zWvFonSJ8=
+github.com/go-openapi/spec v0.19.3/go.mod h1:FpwSN1ksY1eteniUU7X0N/BgJ7a4WvBFVA8Lj9mJglo=
+github.com/go-openapi/swag v0.19.2/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
+github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
+github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
+github.com/godbus/dbus v0.0.0-20151105175453-c7fdd8b5cd55/go.mod h1:/YcGZj5zSblfDWMMoOzV4fas9FZnQYTkDnsGvmh2Grw=
+github.com/godbus/dbus v0.0.0-20180201030542-885f9cc04c9c/go.mod h1:/YcGZj5zSblfDWMMoOzV4fas9FZnQYTkDnsGvmh2Grw=
+github.com/godbus/dbus v0.0.0-20190422162347-ade71ed3457e/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4=
+github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
+github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
+github.com/gogo/googleapis v1.2.0/go.mod h1:Njal3psf3qN6dwBtQfUmBZh2ybovJ0tlu3o/AC7HYjU=
+github.com/gogo/googleapis v1.4.0/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c=
+github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ=
+github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4=
+github.com/gogo/protobuf v1.2.2-0.20190723190241-65acae22fc9d/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
+github.com/gogo/protobuf v1.3.0/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
+github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
+github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q=
+github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
+github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
+github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
+github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
+github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
+github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
+github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
+github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
+github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
+github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
+github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y=
+github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
+github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
+github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
+github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4=
+github.com/golang/mock v1.5.0/go.mod h1:CWnOUgYIOo4TcNZ0wHX3YZCqsaM1I1Jvs6v3mP3KVu8=
+github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs=
+github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
+github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
+github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
+github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
+github.com/golang/protobuf v1.3.4/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
+github.com/golang/protobuf v1.3.5/go.mod h1:6O5/vntMXwX2lRkT1hjjk0nAC1IDOTvTlVgjlRvqsdk=
+github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8=
+github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA=
+github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs=
+github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w=
+github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0=
+github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8=
+github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI=
+github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI=
+github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk=
+github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM=
+github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw=
+github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY=
+github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
+github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
+github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
+github.com/google/btree v1.0.1/go.mod h1:xXMiIv4Fb/0kKde4SpL7qlzvu5cMJDRkFDxJfI9uaxA=
+github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
+github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
+github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
+github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
+github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-containerregistry v0.8.0 h1:mtR24eN6rapCN+shds82qFEIWWmg64NPMuyCNT7/Ogc=
+github.com/google/go-containerregistry v0.8.0/go.mod h1:wW5v71NHGnQyb4k+gSshjxidrC7lN33MdWEn+Mz9TsI=
+github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
+github.com/google/gofuzz v1.1.0 h1:Hsa8mG0dQ46ij8Sl2AYJDUv1oA9/d6Vk+3LG99Oe02g=
+github.com/google/gofuzz v1.1.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
+github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs=
+github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0=
+github.com/google/martian/v3 v3.1.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0=
+github.com/google/martian/v3 v3.2.1/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk=
+github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
+github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
+github.com/google/pprof v0.0.0-20191218002539-d4f498aebedc/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
+github.com/google/pprof v0.0.0-20200212024743-f11f1df84d12/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
+github.com/google/pprof v0.0.0-20200229191704-1ebb73c60ed3/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
+github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
+github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
+github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
+github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
+github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
+github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
+github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
+github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
+github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
+github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0=
+github.com/googleapis/gax-go/v2 v2.1.1/go.mod h1:hddJymUZASv3XPyGkUpKj8pPO47Rmb0eJc8R6ouapiM=
+github.com/googleapis/gnostic v0.4.1/go.mod h1:LRhVm6pbyptWbWbuZ38d1eyptfvIytN3ir6b65WBswg=
+github.com/googleapis/gnostic v0.5.1/go.mod h1:6U4PtQXGIEt/Z3h5MAT7FNofLnw9vXk2cUuW7uA/OeU=
+github.com/googleapis/gnostic v0.5.5 h1:9fHAtK0uDfpveeqqo1hkEZJcFvYXAiCN3UutL8F9xHw=
+github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA=
+github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
+github.com/gorilla/handlers v0.0.0-20150720190736-60c7bfde3e33/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ=
+github.com/gorilla/mux v1.7.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
+github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So=
+github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
+github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
+github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE=
+github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA=
+github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
+github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
+github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk=
+github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
+github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
+github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw=
+github.com/hashicorp/consul/api v1.11.0/go.mod h1:XjsvQN+RJGWI2TWy1/kqaE16HrR2J/FWgkYjdZQsX9M=
+github.com/hashicorp/consul/sdk v0.8.0/go.mod h1:GBvyrGALthsZObzUGsfgHZQDXjg4lOjagTIwIR1vPms=
+github.com/hashicorp/errwrap v0.0.0-20141028054710-7554cd9344ce/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
+github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
+github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
+github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
+github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48=
+github.com/hashicorp/go-hclog v0.12.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
+github.com/hashicorp/go-hclog v1.0.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
+github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
+github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
+github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM=
+github.com/hashicorp/go-multierror v0.0.0-20161216184304-ed905158d874/go.mod h1:JMRHfdO9jKNzS/+BTlxCjKNQHg/jZAft8U7LloJvN7I=
+github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk=
+github.com/hashicorp/go-multierror v1.1.0/go.mod h1:spPvp8C1qA32ftKqdAHm4hHTbPw+vmowP0z+KUhOZdA=
+github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs=
+github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8=
+github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU=
+github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4=
+github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
+github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
+github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
+github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
+github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
+github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
+github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64=
+github.com/hashicorp/mdns v1.0.1/go.mod h1:4gW7WsVCke5TE7EPeYliwHlRUyBtfCwuFwuMg2DmyNY=
+github.com/hashicorp/mdns v1.0.4/go.mod h1:mtBihi+LeNXGtG8L9dX59gAEa12BDtBQSp4v/YAJqrc=
+github.com/hashicorp/memberlist v0.2.2/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOnAH9VT3Sh9MUE=
+github.com/hashicorp/memberlist v0.3.0/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOnAH9VT3Sh9MUE=
+github.com/hashicorp/serf v0.9.5/go.mod h1:UWDWwZeL5cuWDJdl0C6wrvrUwEqtQ4ZKBKKENpqIUyk=
+github.com/hashicorp/serf v0.9.6/go.mod h1:TXZNMjZQijwlDvp+r0b63xZ45H7JmCmgg4gpTwn9UV4=
+github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
+github.com/iancoleman/strcase v0.2.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho=
+github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
+github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
+github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
+github.com/imdario/mergo v0.3.8/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
+github.com/imdario/mergo v0.3.10/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
+github.com/imdario/mergo v0.3.11/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
+github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
+github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
+github.com/j-keck/arping v0.0.0-20160618110441-2cf9dc699c56/go.mod h1:ymszkNOg6tORTn+6F6j+Jc8TOr5osrynvN6ivFWZ2GA=
+github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k=
+github.com/jmespath/go-jmespath v0.0.0-20160803190731-bd40a432e4c7/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k=
+github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo=
+github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
+github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
+github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
+github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
+github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
+github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM=
+github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo=
+github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU=
+github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk=
+github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
+github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w=
+github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q=
+github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00=
+github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8=
+github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
+github.com/klauspost/compress v1.11.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs=
+github.com/klauspost/compress v1.11.13/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs=
+github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk=
+github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
+github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
+github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
+github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg=
+github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc=
+github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
+github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
+github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI=
+github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
+github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
+github.com/kr/pty v1.1.5/go.mod h1:9r2w37qlBe7rQ6e1fg1S/9xpWHSnaqNdHD3WcMdbPDA=
+github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
+github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
+github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
+github.com/lyft/protoc-gen-star v0.5.3/go.mod h1:V0xaHgaf5oCCqmcxYcWiDfTiKsZsRc87/1qhoTACD8w=
+github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
+github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
+github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
+github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
+github.com/mailru/easyjson v0.7.0/go.mod h1:KAzv3t3aY1NaHWoQz1+4F1ccyAH66Jk7yos7ldAVICs=
+github.com/marstr/guid v1.1.0/go.mod h1:74gB1z2wpxxInTG6yaqA7KrtM0NZ+RbrcqDvYHefzho=
+github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
+github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE=
+github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
+github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
+github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4=
+github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
+github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
+github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
+github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84=
+github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE=
+github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
+github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
+github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU=
+github.com/mattn/go-shellwords v1.0.3/go.mod h1:3xCvwCdWdlDJUrvuMn7Wuy9eWs4pE8vqg+NOMyg4B2o=
+github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
+github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4=
+github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg=
+github.com/miekg/dns v1.1.26/go.mod h1:bPDLeHnStXmXAq1m/Ch/hvfNHr14JKNPMBo3VZKjuso=
+github.com/miekg/dns v1.1.41/go.mod h1:p6aan82bvRIyn+zDIv9xYNUpwa73JcSh9BKwknJysuI=
+github.com/miekg/pkcs11 v1.0.3/go.mod h1:XsNlhZGX73bx86s2hdc/FuaLm2CPZJemRLMA+WTFxgs=
+github.com/mistifyio/go-zfs v2.1.2-0.20190413222219-f784269be439+incompatible/go.mod h1:8AuVvqP/mXw1px98n46wfvcGfQ4ci2FwoAjKYxuo3Z4=
+github.com/mitchellh/cli v1.1.0/go.mod h1:xcISNoH86gajksDmfB23e/pu+B+GeFRMYmoHXxx3xhI=
+github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
+github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
+github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI=
+github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
+github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
+github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
+github.com/mitchellh/osext v0.0.0-20151018003038-5e2d6d41470f/go.mod h1:OkQIRizQZAeMln+1tSwduZz7+Af5oFlKirV/MSYes2A=
+github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQppc=
+github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c=
+github.com/moby/sys/mountinfo v0.4.0/go.mod h1:rEr8tzG/lsIZHBtN/JjGG+LMYx9eXgW2JI+6q0qou+A=
+github.com/moby/sys/mountinfo v0.4.1/go.mod h1:rEr8tzG/lsIZHBtN/JjGG+LMYx9eXgW2JI+6q0qou+A=
+github.com/moby/sys/symlink v0.1.0/go.mod h1:GGDODQmbFOjFsXvfLVn3+ZRxkch54RkSiGqsZeMYowQ=
+github.com/moby/term v0.0.0-20200312100748-672ec06f55cd/go.mod h1:DdlQx2hp0Ss5/fLikoLlEeIYiATotOjgB//nb973jeo=
+github.com/moby/term v0.0.0-20201216013528-df9cb8a40635/go.mod h1:FBS0z0QWA44HXygs7VXDUOGoN/1TV3RuWkLO04am3wc=
+github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
+github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=
+github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
+github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
+github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
+github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M=
+github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
+github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc=
+github.com/mrunalp/fileutils v0.5.0/go.mod h1:M1WthSahJixYnrXQl/DFQuteStB1weuxD2QJNHXfbSQ=
+github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
+github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
+github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
+github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw=
+github.com/ncw/swift v1.0.47/go.mod h1:23YIA4yWVnGwv2dQlN4bB7egfYX6YLn0Yo/S6zZO/ZM=
+github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno=
+github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78=
+github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A=
+github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U=
+github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo=
+github.com/onsi/ginkgo v0.0.0-20151202141238-7f8ab55aaf3b/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
+github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
+github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
+github.com/onsi/ginkgo v1.10.1/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
+github.com/onsi/ginkgo v1.10.3/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
+github.com/onsi/ginkgo v1.11.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
+github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk=
+github.com/onsi/ginkgo v1.14.0 h1:2mOpI4JVVPBN+WQRa0WKH2eXR+Ey+uK4n7Zj0aYpIQA=
+github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY=
+github.com/onsi/gomega v0.0.0-20151007035656-2152b45fa28a/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
+github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
+github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
+github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY=
+github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo=
+github.com/onsi/gomega v1.10.3 h1:gph6h/qe9GSUw1NhH1gp+qb+h8rXD8Cy60Z32Qw3ELA=
+github.com/onsi/gomega v1.10.3/go.mod h1:V9xEwhxec5O8UDM77eCW8vLymOMltsqPVYWrpDsH8xc=
+github.com/opencontainers/go-digest v0.0.0-20170106003457-a6d0ee40d420/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s=
+github.com/opencontainers/go-digest v0.0.0-20180430190053-c9281466c8b2/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s=
+github.com/opencontainers/go-digest v1.0.0-rc1/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s=
+github.com/opencontainers/go-digest v1.0.0-rc1.0.20180430190053-c9281466c8b2/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s=
+github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM=
+github.com/opencontainers/image-spec v1.0.0/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0=
+github.com/opencontainers/image-spec v1.0.1/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0=
+github.com/opencontainers/image-spec v1.0.2-0.20211117181255-693428a734f5/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0=
+github.com/opencontainers/runc v0.0.0-20190115041553-12f6a991201f/go.mod h1:qT5XzbpPznkRYVz/mWwUaVBUv2rmF59PVA73FjuZG0U=
+github.com/opencontainers/runc v0.1.1/go.mod h1:qT5XzbpPznkRYVz/mWwUaVBUv2rmF59PVA73FjuZG0U=
+github.com/opencontainers/runc v1.0.0-rc8.0.20190926000215-3e425f80a8c9/go.mod h1:qT5XzbpPznkRYVz/mWwUaVBUv2rmF59PVA73FjuZG0U=
+github.com/opencontainers/runc v1.0.0-rc9/go.mod h1:qT5XzbpPznkRYVz/mWwUaVBUv2rmF59PVA73FjuZG0U=
+github.com/opencontainers/runc v1.0.0-rc93/go.mod h1:3NOsor4w32B2tC0Zbl8Knk4Wg84SM2ImC1fxBuqJ/H0=
+github.com/opencontainers/runc v1.0.2/go.mod h1:aTaHFFwQXuA71CiyxOdFFIorAoemI04suvGRQFzWTD0=
+github.com/opencontainers/runtime-spec v0.1.2-0.20190507144316-5b71a03e2700/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
+github.com/opencontainers/runtime-spec v1.0.1/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
+github.com/opencontainers/runtime-spec v1.0.2-0.20190207185410-29686dbc5559/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
+github.com/opencontainers/runtime-spec v1.0.2/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
+github.com/opencontainers/runtime-spec v1.0.3-0.20200929063507-e6143ca7d51d/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
+github.com/opencontainers/runtime-spec v1.0.3-0.20210326190908-1c3f411f0417/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0=
+github.com/opencontainers/runtime-tools v0.0.0-20181011054405-1d69bd0f9c39/go.mod h1:r3f7wjNzSs2extwzU3Y+6pKfobzPh+kKFJ3ofN+3nfs=
+github.com/opencontainers/selinux v1.6.0/go.mod h1:VVGKuOLlE7v4PJyT6h7mNWvq1rzqiriPsEqVhc+svHE=
+github.com/opencontainers/selinux v1.8.0/go.mod h1:RScLhm78qiWa2gbVCcGkC7tCGdgk3ogry1nUQF8Evvo=
+github.com/opencontainers/selinux v1.8.2/go.mod h1:MUIHuUEvKB1wtJjQdOyYRgOnLD2xAPP8dBsCoU0KuF8=
+github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
+github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
+github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
+github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc=
+github.com/pelletier/go-toml v1.9.4/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c=
+github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU=
+github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
+github.com/pkg/errors v0.8.1-0.20171018195549-f15c970de5b7/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
+github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
+github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
+github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
+github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI=
+github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
+github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
+github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
+github.com/posener/complete v1.2.3/go.mod h1:WZIdtGGp+qx0sLrYKtIRAruyNpv6hFCicSgv7Sy7s/s=
+github.com/pquerna/cachecontrol v0.0.0-20171018203845-0dec1b30a021/go.mod h1:prYjPmNq4d1NPVmpShWobRqXY3q7Vp+80DqgxxUrUIA=
+github.com/prometheus/client_golang v0.0.0-20180209125602-c332b6f63c06/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
+github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
+github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso=
+github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo=
+github.com/prometheus/client_golang v1.1.0/go.mod h1:I1FGZT9+L76gKKOs5djB6ezCbFQP1xR9D75/vuwEF3g=
+github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU=
+github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M=
+github.com/prometheus/client_model v0.0.0-20171117100541-99fa1f4be8e5/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
+github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
+github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
+github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
+github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
+github.com/prometheus/common v0.0.0-20180110214958-89604d197083/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro=
+github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro=
+github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
+github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
+github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc=
+github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4=
+github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo=
+github.com/prometheus/procfs v0.0.0-20180125133057-cb4147076ac7/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
+github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
+github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
+github.com/prometheus/procfs v0.0.0-20190522114515-bc1a522cf7b1/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
+github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
+github.com/prometheus/procfs v0.0.3/go.mod h1:4A/X28fw3Fc593LaREMrKMqOKvUAntwMDaekg4FpcdQ=
+github.com/prometheus/procfs v0.0.5/go.mod h1:4A/X28fw3Fc593LaREMrKMqOKvUAntwMDaekg4FpcdQ=
+github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A=
+github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU=
+github.com/prometheus/procfs v0.2.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU=
+github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA=
+github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU=
+github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg=
+github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ=
+github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
+github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
+github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
+github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
+github.com/safchain/ethtool v0.0.0-20190326074333-42ed695e3de8/go.mod h1:Z0q5wiBQGYcxhMZ6gUqHn6pYNLypFAvaL3UvgZLR0U4=
+github.com/sagikazarmark/crypt v0.3.0/go.mod h1:uD/D+6UF4SrIR1uGEv7bBNkNqLGqUr43MRiaGWX1Nig=
+github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
+github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
+github.com/seccomp/libseccomp-golang v0.9.1/go.mod h1:GbW5+tmTXfcxTToHLXlScSlAvWlF4P2Ca7zGrPiEpWo=
+github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
+github.com/sirupsen/logrus v1.0.4-0.20170822132746-89742aefa4b2/go.mod h1:pMByvHTf9Beacp5x1UXfOR9xyW/9antXMhjMPG0dEzc=
+github.com/sirupsen/logrus v1.0.6/go.mod h1:pMByvHTf9Beacp5x1UXfOR9xyW/9antXMhjMPG0dEzc=
+github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
+github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q=
+github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE=
+github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88=
+github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0=
+github.com/sirupsen/logrus v1.8.1 h1:dJKuHgqk1NNQlqoA6BTlM1Wf9DOH3NBjQyu0h9+AZZE=
+github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0=
+github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc=
+github.com/smartystreets/goconvey v0.0.0-20190330032615-68dc04aab96a/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
+github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
+github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
+github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
+github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
+github.com/spf13/afero v1.3.3/go.mod h1:5KUK8ByomD5Ti5Artl0RtHeI5pTF7MIDuXL3yY520V4=
+github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
+github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
+github.com/spf13/cast v1.4.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
+github.com/spf13/cobra v0.0.2-0.20171109065643-2da4a54c5cee/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
+github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
+github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE=
+github.com/spf13/cobra v1.3.0/go.mod h1:BrRVncBjOJa/eUcVVm9CE+oC6as8k+VYr4NY7WCi9V4=
+github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
+github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
+github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
+github.com/spf13/pflag v1.0.1-0.20171106142849-4c012f6dcd95/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
+github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
+github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
+github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
+github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
+github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE=
+github.com/spf13/viper v1.10.0/go.mod h1:SoyBPwAtKDzypXNDFKN5kzH7ppppbGZtls1UpIy5AsM=
+github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980/go.mod h1:AO3tvPzVZ/ayst6UlUKUv6rcPQInYe3IknH3jYhAKu8=
+github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8=
+github.com/stretchr/objx v0.0.0-20180129172003-8a3f7159479f/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
+github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE=
+github.com/stretchr/testify v0.0.0-20180303142811-b89eecf5ca5d/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
+github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
+github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
+github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
+github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA=
+github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
+github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY=
+github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
+github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw=
+github.com/syndtr/gocapability v0.0.0-20170704070218-db04d3cc01c8/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww=
+github.com/syndtr/gocapability v0.0.0-20180916011248-d98352740cb2/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww=
+github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww=
+github.com/tchap/go-patricia v2.2.6+incompatible/go.mod h1:bmLyhP68RS6kStMGxByiQ23RP/odRBOTVjwp2cDyi6I=
+github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
+github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
+github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM=
+github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc=
+github.com/urfave/cli v0.0.0-20171014202726-7bc6a0acffa5/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
+github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
+github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
+github.com/urfave/cli v1.22.2/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
+github.com/urfave/cli v1.22.4/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
+github.com/vbatts/tar-split v0.11.2/go.mod h1:vV3ZuO2yWSVsz+pfFzDG/upWH1JhjOiEaWq6kXyQ3VI=
+github.com/vishvananda/netlink v0.0.0-20181108222139-023a6dafdcdf/go.mod h1:+SR5DhBJrl6ZM7CoCKvpw5BKroDKQ+PJqOg65H/2ktk=
+github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE=
+github.com/vishvananda/netlink v1.1.1-0.20201029203352-d40f9887b852/go.mod h1:twkDnbuQxJYemMlGd4JFIcuhgX83tXhKS2B/PRMpOho=
+github.com/vishvananda/netns v0.0.0-20180720170159-13995c7128cc/go.mod h1:ZjcWmFBXmLKZu9Nxj3WKYEafiSqer2rnvPr0en9UNpI=
+github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df/go.mod h1:JP3t17pCcGlemwknint6hfoeCVQrEMVwxRLRjXpq+BU=
+github.com/vishvananda/netns v0.0.0-20200728191858-db3c7e526aae/go.mod h1:DD4vA1DwXk04H54A1oHXtwZmA0grkVMdPxx/VGLCah0=
+github.com/willf/bitset v1.1.11-0.20200630133818-d5bec3311243/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4=
+github.com/willf/bitset v1.1.11/go.mod h1:83CECat5yLh5zVOf4P1ErAgKA5UDvKtgyUABdr3+MjI=
+github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU=
+github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ=
+github.com/xeipuuv/gojsonschema v0.0.0-20180618132009-1d523034197f/go.mod h1:5yf86TLmAcydyeJq5YvxkGPE2fm/u4myDekKRoLuqhs=
+github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
+github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
+github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
+github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
+github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
+github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
+github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
+github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
+github.com/yvasiyarov/go-metrics v0.0.0-20140926110328-57bccd1ccd43/go.mod h1:aX5oPXxHm3bOH+xeAttToC8pqch2ScQN/JoXYupl6xs=
+github.com/yvasiyarov/gorelic v0.0.0-20141212073537-a9bba5b9ab50/go.mod h1:NUSPSUX/bi6SeDMUh6brw0nXpxHnc96TguQh0+r/ssA=
+github.com/yvasiyarov/newrelic_platform_go v0.0.0-20140908184405-b21fdbd4370f/go.mod h1:GlGEuHIJweS1mbCqG+7vt2nvWLzLLnRHbXz5JKd/Qbg=
+go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
+go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
+go.etcd.io/bbolt v1.3.5/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ=
+go.etcd.io/etcd v0.5.0-alpha.5.0.20200910180754-dd1b699fc489/go.mod h1:yVHk9ub3CSBatqGNg7GRmsnfLWtoW60w4eDYfh7vHDg=
+go.etcd.io/etcd/api/v3 v3.5.1/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
+go.etcd.io/etcd/client/pkg/v3 v3.5.1/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
+go.etcd.io/etcd/client/v2 v2.305.1/go.mod h1:pMEacxZW7o8pg4CrFE7pquyCJJzZvkvdD2RibOCCCGs=
+go.mozilla.org/pkcs7 v0.0.0-20200128120323-432b2356ecb1/go.mod h1:SNgMg+EgDFwmvSmLRTNKC5fegJjB7v23qTQ0XLGUNHk=
+go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
+go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
+go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
+go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
+go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
+go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk=
+go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E=
+go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI=
+go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
+go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
+go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc=
+go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0=
+go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU=
+go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q=
+go.uber.org/zap v1.17.0/go.mod h1:MXVU+bhUf/A7Xi2HNOnopQOrmycQ5Ih87HtOu4q5SSo=
+golang.org/x/crypto v0.0.0-20171113213409-9f005a07e0d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
+golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
+golang.org/x/crypto v0.0.0-20181009213950-7c1a557ab941/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
+golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
+golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
+golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY=
+golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
+golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
+golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
+golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
+golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
+golang.org/x/crypto v0.0.0-20210817164053-32db794688a5/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
+golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
+golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
+golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek=
+golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY=
+golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
+golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
+golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
+golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM=
+golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
+golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
+golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
+golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
+golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
+golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
+golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
+golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
+golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
+golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
+golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRuDixDT3tpyyb+LUpUlRWLxfhWrs=
+golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
+golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
+golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
+golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
+golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE=
+golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o=
+golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc=
+golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
+golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
+golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
+golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
+golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
+golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
+golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
+golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
+golang.org/x/mod v0.5.0/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
+golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
+golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20181011144130-49bb7cea24b1/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
+golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
+golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
+golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
+golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
+golang.org/x/net v0.0.0-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
+golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
+golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20190619014844-b5b0513f8c1b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20191004110552-13f9640d40b9/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20200222125558-5a598a2470a0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20200301022130-244492dfa37a/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
+golang.org/x/net v0.0.0-20200501053045-e0ff5e5a1de5/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
+golang.org/x/net v0.0.0-20200506145744-7e3656a0809f/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
+golang.org/x/net v0.0.0-20200513185701-a91f0712d120/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
+golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
+golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
+golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
+golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
+golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
+golang.org/x/net v0.0.0-20201006153459-a7d1128ccaa0/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
+golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
+golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
+golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
+golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
+golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
+golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
+golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
+golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc=
+golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM=
+golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8=
+golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20210813160813-60bc85c4be6d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211209124913-491a49abca63/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211216030914-fe4d6282115f h1:hEYJvxw1lSnWIl8X9ofsYMklzaDs90JI2az5YMd4fPM=
+golang.org/x/net v0.0.0-20211216030914-fe4d6282115f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
+golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
+golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
+golang.org/x/oauth2 v0.0.0-20191202225959-858c2ad4c8b6/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
+golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
+golang.org/x/oauth2 v0.0.0-20200902213428-5d25da1a8d43/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20201109201403-9fd604954f58/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20210628180205-a41e5a781914/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20210805134026-6f1e6394065a/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20211005180243-6b3c2da341f1/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 h1:RerP+noqYHUQ8CMRcPlC2nvTa4dcBIjegkuWdcUDuqg=
+golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
+golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
+golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
+golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190514135907-3a4b5fb9f71f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190522044717-8097e1b27ff5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190602015325-4c4f7f33c9ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190606203320-7fc4e5ec1444/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190801041406-cbf593c0f2f3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190812073006-9eafafc0a87e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190922100055-0a153f010e69/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191022100944-742c48ecaeb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191115151921-52ab43148777/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191210023423-ac6580df4449/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200120151820-655fe14d7479/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200124204421-9fbb57f87de9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200217220822-9197077df867/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200302150141-5c8b2ff67527/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200622214017-ed371f2e16b4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200728102440-3e129f6d46b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200817155316-9781c653f443/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200831180312-196b9ba8737a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200909081042-eff7692f9009/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200916030750-2334cc1a136f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200922070232-aee5d888a860/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20201112073958-5cba982894dd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20201117170446-d9b008d0a637/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20201202213521-69691e467435/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210324051608-47abb6519492/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210426230700-d19ff857e887/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211205182925-97ca703d548d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e h1:fLOSk5Q00efkSvAm+4xcoXD+RRmLmmulPn5I3Y9F2EM=
+golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
+golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
+golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
+golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b h1:9zKuko04nR4gjZ4+DNjHqRlAJqbJETHwiNKDqTfOjfE=
+golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
+golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
+golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
+golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
+golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
+golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk=
+golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
+golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
+golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
+golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
+golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
+golang.org/x/time v0.0.0-20200630173020-3af7569d3a1e/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
+golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
+golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac h1:7zkz7BUtwNFFqcowJ+RIgu2MaV/MapERkDIy+mwPyjs=
+golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
+golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
+golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
+golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
+golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
+golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY=
+golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
+golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
+golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
+golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
+golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
+golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
+golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
+golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
+golang.org/x/tools v0.0.0-20190614205625-5aca471b1d59/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
+golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
+golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
+golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
+golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20190907020128-2ca718005c18/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20191125144606-a911d9008d1f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200227222343-706bc42d1f0d/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200304193943-95d2e580d8eb/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw=
+golang.org/x/tools v0.0.0-20200312045724-11d5b4c81c7d/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw=
+golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8=
+golang.org/x/tools v0.0.0-20200501065659-ab2804fb9c9d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
+golang.org/x/tools v0.0.0-20200505023115-26f46d2f7ef8/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
+golang.org/x/tools v0.0.0-20200512131952-2bc93b1c0c88/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
+golang.org/x/tools v0.0.0-20200515010526-7d3b6ebf133d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
+golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
+golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
+golang.org/x/tools v0.0.0-20200729194436-6467de6f59a7/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
+golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
+golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
+golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE=
+golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
+golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
+golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
+golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
+golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
+golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0=
+golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
+golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
+golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
+golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
+golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
+golang.org/x/tools v0.1.8/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
+golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE=
+golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+google.golang.org/api v0.0.0-20160322025152-9bf6e6e569ff/go.mod h1:4mhQ8q/RsB7i+udVvVy5NUi08OU8ZlA0gRVgrF7VFY0=
+google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE=
+google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M=
+google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg=
+google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg=
+google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
+google.golang.org/api v0.14.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
+google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
+google.golang.org/api v0.17.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
+google.golang.org/api v0.18.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
+google.golang.org/api v0.19.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
+google.golang.org/api v0.20.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
+google.golang.org/api v0.22.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
+google.golang.org/api v0.24.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE=
+google.golang.org/api v0.28.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE=
+google.golang.org/api v0.29.0/go.mod h1:Lcubydp8VUV7KeIHD9z2Bys/sm/vGKnG1UHuDBSrHWM=
+google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz5138Fc=
+google.golang.org/api v0.35.0/go.mod h1:/XrVsuzM0rZmrsbjJutiuftIzeuTQcEeaYcSk/mQ1dg=
+google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34qYtE=
+google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8=
+google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU=
+google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94=
+google.golang.org/api v0.47.0/go.mod h1:Wbvgpq1HddcWVtzsVLyfLp8lDg6AA241LmgIL59tHXo=
+google.golang.org/api v0.48.0/go.mod h1:71Pr1vy+TAZRPkPs/xlCf5SsU8WjuAWv1Pfjbtukyy4=
+google.golang.org/api v0.50.0/go.mod h1:4bNT5pAuq5ji4SRZm+5QIkjny9JAyVD/3gaSihNefaw=
+google.golang.org/api v0.51.0/go.mod h1:t4HdrdoNgyN5cbEfm7Lum0lcLDLiise1F8qDKX00sOU=
+google.golang.org/api v0.54.0/go.mod h1:7C4bFFOvVDGXjfDTAsgGwDgAxRDeQ4X8NvUedIt6z3k=
+google.golang.org/api v0.55.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE=
+google.golang.org/api v0.56.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE=
+google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdrMgI=
+google.golang.org/api v0.59.0/go.mod h1:sT2boj7M9YJxZzgeZqXogmhfmRWDtPzT31xkieUbuZU=
+google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I=
+google.golang.org/api v0.62.0/go.mod h1:dKmwPCydfsad4qCH08MSdgWjfHOyfpd4VtDGgRFdavw=
+google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
+google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
+google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
+google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0=
+google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
+google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
+google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c=
+google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
+google.golang.org/cloud v0.0.0-20151119220103-975617b05ea8/go.mod h1:0H1ncTHf11KCFhTc/+EFRbzSCOZx+VUbRMk55Yv5MYk=
+google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
+google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
+google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
+google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
+google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
+google.golang.org/genproto v0.0.0-20190522204451-c2c4e71fbf69/go.mod h1:z3L6/3dTEVtUr6QSP8miRzeRqwQOioJ9I66odjN4I7s=
+google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
+google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
+google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8=
+google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
+google.golang.org/genproto v0.0.0-20191115194625-c23dd37a84c9/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
+google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
+google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
+google.golang.org/genproto v0.0.0-20200115191322-ca5a22157cba/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
+google.golang.org/genproto v0.0.0-20200117163144-32f20d992d24/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
+google.golang.org/genproto v0.0.0-20200122232147-0452cf42e150/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
+google.golang.org/genproto v0.0.0-20200204135345-fa8e72b47b90/go.mod h1:GmwEX6Z4W5gMy59cAlVYjN9JhxgbQH6Gn+gFDQe2lzA=
+google.golang.org/genproto v0.0.0-20200212174721-66ed5ce911ce/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200224152610-e50cd9704f63/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
+google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U=
+google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo=
+google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA=
+google.golang.org/genproto v0.0.0-20200729003335-053ba62fc06f/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20200804131852-c06518451d9c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20201019141844-1ed22bb0c154/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20201109203340-2640f1f9cdfb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20201110150050-8816d57aaa9a/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210402141018-6c239bbf2bb1/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A=
+google.golang.org/genproto v0.0.0-20210513213006-bf773b8c8384/go.mod h1:P3QM42oQyzQSnHPnZ/vqoCdDmzH28fzWByN9asMeM8A=
+google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0=
+google.golang.org/genproto v0.0.0-20210604141403-392c879c8b08/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0=
+google.golang.org/genproto v0.0.0-20210608205507-b6d2f5bf0d7d/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0=
+google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24=
+google.golang.org/genproto v0.0.0-20210713002101-d411969a0d9a/go.mod h1:AxrInvYm1dci+enl5hChSFPOmmUF1+uAa/UsgNRWd7k=
+google.golang.org/genproto v0.0.0-20210716133855-ce7ef5c701ea/go.mod h1:AxrInvYm1dci+enl5hChSFPOmmUF1+uAa/UsgNRWd7k=
+google.golang.org/genproto v0.0.0-20210728212813-7823e685a01f/go.mod h1:ob2IJxKrgPT52GcgX759i1sleT07tiKowYBGbczaW48=
+google.golang.org/genproto v0.0.0-20210805201207-89edb61ffb67/go.mod h1:ob2IJxKrgPT52GcgX759i1sleT07tiKowYBGbczaW48=
+google.golang.org/genproto v0.0.0-20210813162853-db860fec028c/go.mod h1:cFeNkxwySK631ADgubI+/XFU/xp8FD5KIVV4rj8UC5w=
+google.golang.org/genproto v0.0.0-20210821163610-241b8fcbd6c8/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
+google.golang.org/genproto v0.0.0-20210828152312-66f60bf46e71/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
+google.golang.org/genproto v0.0.0-20210831024726-fe130286e0e2/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
+google.golang.org/genproto v0.0.0-20210903162649-d08c68adba83/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
+google.golang.org/genproto v0.0.0-20210909211513-a8c4777a87af/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY=
+google.golang.org/genproto v0.0.0-20210924002016-3dee208752a0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211008145708-270636b82663/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211028162531-8db9c33dc351/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211118181313-81c1377c94b1/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211129164237-f09f9a12af12/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211203200212-54befc351ae9/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211206160659-862468c7d6e0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc=
+google.golang.org/grpc v0.0.0-20160317175043-d3ddb4469d5a/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw=
+google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
+google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
+google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
+google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
+google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
+google.golang.org/grpc v1.23.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
+google.golang.org/grpc v1.24.0/go.mod h1:XDChyiUovWa60DnaeDeZmSW86xtLtjtZbwvSiRnRtcA=
+google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY=
+google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
+google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
+google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
+google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60=
+google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk=
+google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
+google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
+google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
+google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTpR3n0=
+google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc=
+google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8=
+google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU=
+google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU=
+google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU=
+google.golang.org/grpc v1.37.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM=
+google.golang.org/grpc v1.37.1/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM=
+google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM=
+google.golang.org/grpc v1.39.0/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE=
+google.golang.org/grpc v1.39.1/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE=
+google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34=
+google.golang.org/grpc v1.40.1/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34=
+google.golang.org/grpc v1.42.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU=
+google.golang.org/grpc v1.43.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU=
+google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw=
+google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
+google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0=
+google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM=
+google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE=
+google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo=
+google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
+google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
+google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
+google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGjtUeSXeh4=
+google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c=
+google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw=
+google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc=
+google.golang.org/protobuf v1.27.1 h1:SnqbnDw1V7RiZcXPx5MEeqPv2s79L9i7BJUlG/+RurQ=
+google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc=
+gopkg.in/airbrake/gobrake.v2 v2.0.9/go.mod h1:/h5ZAUhDkGaJfjzjKLSjv6zCL6O0LLBxU4K+aSYdM/U=
+gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/check.v1 v1.0.0-20141024133853-64131543e789/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
+gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
+gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw=
+gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
+gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
+gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2/go.mod h1:Xk6kEKp8OKb+X14hQBKWaSkCsqBpgog8nAV2xsGOxlo=
+gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc=
+gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
+gopkg.in/ini.v1 v1.66.2/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
+gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k=
+gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo=
+gopkg.in/square/go-jose.v2 v2.2.2/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
+gopkg.in/square/go-jose.v2 v2.3.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
+gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
+gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ=
+gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
+gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74=
+gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
+gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
+gopkg.in/yaml.v2 v2.2.3/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
+gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
+gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
+gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
+gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
+gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=
+gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
+gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
+gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
+gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo=
+gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
+gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo=
+gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw=
+gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk=
+gotest.tools/v3 v3.0.3 h1:4AuOwCGf4lLR9u3YOe2awrHygurzhO/HeQ6laiA6Sx0=
+gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8=
+honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
+honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
+honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
+honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
+honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
+honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
+honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
+k8s.io/api v0.20.1/go.mod h1:KqwcCVogGxQY3nBlRpwt+wpAMF/KjaCc7RpywacvqUo=
+k8s.io/api v0.20.4/go.mod h1:++lNL1AJMkDymriNniQsWRkMDzRaX2Y/POTUi8yvqYQ=
+k8s.io/api v0.20.6/go.mod h1:X9e8Qag6JV/bL5G6bU8sdVRltWKmdHsFUGS3eVndqE8=
+k8s.io/api v0.22.5 h1:xk7C+rMjF/EGELiD560jdmwzrB788mfcHiNbMQLIVI8=
+k8s.io/api v0.22.5/go.mod h1:mEhXyLaSD1qTOf40rRiKXkc+2iCem09rWLlFwhCEiAs=
+k8s.io/apimachinery v0.20.1/go.mod h1:WlLqWAHZGg07AeltaI0MV5uk1Omp8xaN0JGLY6gkRpU=
+k8s.io/apimachinery v0.20.4/go.mod h1:WlLqWAHZGg07AeltaI0MV5uk1Omp8xaN0JGLY6gkRpU=
+k8s.io/apimachinery v0.20.6/go.mod h1:ejZXtW1Ra6V1O5H8xPBGz+T3+4gfkTCeExAHKU57MAc=
+k8s.io/apimachinery v0.22.5 h1:cIPwldOYm1Slq9VLBRPtEYpyhjIm1C6aAMAoENuvN9s=
+k8s.io/apimachinery v0.22.5/go.mod h1:xziclGKwuuJ2RM5/rSFQSYAj0zdbci3DH8kj+WvyN0U=
+k8s.io/apiserver v0.20.1/go.mod h1:ro5QHeQkgMS7ZGpvf4tSMx6bBOgPfE+f52KwvXfScaU=
+k8s.io/apiserver v0.20.4/go.mod h1:Mc80thBKOyy7tbvFtB4kJv1kbdD0eIH8k8vianJcbFM=
+k8s.io/apiserver v0.20.6/go.mod h1:QIJXNt6i6JB+0YQRNcS0hdRHJlMhflFmsBDeSgT1r8Q=
+k8s.io/client-go v0.20.1/go.mod h1:/zcHdt1TeWSd5HoUe6elJmHSQ6uLLgp4bIJHVEuy+/Y=
+k8s.io/client-go v0.20.4/go.mod h1:LiMv25ND1gLUdBeYxBIwKpkSC5IsozMMmOOeSJboP+k=
+k8s.io/client-go v0.20.6/go.mod h1:nNQMnOvEUEsOzRRFIIkdmYOjAZrC8bgq0ExboWSU1I0=
+k8s.io/client-go v0.22.5 h1:I8Zn/UqIdi2r02aZmhaJ1hqMxcpfJ3t5VqvHtctHYFo=
+k8s.io/client-go v0.22.5/go.mod h1:cs6yf/61q2T1SdQL5Rdcjg9J1ElXSwbjSrW2vFImM4Y=
+k8s.io/component-base v0.20.1/go.mod h1:guxkoJnNoh8LNrbtiQOlyp2Y2XFCZQmrcg2n/DeYNLk=
+k8s.io/component-base v0.20.4/go.mod h1:t4p9EdiagbVCJKrQ1RsA5/V4rFQNDfRlevJajlGwgjI=
+k8s.io/component-base v0.20.6/go.mod h1:6f1MPBAeI+mvuts3sIdtpjljHWBQ2cIy38oBIWMYnrM=
+k8s.io/cri-api v0.17.3/go.mod h1:X1sbHmuXhwaHs9xxYffLqJogVsnI+f6cPRcgPel7ywM=
+k8s.io/cri-api v0.20.1/go.mod h1:2JRbKt+BFLTjtrILYVqQK5jqhI+XNdF6UiGMgczeBCI=
+k8s.io/cri-api v0.20.4/go.mod h1:2JRbKt+BFLTjtrILYVqQK5jqhI+XNdF6UiGMgczeBCI=
+k8s.io/cri-api v0.20.6/go.mod h1:ew44AjNXwyn1s0U4xCKGodU7J1HzBeZ1MpGrpa5r8Yc=
+k8s.io/gengo v0.0.0-20200413195148-3a45101e95ac/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0=
+k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
+k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE=
+k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
+k8s.io/klog/v2 v2.4.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
+k8s.io/klog/v2 v2.9.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
+k8s.io/klog/v2 v2.30.0 h1:bUO6drIvCIsvZ/XFgfxoGFQU/a4Qkh0iAlvUR7vlHJw=
+k8s.io/klog/v2 v2.30.0/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
+k8s.io/kube-openapi v0.0.0-20201113171705-d219536bb9fd/go.mod h1:WOJ3KddDSol4tAGcJo0Tvi+dK12EcqSLqcWsryKMpfM=
+k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c/go.mod h1:vHXdDvt9+2spS2Rx9ql3I8tycm3H9FDfdUoIuKCefvw=
+k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65 h1:E3J9oCLlaobFUqsjG9DfKbP2BmgwBL2p7pn0A3dG9W4=
+k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65/go.mod h1:sX9MT8g7NVZM5lVL/j8QyCCJe8YSMW30QvGZWaCIDIk=
+k8s.io/kubernetes v1.13.0/go.mod h1:ocZa8+6APFNC2tX1DZASIbocyYT5jHzqFVsY5aoB7Jk=
+k8s.io/utils v0.0.0-20201110183641-67b214c5f920/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
+k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
+k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
+k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b h1:wxEMGetGMur3J1xuGLQY7GEQYg9bZxKn3tKo5k/eYcs=
+k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
+rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
+rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0=
+rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA=
+sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.14/go.mod h1:LEScyzhFmoF5pso/YSeBstl57mOzx9xlU9n85RGrDQg=
+sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.15/go.mod h1:LEScyzhFmoF5pso/YSeBstl57mOzx9xlU9n85RGrDQg=
+sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
+sigs.k8s.io/structured-merge-diff/v4 v4.0.3/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
+sigs.k8s.io/structured-merge-diff/v4 v4.1.2 h1:Hr/htKFmJEbtMgS/UD0N+gtgctAqz81t3nu+sPzynno=
+sigs.k8s.io/structured-merge-diff/v4 v4.1.2/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4=
+sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o=
+sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=
+sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/keychain.go b/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/keychain.go
new file mode 100644
index 000000000000..a51e6cf22ea1
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/kubernetes/keychain.go
@@ -0,0 +1,172 @@
+// Copyright 2022 Google LLC All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package kubernetes
+
+import (
+ "context"
+ "encoding/base64"
+ "encoding/json"
+ "fmt"
+ "strings"
+
+ "github.com/google/go-containerregistry/pkg/authn"
+ "github.com/google/go-containerregistry/pkg/name"
+ corev1 "k8s.io/api/core/v1"
+ metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
+ "k8s.io/client-go/kubernetes"
+ "k8s.io/client-go/rest"
+)
+
+// Options holds configuration data for guiding credential resolution.
+type Options struct {
+ // Namespace holds the namespace inside of which we are resolving the
+ // image reference. If empty, "default" is assumed.
+ Namespace string
+ // ServiceAccountName holds the serviceaccount as which the container
+ // will run (scoped to Namespace). If empty, "default" is assumed.
+ ServiceAccountName string
+ // ImagePullSecrets holds the names of the Kubernetes secrets (scoped to
+ // Namespace) containing credential data to use for the image pull.
+ ImagePullSecrets []string
+}
+
+// New returns a new authn.Keychain suitable for resolving image references as
+// scoped by the provided Options. It speaks to Kubernetes through the provided
+// client interface.
+func New(ctx context.Context, client kubernetes.Interface, opt Options) (authn.Keychain, error) {
+ if opt.Namespace == "" {
+ opt.Namespace = "default"
+ }
+ if opt.ServiceAccountName == "" {
+ opt.ServiceAccountName = "default"
+ }
+
+ // Implement a Kubernetes-style authentication keychain.
+ // This needs to support roughly the following kinds of authentication:
+ // 1) The explicit authentication from imagePullSecrets on Pod
+ // 2) The semi-implicit authentication where imagePullSecrets are on the
+ // Pod's service account.
+
+ // First, fetch all of the explicitly declared pull secrets
+ var pullSecrets []corev1.Secret
+ for _, name := range opt.ImagePullSecrets {
+ ps, err := client.CoreV1().Secrets(opt.Namespace).Get(ctx, name, metav1.GetOptions{})
+ if err != nil {
+ return nil, err
+ }
+ pullSecrets = append(pullSecrets, *ps)
+ }
+
+ // Second, fetch all of the pull secrets attached to our service account.
+ sa, err := client.CoreV1().ServiceAccounts(opt.Namespace).Get(ctx, opt.ServiceAccountName, metav1.GetOptions{})
+ if err != nil {
+ return nil, err
+ }
+ for _, localObj := range sa.ImagePullSecrets {
+ ps, err := client.CoreV1().Secrets(opt.Namespace).Get(ctx, localObj.Name, metav1.GetOptions{})
+ if err != nil {
+ return nil, err
+ }
+ pullSecrets = append(pullSecrets, *ps)
+ }
+
+ return NewFromPullSecrets(ctx, pullSecrets)
+}
+
+// NewInCluster returns a new authn.Keychain suitable for resolving image references as
+// scoped by the provided Options, constructing a kubernetes.Interface based on in-cluster
+// authentication.
+func NewInCluster(ctx context.Context, opt Options) (authn.Keychain, error) {
+ clusterConfig, err := rest.InClusterConfig()
+ if err != nil {
+ return nil, err
+ }
+
+ client, err := kubernetes.NewForConfig(clusterConfig)
+ if err != nil {
+ return nil, err
+ }
+ return New(ctx, client, opt)
+}
+
+// NewFromPullSecrets returns a new authn.Keychain suitable for resolving image references as
+// scoped by the pull secrets.
+func NewFromPullSecrets(ctx context.Context, secrets []corev1.Secret) (authn.Keychain, error) {
+ m := map[string]authn.AuthConfig{}
+ for _, secret := range secrets {
+ auths := map[string]authn.AuthConfig{}
+ if b, exists := secret.Data[corev1.DockerConfigJsonKey]; secret.Type == corev1.SecretTypeDockerConfigJson && exists && len(b) > 0 {
+ var cfg struct {
+ Auths map[string]authn.AuthConfig
+ }
+ if err := json.Unmarshal(b, &cfg); err != nil {
+ return nil, err
+ }
+ auths = cfg.Auths
+ }
+ if b, exists := secret.Data[corev1.DockerConfigKey]; secret.Type == corev1.SecretTypeDockercfg && exists && len(b) > 0 {
+ if err := json.Unmarshal(b, &auths); err != nil {
+ return nil, err
+ }
+ }
+
+ for k, v := range auths {
+ // Don't overwrite previously specified Auths for a
+ // given key.
+ if _, found := m[k]; !found {
+ m[k] = v
+ }
+ }
+ }
+ return authsKeychain(m), nil
+}
+
+type authsKeychain map[string]authn.AuthConfig
+
+func (kc authsKeychain) Resolve(target authn.Resource) (authn.Authenticator, error) {
+ // Check for an auth that matches the repository, then if that's not
+ // found, one that matches the registry.
+ var cfg authn.AuthConfig
+ for _, key := range []string{target.String(), target.RegistryStr()} {
+ if key == name.DefaultRegistry {
+ key = authn.DefaultAuthKey
+ }
+ var ok bool
+ cfg, ok = kc[key]
+ if ok {
+ break
+ }
+ }
+ empty := authn.AuthConfig{}
+ if cfg == empty {
+ return authn.Anonymous, nil
+ }
+
+ if cfg.Auth != "" {
+ dec, err := base64.StdEncoding.DecodeString(cfg.Auth)
+ if err != nil {
+ return nil, err
+ }
+ parts := strings.SplitN(string(dec), ":", 2)
+ if len(parts) != 2 {
+ return nil, fmt.Errorf("unable to parse auth field, must be formatted as base64(username:password)")
+ }
+ cfg.Username = parts[0]
+ cfg.Password = parts[1]
+ cfg.Auth = ""
+ }
+
+ return authn.FromConfig(authn.AuthConfig(cfg)), nil
+}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/name/check.go b/vendor/github.com/google/go-containerregistry/pkg/name/check.go
index c15cc03b3c61..e9a240a3e5ab 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/name/check.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/name/check.go
@@ -35,9 +35,9 @@ func stripRunesFn(runes string) func(rune) rune {
func checkElement(name, element, allowedRunes string, minRunes, maxRunes int) error {
numRunes := utf8.RuneCountInString(element)
if (numRunes < minRunes) || (maxRunes < numRunes) {
- return newErrBadName("%s must be between %d and %d runes in length: %s", name, minRunes, maxRunes, element)
+ return newErrBadName("%s must be between %d and %d characters in length: %s", name, minRunes, maxRunes, element)
} else if len(strings.Map(stripRunesFn(allowedRunes), element)) != 0 {
- return newErrBadName("%s can only contain the runes `%s`: %s", name, allowedRunes, element)
+ return newErrBadName("%s can only contain the characters `%s`: %s", name, allowedRunes, element)
}
return nil
}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/google/README.md b/vendor/github.com/google/go-containerregistry/pkg/v1/google/README.md
new file mode 100644
index 000000000000..7cd8971fe573
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/google/README.md
@@ -0,0 +1,7 @@
+# `google`
+
+[](https://godoc.org/github.com/google/go-containerregistry/pkg/v1/google)
+
+The `google` package provides:
+* Some google-specific authentication methods.
+* Some [GCR](gcr.io)-specific listing methods.
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/google/auth.go b/vendor/github.com/google/go-containerregistry/pkg/v1/google/auth.go
new file mode 100644
index 000000000000..4ce979577bfb
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/google/auth.go
@@ -0,0 +1,180 @@
+// Copyright 2018 Google LLC All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package google
+
+import (
+ "bytes"
+ "context"
+ "encoding/json"
+ "fmt"
+ "os"
+ "os/exec"
+ "time"
+
+ "github.com/google/go-containerregistry/pkg/authn"
+ "github.com/google/go-containerregistry/pkg/logs"
+ "golang.org/x/oauth2"
+ googauth "golang.org/x/oauth2/google"
+)
+
+const cloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
+
+// GetGcloudCmd is exposed so we can test this.
+var GetGcloudCmd = func() *exec.Cmd {
+ // This is odd, but basically what docker-credential-gcr does.
+ //
+ // config-helper is undocumented, but it's purportedly the only supported way
+ // of accessing tokens (`gcloud auth print-access-token` is discouraged).
+ //
+ // --force-auth-refresh means we are getting a token that is valid for about
+ // an hour (we reuse it until it's expired).
+ return exec.Command("gcloud", "config", "config-helper", "--force-auth-refresh", "--format=json(credential)")
+}
+
+// NewEnvAuthenticator returns an authn.Authenticator that generates access
+// tokens from the environment we're running in.
+//
+// See: https://godoc.org/golang.org/x/oauth2/google#FindDefaultCredentials
+func NewEnvAuthenticator() (authn.Authenticator, error) {
+ ts, err := googauth.DefaultTokenSource(context.Background(), cloudPlatformScope)
+ if err != nil {
+ return nil, err
+ }
+
+ token, err := ts.Token()
+ if err != nil {
+ return nil, err
+ }
+
+ return &tokenSourceAuth{oauth2.ReuseTokenSource(token, ts)}, nil
+}
+
+// NewGcloudAuthenticator returns an oauth2.TokenSource that generates access
+// tokens by shelling out to the gcloud sdk.
+func NewGcloudAuthenticator() (authn.Authenticator, error) {
+ if _, err := exec.LookPath("gcloud"); err != nil {
+ // gcloud is not available, fall back to anonymous
+ logs.Warn.Println("gcloud binary not found")
+ return authn.Anonymous, nil
+ }
+
+ ts := gcloudSource{GetGcloudCmd}
+
+ // Attempt to fetch a token to ensure gcloud is installed and we can run it.
+ token, err := ts.Token()
+ if err != nil {
+ return nil, err
+ }
+
+ return &tokenSourceAuth{oauth2.ReuseTokenSource(token, ts)}, nil
+}
+
+// NewJSONKeyAuthenticator returns a Basic authenticator which uses Service Account
+// as a way of authenticating with Google Container Registry.
+// More information: https://cloud.google.com/container-registry/docs/advanced-authentication#json_key_file
+func NewJSONKeyAuthenticator(serviceAccountJSON string) authn.Authenticator {
+ return &authn.Basic{
+ Username: "_json_key",
+ Password: serviceAccountJSON,
+ }
+}
+
+// NewTokenAuthenticator returns an oauth2.TokenSource that generates access
+// tokens by using the Google SDK to produce JWT tokens from a Service Account.
+// More information: https://godoc.org/golang.org/x/oauth2/google#JWTAccessTokenSourceFromJSON
+func NewTokenAuthenticator(serviceAccountJSON string, scope string) (authn.Authenticator, error) {
+ ts, err := googauth.JWTAccessTokenSourceFromJSON([]byte(serviceAccountJSON), scope)
+ if err != nil {
+ return nil, err
+ }
+
+ return &tokenSourceAuth{oauth2.ReuseTokenSource(nil, ts)}, nil
+}
+
+// NewTokenSourceAuthenticator converts an oauth2.TokenSource into an authn.Authenticator.
+func NewTokenSourceAuthenticator(ts oauth2.TokenSource) authn.Authenticator {
+ return &tokenSourceAuth{ts}
+}
+
+// tokenSourceAuth turns an oauth2.TokenSource into an authn.Authenticator.
+type tokenSourceAuth struct {
+ oauth2.TokenSource
+}
+
+// Authorization implements authn.Authenticator.
+func (tsa *tokenSourceAuth) Authorization() (*authn.AuthConfig, error) {
+ token, err := tsa.Token()
+ if err != nil {
+ return nil, err
+ }
+
+ return &authn.AuthConfig{
+ Username: "_token",
+ Password: token.AccessToken,
+ }, nil
+}
+
+// gcloudOutput represents the output of the gcloud command we invoke.
+//
+// `gcloud config config-helper --format=json(credential)` looks something like:
+//
+// {
+// "credential": {
+// "access_token": "ya29.abunchofnonsense",
+// "token_expiry": "2018-12-02T04:08:13Z"
+// }
+// }
+type gcloudOutput struct {
+ Credential struct {
+ AccessToken string `json:"access_token"`
+ TokenExpiry string `json:"token_expiry"`
+ } `json:"credential"`
+}
+
+type gcloudSource struct {
+ // This is passed in so that we mock out gcloud and test Token.
+ exec func() *exec.Cmd
+}
+
+// Token implements oauath2.TokenSource.
+func (gs gcloudSource) Token() (*oauth2.Token, error) {
+ cmd := gs.exec()
+ var out bytes.Buffer
+ cmd.Stdout = &out
+
+ // Don't attempt to interpret stderr, just pass it through.
+ cmd.Stderr = os.Stderr
+
+ if err := cmd.Run(); err != nil {
+ return nil, fmt.Errorf("error executing `gcloud config config-helper`: %w", err)
+ }
+
+ creds := gcloudOutput{}
+ if err := json.Unmarshal(out.Bytes(), &creds); err != nil {
+ return nil, fmt.Errorf("failed to parse `gcloud config config-helper` output: %w", err)
+ }
+
+ expiry, err := time.Parse(time.RFC3339, creds.Credential.TokenExpiry)
+ if err != nil {
+ return nil, fmt.Errorf("failed to parse gcloud token expiry: %w", err)
+ }
+
+ token := oauth2.Token{
+ AccessToken: creds.Credential.AccessToken,
+ Expiry: expiry,
+ }
+
+ return &token, nil
+}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_aws.go b/vendor/github.com/google/go-containerregistry/pkg/v1/google/doc.go
similarity index 72%
rename from vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_aws.go
rename to vendor/github.com/google/go-containerregistry/pkg/v1/google/doc.go
index 9c342b824881..b6a67df049f7 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/k8schain_aws.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/google/doc.go
@@ -1,7 +1,4 @@
-//go:build !disable_aws
-// +build !disable_aws
-
-// Copyright 2019 Google LLC All Rights Reserved.
+// Copyright 2018 Google LLC All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -15,9 +12,5 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-package k8schain
-
-import (
- // aws credential provider
- _ "github.com/vdemeester/k8s-pkg-credentialprovider/aws"
-)
+// Package google provides facilities for listing images in gcr.io.
+package google
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/google/keychain.go b/vendor/github.com/google/go-containerregistry/pkg/v1/google/keychain.go
new file mode 100644
index 000000000000..7471a01734af
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/google/keychain.go
@@ -0,0 +1,81 @@
+// Copyright 2018 Google LLC All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package google
+
+import (
+ "fmt"
+ "strings"
+ "sync"
+
+ "github.com/google/go-containerregistry/pkg/authn"
+)
+
+// Keychain exports an instance of the google Keychain.
+var Keychain authn.Keychain = &googleKeychain{}
+
+type googleKeychain struct {
+ once sync.Once
+ auth authn.Authenticator
+ err error
+}
+
+// Resolve implements authn.Keychain a la docker-credential-gcr.
+//
+// This behaves similarly to the GCR credential helper, but reuses tokens until
+// they expire.
+//
+// We can't easily add this behavior to our credential helper implementation
+// of authn.Authenticator because the credential helper protocol doesn't include
+// expiration information, see here:
+// https://godoc.org/github.com/docker/docker-credential-helpers/credentials#Credentials
+//
+// In addition to being a performance optimization, the reuse of these access
+// tokens works around a bug in gcloud. It appears that attempting to invoke
+// `gcloud config config-helper` multiple times too quickly will fail:
+// https://github.com/GoogleCloudPlatform/docker-credential-gcr/issues/54
+//
+// We could upstream this behavior into docker-credential-gcr by parsing
+// gcloud's output and persisting its tokens across invocations, but then
+// we have to deal with invalidating caches across multiple runs (no fun).
+//
+// In general, we don't worry about that here because we expect to use the same
+// gcloud configuration in the scope of this one process.
+func (gk *googleKeychain) Resolve(target authn.Resource) (authn.Authenticator, error) {
+ // Only authenticate GCR and AR so it works with authn.NewMultiKeychain to fallback.
+ host := target.RegistryStr()
+ if host != "gcr.io" && !strings.HasSuffix(host, ".gcr.io") && !strings.HasSuffix(host, ".pkg.dev") && !strings.HasSuffix(host, ".google.com") {
+ return authn.Anonymous, nil
+ }
+
+ gk.once.Do(func() {
+ gk.auth, gk.err = resolve()
+ })
+
+ return gk.auth, gk.err
+}
+
+func resolve() (authn.Authenticator, error) {
+ auth, envErr := NewEnvAuthenticator()
+ if envErr == nil {
+ return auth, nil
+ }
+
+ auth, gErr := NewGcloudAuthenticator()
+ if gErr == nil {
+ return auth, nil
+ }
+
+ return nil, fmt.Errorf("failed to create token source from env: %v or gcloud: %v", envErr, gErr) //nolint: errorlint
+}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/google/list.go b/vendor/github.com/google/go-containerregistry/pkg/v1/google/list.go
new file mode 100644
index 000000000000..a70bb27ee55d
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/google/list.go
@@ -0,0 +1,331 @@
+// Copyright 2018 Google LLC All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package google
+
+import (
+ "context"
+ "encoding/json"
+ "fmt"
+ "net/http"
+ "net/url"
+ "strconv"
+ "strings"
+ "time"
+
+ "github.com/google/go-containerregistry/pkg/authn"
+ "github.com/google/go-containerregistry/pkg/logs"
+ "github.com/google/go-containerregistry/pkg/name"
+ "github.com/google/go-containerregistry/pkg/v1/remote/transport"
+)
+
+// Option is a functional option for List and Walk.
+// TODO: Can we somehow reuse the remote options here?
+type Option func(*lister) error
+
+type lister struct {
+ auth authn.Authenticator
+ transport http.RoundTripper
+ repo name.Repository
+ client *http.Client
+ ctx context.Context
+ userAgent string
+}
+
+func newLister(repo name.Repository, options ...Option) (*lister, error) {
+ l := &lister{
+ auth: authn.Anonymous,
+ transport: http.DefaultTransport,
+ repo: repo,
+ ctx: context.Background(),
+ }
+
+ for _, option := range options {
+ if err := option(l); err != nil {
+ return nil, err
+ }
+ }
+
+ // transport.Wrapper is a signal that consumers are opt-ing into providing their own transport without any additional wrapping.
+ // This is to allow consumers full control over the transports logic, such as providing retry logic.
+ if _, ok := l.transport.(*transport.Wrapper); !ok {
+ // Wrap the transport in something that logs requests and responses.
+ // It's expensive to generate the dumps, so skip it if we're writing
+ // to nothing.
+ if logs.Enabled(logs.Debug) {
+ l.transport = transport.NewLogger(l.transport)
+ }
+
+ // Wrap the transport in something that can retry network flakes.
+ l.transport = transport.NewRetry(l.transport)
+
+ // Wrap this last to prevent transport.New from double-wrapping.
+ if l.userAgent != "" {
+ l.transport = transport.NewUserAgent(l.transport, l.userAgent)
+ }
+ }
+
+ scopes := []string{repo.Scope(transport.PullScope)}
+ tr, err := transport.NewWithContext(l.ctx, repo.Registry, l.auth, l.transport, scopes)
+ if err != nil {
+ return nil, err
+ }
+
+ l.client = &http.Client{Transport: tr}
+
+ return l, nil
+}
+
+func (l *lister) list(repo name.Repository) (*Tags, error) {
+ uri := &url.URL{
+ Scheme: repo.Registry.Scheme(),
+ Host: repo.Registry.RegistryStr(),
+ Path: fmt.Sprintf("/v2/%s/tags/list", repo.RepositoryStr()),
+ // ECR returns an error if n > 1000:
+ // https://github.com/google/go-containerregistry/issues/681
+ RawQuery: "n=1000",
+ }
+
+ tags := Tags{}
+
+ // get responses until there is no next page
+ for {
+ select {
+ case <-l.ctx.Done():
+ return nil, l.ctx.Err()
+ default:
+ }
+
+ req, err := http.NewRequest("GET", uri.String(), nil)
+ if err != nil {
+ return nil, err
+ }
+ req = req.WithContext(l.ctx)
+
+ resp, err := l.client.Do(req)
+ if err != nil {
+ return nil, err
+ }
+
+ if err := transport.CheckError(resp, http.StatusOK); err != nil {
+ return nil, err
+ }
+
+ parsed := Tags{}
+ if err := json.NewDecoder(resp.Body).Decode(&parsed); err != nil {
+ return nil, err
+ }
+
+ if err := resp.Body.Close(); err != nil {
+ return nil, err
+ }
+
+ if len(parsed.Manifests) != 0 || len(parsed.Children) != 0 {
+ // We're dealing with GCR, just return directly.
+ return &parsed, nil
+ }
+
+ // This isn't GCR, just append the tags and keep paginating.
+ tags.Tags = append(tags.Tags, parsed.Tags...)
+
+ uri, err = getNextPageURL(resp)
+ if err != nil {
+ return nil, err
+ }
+ // no next page
+ if uri == nil {
+ break
+ }
+ logs.Warn.Printf("saw non-google tag listing response, falling back to pagination")
+ }
+
+ return &tags, nil
+}
+
+// getNextPageURL checks if there is a Link header in a http.Response which
+// contains a link to the next page. If yes it returns the url.URL of the next
+// page otherwise it returns nil.
+func getNextPageURL(resp *http.Response) (*url.URL, error) {
+ link := resp.Header.Get("Link")
+ if link == "" {
+ return nil, nil
+ }
+
+ if link[0] != '<' {
+ return nil, fmt.Errorf("failed to parse link header: missing '<' in: %s", link)
+ }
+
+ end := strings.Index(link, ">")
+ if end == -1 {
+ return nil, fmt.Errorf("failed to parse link header: missing '>' in: %s", link)
+ }
+ link = link[1:end]
+
+ linkURL, err := url.Parse(link)
+ if err != nil {
+ return nil, err
+ }
+ if resp.Request == nil || resp.Request.URL == nil {
+ return nil, nil
+ }
+ linkURL = resp.Request.URL.ResolveReference(linkURL)
+ return linkURL, nil
+}
+
+type rawManifestInfo struct {
+ Size string `json:"imageSizeBytes"`
+ MediaType string `json:"mediaType"`
+ Created string `json:"timeCreatedMs"`
+ Uploaded string `json:"timeUploadedMs"`
+ Tags []string `json:"tag"`
+}
+
+// ManifestInfo is a Manifests entry is the output of List and Walk.
+type ManifestInfo struct {
+ Size uint64 `json:"imageSizeBytes"`
+ MediaType string `json:"mediaType"`
+ Created time.Time `json:"timeCreatedMs"`
+ Uploaded time.Time `json:"timeUploadedMs"`
+ Tags []string `json:"tag"`
+}
+
+func fromUnixMs(ms int64) time.Time {
+ sec := ms / 1000
+ ns := (ms % 1000) * 1000000
+ return time.Unix(sec, ns)
+}
+
+func toUnixMs(t time.Time) string {
+ return strconv.FormatInt(t.UnixNano()/1000000, 10)
+}
+
+// MarshalJSON implements json.Marshaler
+func (m ManifestInfo) MarshalJSON() ([]byte, error) {
+ return json.Marshal(rawManifestInfo{
+ Size: strconv.FormatUint(m.Size, 10),
+ MediaType: m.MediaType,
+ Created: toUnixMs(m.Created),
+ Uploaded: toUnixMs(m.Uploaded),
+ Tags: m.Tags,
+ })
+}
+
+// UnmarshalJSON implements json.Unmarshaler
+func (m *ManifestInfo) UnmarshalJSON(data []byte) error {
+ raw := rawManifestInfo{}
+ if err := json.Unmarshal(data, &raw); err != nil {
+ return err
+ }
+
+ if raw.Size != "" {
+ size, err := strconv.ParseUint(raw.Size, 10, 64)
+ if err != nil {
+ return err
+ }
+ m.Size = size
+ }
+
+ if raw.Created != "" {
+ created, err := strconv.ParseInt(raw.Created, 10, 64)
+ if err != nil {
+ return err
+ }
+ m.Created = fromUnixMs(created)
+ }
+
+ if raw.Uploaded != "" {
+ uploaded, err := strconv.ParseInt(raw.Uploaded, 10, 64)
+ if err != nil {
+ return err
+ }
+ m.Uploaded = fromUnixMs(uploaded)
+ }
+
+ m.MediaType = raw.MediaType
+ m.Tags = raw.Tags
+
+ return nil
+}
+
+// Tags is the result of List and Walk.
+type Tags struct {
+ Children []string `json:"child"`
+ Manifests map[string]ManifestInfo `json:"manifest"`
+ Name string `json:"name"`
+ Tags []string `json:"tags"`
+}
+
+// List calls /tags/list for the given repository.
+func List(repo name.Repository, options ...Option) (*Tags, error) {
+ l, err := newLister(repo, options...)
+ if err != nil {
+ return nil, err
+ }
+
+ return l.list(repo)
+}
+
+// WalkFunc is the type of the function called for each repository visited by
+// Walk. This implements a similar API to filepath.Walk.
+//
+// The repo argument contains the argument to Walk as a prefix; that is, if Walk
+// is called with "gcr.io/foo", which is a repository containing the repository
+// "bar", the walk function will be called with argument "gcr.io/foo/bar".
+// The tags and error arguments are the result of calling List on repo.
+//
+// TODO: Do we want a SkipDir error, as in filepath.WalkFunc?
+type WalkFunc func(repo name.Repository, tags *Tags, err error) error
+
+func walk(repo name.Repository, tags *Tags, walkFn WalkFunc, options ...Option) error {
+ if tags == nil {
+ // This shouldn't happen.
+ return fmt.Errorf("tags nil for %q", repo)
+ }
+
+ if err := walkFn(repo, tags, nil); err != nil {
+ return err
+ }
+
+ for _, path := range tags.Children {
+ child, err := name.NewRepository(fmt.Sprintf("%s/%s", repo, path), name.StrictValidation)
+ if err != nil {
+ // We don't expect this ever, so don't pass it through to walkFn.
+ return fmt.Errorf("unexpected path failure: %w", err)
+ }
+
+ childTags, err := List(child, options...)
+ if err != nil {
+ if err := walkFn(child, nil, err); err != nil {
+ return err
+ }
+ } else {
+ if err := walk(child, childTags, walkFn, options...); err != nil {
+ return err
+ }
+ }
+ }
+
+ // We made it!
+ return nil
+}
+
+// Walk recursively descends repositories, calling walkFn.
+func Walk(root name.Repository, walkFn WalkFunc, options ...Option) error {
+ tags, err := List(root, options...)
+ if err != nil {
+ return walkFn(root, nil, err)
+ }
+
+ return walk(root, tags, walkFn, options...)
+}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/google/options.go b/vendor/github.com/google/go-containerregistry/pkg/v1/google/options.go
new file mode 100644
index 000000000000..604808cea6e1
--- /dev/null
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/google/options.go
@@ -0,0 +1,73 @@
+// Copyright 2018 Google LLC All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package google
+
+import (
+ "context"
+ "net/http"
+
+ "github.com/google/go-containerregistry/pkg/authn"
+)
+
+// WithTransport is a functional option for overriding the default transport
+// on a remote image
+func WithTransport(t http.RoundTripper) Option {
+ return func(l *lister) error {
+ l.transport = t
+ return nil
+ }
+}
+
+// WithAuth is a functional option for overriding the default authenticator
+// on a remote image
+func WithAuth(auth authn.Authenticator) Option {
+ return func(l *lister) error {
+ l.auth = auth
+ return nil
+ }
+}
+
+// WithAuthFromKeychain is a functional option for overriding the default
+// authenticator on a remote image using an authn.Keychain
+func WithAuthFromKeychain(keys authn.Keychain) Option {
+ return func(l *lister) error {
+ auth, err := keys.Resolve(l.repo.Registry)
+ if err != nil {
+ return err
+ }
+ l.auth = auth
+ return nil
+ }
+}
+
+// WithContext is a functional option for overriding the default
+// context.Context for HTTP request to list remote images
+func WithContext(ctx context.Context) Option {
+ return func(l *lister) error {
+ l.ctx = ctx
+ return nil
+ }
+}
+
+// WithUserAgent adds the given string to the User-Agent header for any HTTP
+// requests. This header will also include "go-containerregistry/${version}".
+//
+// If you want to completely overwrite the User-Agent header, use WithTransport.
+func WithUserAgent(ua string) Option {
+ return func(l *lister) error {
+ l.userAgent = ua
+ return nil
+ }
+}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/mutate/image.go b/vendor/github.com/google/go-containerregistry/pkg/v1/mutate/image.go
index 834cee15fb10..93c230e3b2e5 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/v1/mutate/image.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/mutate/image.go
@@ -18,7 +18,6 @@ import (
"bytes"
"encoding/json"
"errors"
- "strings"
v1 "github.com/google/go-containerregistry/pkg/v1"
"github.com/google/go-containerregistry/pkg/v1/partial"
@@ -141,14 +140,8 @@ func (i *image) compute() error {
manifest.Config.MediaType = *i.configMediaType
}
- // With OCI media types, this should not be set, see discussion:
- // https://github.com/opencontainers/image-spec/pull/795
if i.mediaType != nil {
- if strings.Contains(string(*i.mediaType), types.OCIVendorPrefix) {
- manifest.MediaType = ""
- } else if strings.Contains(string(*i.mediaType), types.DockerVendorPrefix) {
- manifest.MediaType = *i.mediaType
- }
+ manifest.MediaType = *i.mediaType
}
if i.annotations != nil {
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/mutate/index.go b/vendor/github.com/google/go-containerregistry/pkg/v1/mutate/index.go
index d9694b29e438..841995f15831 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/v1/mutate/index.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/mutate/index.go
@@ -17,7 +17,6 @@ package mutate
import (
"encoding/json"
"fmt"
- "strings"
"github.com/google/go-containerregistry/pkg/logs"
v1 "github.com/google/go-containerregistry/pkg/v1"
@@ -131,14 +130,8 @@ func (i *index) compute() error {
manifest.Manifests = manifests
- // With OCI media types, this should not be set, see discussion:
- // https://github.com/opencontainers/image-spec/pull/795
if i.mediaType != nil {
- if strings.Contains(string(*i.mediaType), types.OCIVendorPrefix) {
- manifest.MediaType = ""
- } else if strings.Contains(string(*i.mediaType), types.DockerVendorPrefix) {
- manifest.MediaType = *i.mediaType
- }
+ manifest.MediaType = *i.mediaType
}
if i.annotations != nil {
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/partial/compressed.go b/vendor/github.com/google/go-containerregistry/pkg/v1/partial/compressed.go
index 2e6e548ac993..c999517289ad 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/v1/partial/compressed.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/partial/compressed.go
@@ -17,6 +17,7 @@ package partial
import (
"io"
+ "github.com/google/go-containerregistry/internal/and"
"github.com/google/go-containerregistry/internal/gzip"
v1 "github.com/google/go-containerregistry/pkg/v1"
"github.com/google/go-containerregistry/pkg/v1/types"
@@ -45,11 +46,28 @@ type compressedLayerExtender struct {
// Uncompressed implements v1.Layer
func (cle *compressedLayerExtender) Uncompressed() (io.ReadCloser, error) {
- r, err := cle.Compressed()
+ rc, err := cle.Compressed()
if err != nil {
return nil, err
}
- return gzip.UnzipReadCloser(r)
+
+ // Often, the "compressed" bytes are not actually gzip-compressed.
+ // Peek at the first two bytes to determine whether or not it's correct to
+ // wrap this with gzip.UnzipReadCloser.
+ gzipped, pr, err := gzip.Peek(rc)
+ if err != nil {
+ return nil, err
+ }
+ prc := &and.ReadCloser{
+ Reader: pr,
+ CloseFunc: rc.Close,
+ }
+
+ if !gzipped {
+ return prc, nil
+ }
+
+ return gzip.UnzipReadCloser(prc)
}
// DiffID implements v1.Layer
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/error.go b/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/error.go
index 2c57f1a31c0f..b94b180ccf4b 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/error.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/error.go
@@ -155,6 +155,10 @@ const (
UnsupportedErrorCode ErrorCode = "UNSUPPORTED"
TooManyRequestsErrorCode ErrorCode = "TOOMANYREQUESTS"
UnknownErrorCode ErrorCode = "UNKNOWN"
+
+ // This isn't defined by either docker or OCI spec, but is defined by docker/distribution:
+ // https://github.com/distribution/distribution/blob/6a977a5a754baa213041443f841705888107362a/registry/api/errcode/register.go#L60
+ UnavailableErrorCode ErrorCode = "UNAVAILABLE"
)
// TODO: Include other error types.
@@ -162,6 +166,7 @@ var temporaryErrorCodes = map[ErrorCode]struct{}{
BlobUploadInvalidErrorCode: {},
TooManyRequestsErrorCode: {},
UnknownErrorCode: {},
+ UnavailableErrorCode: {},
}
var temporaryStatusCodes = map[int]struct{}{
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/ping.go b/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/ping.go
index 897aa703c9a9..29c36afe7c5e 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/ping.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/ping.go
@@ -79,7 +79,7 @@ func ping(ctx context.Context, reg name.Registry, t http.RoundTripper) (*pingRes
schemes = append(schemes, "http")
}
- var errs []string
+ var errs []error
for _, scheme := range schemes {
url := fmt.Sprintf("%s://%s/v2/", scheme, reg.Name())
req, err := http.NewRequest(http.MethodGet, url, nil)
@@ -88,7 +88,7 @@ func ping(ctx context.Context, reg name.Registry, t http.RoundTripper) (*pingRes
}
resp, err := client.Do(req.WithContext(ctx))
if err != nil {
- errs = append(errs, err.Error())
+ errs = append(errs, err)
// Potentially retry with http.
continue
}
@@ -125,7 +125,7 @@ func ping(ctx context.Context, reg name.Registry, t http.RoundTripper) (*pingRes
return nil, CheckError(resp, http.StatusOK, http.StatusUnauthorized)
}
}
- return nil, errors.New(strings.Join(errs, "; "))
+ return nil, multierrs(errs)
}
func pickFromMultipleChallenges(challenges []authchallenge.Challenge) authchallenge.Challenge {
@@ -145,3 +145,36 @@ func pickFromMultipleChallenges(challenges []authchallenge.Challenge) authchalle
return challenges[0]
}
+
+type multierrs []error
+
+func (m multierrs) Error() string {
+ var b strings.Builder
+ hasWritten := false
+ for _, err := range m {
+ if hasWritten {
+ b.WriteString("; ")
+ }
+ hasWritten = true
+ b.WriteString(err.Error())
+ }
+ return b.String()
+}
+
+func (m multierrs) As(target interface{}) bool {
+ for _, err := range m {
+ if errors.As(err, target) {
+ return true
+ }
+ }
+ return false
+}
+
+func (m multierrs) Is(target error) bool {
+ for _, err := range m {
+ if errors.Is(err, target) {
+ return true
+ }
+ }
+ return false
+}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/transport.go b/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/transport.go
index ea40e3a4fb10..121904df3a82 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/transport.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/remote/transport/transport.go
@@ -68,9 +68,7 @@ func NewWithContext(ctx context.Context, reg name.Registry, auth authn.Authentic
}
switch pr.challenge.Canonical() {
- case anonymous:
- return &Wrapper{t}, nil
- case basic:
+ case anonymous, basic:
return &Wrapper{&basicTransport{inner: t, auth: auth, target: reg.RegistryStr()}}, nil
case bearer:
// We require the realm, which tells us where to send our Basic auth to turn it into Bearer auth.
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/stream/layer.go b/vendor/github.com/google/go-containerregistry/pkg/v1/stream/layer.go
index e91f57ab3a2f..eeed00b3c54a 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/v1/stream/layer.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/stream/layer.go
@@ -126,18 +126,36 @@ func (l *Layer) Compressed() (io.ReadCloser, error) {
return newCompressedReader(l)
}
-type compressedReader struct {
- closer io.Closer // original blob's Closer.
+// finalize sets the layer to consumed and computes all hash and size values.
+func (l *Layer) finalize(uncompressed, compressed hash.Hash, size int64) error {
+ l.mu.Lock()
+ defer l.mu.Unlock()
+
+ diffID, err := v1.NewHash("sha256:" + hex.EncodeToString(uncompressed.Sum(nil)))
+ if err != nil {
+ return err
+ }
+ l.diffID = &diffID
+
+ digest, err := v1.NewHash("sha256:" + hex.EncodeToString(compressed.Sum(nil)))
+ if err != nil {
+ return err
+ }
+ l.digest = &digest
- h, zh hash.Hash // collects digests of compressed and uncompressed stream.
- pr io.Reader
- bw *bufio.Writer
- count *countWriter
+ l.size = size
+ l.consumed = true
+ return nil
+}
- l *Layer // stream.Layer to update upon Close.
+type compressedReader struct {
+ pr io.Reader
+ closer func() error
}
func newCompressedReader(l *Layer) (*compressedReader, error) {
+ // Collect digests of compressed and uncompressed stream and size of
+ // compressed stream.
h := sha256.New()
zh := sha256.New()
count := &countWriter{}
@@ -158,24 +176,74 @@ func newCompressedReader(l *Layer) (*compressedReader, error) {
return nil, err
}
+ doneDigesting := make(chan struct{})
+
cr := &compressedReader{
- closer: newMultiCloser(zw, l.blob),
- pr: pr,
- bw: bw,
- h: h,
- zh: zh,
- count: count,
- l: l,
+ pr: pr,
+ closer: func() error {
+ // Immediately close pw without error. There are three ways to get
+ // here.
+ //
+ // 1. There was a copy error due from the underlying reader, in which
+ // case the error will not be overwritten.
+ // 2. Copying from the underlying reader completed successfully.
+ // 3. Close has been called before the underlying reader has been
+ // fully consumed. In this case pw must be closed in order to
+ // keep the flush of bw from blocking indefinitely.
+ //
+ // NOTE: pw.Close never returns an error. The signature is only to
+ // implement io.Closer.
+ _ = pw.Close()
+
+ // Close the inner ReadCloser.
+ //
+ // NOTE: net/http will call close on success, so if we've already
+ // closed the inner rc, it's not an error.
+ if err := l.blob.Close(); err != nil && !errors.Is(err, os.ErrClosed) {
+ return err
+ }
+
+ // Finalize layer with its digest and size values.
+ <-doneDigesting
+ return l.finalize(h, zh, count.n)
+ },
}
go func() {
- if _, err := io.Copy(io.MultiWriter(h, zw), l.blob); err != nil {
+ // Copy blob into the gzip writer, which also hashes and counts the
+ // size of the compressed output, and hasher of the raw contents.
+ _, copyErr := io.Copy(io.MultiWriter(h, zw), l.blob)
+
+ // Close the gzip writer once copying is done. If this is done in the
+ // Close method of compressedReader instead, then it can cause a panic
+ // when the compressedReader is closed before the blob is fully
+ // consumed and io.Copy in this goroutine is still blocking.
+ closeErr := zw.Close()
+
+ // Check errors from writing and closing streams.
+ if copyErr != nil {
+ close(doneDigesting)
+ pw.CloseWithError(copyErr)
+ return
+ }
+ if closeErr != nil {
+ close(doneDigesting)
+ pw.CloseWithError(closeErr)
+ return
+ }
+
+ // Flush the buffer once all writes are complete to the gzip writer.
+ if err := bw.Flush(); err != nil {
+ close(doneDigesting)
pw.CloseWithError(err)
return
}
- // Now close the compressed reader, to flush the gzip stream
- // and calculate digest/diffID/size. This will cause pr to
- // return EOF which will cause readers of the Compressed stream
- // to finish reading.
+
+ // Notify closer that digests are done being written.
+ close(doneDigesting)
+
+ // Close the compressed reader to calculate digest/diffID/size. This
+ // will cause pr to return EOF which will cause readers of the
+ // Compressed stream to finish reading.
pw.CloseWithError(cr.Close())
}()
@@ -184,36 +252,7 @@ func newCompressedReader(l *Layer) (*compressedReader, error) {
func (cr *compressedReader) Read(b []byte) (int, error) { return cr.pr.Read(b) }
-func (cr *compressedReader) Close() error {
- cr.l.mu.Lock()
- defer cr.l.mu.Unlock()
-
- // Close the inner ReadCloser.
- if err := cr.closer.Close(); err != nil {
- return err
- }
-
- // Flush the buffer.
- if err := cr.bw.Flush(); err != nil {
- return err
- }
-
- diffID, err := v1.NewHash("sha256:" + hex.EncodeToString(cr.h.Sum(nil)))
- if err != nil {
- return err
- }
- cr.l.diffID = &diffID
-
- digest, err := v1.NewHash("sha256:" + hex.EncodeToString(cr.zh.Sum(nil)))
- if err != nil {
- return err
- }
- cr.l.digest = &digest
-
- cr.l.size = cr.count.n
- cr.l.consumed = true
- return nil
-}
+func (cr *compressedReader) Close() error { return cr.closer() }
// countWriter counts bytes written to it.
type countWriter struct{ n int64 }
@@ -222,21 +261,3 @@ func (c *countWriter) Write(p []byte) (int, error) {
c.n += int64(len(p))
return len(p), nil
}
-
-// multiCloser is a Closer that collects multiple Closers and Closes them in order.
-type multiCloser []io.Closer
-
-var _ io.Closer = (multiCloser)(nil)
-
-func newMultiCloser(c ...io.Closer) multiCloser { return multiCloser(c) }
-
-func (m multiCloser) Close() error {
- for _, c := range m {
- // NOTE: net/http will call close on success, so if we've already
- // closed the inner rc, it's not an error.
- if err := c.Close(); err != nil && !errors.Is(err, os.ErrClosed) {
- return err
- }
- }
- return nil
-}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/v1/zz_deepcopy_generated.go b/vendor/github.com/google/go-containerregistry/pkg/v1/zz_deepcopy_generated.go
index b32b8b77a127..0cb1586f1e3d 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/v1/zz_deepcopy_generated.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/v1/zz_deepcopy_generated.go
@@ -1,3 +1,4 @@
+//go:build !ignore_autogenerated
// +build !ignore_autogenerated
// Copyright 2018 Google LLC All Rights Reserved.
diff --git a/vendor/github.com/json-iterator/go/README.md b/vendor/github.com/json-iterator/go/README.md
index 52b111d5f36e..c589addf98c2 100644
--- a/vendor/github.com/json-iterator/go/README.md
+++ b/vendor/github.com/json-iterator/go/README.md
@@ -8,8 +8,6 @@
A high-performance 100% compatible drop-in replacement of "encoding/json"
-You can also use thrift like JSON using [thrift-iterator](https://github.com/thrift-iterator/go)
-
# Benchmark

diff --git a/vendor/github.com/json-iterator/go/go.mod b/vendor/github.com/json-iterator/go/go.mod
index e05c42ff58b8..e817cccbf6fd 100644
--- a/vendor/github.com/json-iterator/go/go.mod
+++ b/vendor/github.com/json-iterator/go/go.mod
@@ -6,6 +6,6 @@ require (
github.com/davecgh/go-spew v1.1.1
github.com/google/gofuzz v1.0.0
github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421
- github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742
+ github.com/modern-go/reflect2 v1.0.2
github.com/stretchr/testify v1.3.0
)
diff --git a/vendor/github.com/json-iterator/go/go.sum b/vendor/github.com/json-iterator/go/go.sum
index be00a6df969d..4b7bb8a29520 100644
--- a/vendor/github.com/json-iterator/go/go.sum
+++ b/vendor/github.com/json-iterator/go/go.sum
@@ -5,11 +5,10 @@ github.com/google/gofuzz v1.0.0 h1:A8PeW59pxE9IoFRqBp37U+mSNaQoZ46F1f0f863XSXw=
github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421 h1:ZqeYNhU3OHLH3mGKHDcjJRFFRrJa6eAM5H+CtDdOsPc=
github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
-github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742 h1:Esafd1046DLDQ0W1YjYsBW+p8U2u7vzgW2SQVmlNazg=
-github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
+github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M=
+github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
-github.com/stretchr/objx v0.1.0 h1:4G4v2dO3VZwixGIRoQ5Lfboy6nUhCyYzaqnIAPPhYs4=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q=
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
diff --git a/vendor/github.com/modern-go/reflect2/.travis.yml b/vendor/github.com/modern-go/reflect2/.travis.yml
index fbb43744d94b..b097728dbffd 100644
--- a/vendor/github.com/modern-go/reflect2/.travis.yml
+++ b/vendor/github.com/modern-go/reflect2/.travis.yml
@@ -1,7 +1,7 @@
language: go
go:
- - 1.8.x
+ - 1.9.x
- 1.x
before_install:
diff --git a/vendor/github.com/modern-go/reflect2/Gopkg.lock b/vendor/github.com/modern-go/reflect2/Gopkg.lock
index 2a3a69893b50..10ef811182d1 100644
--- a/vendor/github.com/modern-go/reflect2/Gopkg.lock
+++ b/vendor/github.com/modern-go/reflect2/Gopkg.lock
@@ -1,15 +1,9 @@
# This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'.
-[[projects]]
- name = "github.com/modern-go/concurrent"
- packages = ["."]
- revision = "e0a39a4cb4216ea8db28e22a69f4ec25610d513a"
- version = "1.0.0"
-
[solve-meta]
analyzer-name = "dep"
analyzer-version = 1
- inputs-digest = "daee8a88b3498b61c5640056665b8b9eea062006f5e596bbb6a3ed9119a11ec7"
+ input-imports = []
solver-name = "gps-cdcl"
solver-version = 1
diff --git a/vendor/github.com/modern-go/reflect2/Gopkg.toml b/vendor/github.com/modern-go/reflect2/Gopkg.toml
index 2f4f4dbdcc5e..a9bc5061b042 100644
--- a/vendor/github.com/modern-go/reflect2/Gopkg.toml
+++ b/vendor/github.com/modern-go/reflect2/Gopkg.toml
@@ -26,10 +26,6 @@
ignored = []
-[[constraint]]
- name = "github.com/modern-go/concurrent"
- version = "1.0.0"
-
[prune]
go-tests = true
unused-packages = true
diff --git a/vendor/github.com/modern-go/reflect2/go.mod b/vendor/github.com/modern-go/reflect2/go.mod
new file mode 100644
index 000000000000..9057e9b33f2a
--- /dev/null
+++ b/vendor/github.com/modern-go/reflect2/go.mod
@@ -0,0 +1,3 @@
+module github.com/modern-go/reflect2
+
+go 1.12
diff --git a/vendor/github.com/modern-go/reflect2/go_above_118.go b/vendor/github.com/modern-go/reflect2/go_above_118.go
new file mode 100644
index 000000000000..2b4116f6c9be
--- /dev/null
+++ b/vendor/github.com/modern-go/reflect2/go_above_118.go
@@ -0,0 +1,23 @@
+//+build go1.18
+
+package reflect2
+
+import (
+ "unsafe"
+)
+
+// m escapes into the return value, but the caller of mapiterinit
+// doesn't let the return value escape.
+//go:noescape
+//go:linkname mapiterinit reflect.mapiterinit
+func mapiterinit(rtype unsafe.Pointer, m unsafe.Pointer, it *hiter)
+
+func (type2 *UnsafeMapType) UnsafeIterate(obj unsafe.Pointer) MapIterator {
+ var it hiter
+ mapiterinit(type2.rtype, *(*unsafe.Pointer)(obj), &it)
+ return &UnsafeMapIterator{
+ hiter: &it,
+ pKeyRType: type2.pKeyRType,
+ pElemRType: type2.pElemRType,
+ }
+}
\ No newline at end of file
diff --git a/vendor/github.com/modern-go/reflect2/go_above_17.go b/vendor/github.com/modern-go/reflect2/go_above_17.go
deleted file mode 100644
index 5c1cea8683ab..000000000000
--- a/vendor/github.com/modern-go/reflect2/go_above_17.go
+++ /dev/null
@@ -1,8 +0,0 @@
-//+build go1.7
-
-package reflect2
-
-import "unsafe"
-
-//go:linkname resolveTypeOff reflect.resolveTypeOff
-func resolveTypeOff(rtype unsafe.Pointer, off int32) unsafe.Pointer
diff --git a/vendor/github.com/modern-go/reflect2/go_above_19.go b/vendor/github.com/modern-go/reflect2/go_above_19.go
index c7e3b780116a..974f7685e495 100644
--- a/vendor/github.com/modern-go/reflect2/go_above_19.go
+++ b/vendor/github.com/modern-go/reflect2/go_above_19.go
@@ -6,6 +6,9 @@ import (
"unsafe"
)
+//go:linkname resolveTypeOff reflect.resolveTypeOff
+func resolveTypeOff(rtype unsafe.Pointer, off int32) unsafe.Pointer
+
//go:linkname makemap reflect.makemap
func makemap(rtype unsafe.Pointer, cap int) (m unsafe.Pointer)
diff --git a/vendor/github.com/modern-go/reflect2/go_below_118.go b/vendor/github.com/modern-go/reflect2/go_below_118.go
new file mode 100644
index 000000000000..00003dbd7c57
--- /dev/null
+++ b/vendor/github.com/modern-go/reflect2/go_below_118.go
@@ -0,0 +1,21 @@
+//+build !go1.18
+
+package reflect2
+
+import (
+ "unsafe"
+)
+
+// m escapes into the return value, but the caller of mapiterinit
+// doesn't let the return value escape.
+//go:noescape
+//go:linkname mapiterinit reflect.mapiterinit
+func mapiterinit(rtype unsafe.Pointer, m unsafe.Pointer) (val *hiter)
+
+func (type2 *UnsafeMapType) UnsafeIterate(obj unsafe.Pointer) MapIterator {
+ return &UnsafeMapIterator{
+ hiter: mapiterinit(type2.rtype, *(*unsafe.Pointer)(obj)),
+ pKeyRType: type2.pKeyRType,
+ pElemRType: type2.pElemRType,
+ }
+}
\ No newline at end of file
diff --git a/vendor/github.com/modern-go/reflect2/go_below_17.go b/vendor/github.com/modern-go/reflect2/go_below_17.go
deleted file mode 100644
index 65a93c889b77..000000000000
--- a/vendor/github.com/modern-go/reflect2/go_below_17.go
+++ /dev/null
@@ -1,9 +0,0 @@
-//+build !go1.7
-
-package reflect2
-
-import "unsafe"
-
-func resolveTypeOff(rtype unsafe.Pointer, off int32) unsafe.Pointer {
- return nil
-}
diff --git a/vendor/github.com/modern-go/reflect2/go_below_19.go b/vendor/github.com/modern-go/reflect2/go_below_19.go
deleted file mode 100644
index b050ef70cddb..000000000000
--- a/vendor/github.com/modern-go/reflect2/go_below_19.go
+++ /dev/null
@@ -1,14 +0,0 @@
-//+build !go1.9
-
-package reflect2
-
-import (
- "unsafe"
-)
-
-//go:linkname makemap reflect.makemap
-func makemap(rtype unsafe.Pointer) (m unsafe.Pointer)
-
-func makeMapWithSize(rtype unsafe.Pointer, cap int) unsafe.Pointer {
- return makemap(rtype)
-}
diff --git a/vendor/github.com/modern-go/reflect2/reflect2.go b/vendor/github.com/modern-go/reflect2/reflect2.go
index 63b49c799194..c43c8b9d6297 100644
--- a/vendor/github.com/modern-go/reflect2/reflect2.go
+++ b/vendor/github.com/modern-go/reflect2/reflect2.go
@@ -1,8 +1,9 @@
package reflect2
import (
- "github.com/modern-go/concurrent"
"reflect"
+ "runtime"
+ "sync"
"unsafe"
)
@@ -130,13 +131,13 @@ var ConfigSafe = Config{UseSafeImplementation: true}.Froze()
type frozenConfig struct {
useSafeImplementation bool
- cache *concurrent.Map
+ cache *sync.Map
}
func (cfg Config) Froze() *frozenConfig {
return &frozenConfig{
useSafeImplementation: cfg.UseSafeImplementation,
- cache: concurrent.NewMap(),
+ cache: new(sync.Map),
}
}
@@ -288,11 +289,12 @@ func NoEscape(p unsafe.Pointer) unsafe.Pointer {
}
func UnsafeCastString(str string) []byte {
+ bytes := make([]byte, 0)
stringHeader := (*reflect.StringHeader)(unsafe.Pointer(&str))
- sliceHeader := &reflect.SliceHeader{
- Data: stringHeader.Data,
- Cap: stringHeader.Len,
- Len: stringHeader.Len,
- }
- return *(*[]byte)(unsafe.Pointer(sliceHeader))
+ sliceHeader := (*reflect.SliceHeader)(unsafe.Pointer(&bytes))
+ sliceHeader.Data = stringHeader.Data
+ sliceHeader.Cap = stringHeader.Len
+ sliceHeader.Len = stringHeader.Len
+ runtime.KeepAlive(str)
+ return bytes
}
diff --git a/vendor/github.com/modern-go/reflect2/test.sh b/vendor/github.com/modern-go/reflect2/test.sh
deleted file mode 100644
index 3d2b9768ce61..000000000000
--- a/vendor/github.com/modern-go/reflect2/test.sh
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/usr/bin/env bash
-
-set -e
-echo "" > coverage.txt
-
-for d in $(go list github.com/modern-go/reflect2-tests/... | grep -v vendor); do
- go test -coverprofile=profile.out -coverpkg=github.com/modern-go/reflect2 $d
- if [ -f profile.out ]; then
- cat profile.out >> coverage.txt
- rm profile.out
- fi
-done
diff --git a/vendor/github.com/modern-go/reflect2/type_map.go b/vendor/github.com/modern-go/reflect2/type_map.go
index 3acfb55803a8..4b13c3155c80 100644
--- a/vendor/github.com/modern-go/reflect2/type_map.go
+++ b/vendor/github.com/modern-go/reflect2/type_map.go
@@ -1,17 +1,13 @@
+// +build !gccgo
+
package reflect2
import (
"reflect"
- "runtime"
- "strings"
"sync"
"unsafe"
)
-// typelinks1 for 1.5 ~ 1.6
-//go:linkname typelinks1 reflect.typelinks
-func typelinks1() [][]unsafe.Pointer
-
// typelinks2 for 1.7 ~
//go:linkname typelinks2 reflect.typelinks
func typelinks2() (sections []unsafe.Pointer, offset [][]int32)
@@ -27,49 +23,10 @@ func discoverTypes() {
types = make(map[string]reflect.Type)
packages = make(map[string]map[string]reflect.Type)
- ver := runtime.Version()
- if ver == "go1.5" || strings.HasPrefix(ver, "go1.5.") {
- loadGo15Types()
- } else if ver == "go1.6" || strings.HasPrefix(ver, "go1.6.") {
- loadGo15Types()
- } else {
- loadGo17Types()
- }
-}
-
-func loadGo15Types() {
- var obj interface{} = reflect.TypeOf(0)
- typePtrss := typelinks1()
- for _, typePtrs := range typePtrss {
- for _, typePtr := range typePtrs {
- (*emptyInterface)(unsafe.Pointer(&obj)).word = typePtr
- typ := obj.(reflect.Type)
- if typ.Kind() == reflect.Ptr && typ.Elem().Kind() == reflect.Struct {
- loadedType := typ.Elem()
- pkgTypes := packages[loadedType.PkgPath()]
- if pkgTypes == nil {
- pkgTypes = map[string]reflect.Type{}
- packages[loadedType.PkgPath()] = pkgTypes
- }
- types[loadedType.String()] = loadedType
- pkgTypes[loadedType.Name()] = loadedType
- }
- if typ.Kind() == reflect.Slice && typ.Elem().Kind() == reflect.Ptr &&
- typ.Elem().Elem().Kind() == reflect.Struct {
- loadedType := typ.Elem().Elem()
- pkgTypes := packages[loadedType.PkgPath()]
- if pkgTypes == nil {
- pkgTypes = map[string]reflect.Type{}
- packages[loadedType.PkgPath()] = pkgTypes
- }
- types[loadedType.String()] = loadedType
- pkgTypes[loadedType.Name()] = loadedType
- }
- }
- }
+ loadGoTypes()
}
-func loadGo17Types() {
+func loadGoTypes() {
var obj interface{} = reflect.TypeOf(0)
sections, offset := typelinks2()
for i, offs := range offset {
diff --git a/vendor/github.com/modern-go/reflect2/unsafe_link.go b/vendor/github.com/modern-go/reflect2/unsafe_link.go
index 57229c8db417..b49f614efc58 100644
--- a/vendor/github.com/modern-go/reflect2/unsafe_link.go
+++ b/vendor/github.com/modern-go/reflect2/unsafe_link.go
@@ -19,18 +19,12 @@ func typedslicecopy(elemType unsafe.Pointer, dst, src sliceHeader) int
//go:linkname mapassign reflect.mapassign
//go:noescape
-func mapassign(rtype unsafe.Pointer, m unsafe.Pointer, key, val unsafe.Pointer)
+func mapassign(rtype unsafe.Pointer, m unsafe.Pointer, key unsafe.Pointer, val unsafe.Pointer)
//go:linkname mapaccess reflect.mapaccess
//go:noescape
func mapaccess(rtype unsafe.Pointer, m unsafe.Pointer, key unsafe.Pointer) (val unsafe.Pointer)
-// m escapes into the return value, but the caller of mapiterinit
-// doesn't let the return value escape.
-//go:noescape
-//go:linkname mapiterinit reflect.mapiterinit
-func mapiterinit(rtype unsafe.Pointer, m unsafe.Pointer) *hiter
-
//go:noescape
//go:linkname mapiternext reflect.mapiternext
func mapiternext(it *hiter)
@@ -42,9 +36,21 @@ func ifaceE2I(rtype unsafe.Pointer, src interface{}, dst unsafe.Pointer)
// If you modify hiter, also change cmd/internal/gc/reflect.go to indicate
// the layout of this structure.
type hiter struct {
- key unsafe.Pointer // Must be in first position. Write nil to indicate iteration end (see cmd/internal/gc/range.go).
- value unsafe.Pointer // Must be in second position (see cmd/internal/gc/range.go).
- // rest fields are ignored
+ key unsafe.Pointer
+ value unsafe.Pointer
+ t unsafe.Pointer
+ h unsafe.Pointer
+ buckets unsafe.Pointer
+ bptr unsafe.Pointer
+ overflow *[]unsafe.Pointer
+ oldoverflow *[]unsafe.Pointer
+ startBucket uintptr
+ offset uint8
+ wrapped bool
+ B uint8
+ i uint8
+ bucket uintptr
+ checkBucket uintptr
}
// add returns p+x.
diff --git a/vendor/github.com/modern-go/reflect2/unsafe_map.go b/vendor/github.com/modern-go/reflect2/unsafe_map.go
index f2e76e6bb149..37872da81910 100644
--- a/vendor/github.com/modern-go/reflect2/unsafe_map.go
+++ b/vendor/github.com/modern-go/reflect2/unsafe_map.go
@@ -107,14 +107,6 @@ func (type2 *UnsafeMapType) Iterate(obj interface{}) MapIterator {
return type2.UnsafeIterate(objEFace.data)
}
-func (type2 *UnsafeMapType) UnsafeIterate(obj unsafe.Pointer) MapIterator {
- return &UnsafeMapIterator{
- hiter: mapiterinit(type2.rtype, *(*unsafe.Pointer)(obj)),
- pKeyRType: type2.pKeyRType,
- pElemRType: type2.pElemRType,
- }
-}
-
type UnsafeMapIterator struct {
*hiter
pKeyRType unsafe.Pointer
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/README.md b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/README.md
deleted file mode 100644
index 413379a0793c..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/README.md
+++ /dev/null
@@ -1,8 +0,0 @@
-# k8s.io/kubernetes/pkg/credentialprovider temporary fork
-
-This is a temporary fork of the package
-`k8s.io/kubernetes/pkg/credentialprovider` to be able to use it
-without having to depend on `k8s.io/kubernetes`, dependency that
-brings hell with it, **especially** with go modules.
-
-See [kubernetes/enhancements#1406](https://github.com/kubernetes/enhancements/pull/1406) for progress on the matter.
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/aws/aws_credentials.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/aws/aws_credentials.go
deleted file mode 100644
index 59945fdb6c71..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/aws/aws_credentials.go
+++ /dev/null
@@ -1,305 +0,0 @@
-/*
-Copyright 2014 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package credentials
-
-import (
- "encoding/base64"
- "errors"
- "fmt"
- "net/url"
- "regexp"
- "strings"
- "sync"
- "time"
-
- "github.com/aws/aws-sdk-go/aws"
- "github.com/aws/aws-sdk-go/aws/request"
- "github.com/aws/aws-sdk-go/aws/session"
- "github.com/aws/aws-sdk-go/service/ecr"
-
- "github.com/vdemeester/k8s-pkg-credentialprovider"
- "k8s.io/apimachinery/pkg/util/wait"
- "k8s.io/client-go/tools/cache"
- "k8s.io/component-base/version"
- "k8s.io/klog/v2"
-)
-
-var ecrPattern = regexp.MustCompile(`^(\d{12})\.dkr\.ecr(\-fips)?\.([a-zA-Z0-9][a-zA-Z0-9-_]*)\.amazonaws\.com(\.cn)?$`)
-
-// init registers a credential provider for each registryURLTemplate and creates
-// an ECR token getter factory with a new cache to store token getters
-func init() {
- credentialprovider.RegisterCredentialProvider("amazon-ecr",
- newECRProvider(&ecrTokenGetterFactory{cache: make(map[string]tokenGetter)}))
-}
-
-// ecrProvider is a DockerConfigProvider that gets and refreshes tokens
-// from AWS to access ECR.
-type ecrProvider struct {
- cache cache.Store
- getterFactory tokenGetterFactory
-}
-
-var _ credentialprovider.DockerConfigProvider = &ecrProvider{}
-
-func newECRProvider(getterFactory tokenGetterFactory) *ecrProvider {
- return &ecrProvider{
- cache: cache.NewExpirationStore(stringKeyFunc, &ecrExpirationPolicy{}),
- getterFactory: getterFactory,
- }
-}
-
-// Enabled implements DockerConfigProvider.Enabled. Enabled is true if AWS
-// credentials are found.
-func (p *ecrProvider) Enabled() bool {
- sess, err := session.NewSessionWithOptions(session.Options{
- SharedConfigState: session.SharedConfigEnable,
- })
- if err != nil {
- klog.Errorf("while validating AWS credentials %v", err)
- return false
- }
- if _, err := sess.Config.Credentials.Get(); err != nil {
- klog.Errorf("while getting AWS credentials %v", err)
- return false
- }
- return true
-}
-
-// Provide returns a DockerConfig with credentials from the cache if they are
-// found, or from ECR
-func (p *ecrProvider) Provide(image string) credentialprovider.DockerConfig {
- parsed, err := parseRepoURL(image)
- if err != nil {
- klog.V(3).Info(err)
- return credentialprovider.DockerConfig{}
- }
-
- if cfg, exists := p.getFromCache(parsed); exists {
- klog.V(6).Infof("Got ECR credentials from cache for %s", parsed.registry)
- return cfg
- }
- klog.V(3).Info("unable to get ECR credentials from cache, checking ECR API")
-
- cfg, err := p.getFromECR(parsed)
- if err != nil {
- klog.Errorf("error getting credentials from ECR for %s %v", parsed.registry, err)
- return credentialprovider.DockerConfig{}
- }
- klog.V(3).Infof("Got ECR credentials from ECR API for %s", parsed.registry)
- return cfg
-}
-
-// getFromCache attempts to get credentials from the cache
-func (p *ecrProvider) getFromCache(parsed *parsedURL) (credentialprovider.DockerConfig, bool) {
- cfg := credentialprovider.DockerConfig{}
-
- obj, exists, err := p.cache.GetByKey(parsed.registry)
- if err != nil {
- klog.Errorf("error getting ECR credentials from cache: %v", err)
- return cfg, false
- }
-
- if !exists {
- return cfg, false
- }
-
- entry := obj.(*cacheEntry)
- cfg[entry.registry] = entry.credentials
- return cfg, true
-}
-
-// getFromECR gets credentials from ECR since they are not in the cache
-func (p *ecrProvider) getFromECR(parsed *parsedURL) (credentialprovider.DockerConfig, error) {
- cfg := credentialprovider.DockerConfig{}
- getter, err := p.getterFactory.GetTokenGetterForRegion(parsed.region)
- if err != nil {
- return cfg, err
- }
- params := &ecr.GetAuthorizationTokenInput{RegistryIds: []*string{aws.String(parsed.registryID)}}
- output, err := getter.GetAuthorizationToken(params)
- if err != nil {
- return cfg, err
- }
- if output == nil {
- return cfg, errors.New("authorization token is nil")
- }
- if len(output.AuthorizationData) == 0 {
- return cfg, errors.New("authorization data from response is empty")
- }
- data := output.AuthorizationData[0]
- if data.AuthorizationToken == nil {
- return cfg, errors.New("authorization token in response is nil")
- }
- entry, err := makeCacheEntry(data, parsed.registry)
- if err != nil {
- return cfg, err
- }
- if err := p.cache.Add(entry); err != nil {
- return cfg, err
- }
- cfg[entry.registry] = entry.credentials
- return cfg, nil
-}
-
-type parsedURL struct {
- registryID string
- region string
- registry string
-}
-
-// parseRepoURL parses and splits the registry URL into the registry ID,
-// region, and registry.
-// .dkr.ecr(-fips)..amazonaws.com(.cn)
-func parseRepoURL(image string) (*parsedURL, error) {
- parsed, err := url.Parse("https://" + image)
- if err != nil {
- return nil, fmt.Errorf("error parsing image %s %v", image, err)
- }
- splitURL := ecrPattern.FindStringSubmatch(parsed.Hostname())
- if len(splitURL) == 0 {
- return nil, fmt.Errorf("%s is not a valid ECR repository URL", parsed.Hostname())
- }
- return &parsedURL{
- registryID: splitURL[1],
- region: splitURL[3],
- registry: parsed.Hostname(),
- }, nil
-}
-
-// tokenGetter is for testing purposes
-type tokenGetter interface {
- GetAuthorizationToken(input *ecr.GetAuthorizationTokenInput) (*ecr.GetAuthorizationTokenOutput, error)
-}
-
-// tokenGetterFactory is for testing purposes
-type tokenGetterFactory interface {
- GetTokenGetterForRegion(string) (tokenGetter, error)
-}
-
-// ecrTokenGetterFactory stores a token getter per region
-type ecrTokenGetterFactory struct {
- cache map[string]tokenGetter
- mutex sync.Mutex
-}
-
-// awsHandlerLogger is a handler that logs all AWS SDK requests
-// Copied from pkg/cloudprovider/providers/aws/log_handler.go
-func awsHandlerLogger(req *request.Request) {
- service := req.ClientInfo.ServiceName
- region := req.Config.Region
-
- name := "?"
- if req.Operation != nil {
- name = req.Operation.Name
- }
-
- klog.V(3).Infof("AWS request: %s:%s in %s", service, name, *region)
-}
-
-func newECRTokenGetter(region string) (tokenGetter, error) {
- sess, err := session.NewSessionWithOptions(session.Options{
- Config: aws.Config{Region: aws.String(region)},
- SharedConfigState: session.SharedConfigEnable,
- })
- if err != nil {
- return nil, err
- }
- getter := &ecrTokenGetter{svc: ecr.New(sess)}
- getter.svc.Handlers.Build.PushFrontNamed(request.NamedHandler{
- Name: "k8s/user-agent",
- Fn: request.MakeAddToUserAgentHandler("kubernetes", version.Get().String()),
- })
- getter.svc.Handlers.Sign.PushFrontNamed(request.NamedHandler{
- Name: "k8s/logger",
- Fn: awsHandlerLogger,
- })
- return getter, nil
-}
-
-// GetTokenGetterForRegion gets the token getter for the requested region. If it
-// doesn't exist, it creates a new ECR token getter
-func (f *ecrTokenGetterFactory) GetTokenGetterForRegion(region string) (tokenGetter, error) {
- f.mutex.Lock()
- defer f.mutex.Unlock()
-
- if getter, ok := f.cache[region]; ok {
- return getter, nil
- }
- getter, err := newECRTokenGetter(region)
- if err != nil {
- return nil, fmt.Errorf("unable to create token getter for region %v %v", region, err)
- }
- f.cache[region] = getter
- return getter, nil
-}
-
-// The canonical implementation
-type ecrTokenGetter struct {
- svc *ecr.ECR
-}
-
-// GetAuthorizationToken gets the ECR authorization token using the ECR API
-func (p *ecrTokenGetter) GetAuthorizationToken(input *ecr.GetAuthorizationTokenInput) (*ecr.GetAuthorizationTokenOutput, error) {
- return p.svc.GetAuthorizationToken(input)
-}
-
-type cacheEntry struct {
- expiresAt time.Time
- credentials credentialprovider.DockerConfigEntry
- registry string
-}
-
-// makeCacheEntry decodes the ECR authorization entry and re-packages it into a
-// cacheEntry.
-func makeCacheEntry(data *ecr.AuthorizationData, registry string) (*cacheEntry, error) {
- decodedToken, err := base64.StdEncoding.DecodeString(aws.StringValue(data.AuthorizationToken))
- if err != nil {
- return nil, fmt.Errorf("error decoding ECR authorization token: %v", err)
- }
- parts := strings.SplitN(string(decodedToken), ":", 2)
- if len(parts) < 2 {
- return nil, errors.New("error getting username and password from authorization token")
- }
- creds := credentialprovider.DockerConfigEntry{
- Username: parts[0],
- Password: parts[1],
- Email: "not@val.id", // ECR doesn't care and Docker is about to obsolete it
- }
- if data.ExpiresAt == nil {
- return nil, errors.New("authorization data expiresAt is nil")
- }
- return &cacheEntry{
- expiresAt: data.ExpiresAt.Add(-1 * wait.Jitter(30*time.Minute, 0.2)),
- credentials: creds,
- registry: registry,
- }, nil
-}
-
-// ecrExpirationPolicy implements ExpirationPolicy from client-go.
-type ecrExpirationPolicy struct{}
-
-// stringKeyFunc returns the cache key as a string
-func stringKeyFunc(obj interface{}) (string, error) {
- key := obj.(*cacheEntry).registry
- return key, nil
-}
-
-// IsExpired checks if the ECR credentials are expired.
-func (p *ecrExpirationPolicy) IsExpired(entry *cache.TimestampedEntry) bool {
- return time.Now().After(entry.Obj.(*cacheEntry).expiresAt)
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/azure_acr_helper.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/azure_acr_helper.go
deleted file mode 100644
index 347b1658a918..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/azure_acr_helper.go
+++ /dev/null
@@ -1,285 +0,0 @@
-// +build !providerless
-
-/*
-Copyright 2016 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-/*
-Copyright 2017 Microsoft Corporation
-
-MIT License
-
-Copyright (c) Microsoft Corporation. All rights reserved.
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all
-copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-SOFTWARE
-*/
-
-// Source: https://github.com/Azure/acr-docker-credential-helper/blob/a79b541f3ee761f6cc4511863ed41fb038c19464/src/docker-credential-acr/acr_login.go
-
-package azure
-
-import (
- "bytes"
- "encoding/json"
- "errors"
- "fmt"
- "io"
- "io/ioutil"
- "net/http"
- "net/url"
- "strconv"
- "strings"
- "unicode"
-)
-
-type authDirective struct {
- service string
- realm string
-}
-
-type acrAuthResponse struct {
- RefreshToken string `json:"refresh_token"`
-}
-
-// 5 minutes buffer time to allow timeshift between local machine and AAD
-const userAgentHeader = "User-Agent"
-const userAgent = "kubernetes-credentialprovider-acr"
-
-const dockerTokenLoginUsernameGUID = "00000000-0000-0000-0000-000000000000"
-
-var client = &http.Client{}
-
-func receiveChallengeFromLoginServer(serverAddress string) (*authDirective, error) {
- challengeURL := url.URL{
- Scheme: "https",
- Host: serverAddress,
- Path: "v2/",
- }
- var err error
- var r *http.Request
- r, err = http.NewRequest("GET", challengeURL.String(), nil)
- if err != nil {
- return nil, fmt.Errorf("failed to construct request, got %v", err)
- }
- r.Header.Add(userAgentHeader, userAgent)
-
- var challenge *http.Response
- if challenge, err = client.Do(r); err != nil {
- return nil, fmt.Errorf("error reaching registry endpoint %s, error: %s", challengeURL.String(), err)
- }
- defer challenge.Body.Close()
-
- if challenge.StatusCode != 401 {
- return nil, fmt.Errorf("registry did not issue a valid AAD challenge, status: %d", challenge.StatusCode)
- }
-
- var authHeader []string
- var ok bool
- if authHeader, ok = challenge.Header["Www-Authenticate"]; !ok {
- return nil, fmt.Errorf("challenge response does not contain header 'Www-Authenticate'")
- }
-
- if len(authHeader) != 1 {
- return nil, fmt.Errorf("registry did not issue a valid AAD challenge, authenticate header [%s]",
- strings.Join(authHeader, ", "))
- }
-
- authSections := strings.SplitN(authHeader[0], " ", 2)
- authType := strings.ToLower(authSections[0])
- var authParams *map[string]string
- if authParams, err = parseAssignments(authSections[1]); err != nil {
- return nil, fmt.Errorf("unable to understand the contents of Www-Authenticate header %s", authSections[1])
- }
-
- // verify headers
- if !strings.EqualFold("Bearer", authType) {
- return nil, fmt.Errorf("Www-Authenticate: expected realm: Bearer, actual: %s", authType)
- }
- if len((*authParams)["service"]) == 0 {
- return nil, fmt.Errorf("Www-Authenticate: missing header \"service\"")
- }
- if len((*authParams)["realm"]) == 0 {
- return nil, fmt.Errorf("Www-Authenticate: missing header \"realm\"")
- }
-
- return &authDirective{
- service: (*authParams)["service"],
- realm: (*authParams)["realm"],
- }, nil
-}
-
-func performTokenExchange(
- serverAddress string,
- directive *authDirective,
- tenant string,
- accessToken string) (string, error) {
- var err error
- data := url.Values{
- "service": []string{directive.service},
- "grant_type": []string{"access_token_refresh_token"},
- "access_token": []string{accessToken},
- "refresh_token": []string{accessToken},
- "tenant": []string{tenant},
- }
-
- var realmURL *url.URL
- if realmURL, err = url.Parse(directive.realm); err != nil {
- return "", fmt.Errorf("Www-Authenticate: invalid realm %s", directive.realm)
- }
- authEndpoint := fmt.Sprintf("%s://%s/oauth2/exchange", realmURL.Scheme, realmURL.Host)
-
- datac := data.Encode()
- var r *http.Request
- r, err = http.NewRequest("POST", authEndpoint, bytes.NewBufferString(datac))
- if err != nil {
- return "", fmt.Errorf("failed to construct request, got %v", err)
- }
- r.Header.Add(userAgentHeader, userAgent)
- r.Header.Add("Content-Type", "application/x-www-form-urlencoded")
- r.Header.Add("Content-Length", strconv.Itoa(len(datac)))
-
- var exchange *http.Response
- if exchange, err = client.Do(r); err != nil {
- return "", fmt.Errorf("Www-Authenticate: failed to reach auth url %s", authEndpoint)
- }
-
- defer exchange.Body.Close()
- if exchange.StatusCode != 200 {
- return "", fmt.Errorf("Www-Authenticate: auth url %s responded with status code %d", authEndpoint, exchange.StatusCode)
- }
-
- var content []byte
- limitedReader := &io.LimitedReader{R: exchange.Body, N: maxReadLength}
- if content, err = ioutil.ReadAll(limitedReader); err != nil {
- return "", fmt.Errorf("Www-Authenticate: error reading response from %s", authEndpoint)
- }
-
- if limitedReader.N <= 0 {
- return "", errors.New("the read limit is reached")
- }
-
- var authResp acrAuthResponse
- if err = json.Unmarshal(content, &authResp); err != nil {
- return "", fmt.Errorf("Www-Authenticate: unable to read response %s", content)
- }
-
- return authResp.RefreshToken, nil
-}
-
-// Try and parse a string of assignments in the form of:
-// key1 = value1, key2 = "value 2", key3 = ""
-// Note: this method and handle quotes but does not handle escaping of quotes
-func parseAssignments(statements string) (*map[string]string, error) {
- var cursor int
- result := make(map[string]string)
- var errorMsg = fmt.Errorf("malformed header value: %s", statements)
- for {
- // parse key
- equalIndex := nextOccurrence(statements, cursor, "=")
- if equalIndex == -1 {
- return nil, errorMsg
- }
- key := strings.TrimSpace(statements[cursor:equalIndex])
-
- // parse value
- cursor = nextNoneSpace(statements, equalIndex+1)
- if cursor == -1 {
- return nil, errorMsg
- }
- // case: value is quoted
- if statements[cursor] == '"' {
- cursor = cursor + 1
- // like I said, not handling escapes, but this will skip any comma that's
- // within the quotes which is somewhat more likely
- closeQuoteIndex := nextOccurrence(statements, cursor, "\"")
- if closeQuoteIndex == -1 {
- return nil, errorMsg
- }
- value := statements[cursor:closeQuoteIndex]
- result[key] = value
-
- commaIndex := nextNoneSpace(statements, closeQuoteIndex+1)
- if commaIndex == -1 {
- // no more comma, done
- return &result, nil
- } else if statements[commaIndex] != ',' {
- // expect comma immediately after close quote
- return nil, errorMsg
- } else {
- cursor = commaIndex + 1
- }
- } else {
- commaIndex := nextOccurrence(statements, cursor, ",")
- endStatements := commaIndex == -1
- var untrimmed string
- if endStatements {
- untrimmed = statements[cursor:commaIndex]
- } else {
- untrimmed = statements[cursor:]
- }
- value := strings.TrimSpace(untrimmed)
-
- if len(value) == 0 {
- // disallow empty value without quote
- return nil, errorMsg
- }
-
- result[key] = value
-
- if endStatements {
- return &result, nil
- }
- cursor = commaIndex + 1
- }
- }
-}
-
-func nextOccurrence(str string, start int, sep string) int {
- if start >= len(str) {
- return -1
- }
- offset := strings.Index(str[start:], sep)
- if offset == -1 {
- return -1
- }
- return offset + start
-}
-
-func nextNoneSpace(str string, start int) int {
- if start >= len(str) {
- return -1
- }
- offset := strings.IndexFunc(str[start:], func(c rune) bool { return !unicode.IsSpace(c) })
- if offset == -1 {
- return -1
- }
- return offset + start
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/azure_credentials.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/azure_credentials.go
deleted file mode 100644
index acab1e0fff89..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/azure_credentials.go
+++ /dev/null
@@ -1,369 +0,0 @@
-// +build !providerless
-
-/*
-Copyright 2016 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package azure
-
-import (
- "context"
- "errors"
- "io"
- "io/ioutil"
- "os"
- "regexp"
- "strings"
- "time"
-
- "github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/adal"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/spf13/pflag"
-
- "k8s.io/client-go/tools/cache"
- "k8s.io/klog/v2"
- "github.com/vdemeester/k8s-pkg-credentialprovider"
- "k8s.io/legacy-cloud-providers/azure/auth"
- "sigs.k8s.io/yaml"
-)
-
-var flagConfigFile = pflag.String("azure-container-registry-config", "",
- "Path to the file containing Azure container registry configuration information.")
-
-const (
- dummyRegistryEmail = "name@contoso.com"
- maxReadLength = 10 * 1 << 20 // 10MB
-)
-
-var (
- containerRegistryUrls = []string{"*.azurecr.io", "*.azurecr.cn", "*.azurecr.de", "*.azurecr.us"}
- acrRE = regexp.MustCompile(`.*\.azurecr\.io|.*\.azurecr\.cn|.*\.azurecr\.de|.*\.azurecr\.us`)
-)
-
-// init registers the various means by which credentials may
-// be resolved on Azure.
-func init() {
- credentialprovider.RegisterCredentialProvider(
- "azure",
- NewACRProvider(flagConfigFile),
- )
-}
-
-type cacheEntry struct {
- expiresAt time.Time
- credentials credentialprovider.DockerConfigEntry
- registry string
-}
-
-// acrExpirationPolicy implements ExpirationPolicy from client-go.
-type acrExpirationPolicy struct{}
-
-// stringKeyFunc returns the cache key as a string
-func stringKeyFunc(obj interface{}) (string, error) {
- key := obj.(*cacheEntry).registry
- return key, nil
-}
-
-// IsExpired checks if the ACR credentials are expired.
-func (p *acrExpirationPolicy) IsExpired(entry *cache.TimestampedEntry) bool {
- return time.Now().After(entry.Obj.(*cacheEntry).expiresAt)
-}
-
-// RegistriesClient is a testable interface for the ACR client List operation.
-type RegistriesClient interface {
- List(ctx context.Context) ([]containerregistry.Registry, error)
-}
-
-// azRegistriesClient implements RegistriesClient.
-type azRegistriesClient struct {
- client containerregistry.RegistriesClient
-}
-
-func newAzRegistriesClient(subscriptionID, endpoint string, token *adal.ServicePrincipalToken) *azRegistriesClient {
- registryClient := containerregistry.NewRegistriesClient(subscriptionID)
- registryClient.BaseURI = endpoint
- registryClient.Authorizer = autorest.NewBearerAuthorizer(token)
-
- return &azRegistriesClient{
- client: registryClient,
- }
-}
-
-func (az *azRegistriesClient) List(ctx context.Context) ([]containerregistry.Registry, error) {
- iterator, err := az.client.ListComplete(ctx)
- if err != nil {
- return nil, err
- }
-
- result := make([]containerregistry.Registry, 0)
- for ; iterator.NotDone(); err = iterator.Next() {
- if err != nil {
- return nil, err
- }
-
- result = append(result, iterator.Value())
- }
-
- return result, nil
-}
-
-// NewACRProvider parses the specified configFile and returns a DockerConfigProvider
-func NewACRProvider(configFile *string) credentialprovider.DockerConfigProvider {
- return &acrProvider{
- file: configFile,
- cache: cache.NewExpirationStore(stringKeyFunc, &acrExpirationPolicy{}),
- }
-}
-
-type acrProvider struct {
- file *string
- config *auth.AzureAuthConfig
- environment *azure.Environment
- registryClient RegistriesClient
- servicePrincipalToken *adal.ServicePrincipalToken
- cache cache.Store
-}
-
-// ParseConfig returns a parsed configuration for an Azure cloudprovider config file
-func parseConfig(configReader io.Reader) (*auth.AzureAuthConfig, error) {
- var config auth.AzureAuthConfig
-
- if configReader == nil {
- return &config, nil
- }
-
- limitedReader := &io.LimitedReader{R: configReader, N: maxReadLength}
- configContents, err := ioutil.ReadAll(limitedReader)
- if err != nil {
- return nil, err
- }
- if limitedReader.N <= 0 {
- return nil, errors.New("the read limit is reached")
- }
- err = yaml.Unmarshal(configContents, &config)
- if err != nil {
- return nil, err
- }
-
- return &config, nil
-}
-
-func (a *acrProvider) loadConfig(rdr io.Reader) error {
- var err error
- a.config, err = parseConfig(rdr)
- if err != nil {
- klog.Errorf("Failed to load azure credential file: %v", err)
- }
-
- a.environment, err = auth.ParseAzureEnvironment(a.config.Cloud, a.config.ResourceManagerEndpoint, a.config.IdentitySystem)
- if err != nil {
- return err
- }
-
- return nil
-}
-
-func (a *acrProvider) Enabled() bool {
- if a.file == nil || len(*a.file) == 0 {
- klog.V(5).Infof("Azure config unspecified, disabling")
- return false
- }
-
- f, err := os.Open(*a.file)
- if err != nil {
- klog.Errorf("Failed to load config from file: %s", *a.file)
- return false
- }
- defer f.Close()
-
- err = a.loadConfig(f)
- if err != nil {
- klog.Errorf("Failed to load config from file: %s", *a.file)
- return false
- }
-
- a.servicePrincipalToken, err = auth.GetServicePrincipalToken(a.config, a.environment)
- if err != nil {
- klog.Errorf("Failed to create service principal token: %v", err)
- return false
- }
-
- a.registryClient = newAzRegistriesClient(a.config.SubscriptionID, a.environment.ResourceManagerEndpoint, a.servicePrincipalToken)
- return true
-}
-
-// getFromCache attempts to get credentials from the cache
-func (a *acrProvider) getFromCache(loginServer string) (credentialprovider.DockerConfig, bool) {
- cfg := credentialprovider.DockerConfig{}
- obj, exists, err := a.cache.GetByKey(loginServer)
- if err != nil {
- klog.Errorf("error getting ACR credentials from cache: %v", err)
- return cfg, false
- }
- if !exists {
- return cfg, false
- }
-
- entry := obj.(*cacheEntry)
- cfg[entry.registry] = entry.credentials
- return cfg, true
-}
-
-// getFromACR gets credentials from ACR since they are not in the cache
-func (a *acrProvider) getFromACR(loginServer string) (credentialprovider.DockerConfig, error) {
- cfg := credentialprovider.DockerConfig{}
- cred, err := getACRDockerEntryFromARMToken(a, loginServer)
- if err != nil {
- return cfg, err
- }
-
- entry := &cacheEntry{
- expiresAt: time.Now().Add(10 * time.Minute),
- credentials: *cred,
- registry: loginServer,
- }
- if err := a.cache.Add(entry); err != nil {
- return cfg, err
- }
- cfg[loginServer] = *cred
- return cfg, nil
-}
-
-func (a *acrProvider) Provide(image string) credentialprovider.DockerConfig {
- loginServer := a.parseACRLoginServerFromImage(image)
- if loginServer == "" {
- klog.V(2).Infof("image(%s) is not from ACR, return empty authentication", image)
- return credentialprovider.DockerConfig{}
- }
-
- cfg := credentialprovider.DockerConfig{}
- if a.config != nil && a.config.UseManagedIdentityExtension {
- var exists bool
- cfg, exists = a.getFromCache(loginServer)
- if exists {
- klog.V(4).Infof("Got ACR credentials from cache for %s", loginServer)
- } else {
- klog.V(2).Infof("unable to get ACR credentials from cache for %s, checking ACR API", loginServer)
- var err error
- cfg, err = a.getFromACR(loginServer)
- if err != nil {
- klog.Errorf("error getting credentials from ACR for %s %v", loginServer, err)
- }
- }
- } else {
- // Add our entry for each of the supported container registry URLs
- for _, url := range containerRegistryUrls {
- cred := &credentialprovider.DockerConfigEntry{
- Username: a.config.AADClientID,
- Password: a.config.AADClientSecret,
- Email: dummyRegistryEmail,
- }
- cfg[url] = *cred
- }
-
- // Handle the custom cloud case
- // In clouds where ACR is not yet deployed, the string will be empty
- if a.environment != nil && strings.Contains(a.environment.ContainerRegistryDNSSuffix, ".azurecr.") {
- customAcrSuffix := "*" + a.environment.ContainerRegistryDNSSuffix
- hasBeenAdded := false
- for _, url := range containerRegistryUrls {
- if strings.EqualFold(url, customAcrSuffix) {
- hasBeenAdded = true
- break
- }
- }
-
- if !hasBeenAdded {
- cred := &credentialprovider.DockerConfigEntry{
- Username: a.config.AADClientID,
- Password: a.config.AADClientSecret,
- Email: dummyRegistryEmail,
- }
- cfg[customAcrSuffix] = *cred
- }
- }
- }
-
- // add ACR anonymous repo support: use empty username and password for anonymous access
- defaultConfigEntry := credentialprovider.DockerConfigEntry{
- Username: "",
- Password: "",
- Email: dummyRegistryEmail,
- }
- cfg["*.azurecr.*"] = defaultConfigEntry
- return cfg
-}
-
-func getLoginServer(registry containerregistry.Registry) string {
- return *(*registry.RegistryProperties).LoginServer
-}
-
-func getACRDockerEntryFromARMToken(a *acrProvider, loginServer string) (*credentialprovider.DockerConfigEntry, error) {
- // Run EnsureFresh to make sure the token is valid and does not expire
- if err := a.servicePrincipalToken.EnsureFresh(); err != nil {
- klog.Errorf("Failed to ensure fresh service principal token: %v", err)
- return nil, err
- }
- armAccessToken := a.servicePrincipalToken.OAuthToken()
-
- klog.V(4).Infof("discovering auth redirects for: %s", loginServer)
- directive, err := receiveChallengeFromLoginServer(loginServer)
- if err != nil {
- klog.Errorf("failed to receive challenge: %s", err)
- return nil, err
- }
-
- klog.V(4).Infof("exchanging an acr refresh_token")
- registryRefreshToken, err := performTokenExchange(
- loginServer, directive, a.config.TenantID, armAccessToken)
- if err != nil {
- klog.Errorf("failed to perform token exchange: %s", err)
- return nil, err
- }
-
- klog.V(4).Infof("adding ACR docker config entry for: %s", loginServer)
- return &credentialprovider.DockerConfigEntry{
- Username: dockerTokenLoginUsernameGUID,
- Password: registryRefreshToken,
- Email: dummyRegistryEmail,
- }, nil
-}
-
-// parseACRLoginServerFromImage takes image as parameter and returns login server of it.
-// Parameter `image` is expected in following format: foo.azurecr.io/bar/imageName:version
-// If the provided image is not an acr image, this function will return an empty string.
-func (a *acrProvider) parseACRLoginServerFromImage(image string) string {
- match := acrRE.FindAllString(image, -1)
- if len(match) == 1 {
- return match[0]
- }
-
- // handle the custom cloud case
- if a != nil && a.environment != nil {
- cloudAcrSuffix := a.environment.ContainerRegistryDNSSuffix
- cloudAcrSuffixLength := len(cloudAcrSuffix)
- if cloudAcrSuffixLength > 0 {
- customAcrSuffixIndex := strings.Index(image, cloudAcrSuffix)
- if customAcrSuffixIndex != -1 {
- endIndex := customAcrSuffixIndex + cloudAcrSuffixLength
- return image[0:endIndex]
- }
- }
- }
-
- return ""
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/doc.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/doc.go
deleted file mode 100644
index b61f8a238db3..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/azure/doc.go
+++ /dev/null
@@ -1,17 +0,0 @@
-/*
-Copyright 2020 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package azure
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/config.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/config.go
deleted file mode 100644
index 00a5fa90608d..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/config.go
+++ /dev/null
@@ -1,329 +0,0 @@
-/*
-Copyright 2014 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package credentialprovider
-
-import (
- "encoding/base64"
- "encoding/json"
- "errors"
- "fmt"
- "io"
- "io/ioutil"
- "net/http"
- "os"
- "path/filepath"
- "strings"
- "sync"
-
- "k8s.io/klog/v2"
-)
-
-const (
- maxReadLength = 10 * 1 << 20 // 10MB
-)
-
-// DockerConfigJSON represents ~/.docker/config.json file info
-// see https://github.com/docker/docker/pull/12009
-type DockerConfigJSON struct {
- Auths DockerConfig `json:"auths"`
- // +optional
- HTTPHeaders map[string]string `json:"HttpHeaders,omitempty"`
-}
-
-// DockerConfig represents the config file used by the docker CLI.
-// This config that represents the credentials that should be used
-// when pulling images from specific image repositories.
-type DockerConfig map[string]DockerConfigEntry
-
-// DockerConfigEntry wraps a docker config as a entry
-type DockerConfigEntry struct {
- Username string
- Password string
- Email string
- Provider DockerConfigProvider
-}
-
-var (
- preferredPathLock sync.Mutex
- preferredPath = ""
- workingDirPath = ""
- homeDirPath, _ = os.UserHomeDir()
- rootDirPath = "/"
- homeJSONDirPath = filepath.Join(homeDirPath, ".docker")
- rootJSONDirPath = filepath.Join(rootDirPath, ".docker")
-
- configFileName = ".dockercfg"
- configJSONFileName = "config.json"
-)
-
-// SetPreferredDockercfgPath set preferred docker config path
-func SetPreferredDockercfgPath(path string) {
- preferredPathLock.Lock()
- defer preferredPathLock.Unlock()
- preferredPath = path
-}
-
-// GetPreferredDockercfgPath get preferred docker config path
-func GetPreferredDockercfgPath() string {
- preferredPathLock.Lock()
- defer preferredPathLock.Unlock()
- return preferredPath
-}
-
-//DefaultDockercfgPaths returns default search paths of .dockercfg
-func DefaultDockercfgPaths() []string {
- return []string{GetPreferredDockercfgPath(), workingDirPath, homeDirPath, rootDirPath}
-}
-
-//DefaultDockerConfigJSONPaths returns default search paths of .docker/config.json
-func DefaultDockerConfigJSONPaths() []string {
- return []string{GetPreferredDockercfgPath(), workingDirPath, homeJSONDirPath, rootJSONDirPath}
-}
-
-// ReadDockercfgFile attempts to read a legacy dockercfg file from the given paths.
-// if searchPaths is empty, the default paths are used.
-func ReadDockercfgFile(searchPaths []string) (cfg DockerConfig, err error) {
- if len(searchPaths) == 0 {
- searchPaths = DefaultDockercfgPaths()
- }
-
- for _, configPath := range searchPaths {
- absDockerConfigFileLocation, err := filepath.Abs(filepath.Join(configPath, configFileName))
- if err != nil {
- klog.Errorf("while trying to canonicalize %s: %v", configPath, err)
- continue
- }
- klog.V(4).Infof("looking for .dockercfg at %s", absDockerConfigFileLocation)
- contents, err := ioutil.ReadFile(absDockerConfigFileLocation)
- if os.IsNotExist(err) {
- continue
- }
- if err != nil {
- klog.V(4).Infof("while trying to read %s: %v", absDockerConfigFileLocation, err)
- continue
- }
- cfg, err := ReadDockerConfigFileFromBytes(contents)
- if err != nil {
- klog.V(4).Infof("couldn't get the config from %q contents: %v", absDockerConfigFileLocation, err)
- continue
- }
-
- klog.V(4).Infof("found .dockercfg at %s", absDockerConfigFileLocation)
- return cfg, nil
-
- }
- return nil, fmt.Errorf("couldn't find valid .dockercfg after checking in %v", searchPaths)
-}
-
-// ReadDockerConfigJSONFile attempts to read a docker config.json file from the given paths.
-// if searchPaths is empty, the default paths are used.
-func ReadDockerConfigJSONFile(searchPaths []string) (cfg DockerConfig, err error) {
- if len(searchPaths) == 0 {
- searchPaths = DefaultDockerConfigJSONPaths()
- }
- for _, configPath := range searchPaths {
- absDockerConfigFileLocation, err := filepath.Abs(filepath.Join(configPath, configJSONFileName))
- if err != nil {
- klog.Errorf("while trying to canonicalize %s: %v", configPath, err)
- continue
- }
- klog.V(4).Infof("looking for %s at %s", configJSONFileName, absDockerConfigFileLocation)
- cfg, err = ReadSpecificDockerConfigJSONFile(absDockerConfigFileLocation)
- if err != nil {
- if !os.IsNotExist(err) {
- klog.V(4).Infof("while trying to read %s: %v", absDockerConfigFileLocation, err)
- }
- continue
- }
- klog.V(4).Infof("found valid %s at %s", configJSONFileName, absDockerConfigFileLocation)
- return cfg, nil
- }
- return nil, fmt.Errorf("couldn't find valid %s after checking in %v", configJSONFileName, searchPaths)
-
-}
-
-//ReadSpecificDockerConfigJSONFile attempts to read docker configJSON from a given file path.
-func ReadSpecificDockerConfigJSONFile(filePath string) (cfg DockerConfig, err error) {
- var contents []byte
-
- if contents, err = ioutil.ReadFile(filePath); err != nil {
- return nil, err
- }
- return readDockerConfigJSONFileFromBytes(contents)
-}
-
-// ReadDockerConfigFile read a docker config file from default path
-func ReadDockerConfigFile() (cfg DockerConfig, err error) {
- if cfg, err := ReadDockerConfigJSONFile(nil); err == nil {
- return cfg, nil
- }
- // Can't find latest config file so check for the old one
- return ReadDockercfgFile(nil)
-}
-
-// HTTPError wraps a non-StatusOK error code as an error.
-type HTTPError struct {
- StatusCode int
- URL string
-}
-
-// Error implements error
-func (he *HTTPError) Error() string {
- return fmt.Sprintf("http status code: %d while fetching url %s",
- he.StatusCode, he.URL)
-}
-
-// ReadURL read contents from given url
-func ReadURL(url string, client *http.Client, header *http.Header) (body []byte, err error) {
- req, err := http.NewRequest("GET", url, nil)
- if err != nil {
- return nil, err
- }
- if header != nil {
- req.Header = *header
- }
- resp, err := client.Do(req)
- if err != nil {
- return nil, err
- }
- defer resp.Body.Close()
-
- if resp.StatusCode != http.StatusOK {
- klog.V(2).Infof("body of failing http response: %v", resp.Body)
- return nil, &HTTPError{
- StatusCode: resp.StatusCode,
- URL: url,
- }
- }
-
- limitedReader := &io.LimitedReader{R: resp.Body, N: maxReadLength}
- contents, err := ioutil.ReadAll(limitedReader)
- if err != nil {
- return nil, err
- }
-
- if limitedReader.N <= 0 {
- return nil, errors.New("the read limit is reached")
- }
-
- return contents, nil
-}
-
-// ReadDockerConfigFileFromURL read a docker config file from the given url
-func ReadDockerConfigFileFromURL(url string, client *http.Client, header *http.Header) (cfg DockerConfig, err error) {
- if contents, err := ReadURL(url, client, header); err == nil {
- return ReadDockerConfigFileFromBytes(contents)
- }
-
- return nil, err
-}
-
-// ReadDockerConfigFileFromBytes read a docker config file from the given bytes
-func ReadDockerConfigFileFromBytes(contents []byte) (cfg DockerConfig, err error) {
- if err = json.Unmarshal(contents, &cfg); err != nil {
- return nil, errors.New("error occurred while trying to unmarshal json")
- }
- return
-}
-
-func readDockerConfigJSONFileFromBytes(contents []byte) (cfg DockerConfig, err error) {
- var cfgJSON DockerConfigJSON
- if err = json.Unmarshal(contents, &cfgJSON); err != nil {
- return nil, errors.New("error occurred while trying to unmarshal json")
- }
- cfg = cfgJSON.Auths
- return
-}
-
-// dockerConfigEntryWithAuth is used solely for deserializing the Auth field
-// into a dockerConfigEntry during JSON deserialization.
-type dockerConfigEntryWithAuth struct {
- // +optional
- Username string `json:"username,omitempty"`
- // +optional
- Password string `json:"password,omitempty"`
- // +optional
- Email string `json:"email,omitempty"`
- // +optional
- Auth string `json:"auth,omitempty"`
-}
-
-// UnmarshalJSON implements the json.Unmarshaler interface.
-func (ident *DockerConfigEntry) UnmarshalJSON(data []byte) error {
- var tmp dockerConfigEntryWithAuth
- err := json.Unmarshal(data, &tmp)
- if err != nil {
- return err
- }
-
- ident.Username = tmp.Username
- ident.Password = tmp.Password
- ident.Email = tmp.Email
-
- if len(tmp.Auth) == 0 {
- return nil
- }
-
- ident.Username, ident.Password, err = decodeDockerConfigFieldAuth(tmp.Auth)
- return err
-}
-
-// MarshalJSON implements the json.Marshaler interface.
-func (ident DockerConfigEntry) MarshalJSON() ([]byte, error) {
- toEncode := dockerConfigEntryWithAuth{ident.Username, ident.Password, ident.Email, ""}
- toEncode.Auth = encodeDockerConfigFieldAuth(ident.Username, ident.Password)
-
- return json.Marshal(toEncode)
-}
-
-// decodeDockerConfigFieldAuth deserializes the "auth" field from dockercfg into a
-// username and a password. The format of the auth field is base64(:).
-func decodeDockerConfigFieldAuth(field string) (username, password string, err error) {
-
- var decoded []byte
-
- // StdEncoding can only decode padded string
- // RawStdEncoding can only decode unpadded string
- if strings.HasSuffix(strings.TrimSpace(field), "=") {
- // decode padded data
- decoded, err = base64.StdEncoding.DecodeString(field)
- } else {
- // decode unpadded data
- decoded, err = base64.RawStdEncoding.DecodeString(field)
- }
-
- if err != nil {
- return
- }
-
- parts := strings.SplitN(string(decoded), ":", 2)
- if len(parts) != 2 {
- err = fmt.Errorf("unable to parse auth field, must be formatted as base64(username:password)")
- return
- }
-
- username = parts[0]
- password = parts[1]
-
- return
-}
-
-func encodeDockerConfigFieldAuth(username, password string) string {
- fieldValue := username + ":" + password
-
- return base64.StdEncoding.EncodeToString([]byte(fieldValue))
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/doc.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/doc.go
deleted file mode 100644
index b6ba09072916..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/doc.go
+++ /dev/null
@@ -1,19 +0,0 @@
-/*
-Copyright 2014 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-// Package credentialprovider supplies interfaces and implementations for
-// docker registry providers to expose their authentication scheme.
-package credentialprovider // import "github.com/vdemeester/k8s-pkg-credentialprovider"
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/gcp/doc.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/gcp/doc.go
deleted file mode 100644
index 6e825a8b3995..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/gcp/doc.go
+++ /dev/null
@@ -1,19 +0,0 @@
-/*
-Copyright 2014 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-// Package gcp contains implementations of DockerConfigProvider
-// for Google Cloud Platform.
-package gcp // import "github.com/vdemeester/k8s-pkg-credentialprovider/gcp"
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/gcp/metadata.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/gcp/metadata.go
deleted file mode 100644
index adff12975bc9..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/gcp/metadata.go
+++ /dev/null
@@ -1,253 +0,0 @@
-/*
-Copyright 2014 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package gcp
-
-import (
- "encoding/json"
- "io/ioutil"
- "net/http"
- "os/exec"
- "runtime"
- "strings"
- "time"
-
- utilnet "k8s.io/apimachinery/pkg/util/net"
- "k8s.io/cloud-provider/credentialconfig"
- "k8s.io/klog/v2"
- "github.com/vdemeester/k8s-pkg-credentialprovider"
- "k8s.io/legacy-cloud-providers/gce/gcpcredential"
-)
-
-const (
- metadataURL = "http://metadata.google.internal./computeMetadata/v1/"
- metadataAttributes = metadataURL + "instance/attributes/"
- // DockerConfigKey is the URL of the dockercfg metadata key used by DockerConfigKeyProvider.
- DockerConfigKey = metadataAttributes + "google-dockercfg"
- // DockerConfigURLKey is the URL of the dockercfg metadata key used by DockerConfigURLKeyProvider.
- DockerConfigURLKey = metadataAttributes + "google-dockercfg-url"
- serviceAccounts = metadataURL + "instance/service-accounts/"
- metadataScopes = metadataURL + "instance/service-accounts/default/scopes"
- metadataToken = metadataURL + "instance/service-accounts/default/token"
- metadataEmail = metadataURL + "instance/service-accounts/default/email"
- // StorageScopePrefix is the prefix checked by ContainerRegistryProvider.Enabled.
- StorageScopePrefix = "https://www.googleapis.com/auth/devstorage"
- cloudPlatformScopePrefix = "https://www.googleapis.com/auth/cloud-platform"
- defaultServiceAccount = "default/"
-)
-
-// gceProductNameFile is the product file path that contains the cloud service name.
-// This is a variable instead of a const to enable testing.
-var gceProductNameFile = "/sys/class/dmi/id/product_name"
-
-var metadataHeader = &http.Header{
- "Metadata-Flavor": []string{"Google"},
-}
-
-// init registers the various means by which credentials may
-// be resolved on GCP.
-func init() {
- tr := utilnet.SetTransportDefaults(&http.Transport{})
- metadataHTTPClientTimeout := time.Second * 10
- httpClient := &http.Client{
- Transport: tr,
- Timeout: metadataHTTPClientTimeout,
- }
- credentialprovider.RegisterCredentialProvider("google-dockercfg",
- &credentialprovider.CachingDockerConfigProvider{
- Provider: &DockerConfigKeyProvider{
- MetadataProvider: MetadataProvider{Client: httpClient},
- },
- Lifetime: 60 * time.Second,
- })
-
- credentialprovider.RegisterCredentialProvider("google-dockercfg-url",
- &credentialprovider.CachingDockerConfigProvider{
- Provider: &DockerConfigURLKeyProvider{
- MetadataProvider: MetadataProvider{Client: httpClient},
- },
- Lifetime: 60 * time.Second,
- })
-
- credentialprovider.RegisterCredentialProvider("google-container-registry",
- // Never cache this. The access token is already
- // cached by the metadata service.
- &ContainerRegistryProvider{
- MetadataProvider: MetadataProvider{Client: httpClient},
- })
-}
-
-// MetadataProvider is a DockerConfigProvider that reads its configuration from Google
-// Compute Engine metadata.
-type MetadataProvider struct {
- Client *http.Client
-}
-
-// DockerConfigKeyProvider is a DockerConfigProvider that reads its configuration from a specific
-// Google Compute Engine metadata key: 'google-dockercfg'.
-type DockerConfigKeyProvider struct {
- MetadataProvider
-}
-
-// DockerConfigURLKeyProvider is a DockerConfigProvider that reads its configuration from a URL read from
-// a specific Google Compute Engine metadata key: 'google-dockercfg-url'.
-type DockerConfigURLKeyProvider struct {
- MetadataProvider
-}
-
-// ContainerRegistryProvider is a DockerConfigProvider that provides a dockercfg with:
-// Username: "_token"
-// Password: "{access token from metadata}"
-type ContainerRegistryProvider struct {
- MetadataProvider
-}
-
-// Returns true if it finds a local GCE VM.
-// Looks at a product file that is an undocumented API.
-func onGCEVM() bool {
- var name string
-
- if runtime.GOOS == "windows" {
- data, err := exec.Command("wmic", "computersystem", "get", "model").Output()
- if err != nil {
- return false
- }
- fields := strings.Split(strings.TrimSpace(string(data)), "\r\n")
- if len(fields) != 2 {
- klog.V(2).Infof("Received unexpected value retrieving system model: %q", string(data))
- return false
- }
- name = fields[1]
- } else {
- data, err := ioutil.ReadFile(gceProductNameFile)
- if err != nil {
- klog.V(2).Infof("Error while reading product_name: %v", err)
- return false
- }
- name = strings.TrimSpace(string(data))
- }
- return name == "Google" || name == "Google Compute Engine"
-}
-
-// Enabled implements DockerConfigProvider for all of the Google implementations.
-func (g *MetadataProvider) Enabled() bool {
- return onGCEVM()
-}
-
-// Provide implements DockerConfigProvider
-func (g *DockerConfigKeyProvider) Provide(image string) credentialprovider.DockerConfig {
- return registryToDocker(gcpcredential.ProvideConfigKey(g.Client, image))
-}
-
-// Provide implements DockerConfigProvider
-func (g *DockerConfigURLKeyProvider) Provide(image string) credentialprovider.DockerConfig {
- return registryToDocker(gcpcredential.ProvideURLKey(g.Client, image))
-}
-
-// runWithBackoff runs input function `f` with an exponential backoff.
-// Note that this method can block indefinitely.
-func runWithBackoff(f func() ([]byte, error)) []byte {
- var backoff = 100 * time.Millisecond
- const maxBackoff = time.Minute
- for {
- value, err := f()
- if err == nil {
- return value
- }
- time.Sleep(backoff)
- backoff = backoff * 2
- if backoff > maxBackoff {
- backoff = maxBackoff
- }
- }
-}
-
-// Enabled implements a special metadata-based check, which verifies the
-// storage scope is available on the GCE VM.
-// If running on a GCE VM, check if 'default' service account exists.
-// If it does not exist, assume that registry is not enabled.
-// If default service account exists, check if relevant scopes exist in the default service account.
-// The metadata service can become temporarily inaccesible. Hence all requests to the metadata
-// service will be retried until the metadata server returns a `200`.
-// It is expected that "http://metadata.google.internal./computeMetadata/v1/instance/service-accounts/" will return a `200`
-// and "http://metadata.google.internal./computeMetadata/v1/instance/service-accounts/default/scopes" will also return `200`.
-// More information on metadata service can be found here - https://cloud.google.com/compute/docs/storing-retrieving-metadata
-func (g *ContainerRegistryProvider) Enabled() bool {
- if !onGCEVM() {
- return false
- }
- // Given that we are on GCE, we should keep retrying until the metadata server responds.
- value := runWithBackoff(func() ([]byte, error) {
- value, err := gcpcredential.ReadURL(serviceAccounts, g.Client, metadataHeader)
- if err != nil {
- klog.V(2).Infof("Failed to Get service accounts from gce metadata server: %v", err)
- }
- return value, err
- })
- // We expect the service account to return a list of account directories separated by newlines, e.g.,
- // sv-account-name1/
- // sv-account-name2/
- // ref: https://cloud.google.com/compute/docs/storing-retrieving-metadata
- defaultServiceAccountExists := false
- for _, sa := range strings.Split(string(value), "\n") {
- if strings.TrimSpace(sa) == defaultServiceAccount {
- defaultServiceAccountExists = true
- break
- }
- }
- if !defaultServiceAccountExists {
- klog.V(2).Infof("'default' service account does not exist. Found following service accounts: %q", string(value))
- return false
- }
- url := metadataScopes + "?alt=json"
- value = runWithBackoff(func() ([]byte, error) {
- value, err := gcpcredential.ReadURL(url, g.Client, metadataHeader)
- if err != nil {
- klog.V(2).Infof("Failed to Get scopes in default service account from gce metadata server: %v", err)
- }
- return value, err
- })
- var scopes []string
- if err := json.Unmarshal(value, &scopes); err != nil {
- klog.Errorf("Failed to unmarshal scopes: %v", err)
- return false
- }
- for _, v := range scopes {
- // cloudPlatformScope implies storage scope.
- if strings.HasPrefix(v, StorageScopePrefix) || strings.HasPrefix(v, cloudPlatformScopePrefix) {
- return true
- }
- }
- klog.Warningf("Google container registry is disabled, no storage scope is available: %s", value)
- return false
-}
-
-// Provide implements DockerConfigProvider
-func (g *ContainerRegistryProvider) Provide(image string) credentialprovider.DockerConfig {
- return registryToDocker(gcpcredential.ProvideContainerRegistry(g.Client, image))
-}
-
-func registryToDocker(registryConfig credentialconfig.RegistryConfig) credentialprovider.DockerConfig {
- dockerConfig := credentialprovider.DockerConfig{}
- for k, v := range registryConfig {
- dockerConfig[k] = credentialprovider.DockerConfigEntry{
- Username: v.Username,
- Password: v.Password,
- Email: v.Email,
- }
- }
- return dockerConfig
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/go.mod b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/go.mod
deleted file mode 100644
index 3826b98eb26e..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/go.mod
+++ /dev/null
@@ -1,22 +0,0 @@
-module github.com/vdemeester/k8s-pkg-credentialprovider
-
-go 1.15
-
-require (
- github.com/Azure/azure-sdk-for-go v43.0.0+incompatible
- github.com/Azure/go-autorest/autorest v0.11.12
- github.com/Azure/go-autorest/autorest/adal v0.9.5
- github.com/Azure/go-autorest/autorest/to v0.3.0
- github.com/aws/aws-sdk-go v1.35.24
- github.com/spf13/pflag v1.0.5
- github.com/stretchr/testify v1.6.1
- golang.org/x/oauth2 v0.0.0-20210427180440-81ed05c6b58c // indirect
- k8s.io/api v0.21.0
- k8s.io/apimachinery v0.21.0
- k8s.io/client-go v0.21.0
- k8s.io/cloud-provider v0.21.0
- k8s.io/component-base v0.21.0
- k8s.io/klog/v2 v2.8.0
- k8s.io/legacy-cloud-providers v0.21.0
- sigs.k8s.io/yaml v1.2.0
-)
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/go.sum b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/go.sum
deleted file mode 100644
index 7397df1c70db..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/go.sum
+++ /dev/null
@@ -1,755 +0,0 @@
-cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
-cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
-cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU=
-cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU=
-cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
-cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc=
-cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0=
-cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To=
-cloud.google.com/go v0.51.0/go.mod h1:hWtGJ6gnXH+KgDv+V0zFGDvpi07n3z8ZNj3T1RW0Gcw=
-cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4=
-cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M=
-cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc=
-cloud.google.com/go v0.56.0/go.mod h1:jr7tqZxxKOVYizybht9+26Z/gUq7tiRzu+ACVAMbKVk=
-cloud.google.com/go v0.57.0/go.mod h1:oXiQ6Rzq3RAkkY7N6t3TcE6jE+CIBBbA36lwQ1JyzZs=
-cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOYc=
-cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY=
-cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o=
-cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE=
-cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc=
-cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg=
-cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc=
-cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ=
-cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE=
-cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk=
-cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk=
-cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I=
-cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw=
-cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA=
-cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU=
-cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw=
-cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos=
-cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk=
-cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs=
-cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0=
-dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
-github.com/Azure/azure-sdk-for-go v43.0.0+incompatible h1:/wSNCu0e6EsHFR4Qa3vBEBbicaprEHMyyga9g8RTULI=
-github.com/Azure/azure-sdk-for-go v43.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
-github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
-github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
-github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
-github.com/Azure/go-autorest/autorest v0.9.0/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+BFDTQ8rEZB0s4Yfa6bI=
-github.com/Azure/go-autorest/autorest v0.11.12 h1:gI8ytXbxMfI+IVbI9mP2JGCTXIuhHLgRlvQ9X4PsnHE=
-github.com/Azure/go-autorest/autorest v0.11.12/go.mod h1:eipySxLmqSyC5s5k1CLupqet0PSENBEDP93LQ9a8QYw=
-github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEgQTmVqjGhiHBW7RJJEciWzS0=
-github.com/Azure/go-autorest/autorest/adal v0.9.5 h1:Y3bBUV4rTuxenJJs41HU3qmqsb+auo+a3Lz+PlJPpL0=
-github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
-github.com/Azure/go-autorest/autorest/date v0.1.0/go.mod h1:plvfp3oPSKwf2DNjlBjWF/7vwR+cUD/ELuzDCXwHUVA=
-github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
-github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
-github.com/Azure/go-autorest/autorest/mocks v0.1.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0=
-github.com/Azure/go-autorest/autorest/mocks v0.2.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0=
-github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
-github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
-github.com/Azure/go-autorest/autorest/to v0.2.0/go.mod h1:GunWKJp1AEqgMaGLV+iocmRAJWqST1wQYhyyjXJ3SJc=
-github.com/Azure/go-autorest/autorest/to v0.3.0 h1:zebkZaadz7+wIQYgC7GXaz3Wb28yKYfVkkBKwc38VF8=
-github.com/Azure/go-autorest/autorest/to v0.3.0/go.mod h1:MgwOyqaIuKdG4TL/2ywSsIWKAfJfgHDo8ObuUk3t5sA=
-github.com/Azure/go-autorest/autorest/validation v0.1.0 h1:ISSNzGUh+ZSzizJWOWzs8bwpXIePbGLW4z/AmUFGH5A=
-github.com/Azure/go-autorest/autorest/validation v0.1.0/go.mod h1:Ha3z/SqBeaalWQvokg3NZAlQTalVMtOIAs1aGK7G6u8=
-github.com/Azure/go-autorest/logger v0.1.0/go.mod h1:oExouG+K6PryycPJfVSxi/koC6LSNgds39diKLz7Vrc=
-github.com/Azure/go-autorest/logger v0.2.0 h1:e4RVHVZKC5p6UANLJHkM4OfR1UKZPj8Wt8Pcx+3oqrE=
-github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
-github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbtp2fGCgRFtBroKn4Dk=
-github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
-github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
-github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
-github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
-github.com/GoogleCloudPlatform/k8s-cloud-provider v0.0.0-20200415212048-7901bc822317/go.mod h1:DF8FZRxMHMGv/vP2lQP6h+dYzzjpuRn24VeRiYn3qjQ=
-github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ=
-github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c=
-github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU=
-github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0=
-github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE=
-github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc=
-github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc=
-github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
-github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
-github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o=
-github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY=
-github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
-github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY=
-github.com/aws/aws-sdk-go v1.35.24 h1:U3GNTg8+7xSM6OAJ8zksiSM4bRqxBWmVwwehvOSNG3A=
-github.com/aws/aws-sdk-go v1.35.24/go.mod h1:tlPOdRjfxPBpNIwqDj61rmsnA85v9jc0Ps9+muhnW+k=
-github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
-github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
-github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
-github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs=
-github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84=
-github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
-github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
-github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc=
-github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
-github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
-github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
-github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
-github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
-github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc=
-github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8=
-github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
-github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
-github.com/coreos/go-oidc v2.1.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc=
-github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
-github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
-github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
-github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
-github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
-github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
-github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
-github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY=
-github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
-github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
-github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
-github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
-github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
-github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
-github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
-github.com/dnaeon/go-vcr v1.0.1/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E=
-github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE=
-github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
-github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
-github.com/elazarl/goproxy v0.0.0-20180725130230-947c36da3153/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc=
-github.com/emicklei/go-restful v0.0.0-20170410110728-ff4f55a20633/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs=
-github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs=
-github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
-github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
-github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98=
-github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
-github.com/evanphx/json-patch v4.9.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk=
-github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
-github.com/form3tech-oss/jwt-go v3.2.2+incompatible h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=
-github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
-github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
-github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
-github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
-github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
-github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
-github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
-github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
-github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
-github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
-github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas=
-github.com/go-logr/logr v0.4.0 h1:K7/B1jt6fIBQVd4Owv2MqGQClcgf0R266+7C/QjRcLc=
-github.com/go-logr/logr v0.4.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
-github.com/go-openapi/jsonpointer v0.19.2/go.mod h1:3akKfEdA7DF1sugOqz1dVQHBcuDBPKZGEoHC/NkiQRg=
-github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
-github.com/go-openapi/jsonreference v0.19.2/go.mod h1:jMjeRr2HHw6nAVajTXJ4eiUwohSTlpa0o73RUL1owJc=
-github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL98+wF9xc8zWvFonSJ8=
-github.com/go-openapi/spec v0.19.3/go.mod h1:FpwSN1ksY1eteniUU7X0N/BgJ7a4WvBFVA8Lj9mJglo=
-github.com/go-openapi/spec v0.19.5/go.mod h1:Hm2Jr4jv8G1ciIAo+frC/Ft+rR2kQDh8JHKHb3gWUSk=
-github.com/go-openapi/swag v0.19.2/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
-github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
-github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
-github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ=
-github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4=
-github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q=
-github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
-github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
-github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
-github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
-github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
-github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
-github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e h1:1r7pUrabqp18hOBcwBwiTsbnFeTZHV9eER/QT5JVZxY=
-github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
-github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
-github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
-github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y=
-github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
-github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
-github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
-github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4=
-github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
-github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
-github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
-github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
-github.com/golang/protobuf v1.3.4/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
-github.com/golang/protobuf v1.3.5/go.mod h1:6O5/vntMXwX2lRkT1hjjk0nAC1IDOTvTlVgjlRvqsdk=
-github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8=
-github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA=
-github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs=
-github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w=
-github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0=
-github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8=
-github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI=
-github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM=
-github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI=
-github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
-github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
-github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
-github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
-github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
-github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
-github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
-github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
-github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
-github.com/google/go-cmp v0.5.2 h1:X2ev0eStA3AbceY54o37/0PQ/UWqKEiiO2dKL5OPaFM=
-github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
-github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
-github.com/google/gofuzz v1.1.0 h1:Hsa8mG0dQ46ij8Sl2AYJDUv1oA9/d6Vk+3LG99Oe02g=
-github.com/google/gofuzz v1.1.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
-github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs=
-github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0=
-github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
-github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
-github.com/google/pprof v0.0.0-20191218002539-d4f498aebedc/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
-github.com/google/pprof v0.0.0-20200212024743-f11f1df84d12/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
-github.com/google/pprof v0.0.0-20200229191704-1ebb73c60ed3/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
-github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
-github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
-github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
-github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
-github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
-github.com/google/uuid v1.1.2 h1:EVhdT+1Kseyi1/pUmXKaFxYsDNy9RQYkMWRH68J/W7Y=
-github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
-github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
-github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
-github.com/googleapis/gnostic v0.4.1/go.mod h1:LRhVm6pbyptWbWbuZ38d1eyptfvIytN3ir6b65WBswg=
-github.com/gophercloud/gophercloud v0.1.0/go.mod h1:vxM41WHh5uqHVBMZHzuwNOHh8XEoIEcSTewFxm1c5g8=
-github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
-github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
-github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE=
-github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA=
-github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
-github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
-github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk=
-github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
-github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
-github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q=
-github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8=
-github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
-github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
-github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
-github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM=
-github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk=
-github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU=
-github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU=
-github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4=
-github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
-github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
-github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90=
-github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
-github.com/hashicorp/golang-lru v0.5.1 h1:0hERBMJE1eitiLkihrMvRVBYAkpHzc/J3QdDN+dAcgU=
-github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
-github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
-github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64=
-github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ=
-github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I=
-github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc=
-github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
-github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
-github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
-github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
-github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg=
-github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
-github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8=
-github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U=
-github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo=
-github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
-github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
-github.com/json-iterator/go v1.1.10 h1:Kz6Cvnvv2wGdaG/V8yMvfkmNiXq9Ya2KUv4rouJJr68=
-github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
-github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU=
-github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk=
-github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
-github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w=
-github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q=
-github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8=
-github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
-github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
-github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc=
-github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
-github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
-github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
-github.com/kr/pty v1.1.5/go.mod h1:9r2w37qlBe7rQ6e1fg1S/9xpWHSnaqNdHD3WcMdbPDA=
-github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
-github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
-github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
-github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
-github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
-github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
-github.com/mailru/easyjson v0.7.0/go.mod h1:KAzv3t3aY1NaHWoQz1+4F1ccyAH66Jk7yos7ldAVICs=
-github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
-github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
-github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
-github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU=
-github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
-github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4=
-github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg=
-github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc=
-github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
-github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
-github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI=
-github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg=
-github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY=
-github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
-github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
-github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c=
-github.com/moby/term v0.0.0-20201216013528-df9cb8a40635/go.mod h1:FBS0z0QWA44HXygs7VXDUOGoN/1TV3RuWkLO04am3wc=
-github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
-github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=
-github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q=
-github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
-github.com/modern-go/reflect2 v1.0.1 h1:9f412s+6RmYXLWZSEzVVgPGK7C2PphHj5RJrvfx9AWI=
-github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
-github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
-github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
-github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
-github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw=
-github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e h1:fD57ERR4JtEqsWbfPhv4DMiApHyliiK5xCTNVSPiaAs=
-github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno=
-github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U=
-github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo=
-github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
-github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
-github.com/onsi/ginkgo v1.11.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
-github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
-github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
-github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
-github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
-github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU=
-github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
-github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
-github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
-github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
-github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
-github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
-github.com/pquerna/cachecontrol v0.0.0-20171018203845-0dec1b30a021/go.mod h1:prYjPmNq4d1NPVmpShWobRqXY3q7Vp+80DqgxxUrUIA=
-github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
-github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso=
-github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo=
-github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M=
-github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
-github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
-github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
-github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
-github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro=
-github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
-github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
-github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo=
-github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
-github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
-github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
-github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU=
-github.com/prometheus/procfs v0.2.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU=
-github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU=
-github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg=
-github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
-github.com/rubiojr/go-vhd v0.0.0-20200706105327-02e210299021/go.mod h1:DM5xW0nvfNNm2uytzsvhI3OnX8uzaRAg8UX/CnDqbto=
-github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
-github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
-github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
-github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
-github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
-github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
-github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE=
-github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0=
-github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc=
-github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
-github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
-github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
-github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
-github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
-github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
-github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
-github.com/spf13/cobra v1.1.1/go.mod h1:WnodtKOvamDL/PwE2M4iKs8aMDBZ5Q5klgD3qfVJQMI=
-github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
-github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
-github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
-github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
-github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
-github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
-github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg=
-github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
-github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
-github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE=
-github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
-github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
-github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
-github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0=
-github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
-github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw=
-github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
-github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
-github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
-github.com/vmware/govmomi v0.20.3/go.mod h1:URlwyTFZX72RmxtxuaFL2Uj3fD1JTvZdx59bHWk6aFU=
-github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
-github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
-github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
-github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
-github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
-go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
-go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
-go.etcd.io/bbolt v1.3.5/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ=
-go.etcd.io/etcd v0.5.0-alpha.5.0.20200910180754-dd1b699fc489/go.mod h1:yVHk9ub3CSBatqGNg7GRmsnfLWtoW60w4eDYfh7vHDg=
-go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
-go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
-go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
-go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
-go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
-go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
-go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
-go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0=
-go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q=
-golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
-golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
-golang.org/x/crypto v0.0.0-20190211182817-74369b46fc67/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
-golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
-golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
-golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
-golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
-golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
-golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
-golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
-golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83 h1:/ZScEX8SfEmUGRHs0gxpqteO5nfNW6axyZbBdw9A12g=
-golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
-golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
-golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
-golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
-golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek=
-golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY=
-golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
-golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
-golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
-golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM=
-golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
-golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
-golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
-golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
-golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
-golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
-golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
-golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
-golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
-golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
-golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRuDixDT3tpyyb+LUpUlRWLxfhWrs=
-golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
-golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
-golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE=
-golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o=
-golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc=
-golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
-golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
-golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
-golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
-golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
-golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20181201002055-351d144fa1fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
-golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
-golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
-golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
-golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
-golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
-golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20200222125558-5a598a2470a0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20200301022130-244492dfa37a/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
-golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
-golang.org/x/net v0.0.0-20200501053045-e0ff5e5a1de5/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
-golang.org/x/net v0.0.0-20200506145744-7e3656a0809f/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
-golang.org/x/net v0.0.0-20200513185701-a91f0712d120/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
-golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
-golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
-golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
-golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA=
-golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
-golang.org/x/net v0.0.0-20210224082022-3d97a244fca7 h1:OgUuv8lsRpBibGNbSizVwKWlysjaNzmC9gYMhPVfqFM=
-golang.org/x/net v0.0.0-20210224082022-3d97a244fca7/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
-golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
-golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
-golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
-golang.org/x/oauth2 v0.0.0-20191202225959-858c2ad4c8b6/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
-golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
-golang.org/x/oauth2 v0.0.0-20210427180440-81ed05c6b58c h1:SgVl/sCtkicsS7psKkje4H9YtjdEl3xsYh7N+5TDHqY=
-golang.org/x/oauth2 v0.0.0-20210427180440-81ed05c6b58c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A=
-golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
-golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190209173611-3b5209105503/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200302150141-5c8b2ff67527/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200831180312-196b9ba8737a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073 h1:8qxJSnu+7dRq6upnbntrmriWByIakBuct5OM/MdQC1M=
-golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
-golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
-golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d h1:SZxvLBoTP5yHO3Frd4z4vrF+DBX9vMVanchswa69toE=
-golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
-golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
-golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
-golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
-golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
-golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
-golang.org/x/text v0.3.4 h1:0YWbFKbhXG/wIiuHDSKpS0Iy7FSA+u45VtBMfQcFTTc=
-golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
-golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
-golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
-golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
-golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
-golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba h1:O8mE0/t419eoIwhTFpKVkHiTs/Igowgfkj25AcZrtiE=
-golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
-golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
-golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
-golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
-golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY=
-golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
-golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
-golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
-golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
-golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
-golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
-golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
-golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
-golang.org/x/tools v0.0.0-20190614205625-5aca471b1d59/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
-golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
-golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
-golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
-golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191112195655-aa38f8e97acc/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191125144606-a911d9008d1f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200227222343-706bc42d1f0d/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
-golang.org/x/tools v0.0.0-20200304193943-95d2e580d8eb/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw=
-golang.org/x/tools v0.0.0-20200312045724-11d5b4c81c7d/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw=
-golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8=
-golang.org/x/tools v0.0.0-20200501065659-ab2804fb9c9d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
-golang.org/x/tools v0.0.0-20200512131952-2bc93b1c0c88/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
-golang.org/x/tools v0.0.0-20200515010526-7d3b6ebf133d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
-golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
-golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
-golang.org/x/tools v0.0.0-20200729194436-6467de6f59a7/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
-golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
-golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA=
-golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
-golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
-golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
-golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
-golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE=
-golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
-google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE=
-google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M=
-google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg=
-google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg=
-google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
-google.golang.org/api v0.14.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
-google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
-google.golang.org/api v0.15.1-0.20200106000736-b8fc810ca6b5/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI=
-google.golang.org/api v0.17.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
-google.golang.org/api v0.18.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
-google.golang.org/api v0.19.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
-google.golang.org/api v0.20.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
-google.golang.org/api v0.22.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE=
-google.golang.org/api v0.24.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE=
-google.golang.org/api v0.28.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE=
-google.golang.org/api v0.29.0/go.mod h1:Lcubydp8VUV7KeIHD9z2Bys/sm/vGKnG1UHuDBSrHWM=
-google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz5138Fc=
-google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
-google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
-google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
-google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0=
-google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
-google.golang.org/appengine v1.6.6 h1:lMO5rYAqUxkmaj76jAkRUvt5JZgFymx/+Q5Mzfivuhc=
-google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
-google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
-google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
-google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
-google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
-google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
-google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
-google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
-google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8=
-google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
-google.golang.org/genproto v0.0.0-20191115194625-c23dd37a84c9/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
-google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
-google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
-google.golang.org/genproto v0.0.0-20200115191322-ca5a22157cba/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
-google.golang.org/genproto v0.0.0-20200122232147-0452cf42e150/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc=
-google.golang.org/genproto v0.0.0-20200204135345-fa8e72b47b90/go.mod h1:GmwEX6Z4W5gMy59cAlVYjN9JhxgbQH6Gn+gFDQe2lzA=
-google.golang.org/genproto v0.0.0-20200212174721-66ed5ce911ce/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
-google.golang.org/genproto v0.0.0-20200224152610-e50cd9704f63/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
-google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
-google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
-google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
-google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
-google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
-google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
-google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U=
-google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo=
-google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA=
-google.golang.org/genproto v0.0.0-20200729003335-053ba62fc06f/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
-google.golang.org/genproto v0.0.0-20200804131852-c06518451d9c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
-google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
-google.golang.org/genproto v0.0.0-20201110150050-8816d57aaa9a/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
-google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
-google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
-google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
-google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
-google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY=
-google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
-google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
-google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
-google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60=
-google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk=
-google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
-google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
-google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
-google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0=
-google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM=
-google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE=
-google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo=
-google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
-google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
-google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
-google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGjtUeSXeh4=
-google.golang.org/protobuf v1.25.0 h1:Ejskq+SyPohKW+1uil0JJMtmHCgJPJ/qWTxr8qp+R4c=
-google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c=
-gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
-gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
-gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
-gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
-gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f h1:BLraFXnmrev5lT+xlilqcH8XK9/i0At2xKjWk4p6zsU=
-gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
-gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw=
-gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
-gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
-gopkg.in/gcfg.v1 v1.2.0/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o=
-gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc=
-gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
-gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
-gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k=
-gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo=
-gopkg.in/square/go-jose.v2 v2.2.2/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
-gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
-gopkg.in/warnings.v0 v0.1.1/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI=
-gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74=
-gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
-gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
-gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
-gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
-gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
-gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=
-gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
-gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo=
-gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
-gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk=
-gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8=
-honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
-honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
-honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
-honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
-honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
-honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
-honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
-k8s.io/api v0.21.0 h1:gu5iGF4V6tfVCQ/R+8Hc0h7H1JuEhzyEi9S4R5LM8+Y=
-k8s.io/api v0.21.0/go.mod h1:+YbrhBBGgsxbF6o6Kj4KJPJnBmAKuXDeS3E18bgHNVU=
-k8s.io/apimachinery v0.21.0 h1:3Fx+41if+IRavNcKOz09FwEXDBG6ORh6iMsTSelhkMA=
-k8s.io/apimachinery v0.21.0/go.mod h1:jbreFvJo3ov9rj7eWT7+sYiRx+qZuCYXwWT1bcDswPY=
-k8s.io/apiserver v0.21.0/go.mod h1:w2YSn4/WIwYuxG5zJmcqtRdtqgW/J2JRgFAqps3bBpg=
-k8s.io/client-go v0.21.0 h1:n0zzzJsAQmJngpC0IhgFcApZyoGXPrDIAD601HD09ag=
-k8s.io/client-go v0.21.0/go.mod h1:nNBytTF9qPFDEhoqgEPaarobC8QPae13bElIVHzIglA=
-k8s.io/cloud-provider v0.21.0 h1:NSTS+czpv6LQAaIpY/VUghsT4oj62hYmQPErkDKTzKU=
-k8s.io/cloud-provider v0.21.0/go.mod h1:z17TQgu3JgUFjcgby8sj5X86YdVK5Pbt+jm/eYMZU9M=
-k8s.io/component-base v0.21.0 h1:tLLGp4BBjQaCpS/KiuWh7m2xqvAdsxLm4ATxHSe5Zpg=
-k8s.io/component-base v0.21.0/go.mod h1:qvtjz6X0USWXbgmbfXR+Agik4RZ3jv2Bgr5QnZzdPYw=
-k8s.io/controller-manager v0.21.0/go.mod h1:Ohy0GRNRKPVjB8C8G+dV+4aPn26m8HYUI6ejloUBvUA=
-k8s.io/csi-translation-lib v0.21.0/go.mod h1:edq+UMpgqEx3roTuGF/03uIuSOsI986jtu65+ytLlkA=
-k8s.io/gengo v0.0.0-20200413195148-3a45101e95ac/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0=
-k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE=
-k8s.io/klog/v2 v2.8.0 h1:Q3gmuM9hKEjefWFFYF0Mat+YyFJvsUyYuwyNNJ5C9Ts=
-k8s.io/klog/v2 v2.8.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
-k8s.io/kube-openapi v0.0.0-20210305001622-591a79e4bda7/go.mod h1:wXW5VT87nVfh/iLV8FpR2uDvrFyomxbtb1KivDbvPTE=
-k8s.io/legacy-cloud-providers v0.21.0 h1:iWf5xaX9yvYT5mkz8UB96UtISQ5IkrWeuMPMhRp01ZY=
-k8s.io/legacy-cloud-providers v0.21.0/go.mod h1:bNxo7gDg+PGkBmT/MFZswLTWdSWK9kAlS1s8DJca5q4=
-k8s.io/utils v0.0.0-20201110183641-67b214c5f920 h1:CbnUZsM497iRC5QMVkHwyl8s2tB3g7yaSHkYPkpgelw=
-k8s.io/utils v0.0.0-20201110183641-67b214c5f920/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
-rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
-rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0=
-rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA=
-sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.15/go.mod h1:LEScyzhFmoF5pso/YSeBstl57mOzx9xlU9n85RGrDQg=
-sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
-sigs.k8s.io/structured-merge-diff/v4 v4.1.0 h1:C4r9BgJ98vrKnnVCjwCSXcWjWe0NKcUQkmzDXZXGwH8=
-sigs.k8s.io/structured-merge-diff/v4 v4.1.0/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw=
-sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o=
-sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=
-sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/keyring.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/keyring.go
deleted file mode 100644
index 0af960a384fc..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/keyring.go
+++ /dev/null
@@ -1,303 +0,0 @@
-/*
-Copyright 2014 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package credentialprovider
-
-import (
- "net"
- "net/url"
- "path/filepath"
- "sort"
- "strings"
-
- "k8s.io/apimachinery/pkg/util/sets"
- "k8s.io/klog/v2"
-)
-
-// DockerKeyring tracks a set of docker registry credentials, maintaining a
-// reverse index across the registry endpoints. A registry endpoint is made
-// up of a host (e.g. registry.example.com), but it may also contain a path
-// (e.g. registry.example.com/foo) This index is important for two reasons:
-// - registry endpoints may overlap, and when this happens we must find the
-// most specific match for a given image
-// - iterating a map does not yield predictable results
-type DockerKeyring interface {
- Lookup(image string) ([]AuthConfig, bool)
-}
-
-// BasicDockerKeyring is a trivial map-backed implementation of DockerKeyring
-type BasicDockerKeyring struct {
- index []string
- creds map[string][]AuthConfig
-}
-
-// providersDockerKeyring is an implementation of DockerKeyring that
-// materializes its dockercfg based on a set of dockerConfigProviders.
-type providersDockerKeyring struct {
- Providers []DockerConfigProvider
-}
-
-// AuthConfig contains authorization information for connecting to a Registry
-// This type mirrors "github.com/docker/docker/api/types.AuthConfig"
-type AuthConfig struct {
- Username string `json:"username,omitempty"`
- Password string `json:"password,omitempty"`
- Auth string `json:"auth,omitempty"`
-
- // Email is an optional value associated with the username.
- // This field is deprecated and will be removed in a later
- // version of docker.
- Email string `json:"email,omitempty"`
-
- ServerAddress string `json:"serveraddress,omitempty"`
-
- // IdentityToken is used to authenticate the user and get
- // an access token for the registry.
- IdentityToken string `json:"identitytoken,omitempty"`
-
- // RegistryToken is a bearer token to be sent to a registry
- RegistryToken string `json:"registrytoken,omitempty"`
-}
-
-// Add add some docker config in basic docker keyring
-func (dk *BasicDockerKeyring) Add(cfg DockerConfig) {
- if dk.index == nil {
- dk.index = make([]string, 0)
- dk.creds = make(map[string][]AuthConfig)
- }
- for loc, ident := range cfg {
- creds := AuthConfig{
- Username: ident.Username,
- Password: ident.Password,
- Email: ident.Email,
- }
-
- value := loc
- if !strings.HasPrefix(value, "https://") && !strings.HasPrefix(value, "http://") {
- value = "https://" + value
- }
- parsed, err := url.Parse(value)
- if err != nil {
- klog.Errorf("Entry %q in dockercfg invalid (%v), ignoring", loc, err)
- continue
- }
-
- // The docker client allows exact matches:
- // foo.bar.com/namespace
- // Or hostname matches:
- // foo.bar.com
- // It also considers /v2/ and /v1/ equivalent to the hostname
- // See ResolveAuthConfig in docker/registry/auth.go.
- effectivePath := parsed.Path
- if strings.HasPrefix(effectivePath, "/v2/") || strings.HasPrefix(effectivePath, "/v1/") {
- effectivePath = effectivePath[3:]
- }
- var key string
- if (len(effectivePath) > 0) && (effectivePath != "/") {
- key = parsed.Host + effectivePath
- } else {
- key = parsed.Host
- }
- dk.creds[key] = append(dk.creds[key], creds)
- dk.index = append(dk.index, key)
- }
-
- eliminateDupes := sets.NewString(dk.index...)
- dk.index = eliminateDupes.List()
-
- // Update the index used to identify which credentials to use for a given
- // image. The index is reverse-sorted so more specific paths are matched
- // first. For example, if for the given image "quay.io/coreos/etcd",
- // credentials for "quay.io/coreos" should match before "quay.io".
- sort.Sort(sort.Reverse(sort.StringSlice(dk.index)))
-}
-
-const (
- defaultRegistryHost = "index.docker.io"
- defaultRegistryKey = defaultRegistryHost + "/v1/"
-)
-
-// isDefaultRegistryMatch determines whether the given image will
-// pull from the default registry (DockerHub) based on the
-// characteristics of its name.
-func isDefaultRegistryMatch(image string) bool {
- parts := strings.SplitN(image, "/", 2)
-
- if len(parts[0]) == 0 {
- return false
- }
-
- if len(parts) == 1 {
- // e.g. library/ubuntu
- return true
- }
-
- if parts[0] == "docker.io" || parts[0] == "index.docker.io" {
- // resolve docker.io/image and index.docker.io/image as default registry
- return true
- }
-
- // From: http://blog.docker.com/2013/07/how-to-use-your-own-registry/
- // Docker looks for either a “.” (domain separator) or “:” (port separator)
- // to learn that the first part of the repository name is a location and not
- // a user name.
- return !strings.ContainsAny(parts[0], ".:")
-}
-
-// ParseSchemelessURL parses a schemeless url and returns a url.URL
-// url.Parse require a scheme, but ours don't have schemes. Adding a
-// scheme to make url.Parse happy, then clear out the resulting scheme.
-func ParseSchemelessURL(schemelessURL string) (*url.URL, error) {
- parsed, err := url.Parse("https://" + schemelessURL)
- if err != nil {
- return nil, err
- }
- // clear out the resulting scheme
- parsed.Scheme = ""
- return parsed, nil
-}
-
-// SplitURL splits the host name into parts, as well as the port
-func SplitURL(url *url.URL) (parts []string, port string) {
- host, port, err := net.SplitHostPort(url.Host)
- if err != nil {
- // could not parse port
- host, port = url.Host, ""
- }
- return strings.Split(host, "."), port
-}
-
-// URLsMatchStr is wrapper for URLsMatch, operating on strings instead of URLs.
-func URLsMatchStr(glob string, target string) (bool, error) {
- globURL, err := ParseSchemelessURL(glob)
- if err != nil {
- return false, err
- }
- targetURL, err := ParseSchemelessURL(target)
- if err != nil {
- return false, err
- }
- return URLsMatch(globURL, targetURL)
-}
-
-// URLsMatch checks whether the given target url matches the glob url, which may have
-// glob wild cards in the host name.
-//
-// Examples:
-// globURL=*.docker.io, targetURL=blah.docker.io => match
-// globURL=*.docker.io, targetURL=not.right.io => no match
-//
-// Note that we don't support wildcards in ports and paths yet.
-func URLsMatch(globURL *url.URL, targetURL *url.URL) (bool, error) {
- globURLParts, globPort := SplitURL(globURL)
- targetURLParts, targetPort := SplitURL(targetURL)
- if globPort != targetPort {
- // port doesn't match
- return false, nil
- }
- if len(globURLParts) != len(targetURLParts) {
- // host name does not have the same number of parts
- return false, nil
- }
- if !strings.HasPrefix(targetURL.Path, globURL.Path) {
- // the path of the credential must be a prefix
- return false, nil
- }
- for k, globURLPart := range globURLParts {
- targetURLPart := targetURLParts[k]
- matched, err := filepath.Match(globURLPart, targetURLPart)
- if err != nil {
- return false, err
- }
- if !matched {
- // glob mismatch for some part
- return false, nil
- }
- }
- // everything matches
- return true, nil
-}
-
-// Lookup implements the DockerKeyring method for fetching credentials based on image name.
-// Multiple credentials may be returned if there are multiple potentially valid credentials
-// available. This allows for rotation.
-func (dk *BasicDockerKeyring) Lookup(image string) ([]AuthConfig, bool) {
- // range over the index as iterating over a map does not provide a predictable ordering
- ret := []AuthConfig{}
- for _, k := range dk.index {
- // both k and image are schemeless URLs because even though schemes are allowed
- // in the credential configurations, we remove them in Add.
- if matched, _ := URLsMatchStr(k, image); matched {
- ret = append(ret, dk.creds[k]...)
- }
- }
-
- if len(ret) > 0 {
- return ret, true
- }
-
- // Use credentials for the default registry if provided, and appropriate
- if isDefaultRegistryMatch(image) {
- if auth, ok := dk.creds[defaultRegistryHost]; ok {
- return auth, true
- }
- }
-
- return []AuthConfig{}, false
-}
-
-// Lookup implements the DockerKeyring method for fetching credentials
-// based on image name.
-func (dk *providersDockerKeyring) Lookup(image string) ([]AuthConfig, bool) {
- keyring := &BasicDockerKeyring{}
-
- for _, p := range dk.Providers {
- keyring.Add(p.Provide(image))
- }
-
- return keyring.Lookup(image)
-}
-
-// FakeKeyring a fake config credentials
-type FakeKeyring struct {
- auth []AuthConfig
- ok bool
-}
-
-// Lookup implements the DockerKeyring method for fetching credentials based on image name
-// return fake auth and ok
-func (f *FakeKeyring) Lookup(image string) ([]AuthConfig, bool) {
- return f.auth, f.ok
-}
-
-// UnionDockerKeyring delegates to a set of keyrings.
-type UnionDockerKeyring []DockerKeyring
-
-// Lookup implements the DockerKeyring method for fetching credentials based on image name.
-// return each credentials
-func (k UnionDockerKeyring) Lookup(image string) ([]AuthConfig, bool) {
- authConfigs := []AuthConfig{}
- for _, subKeyring := range k {
- if subKeyring == nil {
- continue
- }
-
- currAuthResults, _ := subKeyring.Lookup(image)
- authConfigs = append(authConfigs, currAuthResults...)
- }
-
- return authConfigs, (len(authConfigs) > 0)
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/plugins.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/plugins.go
deleted file mode 100644
index 76051a9b4b55..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/plugins.go
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
-Copyright 2014 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package credentialprovider
-
-import (
- "reflect"
- "sort"
- "sync"
-
- "k8s.io/klog/v2"
-)
-
-// All registered credential providers.
-var providersMutex sync.Mutex
-var providers = make(map[string]DockerConfigProvider)
-
-// RegisterCredentialProvider is called by provider implementations on
-// initialization to register themselves, like so:
-// func init() {
-// RegisterCredentialProvider("name", &myProvider{...})
-// }
-func RegisterCredentialProvider(name string, provider DockerConfigProvider) {
- providersMutex.Lock()
- defer providersMutex.Unlock()
- _, found := providers[name]
- if found {
- klog.Fatalf("Credential provider %q was registered twice", name)
- }
- klog.V(4).Infof("Registered credential provider %q", name)
- providers[name] = provider
-}
-
-// NewDockerKeyring creates a DockerKeyring to use for resolving credentials,
-// which draws from the set of registered credential providers.
-func NewDockerKeyring() DockerKeyring {
- keyring := &providersDockerKeyring{
- Providers: make([]DockerConfigProvider, 0),
- }
-
- keys := reflect.ValueOf(providers).MapKeys()
- stringKeys := make([]string, len(keys))
- for ix := range keys {
- stringKeys[ix] = keys[ix].String()
- }
- sort.Strings(stringKeys)
-
- for _, key := range stringKeys {
- provider := providers[key]
- if provider.Enabled() {
- klog.V(4).Infof("Registering credential provider: %v", key)
- keyring.Providers = append(keyring.Providers, provider)
- }
- }
-
- return keyring
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/provider.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/provider.go
deleted file mode 100644
index 8c9ad347b72c..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/provider.go
+++ /dev/null
@@ -1,109 +0,0 @@
-/*
-Copyright 2014 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package credentialprovider
-
-import (
- "os"
- "reflect"
- "sync"
- "time"
-
- "k8s.io/klog/v2"
-)
-
-// DockerConfigProvider is the interface that registered extensions implement
-// to materialize 'dockercfg' credentials.
-type DockerConfigProvider interface {
- // Enabled returns true if the config provider is enabled.
- // Implementations can be blocking - e.g. metadata server unavailable.
- Enabled() bool
- // Provide returns docker configuration.
- // Implementations can be blocking - e.g. metadata server unavailable.
- // The image is passed in as context in the event that the
- // implementation depends on information in the image name to return
- // credentials; implementations are safe to ignore the image.
- Provide(image string) DockerConfig
-}
-
-// A DockerConfigProvider that simply reads the .dockercfg file
-type defaultDockerConfigProvider struct{}
-
-// init registers our default provider, which simply reads the .dockercfg file.
-func init() {
- RegisterCredentialProvider(".dockercfg",
- &CachingDockerConfigProvider{
- Provider: &defaultDockerConfigProvider{},
- Lifetime: 5 * time.Minute,
- })
-}
-
-// CachingDockerConfigProvider implements DockerConfigProvider by composing
-// with another DockerConfigProvider and caching the DockerConfig it provides
-// for a pre-specified lifetime.
-type CachingDockerConfigProvider struct {
- Provider DockerConfigProvider
- Lifetime time.Duration
-
- // ShouldCache is an optional function that returns true if the specific config should be cached.
- // If nil, all configs are treated as cacheable.
- ShouldCache func(DockerConfig) bool
-
- // cache fields
- cacheDockerConfig DockerConfig
- expiration time.Time
- mu sync.Mutex
-}
-
-// Enabled implements dockerConfigProvider
-func (d *defaultDockerConfigProvider) Enabled() bool {
- return true
-}
-
-// Provide implements dockerConfigProvider
-func (d *defaultDockerConfigProvider) Provide(image string) DockerConfig {
- // Read the standard Docker credentials from .dockercfg
- if cfg, err := ReadDockerConfigFile(); err == nil {
- return cfg
- } else if !os.IsNotExist(err) {
- klog.V(2).Infof("Docker config file not found: %v", err)
- }
- return DockerConfig{}
-}
-
-// Enabled implements dockerConfigProvider
-func (d *CachingDockerConfigProvider) Enabled() bool {
- return d.Provider.Enabled()
-}
-
-// Provide implements dockerConfigProvider
-func (d *CachingDockerConfigProvider) Provide(image string) DockerConfig {
- d.mu.Lock()
- defer d.mu.Unlock()
-
- // If the cache hasn't expired, return our cache
- if time.Now().Before(d.expiration) {
- return d.cacheDockerConfig
- }
-
- klog.V(2).Infof("Refreshing cache for provider: %v", reflect.TypeOf(d.Provider).String())
- config := d.Provider.Provide(image)
- if d.ShouldCache == nil || d.ShouldCache(config) {
- d.cacheDockerConfig = config
- d.expiration = time.Now().Add(d.Lifetime)
- }
- return config
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/secrets/secrets.go b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/secrets/secrets.go
deleted file mode 100644
index 9cdec624122d..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/secrets/secrets.go
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
-Copyright 2018 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package secrets
-
-import (
- "encoding/json"
-
- v1 "k8s.io/api/core/v1"
- "github.com/vdemeester/k8s-pkg-credentialprovider"
-)
-
-// MakeDockerKeyring inspects the passedSecrets to see if they contain any DockerConfig secrets. If they do,
-// then a DockerKeyring is built based on every hit and unioned with the defaultKeyring.
-// If they do not, then the default keyring is returned
-func MakeDockerKeyring(passedSecrets []v1.Secret, defaultKeyring credentialprovider.DockerKeyring) (credentialprovider.DockerKeyring, error) {
- passedCredentials := []credentialprovider.DockerConfig{}
- for _, passedSecret := range passedSecrets {
- if dockerConfigJSONBytes, dockerConfigJSONExists := passedSecret.Data[v1.DockerConfigJsonKey]; (passedSecret.Type == v1.SecretTypeDockerConfigJson) && dockerConfigJSONExists && (len(dockerConfigJSONBytes) > 0) {
- dockerConfigJSON := credentialprovider.DockerConfigJSON{}
- if err := json.Unmarshal(dockerConfigJSONBytes, &dockerConfigJSON); err != nil {
- return nil, err
- }
-
- passedCredentials = append(passedCredentials, dockerConfigJSON.Auths)
- } else if dockercfgBytes, dockercfgExists := passedSecret.Data[v1.DockerConfigKey]; (passedSecret.Type == v1.SecretTypeDockercfg) && dockercfgExists && (len(dockercfgBytes) > 0) {
- dockercfg := credentialprovider.DockerConfig{}
- if err := json.Unmarshal(dockercfgBytes, &dockercfg); err != nil {
- return nil, err
- }
-
- passedCredentials = append(passedCredentials, dockercfg)
- }
- }
-
- if len(passedCredentials) > 0 {
- basicKeyring := &credentialprovider.BasicDockerKeyring{}
- for _, currCredentials := range passedCredentials {
- basicKeyring.Add(currCredentials)
- }
- return credentialprovider.UnionDockerKeyring{basicKeyring, defaultKeyring}, nil
- }
-
- return defaultKeyring, nil
-}
diff --git a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/sync.sh b/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/sync.sh
deleted file mode 100644
index 4db00d204fcb..000000000000
--- a/vendor/github.com/vdemeester/k8s-pkg-credentialprovider/sync.sh
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/usr/bin/env bash
-
-set -e
-set -uv
-
-tag="${1}"
-dir=$(mktemp -d)
-
-git clone --depth 1 --branch "${tag}" git@github.com:kubernetes/kubernetes.git "${dir}"
-cp -r "${dir}/pkg/credentialprovider/." .
-
-find . \( -name "OWNERS" \
- -o -name "OWNERS_ALIASES" \
- -o -name "BUILD" \
- -o -name "BUILD.bazel" \) -exec rm -f {} +
-rm -fR plugin
-
-
-oldpkg="k8s.io/kubernetes/pkg/credentialprovider"
-newpkg="github.com/vdemeester/k8s-pkg-credentialprovider"
-
-find ./ -type f ! -name "sync.sh" ! -name "README.md" \
- -exec sed -i '' "s,${oldpkg},${newpkg},g" {} \;
diff --git a/vendor/golang.org/x/net/http2/server.go b/vendor/golang.org/x/net/http2/server.go
index d219dc4c76df..e644d9b2f34d 100644
--- a/vendor/golang.org/x/net/http2/server.go
+++ b/vendor/golang.org/x/net/http2/server.go
@@ -722,7 +722,7 @@ func (sc *serverConn) canonicalHeader(v string) string {
// maxCachedCanonicalHeaders is an arbitrarily-chosen limit on the number of
// entries in the canonHeader cache. This should be larger than the number
// of unique, uncommon header keys likely to be sent by the peer, while not
- // so high as to permit unreaasonable memory usage if the peer sends an unbounded
+ // so high as to permit unreasonable memory usage if the peer sends an unbounded
// number of unique header keys.
const maxCachedCanonicalHeaders = 32
if len(sc.canonHeader) < maxCachedCanonicalHeaders {
diff --git a/vendor/golang.org/x/sys/plan9/syscall_plan9.go b/vendor/golang.org/x/sys/plan9/syscall_plan9.go
index 84e14714811d..723b1f4002aa 100644
--- a/vendor/golang.org/x/sys/plan9/syscall_plan9.go
+++ b/vendor/golang.org/x/sys/plan9/syscall_plan9.go
@@ -132,8 +132,10 @@ func Pipe(p []int) (err error) {
}
var pp [2]int32
err = pipe(&pp)
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return
}
diff --git a/vendor/golang.org/x/sys/unix/mkerrors.sh b/vendor/golang.org/x/sys/unix/mkerrors.sh
index 4945739ea0a9..a47b035f9af3 100644
--- a/vendor/golang.org/x/sys/unix/mkerrors.sh
+++ b/vendor/golang.org/x/sys/unix/mkerrors.sh
@@ -261,6 +261,7 @@ struct ltchars {
#include
#include
#include
+#include
#include
#include
@@ -606,6 +607,7 @@ ccflags="$@"
$2 ~ /^MTD/ ||
$2 ~ /^OTP/ ||
$2 ~ /^MEM/ ||
+ $2 ~ /^WG/ ||
$2 ~ /^BLK[A-Z]*(GET$|SET$|BUF$|PART$|SIZE)/ {printf("\t%s = C.%s\n", $2, $2)}
$2 ~ /^__WCOREFLAG$/ {next}
$2 ~ /^__W[A-Z0-9]+$/ {printf("\t%s = C.%s\n", substr($2,3), $2)}
diff --git a/vendor/golang.org/x/sys/unix/syscall_aix.go b/vendor/golang.org/x/sys/unix/syscall_aix.go
index 6192750ce31b..4f55c8d99960 100644
--- a/vendor/golang.org/x/sys/unix/syscall_aix.go
+++ b/vendor/golang.org/x/sys/unix/syscall_aix.go
@@ -519,8 +519,10 @@ func Pipe(p []int) (err error) {
}
var pp [2]_C_int
err = pipe(&pp)
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_darwin.go b/vendor/golang.org/x/sys/unix/syscall_darwin.go
index 8826f41435e9..0eaab91314c6 100644
--- a/vendor/golang.org/x/sys/unix/syscall_darwin.go
+++ b/vendor/golang.org/x/sys/unix/syscall_darwin.go
@@ -159,8 +159,10 @@ func Pipe(p []int) (err error) {
}
var x [2]int32
err = pipe(&x)
- p[0] = int(x[0])
- p[1] = int(x[1])
+ if err == nil {
+ p[0] = int(x[0])
+ p[1] = int(x[1])
+ }
return
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_dragonfly.go b/vendor/golang.org/x/sys/unix/syscall_dragonfly.go
index 5af108a50385..2e37c3167f39 100644
--- a/vendor/golang.org/x/sys/unix/syscall_dragonfly.go
+++ b/vendor/golang.org/x/sys/unix/syscall_dragonfly.go
@@ -101,7 +101,10 @@ func Pipe(p []int) (err error) {
if len(p) != 2 {
return EINVAL
}
- p[0], p[1], err = pipe()
+ r, w, err := pipe()
+ if err == nil {
+ p[0], p[1] = r, w
+ }
return
}
@@ -114,7 +117,10 @@ func Pipe2(p []int, flags int) (err error) {
var pp [2]_C_int
// pipe2 on dragonfly takes an fds array as an argument, but still
// returns the file descriptors.
- p[0], p[1], err = pipe2(&pp, flags)
+ r, w, err := pipe2(&pp, flags)
+ if err == nil {
+ p[0], p[1] = r, w
+ }
return err
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_freebsd.go b/vendor/golang.org/x/sys/unix/syscall_freebsd.go
index 18c392cf3692..2f650ae665cc 100644
--- a/vendor/golang.org/x/sys/unix/syscall_freebsd.go
+++ b/vendor/golang.org/x/sys/unix/syscall_freebsd.go
@@ -110,8 +110,10 @@ func Pipe2(p []int, flags int) error {
}
var pp [2]_C_int
err := pipe2(&pp, flags)
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return err
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_linux.go b/vendor/golang.org/x/sys/unix/syscall_linux.go
index 4bc5baf77d96..f432b0684b8c 100644
--- a/vendor/golang.org/x/sys/unix/syscall_linux.go
+++ b/vendor/golang.org/x/sys/unix/syscall_linux.go
@@ -131,8 +131,10 @@ func Pipe2(p []int, flags int) error {
}
var pp [2]_C_int
err := pipe2(&pp, flags)
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return err
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_netbsd.go b/vendor/golang.org/x/sys/unix/syscall_netbsd.go
index 853d5f0f4365..696fed496f68 100644
--- a/vendor/golang.org/x/sys/unix/syscall_netbsd.go
+++ b/vendor/golang.org/x/sys/unix/syscall_netbsd.go
@@ -110,14 +110,8 @@ func direntNamlen(buf []byte) (uint64, bool) {
return readInt(buf, unsafe.Offsetof(Dirent{}.Namlen), unsafe.Sizeof(Dirent{}.Namlen))
}
-//sysnb pipe() (fd1 int, fd2 int, err error)
-
func Pipe(p []int) (err error) {
- if len(p) != 2 {
- return EINVAL
- }
- p[0], p[1], err = pipe()
- return
+ return Pipe2(p, 0)
}
//sysnb pipe2(p *[2]_C_int, flags int) (err error)
@@ -128,8 +122,10 @@ func Pipe2(p []int, flags int) error {
}
var pp [2]_C_int
err := pipe2(&pp, flags)
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return err
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_openbsd.go b/vendor/golang.org/x/sys/unix/syscall_openbsd.go
index 22b55038501f..11b1d419da91 100644
--- a/vendor/golang.org/x/sys/unix/syscall_openbsd.go
+++ b/vendor/golang.org/x/sys/unix/syscall_openbsd.go
@@ -87,8 +87,10 @@ func Pipe2(p []int, flags int) error {
}
var pp [2]_C_int
err := pipe2(&pp, flags)
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return err
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_solaris.go b/vendor/golang.org/x/sys/unix/syscall_solaris.go
index 8b88ac213333..5c813921e855 100644
--- a/vendor/golang.org/x/sys/unix/syscall_solaris.go
+++ b/vendor/golang.org/x/sys/unix/syscall_solaris.go
@@ -66,8 +66,10 @@ func Pipe(p []int) (err error) {
if n != 0 {
return err
}
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return nil
}
@@ -79,8 +81,10 @@ func Pipe2(p []int, flags int) error {
}
var pp [2]_C_int
err := pipe2(&pp, flags)
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return err
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_zos_s390x.go b/vendor/golang.org/x/sys/unix/syscall_zos_s390x.go
index 5fb76a146843..f8616f454ec6 100644
--- a/vendor/golang.org/x/sys/unix/syscall_zos_s390x.go
+++ b/vendor/golang.org/x/sys/unix/syscall_zos_s390x.go
@@ -579,8 +579,10 @@ func Pipe(p []int) (err error) {
}
var pp [2]_C_int
err = pipe(&pp)
- p[0] = int(pp[0])
- p[1] = int(pp[1])
+ if err == nil {
+ p[0] = int(pp[0])
+ p[1] = int(pp[1])
+ }
return
}
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux.go b/vendor/golang.org/x/sys/unix/zerrors_linux.go
index d175aae896cb..4e5420586120 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux.go
@@ -741,6 +741,7 @@ const (
ETH_P_QINQ2 = 0x9200
ETH_P_QINQ3 = 0x9300
ETH_P_RARP = 0x8035
+ ETH_P_REALTEK = 0x8899
ETH_P_SCA = 0x6007
ETH_P_SLOW = 0x8809
ETH_P_SNAP = 0x5
@@ -810,10 +811,12 @@ const (
FAN_EPIDFD = -0x2
FAN_EVENT_INFO_TYPE_DFID = 0x3
FAN_EVENT_INFO_TYPE_DFID_NAME = 0x2
+ FAN_EVENT_INFO_TYPE_ERROR = 0x5
FAN_EVENT_INFO_TYPE_FID = 0x1
FAN_EVENT_INFO_TYPE_PIDFD = 0x4
FAN_EVENT_METADATA_LEN = 0x18
FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_FS_ERROR = 0x8000
FAN_MARK_ADD = 0x1
FAN_MARK_DONT_FOLLOW = 0x4
FAN_MARK_FILESYSTEM = 0x100
@@ -1827,6 +1830,8 @@ const (
PERF_MEM_BLK_DATA = 0x2
PERF_MEM_BLK_NA = 0x1
PERF_MEM_BLK_SHIFT = 0x28
+ PERF_MEM_HOPS_0 = 0x1
+ PERF_MEM_HOPS_SHIFT = 0x2b
PERF_MEM_LOCK_LOCKED = 0x2
PERF_MEM_LOCK_NA = 0x1
PERF_MEM_LOCK_SHIFT = 0x18
@@ -1986,6 +1991,9 @@ const (
PR_SCHED_CORE_CREATE = 0x1
PR_SCHED_CORE_GET = 0x0
PR_SCHED_CORE_MAX = 0x4
+ PR_SCHED_CORE_SCOPE_PROCESS_GROUP = 0x2
+ PR_SCHED_CORE_SCOPE_THREAD = 0x0
+ PR_SCHED_CORE_SCOPE_THREAD_GROUP = 0x1
PR_SCHED_CORE_SHARE_FROM = 0x3
PR_SCHED_CORE_SHARE_TO = 0x2
PR_SET_CHILD_SUBREAPER = 0x24
@@ -2167,12 +2175,23 @@ const (
RTCF_NAT = 0x800000
RTCF_VALVE = 0x200000
RTC_AF = 0x20
+ RTC_BSM_DIRECT = 0x1
+ RTC_BSM_DISABLED = 0x0
+ RTC_BSM_LEVEL = 0x2
+ RTC_BSM_STANDBY = 0x3
RTC_FEATURE_ALARM = 0x0
+ RTC_FEATURE_ALARM_RES_2S = 0x3
RTC_FEATURE_ALARM_RES_MINUTE = 0x1
- RTC_FEATURE_CNT = 0x3
+ RTC_FEATURE_BACKUP_SWITCH_MODE = 0x6
+ RTC_FEATURE_CNT = 0x7
+ RTC_FEATURE_CORRECTION = 0x5
RTC_FEATURE_NEED_WEEK_DAY = 0x2
+ RTC_FEATURE_UPDATE_INTERRUPT = 0x4
RTC_IRQF = 0x80
RTC_MAX_FREQ = 0x2000
+ RTC_PARAM_BACKUP_SWITCH_MODE = 0x2
+ RTC_PARAM_CORRECTION = 0x1
+ RTC_PARAM_FEATURES = 0x0
RTC_PF = 0x40
RTC_UF = 0x10
RTF_ADDRCLASSMASK = 0xf8000000
@@ -2532,6 +2551,8 @@ const (
SO_VM_SOCKETS_BUFFER_MIN_SIZE = 0x1
SO_VM_SOCKETS_BUFFER_SIZE = 0x0
SO_VM_SOCKETS_CONNECT_TIMEOUT = 0x6
+ SO_VM_SOCKETS_CONNECT_TIMEOUT_NEW = 0x8
+ SO_VM_SOCKETS_CONNECT_TIMEOUT_OLD = 0x6
SO_VM_SOCKETS_NONBLOCK_TXRX = 0x7
SO_VM_SOCKETS_PEER_HOST_VM_ID = 0x3
SO_VM_SOCKETS_TRUSTED = 0x5
@@ -2826,6 +2847,13 @@ const (
WDIOS_TEMPPANIC = 0x4
WDIOS_UNKNOWN = -0x1
WEXITED = 0x4
+ WGALLOWEDIP_A_MAX = 0x3
+ WGDEVICE_A_MAX = 0x8
+ WGPEER_A_MAX = 0xa
+ WG_CMD_MAX = 0x1
+ WG_GENL_NAME = "wireguard"
+ WG_GENL_VERSION = 0x1
+ WG_KEY_LEN = 0x20
WIN_ACKMEDIACHANGE = 0xdb
WIN_CHECKPOWERMODE1 = 0xe5
WIN_CHECKPOWERMODE2 = 0x98
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_386.go b/vendor/golang.org/x/sys/unix/zerrors_linux_386.go
index 3ca40ca7f02a..234fd4a5d1ad 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_386.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_386.go
@@ -250,6 +250,8 @@ const (
RTC_EPOCH_SET = 0x4004700e
RTC_IRQP_READ = 0x8004700b
RTC_IRQP_SET = 0x4004700c
+ RTC_PARAM_GET = 0x40187013
+ RTC_PARAM_SET = 0x40187014
RTC_PIE_OFF = 0x7006
RTC_PIE_ON = 0x7005
RTC_PLL_GET = 0x801c7011
@@ -327,6 +329,7 @@ const (
SO_RCVTIMEO = 0x14
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x14
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go
index ead332091afd..58619b7589b0 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go
@@ -251,6 +251,8 @@ const (
RTC_EPOCH_SET = 0x4008700e
RTC_IRQP_READ = 0x8008700b
RTC_IRQP_SET = 0x4008700c
+ RTC_PARAM_GET = 0x40187013
+ RTC_PARAM_SET = 0x40187014
RTC_PIE_OFF = 0x7006
RTC_PIE_ON = 0x7005
RTC_PLL_GET = 0x80207011
@@ -328,6 +330,7 @@ const (
SO_RCVTIMEO = 0x14
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x14
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go b/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go
index 39bdc9455899..3a64ff59dcec 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go
@@ -257,6 +257,8 @@ const (
RTC_EPOCH_SET = 0x4004700e
RTC_IRQP_READ = 0x8004700b
RTC_IRQP_SET = 0x4004700c
+ RTC_PARAM_GET = 0x40187013
+ RTC_PARAM_SET = 0x40187014
RTC_PIE_OFF = 0x7006
RTC_PIE_ON = 0x7005
RTC_PLL_GET = 0x801c7011
@@ -334,6 +336,7 @@ const (
SO_RCVTIMEO = 0x14
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x14
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go
index 9aec987db1ce..abe0b925789f 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go
@@ -247,6 +247,8 @@ const (
RTC_EPOCH_SET = 0x4008700e
RTC_IRQP_READ = 0x8008700b
RTC_IRQP_SET = 0x4008700c
+ RTC_PARAM_GET = 0x40187013
+ RTC_PARAM_SET = 0x40187014
RTC_PIE_OFF = 0x7006
RTC_PIE_ON = 0x7005
RTC_PLL_GET = 0x80207011
@@ -324,6 +326,7 @@ const (
SO_RCVTIMEO = 0x14
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x14
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go
index a8bba9491e82..14d7a84399de 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go
@@ -250,6 +250,8 @@ const (
RTC_EPOCH_SET = 0x8004700e
RTC_IRQP_READ = 0x4004700b
RTC_IRQP_SET = 0x8004700c
+ RTC_PARAM_GET = 0x80187013
+ RTC_PARAM_SET = 0x80187014
RTC_PIE_OFF = 0x20007006
RTC_PIE_ON = 0x20007005
RTC_PLL_GET = 0x401c7011
@@ -327,6 +329,7 @@ const (
SO_RCVTIMEO = 0x1006
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x1006
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x4
SO_REUSEPORT = 0x200
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go
index ee9e7e2020ea..99e7c4ac0b45 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go
@@ -250,6 +250,8 @@ const (
RTC_EPOCH_SET = 0x8008700e
RTC_IRQP_READ = 0x4008700b
RTC_IRQP_SET = 0x8008700c
+ RTC_PARAM_GET = 0x80187013
+ RTC_PARAM_SET = 0x80187014
RTC_PIE_OFF = 0x20007006
RTC_PIE_ON = 0x20007005
RTC_PLL_GET = 0x40207011
@@ -327,6 +329,7 @@ const (
SO_RCVTIMEO = 0x1006
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x1006
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x4
SO_REUSEPORT = 0x200
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go
index ba4b288a3c06..496364c33cc6 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go
@@ -250,6 +250,8 @@ const (
RTC_EPOCH_SET = 0x8008700e
RTC_IRQP_READ = 0x4008700b
RTC_IRQP_SET = 0x8008700c
+ RTC_PARAM_GET = 0x80187013
+ RTC_PARAM_SET = 0x80187014
RTC_PIE_OFF = 0x20007006
RTC_PIE_ON = 0x20007005
RTC_PLL_GET = 0x40207011
@@ -327,6 +329,7 @@ const (
SO_RCVTIMEO = 0x1006
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x1006
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x4
SO_REUSEPORT = 0x200
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go
index bc93afc36751..3e40830857dd 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go
@@ -250,6 +250,8 @@ const (
RTC_EPOCH_SET = 0x8004700e
RTC_IRQP_READ = 0x4004700b
RTC_IRQP_SET = 0x8004700c
+ RTC_PARAM_GET = 0x80187013
+ RTC_PARAM_SET = 0x80187014
RTC_PIE_OFF = 0x20007006
RTC_PIE_ON = 0x20007005
RTC_PLL_GET = 0x401c7011
@@ -327,6 +329,7 @@ const (
SO_RCVTIMEO = 0x1006
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x1006
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x4
SO_REUSEPORT = 0x200
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc.go b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc.go
index 9295e6947852..1151a7dfab33 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc.go
@@ -305,6 +305,8 @@ const (
RTC_EPOCH_SET = 0x8004700e
RTC_IRQP_READ = 0x4004700b
RTC_IRQP_SET = 0x8004700c
+ RTC_PARAM_GET = 0x80187013
+ RTC_PARAM_SET = 0x80187014
RTC_PIE_OFF = 0x20007006
RTC_PIE_ON = 0x20007005
RTC_PLL_GET = 0x401c7011
@@ -382,6 +384,7 @@ const (
SO_RCVTIMEO = 0x12
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x12
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go
index 1fa081c9a673..ed17f249e758 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go
@@ -309,6 +309,8 @@ const (
RTC_EPOCH_SET = 0x8008700e
RTC_IRQP_READ = 0x4008700b
RTC_IRQP_SET = 0x8008700c
+ RTC_PARAM_GET = 0x80187013
+ RTC_PARAM_SET = 0x80187014
RTC_PIE_OFF = 0x20007006
RTC_PIE_ON = 0x20007005
RTC_PLL_GET = 0x40207011
@@ -386,6 +388,7 @@ const (
SO_RCVTIMEO = 0x12
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x12
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go
index 74b321149463..d84a37c1ac23 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go
@@ -309,6 +309,8 @@ const (
RTC_EPOCH_SET = 0x8008700e
RTC_IRQP_READ = 0x4008700b
RTC_IRQP_SET = 0x8008700c
+ RTC_PARAM_GET = 0x80187013
+ RTC_PARAM_SET = 0x80187014
RTC_PIE_OFF = 0x20007006
RTC_PIE_ON = 0x20007005
RTC_PLL_GET = 0x40207011
@@ -386,6 +388,7 @@ const (
SO_RCVTIMEO = 0x12
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x12
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go
index c91c8ac5b01d..5cafba83f6b4 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go
@@ -238,6 +238,8 @@ const (
RTC_EPOCH_SET = 0x4008700e
RTC_IRQP_READ = 0x8008700b
RTC_IRQP_SET = 0x4008700c
+ RTC_PARAM_GET = 0x40187013
+ RTC_PARAM_SET = 0x40187014
RTC_PIE_OFF = 0x7006
RTC_PIE_ON = 0x7005
RTC_PLL_GET = 0x80207011
@@ -315,6 +317,7 @@ const (
SO_RCVTIMEO = 0x14
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x14
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go b/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go
index b66bf2228949..6d122da41c53 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go
@@ -313,6 +313,8 @@ const (
RTC_EPOCH_SET = 0x4008700e
RTC_IRQP_READ = 0x8008700b
RTC_IRQP_SET = 0x4008700c
+ RTC_PARAM_GET = 0x40187013
+ RTC_PARAM_SET = 0x40187014
RTC_PIE_OFF = 0x7006
RTC_PIE_ON = 0x7005
RTC_PLL_GET = 0x80207011
@@ -390,6 +392,7 @@ const (
SO_RCVTIMEO = 0x14
SO_RCVTIMEO_NEW = 0x42
SO_RCVTIMEO_OLD = 0x14
+ SO_RESERVE_MEM = 0x49
SO_REUSEADDR = 0x2
SO_REUSEPORT = 0xf
SO_RXQ_OVFL = 0x28
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go
index f7fb149b0c98..6bd19e51dbb9 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go
@@ -304,6 +304,8 @@ const (
RTC_EPOCH_SET = 0x8008700e
RTC_IRQP_READ = 0x4008700b
RTC_IRQP_SET = 0x8008700c
+ RTC_PARAM_GET = 0x80187013
+ RTC_PARAM_SET = 0x80187014
RTC_PIE_OFF = 0x20007006
RTC_PIE_ON = 0x20007005
RTC_PLL_GET = 0x40207011
@@ -381,6 +383,7 @@ const (
SO_RCVTIMEO = 0x2000
SO_RCVTIMEO_NEW = 0x44
SO_RCVTIMEO_OLD = 0x2000
+ SO_RESERVE_MEM = 0x52
SO_REUSEADDR = 0x4
SO_REUSEPORT = 0x200
SO_RXQ_OVFL = 0x24
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_netbsd_386.go b/vendor/golang.org/x/sys/unix/zsyscall_netbsd_386.go
index 4726ab30a8fa..51d0c0742bfa 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_netbsd_386.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_netbsd_386.go
@@ -351,18 +351,6 @@ func Munlockall() (err error) {
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
-func pipe() (fd1 int, fd2 int, err error) {
- r0, r1, e1 := RawSyscall(SYS_PIPE, 0, 0, 0)
- fd1 = int(r0)
- fd2 = int(r1)
- if e1 != 0 {
- err = errnoErr(e1)
- }
- return
-}
-
-// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
-
func pipe2(p *[2]_C_int, flags int) (err error) {
_, _, e1 := RawSyscall(SYS_PIPE2, uintptr(unsafe.Pointer(p)), uintptr(flags), 0)
if e1 != 0 {
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_netbsd_amd64.go b/vendor/golang.org/x/sys/unix/zsyscall_netbsd_amd64.go
index fe71456dbc0f..df2efb6db3fa 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_netbsd_amd64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_netbsd_amd64.go
@@ -351,18 +351,6 @@ func Munlockall() (err error) {
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
-func pipe() (fd1 int, fd2 int, err error) {
- r0, r1, e1 := RawSyscall(SYS_PIPE, 0, 0, 0)
- fd1 = int(r0)
- fd2 = int(r1)
- if e1 != 0 {
- err = errnoErr(e1)
- }
- return
-}
-
-// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
-
func pipe2(p *[2]_C_int, flags int) (err error) {
_, _, e1 := RawSyscall(SYS_PIPE2, uintptr(unsafe.Pointer(p)), uintptr(flags), 0)
if e1 != 0 {
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm.go b/vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm.go
index 0b5b2f0143be..c8536c2c9f09 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm.go
@@ -351,18 +351,6 @@ func Munlockall() (err error) {
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
-func pipe() (fd1 int, fd2 int, err error) {
- r0, r1, e1 := RawSyscall(SYS_PIPE, 0, 0, 0)
- fd1 = int(r0)
- fd2 = int(r1)
- if e1 != 0 {
- err = errnoErr(e1)
- }
- return
-}
-
-// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
-
func pipe2(p *[2]_C_int, flags int) (err error) {
_, _, e1 := RawSyscall(SYS_PIPE2, uintptr(unsafe.Pointer(p)), uintptr(flags), 0)
if e1 != 0 {
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm64.go b/vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm64.go
index bfca28648fb5..8b981bfc2eb9 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm64.go
@@ -351,18 +351,6 @@ func Munlockall() (err error) {
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
-func pipe() (fd1 int, fd2 int, err error) {
- r0, r1, e1 := RawSyscall(SYS_PIPE, 0, 0, 0)
- fd1 = int(r0)
- fd2 = int(r1)
- if e1 != 0 {
- err = errnoErr(e1)
- }
- return
-}
-
-// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
-
func pipe2(p *[2]_C_int, flags int) (err error) {
_, _, e1 := RawSyscall(SYS_PIPE2, uintptr(unsafe.Pointer(p)), uintptr(flags), 0)
if e1 != 0 {
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_386.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_386.go
index 31847d2305fa..cac1f758bf7e 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_386.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_386.go
@@ -445,4 +445,5 @@ const (
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_MEMFD_SECRET = 447
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_amd64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_amd64.go
index 3503cbbde385..f327e4a0bccb 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_amd64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_amd64.go
@@ -367,4 +367,5 @@ const (
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_MEMFD_SECRET = 447
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_arm.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_arm.go
index 5ecd24bf683c..fb06a08d4ee8 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_arm.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_arm.go
@@ -409,4 +409,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 445
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go
index 7e5c94cc7fea..58285646eb79 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go
@@ -312,4 +312,5 @@ const (
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_MEMFD_SECRET = 447
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_mips.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_mips.go
index e1e2a2bf59ed..3b0418e68944 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_mips.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_mips.go
@@ -429,4 +429,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 4445
SYS_LANDLOCK_RESTRICT_SELF = 4446
SYS_PROCESS_MRELEASE = 4448
+ SYS_FUTEX_WAITV = 4449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64.go
index 7651915a3adc..314ebf166ab9 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64.go
@@ -359,4 +359,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 5445
SYS_LANDLOCK_RESTRICT_SELF = 5446
SYS_PROCESS_MRELEASE = 5448
+ SYS_FUTEX_WAITV = 5449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64le.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64le.go
index a26a2c050bca..b8fbb937a333 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64le.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64le.go
@@ -359,4 +359,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 5445
SYS_LANDLOCK_RESTRICT_SELF = 5446
SYS_PROCESS_MRELEASE = 5448
+ SYS_FUTEX_WAITV = 5449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_mipsle.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_mipsle.go
index fda9a6a99131..ee309b2bac96 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_mipsle.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_mipsle.go
@@ -429,4 +429,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 4445
SYS_LANDLOCK_RESTRICT_SELF = 4446
SYS_PROCESS_MRELEASE = 4448
+ SYS_FUTEX_WAITV = 4449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc.go
index e8496150d410..ac3748104ed0 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc.go
@@ -436,4 +436,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 445
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64.go
index 5ee0678a360c..5aa472111041 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64.go
@@ -408,4 +408,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 445
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64le.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64le.go
index 29c0f9a39ead..0793ac1a65be 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64le.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64le.go
@@ -408,4 +408,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 445
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go
index 5c9a9a3b61c9..a520962e3954 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go
@@ -310,4 +310,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 445
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_s390x.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_s390x.go
index 913f50f98b90..d1738586b4f6 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_s390x.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_s390x.go
@@ -373,4 +373,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 445
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go
index 0de03a7227c3..dfd5660f9741 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go
@@ -387,4 +387,5 @@ const (
SYS_LANDLOCK_ADD_RULE = 445
SYS_LANDLOCK_RESTRICT_SELF = 446
SYS_PROCESS_MRELEASE = 448
+ SYS_FUTEX_WAITV = 449
)
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux.go b/vendor/golang.org/x/sys/unix/ztypes_linux.go
index 37b521436bc2..66788f156814 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux.go
@@ -867,6 +867,7 @@ const (
CTRL_CMD_NEWMCAST_GRP = 0x7
CTRL_CMD_DELMCAST_GRP = 0x8
CTRL_CMD_GETMCAST_GRP = 0x9
+ CTRL_CMD_GETPOLICY = 0xa
CTRL_ATTR_UNSPEC = 0x0
CTRL_ATTR_FAMILY_ID = 0x1
CTRL_ATTR_FAMILY_NAME = 0x2
@@ -875,12 +876,19 @@ const (
CTRL_ATTR_MAXATTR = 0x5
CTRL_ATTR_OPS = 0x6
CTRL_ATTR_MCAST_GROUPS = 0x7
+ CTRL_ATTR_POLICY = 0x8
+ CTRL_ATTR_OP_POLICY = 0x9
+ CTRL_ATTR_OP = 0xa
CTRL_ATTR_OP_UNSPEC = 0x0
CTRL_ATTR_OP_ID = 0x1
CTRL_ATTR_OP_FLAGS = 0x2
CTRL_ATTR_MCAST_GRP_UNSPEC = 0x0
CTRL_ATTR_MCAST_GRP_NAME = 0x1
CTRL_ATTR_MCAST_GRP_ID = 0x2
+ CTRL_ATTR_POLICY_UNSPEC = 0x0
+ CTRL_ATTR_POLICY_DO = 0x1
+ CTRL_ATTR_POLICY_DUMP = 0x2
+ CTRL_ATTR_POLICY_DUMP_MAX = 0x2
)
const (
@@ -1136,7 +1144,8 @@ const (
PERF_RECORD_BPF_EVENT = 0x12
PERF_RECORD_CGROUP = 0x13
PERF_RECORD_TEXT_POKE = 0x14
- PERF_RECORD_MAX = 0x15
+ PERF_RECORD_AUX_OUTPUT_HW_ID = 0x15
+ PERF_RECORD_MAX = 0x16
PERF_RECORD_KSYMBOL_TYPE_UNKNOWN = 0x0
PERF_RECORD_KSYMBOL_TYPE_BPF = 0x1
PERF_RECORD_KSYMBOL_TYPE_OOL = 0x2
@@ -1776,7 +1785,8 @@ const (
const (
NF_NETDEV_INGRESS = 0x0
- NF_NETDEV_NUMHOOKS = 0x1
+ NF_NETDEV_EGRESS = 0x1
+ NF_NETDEV_NUMHOOKS = 0x2
)
const (
@@ -3158,7 +3168,13 @@ const (
DEVLINK_ATTR_RELOAD_ACTION_INFO = 0xa2
DEVLINK_ATTR_RELOAD_ACTION_STATS = 0xa3
DEVLINK_ATTR_PORT_PCI_SF_NUMBER = 0xa4
- DEVLINK_ATTR_MAX = 0xa9
+ DEVLINK_ATTR_RATE_TYPE = 0xa5
+ DEVLINK_ATTR_RATE_TX_SHARE = 0xa6
+ DEVLINK_ATTR_RATE_TX_MAX = 0xa7
+ DEVLINK_ATTR_RATE_NODE_NAME = 0xa8
+ DEVLINK_ATTR_RATE_PARENT_NODE_NAME = 0xa9
+ DEVLINK_ATTR_REGION_MAX_SNAPSHOTS = 0xaa
+ DEVLINK_ATTR_MAX = 0xaa
DEVLINK_DPIPE_FIELD_MAPPING_TYPE_NONE = 0x0
DEVLINK_DPIPE_FIELD_MAPPING_TYPE_IFINDEX = 0x1
DEVLINK_DPIPE_MATCH_TYPE_FIELD_EXACT = 0x0
@@ -3455,7 +3471,14 @@ const (
ETHTOOL_MSG_CABLE_TEST_ACT = 0x1a
ETHTOOL_MSG_CABLE_TEST_TDR_ACT = 0x1b
ETHTOOL_MSG_TUNNEL_INFO_GET = 0x1c
- ETHTOOL_MSG_USER_MAX = 0x21
+ ETHTOOL_MSG_FEC_GET = 0x1d
+ ETHTOOL_MSG_FEC_SET = 0x1e
+ ETHTOOL_MSG_MODULE_EEPROM_GET = 0x1f
+ ETHTOOL_MSG_STATS_GET = 0x20
+ ETHTOOL_MSG_PHC_VCLOCKS_GET = 0x21
+ ETHTOOL_MSG_MODULE_GET = 0x22
+ ETHTOOL_MSG_MODULE_SET = 0x23
+ ETHTOOL_MSG_USER_MAX = 0x23
ETHTOOL_MSG_KERNEL_NONE = 0x0
ETHTOOL_MSG_STRSET_GET_REPLY = 0x1
ETHTOOL_MSG_LINKINFO_GET_REPLY = 0x2
@@ -3486,7 +3509,14 @@ const (
ETHTOOL_MSG_CABLE_TEST_NTF = 0x1b
ETHTOOL_MSG_CABLE_TEST_TDR_NTF = 0x1c
ETHTOOL_MSG_TUNNEL_INFO_GET_REPLY = 0x1d
- ETHTOOL_MSG_KERNEL_MAX = 0x22
+ ETHTOOL_MSG_FEC_GET_REPLY = 0x1e
+ ETHTOOL_MSG_FEC_NTF = 0x1f
+ ETHTOOL_MSG_MODULE_EEPROM_GET_REPLY = 0x20
+ ETHTOOL_MSG_STATS_GET_REPLY = 0x21
+ ETHTOOL_MSG_PHC_VCLOCKS_GET_REPLY = 0x22
+ ETHTOOL_MSG_MODULE_GET_REPLY = 0x23
+ ETHTOOL_MSG_MODULE_NTF = 0x24
+ ETHTOOL_MSG_KERNEL_MAX = 0x24
ETHTOOL_A_HEADER_UNSPEC = 0x0
ETHTOOL_A_HEADER_DEV_INDEX = 0x1
ETHTOOL_A_HEADER_DEV_NAME = 0x2
@@ -3968,3 +3998,70 @@ type MountAttr struct {
Propagation uint64
Userns_fd uint64
}
+
+const (
+ WG_CMD_GET_DEVICE = 0x0
+ WG_CMD_SET_DEVICE = 0x1
+ WGDEVICE_F_REPLACE_PEERS = 0x1
+ WGDEVICE_A_UNSPEC = 0x0
+ WGDEVICE_A_IFINDEX = 0x1
+ WGDEVICE_A_IFNAME = 0x2
+ WGDEVICE_A_PRIVATE_KEY = 0x3
+ WGDEVICE_A_PUBLIC_KEY = 0x4
+ WGDEVICE_A_FLAGS = 0x5
+ WGDEVICE_A_LISTEN_PORT = 0x6
+ WGDEVICE_A_FWMARK = 0x7
+ WGDEVICE_A_PEERS = 0x8
+ WGPEER_F_REMOVE_ME = 0x1
+ WGPEER_F_REPLACE_ALLOWEDIPS = 0x2
+ WGPEER_F_UPDATE_ONLY = 0x4
+ WGPEER_A_UNSPEC = 0x0
+ WGPEER_A_PUBLIC_KEY = 0x1
+ WGPEER_A_PRESHARED_KEY = 0x2
+ WGPEER_A_FLAGS = 0x3
+ WGPEER_A_ENDPOINT = 0x4
+ WGPEER_A_PERSISTENT_KEEPALIVE_INTERVAL = 0x5
+ WGPEER_A_LAST_HANDSHAKE_TIME = 0x6
+ WGPEER_A_RX_BYTES = 0x7
+ WGPEER_A_TX_BYTES = 0x8
+ WGPEER_A_ALLOWEDIPS = 0x9
+ WGPEER_A_PROTOCOL_VERSION = 0xa
+ WGALLOWEDIP_A_UNSPEC = 0x0
+ WGALLOWEDIP_A_FAMILY = 0x1
+ WGALLOWEDIP_A_IPADDR = 0x2
+ WGALLOWEDIP_A_CIDR_MASK = 0x3
+)
+
+const (
+ NL_ATTR_TYPE_INVALID = 0x0
+ NL_ATTR_TYPE_FLAG = 0x1
+ NL_ATTR_TYPE_U8 = 0x2
+ NL_ATTR_TYPE_U16 = 0x3
+ NL_ATTR_TYPE_U32 = 0x4
+ NL_ATTR_TYPE_U64 = 0x5
+ NL_ATTR_TYPE_S8 = 0x6
+ NL_ATTR_TYPE_S16 = 0x7
+ NL_ATTR_TYPE_S32 = 0x8
+ NL_ATTR_TYPE_S64 = 0x9
+ NL_ATTR_TYPE_BINARY = 0xa
+ NL_ATTR_TYPE_STRING = 0xb
+ NL_ATTR_TYPE_NUL_STRING = 0xc
+ NL_ATTR_TYPE_NESTED = 0xd
+ NL_ATTR_TYPE_NESTED_ARRAY = 0xe
+ NL_ATTR_TYPE_BITFIELD32 = 0xf
+
+ NL_POLICY_TYPE_ATTR_UNSPEC = 0x0
+ NL_POLICY_TYPE_ATTR_TYPE = 0x1
+ NL_POLICY_TYPE_ATTR_MIN_VALUE_S = 0x2
+ NL_POLICY_TYPE_ATTR_MAX_VALUE_S = 0x3
+ NL_POLICY_TYPE_ATTR_MIN_VALUE_U = 0x4
+ NL_POLICY_TYPE_ATTR_MAX_VALUE_U = 0x5
+ NL_POLICY_TYPE_ATTR_MIN_LENGTH = 0x6
+ NL_POLICY_TYPE_ATTR_MAX_LENGTH = 0x7
+ NL_POLICY_TYPE_ATTR_POLICY_IDX = 0x8
+ NL_POLICY_TYPE_ATTR_POLICY_MAXTYPE = 0x9
+ NL_POLICY_TYPE_ATTR_BITFIELD32_MASK = 0xa
+ NL_POLICY_TYPE_ATTR_PAD = 0xb
+ NL_POLICY_TYPE_ATTR_MASK = 0xc
+ NL_POLICY_TYPE_ATTR_MAX = 0xc
+)
diff --git a/vendor/golang.org/x/sys/windows/exec_windows.go b/vendor/golang.org/x/sys/windows/exec_windows.go
index 7a11e83b7ec1..855698bb2828 100644
--- a/vendor/golang.org/x/sys/windows/exec_windows.go
+++ b/vendor/golang.org/x/sys/windows/exec_windows.go
@@ -9,8 +9,6 @@ package windows
import (
errorspkg "errors"
"unsafe"
-
- "golang.org/x/sys/internal/unsafeheader"
)
// EscapeArg rewrites command line argument s as prescribed
@@ -147,8 +145,12 @@ func NewProcThreadAttributeList(maxAttrCount uint32) (*ProcThreadAttributeListCo
}
return nil, err
}
+ alloc, err := LocalAlloc(LMEM_FIXED, uint32(size))
+ if err != nil {
+ return nil, err
+ }
// size is guaranteed to be ≥1 by InitializeProcThreadAttributeList.
- al := &ProcThreadAttributeListContainer{data: (*ProcThreadAttributeList)(unsafe.Pointer(&make([]byte, size)[0]))}
+ al := &ProcThreadAttributeListContainer{data: (*ProcThreadAttributeList)(unsafe.Pointer(alloc))}
err = initializeProcThreadAttributeList(al.data, maxAttrCount, 0, &size)
if err != nil {
return nil, err
@@ -157,36 +159,17 @@ func NewProcThreadAttributeList(maxAttrCount uint32) (*ProcThreadAttributeListCo
}
// Update modifies the ProcThreadAttributeList using UpdateProcThreadAttribute.
-// Note that the value passed to this function will be copied into memory
-// allocated by LocalAlloc, the contents of which should not contain any
-// Go-managed pointers, even if the passed value itself is a Go-managed
-// pointer.
func (al *ProcThreadAttributeListContainer) Update(attribute uintptr, value unsafe.Pointer, size uintptr) error {
- alloc, err := LocalAlloc(LMEM_FIXED, uint32(size))
- if err != nil {
- return err
- }
- var src, dst []byte
- hdr := (*unsafeheader.Slice)(unsafe.Pointer(&src))
- hdr.Data = value
- hdr.Cap = int(size)
- hdr.Len = int(size)
- hdr = (*unsafeheader.Slice)(unsafe.Pointer(&dst))
- hdr.Data = unsafe.Pointer(alloc)
- hdr.Cap = int(size)
- hdr.Len = int(size)
- copy(dst, src)
- al.heapAllocations = append(al.heapAllocations, alloc)
- return updateProcThreadAttribute(al.data, 0, attribute, unsafe.Pointer(alloc), size, nil, nil)
+ al.pointers = append(al.pointers, value)
+ return updateProcThreadAttribute(al.data, 0, attribute, value, size, nil, nil)
}
// Delete frees ProcThreadAttributeList's resources.
func (al *ProcThreadAttributeListContainer) Delete() {
deleteProcThreadAttributeList(al.data)
- for i := range al.heapAllocations {
- LocalFree(Handle(al.heapAllocations[i]))
- }
- al.heapAllocations = nil
+ LocalFree(Handle(unsafe.Pointer(al.data)))
+ al.data = nil
+ al.pointers = nil
}
// List returns the actual ProcThreadAttributeList to be passed to StartupInfoEx.
diff --git a/vendor/golang.org/x/sys/windows/syscall_windows.go b/vendor/golang.org/x/sys/windows/syscall_windows.go
index 7702bbb8d8ba..cf44e6933790 100644
--- a/vendor/golang.org/x/sys/windows/syscall_windows.go
+++ b/vendor/golang.org/x/sys/windows/syscall_windows.go
@@ -323,6 +323,8 @@ func NewCallbackCDecl(fn interface{}) uintptr {
//sys WriteConsole(console Handle, buf *uint16, towrite uint32, written *uint32, reserved *byte) (err error) = kernel32.WriteConsoleW
//sys ReadConsole(console Handle, buf *uint16, toread uint32, read *uint32, inputControl *byte) (err error) = kernel32.ReadConsoleW
//sys CreateToolhelp32Snapshot(flags uint32, processId uint32) (handle Handle, err error) [failretval==InvalidHandle] = kernel32.CreateToolhelp32Snapshot
+//sys Module32First(snapshot Handle, moduleEntry *ModuleEntry32) (err error) = kernel32.Module32FirstW
+//sys Module32Next(snapshot Handle, moduleEntry *ModuleEntry32) (err error) = kernel32.Module32NextW
//sys Process32First(snapshot Handle, procEntry *ProcessEntry32) (err error) = kernel32.Process32FirstW
//sys Process32Next(snapshot Handle, procEntry *ProcessEntry32) (err error) = kernel32.Process32NextW
//sys Thread32First(snapshot Handle, threadEntry *ThreadEntry32) (err error)
@@ -361,6 +363,8 @@ func NewCallbackCDecl(fn interface{}) uintptr {
//sys SetProcessWorkingSetSizeEx(hProcess Handle, dwMinimumWorkingSetSize uintptr, dwMaximumWorkingSetSize uintptr, flags uint32) (err error)
//sys GetCommTimeouts(handle Handle, timeouts *CommTimeouts) (err error)
//sys SetCommTimeouts(handle Handle, timeouts *CommTimeouts) (err error)
+//sys GetActiveProcessorCount(groupNumber uint16) (ret uint32)
+//sys GetMaximumProcessorCount(groupNumber uint16) (ret uint32)
// Volume Management Functions
//sys DefineDosDevice(flags uint32, deviceName *uint16, targetPath *uint16) (err error) = DefineDosDeviceW
diff --git a/vendor/golang.org/x/sys/windows/types_windows.go b/vendor/golang.org/x/sys/windows/types_windows.go
index 286dd1eab951..e19471c6a852 100644
--- a/vendor/golang.org/x/sys/windows/types_windows.go
+++ b/vendor/golang.org/x/sys/windows/types_windows.go
@@ -156,6 +156,8 @@ const (
MAX_PATH = 260
MAX_LONG_PATH = 32768
+ MAX_MODULE_NAME32 = 255
+
MAX_COMPUTERNAME_LENGTH = 15
TIME_ZONE_ID_UNKNOWN = 0
@@ -936,8 +938,8 @@ type StartupInfoEx struct {
type ProcThreadAttributeList struct{}
type ProcThreadAttributeListContainer struct {
- data *ProcThreadAttributeList
- heapAllocations []uintptr
+ data *ProcThreadAttributeList
+ pointers []unsafe.Pointer
}
type ProcessInformation struct {
@@ -970,6 +972,21 @@ type ThreadEntry32 struct {
Flags uint32
}
+type ModuleEntry32 struct {
+ Size uint32
+ ModuleID uint32
+ ProcessID uint32
+ GlblcntUsage uint32
+ ProccntUsage uint32
+ ModBaseAddr uintptr
+ ModBaseSize uint32
+ ModuleHandle Handle
+ Module [MAX_MODULE_NAME32 + 1]uint16
+ ExePath [MAX_PATH]uint16
+}
+
+const SizeofModuleEntry32 = unsafe.Sizeof(ModuleEntry32{})
+
type Systemtime struct {
Year uint16
Month uint16
@@ -2732,6 +2749,43 @@ type PROCESS_BASIC_INFORMATION struct {
InheritedFromUniqueProcessId uintptr
}
+type SYSTEM_PROCESS_INFORMATION struct {
+ NextEntryOffset uint32
+ NumberOfThreads uint32
+ WorkingSetPrivateSize int64
+ HardFaultCount uint32
+ NumberOfThreadsHighWatermark uint32
+ CycleTime uint64
+ CreateTime int64
+ UserTime int64
+ KernelTime int64
+ ImageName NTUnicodeString
+ BasePriority int32
+ UniqueProcessID uintptr
+ InheritedFromUniqueProcessID uintptr
+ HandleCount uint32
+ SessionID uint32
+ UniqueProcessKey *uint32
+ PeakVirtualSize uintptr
+ VirtualSize uintptr
+ PageFaultCount uint32
+ PeakWorkingSetSize uintptr
+ WorkingSetSize uintptr
+ QuotaPeakPagedPoolUsage uintptr
+ QuotaPagedPoolUsage uintptr
+ QuotaPeakNonPagedPoolUsage uintptr
+ QuotaNonPagedPoolUsage uintptr
+ PagefileUsage uintptr
+ PeakPagefileUsage uintptr
+ PrivatePageCount uintptr
+ ReadOperationCount int64
+ WriteOperationCount int64
+ OtherOperationCount int64
+ ReadTransferCount int64
+ WriteTransferCount int64
+ OtherTransferCount int64
+}
+
// SystemInformationClasses for NtQuerySystemInformation and NtSetSystemInformation
const (
SystemBasicInformation = iota
@@ -3118,3 +3172,5 @@ type ModuleInfo struct {
SizeOfImage uint32
EntryPoint uintptr
}
+
+const ALL_PROCESSOR_GROUPS = 0xFFFF
diff --git a/vendor/golang.org/x/sys/windows/zsyscall_windows.go b/vendor/golang.org/x/sys/windows/zsyscall_windows.go
index bf0dd8fca88f..9ea1a44f04de 100644
--- a/vendor/golang.org/x/sys/windows/zsyscall_windows.go
+++ b/vendor/golang.org/x/sys/windows/zsyscall_windows.go
@@ -226,6 +226,7 @@ var (
procFreeLibrary = modkernel32.NewProc("FreeLibrary")
procGenerateConsoleCtrlEvent = modkernel32.NewProc("GenerateConsoleCtrlEvent")
procGetACP = modkernel32.NewProc("GetACP")
+ procGetActiveProcessorCount = modkernel32.NewProc("GetActiveProcessorCount")
procGetCommTimeouts = modkernel32.NewProc("GetCommTimeouts")
procGetCommandLineW = modkernel32.NewProc("GetCommandLineW")
procGetComputerNameExW = modkernel32.NewProc("GetComputerNameExW")
@@ -251,6 +252,7 @@ var (
procGetLogicalDriveStringsW = modkernel32.NewProc("GetLogicalDriveStringsW")
procGetLogicalDrives = modkernel32.NewProc("GetLogicalDrives")
procGetLongPathNameW = modkernel32.NewProc("GetLongPathNameW")
+ procGetMaximumProcessorCount = modkernel32.NewProc("GetMaximumProcessorCount")
procGetModuleFileNameW = modkernel32.NewProc("GetModuleFileNameW")
procGetModuleHandleExW = modkernel32.NewProc("GetModuleHandleExW")
procGetNamedPipeHandleStateW = modkernel32.NewProc("GetNamedPipeHandleStateW")
@@ -295,6 +297,8 @@ var (
procLockFileEx = modkernel32.NewProc("LockFileEx")
procLockResource = modkernel32.NewProc("LockResource")
procMapViewOfFile = modkernel32.NewProc("MapViewOfFile")
+ procModule32FirstW = modkernel32.NewProc("Module32FirstW")
+ procModule32NextW = modkernel32.NewProc("Module32NextW")
procMoveFileExW = modkernel32.NewProc("MoveFileExW")
procMoveFileW = modkernel32.NewProc("MoveFileW")
procMultiByteToWideChar = modkernel32.NewProc("MultiByteToWideChar")
@@ -1965,6 +1969,12 @@ func GetACP() (acp uint32) {
return
}
+func GetActiveProcessorCount(groupNumber uint16) (ret uint32) {
+ r0, _, _ := syscall.Syscall(procGetActiveProcessorCount.Addr(), 1, uintptr(groupNumber), 0, 0)
+ ret = uint32(r0)
+ return
+}
+
func GetCommTimeouts(handle Handle, timeouts *CommTimeouts) (err error) {
r1, _, e1 := syscall.Syscall(procGetCommTimeouts.Addr(), 2, uintptr(handle), uintptr(unsafe.Pointer(timeouts)), 0)
if r1 == 0 {
@@ -2167,6 +2177,12 @@ func GetLongPathName(path *uint16, buf *uint16, buflen uint32) (n uint32, err er
return
}
+func GetMaximumProcessorCount(groupNumber uint16) (ret uint32) {
+ r0, _, _ := syscall.Syscall(procGetMaximumProcessorCount.Addr(), 1, uintptr(groupNumber), 0, 0)
+ ret = uint32(r0)
+ return
+}
+
func GetModuleFileName(module Handle, filename *uint16, size uint32) (n uint32, err error) {
r0, _, e1 := syscall.Syscall(procGetModuleFileNameW.Addr(), 3, uintptr(module), uintptr(unsafe.Pointer(filename)), uintptr(size))
n = uint32(r0)
@@ -2567,6 +2583,22 @@ func MapViewOfFile(handle Handle, access uint32, offsetHigh uint32, offsetLow ui
return
}
+func Module32First(snapshot Handle, moduleEntry *ModuleEntry32) (err error) {
+ r1, _, e1 := syscall.Syscall(procModule32FirstW.Addr(), 2, uintptr(snapshot), uintptr(unsafe.Pointer(moduleEntry)), 0)
+ if r1 == 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+func Module32Next(snapshot Handle, moduleEntry *ModuleEntry32) (err error) {
+ r1, _, e1 := syscall.Syscall(procModule32NextW.Addr(), 2, uintptr(snapshot), uintptr(unsafe.Pointer(moduleEntry)), 0)
+ if r1 == 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
func MoveFileEx(from *uint16, to *uint16, flags uint32) (err error) {
r1, _, e1 := syscall.Syscall(procMoveFileExW.Addr(), 3, uintptr(unsafe.Pointer(from)), uintptr(unsafe.Pointer(to)), uintptr(flags))
if r1 == 0 {
diff --git a/vendor/golang.org/x/term/go.mod b/vendor/golang.org/x/term/go.mod
index d45f52851ec4..edf0e5b1db4c 100644
--- a/vendor/golang.org/x/term/go.mod
+++ b/vendor/golang.org/x/term/go.mod
@@ -1,5 +1,5 @@
module golang.org/x/term
-go 1.11
+go 1.17
-require golang.org/x/sys v0.0.0-20201119102817-f84b799fce68
+require golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1
diff --git a/vendor/golang.org/x/term/go.sum b/vendor/golang.org/x/term/go.sum
index de9e09c6547e..ff132135ec68 100644
--- a/vendor/golang.org/x/term/go.sum
+++ b/vendor/golang.org/x/term/go.sum
@@ -1,2 +1,2 @@
-golang.org/x/sys v0.0.0-20201119102817-f84b799fce68 h1:nxC68pudNYkKU6jWhgrqdreuFiOQWj1Fs7T3VrH4Pjw=
-golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1 h1:SrN+KX8Art/Sf4HNj6Zcz06G7VEz+7w9tdXTPOZ7+l4=
+golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
diff --git a/vendor/golang.org/x/term/term.go b/vendor/golang.org/x/term/term.go
index 2a4ccf801210..1f6a38fad2ab 100644
--- a/vendor/golang.org/x/term/term.go
+++ b/vendor/golang.org/x/term/term.go
@@ -7,11 +7,11 @@
//
// Putting a terminal into raw mode is the most common requirement:
//
-// oldState, err := term.MakeRaw(0)
+// oldState, err := term.MakeRaw(int(os.Stdin.Fd()))
// if err != nil {
// panic(err)
// }
-// defer term.Restore(0, oldState)
+// defer term.Restore(int(os.Stdin.Fd()), oldState)
package term
// State contains the state of a terminal.
diff --git a/vendor/golang.org/x/term/term_solaris.go b/vendor/golang.org/x/term/term_solaris.go
deleted file mode 100644
index b9da29744b7a..000000000000
--- a/vendor/golang.org/x/term/term_solaris.go
+++ /dev/null
@@ -1,111 +0,0 @@
-// Copyright 2019 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package term
-
-import (
- "io"
- "syscall"
-
- "golang.org/x/sys/unix"
-)
-
-// State contains the state of a terminal.
-type state struct {
- termios unix.Termios
-}
-
-func isTerminal(fd int) bool {
- _, err := unix.IoctlGetTermio(fd, unix.TCGETA)
- return err == nil
-}
-
-func readPassword(fd int) ([]byte, error) {
- // see also: http://src.illumos.org/source/xref/illumos-gate/usr/src/lib/libast/common/uwin/getpass.c
- val, err := unix.IoctlGetTermios(fd, unix.TCGETS)
- if err != nil {
- return nil, err
- }
- oldState := *val
-
- newState := oldState
- newState.Lflag &^= syscall.ECHO
- newState.Lflag |= syscall.ICANON | syscall.ISIG
- newState.Iflag |= syscall.ICRNL
- err = unix.IoctlSetTermios(fd, unix.TCSETS, &newState)
- if err != nil {
- return nil, err
- }
-
- defer unix.IoctlSetTermios(fd, unix.TCSETS, &oldState)
-
- var buf [16]byte
- var ret []byte
- for {
- n, err := syscall.Read(fd, buf[:])
- if err != nil {
- return nil, err
- }
- if n == 0 {
- if len(ret) == 0 {
- return nil, io.EOF
- }
- break
- }
- if buf[n-1] == '\n' {
- n--
- }
- ret = append(ret, buf[:n]...)
- if n < len(buf) {
- break
- }
- }
-
- return ret, nil
-}
-
-func makeRaw(fd int) (*State, error) {
- // see http://cr.illumos.org/~webrev/andy_js/1060/
- termios, err := unix.IoctlGetTermios(fd, unix.TCGETS)
- if err != nil {
- return nil, err
- }
-
- oldState := State{state{termios: *termios}}
-
- termios.Iflag &^= unix.IGNBRK | unix.BRKINT | unix.PARMRK | unix.ISTRIP | unix.INLCR | unix.IGNCR | unix.ICRNL | unix.IXON
- termios.Oflag &^= unix.OPOST
- termios.Lflag &^= unix.ECHO | unix.ECHONL | unix.ICANON | unix.ISIG | unix.IEXTEN
- termios.Cflag &^= unix.CSIZE | unix.PARENB
- termios.Cflag |= unix.CS8
- termios.Cc[unix.VMIN] = 1
- termios.Cc[unix.VTIME] = 0
-
- if err := unix.IoctlSetTermios(fd, unix.TCSETS, termios); err != nil {
- return nil, err
- }
-
- return &oldState, nil
-}
-
-func restore(fd int, oldState *State) error {
- return unix.IoctlSetTermios(fd, unix.TCSETS, &oldState.termios)
-}
-
-func getState(fd int) (*State, error) {
- termios, err := unix.IoctlGetTermios(fd, unix.TCGETS)
- if err != nil {
- return nil, err
- }
-
- return &State{state{termios: *termios}}, nil
-}
-
-func getSize(fd int) (width, height int, err error) {
- ws, err := unix.IoctlGetWinsize(fd, unix.TIOCGWINSZ)
- if err != nil {
- return 0, 0, err
- }
- return int(ws.Col), int(ws.Row), nil
-}
diff --git a/vendor/golang.org/x/term/term_unix.go b/vendor/golang.org/x/term/term_unix.go
index 6849b6ee5ba1..a4e31ab1b29c 100644
--- a/vendor/golang.org/x/term/term_unix.go
+++ b/vendor/golang.org/x/term/term_unix.go
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-//go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || zos
-// +build aix darwin dragonfly freebsd linux netbsd openbsd zos
+//go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos
+// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris zos
package term
diff --git a/vendor/golang.org/x/term/term_unix_linux.go b/vendor/golang.org/x/term/term_unix_linux.go
deleted file mode 100644
index 2d5efd26ad44..000000000000
--- a/vendor/golang.org/x/term/term_unix_linux.go
+++ /dev/null
@@ -1,10 +0,0 @@
-// Copyright 2019 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package term
-
-import "golang.org/x/sys/unix"
-
-const ioctlReadTermios = unix.TCGETS
-const ioctlWriteTermios = unix.TCSETS
diff --git a/vendor/golang.org/x/term/term_unix_aix.go b/vendor/golang.org/x/term/term_unix_other.go
similarity index 63%
rename from vendor/golang.org/x/term/term_unix_aix.go
rename to vendor/golang.org/x/term/term_unix_other.go
index 2d5efd26ad44..1e8955c934ff 100644
--- a/vendor/golang.org/x/term/term_unix_aix.go
+++ b/vendor/golang.org/x/term/term_unix_other.go
@@ -1,7 +1,10 @@
-// Copyright 2019 The Go Authors. All rights reserved.
+// Copyright 2021 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
+//go:build aix || linux || solaris || zos
+// +build aix linux solaris zos
+
package term
import "golang.org/x/sys/unix"
diff --git a/vendor/golang.org/x/term/term_unix_zos.go b/vendor/golang.org/x/term/term_unix_zos.go
deleted file mode 100644
index b85ab899893e..000000000000
--- a/vendor/golang.org/x/term/term_unix_zos.go
+++ /dev/null
@@ -1,10 +0,0 @@
-// Copyright 2020 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package term
-
-import "golang.org/x/sys/unix"
-
-const ioctlReadTermios = unix.TCGETS
-const ioctlWriteTermios = unix.TCSETS
diff --git a/vendor/google.golang.org/api/dns/v1/dns-gen.go b/vendor/google.golang.org/api/dns/v1/dns-gen.go
index 0029d0541e09..73fe95954a69 100644
--- a/vendor/google.golang.org/api/dns/v1/dns-gen.go
+++ b/vendor/google.golang.org/api/dns/v1/dns-gen.go
@@ -1899,7 +1899,7 @@ func (c *ChangesCreateCall) Header() http.Header {
func (c *ChangesCreateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2080,7 +2080,7 @@ func (c *ChangesGetCall) Header() http.Header {
func (c *ChangesGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2286,7 +2286,7 @@ func (c *ChangesListCall) Header() http.Header {
func (c *ChangesListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2516,7 +2516,7 @@ func (c *DnsKeysGetCall) Header() http.Header {
func (c *DnsKeysGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2719,7 +2719,7 @@ func (c *DnsKeysListCall) Header() http.Header {
func (c *DnsKeysListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2928,7 +2928,7 @@ func (c *ManagedZoneOperationsGetCall) Header() http.Header {
func (c *ManagedZoneOperationsGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3127,7 +3127,7 @@ func (c *ManagedZoneOperationsListCall) Header() http.Header {
func (c *ManagedZoneOperationsListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3330,7 +3330,7 @@ func (c *ManagedZonesCreateCall) Header() http.Header {
func (c *ManagedZonesCreateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3488,7 +3488,7 @@ func (c *ManagedZonesDeleteCall) Header() http.Header {
func (c *ManagedZonesDeleteCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3629,7 +3629,7 @@ func (c *ManagedZonesGetCall) Header() http.Header {
func (c *ManagedZonesGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3814,7 +3814,7 @@ func (c *ManagedZonesListCall) Header() http.Header {
func (c *ManagedZonesListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4003,7 +4003,7 @@ func (c *ManagedZonesPatchCall) Header() http.Header {
func (c *ManagedZonesPatchCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4171,7 +4171,7 @@ func (c *ManagedZonesUpdateCall) Header() http.Header {
func (c *ManagedZonesUpdateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4335,7 +4335,7 @@ func (c *PoliciesCreateCall) Header() http.Header {
func (c *PoliciesCreateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4494,7 +4494,7 @@ func (c *PoliciesDeleteCall) Header() http.Header {
func (c *PoliciesDeleteCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4635,7 +4635,7 @@ func (c *PoliciesGetCall) Header() http.Header {
func (c *PoliciesGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4812,7 +4812,7 @@ func (c *PoliciesListCall) Header() http.Header {
func (c *PoliciesListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4996,7 +4996,7 @@ func (c *PoliciesPatchCall) Header() http.Header {
func (c *PoliciesPatchCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5164,7 +5164,7 @@ func (c *PoliciesUpdateCall) Header() http.Header {
func (c *PoliciesUpdateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5337,7 +5337,7 @@ func (c *ProjectsGetCall) Header() http.Header {
func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5494,7 +5494,7 @@ func (c *ResourceRecordSetsCreateCall) Header() http.Header {
func (c *ResourceRecordSetsCreateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5666,7 +5666,7 @@ func (c *ResourceRecordSetsDeleteCall) Header() http.Header {
func (c *ResourceRecordSetsDeleteCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5857,7 +5857,7 @@ func (c *ResourceRecordSetsGetCall) Header() http.Header {
func (c *ResourceRecordSetsGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -6070,7 +6070,7 @@ func (c *ResourceRecordSetsListCall) Header() http.Header {
func (c *ResourceRecordSetsListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -6278,7 +6278,7 @@ func (c *ResourceRecordSetsPatchCall) Header() http.Header {
func (c *ResourceRecordSetsPatchCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211201")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
for k, v := range c.header_ {
reqHeaders[k] = v
}
diff --git a/vendor/google.golang.org/grpc/balancer/balancer.go b/vendor/google.golang.org/grpc/balancer/balancer.go
index 178de0898aa4..bcc6f5451c90 100644
--- a/vendor/google.golang.org/grpc/balancer/balancer.go
+++ b/vendor/google.golang.org/grpc/balancer/balancer.go
@@ -174,25 +174,32 @@ type ClientConn interface {
// BuildOptions contains additional information for Build.
type BuildOptions struct {
- // DialCreds is the transport credential the Balancer implementation can
- // use to dial to a remote load balancer server. The Balancer implementations
- // can ignore this if it does not need to talk to another party securely.
+ // DialCreds is the transport credentials to use when communicating with a
+ // remote load balancer server. Balancer implementations which do not
+ // communicate with a remote load balancer server can ignore this field.
DialCreds credentials.TransportCredentials
- // CredsBundle is the credentials bundle that the Balancer can use.
+ // CredsBundle is the credentials bundle to use when communicating with a
+ // remote load balancer server. Balancer implementations which do not
+ // communicate with a remote load balancer server can ignore this field.
CredsBundle credentials.Bundle
- // Dialer is the custom dialer the Balancer implementation can use to dial
- // to a remote load balancer server. The Balancer implementations
- // can ignore this if it doesn't need to talk to remote balancer.
+ // Dialer is the custom dialer to use when communicating with a remote load
+ // balancer server. Balancer implementations which do not communicate with a
+ // remote load balancer server can ignore this field.
Dialer func(context.Context, string) (net.Conn, error)
- // ChannelzParentID is the entity parent's channelz unique identification number.
+ // Authority is the server name to use as part of the authentication
+ // handshake when communicating with a remote load balancer server. Balancer
+ // implementations which do not communicate with a remote load balancer
+ // server can ignore this field.
+ Authority string
+ // ChannelzParentID is the parent ClientConn's channelz ID.
ChannelzParentID int64
// CustomUserAgent is the custom user agent set on the parent ClientConn.
// The balancer should set the same custom user agent if it creates a
// ClientConn.
CustomUserAgent string
- // Target contains the parsed address info of the dial target. It is the same resolver.Target as
- // passed to the resolver.
- // See the documentation for the resolver.Target type for details about what it contains.
+ // Target contains the parsed address info of the dial target. It is the
+ // same resolver.Target as passed to the resolver. See the documentation for
+ // the resolver.Target type for details about what it contains.
Target resolver.Target
}
diff --git a/vendor/google.golang.org/grpc/clientconn.go b/vendor/google.golang.org/grpc/clientconn.go
index 5a9e7d754fe2..28f09dc87073 100644
--- a/vendor/google.golang.org/grpc/clientconn.go
+++ b/vendor/google.golang.org/grpc/clientconn.go
@@ -83,13 +83,13 @@ var (
// errTransportCredsAndBundle indicates that creds bundle is used together
// with other individual Transport Credentials.
errTransportCredsAndBundle = errors.New("grpc: credentials.Bundle may not be used with individual TransportCredentials")
- // errTransportCredentialsMissing indicates that users want to transmit security
- // information (e.g., OAuth2 token) which requires secure connection on an insecure
- // connection.
+ // errNoTransportCredsInBundle indicated that the configured creds bundle
+ // returned a transport credentials which was nil.
+ errNoTransportCredsInBundle = errors.New("grpc: credentials.Bundle must return non-nil transport credentials")
+ // errTransportCredentialsMissing indicates that users want to transmit
+ // security information (e.g., OAuth2 token) which requires secure
+ // connection on an insecure connection.
errTransportCredentialsMissing = errors.New("grpc: the credentials require transport level security (use grpc.WithTransportCredentials() to set)")
- // errCredentialsConflict indicates that grpc.WithTransportCredentials()
- // and grpc.WithInsecure() are both called for a connection.
- errCredentialsConflict = errors.New("grpc: transport credentials are set for an insecure connection (grpc.WithTransportCredentials() and grpc.WithInsecure() are both called)")
)
const (
@@ -177,17 +177,20 @@ func DialContext(ctx context.Context, target string, opts ...DialOption) (conn *
cc.csMgr.channelzID = cc.channelzID
}
- if !cc.dopts.insecure {
- if cc.dopts.copts.TransportCredentials == nil && cc.dopts.copts.CredsBundle == nil {
- return nil, errNoTransportSecurity
- }
- if cc.dopts.copts.TransportCredentials != nil && cc.dopts.copts.CredsBundle != nil {
- return nil, errTransportCredsAndBundle
- }
- } else {
- if cc.dopts.copts.TransportCredentials != nil || cc.dopts.copts.CredsBundle != nil {
- return nil, errCredentialsConflict
- }
+ if cc.dopts.copts.TransportCredentials == nil && cc.dopts.copts.CredsBundle == nil {
+ return nil, errNoTransportSecurity
+ }
+ if cc.dopts.copts.TransportCredentials != nil && cc.dopts.copts.CredsBundle != nil {
+ return nil, errTransportCredsAndBundle
+ }
+ if cc.dopts.copts.CredsBundle != nil && cc.dopts.copts.CredsBundle.TransportCredentials() == nil {
+ return nil, errNoTransportCredsInBundle
+ }
+ transportCreds := cc.dopts.copts.TransportCredentials
+ if transportCreds == nil {
+ transportCreds = cc.dopts.copts.CredsBundle.TransportCredentials()
+ }
+ if transportCreds.Info().SecurityProtocol == "insecure" {
for _, cd := range cc.dopts.copts.PerRPCCredentials {
if cd.RequireTransportSecurity() {
return nil, errTransportCredentialsMissing
@@ -282,6 +285,7 @@ func DialContext(ctx context.Context, target string, opts ...DialOption) (conn *
DialCreds: credsClone,
CredsBundle: cc.dopts.copts.CredsBundle,
Dialer: cc.dopts.copts.Dialer,
+ Authority: cc.authority,
CustomUserAgent: cc.dopts.copts.UserAgent,
ChannelzParentID: cc.channelzID,
Target: cc.parsedTarget,
@@ -629,7 +633,10 @@ func (cc *ClientConn) updateResolverState(s resolver.State, err error) error {
}
var ret error
- if cc.dopts.disableServiceConfig || s.ServiceConfig == nil {
+ if cc.dopts.disableServiceConfig {
+ channelz.Infof(logger, cc.channelzID, "ignoring service config from resolver (%v) and applying the default because service config is disabled", s.ServiceConfig)
+ cc.maybeApplyDefaultServiceConfig(s.Addresses)
+ } else if s.ServiceConfig == nil {
cc.maybeApplyDefaultServiceConfig(s.Addresses)
// TODO: do we need to apply a failing LB policy if there is no
// default, per the error handling design?
diff --git a/vendor/google.golang.org/grpc/credentials/credentials.go b/vendor/google.golang.org/grpc/credentials/credentials.go
index a671107584f5..96ff1877e754 100644
--- a/vendor/google.golang.org/grpc/credentials/credentials.go
+++ b/vendor/google.golang.org/grpc/credentials/credentials.go
@@ -178,8 +178,18 @@ type TransportCredentials interface {
//
// This API is experimental.
type Bundle interface {
+ // TransportCredentials returns the transport credentials from the Bundle.
+ //
+ // Implementations must return non-nil transport credentials. If transport
+ // security is not needed by the Bundle, implementations may choose to
+ // return insecure.NewCredentials().
TransportCredentials() TransportCredentials
+
+ // PerRPCCredentials returns the per-RPC credentials from the Bundle.
+ //
+ // May be nil if per-RPC credentials are not needed.
PerRPCCredentials() PerRPCCredentials
+
// NewWithMode should make a copy of Bundle, and switch mode. Modifying the
// existing Bundle may cause races.
//
diff --git a/vendor/google.golang.org/grpc/credentials/insecure/insecure.go b/vendor/google.golang.org/grpc/credentials/insecure/insecure.go
new file mode 100644
index 000000000000..22a8f996a68b
--- /dev/null
+++ b/vendor/google.golang.org/grpc/credentials/insecure/insecure.go
@@ -0,0 +1,77 @@
+/*
+ *
+ * Copyright 2020 gRPC authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// Package insecure provides an implementation of the
+// credentials.TransportCredentials interface which disables transport security.
+//
+// Experimental
+//
+// Notice: This package is EXPERIMENTAL and may be changed or removed in a
+// later release.
+package insecure
+
+import (
+ "context"
+ "net"
+
+ "google.golang.org/grpc/credentials"
+)
+
+// NewCredentials returns a credentials which disables transport security.
+//
+// Note that using this credentials with per-RPC credentials which require
+// transport security is incompatible and will cause grpc.Dial() to fail.
+func NewCredentials() credentials.TransportCredentials {
+ return insecureTC{}
+}
+
+// insecureTC implements the insecure transport credentials. The handshake
+// methods simply return the passed in net.Conn and set the security level to
+// NoSecurity.
+type insecureTC struct{}
+
+func (insecureTC) ClientHandshake(ctx context.Context, _ string, conn net.Conn) (net.Conn, credentials.AuthInfo, error) {
+ return conn, info{credentials.CommonAuthInfo{SecurityLevel: credentials.NoSecurity}}, nil
+}
+
+func (insecureTC) ServerHandshake(conn net.Conn) (net.Conn, credentials.AuthInfo, error) {
+ return conn, info{credentials.CommonAuthInfo{SecurityLevel: credentials.NoSecurity}}, nil
+}
+
+func (insecureTC) Info() credentials.ProtocolInfo {
+ return credentials.ProtocolInfo{SecurityProtocol: "insecure"}
+}
+
+func (insecureTC) Clone() credentials.TransportCredentials {
+ return insecureTC{}
+}
+
+func (insecureTC) OverrideServerName(string) error {
+ return nil
+}
+
+// info contains the auth information for an insecure connection.
+// It implements the AuthInfo interface.
+type info struct {
+ credentials.CommonAuthInfo
+}
+
+// AuthType returns the type of info as a string.
+func (info) AuthType() string {
+ return "insecure"
+}
diff --git a/vendor/google.golang.org/grpc/dialoptions.go b/vendor/google.golang.org/grpc/dialoptions.go
index 40d8ba6596ab..063f1e903c01 100644
--- a/vendor/google.golang.org/grpc/dialoptions.go
+++ b/vendor/google.golang.org/grpc/dialoptions.go
@@ -27,9 +27,9 @@ import (
"google.golang.org/grpc/backoff"
"google.golang.org/grpc/balancer"
"google.golang.org/grpc/credentials"
+ "google.golang.org/grpc/credentials/insecure"
"google.golang.org/grpc/internal"
internalbackoff "google.golang.org/grpc/internal/backoff"
- "google.golang.org/grpc/internal/envconfig"
"google.golang.org/grpc/internal/transport"
"google.golang.org/grpc/keepalive"
"google.golang.org/grpc/resolver"
@@ -50,7 +50,6 @@ type dialOptions struct {
bs internalbackoff.Strategy
block bool
returnLastError bool
- insecure bool
timeout time.Duration
scChan <-chan ServiceConfig
authority string
@@ -228,18 +227,14 @@ func WithServiceConfig(c <-chan ServiceConfig) DialOption {
})
}
-// WithConnectParams configures the dialer to use the provided ConnectParams.
+// WithConnectParams configures the ClientConn to use the provided ConnectParams
+// for creating and maintaining connections to servers.
//
// The backoff configuration specified as part of the ConnectParams overrides
// all defaults specified in
// https://github.com/grpc/grpc/blob/master/doc/connection-backoff.md. Consider
// using the backoff.DefaultConfig as a base, in cases where you want to
// override only a subset of the backoff configuration.
-//
-// Experimental
-//
-// Notice: This API is EXPERIMENTAL and may be changed or removed in a
-// later release.
func WithConnectParams(p ConnectParams) DialOption {
return newFuncDialOption(func(o *dialOptions) {
o.bs = internalbackoff.Exponential{Config: p.Backoff}
@@ -303,11 +298,17 @@ func WithReturnConnectionError() DialOption {
}
// WithInsecure returns a DialOption which disables transport security for this
-// ClientConn. Note that transport security is required unless WithInsecure is
-// set.
+// ClientConn. Under the hood, it uses insecure.NewCredentials().
+//
+// Note that using this DialOption with per-RPC credentials (through
+// WithCredentialsBundle or WithPerRPCCredentials) which require transport
+// security is incompatible and will cause grpc.Dial() to fail.
+//
+// Deprecated: use insecure.NewCredentials() instead.
+// Will be supported throughout 1.x.
func WithInsecure() DialOption {
return newFuncDialOption(func(o *dialOptions) {
- o.insecure = true
+ o.copts.TransportCredentials = insecure.NewCredentials()
})
}
@@ -580,7 +581,6 @@ func withHealthCheckFunc(f internal.HealthChecker) DialOption {
func defaultDialOptions() dialOptions {
return dialOptions{
- disableRetry: !envconfig.Retry,
healthCheckFunc: internal.HealthCheckFunc,
copts: transport.ConnectOptions{
WriteBufferSize: defaultWriteBufSize,
diff --git a/vendor/google.golang.org/grpc/internal/channelz/funcs.go b/vendor/google.golang.org/grpc/internal/channelz/funcs.go
index 6d5760d95146..cd1807543eee 100644
--- a/vendor/google.golang.org/grpc/internal/channelz/funcs.go
+++ b/vendor/google.golang.org/grpc/internal/channelz/funcs.go
@@ -204,9 +204,9 @@ func RegisterChannel(c Channel, pid int64, ref string) int64 {
trace: &channelTrace{createdTime: time.Now(), events: make([]*TraceEvent, 0, getMaxTraceEntry())},
}
if pid == 0 {
- db.get().addChannel(id, cn, true, pid, ref)
+ db.get().addChannel(id, cn, true, pid)
} else {
- db.get().addChannel(id, cn, false, pid, ref)
+ db.get().addChannel(id, cn, false, pid)
}
return id
}
@@ -228,7 +228,7 @@ func RegisterSubChannel(c Channel, pid int64, ref string) int64 {
pid: pid,
trace: &channelTrace{createdTime: time.Now(), events: make([]*TraceEvent, 0, getMaxTraceEntry())},
}
- db.get().addSubChannel(id, sc, pid, ref)
+ db.get().addSubChannel(id, sc, pid)
return id
}
@@ -258,7 +258,7 @@ func RegisterListenSocket(s Socket, pid int64, ref string) int64 {
}
id := idGen.genID()
ls := &listenSocket{refName: ref, s: s, id: id, pid: pid}
- db.get().addListenSocket(id, ls, pid, ref)
+ db.get().addListenSocket(id, ls, pid)
return id
}
@@ -273,11 +273,11 @@ func RegisterNormalSocket(s Socket, pid int64, ref string) int64 {
}
id := idGen.genID()
ns := &normalSocket{refName: ref, s: s, id: id, pid: pid}
- db.get().addNormalSocket(id, ns, pid, ref)
+ db.get().addNormalSocket(id, ns, pid)
return id
}
-// RemoveEntry removes an entry with unique channelz trakcing id to be id from
+// RemoveEntry removes an entry with unique channelz tracking id to be id from
// channelz database.
func RemoveEntry(id int64) {
db.get().removeEntry(id)
@@ -333,7 +333,7 @@ func (c *channelMap) addServer(id int64, s *server) {
c.mu.Unlock()
}
-func (c *channelMap) addChannel(id int64, cn *channel, isTopChannel bool, pid int64, ref string) {
+func (c *channelMap) addChannel(id int64, cn *channel, isTopChannel bool, pid int64) {
c.mu.Lock()
cn.cm = c
cn.trace.cm = c
@@ -346,7 +346,7 @@ func (c *channelMap) addChannel(id int64, cn *channel, isTopChannel bool, pid in
c.mu.Unlock()
}
-func (c *channelMap) addSubChannel(id int64, sc *subChannel, pid int64, ref string) {
+func (c *channelMap) addSubChannel(id int64, sc *subChannel, pid int64) {
c.mu.Lock()
sc.cm = c
sc.trace.cm = c
@@ -355,7 +355,7 @@ func (c *channelMap) addSubChannel(id int64, sc *subChannel, pid int64, ref stri
c.mu.Unlock()
}
-func (c *channelMap) addListenSocket(id int64, ls *listenSocket, pid int64, ref string) {
+func (c *channelMap) addListenSocket(id int64, ls *listenSocket, pid int64) {
c.mu.Lock()
ls.cm = c
c.listenSockets[id] = ls
@@ -363,7 +363,7 @@ func (c *channelMap) addListenSocket(id int64, ls *listenSocket, pid int64, ref
c.mu.Unlock()
}
-func (c *channelMap) addNormalSocket(id int64, ns *normalSocket, pid int64, ref string) {
+func (c *channelMap) addNormalSocket(id int64, ns *normalSocket, pid int64) {
c.mu.Lock()
ns.cm = c
c.normalSockets[id] = ns
diff --git a/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go b/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
index 9f25a67fc6bd..6f0272543110 100644
--- a/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
+++ b/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
@@ -22,20 +22,14 @@ package envconfig
import (
"os"
"strings"
-
- xdsenv "google.golang.org/grpc/internal/xds/env"
)
const (
prefix = "GRPC_GO_"
- retryStr = prefix + "RETRY"
txtErrIgnoreStr = prefix + "IGNORE_TXT_ERRORS"
)
var (
- // Retry is enabled unless explicitly disabled via "GRPC_GO_RETRY=off" or
- // if XDS retry support is explicitly disabled.
- Retry = !strings.EqualFold(os.Getenv(retryStr), "off") && xdsenv.RetrySupport
// TXTErrIgnore is set if TXT errors should be ignored ("GRPC_GO_IGNORE_TXT_ERRORS" is not "false").
TXTErrIgnore = !strings.EqualFold(os.Getenv(txtErrIgnoreStr), "false")
)
diff --git a/vendor/google.golang.org/grpc/internal/xds/env/env.go b/vendor/google.golang.org/grpc/internal/envconfig/xds.go
similarity index 50%
rename from vendor/google.golang.org/grpc/internal/xds/env/env.go
rename to vendor/google.golang.org/grpc/internal/envconfig/xds.go
index 87d3c2433a4f..93522d716d1e 100644
--- a/vendor/google.golang.org/grpc/internal/xds/env/env.go
+++ b/vendor/google.golang.org/grpc/internal/envconfig/xds.go
@@ -16,9 +16,7 @@
*
*/
-// Package env acts a single source of definition for all environment variables
-// related to the xDS implementation in gRPC.
-package env
+package envconfig
import (
"os"
@@ -26,72 +24,67 @@ import (
)
const (
- // BootstrapFileNameEnv is the env variable to set bootstrap file name.
+ // XDSBootstrapFileNameEnv is the env variable to set bootstrap file name.
// Do not use this and read from env directly. Its value is read and kept in
// variable BootstrapFileName.
//
// When both bootstrap FileName and FileContent are set, FileName is used.
- BootstrapFileNameEnv = "GRPC_XDS_BOOTSTRAP"
- // BootstrapFileContentEnv is the env variable to set bootstrapp file
+ XDSBootstrapFileNameEnv = "GRPC_XDS_BOOTSTRAP"
+ // XDSBootstrapFileContentEnv is the env variable to set bootstrapp file
// content. Do not use this and read from env directly. Its value is read
// and kept in variable BootstrapFileName.
//
// When both bootstrap FileName and FileContent are set, FileName is used.
- BootstrapFileContentEnv = "GRPC_XDS_BOOTSTRAP_CONFIG"
+ XDSBootstrapFileContentEnv = "GRPC_XDS_BOOTSTRAP_CONFIG"
ringHashSupportEnv = "GRPC_XDS_EXPERIMENTAL_ENABLE_RING_HASH"
clientSideSecuritySupportEnv = "GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT"
aggregateAndDNSSupportEnv = "GRPC_XDS_EXPERIMENTAL_ENABLE_AGGREGATE_AND_LOGICAL_DNS_CLUSTER"
- retrySupportEnv = "GRPC_XDS_EXPERIMENTAL_ENABLE_RETRY"
rbacSupportEnv = "GRPC_XDS_EXPERIMENTAL_RBAC"
+ federationEnv = "GRPC_EXPERIMENTAL_XDS_FEDERATION"
- c2pResolverSupportEnv = "GRPC_EXPERIMENTAL_GOOGLE_C2P_RESOLVER"
c2pResolverTestOnlyTrafficDirectorURIEnv = "GRPC_TEST_ONLY_GOOGLE_C2P_RESOLVER_TRAFFIC_DIRECTOR_URI"
)
var (
- // BootstrapFileName holds the name of the file which contains xDS bootstrap
- // configuration. Users can specify the location of the bootstrap file by
- // setting the environment variable "GRPC_XDS_BOOTSTRAP".
+ // XDSBootstrapFileName holds the name of the file which contains xDS
+ // bootstrap configuration. Users can specify the location of the bootstrap
+ // file by setting the environment variable "GRPC_XDS_BOOTSTRAP".
//
// When both bootstrap FileName and FileContent are set, FileName is used.
- BootstrapFileName = os.Getenv(BootstrapFileNameEnv)
- // BootstrapFileContent holds the content of the xDS bootstrap
- // configuration. Users can specify the bootstrap config by
- // setting the environment variable "GRPC_XDS_BOOTSTRAP_CONFIG".
+ XDSBootstrapFileName = os.Getenv(XDSBootstrapFileNameEnv)
+ // XDSBootstrapFileContent holds the content of the xDS bootstrap
+ // configuration. Users can specify the bootstrap config by setting the
+ // environment variable "GRPC_XDS_BOOTSTRAP_CONFIG".
//
// When both bootstrap FileName and FileContent are set, FileName is used.
- BootstrapFileContent = os.Getenv(BootstrapFileContentEnv)
- // RingHashSupport indicates whether ring hash support is enabled, which can
- // be disabled by setting the environment variable
+ XDSBootstrapFileContent = os.Getenv(XDSBootstrapFileContentEnv)
+ // XDSRingHash indicates whether ring hash support is enabled, which can be
+ // disabled by setting the environment variable
// "GRPC_XDS_EXPERIMENTAL_ENABLE_RING_HASH" to "false".
- RingHashSupport = !strings.EqualFold(os.Getenv(ringHashSupportEnv), "false")
- // ClientSideSecuritySupport is used to control processing of security
+ XDSRingHash = !strings.EqualFold(os.Getenv(ringHashSupportEnv), "false")
+ // XDSClientSideSecurity is used to control processing of security
// configuration on the client-side.
//
// Note that there is no env var protection for the server-side because we
// have a brand new API on the server-side and users explicitly need to use
// the new API to get security integration on the server.
- ClientSideSecuritySupport = !strings.EqualFold(os.Getenv(clientSideSecuritySupportEnv), "false")
- // AggregateAndDNSSupportEnv indicates whether processing of aggregated
- // cluster and DNS cluster is enabled, which can be enabled by setting the
+ XDSClientSideSecurity = !strings.EqualFold(os.Getenv(clientSideSecuritySupportEnv), "false")
+ // XDSAggregateAndDNS indicates whether processing of aggregated cluster
+ // and DNS cluster is enabled, which can be enabled by setting the
// environment variable
// "GRPC_XDS_EXPERIMENTAL_ENABLE_AGGREGATE_AND_LOGICAL_DNS_CLUSTER" to
// "true".
- AggregateAndDNSSupportEnv = strings.EqualFold(os.Getenv(aggregateAndDNSSupportEnv), "true")
+ XDSAggregateAndDNS = strings.EqualFold(os.Getenv(aggregateAndDNSSupportEnv), "true")
- // RetrySupport indicates whether xDS retry is enabled.
- RetrySupport = !strings.EqualFold(os.Getenv(retrySupportEnv), "false")
-
- // RBACSupport indicates whether xDS configured RBAC HTTP Filter is enabled,
+ // XDSRBAC indicates whether xDS configured RBAC HTTP Filter is enabled,
// which can be disabled by setting the environment variable
// "GRPC_XDS_EXPERIMENTAL_RBAC" to "false".
- RBACSupport = !strings.EqualFold(os.Getenv(rbacSupportEnv), "false")
+ XDSRBAC = !strings.EqualFold(os.Getenv(rbacSupportEnv), "false")
+
+ // XDSFederation indicates whether federation support is enabled.
+ XDSFederation = strings.EqualFold(os.Getenv(federationEnv), "true")
- // C2PResolverSupport indicates whether support for C2P resolver is enabled.
- // This can be enabled by setting the environment variable
- // "GRPC_EXPERIMENTAL_GOOGLE_C2P_RESOLVER" to "true".
- C2PResolverSupport = strings.EqualFold(os.Getenv(c2pResolverSupportEnv), "true")
// C2PResolverTestOnlyTrafficDirectorURI is the TD URI for testing.
C2PResolverTestOnlyTrafficDirectorURI = os.Getenv(c2pResolverTestOnlyTrafficDirectorURIEnv)
)
diff --git a/vendor/google.golang.org/grpc/internal/transport/flowcontrol.go b/vendor/google.golang.org/grpc/internal/transport/flowcontrol.go
index f262edd8ecda..97198c515889 100644
--- a/vendor/google.golang.org/grpc/internal/transport/flowcontrol.go
+++ b/vendor/google.golang.org/grpc/internal/transport/flowcontrol.go
@@ -136,12 +136,10 @@ type inFlow struct {
// newLimit updates the inflow window to a new value n.
// It assumes that n is always greater than the old limit.
-func (f *inFlow) newLimit(n uint32) uint32 {
+func (f *inFlow) newLimit(n uint32) {
f.mu.Lock()
- d := n - f.limit
f.limit = n
f.mu.Unlock()
- return d
}
func (f *inFlow) maybeAdjust(n uint32) uint32 {
diff --git a/vendor/google.golang.org/grpc/internal/transport/http2_client.go b/vendor/google.golang.org/grpc/internal/transport/http2_client.go
index 2521a7d7a408..f0c72d337105 100644
--- a/vendor/google.golang.org/grpc/internal/transport/http2_client.go
+++ b/vendor/google.golang.org/grpc/internal/transport/http2_client.go
@@ -201,6 +201,12 @@ func newHTTP2Client(connectCtx, ctx context.Context, addr resolver.Address, opts
}
}()
+ // gRPC, resolver, balancer etc. can specify arbitrary data in the
+ // Attributes field of resolver.Address, which is shoved into connectCtx
+ // and passed to the dialer and credential handshaker. This makes it possible for
+ // address specific arbitrary data to reach custom dialers and credential handshakers.
+ connectCtx = icredentials.NewClientHandshakeInfoContext(connectCtx, credentials.ClientHandshakeInfo{Attributes: addr.Attributes})
+
conn, err := dial(connectCtx, opts.Dialer, addr, opts.UseProxy, opts.UserAgent)
if err != nil {
if opts.FailOnNonTempDialError {
@@ -245,11 +251,6 @@ func newHTTP2Client(connectCtx, ctx context.Context, addr resolver.Address, opts
}
}
if transportCreds != nil {
- // gRPC, resolver, balancer etc. can specify arbitrary data in the
- // Attributes field of resolver.Address, which is shoved into connectCtx
- // and passed to the credential handshaker. This makes it possible for
- // address specific arbitrary data to reach the credential handshaker.
- connectCtx = icredentials.NewClientHandshakeInfoContext(connectCtx, credentials.ClientHandshakeInfo{Attributes: addr.Attributes})
rawConn := conn
// Pull the deadline from the connectCtx, which will be used for
// timeouts in the authentication protocol handshake. Can ignore the
@@ -587,7 +588,7 @@ func (t *http2Client) getTrAuthData(ctx context.Context, audience string) (map[s
return nil, err
}
- return nil, status.Errorf(codes.Unauthenticated, "transport: %v", err)
+ return nil, status.Errorf(codes.Unauthenticated, "transport: per-RPC creds failed due to error: %v", err)
}
for k, v := range data {
// Capital header names are illegal in HTTP/2.
@@ -1556,7 +1557,7 @@ func minTime(a, b time.Duration) time.Duration {
return b
}
-// keepalive running in a separate goroutune makes sure the connection is alive by sending pings.
+// keepalive running in a separate goroutine makes sure the connection is alive by sending pings.
func (t *http2Client) keepalive() {
p := &ping{data: [8]byte{}}
// True iff a ping has been sent, and no data has been received since then.
diff --git a/vendor/google.golang.org/grpc/internal/transport/http2_server.go b/vendor/google.golang.org/grpc/internal/transport/http2_server.go
index f2cad9ebc311..2c6eaf0e59cf 100644
--- a/vendor/google.golang.org/grpc/internal/transport/http2_server.go
+++ b/vendor/google.golang.org/grpc/internal/transport/http2_server.go
@@ -73,7 +73,6 @@ type http2Server struct {
writerDone chan struct{} // sync point to enable testing.
remoteAddr net.Addr
localAddr net.Addr
- maxStreamID uint32 // max stream ID ever seen
authInfo credentials.AuthInfo // auth info about the connection
inTapHandle tap.ServerInHandle
framer *framer
@@ -123,6 +122,11 @@ type http2Server struct {
bufferPool *bufferPool
connectionID uint64
+
+ // maxStreamMu guards the maximum stream ID
+ // This lock may not be taken if mu is already held.
+ maxStreamMu sync.Mutex
+ maxStreamID uint32 // max stream ID ever seen
}
// NewServerTransport creates a http2 transport with conn and configuration
@@ -334,6 +338,10 @@ func NewServerTransport(conn net.Conn, config *ServerConfig) (_ ServerTransport,
// operateHeader takes action on the decoded headers.
func (t *http2Server) operateHeaders(frame *http2.MetaHeadersFrame, handle func(*Stream), traceCtx func(context.Context, string) context.Context) (fatal bool) {
+ // Acquire max stream ID lock for entire duration
+ t.maxStreamMu.Lock()
+ defer t.maxStreamMu.Unlock()
+
streamID := frame.Header().StreamID
// frame.Truncated is set to true when framer detects that the current header
@@ -348,6 +356,15 @@ func (t *http2Server) operateHeaders(frame *http2.MetaHeadersFrame, handle func(
return false
}
+ if streamID%2 != 1 || streamID <= t.maxStreamID {
+ // illegal gRPC stream id.
+ if logger.V(logLevel) {
+ logger.Errorf("transport: http2Server.HandleStreams received an illegal stream id: %v", streamID)
+ }
+ return true
+ }
+ t.maxStreamID = streamID
+
buf := newRecvBuffer()
s := &Stream{
id: streamID,
@@ -355,7 +372,6 @@ func (t *http2Server) operateHeaders(frame *http2.MetaHeadersFrame, handle func(
buf: buf,
fc: &inFlow{limit: uint32(t.initialWindowSize)},
}
-
var (
// If a gRPC Response-Headers has already been received, then it means
// that the peer is speaking gRPC and we are in gRPC mode.
@@ -498,16 +514,6 @@ func (t *http2Server) operateHeaders(frame *http2.MetaHeadersFrame, handle func(
s.cancel()
return false
}
- if streamID%2 != 1 || streamID <= t.maxStreamID {
- t.mu.Unlock()
- // illegal gRPC stream id.
- if logger.V(logLevel) {
- logger.Errorf("transport: http2Server.HandleStreams received an illegal stream id: %v", streamID)
- }
- s.cancel()
- return true
- }
- t.maxStreamID = streamID
if httpMethod != http.MethodPost {
t.mu.Unlock()
if logger.V(logLevel) {
@@ -1293,20 +1299,23 @@ var goAwayPing = &ping{data: [8]byte{1, 6, 1, 8, 0, 3, 3, 9}}
// Handles outgoing GoAway and returns true if loopy needs to put itself
// in draining mode.
func (t *http2Server) outgoingGoAwayHandler(g *goAway) (bool, error) {
+ t.maxStreamMu.Lock()
t.mu.Lock()
if t.state == closing { // TODO(mmukhi): This seems unnecessary.
t.mu.Unlock()
+ t.maxStreamMu.Unlock()
// The transport is closing.
return false, ErrConnClosing
}
- sid := t.maxStreamID
if !g.headsUp {
// Stop accepting more streams now.
t.state = draining
+ sid := t.maxStreamID
if len(t.activeStreams) == 0 {
g.closeConn = true
}
t.mu.Unlock()
+ t.maxStreamMu.Unlock()
if err := t.framer.fr.WriteGoAway(sid, g.code, g.debugData); err != nil {
return false, err
}
@@ -1319,6 +1328,7 @@ func (t *http2Server) outgoingGoAwayHandler(g *goAway) (bool, error) {
return true, nil
}
t.mu.Unlock()
+ t.maxStreamMu.Unlock()
// For a graceful close, send out a GoAway with stream ID of MaxUInt32,
// Follow that with a ping and wait for the ack to come back or a timer
// to expire. During this time accept new streams since they might have
diff --git a/vendor/google.golang.org/grpc/internal/transport/proxy.go b/vendor/google.golang.org/grpc/internal/transport/proxy.go
index a662bf39a6c8..415961987870 100644
--- a/vendor/google.golang.org/grpc/internal/transport/proxy.go
+++ b/vendor/google.golang.org/grpc/internal/transport/proxy.go
@@ -37,7 +37,7 @@ var (
httpProxyFromEnvironment = http.ProxyFromEnvironment
)
-func mapAddress(ctx context.Context, address string) (*url.URL, error) {
+func mapAddress(address string) (*url.URL, error) {
req := &http.Request{
URL: &url.URL{
Scheme: "https",
@@ -114,7 +114,7 @@ func doHTTPConnectHandshake(ctx context.Context, conn net.Conn, backendAddr stri
// connection.
func proxyDial(ctx context.Context, addr string, grpcUA string) (conn net.Conn, err error) {
newAddr := addr
- proxyURL, err := mapAddress(ctx, addr)
+ proxyURL, err := mapAddress(addr)
if err != nil {
return nil, err
}
diff --git a/vendor/google.golang.org/grpc/pickfirst.go b/vendor/google.golang.org/grpc/pickfirst.go
index f194d14a0816..5168b62b078a 100644
--- a/vendor/google.golang.org/grpc/pickfirst.go
+++ b/vendor/google.golang.org/grpc/pickfirst.go
@@ -125,7 +125,7 @@ func (b *pickfirstBalancer) Close() {
}
func (b *pickfirstBalancer) ExitIdle() {
- if b.state == connectivity.Idle {
+ if b.sc != nil && b.state == connectivity.Idle {
b.sc.Connect()
}
}
diff --git a/vendor/google.golang.org/grpc/regenerate.sh b/vendor/google.golang.org/grpc/regenerate.sh
index dfd3226a1d96..a0a71aae9681 100644
--- a/vendor/google.golang.org/grpc/regenerate.sh
+++ b/vendor/google.golang.org/grpc/regenerate.sh
@@ -102,8 +102,8 @@ done
# The go_package option in grpc/lookup/v1/rls.proto doesn't match the
# current location. Move it into the right place.
-mkdir -p ${WORKDIR}/out/google.golang.org/grpc/balancer/rls/internal/proto/grpc_lookup_v1
-mv ${WORKDIR}/out/google.golang.org/grpc/lookup/grpc_lookup_v1/* ${WORKDIR}/out/google.golang.org/grpc/balancer/rls/internal/proto/grpc_lookup_v1
+mkdir -p ${WORKDIR}/out/google.golang.org/grpc/internal/proto/grpc_lookup_v1
+mv ${WORKDIR}/out/google.golang.org/grpc/lookup/grpc_lookup_v1/* ${WORKDIR}/out/google.golang.org/grpc/internal/proto/grpc_lookup_v1
# grpc_testingv3/testv3.pb.go is not re-generated because it was
# intentionally generated by an older version of protoc-gen-go.
diff --git a/vendor/google.golang.org/grpc/rpc_util.go b/vendor/google.golang.org/grpc/rpc_util.go
index 87987a2e652f..5d407b004b0e 100644
--- a/vendor/google.golang.org/grpc/rpc_util.go
+++ b/vendor/google.golang.org/grpc/rpc_util.go
@@ -712,13 +712,11 @@ func recvAndDecompress(p *parser, s *transport.Stream, dc Decompressor, maxRecei
if err != nil {
return nil, status.Errorf(codes.Internal, "grpc: failed to decompress the received message %v", err)
}
- } else {
- size = len(d)
- }
- if size > maxReceiveMessageSize {
- // TODO: Revisit the error code. Currently keep it consistent with java
- // implementation.
- return nil, status.Errorf(codes.ResourceExhausted, "grpc: received message larger than max (%d vs. %d)", size, maxReceiveMessageSize)
+ if size > maxReceiveMessageSize {
+ // TODO: Revisit the error code. Currently keep it consistent with java
+ // implementation.
+ return nil, status.Errorf(codes.ResourceExhausted, "grpc: received message after decompression larger than max (%d vs. %d)", size, maxReceiveMessageSize)
+ }
}
return d, nil
}
diff --git a/vendor/google.golang.org/grpc/status/status.go b/vendor/google.golang.org/grpc/status/status.go
index af2cffe985c0..6d163b6e3842 100644
--- a/vendor/google.golang.org/grpc/status/status.go
+++ b/vendor/google.golang.org/grpc/status/status.go
@@ -29,6 +29,7 @@ package status
import (
"context"
+ "errors"
"fmt"
spb "google.golang.org/genproto/googleapis/rpc/status"
@@ -117,18 +118,18 @@ func Code(err error) codes.Code {
return codes.Unknown
}
-// FromContextError converts a context error into a Status. It returns a
-// Status with codes.OK if err is nil, or a Status with codes.Unknown if err is
-// non-nil and not a context error.
+// FromContextError converts a context error or wrapped context error into a
+// Status. It returns a Status with codes.OK if err is nil, or a Status with
+// codes.Unknown if err is non-nil and not a context error.
func FromContextError(err error) *Status {
- switch err {
- case nil:
+ if err == nil {
return nil
- case context.DeadlineExceeded:
+ }
+ if errors.Is(err, context.DeadlineExceeded) {
return New(codes.DeadlineExceeded, err.Error())
- case context.Canceled:
+ }
+ if errors.Is(err, context.Canceled) {
return New(codes.Canceled, err.Error())
- default:
- return New(codes.Unknown, err.Error())
}
+ return New(codes.Unknown, err.Error())
}
diff --git a/vendor/google.golang.org/grpc/version.go b/vendor/google.golang.org/grpc/version.go
index 1a5fd584af38..8ef0958797fb 100644
--- a/vendor/google.golang.org/grpc/version.go
+++ b/vendor/google.golang.org/grpc/version.go
@@ -19,4 +19,4 @@
package grpc
// Version is the current grpc version.
-const Version = "1.42.0"
+const Version = "1.43.0"
diff --git a/vendor/k8s.io/cloud-provider/credentialconfig/registry.go b/vendor/k8s.io/cloud-provider/credentialconfig/registry.go
deleted file mode 100644
index eac2173e8add..000000000000
--- a/vendor/k8s.io/cloud-provider/credentialconfig/registry.go
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
-Copyright 2021 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package credentialconfig
-
-// Code taken from /pkg/credentialprovider/config.go
-
-// RegistryConfig represents the config file used by the docker CLI.
-// This config that represents the credentials that should be used
-// when pulling images from specific image repositories.
-type RegistryConfig map[string]RegistryConfigEntry
-
-// RegistryConfigEntry wraps a docker config as a entry
-type RegistryConfigEntry struct {
- Username string
- Password string
- Email string
-}
diff --git a/vendor/k8s.io/component-base/version/.gitattributes b/vendor/k8s.io/component-base/version/.gitattributes
deleted file mode 100644
index 7e349eff60bd..000000000000
--- a/vendor/k8s.io/component-base/version/.gitattributes
+++ /dev/null
@@ -1 +0,0 @@
-base.go export-subst
diff --git a/vendor/k8s.io/component-base/version/base.go b/vendor/k8s.io/component-base/version/base.go
deleted file mode 100644
index b753b7d191fc..000000000000
--- a/vendor/k8s.io/component-base/version/base.go
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
-Copyright 2019 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package version
-
-// Base version information.
-//
-// This is the fallback data used when version information from git is not
-// provided via go ldflags. It provides an approximation of the Kubernetes
-// version for ad-hoc builds (e.g. `go build`) that cannot get the version
-// information from git.
-//
-// If you are looking at these fields in the git tree, they look
-// strange. They are modified on the fly by the build process. The
-// in-tree values are dummy values used for "git archive", which also
-// works for GitHub tar downloads.
-//
-// When releasing a new Kubernetes version, this file is updated by
-// build/mark_new_version.sh to reflect the new version, and then a
-// git annotated tag (using format vX.Y where X == Major version and Y
-// == Minor version) is created to point to the commit that updates
-// component-base/version/base.go
-var (
- // TODO: Deprecate gitMajor and gitMinor, use only gitVersion
- // instead. First step in deprecation, keep the fields but make
- // them irrelevant. (Next we'll take it out, which may muck with
- // scripts consuming the kubectl version output - but most of
- // these should be looking at gitVersion already anyways.)
- gitMajor string // major version, always numeric
- gitMinor string // minor version, numeric possibly followed by "+"
-
- // semantic version, derived by build scripts (see
- // https://github.com/kubernetes/community/blob/master/contributors/design-proposals/release/versioning.md
- // for a detailed discussion of this field)
- //
- // TODO: This field is still called "gitVersion" for legacy
- // reasons. For prerelease versions, the build metadata on the
- // semantic version is a git hash, but the version itself is no
- // longer the direct output of "git describe", but a slight
- // translation to be semver compliant.
-
- // NOTE: The $Format strings are replaced during 'git archive' thanks to the
- // companion .gitattributes file containing 'export-subst' in this same
- // directory. See also https://git-scm.com/docs/gitattributes
- gitVersion = "v0.0.0-master+$Format:%H$"
- gitCommit = "$Format:%H$" // sha1 from git, output of $(git rev-parse HEAD)
- gitTreeState = "" // state of git tree, either "clean" or "dirty"
-
- buildDate = "1970-01-01T00:00:00Z" // build date in ISO8601 format, output of $(date -u +'%Y-%m-%dT%H:%M:%SZ')
-)
diff --git a/vendor/k8s.io/component-base/version/version.go b/vendor/k8s.io/component-base/version/version.go
deleted file mode 100644
index d1e76dc00e05..000000000000
--- a/vendor/k8s.io/component-base/version/version.go
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
-Copyright 2019 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package version
-
-import (
- "fmt"
- "runtime"
-
- apimachineryversion "k8s.io/apimachinery/pkg/version"
-)
-
-// Get returns the overall codebase version. It's for detecting
-// what code a binary was built from.
-func Get() apimachineryversion.Info {
- // These variables typically come from -ldflags settings and in
- // their absence fallback to the settings in ./base.go
- return apimachineryversion.Info{
- Major: gitMajor,
- Minor: gitMinor,
- GitVersion: gitVersion,
- GitCommit: gitCommit,
- GitTreeState: gitTreeState,
- BuildDate: buildDate,
- GoVersion: runtime.Version(),
- Compiler: runtime.Compiler,
- Platform: fmt.Sprintf("%s/%s", runtime.GOOS, runtime.GOARCH),
- }
-}
diff --git a/vendor/k8s.io/kube-openapi/pkg/common/common.go b/vendor/k8s.io/kube-openapi/pkg/common/common.go
index 682014bda941..cf1d01f903db 100644
--- a/vendor/k8s.io/kube-openapi/pkg/common/common.go
+++ b/vendor/k8s.io/kube-openapi/pkg/common/common.go
@@ -57,6 +57,11 @@ type PathHandler interface {
Handle(path string, handler http.Handler)
}
+type PathHandlerByGroupVersion interface {
+ Handle(path string, handler http.Handler)
+ HandlePrefix(path string, handler http.Handler)
+}
+
// Config is set of configuration for openAPI spec generation.
type Config struct {
// List of supported protocols such as https, http, etc.
diff --git a/vendor/k8s.io/kube-openapi/pkg/generators/enum.go b/vendor/k8s.io/kube-openapi/pkg/generators/enum.go
new file mode 100644
index 000000000000..8b1994fec978
--- /dev/null
+++ b/vendor/k8s.io/kube-openapi/pkg/generators/enum.go
@@ -0,0 +1,152 @@
+/*
+Copyright 2021 The Kubernetes Authors.
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+
+package generators
+
+import (
+ "fmt"
+ "regexp"
+ "sort"
+ "strings"
+
+ "k8s.io/gengo/generator"
+ "k8s.io/gengo/types"
+)
+
+const tagEnumType = "enum"
+const enumTypeDescriptionHeader = "Possible enum values:"
+
+type enumValue struct {
+ Name string
+ Value string
+ Comment string
+}
+
+type enumType struct {
+ Name types.Name
+ Values []*enumValue
+}
+
+// enumMap is a map from the name to the matching enum type.
+type enumMap map[types.Name]*enumType
+
+type enumContext struct {
+ enumTypes enumMap
+}
+
+func newEnumContext(c *generator.Context) *enumContext {
+ return &enumContext{enumTypes: parseEnums(c)}
+}
+
+// EnumType checks and finds the enumType for a given type.
+// If the given type is a known enum type, returns the enumType, true
+// Otherwise, returns nil, false
+func (ec *enumContext) EnumType(t *types.Type) (enum *enumType, isEnum bool) {
+ enum, ok := ec.enumTypes[t.Name]
+ return enum, ok
+}
+
+// ValueStrings returns all possible values of the enum type as strings
+// the results are sorted and quoted as Go literals.
+func (et *enumType) ValueStrings() []string {
+ var values []string
+ for _, value := range et.Values {
+ // use "%q" format to generate a Go literal of the string const value
+ values = append(values, fmt.Sprintf("%q", value.Value))
+ }
+ sort.Strings(values)
+ return values
+}
+
+// DescriptionLines returns a description of the enum in this format:
+//
+// Possible enum values:
+// - `"value1"` description 1
+// - `"value2"` description 2
+func (et *enumType) DescriptionLines() []string {
+ var lines []string
+ for _, value := range et.Values {
+ lines = append(lines, value.Description())
+ }
+ sort.Strings(lines)
+ // Prepend an empty string to initiate a new paragraph.
+ return append([]string{"", enumTypeDescriptionHeader}, lines...)
+}
+
+func parseEnums(c *generator.Context) enumMap {
+ // First, find the builtin "string" type
+ stringType := c.Universe.Type(types.Name{Name: "string"})
+
+ enumTypes := make(enumMap)
+ for _, p := range c.Universe {
+ // find all enum types.
+ for _, t := range p.Types {
+ if isEnumType(stringType, t) {
+ if _, ok := enumTypes[t.Name]; !ok {
+ enumTypes[t.Name] = &enumType{
+ Name: t.Name,
+ }
+ }
+ }
+ }
+ // find all enum values from constants, and try to match each with its type.
+ for _, c := range p.Constants {
+ enumType := c.Underlying
+ if _, ok := enumTypes[enumType.Name]; ok {
+ value := &enumValue{
+ Name: c.Name.Name,
+ Value: *c.ConstValue,
+ Comment: strings.Join(c.CommentLines, " "),
+ }
+ enumTypes[enumType.Name].appendValue(value)
+ }
+ }
+ }
+
+ return enumTypes
+}
+
+func (et *enumType) appendValue(value *enumValue) {
+ et.Values = append(et.Values, value)
+}
+
+// Description returns the description line for the enumValue
+// with the format:
+// - `"FooValue"` is the Foo value
+func (ev *enumValue) Description() string {
+ comment := strings.TrimSpace(ev.Comment)
+ // The comment should starts with the type name, trim it first.
+ comment = strings.TrimPrefix(comment, ev.Name)
+ // Trim the possible space after previous step.
+ comment = strings.TrimSpace(comment)
+ // The comment may be multiline, cascade all consecutive whitespaces.
+ comment = whitespaceRegex.ReplaceAllString(comment, " ")
+ return fmt.Sprintf(" - `%q` %s", ev.Value, comment)
+}
+
+// isEnumType checks if a given type is an enum by the definition
+// An enum type should be an alias of string and has tag '+enum' in its comment.
+// Additionally, pass the type of builtin 'string' to check against.
+func isEnumType(stringType *types.Type, t *types.Type) bool {
+ return t.Kind == types.Alias && t.Underlying == stringType && hasEnumTag(t)
+}
+
+func hasEnumTag(t *types.Type) bool {
+ return types.ExtractCommentTags("+", t.CommentLines)[tagEnumType] != nil
+}
+
+// whitespaceRegex is the regex for consecutive whitespaces.
+var whitespaceRegex = regexp.MustCompile(`\s+`)
diff --git a/vendor/k8s.io/kube-openapi/pkg/generators/extension.go b/vendor/k8s.io/kube-openapi/pkg/generators/extension.go
index 15a911288f3e..e37d93ef733b 100644
--- a/vendor/k8s.io/kube-openapi/pkg/generators/extension.go
+++ b/vendor/k8s.io/kube-openapi/pkg/generators/extension.go
@@ -66,6 +66,10 @@ var tagToExtension = map[string]extensionAttributes{
kind: types.Struct,
allowedValues: sets.NewString("atomic", "granular"),
},
+ "validations": {
+ xName: "x-kubernetes-validations",
+ kind: types.Slice,
+ },
}
// Extension encapsulates information necessary to generate an OpenAPI extension.
diff --git a/vendor/k8s.io/kube-openapi/pkg/generators/openapi.go b/vendor/k8s.io/kube-openapi/pkg/generators/openapi.go
index a294c2e8adfe..5d0349ccb904 100644
--- a/vendor/k8s.io/kube-openapi/pkg/generators/openapi.go
+++ b/vendor/k8s.io/kube-openapi/pkg/generators/openapi.go
@@ -225,6 +225,7 @@ type openAPITypeWriter struct {
*generator.SnippetWriter
context *generator.Context
refTypes map[string]*types.Type
+ enumContext *enumContext
GetDefinitionInterface *types.Type
}
@@ -233,6 +234,7 @@ func newOpenAPITypeWriter(sw *generator.SnippetWriter, c *generator.Context) ope
SnippetWriter: sw,
context: c,
refTypes: map[string]*types.Type{},
+ enumContext: newEnumContext(c),
}
}
@@ -548,7 +550,7 @@ func mustEnforceDefault(t *types.Type, omitEmpty bool) (interface{}, error) {
}
func (g openAPITypeWriter) generateDefault(comments []string, t *types.Type, omitEmpty bool) error {
- t = resolveAliasType(t)
+ t = resolveAliasAndEmbeddedType(t)
def, err := defaultFromComments(comments)
if err != nil {
return err
@@ -625,7 +627,11 @@ func (g openAPITypeWriter) generateProperty(m *types.Member, parent *types.Type)
return err
}
g.Do("SchemaProps: spec.SchemaProps{\n", nil)
- g.generateDescription(m.CommentLines)
+ var extraComments []string
+ if enumType, isEnum := g.enumContext.EnumType(m.Type); isEnum {
+ extraComments = enumType.DescriptionLines()
+ }
+ g.generateDescription(append(m.CommentLines, extraComments...))
jsonTags := getJsonTags(m)
if len(jsonTags) > 1 && jsonTags[1] == "string" {
g.generateSimpleProperty("string", "")
@@ -641,6 +647,10 @@ func (g openAPITypeWriter) generateProperty(m *types.Member, parent *types.Type)
typeString, format := openapi.OpenAPITypeFormat(t.String())
if typeString != "" {
g.generateSimpleProperty(typeString, format)
+ if enumType, isEnum := g.enumContext.EnumType(m.Type); isEnum {
+ // original type is an enum, add "Enum: " and the values
+ g.Do("Enum: []interface{}{$.$}", strings.Join(enumType.ValueStrings(), ", "))
+ }
g.Do("},\n},\n", nil)
return nil
}
@@ -674,13 +684,18 @@ func (g openAPITypeWriter) generateReferenceProperty(t *types.Type) {
g.Do("Ref: ref(\"$.$\"),\n", t.Name.String())
}
-func resolveAliasType(t *types.Type) *types.Type {
+func resolveAliasAndEmbeddedType(t *types.Type) *types.Type {
var prev *types.Type
for prev != t {
prev = t
if t.Kind == types.Alias {
t = t.Underlying
}
+ if t.Kind == types.Struct {
+ if len(t.Members) == 1 && t.Members[0].Embedded {
+ t = t.Members[0].Type
+ }
+ }
}
return t
}
diff --git a/vendor/k8s.io/kube-openapi/pkg/validation/spec/info.go b/vendor/k8s.io/kube-openapi/pkg/validation/spec/info.go
index 504a3972afd4..51a2f5781f0e 100644
--- a/vendor/k8s.io/kube-openapi/pkg/validation/spec/info.go
+++ b/vendor/k8s.io/kube-openapi/pkg/validation/spec/info.go
@@ -68,6 +68,25 @@ func (e Extensions) GetStringSlice(key string) ([]string, bool) {
return nil, false
}
+// GetObject gets the object value from the extensions.
+// out must be a json serializable type; the json go struct
+// tags of out are used to populate it.
+func (e Extensions) GetObject(key string, out interface{}) error {
+ // This json serialization/deserialization could be replaced with
+ // an approach using reflection if the optimization becomes justified.
+ if v, ok := e[strings.ToLower(key)]; ok {
+ b, err := json.Marshal(v)
+ if err != nil {
+ return err
+ }
+ err = json.Unmarshal(b, out)
+ if err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
// VendorExtensible composition block.
type VendorExtensible struct {
Extensions Extensions
diff --git a/vendor/k8s.io/legacy-cloud-providers/azure/auth/azure_auth.go b/vendor/k8s.io/legacy-cloud-providers/azure/auth/azure_auth.go
deleted file mode 100644
index c8a7dfd78667..000000000000
--- a/vendor/k8s.io/legacy-cloud-providers/azure/auth/azure_auth.go
+++ /dev/null
@@ -1,290 +0,0 @@
-/*
-Copyright 2017 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package auth
-
-import (
- "crypto/rsa"
- "crypto/x509"
- "fmt"
- "io/ioutil"
- "strings"
-
- "github.com/Azure/go-autorest/autorest/adal"
- "github.com/Azure/go-autorest/autorest/azure"
- "golang.org/x/crypto/pkcs12"
-
- "k8s.io/klog/v2"
-)
-
-const (
- // ADFSIdentitySystem is the override value for tenantID on Azure Stack clouds.
- ADFSIdentitySystem = "adfs"
-)
-
-var (
- // ErrorNoAuth indicates that no credentials are provided.
- ErrorNoAuth = fmt.Errorf("no credentials provided for Azure cloud provider")
-)
-
-// AzureAuthConfig holds auth related part of cloud config
-type AzureAuthConfig struct {
- // The cloud environment identifier. Takes values from https://github.com/Azure/go-autorest/blob/ec5f4903f77ed9927ac95b19ab8e44ada64c1356/autorest/azure/environments.go#L13
- Cloud string `json:"cloud,omitempty" yaml:"cloud,omitempty"`
- // The AAD Tenant ID for the Subscription that the cluster is deployed in
- TenantID string `json:"tenantId,omitempty" yaml:"tenantId,omitempty"`
- // The ClientID for an AAD application with RBAC access to talk to Azure RM APIs
- AADClientID string `json:"aadClientId,omitempty" yaml:"aadClientId,omitempty"`
- // The ClientSecret for an AAD application with RBAC access to talk to Azure RM APIs
- AADClientSecret string `json:"aadClientSecret,omitempty" yaml:"aadClientSecret,omitempty" datapolicy:"token"`
- // The path of a client certificate for an AAD application with RBAC access to talk to Azure RM APIs
- AADClientCertPath string `json:"aadClientCertPath,omitempty" yaml:"aadClientCertPath,omitempty"`
- // The password of the client certificate for an AAD application with RBAC access to talk to Azure RM APIs
- AADClientCertPassword string `json:"aadClientCertPassword,omitempty" yaml:"aadClientCertPassword,omitempty" datapolicy:"password"`
- // Use managed service identity for the virtual machine to access Azure ARM APIs
- UseManagedIdentityExtension bool `json:"useManagedIdentityExtension,omitempty" yaml:"useManagedIdentityExtension,omitempty"`
- // UserAssignedIdentityID contains the Client ID of the user assigned MSI which is assigned to the underlying VMs. If empty the user assigned identity is not used.
- // More details of the user assigned identity can be found at: https://docs.microsoft.com/en-us/azure/active-directory/managed-service-identity/overview
- // For the user assigned identity specified here to be used, the UseManagedIdentityExtension has to be set to true.
- UserAssignedIdentityID string `json:"userAssignedIdentityID,omitempty" yaml:"userAssignedIdentityID,omitempty"`
- // The ID of the Azure Subscription that the cluster is deployed in
- SubscriptionID string `json:"subscriptionId,omitempty" yaml:"subscriptionId,omitempty"`
- // IdentitySystem indicates the identity provider. Relevant only to hybrid clouds (Azure Stack).
- // Allowed values are 'azure_ad' (default), 'adfs'.
- IdentitySystem string `json:"identitySystem,omitempty" yaml:"identitySystem,omitempty"`
- // ResourceManagerEndpoint is the cloud's resource manager endpoint. If set, cloud provider queries this endpoint
- // in order to generate an autorest.Environment instance instead of using one of the pre-defined Environments.
- ResourceManagerEndpoint string `json:"resourceManagerEndpoint,omitempty" yaml:"resourceManagerEndpoint,omitempty"`
- // The AAD Tenant ID for the Subscription that the network resources are deployed in
- NetworkResourceTenantID string `json:"networkResourceTenantID,omitempty" yaml:"networkResourceTenantID,omitempty"`
- // The ID of the Azure Subscription that the network resources are deployed in
- NetworkResourceSubscriptionID string `json:"networkResourceSubscriptionID,omitempty" yaml:"networkResourceSubscriptionID,omitempty"`
-}
-
-// GetServicePrincipalToken creates a new service principal token based on the configuration.
-//
-// By default, the cluster and its network resources are deployed in the same AAD Tenant and Subscription,
-// and all azure clients use this method to fetch Service Principal Token.
-//
-// If NetworkResourceTenantID and NetworkResourceSubscriptionID are specified to have different values than TenantID and SubscriptionID, network resources are deployed in different AAD Tenant and Subscription than those for the cluster,
-// than only azure clients except VM/VMSS and network resource ones use this method to fetch Token.
-// For tokens for VM/VMSS and network resource ones, please check GetMultiTenantServicePrincipalToken and GetNetworkResourceServicePrincipalToken.
-func GetServicePrincipalToken(config *AzureAuthConfig, env *azure.Environment) (*adal.ServicePrincipalToken, error) {
- var tenantID string
- if strings.EqualFold(config.IdentitySystem, ADFSIdentitySystem) {
- tenantID = ADFSIdentitySystem
- } else {
- tenantID = config.TenantID
- }
-
- if config.UseManagedIdentityExtension {
- klog.V(2).Infoln("azure: using managed identity extension to retrieve access token")
- msiEndpoint, err := adal.GetMSIVMEndpoint()
- if err != nil {
- return nil, fmt.Errorf("Getting the managed service identity endpoint: %v", err)
- }
- if len(config.UserAssignedIdentityID) > 0 {
- klog.V(4).Info("azure: using User Assigned MSI ID to retrieve access token")
- return adal.NewServicePrincipalTokenFromMSIWithUserAssignedID(msiEndpoint,
- env.ServiceManagementEndpoint,
- config.UserAssignedIdentityID)
- }
- klog.V(4).Info("azure: using System Assigned MSI to retrieve access token")
- return adal.NewServicePrincipalTokenFromMSI(
- msiEndpoint,
- env.ServiceManagementEndpoint)
- }
-
- oauthConfig, err := adal.NewOAuthConfigWithAPIVersion(env.ActiveDirectoryEndpoint, tenantID, nil)
- if err != nil {
- return nil, fmt.Errorf("creating the OAuth config: %v", err)
- }
-
- if len(config.AADClientSecret) > 0 {
- klog.V(2).Infoln("azure: using client_id+client_secret to retrieve access token")
- return adal.NewServicePrincipalToken(
- *oauthConfig,
- config.AADClientID,
- config.AADClientSecret,
- env.ServiceManagementEndpoint)
- }
-
- if len(config.AADClientCertPath) > 0 && len(config.AADClientCertPassword) > 0 {
- klog.V(2).Infoln("azure: using jwt client_assertion (client_cert+client_private_key) to retrieve access token")
- certData, err := ioutil.ReadFile(config.AADClientCertPath)
- if err != nil {
- return nil, fmt.Errorf("reading the client certificate from file %s: %v", config.AADClientCertPath, err)
- }
- certificate, privateKey, err := decodePkcs12(certData, config.AADClientCertPassword)
- if err != nil {
- return nil, fmt.Errorf("decoding the client certificate: %v", err)
- }
- return adal.NewServicePrincipalTokenFromCertificate(
- *oauthConfig,
- config.AADClientID,
- certificate,
- privateKey,
- env.ServiceManagementEndpoint)
- }
-
- return nil, ErrorNoAuth
-}
-
-// GetMultiTenantServicePrincipalToken is used when (and only when) NetworkResourceTenantID and NetworkResourceSubscriptionID are specified to have different values than TenantID and SubscriptionID.
-//
-// In that scenario, network resources are deployed in different AAD Tenant and Subscription than those for the cluster,
-// and this method creates a new multi-tenant service principal token based on the configuration.
-//
-// PrimaryToken of the returned multi-tenant token is for the AAD Tenant specified by TenantID, and AuxiliaryToken of the returned multi-tenant token is for the AAD Tenant specified by NetworkResourceTenantID.
-//
-// Azure VM/VMSS clients use this multi-tenant token, in order to operate those VM/VMSS in AAD Tenant specified by TenantID, and meanwhile in their payload they are referencing network resources (e.g. Load Balancer, Network Security Group, etc.) in AAD Tenant specified by NetworkResourceTenantID.
-func GetMultiTenantServicePrincipalToken(config *AzureAuthConfig, env *azure.Environment) (*adal.MultiTenantServicePrincipalToken, error) {
- err := config.checkConfigWhenNetworkResourceInDifferentTenant()
- if err != nil {
- return nil, fmt.Errorf("got error(%v) in getting multi-tenant service principal token", err)
- }
-
- multiTenantOAuthConfig, err := adal.NewMultiTenantOAuthConfig(
- env.ActiveDirectoryEndpoint, config.TenantID, []string{config.NetworkResourceTenantID}, adal.OAuthOptions{})
- if err != nil {
- return nil, fmt.Errorf("creating the multi-tenant OAuth config: %v", err)
- }
-
- if len(config.AADClientSecret) > 0 {
- klog.V(2).Infoln("azure: using client_id+client_secret to retrieve multi-tenant access token")
- return adal.NewMultiTenantServicePrincipalToken(
- multiTenantOAuthConfig,
- config.AADClientID,
- config.AADClientSecret,
- env.ServiceManagementEndpoint)
- }
-
- if len(config.AADClientCertPath) > 0 && len(config.AADClientCertPassword) > 0 {
- return nil, fmt.Errorf("AAD Application client certificate authentication is not supported in getting multi-tenant service principal token")
- }
-
- return nil, ErrorNoAuth
-}
-
-// GetNetworkResourceServicePrincipalToken is used when (and only when) NetworkResourceTenantID and NetworkResourceSubscriptionID are specified to have different values than TenantID and SubscriptionID.
-//
-// In that scenario, network resources are deployed in different AAD Tenant and Subscription than those for the cluster,
-// and this method creates a new service principal token for network resources tenant based on the configuration.
-//
-// Azure network resource (Load Balancer, Public IP, Route Table, Network Security Group and their sub level resources) clients use this multi-tenant token, in order to operate resources in AAD Tenant specified by NetworkResourceTenantID.
-func GetNetworkResourceServicePrincipalToken(config *AzureAuthConfig, env *azure.Environment) (*adal.ServicePrincipalToken, error) {
- err := config.checkConfigWhenNetworkResourceInDifferentTenant()
- if err != nil {
- return nil, fmt.Errorf("got error(%v) in getting network resources service principal token", err)
- }
-
- oauthConfig, err := adal.NewOAuthConfigWithAPIVersion(env.ActiveDirectoryEndpoint, config.NetworkResourceTenantID, nil)
- if err != nil {
- return nil, fmt.Errorf("creating the OAuth config for network resources tenant: %v", err)
- }
-
- if len(config.AADClientSecret) > 0 {
- klog.V(2).Infoln("azure: using client_id+client_secret to retrieve access token for network resources tenant")
- return adal.NewServicePrincipalToken(
- *oauthConfig,
- config.AADClientID,
- config.AADClientSecret,
- env.ServiceManagementEndpoint)
- }
-
- if len(config.AADClientCertPath) > 0 && len(config.AADClientCertPassword) > 0 {
- return nil, fmt.Errorf("AAD Application client certificate authentication is not supported in getting network resources service principal token")
- }
-
- return nil, ErrorNoAuth
-}
-
-// ParseAzureEnvironment returns the azure environment.
-// If 'resourceManagerEndpoint' is set, the environment is computed by querying the cloud's resource manager endpoint.
-// Otherwise, a pre-defined Environment is looked up by name.
-func ParseAzureEnvironment(cloudName, resourceManagerEndpoint, identitySystem string) (*azure.Environment, error) {
- var env azure.Environment
- var err error
- if resourceManagerEndpoint != "" {
- klog.V(4).Infof("Loading environment from resource manager endpoint: %s", resourceManagerEndpoint)
- nameOverride := azure.OverrideProperty{Key: azure.EnvironmentName, Value: cloudName}
- env, err = azure.EnvironmentFromURL(resourceManagerEndpoint, nameOverride)
- if err == nil {
- azureStackOverrides(&env, resourceManagerEndpoint, identitySystem)
- }
- } else if cloudName == "" {
- klog.V(4).Info("Using public cloud environment")
- env = azure.PublicCloud
- } else {
- klog.V(4).Infof("Using %s environment", cloudName)
- env, err = azure.EnvironmentFromName(cloudName)
- }
- return &env, err
-}
-
-// UsesNetworkResourceInDifferentTenant determines whether the AzureAuthConfig indicates to use network resources in different AAD Tenant and Subscription than those for the cluster
-// Return true only when both NetworkResourceTenantID and NetworkResourceSubscriptionID are specified
-// and they are not equals to TenantID and SubscriptionID
-func (config *AzureAuthConfig) UsesNetworkResourceInDifferentTenant() bool {
- return len(config.NetworkResourceTenantID) > 0 &&
- len(config.NetworkResourceSubscriptionID) > 0 &&
- !strings.EqualFold(config.NetworkResourceTenantID, config.TenantID) &&
- !strings.EqualFold(config.NetworkResourceSubscriptionID, config.SubscriptionID)
-}
-
-// decodePkcs12 decodes a PKCS#12 client certificate by extracting the public certificate and
-// the private RSA key
-func decodePkcs12(pkcs []byte, password string) (*x509.Certificate, *rsa.PrivateKey, error) {
- privateKey, certificate, err := pkcs12.Decode(pkcs, password)
- if err != nil {
- return nil, nil, fmt.Errorf("decoding the PKCS#12 client certificate: %v", err)
- }
- rsaPrivateKey, isRsaKey := privateKey.(*rsa.PrivateKey)
- if !isRsaKey {
- return nil, nil, fmt.Errorf("PKCS#12 certificate must contain a RSA private key")
- }
-
- return certificate, rsaPrivateKey, nil
-}
-
-// azureStackOverrides ensures that the Environment matches what AKSe currently generates for Azure Stack
-func azureStackOverrides(env *azure.Environment, resourceManagerEndpoint, identitySystem string) {
- env.ManagementPortalURL = strings.Replace(resourceManagerEndpoint, "https://management.", "https://portal.", -1)
- env.ServiceManagementEndpoint = env.TokenAudience
- env.ResourceManagerVMDNSSuffix = strings.Replace(resourceManagerEndpoint, "https://management.", "cloudapp.", -1)
- env.ResourceManagerVMDNSSuffix = strings.TrimSuffix(env.ResourceManagerVMDNSSuffix, "/")
- if strings.EqualFold(identitySystem, ADFSIdentitySystem) {
- env.ActiveDirectoryEndpoint = strings.TrimSuffix(env.ActiveDirectoryEndpoint, "/")
- env.ActiveDirectoryEndpoint = strings.TrimSuffix(env.ActiveDirectoryEndpoint, "adfs")
- }
-}
-
-// checkConfigWhenNetworkResourceInDifferentTenant checks configuration for the scenario of using network resource in different tenant
-func (config *AzureAuthConfig) checkConfigWhenNetworkResourceInDifferentTenant() error {
- if !config.UsesNetworkResourceInDifferentTenant() {
- return fmt.Errorf("NetworkResourceTenantID and NetworkResourceSubscriptionID must be configured")
- }
-
- if strings.EqualFold(config.IdentitySystem, ADFSIdentitySystem) {
- return fmt.Errorf("ADFS identity system is not supported")
- }
-
- if config.UseManagedIdentityExtension {
- return fmt.Errorf("managed identity is not supported")
- }
-
- return nil
-}
diff --git a/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/credentialutil.go b/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/credentialutil.go
deleted file mode 100644
index 6f13eec0791e..000000000000
--- a/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/credentialutil.go
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
-Copyright 2021 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package gcpcredential
-
-import (
- "encoding/json"
- "errors"
- "fmt"
- "io"
- "io/ioutil"
- "net/http"
-
- "k8s.io/cloud-provider/credentialconfig"
- "k8s.io/klog/v2"
-)
-
-const (
- maxReadLength = 10 * 1 << 20 // 10MB
-)
-
-// HTTPError wraps a non-StatusOK error code as an error.
-type HTTPError struct {
- StatusCode int
- URL string
-}
-
-// Error implements error
-func (he *HTTPError) Error() string {
- return fmt.Sprintf("http status code: %d while fetching url %s",
- he.StatusCode, he.URL)
-}
-
-// ReadURL read contents from given url
-func ReadURL(url string, client *http.Client, header *http.Header) (body []byte, err error) {
- req, err := http.NewRequest("GET", url, nil)
- if err != nil {
- return nil, err
- }
- if header != nil {
- req.Header = *header
- }
- resp, err := client.Do(req)
- if err != nil {
- return nil, err
- }
- defer resp.Body.Close()
-
- if resp.StatusCode != http.StatusOK {
- klog.V(2).Infof("body of failing http response: %v", resp.Body)
- return nil, &HTTPError{
- StatusCode: resp.StatusCode,
- URL: url,
- }
- }
-
- limitedReader := &io.LimitedReader{R: resp.Body, N: maxReadLength}
- contents, err := ioutil.ReadAll(limitedReader)
- if err != nil {
- return nil, err
- }
-
- if limitedReader.N <= 0 {
- return nil, errors.New("the read limit is reached")
- }
-
- return contents, nil
-}
-
-// ReadDockerConfigFileFromURL read a docker config file from the given url
-func ReadDockerConfigFileFromURL(url string, client *http.Client, header *http.Header) (cfg credentialconfig.RegistryConfig, err error) {
- if contents, err := ReadURL(url, client, header); err == nil {
- return ReadDockerConfigFileFromBytes(contents)
- }
-
- return nil, err
-}
-
-type internalRegistryConfig map[string]RegistryConfigEntry
-
-// ReadDockerConfigFileFromBytes read a docker config file from the given bytes
-func ReadDockerConfigFileFromBytes(contents []byte) (cfg credentialconfig.RegistryConfig, err error) {
- serializableCfg := internalRegistryConfig{}
- if err = json.Unmarshal(contents, &serializableCfg); err != nil {
- return nil, errors.New("error occurred while trying to unmarshal json")
- }
- return convertToExternalConfig(serializableCfg), nil
-}
-
-func convertToExternalConfig(in internalRegistryConfig) (cfg credentialconfig.RegistryConfig) {
- configMap := credentialconfig.RegistryConfig{}
- for k, v := range in {
- configMap[k] = credentialconfig.RegistryConfigEntry{
- Username: v.Username,
- Password: v.Password,
- Email: v.Email,
- }
- }
- return configMap
-}
diff --git a/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/gcpcredential.go b/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/gcpcredential.go
deleted file mode 100644
index b51990d15433..000000000000
--- a/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/gcpcredential.go
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
-Copyright 2020 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package gcpcredential
-
-import (
- "encoding/json"
- "net/http"
- "strings"
-
- "k8s.io/cloud-provider/credentialconfig"
- "k8s.io/klog/v2"
-)
-
-const (
- metadataURL = "http://metadata.google.internal./computeMetadata/v1/"
- metadataAttributes = metadataURL + "instance/attributes/"
- // DockerConfigKey is the URL of the dockercfg metadata key used by DockerConfigKeyProvider.
- DockerConfigKey = metadataAttributes + "google-dockercfg"
- // DockerConfigURLKey is the URL of the dockercfg metadata key used by DockerConfigURLKeyProvider.
- DockerConfigURLKey = metadataAttributes + "google-dockercfg-url"
- serviceAccounts = metadataURL + "instance/service-accounts/"
- metadataScopes = metadataURL + "instance/service-accounts/default/scopes"
- metadataToken = metadataURL + "instance/service-accounts/default/token"
- metadataEmail = metadataURL + "instance/service-accounts/default/email"
- // StorageScopePrefix is the prefix checked by ContainerRegistryProvider.Enabled.
- StorageScopePrefix = "https://www.googleapis.com/auth/devstorage"
- cloudPlatformScopePrefix = "https://www.googleapis.com/auth/cloud-platform"
- defaultServiceAccount = "default/"
-)
-
-// GCEProductNameFile is the product file path that contains the cloud service name.
-// This is a variable instead of a const to enable testing.
-var GCEProductNameFile = "/sys/class/dmi/id/product_name"
-
-// For these urls, the parts of the host name can be glob, for example '*.gcr.io" will match
-// "foo.gcr.io" and "bar.gcr.io".
-var containerRegistryUrls = []string{"container.cloud.google.com", "gcr.io", "*.gcr.io", "*.pkg.dev"}
-
-var metadataHeader = &http.Header{
- "Metadata-Flavor": []string{"Google"},
-}
-
-// ProvideConfigKey implements a dockercfg-based authentication flow.
-func ProvideConfigKey(client *http.Client, image string) credentialconfig.RegistryConfig {
- // Read the contents of the google-dockercfg metadata key and
- // parse them as an alternate .dockercfg
- if cfg, err := ReadDockerConfigFileFromURL(DockerConfigKey, client, metadataHeader); err != nil {
- klog.Errorf("while reading 'google-dockercfg' metadata: %v", err)
- } else {
- return cfg
- }
-
- return credentialconfig.RegistryConfig{}
-}
-
-// ProvideURLKey implements a dockercfg-url-based authentication flow.
-func ProvideURLKey(client *http.Client, image string) credentialconfig.RegistryConfig {
- // Read the contents of the google-dockercfg-url key and load a .dockercfg from there
- if url, err := ReadURL(DockerConfigURLKey, client, metadataHeader); err != nil {
- klog.Errorf("while reading 'google-dockercfg-url' metadata: %v", err)
- } else {
- if strings.HasPrefix(string(url), "http") {
- if cfg, err := ReadDockerConfigFileFromURL(string(url), client, nil); err != nil {
- klog.Errorf("while reading 'google-dockercfg-url'-specified url: %s, %v", string(url), err)
- } else {
- return cfg
- }
- } else {
- // TODO(mattmoor): support reading alternate scheme URLs (e.g. gs:// or s3://)
- klog.Errorf("Unsupported URL scheme: %s", string(url))
- }
- }
-
- return credentialconfig.RegistryConfig{}
-}
-
-// TokenBlob is used to decode the JSON blob containing an access token
-// that is returned by GCE metadata.
-type TokenBlob struct {
- AccessToken string `json:"access_token"`
-}
-
-// ProvideContainerRegistry implements a gcr.io-based authentication flow.
-func ProvideContainerRegistry(client *http.Client, image string) credentialconfig.RegistryConfig {
- cfg := credentialconfig.RegistryConfig{}
-
- tokenJSONBlob, err := ReadURL(metadataToken, client, metadataHeader)
- if err != nil {
- klog.Errorf("while reading access token endpoint: %v", err)
- return cfg
- }
-
- email, err := ReadURL(metadataEmail, client, metadataHeader)
- if err != nil {
- klog.Errorf("while reading email endpoint: %v", err)
- return cfg
- }
-
- var parsedBlob TokenBlob
- if err := json.Unmarshal([]byte(tokenJSONBlob), &parsedBlob); err != nil {
- klog.Errorf("while parsing json blob %s: %v", tokenJSONBlob, err)
- return cfg
- }
-
- entry := credentialconfig.RegistryConfigEntry{
- Username: "_token",
- Password: parsedBlob.AccessToken,
- Email: string(email),
- }
-
- // Add our entry for each of the supported container registry URLs
- for _, k := range containerRegistryUrls {
- cfg[k] = entry
- }
- return cfg
-}
diff --git a/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/registry_marshal.go b/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/registry_marshal.go
deleted file mode 100644
index 75541e21166f..000000000000
--- a/vendor/k8s.io/legacy-cloud-providers/gce/gcpcredential/registry_marshal.go
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
-Copyright 2021 The Kubernetes Authors.
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-*/
-
-package gcpcredential
-
-import (
- "encoding/base64"
- "encoding/json"
- "fmt"
- "strings"
-
- "k8s.io/cloud-provider/credentialconfig"
-)
-
-// registryConfigEntryWithAuth is used solely for deserializing the Auth field
-// into a dockerConfigEntry during JSON deserialization.
-type registryConfigEntryWithAuth struct {
- // +optional
- Username string `json:"username,omitempty"`
- // +optional
- Password string `json:"password,omitempty"`
- // +optional
- Email string `json:"email,omitempty"`
- // +optional
- Auth string `json:"auth,omitempty"`
-}
-
-// RegistryConfigEntry is a serializable wrapper around credentialconfig.RegistryConfigEntry.
-type RegistryConfigEntry struct {
- credentialconfig.RegistryConfigEntry
-}
-
-// UnmarshalJSON implements the json.Unmarshaler interface.
-func (ident *RegistryConfigEntry) UnmarshalJSON(data []byte) error {
- var tmp registryConfigEntryWithAuth
- err := json.Unmarshal(data, &tmp)
- if err != nil {
- return err
- }
-
- ident.Username = tmp.Username
- ident.Password = tmp.Password
- ident.Email = tmp.Email
-
- if len(tmp.Auth) == 0 {
- return nil
- }
-
- ident.Username, ident.Password, err = decodeRegistryConfigFieldAuth(tmp.Auth)
- return err
-}
-
-// MarshalJSON implements the json.Marshaler interface.
-func (ident RegistryConfigEntry) MarshalJSON() ([]byte, error) {
- toEncode := registryConfigEntryWithAuth{ident.Username, ident.Password, ident.Email, ""}
- toEncode.Auth = encodeRegistryConfigFieldAuth(ident.Username, ident.Password)
-
- return json.Marshal(toEncode)
-}
-
-// decodeRegistryConfigFieldAuth deserializes the "auth" field from dockercfg into a
-// username and a password. The format of the auth field is base64(:).
-func decodeRegistryConfigFieldAuth(field string) (username, password string, err error) {
-
- var decoded []byte
-
- // StdEncoding can only decode padded string
- // RawStdEncoding can only decode unpadded string
- if strings.HasSuffix(strings.TrimSpace(field), "=") {
- // decode padded data
- decoded, err = base64.StdEncoding.DecodeString(field)
- } else {
- // decode unpadded data
- decoded, err = base64.RawStdEncoding.DecodeString(field)
- }
-
- if err != nil {
- return
- }
-
- parts := strings.SplitN(string(decoded), ":", 2)
- if len(parts) != 2 {
- err = fmt.Errorf("unable to parse auth field, must be formatted as base64(username:password)")
- return
- }
-
- username = parts[0]
- password = parts[1]
-
- return
-}
-
-func encodeRegistryConfigFieldAuth(username, password string) string {
- fieldValue := username + ":" + password
-
- return base64.StdEncoding.EncodeToString([]byte(fieldValue))
-}
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 617044e86c0e..7e3c61aeb1d3 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -1,4 +1,4 @@
-# cloud.google.com/go v0.98.0
+# cloud.google.com/go v0.99.0
cloud.google.com/go/compute/metadata
# contrib.go.opencensus.io/exporter/ocagent v0.7.1-0.20200907061046-05415f1de66d
contrib.go.opencensus.io/exporter/ocagent
@@ -6,8 +6,8 @@ contrib.go.opencensus.io/exporter/ocagent
contrib.go.opencensus.io/exporter/prometheus
# contrib.go.opencensus.io/exporter/zipkin v0.1.2
contrib.go.opencensus.io/exporter/zipkin
-# github.com/Azure/azure-sdk-for-go v43.0.0+incompatible
-github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2019-05-01/containerregistry
+# github.com/Azure/azure-sdk-for-go v46.4.0+incompatible
+github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry
github.com/Azure/azure-sdk-for-go/version
# github.com/Azure/go-autorest v14.2.0+incompatible
github.com/Azure/go-autorest
@@ -16,12 +16,12 @@ github.com/Azure/go-autorest/autorest
github.com/Azure/go-autorest/autorest/azure
# github.com/Azure/go-autorest/autorest/adal v0.9.13
github.com/Azure/go-autorest/autorest/adal
+# github.com/Azure/go-autorest/autorest/azure/auth v0.5.2
+github.com/Azure/go-autorest/autorest/azure/auth
+# github.com/Azure/go-autorest/autorest/azure/cli v0.4.1
+github.com/Azure/go-autorest/autorest/azure/cli
# github.com/Azure/go-autorest/autorest/date v0.3.0
github.com/Azure/go-autorest/autorest/date
-# github.com/Azure/go-autorest/autorest/to v0.3.0
-github.com/Azure/go-autorest/autorest/to
-# github.com/Azure/go-autorest/autorest/validation v0.1.0
-github.com/Azure/go-autorest/autorest/validation
# github.com/Azure/go-autorest/logger v0.2.1
github.com/Azure/go-autorest/logger
# github.com/Azure/go-autorest/tracing v0.6.0
@@ -34,44 +34,83 @@ github.com/PuerkitoBio/urlesc
## explicit
github.com/ahmetb/gen-crd-api-reference-docs
github.com/ahmetb/gen-crd-api-reference-docs/template
-# github.com/aws/aws-sdk-go v1.35.24
-github.com/aws/aws-sdk-go/aws
-github.com/aws/aws-sdk-go/aws/awserr
-github.com/aws/aws-sdk-go/aws/awsutil
-github.com/aws/aws-sdk-go/aws/client
-github.com/aws/aws-sdk-go/aws/client/metadata
-github.com/aws/aws-sdk-go/aws/corehandlers
-github.com/aws/aws-sdk-go/aws/credentials
-github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds
-github.com/aws/aws-sdk-go/aws/credentials/endpointcreds
-github.com/aws/aws-sdk-go/aws/credentials/processcreds
-github.com/aws/aws-sdk-go/aws/credentials/stscreds
-github.com/aws/aws-sdk-go/aws/csm
-github.com/aws/aws-sdk-go/aws/defaults
-github.com/aws/aws-sdk-go/aws/ec2metadata
-github.com/aws/aws-sdk-go/aws/endpoints
-github.com/aws/aws-sdk-go/aws/request
-github.com/aws/aws-sdk-go/aws/session
-github.com/aws/aws-sdk-go/aws/signer/v4
-github.com/aws/aws-sdk-go/internal/context
-github.com/aws/aws-sdk-go/internal/ini
-github.com/aws/aws-sdk-go/internal/sdkio
-github.com/aws/aws-sdk-go/internal/sdkmath
-github.com/aws/aws-sdk-go/internal/sdkrand
-github.com/aws/aws-sdk-go/internal/sdkuri
-github.com/aws/aws-sdk-go/internal/shareddefaults
-github.com/aws/aws-sdk-go/internal/strings
-github.com/aws/aws-sdk-go/internal/sync/singleflight
-github.com/aws/aws-sdk-go/private/protocol
-github.com/aws/aws-sdk-go/private/protocol/json/jsonutil
-github.com/aws/aws-sdk-go/private/protocol/jsonrpc
-github.com/aws/aws-sdk-go/private/protocol/query
-github.com/aws/aws-sdk-go/private/protocol/query/queryutil
-github.com/aws/aws-sdk-go/private/protocol/rest
-github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil
-github.com/aws/aws-sdk-go/service/ecr
-github.com/aws/aws-sdk-go/service/sts
-github.com/aws/aws-sdk-go/service/sts/stsiface
+# github.com/aws/aws-sdk-go-v2 v1.12.0
+github.com/aws/aws-sdk-go-v2
+github.com/aws/aws-sdk-go-v2/aws
+github.com/aws/aws-sdk-go-v2/aws/middleware
+github.com/aws/aws-sdk-go-v2/aws/protocol/query
+github.com/aws/aws-sdk-go-v2/aws/protocol/restjson
+github.com/aws/aws-sdk-go-v2/aws/protocol/xml
+github.com/aws/aws-sdk-go-v2/aws/ratelimit
+github.com/aws/aws-sdk-go-v2/aws/retry
+github.com/aws/aws-sdk-go-v2/aws/signer/internal/v4
+github.com/aws/aws-sdk-go-v2/aws/signer/v4
+github.com/aws/aws-sdk-go-v2/aws/transport/http
+github.com/aws/aws-sdk-go-v2/internal/rand
+github.com/aws/aws-sdk-go-v2/internal/sdk
+github.com/aws/aws-sdk-go-v2/internal/sdkio
+github.com/aws/aws-sdk-go-v2/internal/strings
+github.com/aws/aws-sdk-go-v2/internal/sync/singleflight
+github.com/aws/aws-sdk-go-v2/internal/timeconv
+# github.com/aws/aws-sdk-go-v2/config v1.12.0
+github.com/aws/aws-sdk-go-v2/config
+# github.com/aws/aws-sdk-go-v2/credentials v1.7.0
+github.com/aws/aws-sdk-go-v2/credentials
+github.com/aws/aws-sdk-go-v2/credentials/ec2rolecreds
+github.com/aws/aws-sdk-go-v2/credentials/endpointcreds
+github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client
+github.com/aws/aws-sdk-go-v2/credentials/processcreds
+github.com/aws/aws-sdk-go-v2/credentials/ssocreds
+github.com/aws/aws-sdk-go-v2/credentials/stscreds
+# github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.9.0
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds/internal/config
+# github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.3
+github.com/aws/aws-sdk-go-v2/internal/configsources
+# github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.1.0
+github.com/aws/aws-sdk-go-v2/internal/endpoints/v2
+# github.com/aws/aws-sdk-go-v2/internal/ini v1.3.3
+github.com/aws/aws-sdk-go-v2/internal/ini
+# github.com/aws/aws-sdk-go-v2/service/ecr v1.13.0
+github.com/aws/aws-sdk-go-v2/service/ecr
+github.com/aws/aws-sdk-go-v2/service/ecr/internal/endpoints
+github.com/aws/aws-sdk-go-v2/service/ecr/types
+# github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.10.0
+github.com/aws/aws-sdk-go-v2/service/ecrpublic
+github.com/aws/aws-sdk-go-v2/service/ecrpublic/internal/endpoints
+github.com/aws/aws-sdk-go-v2/service/ecrpublic/types
+# github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.6.0
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url
+# github.com/aws/aws-sdk-go-v2/service/sso v1.8.0
+github.com/aws/aws-sdk-go-v2/service/sso
+github.com/aws/aws-sdk-go-v2/service/sso/internal/endpoints
+github.com/aws/aws-sdk-go-v2/service/sso/types
+# github.com/aws/aws-sdk-go-v2/service/sts v1.13.0
+github.com/aws/aws-sdk-go-v2/service/sts
+github.com/aws/aws-sdk-go-v2/service/sts/internal/endpoints
+github.com/aws/aws-sdk-go-v2/service/sts/types
+# github.com/aws/smithy-go v1.9.1
+github.com/aws/smithy-go
+github.com/aws/smithy-go/document
+github.com/aws/smithy-go/encoding
+github.com/aws/smithy-go/encoding/httpbinding
+github.com/aws/smithy-go/encoding/json
+github.com/aws/smithy-go/encoding/xml
+github.com/aws/smithy-go/io
+github.com/aws/smithy-go/logging
+github.com/aws/smithy-go/middleware
+github.com/aws/smithy-go/ptr
+github.com/aws/smithy-go/rand
+github.com/aws/smithy-go/time
+github.com/aws/smithy-go/transport/http
+github.com/aws/smithy-go/transport/http/internal/io
+github.com/aws/smithy-go/waiter
+# github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20211215200129-69c85dc22db6
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login/config
+github.com/awslabs/amazon-ecr-credential-helper/ecr-login/version
# github.com/beorn7/perks v1.0.1
github.com/beorn7/perks/quantile
# github.com/blang/semver/v4 v4.0.0
@@ -88,22 +127,28 @@ github.com/census-instrumentation/opencensus-proto/gen-go/agent/trace/v1
github.com/census-instrumentation/opencensus-proto/gen-go/metrics/v1
github.com/census-instrumentation/opencensus-proto/gen-go/resource/v1
github.com/census-instrumentation/opencensus-proto/gen-go/trace/v1
-# github.com/cespare/xxhash/v2 v2.1.1
+# github.com/cespare/xxhash/v2 v2.1.2
github.com/cespare/xxhash/v2
+# github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86
+github.com/chrismellard/docker-credential-acr-env/pkg/credhelper
+github.com/chrismellard/docker-credential-acr-env/pkg/registry
+github.com/chrismellard/docker-credential-acr-env/pkg/token
# github.com/containerd/stargz-snapshotter/estargz v0.10.1
github.com/containerd/stargz-snapshotter/estargz
github.com/containerd/stargz-snapshotter/estargz/errorutil
# github.com/davecgh/go-spew v1.1.1
## explicit
github.com/davecgh/go-spew/spew
-# github.com/docker/cli v20.10.11+incompatible
+# github.com/dimchansky/utfbom v1.1.0
+github.com/dimchansky/utfbom
+# github.com/docker/cli v20.10.12+incompatible
github.com/docker/cli/cli/config
github.com/docker/cli/cli/config/configfile
github.com/docker/cli/cli/config/credentials
github.com/docker/cli/cli/config/types
# github.com/docker/distribution v2.7.1+incompatible
github.com/docker/distribution/registry/client/auth/challenge
-# github.com/docker/docker v20.10.11+incompatible
+# github.com/docker/docker v20.10.12+incompatible
github.com/docker/docker/pkg/homedir
# github.com/docker/docker-credential-helpers v0.6.4
github.com/docker/docker-credential-helpers/client
@@ -111,7 +156,7 @@ github.com/docker/docker-credential-helpers/credentials
# github.com/emicklei/go-restful v2.9.5+incompatible
github.com/emicklei/go-restful
github.com/emicklei/go-restful/log
-# github.com/evanphx/json-patch v4.11.0+incompatible
+# github.com/evanphx/json-patch v4.12.0+incompatible
github.com/evanphx/json-patch
# github.com/evanphx/json-patch/v5 v5.6.0
github.com/evanphx/json-patch/v5
@@ -156,7 +201,7 @@ github.com/google/go-cmp/cmp/internal/diff
github.com/google/go-cmp/cmp/internal/flags
github.com/google/go-cmp/cmp/internal/function
github.com/google/go-cmp/cmp/internal/value
-# github.com/google/go-containerregistry v0.7.1-0.20211118220127-abdc633f8305
+# github.com/google/go-containerregistry v0.8.1-0.20220114205711-890d5b362eb8
## explicit
github.com/google/go-containerregistry/internal/and
github.com/google/go-containerregistry/internal/estargz
@@ -170,6 +215,7 @@ github.com/google/go-containerregistry/pkg/logs
github.com/google/go-containerregistry/pkg/name
github.com/google/go-containerregistry/pkg/v1
github.com/google/go-containerregistry/pkg/v1/empty
+github.com/google/go-containerregistry/pkg/v1/google
github.com/google/go-containerregistry/pkg/v1/match
github.com/google/go-containerregistry/pkg/v1/mutate
github.com/google/go-containerregistry/pkg/v1/partial
@@ -179,9 +225,11 @@ github.com/google/go-containerregistry/pkg/v1/remote/transport
github.com/google/go-containerregistry/pkg/v1/stream
github.com/google/go-containerregistry/pkg/v1/tarball
github.com/google/go-containerregistry/pkg/v1/types
-# github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20211118220127-abdc633f8305
+# github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220114205711-890d5b362eb8
## explicit
github.com/google/go-containerregistry/pkg/authn/k8schain
+# github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20220110151055-a61fd0a8e2bb
+github.com/google/go-containerregistry/pkg/authn/kubernetes
# github.com/google/gofuzz v1.2.0
## explicit
github.com/google/gofuzz
@@ -217,7 +265,7 @@ github.com/influxdata/tdigest
github.com/jmespath/go-jmespath
# github.com/josharian/intern v1.0.0
github.com/josharian/intern
-# github.com/json-iterator/go v1.1.11
+# github.com/json-iterator/go v1.1.12
github.com/json-iterator/go
# github.com/kelseyhightower/envconfig v1.4.0
## explicit
@@ -236,13 +284,11 @@ github.com/mailru/easyjson/jlexer
github.com/mailru/easyjson/jwriter
# github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369
github.com/matttproud/golang_protobuf_extensions/pbutil
-# github.com/miekg/dns v1.1.29
-## explicit
# github.com/mitchellh/go-homedir v1.1.0
github.com/mitchellh/go-homedir
# github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd
github.com/modern-go/concurrent
-# github.com/modern-go/reflect2 v1.0.1
+# github.com/modern-go/reflect2 v1.0.2
github.com/modern-go/reflect2
# github.com/opencontainers/go-digest v1.0.0
github.com/opencontainers/go-digest
@@ -297,12 +343,6 @@ github.com/tsenart/vegeta/v12/lib/lttb
github.com/tsenart/vegeta/v12/lib/plot
# github.com/vbatts/tar-split v0.11.2
github.com/vbatts/tar-split/archive/tar
-# github.com/vdemeester/k8s-pkg-credentialprovider v1.21.0-1
-github.com/vdemeester/k8s-pkg-credentialprovider
-github.com/vdemeester/k8s-pkg-credentialprovider/aws
-github.com/vdemeester/k8s-pkg-credentialprovider/azure
-github.com/vdemeester/k8s-pkg-credentialprovider/gcp
-github.com/vdemeester/k8s-pkg-credentialprovider/secrets
# go.opencensus.io v0.23.0
## explicit
go.opencensus.io
@@ -351,7 +391,7 @@ golang.org/x/crypto/pkcs12/internal/rc2
golang.org/x/mod/internal/lazyregexp
golang.org/x/mod/module
golang.org/x/mod/semver
-# golang.org/x/net v0.0.0-20211209124913-491a49abca63
+# golang.org/x/net v0.0.0-20211216030914-fe4d6282115f
## explicit
golang.org/x/net/context
golang.org/x/net/context/ctxhttp
@@ -375,13 +415,13 @@ golang.org/x/oauth2/jwt
## explicit
golang.org/x/sync/errgroup
golang.org/x/sync/semaphore
-# golang.org/x/sys v0.0.0-20211124211545-fe61309f8881
+# golang.org/x/sys v0.0.0-20220111092808-5a964db01320
golang.org/x/sys/execabs
golang.org/x/sys/internal/unsafeheader
golang.org/x/sys/plan9
golang.org/x/sys/unix
golang.org/x/sys/windows
-# golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d
+# golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b
golang.org/x/term
# golang.org/x/text v0.3.7
golang.org/x/text/secure/bidirule
@@ -415,7 +455,7 @@ golang.org/x/xerrors
golang.org/x/xerrors/internal
# gomodules.xyz/jsonpatch/v2 v2.2.0
gomodules.xyz/jsonpatch/v2
-# google.golang.org/api v0.61.0
+# google.golang.org/api v0.62.0
## explicit
google.golang.org/api/dns/v1
google.golang.org/api/googleapi
@@ -442,13 +482,13 @@ google.golang.org/appengine/internal/modules
google.golang.org/appengine/internal/remote_api
google.golang.org/appengine/internal/urlfetch
google.golang.org/appengine/urlfetch
-# google.golang.org/genproto v0.0.0-20211129164237-f09f9a12af12
+# google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa
google.golang.org/genproto/googleapis/api/httpbody
google.golang.org/genproto/googleapis/rpc/code
google.golang.org/genproto/googleapis/rpc/errdetails
google.golang.org/genproto/googleapis/rpc/status
google.golang.org/genproto/protobuf/field_mask
-# google.golang.org/grpc v1.42.0
+# google.golang.org/grpc v1.43.0
## explicit
google.golang.org/grpc
google.golang.org/grpc/attributes
@@ -461,6 +501,7 @@ google.golang.org/grpc/binarylog/grpc_binarylog_v1
google.golang.org/grpc/codes
google.golang.org/grpc/connectivity
google.golang.org/grpc/credentials
+google.golang.org/grpc/credentials/insecure
google.golang.org/grpc/encoding
google.golang.org/grpc/encoding/proto
google.golang.org/grpc/grpclog
@@ -486,7 +527,6 @@ google.golang.org/grpc/internal/status
google.golang.org/grpc/internal/syscall
google.golang.org/grpc/internal/transport
google.golang.org/grpc/internal/transport/networktype
-google.golang.org/grpc/internal/xds/env
google.golang.org/grpc/keepalive
google.golang.org/grpc/metadata
google.golang.org/grpc/peer
@@ -914,8 +954,6 @@ k8s.io/client-go/util/jsonpath
k8s.io/client-go/util/keyutil
k8s.io/client-go/util/retry
k8s.io/client-go/util/workqueue
-# k8s.io/cloud-provider v0.21.0
-k8s.io/cloud-provider/credentialconfig
# k8s.io/code-generator v0.22.5
## explicit
k8s.io/code-generator
@@ -951,8 +989,6 @@ k8s.io/code-generator/cmd/set-gen
k8s.io/code-generator/pkg/namer
k8s.io/code-generator/pkg/util
k8s.io/code-generator/third_party/forked/golang/reflect
-# k8s.io/component-base v0.22.5
-k8s.io/component-base/version
# k8s.io/gengo v0.0.0-20211129171323-c02415ce4185
k8s.io/gengo/args
k8s.io/gengo/examples/deepcopy-gen/generators
@@ -969,7 +1005,7 @@ k8s.io/gengo/types
k8s.io/klog
# k8s.io/klog/v2 v2.40.1
k8s.io/klog/v2
-# k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c
+# k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65
## explicit
k8s.io/kube-openapi/cmd/openapi-gen
k8s.io/kube-openapi/cmd/openapi-gen/args
@@ -979,10 +1015,7 @@ k8s.io/kube-openapi/pkg/generators/rules
k8s.io/kube-openapi/pkg/util/proto
k8s.io/kube-openapi/pkg/util/sets
k8s.io/kube-openapi/pkg/validation/spec
-# k8s.io/legacy-cloud-providers v0.21.0
-k8s.io/legacy-cloud-providers/azure/auth
-k8s.io/legacy-cloud-providers/gce/gcpcredential
-# k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a
+# k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b
k8s.io/utils/buffer
k8s.io/utils/integer
k8s.io/utils/pointer
From 969beb32ac40e6f6cda1c7edd8bff2e482e0c8a3 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 18 Jan 2022 09:44:33 -0800
Subject: [PATCH 091/733] Update net-istio nightly (#12519)
bumping knative.dev/net-istio 2ab0b98...957190f:
> 957190f Update community files (# 844)
Signed-off-by: Knative Automation
---
third_party/istio-latest/net-istio.yaml | 70 ++++++++++++-------------
1 file changed, 35 insertions(+), 35 deletions(-)
diff --git a/third_party/istio-latest/net-istio.yaml b/third_party/istio-latest/net-istio.yaml
index 6d0df389f4ff..d84e8c75751b 100644
--- a/third_party/istio-latest/net-istio.yaml
+++ b/third_party/istio-latest/net-istio.yaml
@@ -1,4 +1,4 @@
-# Generated when HEAD was 2ab0b98d40edbffd8ffef7fb03ee678c457f57ad
+# Generated when HEAD was 957190f981391911d2a660999c3d0af35f1f43ad
#
# Copyright 2019 The Knative Authors
#
@@ -22,8 +22,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
serving.knative.dev/controller: "true"
networking.knative.dev/ingress-provider: istio
rules:
@@ -55,8 +55,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -95,8 +95,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -117,8 +117,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -153,8 +153,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
data:
_example: |
@@ -220,8 +220,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -239,8 +239,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -258,8 +258,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -292,8 +292,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -311,15 +311,15 @@ spec:
app: net-istio-controller
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:126e41eac7774d4d19516b5f48cdfd0e57e8a8c56567d490e7de5e370b63fbd1
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:be615cbd54949ea98a62567e159de15c2e8c15036d5ebc8c1218373cc0bc1b75
resources:
requests:
cpu: 30m
@@ -378,8 +378,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -395,15 +395,15 @@ spec:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:d4109aaeefb3d1d007528fd6027981f22af6b711159b911038aa95383479d785
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:6b381296aad9e6da52291d3adac0563b32d0cf9e977f171c5e18b160ec7a6a07
resources:
requests:
cpu: 20m
@@ -458,8 +458,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
---
@@ -486,8 +486,8 @@ metadata:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
spec:
ports:
@@ -526,8 +526,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -566,8 +566,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220112-2ab0b98d"
- serving.knative.dev/release: "v20220112-2ab0b98d"
+ app.kubernetes.io/version: "20220118-957190f9"
+ serving.knative.dev/release: "v20220118-957190f9"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
From f0792835ff3a9804ce97232b76c51493c8842d25 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 18 Jan 2022 09:44:40 -0800
Subject: [PATCH 092/733] Update net-gateway-api nightly (#12521)
bumping knative.dev/net-gateway-api efb9e44...7683b1b:
> 7683b1b Add chaos duck for controller (# 234)
> ad30ff6 Update actions (# 233)
> ba9353f upgrade to latest dependencies (# 232)
> b077504 upgrade to latest dependencies (# 231)
> 79b15bd Update actions (# 230)
Signed-off-by: Knative Automation
---
third_party/gateway-api-latest/istio-gateway.yaml | 2 +-
third_party/gateway-api-latest/net-gateway-api.yaml | 12 ++++++------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/third_party/gateway-api-latest/istio-gateway.yaml b/third_party/gateway-api-latest/istio-gateway.yaml
index c7a55ea7bd59..05349db61220 100644
--- a/third_party/gateway-api-latest/istio-gateway.yaml
+++ b/third_party/gateway-api-latest/istio-gateway.yaml
@@ -20,7 +20,7 @@ metadata:
name: knative-local-gateway
namespace: istio-system
labels:
- serving.knative.dev/release: "v20220112-efb9e447"
+ serving.knative.dev/release: "v20220118-7683b1b9"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
diff --git a/third_party/gateway-api-latest/net-gateway-api.yaml b/third_party/gateway-api-latest/net-gateway-api.yaml
index 2c55f6b57262..b2b15e850fff 100644
--- a/third_party/gateway-api-latest/net-gateway-api.yaml
+++ b/third_party/gateway-api-latest/net-gateway-api.yaml
@@ -2125,7 +2125,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-admin
labels:
- serving.knative.dev/release: "v20220112-efb9e447"
+ serving.knative.dev/release: "v20220118-7683b1b9"
aggregationRule:
clusterRoleSelectors:
- matchLabels:
@@ -2137,7 +2137,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-core
labels:
- serving.knative.dev/release: "v20220112-efb9e447"
+ serving.knative.dev/release: "v20220118-7683b1b9"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["networking.x-k8s.io"]
@@ -2165,7 +2165,7 @@ metadata:
name: config-gateway
namespace: knative-serving
labels:
- serving.knative.dev/release: "v20220112-efb9e447"
+ serving.knative.dev/release: "v20220118-7683b1b9"
data:
_example: |
################################
@@ -2219,9 +2219,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: net-gateway-api
app.kubernetes.io/component: net-gateway-api
- app.kubernetes.io/version: "20220112-efb9e447"
+ app.kubernetes.io/version: "20220118-7683b1b9"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220112-efb9e447"
+ serving.knative.dev/release: "v20220118-7683b1b9"
spec:
replicas: 1
selector:
@@ -2247,7 +2247,7 @@ spec:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:6960594fdc6421722e54d7acf9e02f087ff6bbcd14d950313c0e39bcccdd0e1a
+ image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:d3fdece88259857afdf6e9ffda47477b77f499830f9eb4fa2026610ff0485008
resources:
requests:
cpu: 100m
From a3216ca8e4a4a7000b94e5035c1790e87d372775 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 18 Jan 2022 10:58:33 -0800
Subject: [PATCH 093/733] Update net-kourier nightly (#12520)
bumping knative.dev/net-kourier 37d3663...f3ceea7:
> f3ceea7 Fix leader election issues due to defaults change (# 753)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index 52e572bbd4f9..91c7812f2399 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
- serving.knative.dev/release: "v20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
+ serving.knative.dev/release: "v20220118-f3ceea74"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:8a15c99a0d1808b6a84a302d863dc1f1d5c85f19c6cd06ca6b3f9460a3c7190b
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:e87618da4c1e9f87af7e603ac5582065b8a62f978d9f623f741fa94a77d5c83f
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220117-37d36631"
+ app.kubernetes.io/version: "20220118-f3ceea74"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220117-37d36631"
+ serving.knative.dev/release: "v20220118-f3ceea74"
spec:
ports:
- name: http2
From 0682e949a90885ba8402b4e03c5e4adfd504743d Mon Sep 17 00:00:00 2001
From: Stavros Kontopoulos
Date: Wed, 19 Jan 2022 14:29:53 +0200
Subject: [PATCH 094/733] Add pvc support (#12458)
* add pvc support
* fix header
* fix fmt
* simplify implementation
* fixes
* fix msg
* improve test names
* nits
* more fixes
---
config/core/configmaps/features.yaml | 12 +-
pkg/apis/config/features.go | 6 +
pkg/apis/config/features_test.go | 36 ++++
pkg/apis/serving/fieldmask.go | 8 +
pkg/apis/serving/k8s_validation.go | 56 +++++-
pkg/apis/serving/k8s_validation_test.go | 183 +++++++++++++++++-
pkg/apis/serving/v1/revision_defaults.go | 2 +-
pkg/reconciler/revision/table_test.go | 24 +++
.../route/resources/service_test.go | 26 +--
pkg/testing/v1/revision.go | 16 ++
10 files changed, 345 insertions(+), 24 deletions(-)
diff --git a/config/core/configmaps/features.yaml b/config/core/configmaps/features.yaml
index d76a2806f699..7e7677556986 100644
--- a/config/core/configmaps/features.yaml
+++ b/config/core/configmaps/features.yaml
@@ -23,7 +23,7 @@ metadata:
app.kubernetes.io/version: devel
serving.knative.dev/release: devel
annotations:
- knative.dev/example-checksum: "2897f625"
+ knative.dev/example-checksum: "d9e300ba"
data:
_example: |-
################################
@@ -149,3 +149,13 @@ data:
# 1. Enabled: enabling init containers support
# 2. Disabled: disabling init containers support
kubernetes.podspec-init-containers: "disabled"
+
+ # Controls whether persistent volume claim support is enabled or not.
+ # 1. Enabled: enabling persistent volume claim support
+ # 2. Disabled: disabling persistent volume claim support
+ kubernetes.podspec-persistent-volume-claim: "disabled"
+
+ # Controls whether write access for persistent volumes is enabled or not.
+ # 1. Enabled: enabling write access for persistent volumes
+ # 2. Disabled: disabling write access for persistent volumes
+ kubernetes.podspec-persistent-volume-write: "disabled"
diff --git a/pkg/apis/config/features.go b/pkg/apis/config/features.go
index db4f212d6cd0..0998025e3898 100644
--- a/pkg/apis/config/features.go
+++ b/pkg/apis/config/features.go
@@ -54,6 +54,8 @@ func defaultFeaturesConfig() *Features {
ContainerSpecAddCapabilities: Disabled,
PodSpecTolerations: Disabled,
PodSpecVolumesEmptyDir: Disabled,
+ PodSpecPersistentVolumeClaim: Disabled,
+ PodSpecPersistentVolumeWrite: Disabled,
PodSpecInitContainers: Disabled,
TagHeaderBasedRouting: Disabled,
AutoDetectHTTP2: Disabled,
@@ -79,6 +81,8 @@ func NewFeaturesConfigFromMap(data map[string]string) (*Features, error) {
asFlag("kubernetes.podspec-tolerations", &nc.PodSpecTolerations),
asFlag("kubernetes.podspec-volumes-emptydir", &nc.PodSpecVolumesEmptyDir),
asFlag("kubernetes.podspec-init-containers", &nc.PodSpecInitContainers),
+ asFlag("kubernetes.podspec-persistent-volume-claim", &nc.PodSpecPersistentVolumeClaim),
+ asFlag("kubernetes.podspec-persistent-volume-write", &nc.PodSpecPersistentVolumeWrite),
asFlag("tag-header-based-routing", &nc.TagHeaderBasedRouting),
asFlag("autodetect-http2", &nc.AutoDetectHTTP2)); err != nil {
return nil, err
@@ -107,6 +111,8 @@ type Features struct {
PodSpecTolerations Flag
PodSpecVolumesEmptyDir Flag
PodSpecInitContainers Flag
+ PodSpecPersistentVolumeClaim Flag
+ PodSpecPersistentVolumeWrite Flag
TagHeaderBasedRouting Flag
AutoDetectHTTP2 Flag
}
diff --git a/pkg/apis/config/features_test.go b/pkg/apis/config/features_test.go
index e38419f5f78b..16dcee7d584c 100644
--- a/pkg/apis/config/features_test.go
+++ b/pkg/apis/config/features_test.go
@@ -354,6 +354,42 @@ func TestFeaturesConfiguration(t *testing.T) {
data: map[string]string{
"kubernetes.podspec-volumes-emptydir": "Enabled",
},
+ }, {
+ name: "kubernetes.podspec-persistent-volume-claim Disabled",
+ wantErr: false,
+ wantFeatures: defaultWith(&Features{
+ PodSpecPersistentVolumeClaim: Disabled,
+ }),
+ data: map[string]string{
+ "kubernetes.podspec-persistent-volume-claim": "Disabled",
+ },
+ }, {
+ name: "kubernetes.podspec-persistent-volume-claim Enabled",
+ wantErr: false,
+ wantFeatures: defaultWith(&Features{
+ PodSpecPersistentVolumeClaim: Enabled,
+ }),
+ data: map[string]string{
+ "kubernetes.podspec-persistent-volume-claim": "Enabled",
+ },
+ }, {
+ name: "kubernetes.podspec-persistent-volume-write Disabled",
+ wantErr: false,
+ wantFeatures: defaultWith(&Features{
+ PodSpecPersistentVolumeWrite: Disabled,
+ }),
+ data: map[string]string{
+ "kubernetes.podspec-persistent-volume-write": "Disabled",
+ },
+ }, {
+ name: "kubernetes.podspec-persistent-volume-claim Enabled",
+ wantErr: false,
+ wantFeatures: defaultWith(&Features{
+ PodSpecPersistentVolumeWrite: Enabled,
+ }),
+ data: map[string]string{
+ "kubernetes.podspec-persistent-volume-write": "Enabled",
+ },
}, {
name: "kubernetes.podspec-init-containers Disabled",
wantErr: false,
diff --git a/pkg/apis/serving/fieldmask.go b/pkg/apis/serving/fieldmask.go
index 4ea939b298a4..32723a1f8586 100644
--- a/pkg/apis/serving/fieldmask.go
+++ b/pkg/apis/serving/fieldmask.go
@@ -45,6 +45,10 @@ func VolumeMask(ctx context.Context, in *corev1.Volume) *corev1.Volume {
out.EmptyDir = in.EmptyDir
}
+ if cfg.Features.PodSpecPersistentVolumeClaim != config.Disabled {
+ out.PersistentVolumeClaim = in.PersistentVolumeClaim
+ }
+
return out
}
@@ -67,6 +71,10 @@ func VolumeSourceMask(ctx context.Context, in *corev1.VolumeSource) *corev1.Volu
out.EmptyDir = in.EmptyDir
}
+ if cfg.Features.PodSpecPersistentVolumeClaim != config.Disabled {
+ out.PersistentVolumeClaim = in.PersistentVolumeClaim
+ }
+
// Too many disallowed fields to list
return out
diff --git a/pkg/apis/serving/k8s_validation.go b/pkg/apis/serving/k8s_validation.go
index 2d03ecbdbd79..eeed43fc892e 100644
--- a/pkg/apis/serving/k8s_validation.go
+++ b/pkg/apis/serving/k8s_validation.go
@@ -85,12 +85,7 @@ var (
func ValidateVolumes(ctx context.Context, vs []corev1.Volume, mountedVolumes sets.String) (map[string]corev1.Volume, *apis.FieldError) {
volumes := make(map[string]corev1.Volume, len(vs))
var errs *apis.FieldError
- features := config.FromContextOrDefaults(ctx).Features
for i, volume := range vs {
- if volume.EmptyDir != nil && features.PodSpecVolumesEmptyDir != config.Enabled {
- errs = errs.Also((&apis.FieldError{Message: fmt.Sprintf("EmptyDir volume support is off, "+
- "but found EmptyDir volume %s", volume.Name)}).ViaIndex(i))
- }
if _, ok := volumes[volume.Name]; ok {
errs = errs.Also((&apis.FieldError{
Message: fmt.Sprintf("duplicate volume name %q", volume.Name),
@@ -109,14 +104,36 @@ func ValidateVolumes(ctx context.Context, vs []corev1.Volume, mountedVolumes set
return volumes, errs
}
+func validatePersistentVolumeClaims(volume corev1.VolumeSource, features *config.Features) *apis.FieldError {
+ var errs *apis.FieldError
+ if volume.PersistentVolumeClaim == nil {
+ return nil
+ }
+ if features.PodSpecPersistentVolumeClaim != config.Enabled {
+ errs = errs.Also(&apis.FieldError{Message: fmt.Sprintf("Persistent volume claim support is disabled, "+
+ "but found persistent volume claim %s", volume.PersistentVolumeClaim.ClaimName)})
+ }
+ isWriteEnabled := features.PodSpecPersistentVolumeWrite == config.Enabled
+ if !volume.PersistentVolumeClaim.ReadOnly && !isWriteEnabled {
+ errs = errs.Also(&apis.FieldError{Message: fmt.Sprintf("Persistent volume write support is disabled, "+
+ "but found persistent volume claim %s that is not read-only", volume.PersistentVolumeClaim.ClaimName)})
+ }
+ return errs
+}
+
func validateVolume(ctx context.Context, volume corev1.Volume) *apis.FieldError {
- errs := apis.CheckDisallowedFields(volume, *VolumeMask(ctx, &volume))
+ features := config.FromContextOrDefaults(ctx).Features
+ errs := validatePersistentVolumeClaims(volume.VolumeSource, features)
+ if volume.EmptyDir != nil && features.PodSpecVolumesEmptyDir != config.Enabled {
+ errs = errs.Also(&apis.FieldError{Message: fmt.Sprintf("EmptyDir volume support is disabled, "+
+ "but found EmptyDir volume %s", volume.Name)})
+ }
+ errs = errs.Also(apis.CheckDisallowedFields(volume, *VolumeMask(ctx, &volume)))
if volume.Name == "" {
errs = apis.ErrMissingField("name")
} else if len(validation.IsDNS1123Label(volume.Name)) != 0 {
errs = apis.ErrInvalidValue(volume.Name, "name")
}
-
vs := volume.VolumeSource
errs = errs.Also(apis.CheckDisallowedFields(vs, *VolumeSourceMask(ctx, &vs)))
var specified []string
@@ -142,12 +159,20 @@ func validateVolume(ctx context.Context, volume corev1.Volume) *apis.FieldError
specified = append(specified, "emptyDir")
errs = errs.Also(validateEmptyDirFields(vs.EmptyDir).ViaField("emptyDir"))
}
+
+ if vs.PersistentVolumeClaim != nil {
+ specified = append(specified, "persistentVolumeClaim")
+ }
+
if len(specified) == 0 {
fieldPaths := []string{"secret", "configMap", "projected"}
cfg := config.FromContextOrDefaults(ctx)
if cfg.Features.PodSpecVolumesEmptyDir == config.Enabled {
fieldPaths = append(fieldPaths, "emptyDir")
}
+ if cfg.Features.PodSpecPersistentVolumeClaim == config.Enabled {
+ fieldPaths = append(fieldPaths, "persistentVolumeClaim")
+ }
errs = errs.Also(apis.ErrMissingOneOf(fieldPaths...))
} else if len(specified) > 1 {
errs = errs.Also(apis.ErrMultipleOneOf(specified...))
@@ -616,8 +641,21 @@ func validateVolumeMounts(mounts []corev1.VolumeMount, volumes map[string]corev1
}
seenMountPath.Insert(filepath.Clean(vm.MountPath))
- if volumes[vm.Name].EmptyDir == nil && !vm.ReadOnly {
- errs = errs.Also(apis.ErrMissingField("readOnly").ViaIndex(i))
+ shouldCheckReadOnlyVolume := volumes[vm.Name].EmptyDir == nil && volumes[vm.Name].PersistentVolumeClaim == nil
+ if shouldCheckReadOnlyVolume && !vm.ReadOnly {
+ errs = errs.Also((&apis.FieldError{
+ Message: "volume mount should be readOnly for this type of volume",
+ Paths: []string{"readOnly"},
+ }).ViaIndex(i))
+ }
+
+ if volumes[vm.Name].PersistentVolumeClaim != nil {
+ if volumes[vm.Name].PersistentVolumeClaim.ReadOnly && !vm.ReadOnly {
+ errs = errs.Also((&apis.FieldError{
+ Message: "volume is readOnly but volume mount is not",
+ Paths: []string{"readOnly"},
+ }).ViaIndex(i))
+ }
}
}
return errs
diff --git a/pkg/apis/serving/k8s_validation_test.go b/pkg/apis/serving/k8s_validation_test.go
index 6f9b21d185b0..e475ea500aca 100644
--- a/pkg/apis/serving/k8s_validation_test.go
+++ b/pkg/apis/serving/k8s_validation_test.go
@@ -114,6 +114,20 @@ func withPodSpecVolumesEmptyDirEnabled() configOption {
}
}
+func withPodSpecPersistentVolumeClaimEnabled() configOption {
+ return func(cfg *config.Config) *config.Config {
+ cfg.Features.PodSpecPersistentVolumeClaim = config.Enabled
+ return cfg
+ }
+}
+
+func withPodSpecPersistentVolumeWriteEnabled() configOption {
+ return func(cfg *config.Config) *config.Config {
+ cfg.Features.PodSpecPersistentVolumeWrite = config.Enabled
+ return cfg
+ }
+}
+
func withPodSpecPriorityClassNameEnabled() configOption {
return func(cfg *config.Config) *config.Config {
cfg.Features.PodSpecPriorityClassName = config.Enabled
@@ -453,6 +467,142 @@ func TestPodSpecValidation(t *testing.T) {
Message: `duplicate container name "the-name"`,
Paths: []string{"name"},
}).ViaFieldIndex("containers", 1),
+ }, {
+ name: "PVC not read-only, mount read-only, write disabled by default",
+ ps: corev1.PodSpec{
+ Containers: []corev1.Container{{
+ Image: "busybox",
+ VolumeMounts: []corev1.VolumeMount{{
+ Name: "foo",
+ MountPath: "/data",
+ ReadOnly: true,
+ }},
+ }},
+ Volumes: []corev1.Volume{{
+ Name: "foo",
+ VolumeSource: corev1.VolumeSource{
+ PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: false,
+ },
+ }},
+ }},
+ cfgOpts: []configOption{withPodSpecPersistentVolumeClaimEnabled()},
+ want: &apis.FieldError{
+ Message: `Persistent volume write support is disabled, but found persistent volume claim myclaim that is not read-only`,
+ },
+ }, {
+ name: "PVC not read-only, mount not read-only, write disabled by default",
+ ps: corev1.PodSpec{
+ Containers: []corev1.Container{{
+ Image: "busybox",
+ VolumeMounts: []corev1.VolumeMount{{
+ Name: "foo",
+ MountPath: "/data",
+ ReadOnly: false,
+ }},
+ }},
+ Volumes: []corev1.Volume{{
+ Name: "foo",
+ VolumeSource: corev1.VolumeSource{
+ PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: false,
+ },
+ }},
+ }},
+ cfgOpts: []configOption{withPodSpecPersistentVolumeClaimEnabled()},
+ want: &apis.FieldError{
+ Message: `Persistent volume write support is disabled, but found persistent volume claim myclaim that is not read-only`,
+ },
+ }, {
+ name: "PVC read-only, mount not read-only, write disabled by default",
+ ps: corev1.PodSpec{
+ Containers: []corev1.Container{{
+ Image: "busybox",
+ VolumeMounts: []corev1.VolumeMount{{
+ Name: "foo",
+ MountPath: "/data",
+ ReadOnly: false,
+ }},
+ }},
+ Volumes: []corev1.Volume{{
+ Name: "foo",
+ VolumeSource: corev1.VolumeSource{
+ PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: true,
+ },
+ }},
+ }},
+ cfgOpts: []configOption{withPodSpecPersistentVolumeClaimEnabled()},
+ want: &apis.FieldError{
+ Message: "volume is readOnly but volume mount is not",
+ Paths: []string{"containers[0].volumeMounts[0].readOnly"},
+ },
+ }, {
+ name: "PVC read-only, write disabled by default",
+ ps: corev1.PodSpec{
+ Containers: []corev1.Container{{
+ Image: "busybox",
+ VolumeMounts: []corev1.VolumeMount{{
+ Name: "foo",
+ MountPath: "/data",
+ ReadOnly: true,
+ }},
+ }},
+ Volumes: []corev1.Volume{{
+ Name: "foo",
+ VolumeSource: corev1.VolumeSource{
+ PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: true,
+ },
+ }},
+ }},
+ cfgOpts: []configOption{withPodSpecPersistentVolumeClaimEnabled()},
+ }, {
+ name: "PVC not read-only, write enabled",
+ ps: corev1.PodSpec{
+ Containers: []corev1.Container{{
+ Image: "busybox",
+ VolumeMounts: []corev1.VolumeMount{{
+ Name: "foo",
+ MountPath: "/data",
+ ReadOnly: true,
+ }},
+ }},
+ Volumes: []corev1.Volume{{
+ Name: "foo",
+ VolumeSource: corev1.VolumeSource{
+ PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: false,
+ },
+ }},
+ }},
+ cfgOpts: []configOption{withPodSpecPersistentVolumeClaimEnabled(), withPodSpecPersistentVolumeWriteEnabled()},
+ }, {
+ name: "PVC read-only, write enabled",
+ ps: corev1.PodSpec{
+ Containers: []corev1.Container{{
+ Image: "busybox",
+ VolumeMounts: []corev1.VolumeMount{{
+ Name: "foo",
+ MountPath: "/data",
+ ReadOnly: false,
+ }},
+ }},
+ Volumes: []corev1.Volume{{
+ Name: "foo",
+ VolumeSource: corev1.VolumeSource{
+ PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: false,
+ },
+ }},
+ }},
+ cfgOpts: []configOption{withPodSpecPersistentVolumeClaimEnabled(), withPodSpecPersistentVolumeWriteEnabled()},
}}
for _, test := range tests {
@@ -1761,7 +1911,10 @@ func getCommonContainerValidationTestCases() []containerValidationTestCase {
Message: "volumeMount has no matching volume",
Paths: []string{"name"},
}).ViaFieldIndex("volumeMounts", 0).Also(
- apis.ErrMissingField("readOnly").ViaFieldIndex("volumeMounts", 0)).Also(
+ (&apis.FieldError{
+ Message: "volume mount should be readOnly for this type of volume",
+ Paths: []string{"readOnly"},
+ }).ViaFieldIndex("volumeMounts", 0)).Also(
apis.ErrMissingField("mountPath").ViaFieldIndex("volumeMounts", 0)).Also(
apis.ErrDisallowedFields("mountPropagation").ViaFieldIndex("volumeMounts", 0)),
}, {
@@ -2091,6 +2244,34 @@ func TestVolumeValidation(t *testing.T) {
},
want: apis.ErrInvalidValue(-1, "emptyDir.sizeLimit"),
cfgOpts: []configOption{withPodSpecVolumesEmptyDirEnabled()},
+ }, {
+ name: "valid PVC with PVC feature enabled",
+ v: corev1.Volume{
+ Name: "foo",
+ VolumeSource: corev1.VolumeSource{
+ PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: true,
+ },
+ },
+ },
+ cfgOpts: []configOption{withPodSpecPersistentVolumeClaimEnabled()},
+ }, {
+ name: "valid PVC with PVC feature disabled",
+ v: corev1.Volume{
+ Name: "foo",
+ VolumeSource: corev1.VolumeSource{
+ PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: false,
+ },
+ }},
+ want: (&apis.FieldError{
+ Message: `Persistent volume claim support is disabled, but found persistent volume claim myclaim`,
+ }).Also(&apis.FieldError{
+ Message: `Persistent volume write support is disabled, but found persistent volume claim myclaim that is not read-only`,
+ }).Also(
+ &apis.FieldError{Message: "must not set the field(s)", Paths: []string{"persistentVolumeClaim"}}),
}, {
name: "no volume source",
v: corev1.Volume{
diff --git a/pkg/apis/serving/v1/revision_defaults.go b/pkg/apis/serving/v1/revision_defaults.go
index 88724199f93e..354b12d89d6f 100644
--- a/pkg/apis/serving/v1/revision_defaults.go
+++ b/pkg/apis/serving/v1/revision_defaults.go
@@ -121,7 +121,7 @@ func (rs *RevisionSpec) applyDefault(ctx context.Context, container *corev1.Cont
vNames := make(sets.String)
for _, v := range rs.PodSpec.Volumes {
- if v.EmptyDir != nil {
+ if v.EmptyDir != nil || v.PersistentVolumeClaim != nil {
vNames.Insert(v.Name)
}
}
diff --git a/pkg/reconciler/revision/table_test.go b/pkg/reconciler/revision/table_test.go
index 780acb5cc335..b84631e4bbab 100644
--- a/pkg/reconciler/revision/table_test.go
+++ b/pkg/reconciler/revision/table_test.go
@@ -655,6 +655,30 @@ func TestReconcile(t *testing.T) {
}},
Key: "foo/first-reconcile",
Ctx: defaultconfig.ToContext(context.Background(), &defaultconfig.Config{Features: &defaultconfig.Features{PodSpecInitContainers: defaultconfig.Enabled}}),
+ }, {
+ Name: "first revision reconciliation with PVC, PVC enabled",
+ // Test the simplest successful reconciliation flow.
+ // We feed in a well formed Revision where none of its sub-resources exist,
+ // and we expect it to create them and initialize the Revision's status.
+ Objects: []runtime.Object{
+ Revision("foo", "first-reconcile", WithRevisionPVC()),
+ },
+ WantCreates: []runtime.Object{
+ // The first reconciliation of a Revision creates the following resources.
+ pa("foo", "first-reconcile"),
+ deploy(t, "foo", "first-reconcile", WithRevisionPVC()),
+ image("foo", "first-reconcile")},
+ WantStatusUpdates: []clientgotesting.UpdateActionImpl{{
+ Object: Revision("foo", "first-reconcile",
+ // The first reconciliation Populates the following status properties.
+ WithLogURL, allUnknownConditions, MarkDeploying("Deploying"),
+ withDefaultContainerStatuses(), WithRevisionObservedGeneration(1), WithRevisionPVC()),
+ }},
+ Key: "foo/first-reconcile",
+ Ctx: defaultconfig.ToContext(context.Background(), &defaultconfig.Config{Features: &defaultconfig.Features{
+ PodSpecPersistentVolumeClaim: defaultconfig.Enabled,
+ PodSpecPersistentVolumeWrite: defaultconfig.Enabled,
+ }}),
}}
table.Test(t, MakeFactory(func(ctx context.Context, listers *Listers, _ configmap.Watcher) controller.Reconciler {
diff --git a/pkg/reconciler/route/resources/service_test.go b/pkg/reconciler/route/resources/service_test.go
index 8c439babd0b0..2996506024fd 100644
--- a/pkg/reconciler/route/resources/service_test.go
+++ b/pkg/reconciler/route/resources/service_test.go
@@ -421,18 +421,20 @@ func testConfig() *config.Config {
TagTemplate: network.DefaultTagTemplate,
},
Features: &apiConfig.Features{
- MultiContainer: apiConfig.Disabled,
- PodSpecAffinity: apiConfig.Disabled,
- PodSpecFieldRef: apiConfig.Disabled,
- PodSpecDryRun: apiConfig.Enabled,
- PodSpecHostAliases: apiConfig.Disabled,
- PodSpecNodeSelector: apiConfig.Disabled,
- PodSpecTolerations: apiConfig.Disabled,
- PodSpecVolumesEmptyDir: apiConfig.Disabled,
- PodSpecInitContainers: apiConfig.Disabled,
- PodSpecPriorityClassName: apiConfig.Disabled,
- PodSpecSchedulerName: apiConfig.Disabled,
- TagHeaderBasedRouting: apiConfig.Disabled,
+ MultiContainer: apiConfig.Disabled,
+ PodSpecAffinity: apiConfig.Disabled,
+ PodSpecFieldRef: apiConfig.Disabled,
+ PodSpecDryRun: apiConfig.Enabled,
+ PodSpecHostAliases: apiConfig.Disabled,
+ PodSpecNodeSelector: apiConfig.Disabled,
+ PodSpecTolerations: apiConfig.Disabled,
+ PodSpecVolumesEmptyDir: apiConfig.Disabled,
+ PodSpecPersistentVolumeClaim: apiConfig.Disabled,
+ PodSpecPersistentVolumeWrite: apiConfig.Disabled,
+ PodSpecInitContainers: apiConfig.Disabled,
+ PodSpecPriorityClassName: apiConfig.Disabled,
+ PodSpecSchedulerName: apiConfig.Disabled,
+ TagHeaderBasedRouting: apiConfig.Disabled,
},
}
}
diff --git a/pkg/testing/v1/revision.go b/pkg/testing/v1/revision.go
index 3445dc0ab9dc..6a5cdfa82071 100644
--- a/pkg/testing/v1/revision.go
+++ b/pkg/testing/v1/revision.go
@@ -232,6 +232,22 @@ func WithRevisionInitContainers() RevisionOption {
}
}
+func WithRevisionPVC() RevisionOption {
+ return func(r *v1.Revision) {
+ r.Spec.Volumes = []corev1.Volume{{
+ Name: "claimvolume",
+ VolumeSource: corev1.VolumeSource{PersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{
+ ClaimName: "myclaim",
+ ReadOnly: false,
+ }}},
+ }
+ r.Spec.Containers[0].VolumeMounts = []corev1.VolumeMount{{
+ Name: "claimvolume",
+ MountPath: "/data",
+ }}
+ }
+}
+
// Revision creates a revision object with given ns/name and options.
func Revision(namespace, name string, ro ...RevisionOption) *v1.Revision {
r := &v1.Revision{
From d844f470d1d087dcd124b507aced819913ff99a3 Mon Sep 17 00:00:00 2001
From: jwcesign
Date: Thu, 20 Jan 2022 11:10:35 +0800
Subject: [PATCH 095/733] CodeReading: Move var to where is used (#12532)
---
cmd/queue/main.go | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/cmd/queue/main.go b/cmd/queue/main.go
index 05cb7b69909c..40a517d762be 100644
--- a/cmd/queue/main.go
+++ b/cmd/queue/main.go
@@ -225,15 +225,11 @@ func buildProbe(logger *zap.SugaredLogger, encodedProbe string, autodetectHTTP2
func buildServer(ctx context.Context, env config, probeContainer func() bool, stats *network.RequestStats, logger *zap.SugaredLogger,
ce *queue.ConcurrencyEndpoint) (server *http.Server, drain func()) {
- maxIdleConns := 1000 // TODO: somewhat arbitrary value for CC=0, needs experimental validation.
- if env.ContainerConcurrency > 0 {
- maxIdleConns = env.ContainerConcurrency
- }
target := net.JoinHostPort("127.0.0.1", env.UserPort)
httpProxy := pkghttp.NewHeaderPruningReverseProxy(target, pkghttp.NoHostOverride, activator.RevisionHeaders)
- httpProxy.Transport = buildTransport(env, logger, maxIdleConns)
+ httpProxy.Transport = buildTransport(env, logger)
httpProxy.ErrorHandler = pkghandler.Error(logger)
httpProxy.BufferPool = network.NewBufferPool()
httpProxy.FlushInterval = network.FlushInterval
@@ -294,9 +290,13 @@ func buildServer(ctx context.Context, env config, probeContainer func() bool, st
return pkgnet.NewServer(":"+env.QueueServingPort, composedHandler), drainer.Drain
}
-func buildTransport(env config, logger *zap.SugaredLogger, maxConns int) http.RoundTripper {
+func buildTransport(env config, logger *zap.SugaredLogger) http.RoundTripper {
+ maxIdleConns := 1000 // TODO: somewhat arbitrary value for CC=0, needs experimental validation.
+ if env.ContainerConcurrency > 0 {
+ maxIdleConns = env.ContainerConcurrency
+ }
// set max-idle and max-idle-per-host to same value since we're always proxying to the same host.
- transport := pkgnet.NewProxyAutoTransport(maxConns /* max-idle */, maxConns /* max-idle-per-host */)
+ transport := pkgnet.NewProxyAutoTransport(maxIdleConns /* max-idle */, maxIdleConns /* max-idle-per-host */)
if env.TracingConfigBackend == tracingconfig.None {
return transport
From bd2a43600cd69131575f761bd6ded244d9a560cd Mon Sep 17 00:00:00 2001
From: Matthias Wessendorf
Date: Thu, 20 Jan 2022 13:20:35 +0100
Subject: [PATCH 096/733] :dizzy: Adding k8s 1.23.0 to GA action e2e workflows
(#12411)
:fire: Remove 1.20 api usage
Signed-off-by: Matthias Wessendorf
---
.github/workflows/kind-e2e.yaml | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/.github/workflows/kind-e2e.yaml b/.github/workflows/kind-e2e.yaml
index 439a2dfab8f4..f536e6afc9e1 100644
--- a/.github/workflows/kind-e2e.yaml
+++ b/.github/workflows/kind-e2e.yaml
@@ -18,10 +18,10 @@ jobs:
fail-fast: false # Keep running if one leg fails.
matrix:
cluster:
- - v1.20.7/contour
- v1.21.1/kourier
- v1.22.2/istio
- - v1.22.2/gateway-api
+ - v1.23.0/contour
+ - v1.23.0/gateway-api
test-suite:
- ./test/conformance/runtime
@@ -32,12 +32,6 @@ jobs:
# Map between K8s and KinD versions.
# This is attempting to make it a bit clearer what's being tested.
# See: https://github.com/kubernetes-sigs/kind/releases
- - cluster: v1.20.7/contour
- k8s-version: v1.20.7
- kind-version: v0.11.1
- kind-image-sha: sha256:cbeaf907fc78ac97ce7b625e4bf0de16e3ea725daf6b04f930bd14c67c671ff9
- kingress: contour
- cluster-suffix: c${{ github.run_id }}.local
- cluster: v1.21.1/kourier
k8s-version: v1.21.1
kind-version: v0.11.1
@@ -50,10 +44,16 @@ jobs:
kind-image-sha: sha256:f638a08c1f68fe2a99e724ace6df233a546eaf6713019a0b310130a4f91ebe7f
kingress: istio
cluster-suffix: c${{ github.run_id }}.local
- - cluster: v1.22.2/gateway-api
- k8s-version: v1.22.2
+ - cluster: v1.23.0/contour
+ k8s-version: v1.23.0
kind-version: v0.11.1
- kind-image-sha: sha256:f638a08c1f68fe2a99e724ace6df233a546eaf6713019a0b310130a4f91ebe7f
+ kind-image-sha: sha256:49824ab1727c04e56a21a5d8372a402fcd32ea51ac96a2706a12af38934f81ac
+ kingress: contour
+ cluster-suffix: c${{ github.run_id }}.local
+ - cluster: v1.23.0/gateway-api
+ k8s-version: v1.23.0
+ kind-version: v0.11.1
+ kind-image-sha: sha256:49824ab1727c04e56a21a5d8372a402fcd32ea51ac96a2706a12af38934f81ac
kingress: gateway-api
cluster-suffix: c${{ github.run_id }}.local
From 30f5c964d4498c1d9b1778e775b24ddabb68afb5 Mon Sep 17 00:00:00 2001
From: Dave Protasowski
Date: Thu, 20 Jan 2022 17:56:53 -0500
Subject: [PATCH 097/733] Move our CI to GKE 1.21 (#12509)
* bump GKE to 1.21
* clean up comments
* set a 60s stabilization window for the HPA e2e test
With GKE 1.21 I'm seeing this test fail regularly. My assumption is the scaling algorithms have changed
or have different timings. So rather than rely on the default 5 minute window let's make adjustments more aggresively.
* disable TestToScaleN due to it being really flakey with GKE 1.21
---
test/e2e-auto-tls-tests.sh | 7 +------
test/e2e-tests.sh | 10 +++-------
test/e2e-upgrade-tests.sh | 5 +----
test/e2e/autoscale_hpa_test.go | 3 ++-
4 files changed, 7 insertions(+), 18 deletions(-)
diff --git a/test/e2e-auto-tls-tests.sh b/test/e2e-auto-tls-tests.sh
index 0b881e8f319d..d893e0d4c568 100755
--- a/test/e2e-auto-tls-tests.sh
+++ b/test/e2e-auto-tls-tests.sh
@@ -158,12 +158,7 @@ function delete_dns_record() {
}
# Script entry point.
-
-# Skip installing istio as an add-on
-# Temporarily increasing the cluster size for serving tests to rule out
-# resource/eviction as causes of flakiness.
-# Pin to 1.20 since scale test is super flakey on 1.21
-initialize "$@" --skip-istio-addon --min-nodes=4 --max-nodes=4 --enable-ha --cluster-version=1.20
+initialize "$@" --skip-istio-addon --min-nodes=4 --max-nodes=4 --enable-ha --cluster-version=1.21
# Run the tests
header "Running tests"
diff --git a/test/e2e-tests.sh b/test/e2e-tests.sh
index 2425a36225a7..4fc6f283b727 100755
--- a/test/e2e-tests.sh
+++ b/test/e2e-tests.sh
@@ -28,12 +28,7 @@
source $(dirname $0)/e2e-common.sh
# Script entry point.
-
-# Skip installing istio as an add-on.
-# Temporarily increasing the cluster size for serving tests to rule out
-# resource/eviction as causes of flakiness.
-# Pin to 1.20 since scale test is super flakey on 1.21
-initialize --skip-istio-addon --min-nodes=4 --max-nodes=4 --enable-ha --cluster-version=1.20 "$@"
+initialize --skip-istio-addon --min-nodes=4 --max-nodes=4 --enable-ha --cluster-version=1.21 "$@"
# Run the tests
header "Running tests"
@@ -112,7 +107,8 @@ kubectl replace cm "config-gc" -n ${SYSTEM_NAMESPACE} -f ${TMP_DIR}/config-gc.ya
# Note that we use a very high -parallel because each ksvc is run as its own
# sub-test. If this is not larger than the maximum scale tested then the test
# simply cannot pass.
-go_test_e2e -timeout=20m -parallel=300 ./test/scale ${TEST_OPTIONS} || failed=1
+# TODO - Renable once we get this reliably passing on GKE 1.21
+# go_test_e2e -timeout=20m -parallel=300 ./test/scale ${TEST_OPTIONS} || failed=1
# Run HPA tests
go_test_e2e -timeout=30m -tags=hpa ./test/e2e ${TEST_OPTIONS} || failed=1
diff --git a/test/e2e-upgrade-tests.sh b/test/e2e-upgrade-tests.sh
index b1f08d2d4921..396c821f9800 100755
--- a/test/e2e-upgrade-tests.sh
+++ b/test/e2e-upgrade-tests.sh
@@ -40,10 +40,7 @@ function stage_test_resources() {
# Script entry point.
# Skip installing istio as an add-on.
-# Temporarily increasing the cluster size for serving tests to rule out
-# resource/eviction as causes of flakiness.
-# Pin to 1.20 since scale test is super flakey on 1.21
-initialize "$@" --skip-istio-addon --min-nodes=4 --max-nodes=4 --cluster-version=1.20 \
+initialize "$@" --skip-istio-addon --min-nodes=4 --max-nodes=4 --cluster-version=1.21 \
--install-latest-release
# TODO(#2656): Reduce the timeout after we get this test to consistently passing.
diff --git a/test/e2e/autoscale_hpa_test.go b/test/e2e/autoscale_hpa_test.go
index 53906935959f..fe28f42b7f64 100644
--- a/test/e2e/autoscale_hpa_test.go
+++ b/test/e2e/autoscale_hpa_test.go
@@ -94,6 +94,7 @@ func setupHPASvc(t *testing.T, metric string, target int) *TestContext {
autoscaling.MetricAnnotationKey: metric,
autoscaling.TargetAnnotationKey: strconv.Itoa(target),
autoscaling.MaxScaleAnnotationKey: fmt.Sprintf("%d", int(maxPods)),
+ autoscaling.WindowAnnotationKey: "20s",
}), rtesting.WithResourceRequirements(corev1.ResourceRequirements{
Requests: corev1.ResourceList{
corev1.ResourceCPU: resource.MustParse("30m"),
@@ -253,7 +254,7 @@ func waitForHPAState(t *testing.T, name, namespace string, clients *test.Clients
return false, err
}
if hpa.Status.CurrentMetrics == nil {
- t.Logf("Waiting for hpa.status is available: %v", hpa.Status)
+ t.Logf("Waiting for hpa.status is available: %#v", hpa.Status)
return false, nil
}
return true, nil
From 782603057277f43c7f510e238c84aa85d432f6b9 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 20 Jan 2022 16:24:03 -0800
Subject: [PATCH 098/733] Update net-certmanager nightly (#12530)
bumping knative.dev/net-certmanager 615f196...ab46e24:
> ab46e24 Update actions (# 343)
> 4fd49c1 Update community files (# 341)
Signed-off-by: Knative Automation
---
.../cert-manager-latest/net-certmanager.yaml | 44 +++++++++----------
1 file changed, 22 insertions(+), 22 deletions(-)
diff --git a/third_party/cert-manager-latest/net-certmanager.yaml b/third_party/cert-manager-latest/net-certmanager.yaml
index fa8230ca94a4..1a779ac6730a 100644
--- a/third_party/cert-manager-latest/net-certmanager.yaml
+++ b/third_party/cert-manager-latest/net-certmanager.yaml
@@ -19,9 +19,9 @@ metadata:
name: knative-serving-certmanager
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
serving.knative.dev/controller: "true"
networking.knative.dev/certificate-provider: cert-manager
rules:
@@ -53,9 +53,9 @@ metadata:
name: config.webhook.net-certmanager.networking.internal.knative.dev
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
networking.knative.dev/certificate-provider: cert-manager
webhooks:
- admissionReviewVersions:
@@ -95,9 +95,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
networking.knative.dev/certificate-provider: cert-manager
---
@@ -122,9 +122,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
networking.knative.dev/certificate-provider: cert-manager
data:
_example: |
@@ -172,9 +172,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
networking.knative.dev/certificate-provider: cert-manager
spec:
selector:
@@ -187,16 +187,16 @@ spec:
labels:
app: net-certmanager-controller
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/controller@sha256:31020888819775cac866679c15f82e5e8f14bd9d907af89cadaa453513a63a61
+ image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/controller@sha256:92a08ce1ce0e98fb5752fa2334c042373cb3b33a086b07b7f2f247bbc4dd8ba5
resources:
requests:
cpu: 30m
@@ -235,9 +235,9 @@ metadata:
labels:
app: net-certmanager-controller
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
networking.knative.dev/certificate-provider: cert-manager
name: net-certmanager-controller
namespace: knative-serving
@@ -275,9 +275,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
networking.knative.dev/certificate-provider: cert-manager
spec:
selector:
@@ -291,17 +291,17 @@ spec:
labels:
app: net-certmanager-webhook
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
role: net-certmanager-webhook
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/webhook@sha256:1f8788dc58349a7b4fef51363f74c9c09b937fb285c9e4a8b6e4bdb73963ab94
+ image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/webhook@sha256:4e208521fa6ae5b3a649034997df0eeef202b3a2377382d924843ddc336e55f5
resources:
requests:
cpu: 20m
@@ -361,9 +361,9 @@ metadata:
labels:
role: net-certmanager-webhook
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220105-615f1960"
+ app.kubernetes.io/version: "20220120-ab46e242"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220105-615f1960"
+ serving.knative.dev/release: "v20220120-ab46e242"
networking.knative.dev/certificate-provider: cert-manager
spec:
ports:
From cec1a478c45c4a7f845db4830c6f68d130db5bf8 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 20 Jan 2022 17:28:04 -0800
Subject: [PATCH 099/733] Update net-gateway-api nightly (#12529)
bumping knative.dev/net-gateway-api 7683b1b...1b2ff08:
> 1b2ff08 Bump k8s version to 1.23.0 in kind (# 236)
> 335b614 upgrade to latest dependencies (# 235)
Signed-off-by: Knative Automation
---
third_party/gateway-api-latest/istio-gateway.yaml | 2 +-
third_party/gateway-api-latest/net-gateway-api.yaml | 12 ++++++------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/third_party/gateway-api-latest/istio-gateway.yaml b/third_party/gateway-api-latest/istio-gateway.yaml
index 05349db61220..955da1aabc8e 100644
--- a/third_party/gateway-api-latest/istio-gateway.yaml
+++ b/third_party/gateway-api-latest/istio-gateway.yaml
@@ -20,7 +20,7 @@ metadata:
name: knative-local-gateway
namespace: istio-system
labels:
- serving.knative.dev/release: "v20220118-7683b1b9"
+ serving.knative.dev/release: "v20220119-1b2ff089"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
diff --git a/third_party/gateway-api-latest/net-gateway-api.yaml b/third_party/gateway-api-latest/net-gateway-api.yaml
index b2b15e850fff..5db599e320ca 100644
--- a/third_party/gateway-api-latest/net-gateway-api.yaml
+++ b/third_party/gateway-api-latest/net-gateway-api.yaml
@@ -2125,7 +2125,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-admin
labels:
- serving.knative.dev/release: "v20220118-7683b1b9"
+ serving.knative.dev/release: "v20220119-1b2ff089"
aggregationRule:
clusterRoleSelectors:
- matchLabels:
@@ -2137,7 +2137,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-core
labels:
- serving.knative.dev/release: "v20220118-7683b1b9"
+ serving.knative.dev/release: "v20220119-1b2ff089"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["networking.x-k8s.io"]
@@ -2165,7 +2165,7 @@ metadata:
name: config-gateway
namespace: knative-serving
labels:
- serving.knative.dev/release: "v20220118-7683b1b9"
+ serving.knative.dev/release: "v20220119-1b2ff089"
data:
_example: |
################################
@@ -2219,9 +2219,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: net-gateway-api
app.kubernetes.io/component: net-gateway-api
- app.kubernetes.io/version: "20220118-7683b1b9"
+ app.kubernetes.io/version: "20220119-1b2ff089"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-7683b1b9"
+ serving.knative.dev/release: "v20220119-1b2ff089"
spec:
replicas: 1
selector:
@@ -2247,7 +2247,7 @@ spec:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:d3fdece88259857afdf6e9ffda47477b77f499830f9eb4fa2026610ff0485008
+ image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:70d1ddb29e13fe1802529bd9a4f187a92a174c438fef77906810dab72953b713
resources:
requests:
cpu: 100m
From a4f8b72183c4723103d4fd5eb15d63cae04ec426 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 20 Jan 2022 17:28:10 -0800
Subject: [PATCH 100/733] Update net-kourier nightly (#12531)
bumping knative.dev/net-kourier f3ceea7...bdac0fe:
> bdac0fe upgrade to latest dependencies (# 755)
> e14829c Bump k8s version to 1.23.0 in kind (# 756)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index 91c7812f2399..52d817f93659 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
- serving.knative.dev/release: "v20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:e87618da4c1e9f87af7e603ac5582065b8a62f978d9f623f741fa94a77d5c83f
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:5cbc4cd41dff8381de7d9497b865af7d416ef5e6057547b5db07aa8467c0375a
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220118-f3ceea74"
+ app.kubernetes.io/version: "20220120-bdac0fe7"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220118-f3ceea74"
+ serving.knative.dev/release: "v20220120-bdac0fe7"
spec:
ports:
- name: http2
From 02417c60a2f94cf2446592d46fe5fcd8799f6061 Mon Sep 17 00:00:00 2001
From: Dave Protasowski
Date: Thu, 20 Jan 2022 22:16:03 -0500
Subject: [PATCH 101/733] bump ggcr again which includes azure credential
timing fixes (#12539)
---
go.mod | 6 +-
go.sum | 66 +++--
.../github.com/Azure/azure-sdk-for-go/LICENSE | 202 -------------
.../Azure/azure-sdk-for-go/LICENSE.txt | 21 ++
.../github.com/Azure/azure-sdk-for-go/NOTICE | 5 -
.../Azure/azure-sdk-for-go/NOTICE.txt | 29 ++
.../github.com/dimchansky/utfbom/LICENSE | 2 +-
.../github.com/golang-jwt/jwt/v4}/LICENSE | 1 +
.../github.com/Azure/azure-sdk-for-go/LICENSE | 202 -------------
.../Azure/azure-sdk-for-go/LICENSE.txt | 21 ++
.../github.com/Azure/azure-sdk-for-go/NOTICE | 5 -
.../Azure/azure-sdk-for-go/NOTICE.txt | 29 ++
.../containerregistry/CHANGELOG.md | 2 +
.../containerregistry/accesstokens.go | 17 +-
.../containerregistry/blob.go | 26 +-
.../containerregistry/client.go | 15 +-
.../containerregistry/dataplane_meta.json | 11 +
.../containerregistry/manifests.go | 21 +-
.../containerregistry/models.go | 21 +-
.../containerregistry/refreshtokens.go | 16 +-
.../containerregistry/repository.go | 19 +-
.../containerregistry/tag.go | 19 +-
.../containerregistry/v2support.go | 16 +-
.../containerregistry/version.go | 15 +-
.../Azure/azure-sdk-for-go/version/version.go | 20 +-
.../Azure/go-autorest/autorest/adal/go.mod | 6 +-
.../Azure/go-autorest/autorest/adal/go.sum | 21 +-
.../autorest/adal/go_mod_tidy_hack.go | 1 +
.../Azure/go-autorest/autorest/adal/sender.go | 21 +-
.../Azure/go-autorest/autorest/adal/token.go | 30 +-
.../go-autorest/autorest/adal/token_1.13.go | 3 +-
.../go-autorest/autorest/adal/token_legacy.go | 3 +-
.../Azure/go-autorest/autorest/azure/async.go | 4 +
.../go-autorest/autorest/azure/auth/auth.go | 75 +++--
.../go-autorest/autorest/azure/auth/go.mod | 11 +-
.../go-autorest/autorest/azure/auth/go.sum | 44 +--
.../autorest/azure/auth/go_mod_tidy_hack.go | 1 +
.../Azure/go-autorest/autorest/azure/azure.go | 14 +-
.../go-autorest/autorest/azure/cli/go.mod | 8 +-
.../go-autorest/autorest/azure/cli/go.sum | 35 ++-
.../autorest/azure/cli/go_mod_tidy_hack.go | 1 +
.../go-autorest/autorest/azure/cli/token.go | 104 +++++--
.../autorest/azure/environments.go | 40 ++-
.../Azure/go-autorest/autorest/client.go | 2 +-
.../Azure/go-autorest/autorest/go.mod | 7 +-
.../Azure/go-autorest/autorest/go.sum | 30 +-
.../go-autorest/autorest/go_mod_tidy_hack.go | 1 +
.../Azure/go-autorest/autorest/preparer.go | 2 +
.../autorest/retriablerequest_1.7.go | 1 +
.../autorest/retriablerequest_1.8.go | 1 +
.../Azure/go-autorest/autorest/sender.go | 27 +-
.../go-autorest/autorest/utility_1.13.go | 1 +
.../go-autorest/autorest/utility_legacy.go | 1 +
.../pkg/credhelper/helper.go | 28 +-
.../pkg/registry/const.go | 9 +-
.../pkg/registry/registry.go | 12 +-
.../github.com/dimchansky/utfbom/.travis.yml | 21 +-
vendor/github.com/dimchansky/utfbom/LICENSE | 2 +-
vendor/github.com/dimchansky/utfbom/go.mod | 2 +-
.../form3tech-oss/jwt-go/.travis.yml | 12 -
.../form3tech-oss/jwt-go/MIGRATION_GUIDE.md | 97 -------
.../github.com/form3tech-oss/jwt-go/claims.go | 136 ---------
.../form3tech-oss/jwt-go/map_claims.go | 110 -------
.../github.com/form3tech-oss/jwt-go/token.go | 108 -------
.../jwt-go => golang-jwt/jwt/v4}/.gitignore | 1 -
.../github.com/golang-jwt/jwt/v4}/LICENSE | 1 +
.../golang-jwt/jwt/v4/MIGRATION_GUIDE.md | 22 ++
.../jwt-go => golang-jwt/jwt/v4}/README.md | 52 ++--
.../jwt/v4}/VERSION_HISTORY.md | 19 +-
vendor/github.com/golang-jwt/jwt/v4/claims.go | 273 ++++++++++++++++++
.../jwt-go => golang-jwt/jwt/v4}/doc.go | 0
.../jwt-go => golang-jwt/jwt/v4}/ecdsa.go | 30 +-
.../jwt/v4}/ecdsa_utils.go | 8 +-
.../github.com/golang-jwt/jwt/v4/ed25519.go | 85 ++++++
.../golang-jwt/jwt/v4/ed25519_utils.go | 64 ++++
.../jwt-go => golang-jwt/jwt/v4}/errors.go | 11 +-
vendor/github.com/golang-jwt/jwt/v4/go.mod | 3 +
vendor/github.com/golang-jwt/jwt/v4/go.sum | 0
.../jwt-go => golang-jwt/jwt/v4}/hmac.go | 6 +-
.../golang-jwt/jwt/v4/map_claims.go | 148 ++++++++++
.../jwt-go => golang-jwt/jwt/v4}/none.go | 2 +-
.../jwt-go => golang-jwt/jwt/v4}/parser.go | 42 ++-
.../golang-jwt/jwt/v4/parser_option.go | 29 ++
.../jwt-go => golang-jwt/jwt/v4}/rsa.go | 6 +-
.../jwt-go => golang-jwt/jwt/v4}/rsa_pss.go | 6 +-
.../jwt-go => golang-jwt/jwt/v4}/rsa_utils.go | 16 +-
.../jwt/v4}/signing_method.go | 17 +-
.../golang-jwt/jwt/v4/staticcheck.conf | 1 +
vendor/github.com/golang-jwt/jwt/v4/token.go | 131 +++++++++
vendor/github.com/golang-jwt/jwt/v4/types.go | 127 ++++++++
.../pkg/authn/k8schain/go.mod | 10 +-
.../pkg/authn/k8schain/go.sum | 57 ++++
.../pkg/authn/keychain.go | 4 +-
.../google.golang.org/api/dns/v1/dns-gen.go | 50 ++--
.../api/internal/gensupport/resumable.go | 67 +----
.../api/internal/gensupport/retry.go | 106 +++++++
.../api/internal/gensupport/send.go | 23 +-
vendor/modules.txt | 28 +-
98 files changed, 1863 insertions(+), 1421 deletions(-)
delete mode 100644 third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/LICENSE
create mode 100644 third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/LICENSE.txt
delete mode 100644 third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/NOTICE
create mode 100644 third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/NOTICE.txt
rename {vendor/github.com/form3tech-oss/jwt-go => third_party/VENDOR-LICENSE/github.com/golang-jwt/jwt/v4}/LICENSE (96%)
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/LICENSE
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/LICENSE.txt
delete mode 100644 vendor/github.com/Azure/azure-sdk-for-go/NOTICE
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/NOTICE.txt
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/CHANGELOG.md
create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/dataplane_meta.json
delete mode 100644 vendor/github.com/form3tech-oss/jwt-go/.travis.yml
delete mode 100644 vendor/github.com/form3tech-oss/jwt-go/MIGRATION_GUIDE.md
delete mode 100644 vendor/github.com/form3tech-oss/jwt-go/claims.go
delete mode 100644 vendor/github.com/form3tech-oss/jwt-go/map_claims.go
delete mode 100644 vendor/github.com/form3tech-oss/jwt-go/token.go
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/.gitignore (95%)
rename {third_party/VENDOR-LICENSE/github.com/form3tech-oss/jwt-go => vendor/github.com/golang-jwt/jwt/v4}/LICENSE (96%)
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/MIGRATION_GUIDE.md
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/README.md (60%)
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/VERSION_HISTORY.md (84%)
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/claims.go
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/doc.go (100%)
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/ecdsa.go (79%)
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/ecdsa_utils.go (81%)
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/ed25519.go
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/ed25519_utils.go
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/errors.go (82%)
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/go.mod
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/go.sum
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/hmac.go (90%)
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/map_claims.go
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/none.go (94%)
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/parser.go (78%)
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/parser_option.go
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/rsa.go (92%)
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/rsa_pss.go (94%)
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/rsa_utils.go (72%)
rename vendor/github.com/{form3tech-oss/jwt-go => golang-jwt/jwt/v4}/signing_method.go (66%)
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/staticcheck.conf
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/token.go
create mode 100644 vendor/github.com/golang-jwt/jwt/v4/types.go
create mode 100644 vendor/google.golang.org/api/internal/gensupport/retry.go
diff --git a/go.mod b/go.mod
index 5e9850a3314f..6bdfd11938f5 100644
--- a/go.mod
+++ b/go.mod
@@ -8,8 +8,8 @@ require (
github.com/davecgh/go-spew v1.1.1
github.com/gogo/protobuf v1.3.2
github.com/google/go-cmp v0.5.6
- github.com/google/go-containerregistry v0.8.1-0.20220114205711-890d5b362eb8
- github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220114205711-890d5b362eb8
+ github.com/google/go-containerregistry v0.8.1-0.20220120151853-ac864e57b117
+ github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220120151853-ac864e57b117
github.com/google/gofuzz v1.2.0
github.com/gorilla/websocket v1.4.2
github.com/hashicorp/golang-lru v0.5.4
@@ -27,7 +27,7 @@ require (
golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c
golang.org/x/time v0.0.0-20211116232009-f0f3c7e86c11
- google.golang.org/api v0.62.0
+ google.golang.org/api v0.63.0
google.golang.org/grpc v1.43.0
k8s.io/api v0.22.5
k8s.io/apiextensions-apiserver v0.22.5
diff --git a/go.sum b/go.sum
index 89722abc7c1b..a194ca0e3ebf 100644
--- a/go.sum
+++ b/go.sum
@@ -4,6 +4,7 @@ cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMT
cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU=
cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU=
cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
+cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc=
cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0=
cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To=
@@ -16,6 +17,7 @@ cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOY
cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY=
cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI=
cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk=
+cloud.google.com/go v0.75.0/go.mod h1:VGuuCn7PG0dwsd5XPVm2Mm3wlh3EL55/79EKB6hlPTY=
cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg=
cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8=
cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0=
@@ -48,6 +50,7 @@ cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0Zeo
cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk=
cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs=
cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0=
+cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo=
cloud.google.com/go/storage v1.18.2/go.mod h1:AiIj7BWXyhO5gGVmYJ+S8tbkCx3yb0IMjua8Aw4naVM=
contrib.go.opencensus.io/exporter/ocagent v0.7.1-0.20200907061046-05415f1de66d h1:LblfooH1lKOpp1hIhukktmSAxFkqMPFk9KR6iZ0MJNI=
contrib.go.opencensus.io/exporter/ocagent v0.7.1-0.20200907061046-05415f1de66d/go.mod h1:IshRmMJBhDfFj5Y67nVhMYTTIze91RUeT73ipWKs/GY=
@@ -57,8 +60,9 @@ contrib.go.opencensus.io/exporter/zipkin v0.1.2 h1:YqE293IZrKtqPnpwDPH/lOqTWD/s3
contrib.go.opencensus.io/exporter/zipkin v0.1.2/go.mod h1:mP5xM3rrgOjpn79MM8fZbj3gsxcuytSqtH0dxSWW1RE=
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
github.com/Azure/azure-sdk-for-go v16.2.1+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
-github.com/Azure/azure-sdk-for-go v46.4.0+incompatible h1:fCN6Pi+tEiEwFa8RSmtVlFHRXEZ+DJm9gfx/MKqYWw4=
github.com/Azure/azure-sdk-for-go v46.4.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
+github.com/Azure/azure-sdk-for-go v61.2.0+incompatible h1:sSormXkfW0ov1vh6ihTBRQxdfg73fPqkccl50GbR9iM=
+github.com/Azure/azure-sdk-for-go v61.2.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
github.com/Azure/go-ansiterm v0.0.0-20210608223527-2377c96fe795/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E=
@@ -68,17 +72,21 @@ github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSW
github.com/Azure/go-autorest/autorest v0.11.1/go.mod h1:JFgpikqFJ/MleTTxwepExTKnFUKKszPS8UavbQYUMuw=
github.com/Azure/go-autorest/autorest v0.11.6/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
github.com/Azure/go-autorest/autorest v0.11.8/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
-github.com/Azure/go-autorest/autorest v0.11.18 h1:90Y4srNYrwOtAgVo3ndrQkTYn6kf1Eg/AjTFJ8Is2aM=
github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA=
+github.com/Azure/go-autorest/autorest v0.11.24 h1:1fIGgHKqVm54KIPT+q8Zmd1QlVsmHqeUGso5qm2BqqE=
+github.com/Azure/go-autorest/autorest v0.11.24/go.mod h1:G6kyRlFnTuSbEYkQGawPfsCswgme4iYf6rfSKUDzbCc=
github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg=
github.com/Azure/go-autorest/autorest/adal v0.9.4/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
-github.com/Azure/go-autorest/autorest/adal v0.9.13 h1:Mp5hbtOePIzM8pJVRa3YLrWWmZtoxRXqUEzCfJt3+/Q=
github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M=
-github.com/Azure/go-autorest/autorest/azure/auth v0.5.2 h1:R1pgoZkhXuv4+0ky9r3e5pcnRXWcXGIuPXpC/xkc7uI=
+github.com/Azure/go-autorest/autorest/adal v0.9.18 h1:kLnPsRjzZZUF3K5REu/Kc+qMQrvuza2bwSnNdhmzLfQ=
+github.com/Azure/go-autorest/autorest/adal v0.9.18/go.mod h1:XVVeme+LZwABT8K5Lc3hA4nAe8LDBVle26gTrguhhPQ=
github.com/Azure/go-autorest/autorest/azure/auth v0.5.2/go.mod h1:q98IH4qgc3eWM4/WOeR5+YPmBuy8Lq0jNRDwSM0CuFk=
-github.com/Azure/go-autorest/autorest/azure/cli v0.4.1 h1:jwcD1wURu0+hKceV04MubZmKLzwEYOCz6q4aOtVZ+Ng=
+github.com/Azure/go-autorest/autorest/azure/auth v0.5.11 h1:P6bYXFoao05z5uhOQzbC3Qd8JqF3jUoocoTeIxkp2cA=
+github.com/Azure/go-autorest/autorest/azure/auth v0.5.11/go.mod h1:84w/uV8E37feW2NCJ08uT9VBfjfUHpgLVnG2InYD6cg=
github.com/Azure/go-autorest/autorest/azure/cli v0.4.1/go.mod h1:JfDgiIO1/RPu6z42AdQTyjOoCM2MFhLqSBDvMEkDgcg=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.5 h1:0W/yGmFdTIT77fvdlGZ0LMISoLHFJ7Tx4U0yeB+uFs4=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.5/go.mod h1:ADQAXrkgm7acgWVUNamOgh8YNrv4p27l3Wc55oVfpzg=
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
github.com/Azure/go-autorest/autorest/mocks v0.4.0/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
@@ -223,8 +231,8 @@ github.com/cespare/xxhash/v2 v2.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cb
github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
github.com/checkpoint-restore/go-criu/v4 v4.1.0/go.mod h1:xUQBLp4RLc5zJtWY++yjOoMoB5lihDt7fai+75m+rGw=
github.com/checkpoint-restore/go-criu/v5 v5.0.0/go.mod h1:cfwC0EG7HMUenopBsUf9d89JlCLQIfgVcNsNN0t6T2M=
-github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86 h1:VZogJ199yfR3BRTzpDcejsFrBCJKLgi9V37K74/YWC8=
-github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86/go.mod h1:Zlre/PVxuSI9y6/UV4NwGixQ48RHQDSPiUkofr6rbMU=
+github.com/chrismellard/docker-credential-acr-env v0.0.0-20220119192733-fe33c00cee21 h1:XlpL9EHrPOBJMLDDOf35/G4t5rGAFNNAZQ3cDcWavtc=
+github.com/chrismellard/docker-credential-acr-env v0.0.0-20220119192733-fe33c00cee21/go.mod h1:Zlre/PVxuSI9y6/UV4NwGixQ48RHQDSPiUkofr6rbMU=
github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
@@ -375,8 +383,9 @@ github.com/dgryski/go-gk v0.0.0-20200319235926-a69029f61654/go.mod h1:qm+vckxRlD
github.com/dgryski/go-lttb v0.0.0-20180810165845-318fcdf10a77 h1:iRnqZBF0a1hoOOjOdPKf+IxqlJZOas7A48j77RAc7Yg=
github.com/dgryski/go-lttb v0.0.0-20180810165845-318fcdf10a77/go.mod h1:Va5MyIzkU0rAM92tn3hb3Anb7oz7KcnixF49+2wOMe4=
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
-github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
+github.com/dimchansky/utfbom v1.1.1 h1:vV6w1AhK4VMnhBno/TPVCoK9U/LP0PkLCS9tbxHdi/U=
+github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE=
github.com/dnaeon/go-vcr v1.0.1/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E=
github.com/docker/cli v20.10.12+incompatible h1:lZlz0uzG+GH+c0plStMUdF/qk3ppmgnswpR5EbqzVGA=
github.com/docker/cli v20.10.12+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
@@ -432,8 +441,8 @@ github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL
github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U=
github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
-github.com/form3tech-oss/jwt-go v3.2.3+incompatible h1:7ZaBxOI7TMoYBfyA3cQHErNNyAWIKUMIwqxEtgHOs5c=
github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
+github.com/form3tech-oss/jwt-go v3.2.5+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
github.com/fortytw2/leaktest v1.3.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g=
github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
@@ -499,6 +508,9 @@ github.com/gogo/protobuf v1.3.0/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXP
github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q=
github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
+github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
+github.com/golang-jwt/jwt/v4 v4.2.0 h1:besgBTC8w8HjP6NzQdxwKH9Z5oQMZ24ThTrHp3cZ8eU=
+github.com/golang-jwt/jwt/v4 v4.2.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
@@ -564,10 +576,10 @@ github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
github.com/google/go-containerregistry v0.8.0/go.mod h1:wW5v71NHGnQyb4k+gSshjxidrC7lN33MdWEn+Mz9TsI=
github.com/google/go-containerregistry v0.8.1-0.20220110151055-a61fd0a8e2bb/go.mod h1:wW5v71NHGnQyb4k+gSshjxidrC7lN33MdWEn+Mz9TsI=
-github.com/google/go-containerregistry v0.8.1-0.20220114205711-890d5b362eb8 h1:ApavQfyjPOgZ8j/yCWZy4UV/CpLILzhBdjvFx+fvRTc=
-github.com/google/go-containerregistry v0.8.1-0.20220114205711-890d5b362eb8/go.mod h1:wW5v71NHGnQyb4k+gSshjxidrC7lN33MdWEn+Mz9TsI=
-github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220114205711-890d5b362eb8 h1:TQE5iKoyn94B7nqOBaVsSUIvC9ufsnqQy8zN4BJOlww=
-github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220114205711-890d5b362eb8/go.mod h1:gUz0Xep+89eZOY19OVQ9u+9xfaQZPtLmBgx4CFmNuhU=
+github.com/google/go-containerregistry v0.8.1-0.20220120151853-ac864e57b117 h1:Jcm0O+2f2Ul/sgoxCts2ocI1BTaJpP56SBb+0iO40Ug=
+github.com/google/go-containerregistry v0.8.1-0.20220120151853-ac864e57b117/go.mod h1:wW5v71NHGnQyb4k+gSshjxidrC7lN33MdWEn+Mz9TsI=
+github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220120151853-ac864e57b117 h1:bRrDPmm+4eFXtlwBa63SONIL/21QUdWi//hBcUaLZiE=
+github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220120151853-ac864e57b117/go.mod h1:BH7pLQnIZhfVpL7cRyWhvvz1bZLY9V45/HvXVh5UMDY=
github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20220110151055-a61fd0a8e2bb h1:TVAKj23PFWViWiy7iGOuVSHSD8T8DZ7gdDvW138EFgg=
github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20220110151055-a61fd0a8e2bb/go.mod h1:SK4EqntTk6tHEyNngoqHUwjjZaW6mfzLukei4+cbvu8=
github.com/google/go-github/v27 v27.0.6/go.mod h1:/0Gr8pJ55COkmv+S/yPKCczSkUPIM/LnFyubufRNIS0=
@@ -590,6 +602,7 @@ github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hf
github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
@@ -611,6 +624,7 @@ github.com/googleapis/gnostic v0.4.1/go.mod h1:LRhVm6pbyptWbWbuZ38d1eyptfvIytN3i
github.com/googleapis/gnostic v0.5.1/go.mod h1:6U4PtQXGIEt/Z3h5MAT7FNofLnw9vXk2cUuW7uA/OeU=
github.com/googleapis/gnostic v0.5.5 h1:9fHAtK0uDfpveeqqo1hkEZJcFvYXAiCN3UutL8F9xHw=
github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA=
+github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g=
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg=
github.com/gorilla/handlers v0.0.0-20150720190736-60c7bfde3e33/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ=
@@ -635,6 +649,7 @@ github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4
github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw=
github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q=
github.com/hashicorp/consul/api v1.11.0/go.mod h1:XjsvQN+RJGWI2TWy1/kqaE16HrR2J/FWgkYjdZQsX9M=
+github.com/hashicorp/consul/api v1.12.0/go.mod h1:6pVBMo0ebnYdt2S3H87XhekM/HHrUoTD2XXb/VrZVy0=
github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8=
github.com/hashicorp/consul/sdk v0.8.0/go.mod h1:GBvyrGALthsZObzUGsfgHZQDXjg4lOjagTIwIR1vPms=
github.com/hashicorp/errwrap v0.0.0-20141028054710-7554cd9344ce/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
@@ -888,6 +903,7 @@ github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/profile v1.2.1/go.mod h1:hJw3o1OdXxsrSjjVksARp5W95eeEaEfptyVZyv6JUPA=
github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI=
+github.com/pkg/sftp v1.13.1/go.mod h1:3HaPG6Dq1ILlpPZRO0HVMrsydcdLt6HRDccSgb87qRg=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
@@ -947,6 +963,7 @@ github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQD
github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
github.com/safchain/ethtool v0.0.0-20190326074333-42ed695e3de8/go.mod h1:Z0q5wiBQGYcxhMZ6gUqHn6pYNLypFAvaL3UvgZLR0U4=
github.com/sagikazarmark/crypt v0.3.0/go.mod h1:uD/D+6UF4SrIR1uGEv7bBNkNqLGqUr43MRiaGWX1Nig=
+github.com/sagikazarmark/crypt v0.4.0/go.mod h1:ALv2SRj7GxYV4HO9elxH9nS6M9gW+xDNxqmyJ6RfDFM=
github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
github.com/seccomp/libseccomp-golang v0.9.1/go.mod h1:GbW5+tmTXfcxTToHLXlScSlAvWlF4P2Ca7zGrPiEpWo=
@@ -971,6 +988,7 @@ github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTd
github.com/spf13/afero v1.3.3/go.mod h1:5KUK8ByomD5Ti5Artl0RtHeI5pTF7MIDuXL3yY520V4=
github.com/spf13/afero v1.4.1/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
+github.com/spf13/afero v1.8.0/go.mod h1:CtAatgMJh6bJEIs48Ay/FOnkljP3WeGUG0MC1RfAqwo=
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cast v1.4.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
@@ -991,6 +1009,7 @@ github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/y
github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg=
github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg=
github.com/spf13/viper v1.10.0/go.mod h1:SoyBPwAtKDzypXNDFKN5kzH7ppppbGZtls1UpIy5AsM=
+github.com/spf13/viper v1.10.1/go.mod h1:IGlFPqhNAPKRxohIzWpI5QEy4kuI7tcl5WvR+8qy1rU=
github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980/go.mod h1:AO3tvPzVZ/ayst6UlUKUv6rcPQInYe3IknH3jYhAKu8=
github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8=
github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw=
@@ -1128,9 +1147,14 @@ golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPh
golang.org/x/crypto v0.0.0-20201112155050-0c6587e931a9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
+golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
golang.org/x/crypto v0.0.0-20210817164053-32db794688a5/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
-golang.org/x/crypto v0.0.0-20210920023735-84f357641f63 h1:kETrAMYZq6WVGPa8IIixL0CaEcIUNi+1WX7grUoi3y8=
golang.org/x/crypto v0.0.0-20210920023735-84f357641f63/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
+golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce h1:Roh6XWxHFKrPgC/EQhVubSAGQ6Ozk6IdxHSzt1mR0EI=
+golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
@@ -1230,6 +1254,7 @@ golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qx
golang.org/x/net v0.0.0-20210813160813-60bc85c4be6d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20210917221730-978cfadd31cf/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211209124913-491a49abca63/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211216030914-fe4d6282115f h1:hEYJvxw1lSnWIl8X9ofsYMklzaDs90JI2az5YMd4fPM=
golang.org/x/net v0.0.0-20211216030914-fe4d6282115f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
@@ -1344,6 +1369,7 @@ golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1352,6 +1378,7 @@ golang.org/x/sys v0.0.0-20210324051608-47abb6519492/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210426230700-d19ff857e887/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
@@ -1370,9 +1397,10 @@ golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211205182925-97ca703d548d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.0.0-20220111092808-5a964db01320 h1:0jf+tOCoZ3LyutmCOWpVni1chK4VfFLhRsDK7MhqGRY=
-golang.org/x/sys v0.0.0-20220111092808-5a964db01320/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20220114195835-da31bd327af9 h1:XfKQ4OlFl8okEOr5UvAqFRVj8pY/4yfcXrddB8qAbU0=
+golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
@@ -1455,6 +1483,7 @@ golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4f
golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
+golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0=
golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
@@ -1507,8 +1536,9 @@ google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdr
google.golang.org/api v0.58.0/go.mod h1:cAbP2FsxoGVNwtgNAmmn3y5G1TWAiVYRmg4yku3lv+E=
google.golang.org/api v0.59.0/go.mod h1:sT2boj7M9YJxZzgeZqXogmhfmRWDtPzT31xkieUbuZU=
google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I=
-google.golang.org/api v0.62.0 h1:PhGymJMXfGBzc4lBRmrx9+1w4w2wEzURHNGF/sD/xGc=
google.golang.org/api v0.62.0/go.mod h1:dKmwPCydfsad4qCH08MSdgWjfHOyfpd4VtDGgRFdavw=
+google.golang.org/api v0.63.0 h1:n2bqqK895ygnBpdPDYetfy23K7fJ22wsrZKCyfuRkkA=
+google.golang.org/api v0.63.0/go.mod h1:gs4ij2ffTRXwuzzgJl/56BdwJaA194ijkfn++9tDuPo=
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
@@ -1559,7 +1589,9 @@ google.golang.org/genproto v0.0.0-20201110150050-8816d57aaa9a/go.mod h1:FWY/as6D
google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
diff --git a/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/LICENSE b/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/LICENSE
deleted file mode 100644
index 047555ec7e58..000000000000
--- a/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright 2020 Microsoft Corporation
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/LICENSE.txt b/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/LICENSE.txt
new file mode 100644
index 000000000000..05b0ebf5bc76
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/LICENSE.txt
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Microsoft Corporation.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/NOTICE b/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/NOTICE
deleted file mode 100644
index 2d1d72608c28..000000000000
--- a/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/NOTICE
+++ /dev/null
@@ -1,5 +0,0 @@
-Microsoft Azure-SDK-for-Go
-Copyright 2014-2017 Microsoft
-
-This product includes software developed at
-the Microsoft Corporation (https://www.microsoft.com).
diff --git a/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/NOTICE.txt b/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/NOTICE.txt
new file mode 100644
index 000000000000..a338672ec53b
--- /dev/null
+++ b/third_party/VENDOR-LICENSE/github.com/Azure/azure-sdk-for-go/NOTICE.txt
@@ -0,0 +1,29 @@
+NOTICES AND INFORMATION
+Do Not Translate or Localize
+
+This software incorporates material from third parties. Microsoft makes certain
+open source code available at https://3rdpartysource.microsoft.com, or you may
+send a check or money order for US $5.00, including the product name, the open
+source component name, and version number, to:
+
+Source Code Compliance Team
+Microsoft Corporation
+One Microsoft Way
+Redmond, WA 98052
+USA
+
+Notwithstanding any other terms, you may reverse engineer this software to the
+extent required to debug changes to any libraries licensed under the GNU Lesser
+General Public License.
+
+------------------------------------------------------------------------------
+
+Azure SDK for Go uses third-party libraries or other resources that may be
+distributed under licenses different than the Azure SDK for Go software.
+
+In the event that we accidentally failed to list a required notice, please
+bring it to our attention. Post an issue or email us:
+
+ azgosdkhelp@microsoft.com
+
+The attached notices are provided for information only.
diff --git a/third_party/VENDOR-LICENSE/github.com/dimchansky/utfbom/LICENSE b/third_party/VENDOR-LICENSE/github.com/dimchansky/utfbom/LICENSE
index 8dada3edaf50..6279cb87f434 100644
--- a/third_party/VENDOR-LICENSE/github.com/dimchansky/utfbom/LICENSE
+++ b/third_party/VENDOR-LICENSE/github.com/dimchansky/utfbom/LICENSE
@@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
- Copyright {yyyy} {name of copyright owner}
+ Copyright (c) 2018-2020, Dmitrij Koniajev (dimchansky@gmail.com)
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
diff --git a/vendor/github.com/form3tech-oss/jwt-go/LICENSE b/third_party/VENDOR-LICENSE/github.com/golang-jwt/jwt/v4/LICENSE
similarity index 96%
rename from vendor/github.com/form3tech-oss/jwt-go/LICENSE
rename to third_party/VENDOR-LICENSE/github.com/golang-jwt/jwt/v4/LICENSE
index df83a9c2f019..35dbc252041e 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/LICENSE
+++ b/third_party/VENDOR-LICENSE/github.com/golang-jwt/jwt/v4/LICENSE
@@ -1,4 +1,5 @@
Copyright (c) 2012 Dave Grijalva
+Copyright (c) 2021 golang-jwt maintainers
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/LICENSE b/vendor/github.com/Azure/azure-sdk-for-go/LICENSE
deleted file mode 100644
index 047555ec7e58..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright 2020 Microsoft Corporation
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/LICENSE.txt b/vendor/github.com/Azure/azure-sdk-for-go/LICENSE.txt
new file mode 100644
index 000000000000..05b0ebf5bc76
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/LICENSE.txt
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Microsoft Corporation.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/NOTICE b/vendor/github.com/Azure/azure-sdk-for-go/NOTICE
deleted file mode 100644
index 2d1d72608c28..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/NOTICE
+++ /dev/null
@@ -1,5 +0,0 @@
-Microsoft Azure-SDK-for-Go
-Copyright 2014-2017 Microsoft
-
-This product includes software developed at
-the Microsoft Corporation (https://www.microsoft.com).
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/NOTICE.txt b/vendor/github.com/Azure/azure-sdk-for-go/NOTICE.txt
new file mode 100644
index 000000000000..a338672ec53b
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/NOTICE.txt
@@ -0,0 +1,29 @@
+NOTICES AND INFORMATION
+Do Not Translate or Localize
+
+This software incorporates material from third parties. Microsoft makes certain
+open source code available at https://3rdpartysource.microsoft.com, or you may
+send a check or money order for US $5.00, including the product name, the open
+source component name, and version number, to:
+
+Source Code Compliance Team
+Microsoft Corporation
+One Microsoft Way
+Redmond, WA 98052
+USA
+
+Notwithstanding any other terms, you may reverse engineer this software to the
+extent required to debug changes to any libraries licensed under the GNU Lesser
+General Public License.
+
+------------------------------------------------------------------------------
+
+Azure SDK for Go uses third-party libraries or other resources that may be
+distributed under licenses different than the Azure SDK for Go software.
+
+In the event that we accidentally failed to list a required notice, please
+bring it to our attention. Post an issue or email us:
+
+ azgosdkhelp@microsoft.com
+
+The attached notices are provided for information only.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/CHANGELOG.md b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/CHANGELOG.md
new file mode 100644
index 000000000000..52911e4cc5e4
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/CHANGELOG.md
@@ -0,0 +1,2 @@
+# Change History
+
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/accesstokens.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/accesstokens.go
index 833d2c503485..e9bc66a39701 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/accesstokens.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/accesstokens.go
@@ -1,18 +1,7 @@
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -68,6 +57,7 @@ func (client AccessTokensClient) Get(ctx context.Context, service string, scope
result, err = client.GetResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.AccessTokensClient", "Get", resp, "Failure responding to request")
+ return
}
return
@@ -144,6 +134,7 @@ func (client AccessTokensClient) GetFromLogin(ctx context.Context, service strin
result, err = client.GetFromLoginResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.AccessTokensClient", "GetFromLogin", resp, "Failure responding to request")
+ return
}
return
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/blob.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/blob.go
index 2905576c69dd..da512a659e08 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/blob.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/blob.go
@@ -1,18 +1,7 @@
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -68,6 +57,7 @@ func (client BlobClient) CancelUpload(ctx context.Context, location string) (res
result, err = client.CancelUploadResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "CancelUpload", resp, "Failure responding to request")
+ return
}
return
@@ -138,6 +128,7 @@ func (client BlobClient) Check(ctx context.Context, name string, digest string)
result, err = client.CheckResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Check", resp, "Failure responding to request")
+ return
}
return
@@ -210,6 +201,7 @@ func (client BlobClient) CheckChunk(ctx context.Context, name string, digest str
result, err = client.CheckChunkResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "CheckChunk", resp, "Failure responding to request")
+ return
}
return
@@ -282,6 +274,7 @@ func (client BlobClient) Delete(ctx context.Context, name string, digest string)
result, err = client.DeleteResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Delete", resp, "Failure responding to request")
+ return
}
return
@@ -356,6 +349,7 @@ func (client BlobClient) EndUpload(ctx context.Context, digest string, location
result, err = client.EndUploadResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "EndUpload", resp, "Failure responding to request")
+ return
}
return
@@ -436,6 +430,7 @@ func (client BlobClient) Get(ctx context.Context, name string, digest string) (r
result, err = client.GetResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Get", resp, "Failure responding to request")
+ return
}
return
@@ -510,6 +505,7 @@ func (client BlobClient) GetChunk(ctx context.Context, name string, digest strin
result, err = client.GetChunkResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "GetChunk", resp, "Failure responding to request")
+ return
}
return
@@ -583,6 +579,7 @@ func (client BlobClient) GetStatus(ctx context.Context, location string) (result
result, err = client.GetStatusResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "GetStatus", resp, "Failure responding to request")
+ return
}
return
@@ -654,6 +651,7 @@ func (client BlobClient) Mount(ctx context.Context, name string, from string, mo
result, err = client.MountResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Mount", resp, "Failure responding to request")
+ return
}
return
@@ -729,6 +727,7 @@ func (client BlobClient) StartUpload(ctx context.Context, name string) (result a
result, err = client.StartUploadResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "StartUpload", resp, "Failure responding to request")
+ return
}
return
@@ -800,6 +799,7 @@ func (client BlobClient) Upload(ctx context.Context, value io.ReadCloser, locati
result, err = client.UploadResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.BlobClient", "Upload", resp, "Failure responding to request")
+ return
}
return
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/client.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/client.go
index bbf3fb2c3693..d0ca3cef41eb 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/client.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/client.go
@@ -3,19 +3,8 @@
// Metadata API definition for the Azure Container Registry runtime
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/dataplane_meta.json b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/dataplane_meta.json
new file mode 100644
index 000000000000..70f8146ccfb4
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/dataplane_meta.json
@@ -0,0 +1,11 @@
+{
+ "commit": "3c764635e7d442b3e74caf593029fcd440b3ef82",
+ "readme": "/_/azure-rest-api-specs/specification/containerregistry/data-plane/readme.md",
+ "tag": "package-2019-08",
+ "use": "@microsoft.azure/autorest.go@2.1.183",
+ "repository_url": "https://github.com/Azure/azure-rest-api-specs.git",
+ "autorest_command": "autorest --use=@microsoft.azure/autorest.go@2.1.183 --tag=package-2019-08 --go-sdk-folder=/_/azure-sdk-for-go --go --verbose --use-onever --version=V2 --go.license-header=MICROSOFT_MIT_NO_VERSION /_/azure-rest-api-specs/specification/containerregistry/data-plane/readme.md",
+ "additional_properties": {
+ "additional_options": "--go --verbose --use-onever --version=V2 --go.license-header=MICROSOFT_MIT_NO_VERSION"
+ }
+}
\ No newline at end of file
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/manifests.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/manifests.go
index e6c023fa78cb..64514378865d 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/manifests.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/manifests.go
@@ -1,18 +1,7 @@
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -67,6 +56,7 @@ func (client ManifestsClient) Create(ctx context.Context, name string, reference
result, err = client.CreateResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Create", resp, "Failure responding to request")
+ return
}
return
@@ -142,6 +132,7 @@ func (client ManifestsClient) Delete(ctx context.Context, name string, reference
result, err = client.DeleteResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Delete", resp, "Failure responding to request")
+ return
}
return
@@ -215,6 +206,7 @@ func (client ManifestsClient) Get(ctx context.Context, name string, reference st
result, err = client.GetResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "Get", resp, "Failure responding to request")
+ return
}
return
@@ -291,6 +283,7 @@ func (client ManifestsClient) GetAttributes(ctx context.Context, name string, re
result, err = client.GetAttributesResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "GetAttributes", resp, "Failure responding to request")
+ return
}
return
@@ -366,6 +359,7 @@ func (client ManifestsClient) GetList(ctx context.Context, name string, last str
result, err = client.GetListResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "GetList", resp, "Failure responding to request")
+ return
}
return
@@ -450,6 +444,7 @@ func (client ManifestsClient) UpdateAttributes(ctx context.Context, name string,
result, err = client.UpdateAttributesResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.ManifestsClient", "UpdateAttributes", resp, "Failure responding to request")
+ return
}
return
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/models.go
index 5c4ae1bc4584..5ae4916064d4 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/models.go
@@ -1,18 +1,7 @@
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -493,9 +482,9 @@ type OCIManifest struct {
SchemaVersion *int32 `json:"schemaVersion,omitempty"`
}
-// Platform the platform object describes the platform which the image in the manifest runs on. A full list of
-// valid operating system and architecture values are listed in the Go language documentation for $GOOS and
-// $GOARCH
+// Platform the platform object describes the platform which the image in the manifest runs on. A full list
+// of valid operating system and architecture values are listed in the Go language documentation for $GOOS
+// and $GOARCH
type Platform struct {
// Architecture - Specifies the CPU architecture, for example amd64 or ppc64le.
Architecture *string `json:"architecture,omitempty"`
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/refreshtokens.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/refreshtokens.go
index c1dab3b259ea..a3f2ef220fb8 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/refreshtokens.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/refreshtokens.go
@@ -1,18 +1,7 @@
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -69,6 +58,7 @@ func (client RefreshTokensClient) GetFromExchange(ctx context.Context, grantType
result, err = client.GetFromExchangeResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.RefreshTokensClient", "GetFromExchange", resp, "Failure responding to request")
+ return
}
return
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/repository.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/repository.go
index b0a856d5cb6a..7b7c4e3fd5d8 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/repository.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/repository.go
@@ -1,18 +1,7 @@
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -65,6 +54,7 @@ func (client RepositoryClient) Delete(ctx context.Context, name string) (result
result, err = client.DeleteResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "Delete", resp, "Failure responding to request")
+ return
}
return
@@ -135,6 +125,7 @@ func (client RepositoryClient) GetAttributes(ctx context.Context, name string) (
result, err = client.GetAttributesResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "GetAttributes", resp, "Failure responding to request")
+ return
}
return
@@ -207,6 +198,7 @@ func (client RepositoryClient) GetList(ctx context.Context, last string, n *int3
result, err = client.GetListResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "GetList", resp, "Failure responding to request")
+ return
}
return
@@ -283,6 +275,7 @@ func (client RepositoryClient) UpdateAttributes(ctx context.Context, name string
result, err = client.UpdateAttributesResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.RepositoryClient", "UpdateAttributes", resp, "Failure responding to request")
+ return
}
return
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/tag.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/tag.go
index 5690c1ad9c99..f53d4f36e547 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/tag.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/tag.go
@@ -1,18 +1,7 @@
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -66,6 +55,7 @@ func (client TagClient) Delete(ctx context.Context, name string, reference strin
result, err = client.DeleteResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "Delete", resp, "Failure responding to request")
+ return
}
return
@@ -137,6 +127,7 @@ func (client TagClient) GetAttributes(ctx context.Context, name string, referenc
result, err = client.GetAttributesResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "GetAttributes", resp, "Failure responding to request")
+ return
}
return
@@ -213,6 +204,7 @@ func (client TagClient) GetList(ctx context.Context, name string, last string, n
result, err = client.GetListResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "GetList", resp, "Failure responding to request")
+ return
}
return
@@ -300,6 +292,7 @@ func (client TagClient) UpdateAttributes(ctx context.Context, name string, refer
result, err = client.UpdateAttributesResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.TagClient", "UpdateAttributes", resp, "Failure responding to request")
+ return
}
return
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/v2support.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/v2support.go
index 56543f63049f..58fca35cbbec 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/v2support.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/v2support.go
@@ -1,18 +1,7 @@
package containerregistry
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
@@ -63,6 +52,7 @@ func (client V2SupportClient) Check(ctx context.Context) (result autorest.Respon
result, err = client.CheckResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "containerregistry.V2SupportClient", "Check", resp, "Failure responding to request")
+ return
}
return
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/version.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/version.go
index 874b077cf95b..1298b04717a3 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/version.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry/version.go
@@ -2,19 +2,8 @@ package containerregistry
import "github.com/Azure/azure-sdk-for-go/version"
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/version/version.go b/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
index 168697eafd8f..ef8efc9588ad 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
@@ -1,21 +1,7 @@
package version
-// Copyright (c) Microsoft and contributors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
// Number contains the semantic version of this SDK.
-const Number = "v46.4.0"
+const Number = "v61.2.0"
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/go.mod b/vendor/github.com/Azure/go-autorest/autorest/adal/go.mod
index 8c5d36ca61d1..264ef2d6ac17 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/go.mod
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/go.mod
@@ -1,6 +1,6 @@
module github.com/Azure/go-autorest/autorest/adal
-go 1.12
+go 1.15
require (
github.com/Azure/go-autorest v14.2.0+incompatible
@@ -8,6 +8,6 @@ require (
github.com/Azure/go-autorest/autorest/mocks v0.4.1
github.com/Azure/go-autorest/logger v0.2.1
github.com/Azure/go-autorest/tracing v0.6.0
- github.com/form3tech-oss/jwt-go v3.2.2+incompatible
- golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0
+ github.com/golang-jwt/jwt/v4 v4.0.0
+ golang.org/x/crypto v0.0.0-20210921155107-089bfa567519
)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/go.sum b/vendor/github.com/Azure/go-autorest/autorest/adal/go.sum
index 5ee68e700106..919ea16d607a 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/go.sum
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/go.sum
@@ -8,14 +8,13 @@ github.com/Azure/go-autorest/logger v0.2.1 h1:IG7i4p/mDa2Ce4TRyAO8IHnVhAVF3RFU+Z
github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
-github.com/form3tech-oss/jwt-go v3.2.2+incompatible h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=
-github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
-golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 h1:VklqNMn3ovrHsnt90PveolxSbWFaJdECFbxSq0Mqo2M=
-golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
-golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0 h1:hb9wdF1z5waM+dSIICn1l0DkLVDT3hqhhQsDNUmHPRE=
-golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
-golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
+github.com/golang-jwt/jwt/v4 v4.0.0 h1:RAqyYixv1p7uEnocuy8P1nru5wprCh/MH2BIlW5z5/o=
+github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
+golang.org/x/crypto v0.0.0-20210921155107-089bfa567519 h1:7I4JAnoQBe7ZtJcBaYHi5UtiO8tQHbUSXxL+pnGRANg=
+golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
+golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
+golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/go_mod_tidy_hack.go b/vendor/github.com/Azure/go-autorest/autorest/adal/go_mod_tidy_hack.go
index 7551b79235de..647a61bb8c95 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/go_mod_tidy_hack.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/go_mod_tidy_hack.go
@@ -1,3 +1,4 @@
+//go:build modhack
// +build modhack
package adal
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/sender.go b/vendor/github.com/Azure/go-autorest/autorest/adal/sender.go
index 1826a68dc825..eb649bce9f7d 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/sender.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/sender.go
@@ -16,9 +16,11 @@ package adal
import (
"crypto/tls"
+ "net"
"net/http"
"net/http/cookiejar"
"sync"
+ "time"
"github.com/Azure/go-autorest/tracing"
)
@@ -72,15 +74,18 @@ func sender() Sender {
// note that we can't init defaultSender in init() since it will
// execute before calling code has had a chance to enable tracing
defaultSenderInit.Do(func() {
- // Use behaviour compatible with DefaultTransport, but require TLS minimum version.
- defaultTransport := http.DefaultTransport.(*http.Transport)
+ // copied from http.DefaultTransport with a TLS minimum version.
transport := &http.Transport{
- Proxy: defaultTransport.Proxy,
- DialContext: defaultTransport.DialContext,
- MaxIdleConns: defaultTransport.MaxIdleConns,
- IdleConnTimeout: defaultTransport.IdleConnTimeout,
- TLSHandshakeTimeout: defaultTransport.TLSHandshakeTimeout,
- ExpectContinueTimeout: defaultTransport.ExpectContinueTimeout,
+ Proxy: http.ProxyFromEnvironment,
+ DialContext: (&net.Dialer{
+ Timeout: 30 * time.Second,
+ KeepAlive: 30 * time.Second,
+ }).DialContext,
+ ForceAttemptHTTP2: true,
+ MaxIdleConns: 100,
+ IdleConnTimeout: 90 * time.Second,
+ TLSHandshakeTimeout: 10 * time.Second,
+ ExpectContinueTimeout: 1 * time.Second,
TLSClientConfig: &tls.Config{
MinVersion: tls.VersionTLS12,
},
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/token.go b/vendor/github.com/Azure/go-autorest/autorest/adal/token.go
index c870ef4ec03e..310be07ec335 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/token.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/token.go
@@ -37,7 +37,7 @@ import (
"github.com/Azure/go-autorest/autorest/date"
"github.com/Azure/go-autorest/logger"
- "github.com/form3tech-oss/jwt-go"
+ "github.com/golang-jwt/jwt/v4"
)
const (
@@ -676,8 +676,6 @@ const (
func (m msiType) String() string {
switch m {
- case msiTypeUnavailable:
- return "unavailable"
case msiTypeAppServiceV20170901:
return "AppServiceV20170901"
case msiTypeCloudShell:
@@ -699,13 +697,9 @@ func getMSIType() (msiType, string, error) {
}
// if ONLY the env var MSI_ENDPOINT is set the msiType is CloudShell
return msiTypeCloudShell, endpointEnvVar, nil
- } else if msiAvailableHook(context.Background(), sender()) {
- // if MSI_ENDPOINT is NOT set AND the IMDS endpoint is available the msiType is IMDS. This will timeout after 500 milliseconds
- return msiTypeIMDS, msiEndpoint, nil
- } else {
- // if MSI_ENDPOINT is NOT set and IMDS endpoint is not available Managed Identity is not available
- return msiTypeUnavailable, "", errors.New("MSI not available")
}
+ // if MSI_ENDPOINT is NOT set assume the msiType is IMDS
+ return msiTypeIMDS, msiEndpoint, nil
}
// GetMSIVMEndpoint gets the MSI endpoint on Virtual Machines.
@@ -800,13 +794,13 @@ func newServicePrincipalTokenFromMSI(msiEndpoint, resource, userAssignedID, iden
}
msiType, endpoint, err := getMSIType()
if err != nil {
- logger.Instance.Writef(logger.LogError, "Error determining managed identity environment: %v", err)
+ logger.Instance.Writef(logger.LogError, "Error determining managed identity environment: %v\n", err)
return nil, err
}
- logger.Instance.Writef(logger.LogInfo, "Managed identity environment is %s, endpoint is %s", msiType, endpoint)
+ logger.Instance.Writef(logger.LogInfo, "Managed identity environment is %s, endpoint is %s\n", msiType, endpoint)
if msiEndpoint != "" {
endpoint = msiEndpoint
- logger.Instance.Writef(logger.LogInfo, "Managed identity custom endpoint is %s", endpoint)
+ logger.Instance.Writef(logger.LogInfo, "Managed identity custom endpoint is %s\n", endpoint)
}
msiEndpointURL, err := url.Parse(endpoint)
if err != nil {
@@ -1322,15 +1316,13 @@ func NewMultiTenantServicePrincipalTokenFromCertificate(multiTenantCfg MultiTena
}
// MSIAvailable returns true if the MSI endpoint is available for authentication.
-func MSIAvailable(ctx context.Context, sender Sender) bool {
- resp, err := getMSIEndpoint(ctx, sender)
+func MSIAvailable(ctx context.Context, s Sender) bool {
+ if s == nil {
+ s = sender()
+ }
+ resp, err := getMSIEndpoint(ctx, s)
if err == nil {
resp.Body.Close()
}
return err == nil
}
-
-// used for testing purposes
-var msiAvailableHook = func(ctx context.Context, sender Sender) bool {
- return MSIAvailable(ctx, sender)
-}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/token_1.13.go b/vendor/github.com/Azure/go-autorest/autorest/adal/token_1.13.go
index 953f75502827..89190a4213cf 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/token_1.13.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/token_1.13.go
@@ -1,3 +1,4 @@
+//go:build go1.13
// +build go1.13
// Copyright 2017 Microsoft Corporation
@@ -24,7 +25,7 @@ import (
)
func getMSIEndpoint(ctx context.Context, sender Sender) (*http.Response, error) {
- tempCtx, cancel := context.WithTimeout(ctx, 500*time.Millisecond)
+ tempCtx, cancel := context.WithTimeout(ctx, 2*time.Second)
defer cancel()
// http.NewRequestWithContext() was added in Go 1.13
req, _ := http.NewRequestWithContext(tempCtx, http.MethodGet, msiEndpoint, nil)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/token_legacy.go b/vendor/github.com/Azure/go-autorest/autorest/adal/token_legacy.go
index 729bfbd0abf0..27ec4efad7c4 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/token_legacy.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/token_legacy.go
@@ -1,3 +1,4 @@
+//go:build !go1.13
// +build !go1.13
// Copyright 2017 Microsoft Corporation
@@ -23,7 +24,7 @@ import (
)
func getMSIEndpoint(ctx context.Context, sender Sender) (*http.Response, error) {
- tempCtx, cancel := context.WithTimeout(ctx, 500*time.Millisecond)
+ tempCtx, cancel := context.WithTimeout(ctx, 2*time.Second)
defer cancel()
req, _ := http.NewRequest(http.MethodGet, msiEndpoint, nil)
req = req.WithContext(tempCtx)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/async.go b/vendor/github.com/Azure/go-autorest/autorest/azure/async.go
index 42e28cf2e4d3..45575eedbfeb 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/async.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/async.go
@@ -26,6 +26,7 @@ import (
"time"
"github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/logger"
"github.com/Azure/go-autorest/tracing"
)
@@ -215,6 +216,7 @@ func (f *Future) WaitForCompletionRef(ctx context.Context, client autorest.Clien
}
// if the initial response has a Retry-After, sleep for the specified amount of time before starting to poll
if delay, ok := f.GetPollingDelay(); ok {
+ logger.Instance.Writeln(logger.LogInfo, "WaitForCompletionRef: initial polling delay")
if delayElapsed := autorest.DelayForBackoff(delay, 0, cancelCtx.Done()); !delayElapsed {
err = cancelCtx.Err()
return
@@ -234,12 +236,14 @@ func (f *Future) WaitForCompletionRef(ctx context.Context, client autorest.Clien
var ok bool
delay, ok = f.GetPollingDelay()
if !ok {
+ logger.Instance.Writeln(logger.LogInfo, "WaitForCompletionRef: Using client polling delay")
delay = client.PollingDelay
}
} else {
// there was an error polling for status so perform exponential
// back-off based on the number of attempts using the client's retry
// duration. update attempts after delayAttempt to avoid off-by-one.
+ logger.Instance.Writef(logger.LogError, "WaitForCompletionRef: %s\n", err)
delayAttempt = attempts
delay = client.RetryDuration
attempts++
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go
index 596b9f5777db..2f1a99818d10 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go
@@ -16,6 +16,7 @@ package auth
import (
"bytes"
+ "context"
"encoding/binary"
"encoding/json"
"errors"
@@ -30,6 +31,7 @@ import (
"github.com/Azure/go-autorest/autorest/adal"
"github.com/Azure/go-autorest/autorest/azure"
"github.com/Azure/go-autorest/autorest/azure/cli"
+ "github.com/Azure/go-autorest/logger"
"github.com/dimchansky/utfbom"
)
@@ -60,6 +62,7 @@ const (
// 3. Username password
// 4. MSI
func NewAuthorizerFromEnvironment() (autorest.Authorizer, error) {
+ logger.Instance.Writeln(logger.LogInfo, "NewAuthorizerFromEnvironment() determining authentication mechanism")
settings, err := GetSettingsFromEnvironment()
if err != nil {
return nil, err
@@ -73,6 +76,7 @@ func NewAuthorizerFromEnvironment() (autorest.Authorizer, error) {
// 3. Username password
// 4. MSI
func NewAuthorizerFromEnvironmentWithResource(resource string) (autorest.Authorizer, error) {
+ logger.Instance.Writeln(logger.LogInfo, "NewAuthorizerFromEnvironmentWithResource() determining authentication mechanism")
settings, err := GetSettingsFromEnvironment()
if err != nil {
return nil, err
@@ -122,6 +126,7 @@ func (settings EnvironmentSettings) GetSubscriptionID() string {
// adds the specified environment variable value to the Values map if it exists
func (settings EnvironmentSettings) setValue(key string) {
if v := os.Getenv(key); v != "" {
+ logger.Instance.Writef(logger.LogInfo, "GetSettingsFromEnvironment() found environment var %s\n", key)
settings.Values[key] = v
}
}
@@ -138,6 +143,7 @@ func (settings EnvironmentSettings) getClientAndTenant() (string, string) {
func (settings EnvironmentSettings) GetClientCredentials() (ClientCredentialsConfig, error) {
secret := settings.Values[ClientSecret]
if secret == "" {
+ logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetClientCredentials() missing client secret")
return ClientCredentialsConfig{}, errors.New("missing client secret")
}
clientID, tenantID := settings.getClientAndTenant()
@@ -158,6 +164,7 @@ func (settings EnvironmentSettings) GetClientCredentials() (ClientCredentialsCon
func (settings EnvironmentSettings) GetClientCertificate() (ClientCertificateConfig, error) {
certPath := settings.Values[CertificatePath]
if certPath == "" {
+ logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetClientCertificate() missing certificate path")
return ClientCertificateConfig{}, errors.New("missing certificate path")
}
certPwd := settings.Values[CertificatePassword]
@@ -174,6 +181,7 @@ func (settings EnvironmentSettings) GetUsernamePassword() (UsernamePasswordConfi
username := settings.Values[Username]
password := settings.Values[Password]
if username == "" || password == "" {
+ logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetUsernamePassword() missing username and/or password")
return UsernamePasswordConfig{}, errors.New("missing username/password")
}
clientID, tenantID := settings.getClientAndTenant()
@@ -208,35 +216,44 @@ func (settings EnvironmentSettings) GetDeviceFlow() DeviceFlowConfig {
func (settings EnvironmentSettings) GetAuthorizer() (autorest.Authorizer, error) {
//1.Client Credentials
if c, e := settings.GetClientCredentials(); e == nil {
+ logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetAuthorizer() using client secret credentials")
return c.Authorizer()
}
//2. Client Certificate
if c, e := settings.GetClientCertificate(); e == nil {
+ logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetAuthorizer() using client certificate credentials")
return c.Authorizer()
}
//3. Username Password
if c, e := settings.GetUsernamePassword(); e == nil {
+ logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetAuthorizer() using user name/password credentials")
return c.Authorizer()
}
// 4. MSI
+ if !adal.MSIAvailable(context.Background(), nil) {
+ return nil, errors.New("MSI not available")
+ }
+ logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetAuthorizer() using MSI authentication")
return settings.GetMSI().Authorizer()
}
// NewAuthorizerFromFile creates an Authorizer configured from a configuration file in the following order.
// 1. Client credentials
// 2. Client certificate
-func NewAuthorizerFromFile(baseURI string) (autorest.Authorizer, error) {
+// The path to the configuration file must be specified in the AZURE_AUTH_LOCATION environment variable.
+// resourceBaseURI - used to determine the resource type
+func NewAuthorizerFromFile(resourceBaseURI string) (autorest.Authorizer, error) {
settings, err := GetSettingsFromFile()
if err != nil {
return nil, err
}
- if a, err := settings.ClientCredentialsAuthorizer(baseURI); err == nil {
+ if a, err := settings.ClientCredentialsAuthorizer(resourceBaseURI); err == nil {
return a, err
}
- if a, err := settings.ClientCertificateAuthorizer(baseURI); err == nil {
+ if a, err := settings.ClientCertificateAuthorizer(resourceBaseURI); err == nil {
return a, err
}
return nil, errors.New("auth file missing client and certificate credentials")
@@ -245,6 +262,7 @@ func NewAuthorizerFromFile(baseURI string) (autorest.Authorizer, error) {
// NewAuthorizerFromFileWithResource creates an Authorizer configured from a configuration file in the following order.
// 1. Client credentials
// 2. Client certificate
+// The path to the configuration file must be specified in the AZURE_AUTH_LOCATION environment variable.
func NewAuthorizerFromFileWithResource(resource string) (autorest.Authorizer, error) {
s, err := GetSettingsFromFile()
if err != nil {
@@ -596,6 +614,7 @@ type ClientCertificateConfig struct {
CertificatePath string
CertificatePassword string
TenantID string
+ AuxTenants []string
AADEndpoint string
Resource string
}
@@ -617,13 +636,37 @@ func (ccc ClientCertificateConfig) ServicePrincipalToken() (*adal.ServicePrincip
return adal.NewServicePrincipalTokenFromCertificate(*oauthConfig, ccc.ClientID, certificate, rsaPrivateKey, ccc.Resource)
}
+// MultiTenantServicePrincipalToken creates a MultiTenantServicePrincipalToken from client certificate.
+func (ccc ClientCertificateConfig) MultiTenantServicePrincipalToken() (*adal.MultiTenantServicePrincipalToken, error) {
+ oauthConfig, err := adal.NewMultiTenantOAuthConfig(ccc.AADEndpoint, ccc.TenantID, ccc.AuxTenants, adal.OAuthOptions{})
+ if err != nil {
+ return nil, err
+ }
+ certData, err := ioutil.ReadFile(ccc.CertificatePath)
+ if err != nil {
+ return nil, fmt.Errorf("failed to read the certificate file (%s): %v", ccc.CertificatePath, err)
+ }
+ certificate, rsaPrivateKey, err := adal.DecodePfxCertificateData(certData, ccc.CertificatePassword)
+ if err != nil {
+ return nil, fmt.Errorf("failed to decode pkcs12 certificate while creating spt: %v", err)
+ }
+ return adal.NewMultiTenantServicePrincipalTokenFromCertificate(oauthConfig, ccc.ClientID, certificate, rsaPrivateKey, ccc.Resource)
+}
+
// Authorizer gets an authorizer object from client certificate.
func (ccc ClientCertificateConfig) Authorizer() (autorest.Authorizer, error) {
- spToken, err := ccc.ServicePrincipalToken()
+ if len(ccc.AuxTenants) == 0 {
+ spToken, err := ccc.ServicePrincipalToken()
+ if err != nil {
+ return nil, fmt.Errorf("failed to get oauth token from certificate auth: %v", err)
+ }
+ return autorest.NewBearerAuthorizer(spToken), nil
+ }
+ mtSPT, err := ccc.MultiTenantServicePrincipalToken()
if err != nil {
- return nil, fmt.Errorf("failed to get oauth token from certificate auth: %v", err)
+ return nil, fmt.Errorf("failed to get multitenant SPT from certificate auth: %v", err)
}
- return autorest.NewBearerAuthorizer(spToken), nil
+ return autorest.NewMultiTenantServicePrincipalTokenAuthorizer(mtSPT), nil
}
// DeviceFlowConfig provides the options to get a bearer authorizer using device flow authentication.
@@ -698,24 +741,12 @@ type MSIConfig struct {
// ServicePrincipalToken creates a ServicePrincipalToken from MSI.
func (mc MSIConfig) ServicePrincipalToken() (*adal.ServicePrincipalToken, error) {
- msiEndpoint, err := adal.GetMSIEndpoint()
+ spToken, err := adal.NewServicePrincipalTokenFromManagedIdentity(mc.Resource, &adal.ManagedIdentityOptions{
+ ClientID: mc.ClientID,
+ })
if err != nil {
- return nil, err
+ return nil, fmt.Errorf("failed to get oauth token from MSI: %v", err)
}
-
- var spToken *adal.ServicePrincipalToken
- if mc.ClientID == "" {
- spToken, err = adal.NewServicePrincipalTokenFromMSI(msiEndpoint, mc.Resource)
- if err != nil {
- return nil, fmt.Errorf("failed to get oauth token from MSI: %v", err)
- }
- } else {
- spToken, err = adal.NewServicePrincipalTokenFromMSIWithUserAssignedID(msiEndpoint, mc.Resource, mc.ClientID)
- if err != nil {
- return nil, fmt.Errorf("failed to get oauth token from MSI for user assigned identity: %v", err)
- }
- }
-
return spToken, nil
}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod
index c811a0635f99..cc3d3577077d 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod
@@ -1,11 +1,12 @@
module github.com/Azure/go-autorest/autorest/azure/auth
-go 1.12
+go 1.15
require (
github.com/Azure/go-autorest v14.2.0+incompatible
- github.com/Azure/go-autorest/autorest v0.11.6
- github.com/Azure/go-autorest/autorest/adal v0.9.4
- github.com/Azure/go-autorest/autorest/azure/cli v0.4.1
- github.com/dimchansky/utfbom v1.1.0
+ github.com/Azure/go-autorest/autorest v0.11.24
+ github.com/Azure/go-autorest/autorest/adal v0.9.18
+ github.com/Azure/go-autorest/autorest/azure/cli v0.4.5
+ github.com/Azure/go-autorest/logger v0.2.1
+ github.com/dimchansky/utfbom v1.1.1
)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum
index 180b5390a19e..b43ae3207b42 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum
@@ -1,29 +1,35 @@
github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
-github.com/Azure/go-autorest/autorest v0.11.6 h1:LIzfhNo9I3+il0KO2JY1/lgJmjig7lY0wFulQNZkbtg=
-github.com/Azure/go-autorest/autorest v0.11.6/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
-github.com/Azure/go-autorest/autorest/adal v0.9.4 h1:1/DtH4Szusk4psLBrJn/gocMRIf1ji30WAz3GfyULRQ=
-github.com/Azure/go-autorest/autorest/adal v0.9.4/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
-github.com/Azure/go-autorest/autorest/azure/cli v0.4.1 h1:jwcD1wURu0+hKceV04MubZmKLzwEYOCz6q4aOtVZ+Ng=
-github.com/Azure/go-autorest/autorest/azure/cli v0.4.1/go.mod h1:JfDgiIO1/RPu6z42AdQTyjOoCM2MFhLqSBDvMEkDgcg=
+github.com/Azure/go-autorest/autorest v0.11.24 h1:1fIGgHKqVm54KIPT+q8Zmd1QlVsmHqeUGso5qm2BqqE=
+github.com/Azure/go-autorest/autorest v0.11.24/go.mod h1:G6kyRlFnTuSbEYkQGawPfsCswgme4iYf6rfSKUDzbCc=
+github.com/Azure/go-autorest/autorest/adal v0.9.18 h1:kLnPsRjzZZUF3K5REu/Kc+qMQrvuza2bwSnNdhmzLfQ=
+github.com/Azure/go-autorest/autorest/adal v0.9.18/go.mod h1:XVVeme+LZwABT8K5Lc3hA4nAe8LDBVle26gTrguhhPQ=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.5 h1:0W/yGmFdTIT77fvdlGZ0LMISoLHFJ7Tx4U0yeB+uFs4=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.5/go.mod h1:ADQAXrkgm7acgWVUNamOgh8YNrv4p27l3Wc55oVfpzg=
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
-github.com/Azure/go-autorest/logger v0.2.0 h1:e4RVHVZKC5p6UANLJHkM4OfR1UKZPj8Wt8Pcx+3oqrE=
-github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
+github.com/Azure/go-autorest/logger v0.2.1 h1:IG7i4p/mDa2Ce4TRyAO8IHnVhAVF3RFU+ZtXWSmf4Tg=
+github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
-github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM=
-github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
-github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
-github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
+github.com/dimchansky/utfbom v1.1.1 h1:vV6w1AhK4VMnhBno/TPVCoK9U/LP0PkLCS9tbxHdi/U=
+github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE=
+github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
+github.com/golang-jwt/jwt/v4 v4.2.0 h1:besgBTC8w8HjP6NzQdxwKH9Z5oQMZ24ThTrHp3cZ8eU=
+github.com/golang-jwt/jwt/v4 v4.2.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
-golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
-golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 h1:psW17arqaxU48Z5kZ0CQnkZWQJsqcURM6tKiBApRjXI=
-golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
-golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
+golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3 h1:0es+/5331RGQPcXlMfP+WrnIIS6dNnNRe0WB02W0F4M=
+golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
+golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
+golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
+golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go_mod_tidy_hack.go b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go_mod_tidy_hack.go
index 38e4900ad0fb..f7eb26fd366b 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go_mod_tidy_hack.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/auth/go_mod_tidy_hack.go
@@ -1,3 +1,4 @@
+//go:build modhack
// +build modhack
package auth
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/azure.go b/vendor/github.com/Azure/go-autorest/autorest/azure/azure.go
index 0ded76bc6f1d..1328f1764c23 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/azure.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/azure.go
@@ -68,7 +68,7 @@ func (se ServiceError) Error() string {
if err != nil {
result += fmt.Sprintf(" Details=%v", se.Details)
}
- result += fmt.Sprintf(" Details=%v", string(d))
+ result += fmt.Sprintf(" Details=%s", d)
}
if se.InnerError != nil {
@@ -76,7 +76,7 @@ func (se ServiceError) Error() string {
if err != nil {
result += fmt.Sprintf(" InnerError=%v", se.InnerError)
}
- result += fmt.Sprintf(" InnerError=%v", string(d))
+ result += fmt.Sprintf(" InnerError=%s", d)
}
if se.AdditionalInfo != nil {
@@ -84,7 +84,7 @@ func (se ServiceError) Error() string {
if err != nil {
result += fmt.Sprintf(" AdditionalInfo=%v", se.AdditionalInfo)
}
- result += fmt.Sprintf(" AdditionalInfo=%v", string(d))
+ result += fmt.Sprintf(" AdditionalInfo=%s", d)
}
return result
@@ -211,7 +211,7 @@ func (r Resource) String() string {
}
// ParseResourceID parses a resource ID into a ResourceDetails struct.
-// See https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-group-template-functions-resource#return-value-4.
+// See https://docs.microsoft.com/en-us/azure/azure-resource-manager/templates/template-functions-resource?tabs=json#resourceid.
func ParseResourceID(resourceID string) (Resource, error) {
const resourceIDPatternText = `(?i)subscriptions/(.+)/resourceGroups/(.+)/providers/(.+?)/(.+?)/(.+)`
@@ -335,13 +335,13 @@ func WithErrorUnlessStatusCode(codes ...int) autorest.RespondDecorator {
b, decodeErr := autorest.CopyAndDecode(encodedAs, resp.Body, &e)
resp.Body = ioutil.NopCloser(&b)
if decodeErr != nil {
- return fmt.Errorf("autorest/azure: error response cannot be parsed: %q error: %v", b.String(), decodeErr)
+ return fmt.Errorf("autorest/azure: error response cannot be parsed: %q error: %v", b, decodeErr)
}
if e.ServiceError == nil {
// Check if error is unwrapped ServiceError
decoder := autorest.NewDecoder(encodedAs, bytes.NewReader(b.Bytes()))
if err := decoder.Decode(&e.ServiceError); err != nil {
- return fmt.Errorf("autorest/azure: error response cannot be parsed: %q error: %v", b.String(), err)
+ return fmt.Errorf("autorest/azure: error response cannot be parsed: %q error: %v", b, err)
}
// for example, should the API return the literal value `null` as the response
@@ -364,7 +364,7 @@ func WithErrorUnlessStatusCode(codes ...int) autorest.RespondDecorator {
rawBody := map[string]interface{}{}
decoder := autorest.NewDecoder(encodedAs, bytes.NewReader(b.Bytes()))
if err := decoder.Decode(&rawBody); err != nil {
- return fmt.Errorf("autorest/azure: error response cannot be parsed: %q error: %v", b.String(), err)
+ return fmt.Errorf("autorest/azure: error response cannot be parsed: %q error: %v", b, err)
}
e.ServiceError = &ServiceError{
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod
index 28086dc59b21..ae72c2d99a55 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod
@@ -1,11 +1,13 @@
module github.com/Azure/go-autorest/autorest/azure/cli
-go 1.12
+go 1.15
require (
github.com/Azure/go-autorest v14.2.0+incompatible
- github.com/Azure/go-autorest/autorest/adal v0.9.4
+ github.com/Azure/go-autorest/autorest/adal v0.9.18
github.com/Azure/go-autorest/autorest/date v0.3.0
- github.com/dimchansky/utfbom v1.1.0
+ github.com/dimchansky/utfbom v1.1.1
+ github.com/golang-jwt/jwt/v4 v4.2.0 // indirect
github.com/mitchellh/go-homedir v1.1.0
+ golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3 // indirect
)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum
index 10a46ee677d9..7bb519aeaf16 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum
@@ -1,24 +1,31 @@
github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
-github.com/Azure/go-autorest/autorest/adal v0.9.4 h1:1/DtH4Szusk4psLBrJn/gocMRIf1ji30WAz3GfyULRQ=
-github.com/Azure/go-autorest/autorest/adal v0.9.4/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
+github.com/Azure/go-autorest/autorest/adal v0.9.18 h1:kLnPsRjzZZUF3K5REu/Kc+qMQrvuza2bwSnNdhmzLfQ=
+github.com/Azure/go-autorest/autorest/adal v0.9.18/go.mod h1:XVVeme+LZwABT8K5Lc3hA4nAe8LDBVle26gTrguhhPQ=
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
+github.com/Azure/go-autorest/logger v0.2.1 h1:IG7i4p/mDa2Ce4TRyAO8IHnVhAVF3RFU+ZtXWSmf4Tg=
+github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
-github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM=
-github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
-github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
-github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
+github.com/dimchansky/utfbom v1.1.1 h1:vV6w1AhK4VMnhBno/TPVCoK9U/LP0PkLCS9tbxHdi/U=
+github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE=
+github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
+github.com/golang-jwt/jwt/v4 v4.2.0 h1:besgBTC8w8HjP6NzQdxwKH9Z5oQMZ24ThTrHp3cZ8eU=
+github.com/golang-jwt/jwt/v4 v4.2.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
-golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
-golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 h1:psW17arqaxU48Z5kZ0CQnkZWQJsqcURM6tKiBApRjXI=
-golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
-golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
+golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3 h1:0es+/5331RGQPcXlMfP+WrnIIS6dNnNRe0WB02W0F4M=
+golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
+golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
+golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
+golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go_mod_tidy_hack.go b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go_mod_tidy_hack.go
index 861ce2984e64..50d6f0391a5e 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go_mod_tidy_hack.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/go_mod_tidy_hack.go
@@ -1,3 +1,4 @@
+//go:build modhack
// +build modhack
package cli
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/token.go b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/token.go
index 44ff446f6697..486619111c67 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/cli/token.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/cli/token.go
@@ -124,24 +124,91 @@ func LoadTokens(path string) ([]Token, error) {
// GetTokenFromCLI gets a token using Azure CLI 2.0 for local development scenarios.
func GetTokenFromCLI(resource string) (*Token, error) {
- // This is the path that a developer can set to tell this class what the install path for Azure CLI is.
- const azureCLIPath = "AzureCLIPath"
+ return GetTokenFromCLIWithParams(GetAccessTokenParams{Resource: resource})
+}
- // The default install paths are used to find Azure CLI. This is for security, so that any path in the calling program's Path environment is not used to execute Azure CLI.
- azureCLIDefaultPathWindows := fmt.Sprintf("%s\\Microsoft SDKs\\Azure\\CLI2\\wbin; %s\\Microsoft SDKs\\Azure\\CLI2\\wbin", os.Getenv("ProgramFiles(x86)"), os.Getenv("ProgramFiles"))
+// GetAccessTokenParams is the parameter struct of GetTokenFromCLIWithParams
+type GetAccessTokenParams struct {
+ Resource string
+ ResourceType string
+ Subscription string
+ Tenant string
+}
- // Default path for non-Windows.
- const azureCLIDefaultPath = "/bin:/sbin:/usr/bin:/usr/local/bin"
+// GetTokenFromCLIWithParams gets a token using Azure CLI 2.0 for local development scenarios.
+func GetTokenFromCLIWithParams(params GetAccessTokenParams) (*Token, error) {
+ cliCmd := GetAzureCLICommand()
- // Validate resource, since it gets sent as a command line argument to Azure CLI
- const invalidResourceErrorTemplate = "Resource %s is not in expected format. Only alphanumeric characters, [dot], [colon], [hyphen], and [forward slash] are allowed."
- match, err := regexp.MatchString("^[0-9a-zA-Z-.:/]+$", resource)
+ cliCmd.Args = append(cliCmd.Args, "account", "get-access-token", "-o", "json")
+ if params.Resource != "" {
+ if err := validateParameter(params.Resource); err != nil {
+ return nil, err
+ }
+ cliCmd.Args = append(cliCmd.Args, "--resource", params.Resource)
+ }
+ if params.ResourceType != "" {
+ if err := validateParameter(params.ResourceType); err != nil {
+ return nil, err
+ }
+ cliCmd.Args = append(cliCmd.Args, "--resource-type", params.ResourceType)
+ }
+ if params.Subscription != "" {
+ if err := validateParameter(params.Subscription); err != nil {
+ return nil, err
+ }
+ cliCmd.Args = append(cliCmd.Args, "--subscription", params.Subscription)
+ }
+ if params.Tenant != "" {
+ if err := validateParameter(params.Tenant); err != nil {
+ return nil, err
+ }
+ cliCmd.Args = append(cliCmd.Args, "--tenant", params.Tenant)
+ }
+
+ var stderr bytes.Buffer
+ cliCmd.Stderr = &stderr
+
+ output, err := cliCmd.Output()
+ if err != nil {
+ if stderr.Len() > 0 {
+ return nil, fmt.Errorf("Invoking Azure CLI failed with the following error: %s", stderr.String())
+ }
+
+ return nil, fmt.Errorf("Invoking Azure CLI failed with the following error: %s", err.Error())
+ }
+
+ tokenResponse := Token{}
+ err = json.Unmarshal(output, &tokenResponse)
if err != nil {
return nil, err
}
+
+ return &tokenResponse, err
+}
+
+func validateParameter(param string) error {
+ // Validate parameters, since it gets sent as a command line argument to Azure CLI
+ const invalidResourceErrorTemplate = "Parameter %s is not in expected format. Only alphanumeric characters, [dot], [colon], [hyphen], and [forward slash] are allowed."
+ match, err := regexp.MatchString("^[0-9a-zA-Z-.:/]+$", param)
+ if err != nil {
+ return err
+ }
if !match {
- return nil, fmt.Errorf(invalidResourceErrorTemplate, resource)
+ return fmt.Errorf(invalidResourceErrorTemplate, param)
}
+ return nil
+}
+
+// GetAzureCLICommand can be used to run arbitrary Azure CLI command
+func GetAzureCLICommand() *exec.Cmd {
+ // This is the path that a developer can set to tell this class what the install path for Azure CLI is.
+ const azureCLIPath = "AzureCLIPath"
+
+ // The default install paths are used to find Azure CLI. This is for security, so that any path in the calling program's Path environment is not used to execute Azure CLI.
+ azureCLIDefaultPathWindows := fmt.Sprintf("%s\\Microsoft SDKs\\Azure\\CLI2\\wbin; %s\\Microsoft SDKs\\Azure\\CLI2\\wbin", os.Getenv("ProgramFiles(x86)"), os.Getenv("ProgramFiles"))
+
+ // Default path for non-Windows.
+ const azureCLIDefaultPath = "/bin:/sbin:/usr/bin:/usr/local/bin"
// Execute Azure CLI to get token
var cliCmd *exec.Cmd
@@ -155,21 +222,6 @@ func GetTokenFromCLI(resource string) (*Token, error) {
cliCmd.Env = os.Environ()
cliCmd.Env = append(cliCmd.Env, fmt.Sprintf("PATH=%s:%s", os.Getenv(azureCLIPath), azureCLIDefaultPath))
}
- cliCmd.Args = append(cliCmd.Args, "account", "get-access-token", "-o", "json", "--resource", resource)
- var stderr bytes.Buffer
- cliCmd.Stderr = &stderr
-
- output, err := cliCmd.Output()
- if err != nil {
- return nil, fmt.Errorf("Invoking Azure CLI failed with the following error: %s", stderr.String())
- }
-
- tokenResponse := Token{}
- err = json.Unmarshal(output, &tokenResponse)
- if err != nil {
- return nil, err
- }
-
- return &tokenResponse, err
+ return cliCmd
}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/azure/environments.go b/vendor/github.com/Azure/go-autorest/autorest/azure/environments.go
index 9bbc0899e4ce..737950eb36b0 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/azure/environments.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/azure/environments.go
@@ -45,9 +45,12 @@ type ResourceIdentifier struct {
Datalake string `json:"datalake"`
Batch string `json:"batch"`
OperationalInsights string `json:"operationalInsights"`
+ OSSRDBMS string `json:"ossRDBMS"`
Storage string `json:"storage"`
Synapse string `json:"synapse"`
ServiceBus string `json:"serviceBus"`
+ SQLDatabase string `json:"sqlDatabase"`
+ CosmosDB string `json:"cosmosDB"`
}
// Environment represents a set of endpoints for each of Azure's Clouds.
@@ -64,6 +67,10 @@ type Environment struct {
ServiceBusEndpoint string `json:"serviceBusEndpoint"`
BatchManagementEndpoint string `json:"batchManagementEndpoint"`
StorageEndpointSuffix string `json:"storageEndpointSuffix"`
+ CosmosDBDNSSuffix string `json:"cosmosDBDNSSuffix"`
+ MariaDBDNSSuffix string `json:"mariaDBDNSSuffix"`
+ MySQLDatabaseDNSSuffix string `json:"mySqlDatabaseDNSSuffix"`
+ PostgresqlDatabaseDNSSuffix string `json:"postgresqlDatabaseDNSSuffix"`
SQLDatabaseDNSSuffix string `json:"sqlDatabaseDNSSuffix"`
TrafficManagerDNSSuffix string `json:"trafficManagerDNSSuffix"`
KeyVaultDNSSuffix string `json:"keyVaultDNSSuffix"`
@@ -71,7 +78,6 @@ type Environment struct {
ServiceManagementVMDNSSuffix string `json:"serviceManagementVMDNSSuffix"`
ResourceManagerVMDNSSuffix string `json:"resourceManagerVMDNSSuffix"`
ContainerRegistryDNSSuffix string `json:"containerRegistryDNSSuffix"`
- CosmosDBDNSSuffix string `json:"cosmosDBDNSSuffix"`
TokenAudience string `json:"tokenAudience"`
APIManagementHostNameSuffix string `json:"apiManagementHostNameSuffix"`
SynapseEndpointSuffix string `json:"synapseEndpointSuffix"`
@@ -93,6 +99,10 @@ var (
ServiceBusEndpoint: "https://servicebus.windows.net/",
BatchManagementEndpoint: "https://batch.core.windows.net/",
StorageEndpointSuffix: "core.windows.net",
+ CosmosDBDNSSuffix: "documents.azure.com",
+ MariaDBDNSSuffix: "mariadb.database.azure.com",
+ MySQLDatabaseDNSSuffix: "mysql.database.azure.com",
+ PostgresqlDatabaseDNSSuffix: "postgres.database.azure.com",
SQLDatabaseDNSSuffix: "database.windows.net",
TrafficManagerDNSSuffix: "trafficmanager.net",
KeyVaultDNSSuffix: "vault.azure.net",
@@ -100,7 +110,6 @@ var (
ServiceManagementVMDNSSuffix: "cloudapp.net",
ResourceManagerVMDNSSuffix: "cloudapp.azure.com",
ContainerRegistryDNSSuffix: "azurecr.io",
- CosmosDBDNSSuffix: "documents.azure.com",
TokenAudience: "https://management.azure.com/",
APIManagementHostNameSuffix: "azure-api.net",
SynapseEndpointSuffix: "dev.azuresynapse.net",
@@ -110,9 +119,12 @@ var (
Datalake: "https://datalake.azure.net/",
Batch: "https://batch.core.windows.net/",
OperationalInsights: "https://api.loganalytics.io",
+ OSSRDBMS: "https://ossrdbms-aad.database.windows.net",
Storage: "https://storage.azure.com/",
Synapse: "https://dev.azuresynapse.net",
ServiceBus: "https://servicebus.azure.net/",
+ SQLDatabase: "https://database.windows.net/",
+ CosmosDB: "https://cosmos.azure.com",
},
}
@@ -130,6 +142,10 @@ var (
ServiceBusEndpoint: "https://servicebus.usgovcloudapi.net/",
BatchManagementEndpoint: "https://batch.core.usgovcloudapi.net/",
StorageEndpointSuffix: "core.usgovcloudapi.net",
+ CosmosDBDNSSuffix: "documents.azure.us",
+ MariaDBDNSSuffix: "mariadb.database.usgovcloudapi.net",
+ MySQLDatabaseDNSSuffix: "mysql.database.usgovcloudapi.net",
+ PostgresqlDatabaseDNSSuffix: "postgres.database.usgovcloudapi.net",
SQLDatabaseDNSSuffix: "database.usgovcloudapi.net",
TrafficManagerDNSSuffix: "usgovtrafficmanager.net",
KeyVaultDNSSuffix: "vault.usgovcloudapi.net",
@@ -137,7 +153,6 @@ var (
ServiceManagementVMDNSSuffix: "usgovcloudapp.net",
ResourceManagerVMDNSSuffix: "cloudapp.usgovcloudapi.net",
ContainerRegistryDNSSuffix: "azurecr.us",
- CosmosDBDNSSuffix: "documents.azure.us",
TokenAudience: "https://management.usgovcloudapi.net/",
APIManagementHostNameSuffix: "azure-api.us",
SynapseEndpointSuffix: NotAvailable,
@@ -147,9 +162,12 @@ var (
Datalake: NotAvailable,
Batch: "https://batch.core.usgovcloudapi.net/",
OperationalInsights: "https://api.loganalytics.us",
+ OSSRDBMS: "https://ossrdbms-aad.database.usgovcloudapi.net",
Storage: "https://storage.azure.com/",
Synapse: NotAvailable,
ServiceBus: "https://servicebus.azure.net/",
+ SQLDatabase: "https://database.usgovcloudapi.net/",
+ CosmosDB: "https://cosmos.azure.com",
},
}
@@ -167,6 +185,10 @@ var (
ServiceBusEndpoint: "https://servicebus.chinacloudapi.cn/",
BatchManagementEndpoint: "https://batch.chinacloudapi.cn/",
StorageEndpointSuffix: "core.chinacloudapi.cn",
+ CosmosDBDNSSuffix: "documents.azure.cn",
+ MariaDBDNSSuffix: "mariadb.database.chinacloudapi.cn",
+ MySQLDatabaseDNSSuffix: "mysql.database.chinacloudapi.cn",
+ PostgresqlDatabaseDNSSuffix: "postgres.database.chinacloudapi.cn",
SQLDatabaseDNSSuffix: "database.chinacloudapi.cn",
TrafficManagerDNSSuffix: "trafficmanager.cn",
KeyVaultDNSSuffix: "vault.azure.cn",
@@ -174,7 +196,6 @@ var (
ServiceManagementVMDNSSuffix: "chinacloudapp.cn",
ResourceManagerVMDNSSuffix: "cloudapp.chinacloudapi.cn",
ContainerRegistryDNSSuffix: "azurecr.cn",
- CosmosDBDNSSuffix: "documents.azure.cn",
TokenAudience: "https://management.chinacloudapi.cn/",
APIManagementHostNameSuffix: "azure-api.cn",
SynapseEndpointSuffix: "dev.azuresynapse.azure.cn",
@@ -184,9 +205,12 @@ var (
Datalake: NotAvailable,
Batch: "https://batch.chinacloudapi.cn/",
OperationalInsights: NotAvailable,
+ OSSRDBMS: "https://ossrdbms-aad.database.chinacloudapi.cn",
Storage: "https://storage.azure.com/",
Synapse: "https://dev.azuresynapse.net",
ServiceBus: "https://servicebus.azure.net/",
+ SQLDatabase: "https://database.chinacloudapi.cn/",
+ CosmosDB: "https://cosmos.azure.com",
},
}
@@ -204,6 +228,10 @@ var (
ServiceBusEndpoint: "https://servicebus.cloudapi.de/",
BatchManagementEndpoint: "https://batch.cloudapi.de/",
StorageEndpointSuffix: "core.cloudapi.de",
+ CosmosDBDNSSuffix: "documents.microsoftazure.de",
+ MariaDBDNSSuffix: "mariadb.database.cloudapi.de",
+ MySQLDatabaseDNSSuffix: "mysql.database.cloudapi.de",
+ PostgresqlDatabaseDNSSuffix: "postgres.database.cloudapi.de",
SQLDatabaseDNSSuffix: "database.cloudapi.de",
TrafficManagerDNSSuffix: "azuretrafficmanager.de",
KeyVaultDNSSuffix: "vault.microsoftazure.de",
@@ -211,7 +239,6 @@ var (
ServiceManagementVMDNSSuffix: "azurecloudapp.de",
ResourceManagerVMDNSSuffix: "cloudapp.microsoftazure.de",
ContainerRegistryDNSSuffix: NotAvailable,
- CosmosDBDNSSuffix: "documents.microsoftazure.de",
TokenAudience: "https://management.microsoftazure.de/",
APIManagementHostNameSuffix: NotAvailable,
SynapseEndpointSuffix: NotAvailable,
@@ -221,9 +248,12 @@ var (
Datalake: NotAvailable,
Batch: "https://batch.cloudapi.de/",
OperationalInsights: NotAvailable,
+ OSSRDBMS: "https://ossrdbms-aad.database.cloudapi.de",
Storage: "https://storage.azure.com/",
Synapse: NotAvailable,
ServiceBus: "https://servicebus.azure.net/",
+ SQLDatabase: "https://database.cloudapi.de/",
+ CosmosDB: "https://cosmos.azure.com",
},
}
)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/client.go b/vendor/github.com/Azure/go-autorest/autorest/client.go
index 0b7525f0f4ca..bb5f9396e9a3 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/client.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/client.go
@@ -31,7 +31,7 @@ import (
const (
// DefaultPollingDelay is a reasonable delay between polling requests.
- DefaultPollingDelay = 60 * time.Second
+ DefaultPollingDelay = 30 * time.Second
// DefaultPollingDuration is a reasonable total polling duration.
DefaultPollingDuration = 15 * time.Minute
diff --git a/vendor/github.com/Azure/go-autorest/autorest/go.mod b/vendor/github.com/Azure/go-autorest/autorest/go.mod
index fd0b2c0c3279..5c2ef4b8b741 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/go.mod
+++ b/vendor/github.com/Azure/go-autorest/autorest/go.mod
@@ -1,12 +1,13 @@
module github.com/Azure/go-autorest/autorest
-go 1.12
+go 1.15
require (
github.com/Azure/go-autorest v14.2.0+incompatible
- github.com/Azure/go-autorest/autorest/adal v0.9.13
+ github.com/Azure/go-autorest/autorest/adal v0.9.18
github.com/Azure/go-autorest/autorest/mocks v0.4.1
github.com/Azure/go-autorest/logger v0.2.1
github.com/Azure/go-autorest/tracing v0.6.0
- golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0
+ github.com/golang-jwt/jwt/v4 v4.2.0 // indirect
+ golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3
)
diff --git a/vendor/github.com/Azure/go-autorest/autorest/go.sum b/vendor/github.com/Azure/go-autorest/autorest/go.sum
index 373d9c4e2557..0ebf4d1825a4 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/go.sum
+++ b/vendor/github.com/Azure/go-autorest/autorest/go.sum
@@ -1,7 +1,7 @@
github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
-github.com/Azure/go-autorest/autorest/adal v0.9.13 h1:Mp5hbtOePIzM8pJVRa3YLrWWmZtoxRXqUEzCfJt3+/Q=
-github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M=
+github.com/Azure/go-autorest/autorest/adal v0.9.18 h1:kLnPsRjzZZUF3K5REu/Kc+qMQrvuza2bwSnNdhmzLfQ=
+github.com/Azure/go-autorest/autorest/adal v0.9.18/go.mod h1:XVVeme+LZwABT8K5Lc3hA4nAe8LDBVle26gTrguhhPQ=
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
@@ -10,14 +10,18 @@ github.com/Azure/go-autorest/logger v0.2.1 h1:IG7i4p/mDa2Ce4TRyAO8IHnVhAVF3RFU+Z
github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
-github.com/form3tech-oss/jwt-go v3.2.2+incompatible h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=
-github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
-golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 h1:VklqNMn3ovrHsnt90PveolxSbWFaJdECFbxSq0Mqo2M=
-golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
-golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0 h1:hb9wdF1z5waM+dSIICn1l0DkLVDT3hqhhQsDNUmHPRE=
-golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
-golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU=
-golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
-golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
-golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
+github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
+github.com/golang-jwt/jwt/v4 v4.2.0 h1:besgBTC8w8HjP6NzQdxwKH9Z5oQMZ24ThTrHp3cZ8eU=
+github.com/golang-jwt/jwt/v4 v4.2.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
+golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3 h1:0es+/5331RGQPcXlMfP+WrnIIS6dNnNRe0WB02W0F4M=
+golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
+golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
+golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
+golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
+golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
diff --git a/vendor/github.com/Azure/go-autorest/autorest/go_mod_tidy_hack.go b/vendor/github.com/Azure/go-autorest/autorest/go_mod_tidy_hack.go
index da65e1041eb0..792f82d4b665 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/go_mod_tidy_hack.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/go_mod_tidy_hack.go
@@ -1,3 +1,4 @@
+//go:build modhack
// +build modhack
package autorest
diff --git a/vendor/github.com/Azure/go-autorest/autorest/preparer.go b/vendor/github.com/Azure/go-autorest/autorest/preparer.go
index 98574a4155fc..121a66fa883d 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/preparer.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/preparer.go
@@ -241,6 +241,8 @@ func WithBaseURL(baseURL string) PrepareDecorator {
return r, fmt.Errorf("autorest: No scheme detected in URL %s", baseURL)
}
if u.RawQuery != "" {
+ // handle unencoded semicolons (ideally the server would send them already encoded)
+ u.RawQuery = strings.Replace(u.RawQuery, ";", "%3B", -1)
q, err := url.ParseQuery(u.RawQuery)
if err != nil {
return r, err
diff --git a/vendor/github.com/Azure/go-autorest/autorest/retriablerequest_1.7.go b/vendor/github.com/Azure/go-autorest/autorest/retriablerequest_1.7.go
index 7143cc61b58b..4c87030e81a5 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/retriablerequest_1.7.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/retriablerequest_1.7.go
@@ -1,3 +1,4 @@
+//go:build !go1.8
// +build !go1.8
// Copyright 2017 Microsoft Corporation
diff --git a/vendor/github.com/Azure/go-autorest/autorest/retriablerequest_1.8.go b/vendor/github.com/Azure/go-autorest/autorest/retriablerequest_1.8.go
index ae15c6bf9629..05847c08ba25 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/retriablerequest_1.8.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/retriablerequest_1.8.go
@@ -1,3 +1,4 @@
+//go:build go1.8
// +build go1.8
// Copyright 2017 Microsoft Corporation
diff --git a/vendor/github.com/Azure/go-autorest/autorest/sender.go b/vendor/github.com/Azure/go-autorest/autorest/sender.go
index 78610ef20441..118de8141181 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/sender.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/sender.go
@@ -20,12 +20,14 @@ import (
"fmt"
"log"
"math"
+ "net"
"net/http"
"net/http/cookiejar"
"strconv"
"sync"
"time"
+ "github.com/Azure/go-autorest/logger"
"github.com/Azure/go-autorest/tracing"
)
@@ -128,15 +130,18 @@ func sender(renengotiation tls.RenegotiationSupport) Sender {
// note that we can't init defaultSenders in init() since it will
// execute before calling code has had a chance to enable tracing
defaultSenders[renengotiation].init.Do(func() {
- // Use behaviour compatible with DefaultTransport, but require TLS minimum version.
- defaultTransport := http.DefaultTransport.(*http.Transport)
+ // copied from http.DefaultTransport with a TLS minimum version.
transport := &http.Transport{
- Proxy: defaultTransport.Proxy,
- DialContext: defaultTransport.DialContext,
- MaxIdleConns: defaultTransport.MaxIdleConns,
- IdleConnTimeout: defaultTransport.IdleConnTimeout,
- TLSHandshakeTimeout: defaultTransport.TLSHandshakeTimeout,
- ExpectContinueTimeout: defaultTransport.ExpectContinueTimeout,
+ Proxy: http.ProxyFromEnvironment,
+ DialContext: (&net.Dialer{
+ Timeout: 30 * time.Second,
+ KeepAlive: 30 * time.Second,
+ }).DialContext,
+ ForceAttemptHTTP2: true,
+ MaxIdleConns: 100,
+ IdleConnTimeout: 90 * time.Second,
+ TLSHandshakeTimeout: 10 * time.Second,
+ ExpectContinueTimeout: 1 * time.Second,
TLSClientConfig: &tls.Config{
MinVersion: tls.VersionTLS12,
Renegotiation: renengotiation,
@@ -271,6 +276,7 @@ func DoRetryForAttempts(attempts int, backoff time.Duration) SendDecorator {
if err == nil {
return resp, err
}
+ logger.Instance.Writef(logger.LogError, "DoRetryForAttempts: received error for attempt %d: %v\n", attempt+1, err)
if !DelayForBackoff(backoff, attempt, r.Context().Done()) {
return nil, r.Context().Err()
}
@@ -325,6 +331,9 @@ func doRetryForStatusCodesImpl(s Sender, r *http.Request, count429 bool, attempt
if err == nil && !ResponseHasStatusCode(resp, codes...) || IsTokenRefreshError(err) {
return resp, err
}
+ if err != nil {
+ logger.Instance.Writef(logger.LogError, "DoRetryForStatusCodes: received error for attempt %d: %v\n", attempt+1, err)
+ }
delayed := DelayWithRetryAfter(resp, r.Context().Done())
// if this was a 429 set the delay cap as specified.
// applicable only in the absence of a retry-after header.
@@ -391,6 +400,7 @@ func DoRetryForDuration(d time.Duration, backoff time.Duration) SendDecorator {
if err == nil {
return resp, err
}
+ logger.Instance.Writef(logger.LogError, "DoRetryForDuration: received error for attempt %d: %v\n", attempt+1, err)
if !DelayForBackoff(backoff, attempt, r.Context().Done()) {
return nil, r.Context().Err()
}
@@ -438,6 +448,7 @@ func DelayForBackoffWithCap(backoff, cap time.Duration, attempt int, cancel <-ch
if cap > 0 && d > cap {
d = cap
}
+ logger.Instance.Writef(logger.LogInfo, "DelayForBackoffWithCap: sleeping for %s\n", d)
select {
case <-time.After(d):
return true
diff --git a/vendor/github.com/Azure/go-autorest/autorest/utility_1.13.go b/vendor/github.com/Azure/go-autorest/autorest/utility_1.13.go
index 4cb5e6849f6a..3133fcc08ef1 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/utility_1.13.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/utility_1.13.go
@@ -1,3 +1,4 @@
+//go:build go1.13
// +build go1.13
// Copyright 2017 Microsoft Corporation
diff --git a/vendor/github.com/Azure/go-autorest/autorest/utility_legacy.go b/vendor/github.com/Azure/go-autorest/autorest/utility_legacy.go
index ebb51b4f5319..851e152db4ef 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/utility_legacy.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/utility_legacy.go
@@ -1,3 +1,4 @@
+//go:build !go1.13
// +build !go1.13
// Copyright 2017 Microsoft Corporation
diff --git a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/credhelper/helper.go b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/credhelper/helper.go
index 87e8345aadfe..2a7cbdf07f21 100644
--- a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/credhelper/helper.go
+++ b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/credhelper/helper.go
@@ -18,6 +18,8 @@ package credhelper
import (
"errors"
"fmt"
+ "net/url"
+ "regexp"
"github.com/Azure/go-autorest/autorest/azure/auth"
"github.com/chrismellard/docker-credential-acr-env/pkg/registry"
@@ -25,7 +27,12 @@ import (
"github.com/docker/docker-credential-helpers/credentials"
)
-const tokenUsername = ""
+var acrRE = regexp.MustCompile(`.*\.azurecr\.io|.*\.azurecr\.cn|.*\.azurecr\.de|.*\.azurecr\.us`)
+
+const (
+ mcrHostname = "mcr.microsoft.com"
+ tokenUsername = ""
+)
type ACRCredHelper struct {
}
@@ -42,7 +49,26 @@ func (a ACRCredHelper) Delete(_ string) error {
return errors.New("list is unimplemented")
}
+func isACRRegistry(input string) bool {
+ serverURL, err := url.Parse("https://" + input)
+ if err != nil {
+ return false
+ }
+ if serverURL.Hostname() == mcrHostname {
+ return true
+ }
+ matches := acrRE.FindStringSubmatch(serverURL.Hostname())
+ if len(matches) == 0 {
+ return false
+ }
+ return true
+}
+
func (a ACRCredHelper) Get(serverURL string) (string, string, error) {
+ if !isACRRegistry(serverURL) {
+ return "", "", errors.New("serverURL does not refer to Azure Container Registry")
+ }
+
spToken, settings, err := token.GetServicePrincipalTokenFromEnvironment()
if err != nil {
return "", "", fmt.Errorf("failed to acquire sp token %w", err)
diff --git a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/const.go b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/const.go
index 4d29da79b12c..2f8ad5a0a55e 100644
--- a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/const.go
+++ b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/const.go
@@ -16,11 +16,10 @@ limitations under the License.
package registry
import (
- "context"
"time"
)
-const secureScheme = "https://"
-
-var defaultTimeOut = time.Duration(30) * time.Second
-var OAuthHTTPContext = context.Background()
+const (
+ secureScheme = "https://"
+ defaultTimeOut = time.Duration(30) * time.Second
+)
diff --git a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/registry.go b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/registry.go
index e546ac1e632f..c1b30dde8f28 100644
--- a/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/registry.go
+++ b/vendor/github.com/chrismellard/docker-credential-acr-env/pkg/registry/registry.go
@@ -27,9 +27,13 @@ import (
// GetRegistryRefreshTokenFromAADExchange retrieves an OAuth2 refresh token for the registry specified by serverURL
func GetRegistryRefreshTokenFromAADExchange(serverURL string, principalToken *adal.ServicePrincipalToken, tenantID string) (string, error) {
+ ctx, cancel := context.WithTimeout(context.Background(), defaultTimeOut)
+ defer cancel()
- err := principalToken.EnsureFresh()
- if err != nil {
+ // If refreshing fails, don't try again, just fail.
+ principalToken.MaxMSIRefreshAttempts = 1
+
+ if err := principalToken.EnsureFreshWithContext(ctx); err != nil {
return "", fmt.Errorf("error refreshing sp token - %w", err)
}
@@ -40,11 +44,7 @@ func GetRegistryRefreshTokenFromAADExchange(serverURL string, principalToken *ad
refreshTokenClient := containerregistry.NewRefreshTokensClient(registryName.String())
authorizer := autorest.NewBearerAuthorizer(principalToken)
refreshTokenClient.Authorizer = authorizer
- ctx, cancel := context.WithTimeout(OAuthHTTPContext, defaultTimeOut)
- defer cancel()
-
rt, err := refreshTokenClient.GetFromExchange(ctx, "access_token", serverURL, tenantID, "", principalToken.Token().AccessToken)
-
if err != nil {
return "", fmt.Errorf("failed to get refresh token for container registry - %w", err)
}
diff --git a/vendor/github.com/dimchansky/utfbom/.travis.yml b/vendor/github.com/dimchansky/utfbom/.travis.yml
index 3512c85190d7..19312ee35fc0 100644
--- a/vendor/github.com/dimchansky/utfbom/.travis.yml
+++ b/vendor/github.com/dimchansky/utfbom/.travis.yml
@@ -1,17 +1,28 @@
language: go
+sudo: false
go:
- - '1.10'
- - '1.11'
+ - 1.10.x
+ - 1.11.x
+ - 1.12.x
+ - 1.13.x
+ - 1.14.x
+ - 1.15.x
-# sudo=false makes the build run using a container
-sudo: false
+cache:
+ directories:
+ - $HOME/.cache/go-build
+ - $HOME/gopath/pkg/mod
+
+env:
+ global:
+ - GO111MODULE=on
before_install:
- go get github.com/mattn/goveralls
- go get golang.org/x/tools/cmd/cover
- go get golang.org/x/tools/cmd/goimports
- - go get github.com/golang/lint/golint
+ - go get golang.org/x/lint/golint
script:
- gofiles=$(find ./ -name '*.go') && [ -z "$gofiles" ] || unformatted=$(goimports -l $gofiles) && [ -z "$unformatted" ] || (echo >&2 "Go files must be formatted with gofmt. Following files has problem:\n $unformatted" && false)
- golint ./... # This won't break the build, just show warnings
diff --git a/vendor/github.com/dimchansky/utfbom/LICENSE b/vendor/github.com/dimchansky/utfbom/LICENSE
index 8dada3edaf50..6279cb87f434 100644
--- a/vendor/github.com/dimchansky/utfbom/LICENSE
+++ b/vendor/github.com/dimchansky/utfbom/LICENSE
@@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
- Copyright {yyyy} {name of copyright owner}
+ Copyright (c) 2018-2020, Dmitrij Koniajev (dimchansky@gmail.com)
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
diff --git a/vendor/github.com/dimchansky/utfbom/go.mod b/vendor/github.com/dimchansky/utfbom/go.mod
index 4b9ecc6f545e..8f8620af3b50 100644
--- a/vendor/github.com/dimchansky/utfbom/go.mod
+++ b/vendor/github.com/dimchansky/utfbom/go.mod
@@ -1 +1 @@
-module github.com/dimchansky/utfbom
\ No newline at end of file
+module github.com/dimchansky/utfbom
diff --git a/vendor/github.com/form3tech-oss/jwt-go/.travis.yml b/vendor/github.com/form3tech-oss/jwt-go/.travis.yml
deleted file mode 100644
index 3c7fb7e1ae64..000000000000
--- a/vendor/github.com/form3tech-oss/jwt-go/.travis.yml
+++ /dev/null
@@ -1,12 +0,0 @@
-language: go
-
-script:
- - go vet ./...
- - go test -v ./...
-
-go:
- - 1.12
- - 1.13
- - 1.14
- - 1.15
- - tip
diff --git a/vendor/github.com/form3tech-oss/jwt-go/MIGRATION_GUIDE.md b/vendor/github.com/form3tech-oss/jwt-go/MIGRATION_GUIDE.md
deleted file mode 100644
index 7fc1f793cbc4..000000000000
--- a/vendor/github.com/form3tech-oss/jwt-go/MIGRATION_GUIDE.md
+++ /dev/null
@@ -1,97 +0,0 @@
-## Migration Guide from v2 -> v3
-
-Version 3 adds several new, frequently requested features. To do so, it introduces a few breaking changes. We've worked to keep these as minimal as possible. This guide explains the breaking changes and how you can quickly update your code.
-
-### `Token.Claims` is now an interface type
-
-The most requested feature from the 2.0 verison of this library was the ability to provide a custom type to the JSON parser for claims. This was implemented by introducing a new interface, `Claims`, to replace `map[string]interface{}`. We also included two concrete implementations of `Claims`: `MapClaims` and `StandardClaims`.
-
-`MapClaims` is an alias for `map[string]interface{}` with built in validation behavior. It is the default claims type when using `Parse`. The usage is unchanged except you must type cast the claims property.
-
-The old example for parsing a token looked like this..
-
-```go
- if token, err := jwt.Parse(tokenString, keyLookupFunc); err == nil {
- fmt.Printf("Token for user %v expires %v", token.Claims["user"], token.Claims["exp"])
- }
-```
-
-is now directly mapped to...
-
-```go
- if token, err := jwt.Parse(tokenString, keyLookupFunc); err == nil {
- claims := token.Claims.(jwt.MapClaims)
- fmt.Printf("Token for user %v expires %v", claims["user"], claims["exp"])
- }
-```
-
-`StandardClaims` is designed to be embedded in your custom type. You can supply a custom claims type with the new `ParseWithClaims` function. Here's an example of using a custom claims type.
-
-```go
- type MyCustomClaims struct {
- User string
- *StandardClaims
- }
-
- if token, err := jwt.ParseWithClaims(tokenString, &MyCustomClaims{}, keyLookupFunc); err == nil {
- claims := token.Claims.(*MyCustomClaims)
- fmt.Printf("Token for user %v expires %v", claims.User, claims.StandardClaims.ExpiresAt)
- }
-```
-
-### `ParseFromRequest` has been moved
-
-To keep this library focused on the tokens without becoming overburdened with complex request processing logic, `ParseFromRequest` and its new companion `ParseFromRequestWithClaims` have been moved to a subpackage, `request`. The method signatues have also been augmented to receive a new argument: `Extractor`.
-
-`Extractors` do the work of picking the token string out of a request. The interface is simple and composable.
-
-This simple parsing example:
-
-```go
- if token, err := jwt.ParseFromRequest(tokenString, req, keyLookupFunc); err == nil {
- fmt.Printf("Token for user %v expires %v", token.Claims["user"], token.Claims["exp"])
- }
-```
-
-is directly mapped to:
-
-```go
- if token, err := request.ParseFromRequest(req, request.OAuth2Extractor, keyLookupFunc); err == nil {
- claims := token.Claims.(jwt.MapClaims)
- fmt.Printf("Token for user %v expires %v", claims["user"], claims["exp"])
- }
-```
-
-There are several concrete `Extractor` types provided for your convenience:
-
-* `HeaderExtractor` will search a list of headers until one contains content.
-* `ArgumentExtractor` will search a list of keys in request query and form arguments until one contains content.
-* `MultiExtractor` will try a list of `Extractors` in order until one returns content.
-* `AuthorizationHeaderExtractor` will look in the `Authorization` header for a `Bearer` token.
-* `OAuth2Extractor` searches the places an OAuth2 token would be specified (per the spec): `Authorization` header and `access_token` argument
-* `PostExtractionFilter` wraps an `Extractor`, allowing you to process the content before it's parsed. A simple example is stripping the `Bearer ` text from a header
-
-
-### RSA signing methods no longer accept `[]byte` keys
-
-Due to a [critical vulnerability](https://auth0.com/blog/2015/03/31/critical-vulnerabilities-in-json-web-token-libraries/), we've decided the convenience of accepting `[]byte` instead of `rsa.PublicKey` or `rsa.PrivateKey` isn't worth the risk of misuse.
-
-To replace this behavior, we've added two helper methods: `ParseRSAPrivateKeyFromPEM(key []byte) (*rsa.PrivateKey, error)` and `ParseRSAPublicKeyFromPEM(key []byte) (*rsa.PublicKey, error)`. These are just simple helpers for unpacking PEM encoded PKCS1 and PKCS8 keys. If your keys are encoded any other way, all you need to do is convert them to the `crypto/rsa` package's types.
-
-```go
- func keyLookupFunc(*Token) (interface{}, error) {
- // Don't forget to validate the alg is what you expect:
- if _, ok := token.Method.(*jwt.SigningMethodRSA); !ok {
- return nil, fmt.Errorf("Unexpected signing method: %v", token.Header["alg"])
- }
-
- // Look up key
- key, err := lookupPublicKey(token.Header["kid"])
- if err != nil {
- return nil, err
- }
-
- // Unpack key from PEM encoded PKCS8
- return jwt.ParseRSAPublicKeyFromPEM(key)
- }
-```
diff --git a/vendor/github.com/form3tech-oss/jwt-go/claims.go b/vendor/github.com/form3tech-oss/jwt-go/claims.go
deleted file mode 100644
index 624890666c66..000000000000
--- a/vendor/github.com/form3tech-oss/jwt-go/claims.go
+++ /dev/null
@@ -1,136 +0,0 @@
-package jwt
-
-import (
- "crypto/subtle"
- "fmt"
- "time"
-)
-
-// For a type to be a Claims object, it must just have a Valid method that determines
-// if the token is invalid for any supported reason
-type Claims interface {
- Valid() error
-}
-
-// Structured version of Claims Section, as referenced at
-// https://tools.ietf.org/html/rfc7519#section-4.1
-// See examples for how to use this with your own claim types
-type StandardClaims struct {
- Audience []string `json:"aud,omitempty"`
- ExpiresAt int64 `json:"exp,omitempty"`
- Id string `json:"jti,omitempty"`
- IssuedAt int64 `json:"iat,omitempty"`
- Issuer string `json:"iss,omitempty"`
- NotBefore int64 `json:"nbf,omitempty"`
- Subject string `json:"sub,omitempty"`
-}
-
-// Validates time based claims "exp, iat, nbf".
-// There is no accounting for clock skew.
-// As well, if any of the above claims are not in the token, it will still
-// be considered a valid claim.
-func (c StandardClaims) Valid() error {
- vErr := new(ValidationError)
- now := TimeFunc().Unix()
-
- // The claims below are optional, by default, so if they are set to the
- // default value in Go, let's not fail the verification for them.
- if c.VerifyExpiresAt(now, false) == false {
- delta := time.Unix(now, 0).Sub(time.Unix(c.ExpiresAt, 0))
- vErr.Inner = fmt.Errorf("token is expired by %v", delta)
- vErr.Errors |= ValidationErrorExpired
- }
-
- if c.VerifyIssuedAt(now, false) == false {
- vErr.Inner = fmt.Errorf("Token used before issued")
- vErr.Errors |= ValidationErrorIssuedAt
- }
-
- if c.VerifyNotBefore(now, false) == false {
- vErr.Inner = fmt.Errorf("token is not valid yet")
- vErr.Errors |= ValidationErrorNotValidYet
- }
-
- if vErr.valid() {
- return nil
- }
-
- return vErr
-}
-
-// Compares the aud claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (c *StandardClaims) VerifyAudience(cmp string, req bool) bool {
- return verifyAud(c.Audience, cmp, req)
-}
-
-// Compares the exp claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (c *StandardClaims) VerifyExpiresAt(cmp int64, req bool) bool {
- return verifyExp(c.ExpiresAt, cmp, req)
-}
-
-// Compares the iat claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (c *StandardClaims) VerifyIssuedAt(cmp int64, req bool) bool {
- return verifyIat(c.IssuedAt, cmp, req)
-}
-
-// Compares the iss claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (c *StandardClaims) VerifyIssuer(cmp string, req bool) bool {
- return verifyIss(c.Issuer, cmp, req)
-}
-
-// Compares the nbf claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (c *StandardClaims) VerifyNotBefore(cmp int64, req bool) bool {
- return verifyNbf(c.NotBefore, cmp, req)
-}
-
-// ----- helpers
-
-func verifyAud(aud []string, cmp string, required bool) bool {
- if len(aud) == 0 {
- return !required
- }
-
- for _, a := range aud {
- if subtle.ConstantTimeCompare([]byte(a), []byte(cmp)) != 0 {
- return true
- }
- }
- return false
-}
-
-func verifyExp(exp int64, now int64, required bool) bool {
- if exp == 0 {
- return !required
- }
- return now <= exp
-}
-
-func verifyIat(iat int64, now int64, required bool) bool {
- if iat == 0 {
- return !required
- }
- return now >= iat
-}
-
-func verifyIss(iss string, cmp string, required bool) bool {
- if iss == "" {
- return !required
- }
- if subtle.ConstantTimeCompare([]byte(iss), []byte(cmp)) != 0 {
- return true
- } else {
- return false
- }
-}
-
-func verifyNbf(nbf int64, now int64, required bool) bool {
- if nbf == 0 {
- return !required
- }
- return now >= nbf
-}
diff --git a/vendor/github.com/form3tech-oss/jwt-go/map_claims.go b/vendor/github.com/form3tech-oss/jwt-go/map_claims.go
deleted file mode 100644
index bcc37b15bf86..000000000000
--- a/vendor/github.com/form3tech-oss/jwt-go/map_claims.go
+++ /dev/null
@@ -1,110 +0,0 @@
-package jwt
-
-import (
- "encoding/json"
- "errors"
- // "fmt"
-)
-
-// Claims type that uses the map[string]interface{} for JSON decoding
-// This is the default claims type if you don't supply one
-type MapClaims map[string]interface{}
-
-// Compares the aud claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (m MapClaims) VerifyAudience(cmp string, req bool) bool {
- var aud []string
- switch v := m["aud"].(type) {
- case []string:
- aud = v
- case []interface{}:
- for _, a := range v {
- vs, ok := a.(string)
- if !ok {
- return false
- }
- aud = append(aud, vs)
- }
- case string:
- aud = append(aud, v)
- default:
- return false
- }
- return verifyAud(aud, cmp, req)
-}
-
-// Compares the exp claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (m MapClaims) VerifyExpiresAt(cmp int64, req bool) bool {
- switch exp := m["exp"].(type) {
- case float64:
- return verifyExp(int64(exp), cmp, req)
- case json.Number:
- v, _ := exp.Int64()
- return verifyExp(v, cmp, req)
- }
- return req == false
-}
-
-// Compares the iat claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (m MapClaims) VerifyIssuedAt(cmp int64, req bool) bool {
- switch iat := m["iat"].(type) {
- case float64:
- return verifyIat(int64(iat), cmp, req)
- case json.Number:
- v, _ := iat.Int64()
- return verifyIat(v, cmp, req)
- }
- return req == false
-}
-
-// Compares the iss claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (m MapClaims) VerifyIssuer(cmp string, req bool) bool {
- iss, _ := m["iss"].(string)
- return verifyIss(iss, cmp, req)
-}
-
-// Compares the nbf claim against cmp.
-// If required is false, this method will return true if the value matches or is unset
-func (m MapClaims) VerifyNotBefore(cmp int64, req bool) bool {
- switch nbf := m["nbf"].(type) {
- case float64:
- return verifyNbf(int64(nbf), cmp, req)
- case json.Number:
- v, _ := nbf.Int64()
- return verifyNbf(v, cmp, req)
- }
- return req == false
-}
-
-// Validates time based claims "exp, iat, nbf".
-// There is no accounting for clock skew.
-// As well, if any of the above claims are not in the token, it will still
-// be considered a valid claim.
-func (m MapClaims) Valid() error {
- vErr := new(ValidationError)
- now := TimeFunc().Unix()
-
- if m.VerifyExpiresAt(now, false) == false {
- vErr.Inner = errors.New("Token is expired")
- vErr.Errors |= ValidationErrorExpired
- }
-
- if m.VerifyIssuedAt(now, false) == false {
- vErr.Inner = errors.New("Token used before issued")
- vErr.Errors |= ValidationErrorIssuedAt
- }
-
- if m.VerifyNotBefore(now, false) == false {
- vErr.Inner = errors.New("Token is not valid yet")
- vErr.Errors |= ValidationErrorNotValidYet
- }
-
- if vErr.valid() {
- return nil
- }
-
- return vErr
-}
diff --git a/vendor/github.com/form3tech-oss/jwt-go/token.go b/vendor/github.com/form3tech-oss/jwt-go/token.go
deleted file mode 100644
index d637e0867c65..000000000000
--- a/vendor/github.com/form3tech-oss/jwt-go/token.go
+++ /dev/null
@@ -1,108 +0,0 @@
-package jwt
-
-import (
- "encoding/base64"
- "encoding/json"
- "strings"
- "time"
-)
-
-// TimeFunc provides the current time when parsing token to validate "exp" claim (expiration time).
-// You can override it to use another time value. This is useful for testing or if your
-// server uses a different time zone than your tokens.
-var TimeFunc = time.Now
-
-// Parse methods use this callback function to supply
-// the key for verification. The function receives the parsed,
-// but unverified Token. This allows you to use properties in the
-// Header of the token (such as `kid`) to identify which key to use.
-type Keyfunc func(*Token) (interface{}, error)
-
-// A JWT Token. Different fields will be used depending on whether you're
-// creating or parsing/verifying a token.
-type Token struct {
- Raw string // The raw token. Populated when you Parse a token
- Method SigningMethod // The signing method used or to be used
- Header map[string]interface{} // The first segment of the token
- Claims Claims // The second segment of the token
- Signature string // The third segment of the token. Populated when you Parse a token
- Valid bool // Is the token valid? Populated when you Parse/Verify a token
-}
-
-// Create a new Token. Takes a signing method
-func New(method SigningMethod) *Token {
- return NewWithClaims(method, MapClaims{})
-}
-
-func NewWithClaims(method SigningMethod, claims Claims) *Token {
- return &Token{
- Header: map[string]interface{}{
- "typ": "JWT",
- "alg": method.Alg(),
- },
- Claims: claims,
- Method: method,
- }
-}
-
-// Get the complete, signed token
-func (t *Token) SignedString(key interface{}) (string, error) {
- var sig, sstr string
- var err error
- if sstr, err = t.SigningString(); err != nil {
- return "", err
- }
- if sig, err = t.Method.Sign(sstr, key); err != nil {
- return "", err
- }
- return strings.Join([]string{sstr, sig}, "."), nil
-}
-
-// Generate the signing string. This is the
-// most expensive part of the whole deal. Unless you
-// need this for something special, just go straight for
-// the SignedString.
-func (t *Token) SigningString() (string, error) {
- var err error
- parts := make([]string, 2)
- for i, _ := range parts {
- var jsonValue []byte
- if i == 0 {
- if jsonValue, err = json.Marshal(t.Header); err != nil {
- return "", err
- }
- } else {
- if jsonValue, err = json.Marshal(t.Claims); err != nil {
- return "", err
- }
- }
-
- parts[i] = EncodeSegment(jsonValue)
- }
- return strings.Join(parts, "."), nil
-}
-
-// Parse, validate, and return a token.
-// keyFunc will receive the parsed token and should return the key for validating.
-// If everything is kosher, err will be nil
-func Parse(tokenString string, keyFunc Keyfunc) (*Token, error) {
- return new(Parser).Parse(tokenString, keyFunc)
-}
-
-func ParseWithClaims(tokenString string, claims Claims, keyFunc Keyfunc) (*Token, error) {
- return new(Parser).ParseWithClaims(tokenString, claims, keyFunc)
-}
-
-// Encode JWT specific base64url encoding with padding stripped
-func EncodeSegment(seg []byte) string {
- return strings.TrimRight(base64.URLEncoding.EncodeToString(seg), "=")
-}
-
-// Decode JWT specific base64url encoding with padding stripped
-func DecodeSegment(seg string) ([]byte, error) {
- if l := len(seg) % 4; l > 0 {
- seg += strings.Repeat("=", 4-l)
- }
-
- return base64.URLEncoding.DecodeString(seg)
-}
diff --git a/vendor/github.com/form3tech-oss/jwt-go/.gitignore b/vendor/github.com/golang-jwt/jwt/v4/.gitignore
similarity index 95%
rename from vendor/github.com/form3tech-oss/jwt-go/.gitignore
rename to vendor/github.com/golang-jwt/jwt/v4/.gitignore
index c0e81a8d9267..09573e0169c2 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/.gitignore
+++ b/vendor/github.com/golang-jwt/jwt/v4/.gitignore
@@ -2,4 +2,3 @@
bin
.idea/
-
diff --git a/third_party/VENDOR-LICENSE/github.com/form3tech-oss/jwt-go/LICENSE b/vendor/github.com/golang-jwt/jwt/v4/LICENSE
similarity index 96%
rename from third_party/VENDOR-LICENSE/github.com/form3tech-oss/jwt-go/LICENSE
rename to vendor/github.com/golang-jwt/jwt/v4/LICENSE
index df83a9c2f019..35dbc252041e 100644
--- a/third_party/VENDOR-LICENSE/github.com/form3tech-oss/jwt-go/LICENSE
+++ b/vendor/github.com/golang-jwt/jwt/v4/LICENSE
@@ -1,4 +1,5 @@
Copyright (c) 2012 Dave Grijalva
+Copyright (c) 2021 golang-jwt maintainers
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
diff --git a/vendor/github.com/golang-jwt/jwt/v4/MIGRATION_GUIDE.md b/vendor/github.com/golang-jwt/jwt/v4/MIGRATION_GUIDE.md
new file mode 100644
index 000000000000..32966f59818e
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/MIGRATION_GUIDE.md
@@ -0,0 +1,22 @@
+## Migration Guide (v4.0.0)
+
+Starting from [v4.0.0](https://github.com/golang-jwt/jwt/releases/tag/v4.0.0), the import path will be:
+
+ "github.com/golang-jwt/jwt/v4"
+
+The `/v4` version will be backwards compatible with existing `v3.x.y` tags in this repo, as well as
+`github.com/dgrijalva/jwt-go`. For most users this should be a drop-in replacement, if you're having
+troubles migrating, please open an issue.
+
+You can replace all occurrences of `github.com/dgrijalva/jwt-go` or `github.com/golang-jwt/jwt` with `github.com/golang-jwt/jwt/v4`, either manually or by using tools such as `sed` or `gofmt`.
+
+And then you'd typically run:
+
+```
+go get github.com/golang-jwt/jwt/v4
+go mod tidy
+```
+
+## Older releases (before v3.2.0)
+
+The original migration guide for older releases can be found at https://github.com/dgrijalva/jwt-go/blob/master/MIGRATION_GUIDE.md.
diff --git a/vendor/github.com/form3tech-oss/jwt-go/README.md b/vendor/github.com/golang-jwt/jwt/v4/README.md
similarity index 60%
rename from vendor/github.com/form3tech-oss/jwt-go/README.md
rename to vendor/github.com/golang-jwt/jwt/v4/README.md
index d7749077fde6..3072d24a9da6 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/README.md
+++ b/vendor/github.com/golang-jwt/jwt/v4/README.md
@@ -1,25 +1,36 @@
# jwt-go
-[](https://travis-ci.org/dgrijalva/jwt-go)
-[](https://godoc.org/github.com/dgrijalva/jwt-go)
+[](https://github.com/golang-jwt/jwt/actions/workflows/build.yml)
+[](https://pkg.go.dev/github.com/golang-jwt/jwt/v4)
-A [go](http://www.golang.org) (or 'golang' for search engine friendliness) implementation of [JSON Web Tokens](http://self-issued.info/docs/draft-ietf-oauth-json-web-token.html)
+A [go](http://www.golang.org) (or 'golang' for search engine friendliness) implementation of [JSON Web Tokens](https://datatracker.ietf.org/doc/html/rfc7519).
-**NEW VERSION COMING:** There have been a lot of improvements suggested since the version 3.0.0 released in 2016. I'm working now on cutting two different releases: 3.2.0 will contain any non-breaking changes or enhancements. 4.0.0 will follow shortly which will include breaking changes. See the 4.0.0 milestone to get an idea of what's coming. If you have other ideas, or would like to participate in 4.0.0, now's the time. If you depend on this library and don't want to be interrupted, I recommend you use your dependency mangement tool to pin to version 3.
+Starting with [v4.0.0](https://github.com/golang-jwt/jwt/releases/tag/v4.0.0) this project adds Go module support, but maintains backwards compatibility with older `v3.x.y` tags and upstream `github.com/dgrijalva/jwt-go`.
+See the [`MIGRATION_GUIDE.md`](./MIGRATION_GUIDE.md) for more information.
-**SECURITY NOTICE:** Some older versions of Go have a security issue in the cryotp/elliptic. Recommendation is to upgrade to at least 1.8.3. See issue #216 for more detail.
+> After the original author of the library suggested migrating the maintenance of `jwt-go`, a dedicated team of open source maintainers decided to clone the existing library into this repository. See [dgrijalva/jwt-go#462](https://github.com/dgrijalva/jwt-go/issues/462) for a detailed discussion on this topic.
+
+
+**SECURITY NOTICE:** Some older versions of Go have a security issue in the crypto/elliptic. Recommendation is to upgrade to at least 1.15 See issue [dgrijalva/jwt-go#216](https://github.com/dgrijalva/jwt-go/issues/216) for more detail.
**SECURITY NOTICE:** It's important that you [validate the `alg` presented is what you expect](https://auth0.com/blog/critical-vulnerabilities-in-json-web-token-libraries/). This library attempts to make it easy to do the right thing by requiring key types match the expected alg, but you should take the extra step to verify it in your usage. See the examples provided.
+### Supported Go versions
+
+Our support of Go versions is aligned with Go's [version release policy](https://golang.org/doc/devel/release#policy).
+So we will support a major version of Go until there are two newer major releases.
+We no longer support building jwt-go with unsupported Go versions, as these contain security vulnerabilities
+which will not be fixed.
+
## What the heck is a JWT?
JWT.io has [a great introduction](https://jwt.io/introduction) to JSON Web Tokens.
-In short, it's a signed JSON object that does something useful (for example, authentication). It's commonly used for `Bearer` tokens in Oauth 2. A token is made of three parts, separated by `.`'s. The first two parts are JSON objects, that have been [base64url](http://tools.ietf.org/html/rfc4648) encoded. The last part is the signature, encoded the same way.
+In short, it's a signed JSON object that does something useful (for example, authentication). It's commonly used for `Bearer` tokens in Oauth 2. A token is made of three parts, separated by `.`'s. The first two parts are JSON objects, that have been [base64url](https://datatracker.ietf.org/doc/html/rfc4648) encoded. The last part is the signature, encoded the same way.
The first part is called the header. It contains the necessary information for verifying the last part, the signature. For example, which encryption method was used for signing and what key was used.
-The part in the middle is the interesting bit. It's called the Claims and contains the actual stuff you care about. Refer to [the RFC](http://self-issued.info/docs/draft-ietf-oauth-json-web-token.html) for information about reserved keys and the proper way to add your own.
+The part in the middle is the interesting bit. It's called the Claims and contains the actual stuff you care about. Refer to [RFC 7519](https://datatracker.ietf.org/doc/html/rfc7519) for information about reserved keys and the proper way to add your own.
## What's in the box?
@@ -27,11 +38,11 @@ This library supports the parsing and verification as well as the generation and
## Examples
-See [the project documentation](https://godoc.org/github.com/dgrijalva/jwt-go) for examples of usage:
+See [the project documentation](https://pkg.go.dev/github.com/golang-jwt/jwt) for examples of usage:
-* [Simple example of parsing and validating a token](https://godoc.org/github.com/dgrijalva/jwt-go#example-Parse--Hmac)
-* [Simple example of building and signing a token](https://godoc.org/github.com/dgrijalva/jwt-go#example-New--Hmac)
-* [Directory of Examples](https://godoc.org/github.com/dgrijalva/jwt-go#pkg-examples)
+* [Simple example of parsing and validating a token](https://pkg.go.dev/github.com/golang-jwt/jwt#example-Parse-Hmac)
+* [Simple example of building and signing a token](https://pkg.go.dev/github.com/golang-jwt/jwt#example-New-Hmac)
+* [Directory of Examples](https://pkg.go.dev/github.com/golang-jwt/jwt#pkg-examples)
## Extensions
@@ -41,20 +52,18 @@ Here's an example of an extension that integrates with multiple Google Cloud Pla
## Compliance
-This library was last reviewed to comply with [RTF 7519](http://www.rfc-editor.org/info/rfc7519) dated May 2015 with a few notable differences:
+This library was last reviewed to comply with [RFC 7519](https://datatracker.ietf.org/doc/html/rfc7519) dated May 2015 with a few notable differences:
-* In order to protect against accidental use of [Unsecured JWTs](http://self-issued.info/docs/draft-ietf-oauth-json-web-token.html#UnsecuredJWT), tokens using `alg=none` will only be accepted if the constant `jwt.UnsafeAllowNoneSignatureType` is provided as the key.
+* In order to protect against accidental use of [Unsecured JWTs](https://datatracker.ietf.org/doc/html/rfc7519#section-6), tokens using `alg=none` will only be accepted if the constant `jwt.UnsafeAllowNoneSignatureType` is provided as the key.
## Project Status & Versioning
This library is considered production ready. Feedback and feature requests are appreciated. The API should be considered stable. There should be very few backwards-incompatible changes outside of major version updates (and only with good reason).
-This project uses [Semantic Versioning 2.0.0](http://semver.org). Accepted pull requests will land on `master`. Periodically, versions will be tagged from `master`. You can find all the releases on [the project releases page](https://github.com/dgrijalva/jwt-go/releases).
-
-While we try to make it obvious when we make breaking changes, there isn't a great mechanism for pushing announcements out to users. You may want to use this alternative package include: `gopkg.in/dgrijalva/jwt-go.v3`. It will do the right thing WRT semantic versioning.
+This project uses [Semantic Versioning 2.0.0](http://semver.org). Accepted pull requests will land on `main`. Periodically, versions will be tagged from `main`. You can find all the releases on [the project releases page](https://github.com/golang-jwt/jwt/releases).
**BREAKING CHANGES:***
-* Version 3.0.0 includes _a lot_ of changes from the 2.x line, including a few that break the API. We've tried to break as few things as possible, so there should just be a few type signature changes. A full list of breaking changes is available in `VERSION_HISTORY.md`. See `MIGRATION_GUIDE.md` for more information on updating your code.
+A full list of breaking changes is available in `VERSION_HISTORY.md`. See `MIGRATION_GUIDE.md` for more information on updating your code.
## Usage Tips
@@ -79,9 +88,10 @@ Asymmetric signing methods, such as RSA, use different keys for signing and veri
Each signing method expects a different object type for its signing keys. See the package documentation for details. Here are the most common ones:
-* The [HMAC signing method](https://godoc.org/github.com/dgrijalva/jwt-go#SigningMethodHMAC) (`HS256`,`HS384`,`HS512`) expect `[]byte` values for signing and validation
-* The [RSA signing method](https://godoc.org/github.com/dgrijalva/jwt-go#SigningMethodRSA) (`RS256`,`RS384`,`RS512`) expect `*rsa.PrivateKey` for signing and `*rsa.PublicKey` for validation
-* The [ECDSA signing method](https://godoc.org/github.com/dgrijalva/jwt-go#SigningMethodECDSA) (`ES256`,`ES384`,`ES512`) expect `*ecdsa.PrivateKey` for signing and `*ecdsa.PublicKey` for validation
+* The [HMAC signing method](https://pkg.go.dev/github.com/golang-jwt/jwt#SigningMethodHMAC) (`HS256`,`HS384`,`HS512`) expect `[]byte` values for signing and validation
+* The [RSA signing method](https://pkg.go.dev/github.com/golang-jwt/jwt#SigningMethodRSA) (`RS256`,`RS384`,`RS512`) expect `*rsa.PrivateKey` for signing and `*rsa.PublicKey` for validation
+* The [ECDSA signing method](https://pkg.go.dev/github.com/golang-jwt/jwt#SigningMethodECDSA) (`ES256`,`ES384`,`ES512`) expect `*ecdsa.PrivateKey` for signing and `*ecdsa.PublicKey` for validation
+* The [EdDSA signing method](https://pkg.go.dev/github.com/golang-jwt/jwt#SigningMethodEd25519) (`Ed25519`) expect `ed25519.PrivateKey` for signing and `ed25519.PublicKey` for validation
### JWT and OAuth
@@ -99,6 +109,6 @@ This library uses descriptive error messages whenever possible. If you are not g
## More
-Documentation can be found [on godoc.org](http://godoc.org/github.com/dgrijalva/jwt-go).
+Documentation can be found [on pkg.go.dev](https://pkg.go.dev/github.com/golang-jwt/jwt).
The command line utility included in this project (cmd/jwt) provides a straightforward example of token creation and parsing as well as a useful tool for debugging your own integration. You'll also find several implementation examples in the documentation.
diff --git a/vendor/github.com/form3tech-oss/jwt-go/VERSION_HISTORY.md b/vendor/github.com/golang-jwt/jwt/v4/VERSION_HISTORY.md
similarity index 84%
rename from vendor/github.com/form3tech-oss/jwt-go/VERSION_HISTORY.md
rename to vendor/github.com/golang-jwt/jwt/v4/VERSION_HISTORY.md
index 6370298313a6..afbfc4e408d1 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/VERSION_HISTORY.md
+++ b/vendor/github.com/golang-jwt/jwt/v4/VERSION_HISTORY.md
@@ -1,5 +1,22 @@
## `jwt-go` Version History
+#### 4.0.0
+
+* Introduces support for Go modules. The `v4` version will be backwards compatible with `v3.x.y`.
+
+#### 3.2.2
+
+* Starting from this release, we are adopting the policy to support the most 2 recent versions of Go currently available. By the time of this release, this is Go 1.15 and 1.16 ([#28](https://github.com/golang-jwt/jwt/pull/28)).
+* Fixed a potential issue that could occur when the verification of `exp`, `iat` or `nbf` was not required and contained invalid contents, i.e. non-numeric/date. Thanks for @thaJeztah for making us aware of that and @giorgos-f3 for originally reporting it to the formtech fork ([#40](https://github.com/golang-jwt/jwt/pull/40)).
+* Added support for EdDSA / ED25519 ([#36](https://github.com/golang-jwt/jwt/pull/36)).
+* Optimized allocations ([#33](https://github.com/golang-jwt/jwt/pull/33)).
+
+#### 3.2.1
+
+* **Import Path Change**: See MIGRATION_GUIDE.md for tips on updating your code
+ * Changed the import path from `github.com/dgrijalva/jwt-go` to `github.com/golang-jwt/jwt`
+* Fixed type confusing issue between `string` and `[]string` in `VerifyAudience` ([#12](https://github.com/golang-jwt/jwt/pull/12)). This fixes CVE-2020-26160
+
#### 3.2.0
* Added method `ParseUnverified` to allow users to split up the tasks of parsing and validation
@@ -115,4 +132,4 @@ It is likely the only integration change required here will be to change `func(t
* First versioned release
* API stabilized
* Supports creating, signing, parsing, and validating JWT tokens
-* Supports RS256 and HS256 signing methods
\ No newline at end of file
+* Supports RS256 and HS256 signing methods
diff --git a/vendor/github.com/golang-jwt/jwt/v4/claims.go b/vendor/github.com/golang-jwt/jwt/v4/claims.go
new file mode 100644
index 000000000000..41cc826563ba
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/claims.go
@@ -0,0 +1,273 @@
+package jwt
+
+import (
+ "crypto/subtle"
+ "fmt"
+ "time"
+)
+
+// Claims must just have a Valid method that determines
+// if the token is invalid for any supported reason
+type Claims interface {
+ Valid() error
+}
+
+// RegisteredClaims are a structured version of the JWT Claims Set,
+// restricted to Registered Claim Names, as referenced at
+// https://datatracker.ietf.org/doc/html/rfc7519#section-4.1
+//
+// This type can be used on its own, but then additional private and
+// public claims embedded in the JWT will not be parsed. The typical usecase
+// therefore is to embedded this in a user-defined claim type.
+//
+// See examples for how to use this with your own claim types.
+type RegisteredClaims struct {
+ // the `iss` (Issuer) claim. See https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.1
+ Issuer string `json:"iss,omitempty"`
+
+ // the `sub` (Subject) claim. See https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.2
+ Subject string `json:"sub,omitempty"`
+
+ // the `aud` (Audience) claim. See https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.3
+ Audience ClaimStrings `json:"aud,omitempty"`
+
+ // the `exp` (Expiration Time) claim. See https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.4
+ ExpiresAt *NumericDate `json:"exp,omitempty"`
+
+ // the `nbf` (Not Before) claim. See https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.5
+ NotBefore *NumericDate `json:"nbf,omitempty"`
+
+ // the `iat` (Issued At) claim. See https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.6
+ IssuedAt *NumericDate `json:"iat,omitempty"`
+
+ // the `jti` (JWT ID) claim. See https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.7
+ ID string `json:"jti,omitempty"`
+}
+
+// Valid validates time based claims "exp, iat, nbf".
+// There is no accounting for clock skew.
+// As well, if any of the above claims are not in the token, it will still
+// be considered a valid claim.
+func (c RegisteredClaims) Valid() error {
+ vErr := new(ValidationError)
+ now := TimeFunc()
+
+ // The claims below are optional, by default, so if they are set to the
+ // default value in Go, let's not fail the verification for them.
+ if !c.VerifyExpiresAt(now, false) {
+ delta := now.Sub(c.ExpiresAt.Time)
+ vErr.Inner = fmt.Errorf("token is expired by %v", delta)
+ vErr.Errors |= ValidationErrorExpired
+ }
+
+ if !c.VerifyIssuedAt(now, false) {
+ vErr.Inner = fmt.Errorf("token used before issued")
+ vErr.Errors |= ValidationErrorIssuedAt
+ }
+
+ if !c.VerifyNotBefore(now, false) {
+ vErr.Inner = fmt.Errorf("token is not valid yet")
+ vErr.Errors |= ValidationErrorNotValidYet
+ }
+
+ if vErr.valid() {
+ return nil
+ }
+
+ return vErr
+}
+
+// VerifyAudience compares the aud claim against cmp.
+// If required is false, this method will return true if the value matches or is unset
+func (c *RegisteredClaims) VerifyAudience(cmp string, req bool) bool {
+ return verifyAud(c.Audience, cmp, req)
+}
+
+// VerifyExpiresAt compares the exp claim against cmp (cmp < exp).
+// If req is false, it will return true, if exp is unset.
+func (c *RegisteredClaims) VerifyExpiresAt(cmp time.Time, req bool) bool {
+ if c.ExpiresAt == nil {
+ return verifyExp(nil, cmp, req)
+ }
+
+ return verifyExp(&c.ExpiresAt.Time, cmp, req)
+}
+
+// VerifyIssuedAt compares the iat claim against cmp (cmp >= iat).
+// If req is false, it will return true, if iat is unset.
+func (c *RegisteredClaims) VerifyIssuedAt(cmp time.Time, req bool) bool {
+ if c.IssuedAt == nil {
+ return verifyIat(nil, cmp, req)
+ }
+
+ return verifyIat(&c.IssuedAt.Time, cmp, req)
+}
+
+// VerifyNotBefore compares the nbf claim against cmp (cmp >= nbf).
+// If req is false, it will return true, if nbf is unset.
+func (c *RegisteredClaims) VerifyNotBefore(cmp time.Time, req bool) bool {
+ if c.NotBefore == nil {
+ return verifyNbf(nil, cmp, req)
+ }
+
+ return verifyNbf(&c.NotBefore.Time, cmp, req)
+}
+
+// VerifyIssuer compares the iss claim against cmp.
+// If required is false, this method will return true if the value matches or is unset
+func (c *RegisteredClaims) VerifyIssuer(cmp string, req bool) bool {
+ return verifyIss(c.Issuer, cmp, req)
+}
+
+// StandardClaims are a structured version of the JWT Claims Set, as referenced at
+// https://datatracker.ietf.org/doc/html/rfc7519#section-4. They do not follow the
+// specification exactly, since they were based on an earlier draft of the
+// specification and not updated. The main difference is that they only
+// support integer-based date fields and singular audiences. This might lead to
+// incompatibilities with other JWT implementations. The use of this is discouraged, instead
+// the newer RegisteredClaims struct should be used.
+//
+// Deprecated: Use RegisteredClaims instead for a forward-compatible way to access registered claims in a struct.
+type StandardClaims struct {
+ Audience string `json:"aud,omitempty"`
+ ExpiresAt int64 `json:"exp,omitempty"`
+ Id string `json:"jti,omitempty"`
+ IssuedAt int64 `json:"iat,omitempty"`
+ Issuer string `json:"iss,omitempty"`
+ NotBefore int64 `json:"nbf,omitempty"`
+ Subject string `json:"sub,omitempty"`
+}
+
+// Valid validates time based claims "exp, iat, nbf". There is no accounting for clock skew.
+// As well, if any of the above claims are not in the token, it will still
+// be considered a valid claim.
+func (c StandardClaims) Valid() error {
+ vErr := new(ValidationError)
+ now := TimeFunc().Unix()
+
+ // The claims below are optional, by default, so if they are set to the
+ // default value in Go, let's not fail the verification for them.
+ if !c.VerifyExpiresAt(now, false) {
+ delta := time.Unix(now, 0).Sub(time.Unix(c.ExpiresAt, 0))
+ vErr.Inner = fmt.Errorf("token is expired by %v", delta)
+ vErr.Errors |= ValidationErrorExpired
+ }
+
+ if !c.VerifyIssuedAt(now, false) {
+ vErr.Inner = fmt.Errorf("token used before issued")
+ vErr.Errors |= ValidationErrorIssuedAt
+ }
+
+ if !c.VerifyNotBefore(now, false) {
+ vErr.Inner = fmt.Errorf("token is not valid yet")
+ vErr.Errors |= ValidationErrorNotValidYet
+ }
+
+ if vErr.valid() {
+ return nil
+ }
+
+ return vErr
+}
+
+// VerifyAudience compares the aud claim against cmp.
+// If required is false, this method will return true if the value matches or is unset
+func (c *StandardClaims) VerifyAudience(cmp string, req bool) bool {
+ return verifyAud([]string{c.Audience}, cmp, req)
+}
+
+// VerifyExpiresAt compares the exp claim against cmp (cmp < exp).
+// If req is false, it will return true, if exp is unset.
+func (c *StandardClaims) VerifyExpiresAt(cmp int64, req bool) bool {
+ if c.ExpiresAt == 0 {
+ return verifyExp(nil, time.Unix(cmp, 0), req)
+ }
+
+ t := time.Unix(c.ExpiresAt, 0)
+ return verifyExp(&t, time.Unix(cmp, 0), req)
+}
+
+// VerifyIssuedAt compares the iat claim against cmp (cmp >= iat).
+// If req is false, it will return true, if iat is unset.
+func (c *StandardClaims) VerifyIssuedAt(cmp int64, req bool) bool {
+ if c.IssuedAt == 0 {
+ return verifyIat(nil, time.Unix(cmp, 0), req)
+ }
+
+ t := time.Unix(c.IssuedAt, 0)
+ return verifyIat(&t, time.Unix(cmp, 0), req)
+}
+
+// VerifyNotBefore compares the nbf claim against cmp (cmp >= nbf).
+// If req is false, it will return true, if nbf is unset.
+func (c *StandardClaims) VerifyNotBefore(cmp int64, req bool) bool {
+ if c.NotBefore == 0 {
+ return verifyNbf(nil, time.Unix(cmp, 0), req)
+ }
+
+ t := time.Unix(c.NotBefore, 0)
+ return verifyNbf(&t, time.Unix(cmp, 0), req)
+}
+
+// VerifyIssuer compares the iss claim against cmp.
+// If required is false, this method will return true if the value matches or is unset
+func (c *StandardClaims) VerifyIssuer(cmp string, req bool) bool {
+ return verifyIss(c.Issuer, cmp, req)
+}
+
+// ----- helpers
+
+func verifyAud(aud []string, cmp string, required bool) bool {
+ if len(aud) == 0 {
+ return !required
+ }
+ // use a var here to keep constant time compare when looping over a number of claims
+ result := false
+
+ var stringClaims string
+ for _, a := range aud {
+ if subtle.ConstantTimeCompare([]byte(a), []byte(cmp)) != 0 {
+ result = true
+ }
+ stringClaims = stringClaims + a
+ }
+
+ // case where "" is sent in one or many aud claims
+ if len(stringClaims) == 0 {
+ return !required
+ }
+
+ return result
+}
+
+func verifyExp(exp *time.Time, now time.Time, required bool) bool {
+ if exp == nil {
+ return !required
+ }
+ return now.Before(*exp)
+}
+
+func verifyIat(iat *time.Time, now time.Time, required bool) bool {
+ if iat == nil {
+ return !required
+ }
+ return now.After(*iat) || now.Equal(*iat)
+}
+
+func verifyNbf(nbf *time.Time, now time.Time, required bool) bool {
+ if nbf == nil {
+ return !required
+ }
+ return now.After(*nbf) || now.Equal(*nbf)
+}
+
+func verifyIss(iss string, cmp string, required bool) bool {
+ if iss == "" {
+ return !required
+ }
+ if subtle.ConstantTimeCompare([]byte(iss), []byte(cmp)) != 0 {
+ return true
+ } else {
+ return false
+ }
+}
diff --git a/vendor/github.com/form3tech-oss/jwt-go/doc.go b/vendor/github.com/golang-jwt/jwt/v4/doc.go
similarity index 100%
rename from vendor/github.com/form3tech-oss/jwt-go/doc.go
rename to vendor/github.com/golang-jwt/jwt/v4/doc.go
diff --git a/vendor/github.com/form3tech-oss/jwt-go/ecdsa.go b/vendor/github.com/golang-jwt/jwt/v4/ecdsa.go
similarity index 79%
rename from vendor/github.com/form3tech-oss/jwt-go/ecdsa.go
rename to vendor/github.com/golang-jwt/jwt/v4/ecdsa.go
index f977381240e3..eac023fc6c84 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/ecdsa.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/ecdsa.go
@@ -13,7 +13,7 @@ var (
ErrECDSAVerification = errors.New("crypto/ecdsa: verification error")
)
-// Implements the ECDSA family of signing methods signing methods
+// SigningMethodECDSA implements the ECDSA family of signing methods.
// Expects *ecdsa.PrivateKey for signing and *ecdsa.PublicKey for verification
type SigningMethodECDSA struct {
Name string
@@ -53,7 +53,7 @@ func (m *SigningMethodECDSA) Alg() string {
return m.Name
}
-// Implements the Verify method from SigningMethod
+// Verify implements token verification for the SigningMethod.
// For this verify method, key must be an ecdsa.PublicKey struct
func (m *SigningMethodECDSA) Verify(signingString, signature string, key interface{}) error {
var err error
@@ -88,14 +88,14 @@ func (m *SigningMethodECDSA) Verify(signingString, signature string, key interfa
hasher.Write([]byte(signingString))
// Verify the signature
- if verifystatus := ecdsa.Verify(ecdsaKey, hasher.Sum(nil), r, s); verifystatus == true {
+ if verifystatus := ecdsa.Verify(ecdsaKey, hasher.Sum(nil), r, s); verifystatus {
return nil
- } else {
- return ErrECDSAVerification
}
+
+ return ErrECDSAVerification
}
-// Implements the Sign method from SigningMethod
+// Sign implements token signing for the SigningMethod.
// For this signing method, key must be an ecdsa.PrivateKey struct
func (m *SigningMethodECDSA) Sign(signingString string, key interface{}) (string, error) {
// Get the key
@@ -128,18 +128,12 @@ func (m *SigningMethodECDSA) Sign(signingString string, key interface{}) (string
keyBytes += 1
}
- // We serialize the outpus (r and s) into big-endian byte arrays and pad
- // them with zeros on the left to make sure the sizes work out. Both arrays
- // must be keyBytes long, and the output must be 2*keyBytes long.
- rBytes := r.Bytes()
- rBytesPadded := make([]byte, keyBytes)
- copy(rBytesPadded[keyBytes-len(rBytes):], rBytes)
-
- sBytes := s.Bytes()
- sBytesPadded := make([]byte, keyBytes)
- copy(sBytesPadded[keyBytes-len(sBytes):], sBytes)
-
- out := append(rBytesPadded, sBytesPadded...)
+ // We serialize the outputs (r and s) into big-endian byte arrays
+ // padded with zeros on the left to make sure the sizes work out.
+ // Output must be 2*keyBytes long.
+ out := make([]byte, 2*keyBytes)
+ r.FillBytes(out[0:keyBytes]) // r is assigned to the first half of output.
+ s.FillBytes(out[keyBytes:]) // s is assigned to the second half of output.
return EncodeSegment(out), nil
} else {
diff --git a/vendor/github.com/form3tech-oss/jwt-go/ecdsa_utils.go b/vendor/github.com/golang-jwt/jwt/v4/ecdsa_utils.go
similarity index 81%
rename from vendor/github.com/form3tech-oss/jwt-go/ecdsa_utils.go
rename to vendor/github.com/golang-jwt/jwt/v4/ecdsa_utils.go
index db9f4be7d8ea..5700636d35b6 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/ecdsa_utils.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/ecdsa_utils.go
@@ -8,11 +8,11 @@ import (
)
var (
- ErrNotECPublicKey = errors.New("Key is not a valid ECDSA public key")
- ErrNotECPrivateKey = errors.New("Key is not a valid ECDSA private key")
+ ErrNotECPublicKey = errors.New("key is not a valid ECDSA public key")
+ ErrNotECPrivateKey = errors.New("key is not a valid ECDSA private key")
)
-// Parse PEM encoded Elliptic Curve Private Key Structure
+// ParseECPrivateKeyFromPEM parses a PEM encoded Elliptic Curve Private Key Structure
func ParseECPrivateKeyFromPEM(key []byte) (*ecdsa.PrivateKey, error) {
var err error
@@ -39,7 +39,7 @@ func ParseECPrivateKeyFromPEM(key []byte) (*ecdsa.PrivateKey, error) {
return pkey, nil
}
-// Parse PEM encoded PKCS1 or PKCS8 public key
+// ParseECPublicKeyFromPEM parses a PEM encoded PKCS1 or PKCS8 public key
func ParseECPublicKeyFromPEM(key []byte) (*ecdsa.PublicKey, error) {
var err error
diff --git a/vendor/github.com/golang-jwt/jwt/v4/ed25519.go b/vendor/github.com/golang-jwt/jwt/v4/ed25519.go
new file mode 100644
index 000000000000..07d3aacd631f
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/ed25519.go
@@ -0,0 +1,85 @@
+package jwt
+
+import (
+ "errors"
+
+ "crypto"
+ "crypto/ed25519"
+ "crypto/rand"
+)
+
+var (
+ ErrEd25519Verification = errors.New("ed25519: verification error")
+)
+
+// SigningMethodEd25519 implements the EdDSA family.
+// Expects ed25519.PrivateKey for signing and ed25519.PublicKey for verification
+type SigningMethodEd25519 struct{}
+
+// Specific instance for EdDSA
+var (
+ SigningMethodEdDSA *SigningMethodEd25519
+)
+
+func init() {
+ SigningMethodEdDSA = &SigningMethodEd25519{}
+ RegisterSigningMethod(SigningMethodEdDSA.Alg(), func() SigningMethod {
+ return SigningMethodEdDSA
+ })
+}
+
+func (m *SigningMethodEd25519) Alg() string {
+ return "EdDSA"
+}
+
+// Verify implements token verification for the SigningMethod.
+// For this verify method, key must be an ed25519.PublicKey
+func (m *SigningMethodEd25519) Verify(signingString, signature string, key interface{}) error {
+ var err error
+ var ed25519Key ed25519.PublicKey
+ var ok bool
+
+ if ed25519Key, ok = key.(ed25519.PublicKey); !ok {
+ return ErrInvalidKeyType
+ }
+
+ if len(ed25519Key) != ed25519.PublicKeySize {
+ return ErrInvalidKey
+ }
+
+ // Decode the signature
+ var sig []byte
+ if sig, err = DecodeSegment(signature); err != nil {
+ return err
+ }
+
+ // Verify the signature
+ if !ed25519.Verify(ed25519Key, []byte(signingString), sig) {
+ return ErrEd25519Verification
+ }
+
+ return nil
+}
+
+// Sign implements token signing for the SigningMethod.
+// For this signing method, key must be an ed25519.PrivateKey
+func (m *SigningMethodEd25519) Sign(signingString string, key interface{}) (string, error) {
+ var ed25519Key crypto.Signer
+ var ok bool
+
+ if ed25519Key, ok = key.(crypto.Signer); !ok {
+ return "", ErrInvalidKeyType
+ }
+
+ if _, ok := ed25519Key.Public().(ed25519.PublicKey); !ok {
+ return "", ErrInvalidKey
+ }
+
+ // Sign the string and return the encoded result
+ // ed25519 performs a two-pass hash as part of its algorithm. Therefore, we need to pass a non-prehashed message into the Sign function, as indicated by crypto.Hash(0)
+ sig, err := ed25519Key.Sign(rand.Reader, []byte(signingString), crypto.Hash(0))
+ if err != nil {
+ return "", err
+ }
+ return EncodeSegment(sig), nil
+}
diff --git a/vendor/github.com/golang-jwt/jwt/v4/ed25519_utils.go b/vendor/github.com/golang-jwt/jwt/v4/ed25519_utils.go
new file mode 100644
index 000000000000..cdb5e68e8767
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/ed25519_utils.go
@@ -0,0 +1,64 @@
+package jwt
+
+import (
+ "crypto"
+ "crypto/ed25519"
+ "crypto/x509"
+ "encoding/pem"
+ "errors"
+)
+
+var (
+ ErrNotEdPrivateKey = errors.New("key is not a valid Ed25519 private key")
+ ErrNotEdPublicKey = errors.New("key is not a valid Ed25519 public key")
+)
+
+// ParseEdPrivateKeyFromPEM parses a PEM-encoded Edwards curve private key
+func ParseEdPrivateKeyFromPEM(key []byte) (crypto.PrivateKey, error) {
+ var err error
+
+ // Parse PEM block
+ var block *pem.Block
+ if block, _ = pem.Decode(key); block == nil {
+ return nil, ErrKeyMustBePEMEncoded
+ }
+
+ // Parse the key
+ var parsedKey interface{}
+ if parsedKey, err = x509.ParsePKCS8PrivateKey(block.Bytes); err != nil {
+ return nil, err
+ }
+
+ var pkey ed25519.PrivateKey
+ var ok bool
+ if pkey, ok = parsedKey.(ed25519.PrivateKey); !ok {
+ return nil, ErrNotEdPrivateKey
+ }
+
+ return pkey, nil
+}
+
+// ParseEdPublicKeyFromPEM parses a PEM-encoded Edwards curve public key
+func ParseEdPublicKeyFromPEM(key []byte) (crypto.PublicKey, error) {
+ var err error
+
+ // Parse PEM block
+ var block *pem.Block
+ if block, _ = pem.Decode(key); block == nil {
+ return nil, ErrKeyMustBePEMEncoded
+ }
+
+ // Parse the key
+ var parsedKey interface{}
+ if parsedKey, err = x509.ParsePKIXPublicKey(block.Bytes); err != nil {
+ return nil, err
+ }
+
+ var pkey ed25519.PublicKey
+ var ok bool
+ if pkey, ok = parsedKey.(ed25519.PublicKey); !ok {
+ return nil, ErrNotEdPublicKey
+ }
+
+ return pkey, nil
+}
diff --git a/vendor/github.com/form3tech-oss/jwt-go/errors.go b/vendor/github.com/golang-jwt/jwt/v4/errors.go
similarity index 82%
rename from vendor/github.com/form3tech-oss/jwt-go/errors.go
rename to vendor/github.com/golang-jwt/jwt/v4/errors.go
index 1c93024aad2e..b9d18e498e3f 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/errors.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/errors.go
@@ -27,7 +27,7 @@ const (
ValidationErrorClaimsInvalid // Generic claims validation error
)
-// Helper for constructing a ValidationError with a string error message
+// NewValidationError is a helper for constructing a ValidationError with a string error message
func NewValidationError(errorText string, errorFlags uint32) *ValidationError {
return &ValidationError{
text: errorText,
@@ -35,14 +35,14 @@ func NewValidationError(errorText string, errorFlags uint32) *ValidationError {
}
}
-// The error from Parse if token is not valid
+// ValidationError represents an error from Parse if token is not valid
type ValidationError struct {
Inner error // stores the error returned by external dependencies, i.e.: KeyFunc
Errors uint32 // bitfield. see ValidationError... constants
text string // errors that do not have a valid error just have text
}
-// Validation error is an error type
+// Error is the implementation of the err interface.
func (e ValidationError) Error() string {
if e.Inner != nil {
return e.Inner.Error()
@@ -53,6 +53,11 @@ func (e ValidationError) Error() string {
}
}
+// Unwrap gives errors.Is and errors.As access to the inner error.
+func (e *ValidationError) Unwrap() error {
+ return e.Inner
+}
+
// No errors
func (e *ValidationError) valid() bool {
return e.Errors == 0
diff --git a/vendor/github.com/golang-jwt/jwt/v4/go.mod b/vendor/github.com/golang-jwt/jwt/v4/go.mod
new file mode 100644
index 000000000000..6bc53fdcb930
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/go.mod
@@ -0,0 +1,3 @@
+module github.com/golang-jwt/jwt/v4
+
+go 1.15
diff --git a/vendor/github.com/golang-jwt/jwt/v4/go.sum b/vendor/github.com/golang-jwt/jwt/v4/go.sum
new file mode 100644
index 000000000000..e69de29bb2d1
diff --git a/vendor/github.com/form3tech-oss/jwt-go/hmac.go b/vendor/github.com/golang-jwt/jwt/v4/hmac.go
similarity index 90%
rename from vendor/github.com/form3tech-oss/jwt-go/hmac.go
rename to vendor/github.com/golang-jwt/jwt/v4/hmac.go
index addbe5d40182..011f68a27440 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/hmac.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/hmac.go
@@ -6,7 +6,7 @@ import (
"errors"
)
-// Implements the HMAC-SHA family of signing methods signing methods
+// SigningMethodHMAC implements the HMAC-SHA family of signing methods.
// Expects key type of []byte for both signing and validation
type SigningMethodHMAC struct {
Name string
@@ -45,7 +45,7 @@ func (m *SigningMethodHMAC) Alg() string {
return m.Name
}
-// Verify the signature of HSXXX tokens. Returns nil if the signature is valid.
+// Verify implements token verification for the SigningMethod. Returns nil if the signature is valid.
func (m *SigningMethodHMAC) Verify(signingString, signature string, key interface{}) error {
// Verify the key is the right type
keyBytes, ok := key.([]byte)
@@ -77,7 +77,7 @@ func (m *SigningMethodHMAC) Verify(signingString, signature string, key interfac
return nil
}
-// Implements the Sign method from SigningMethod for this signing method.
+// Sign implements token signing for the SigningMethod.
// Key must be []byte
func (m *SigningMethodHMAC) Sign(signingString string, key interface{}) (string, error) {
if keyBytes, ok := key.([]byte); ok {
diff --git a/vendor/github.com/golang-jwt/jwt/v4/map_claims.go b/vendor/github.com/golang-jwt/jwt/v4/map_claims.go
new file mode 100644
index 000000000000..e7da633b93c6
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/map_claims.go
@@ -0,0 +1,148 @@
+package jwt
+
+import (
+ "encoding/json"
+ "errors"
+ "time"
+ // "fmt"
+)
+
+// MapClaims is a claims type that uses the map[string]interface{} for JSON decoding.
+// This is the default claims type if you don't supply one
+type MapClaims map[string]interface{}
+
+// VerifyAudience Compares the aud claim against cmp.
+// If required is false, this method will return true if the value matches or is unset
+func (m MapClaims) VerifyAudience(cmp string, req bool) bool {
+ var aud []string
+ switch v := m["aud"].(type) {
+ case string:
+ aud = append(aud, v)
+ case []string:
+ aud = v
+ case []interface{}:
+ for _, a := range v {
+ vs, ok := a.(string)
+ if !ok {
+ return false
+ }
+ aud = append(aud, vs)
+ }
+ }
+ return verifyAud(aud, cmp, req)
+}
+
+// VerifyExpiresAt compares the exp claim against cmp (cmp <= exp).
+// If req is false, it will return true, if exp is unset.
+func (m MapClaims) VerifyExpiresAt(cmp int64, req bool) bool {
+ cmpTime := time.Unix(cmp, 0)
+
+ v, ok := m["exp"]
+ if !ok {
+ return !req
+ }
+
+ switch exp := v.(type) {
+ case float64:
+ if exp == 0 {
+ return verifyExp(nil, cmpTime, req)
+ }
+
+ return verifyExp(&newNumericDateFromSeconds(exp).Time, cmpTime, req)
+ case json.Number:
+ v, _ := exp.Float64()
+
+ return verifyExp(&newNumericDateFromSeconds(v).Time, cmpTime, req)
+ }
+
+ return false
+}
+
+// VerifyIssuedAt compares the exp claim against cmp (cmp >= iat).
+// If req is false, it will return true, if iat is unset.
+func (m MapClaims) VerifyIssuedAt(cmp int64, req bool) bool {
+ cmpTime := time.Unix(cmp, 0)
+
+ v, ok := m["iat"]
+ if !ok {
+ return !req
+ }
+
+ switch iat := v.(type) {
+ case float64:
+ if iat == 0 {
+ return verifyIat(nil, cmpTime, req)
+ }
+
+ return verifyIat(&newNumericDateFromSeconds(iat).Time, cmpTime, req)
+ case json.Number:
+ v, _ := iat.Float64()
+
+ return verifyIat(&newNumericDateFromSeconds(v).Time, cmpTime, req)
+ }
+
+ return false
+}
+
+// VerifyNotBefore compares the nbf claim against cmp (cmp >= nbf).
+// If req is false, it will return true, if nbf is unset.
+func (m MapClaims) VerifyNotBefore(cmp int64, req bool) bool {
+ cmpTime := time.Unix(cmp, 0)
+
+ v, ok := m["nbf"]
+ if !ok {
+ return !req
+ }
+
+ switch nbf := v.(type) {
+ case float64:
+ if nbf == 0 {
+ return verifyNbf(nil, cmpTime, req)
+ }
+
+ return verifyNbf(&newNumericDateFromSeconds(nbf).Time, cmpTime, req)
+ case json.Number:
+ v, _ := nbf.Float64()
+
+ return verifyNbf(&newNumericDateFromSeconds(v).Time, cmpTime, req)
+ }
+
+ return false
+}
+
+// VerifyIssuer compares the iss claim against cmp.
+// If required is false, this method will return true if the value matches or is unset
+func (m MapClaims) VerifyIssuer(cmp string, req bool) bool {
+ iss, _ := m["iss"].(string)
+ return verifyIss(iss, cmp, req)
+}
+
+// Valid validates time based claims "exp, iat, nbf".
+// There is no accounting for clock skew.
+// As well, if any of the above claims are not in the token, it will still
+// be considered a valid claim.
+func (m MapClaims) Valid() error {
+ vErr := new(ValidationError)
+ now := TimeFunc().Unix()
+
+ if !m.VerifyExpiresAt(now, false) {
+ vErr.Inner = errors.New("Token is expired")
+ vErr.Errors |= ValidationErrorExpired
+ }
+
+ if !m.VerifyIssuedAt(now, false) {
+ vErr.Inner = errors.New("Token used before issued")
+ vErr.Errors |= ValidationErrorIssuedAt
+ }
+
+ if !m.VerifyNotBefore(now, false) {
+ vErr.Inner = errors.New("Token is not valid yet")
+ vErr.Errors |= ValidationErrorNotValidYet
+ }
+
+ if vErr.valid() {
+ return nil
+ }
+
+ return vErr
+}
diff --git a/vendor/github.com/form3tech-oss/jwt-go/none.go b/vendor/github.com/golang-jwt/jwt/v4/none.go
similarity index 94%
rename from vendor/github.com/form3tech-oss/jwt-go/none.go
rename to vendor/github.com/golang-jwt/jwt/v4/none.go
index f04d189d067b..f19835d2078b 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/none.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/none.go
@@ -1,6 +1,6 @@
package jwt
-// Implements the none signing method. This is required by the spec
+// SigningMethodNone implements the none signing method. This is required by the spec
// but you probably should never use it.
var SigningMethodNone *signingMethodNone
diff --git a/vendor/github.com/form3tech-oss/jwt-go/parser.go b/vendor/github.com/golang-jwt/jwt/v4/parser.go
similarity index 78%
rename from vendor/github.com/form3tech-oss/jwt-go/parser.go
rename to vendor/github.com/golang-jwt/jwt/v4/parser.go
index d6901d9adb52..2f61a69d7fcb 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/parser.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/parser.go
@@ -8,14 +8,36 @@ import (
)
type Parser struct {
- ValidMethods []string // If populated, only these methods will be considered valid
- UseJSONNumber bool // Use JSON Number format in JSON decoder
- SkipClaimsValidation bool // Skip claims validation during token parsing
+ // If populated, only these methods will be considered valid.
+ //
+ // Deprecated: In future releases, this field will not be exported anymore and should be set with an option to NewParser instead.
+ ValidMethods []string
+
+ // Use JSON Number format in JSON decoder.
+ //
+ // Deprecated: In future releases, this field will not be exported anymore and should be set with an option to NewParser instead.
+ UseJSONNumber bool
+
+ // Skip claims validation during token parsing.
+ //
+ // Deprecated: In future releases, this field will not be exported anymore and should be set with an option to NewParser instead.
+ SkipClaimsValidation bool
}
-// Parse, validate, and return a token.
+// NewParser creates a new Parser with the specified options
+func NewParser(options ...ParserOption) *Parser {
+ p := &Parser{}
+
+ // loop through our parsing options and apply them
+ for _, option := range options {
+ option(p)
+ }
+
+ return p
+}
+
+// Parse parses, validates, verifies the signature and returns the parsed token.
// keyFunc will receive the parsed token and should return the key for validating.
-// If everything is kosher, err will be nil
func (p *Parser) Parse(tokenString string, keyFunc Keyfunc) (*Token, error) {
return p.ParseWithClaims(tokenString, MapClaims{}, keyFunc)
}
@@ -87,12 +109,12 @@ func (p *Parser) ParseWithClaims(tokenString string, claims Claims, keyFunc Keyf
return token, vErr
}
-// WARNING: Don't use this method unless you know what you're doing
+// ParseUnverified parses the token but doesn't validate the signature.
+//
+// WARNING: Don't use this method unless you know what you're doing.
//
-// This method parses the token but doesn't validate the signature. It's only
-// ever useful in cases where you know the signature is valid (because it has
-// been checked previously in the stack) and you want to extract values from
-// it.
+// It's only ever useful in cases where you know the signature is valid (because it has
+// been checked previously in the stack) and you want to extract values from it.
func (p *Parser) ParseUnverified(tokenString string, claims Claims) (token *Token, parts []string, err error) {
parts = strings.Split(tokenString, ".")
if len(parts) != 3 {
diff --git a/vendor/github.com/golang-jwt/jwt/v4/parser_option.go b/vendor/github.com/golang-jwt/jwt/v4/parser_option.go
new file mode 100644
index 000000000000..0fede4f15c90
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/parser_option.go
@@ -0,0 +1,29 @@
+package jwt
+
+// ParserOption is used to implement functional-style options that modify the behaviour of the parser. To add
+// new options, just create a function (ideally beginning with With or Without) that returns an anonymous function that
+// takes a *Parser type as input and manipulates its configuration accordingly.
+type ParserOption func(*Parser)
+
+// WithValidMethods is an option to supply algorithm methods that the parser will check. Only those methods will be considered valid.
+// It is heavily encouraged to use this option in order to prevent attacks such as https://auth0.com/blog/critical-vulnerabilities-in-json-web-token-libraries/.
+func WithValidMethods(methods []string) ParserOption {
+ return func(p *Parser) {
+ p.ValidMethods = methods
+ }
+}
+
+// WithJSONNumber is an option to configure the underyling JSON parser with UseNumber
+func WithJSONNumber() ParserOption {
+ return func(p *Parser) {
+ p.UseJSONNumber = true
+ }
+}
+
+// WithoutClaimsValidation is an option to disable claims validation. This option should only be used if you exactly know
+// what you are doing.
+func WithoutClaimsValidation() ParserOption {
+ return func(p *Parser) {
+ p.SkipClaimsValidation = true
+ }
+}
diff --git a/vendor/github.com/form3tech-oss/jwt-go/rsa.go b/vendor/github.com/golang-jwt/jwt/v4/rsa.go
similarity index 92%
rename from vendor/github.com/form3tech-oss/jwt-go/rsa.go
rename to vendor/github.com/golang-jwt/jwt/v4/rsa.go
index e4caf1ca4a11..b910b19c0b51 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/rsa.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/rsa.go
@@ -6,7 +6,7 @@ import (
"crypto/rsa"
)
-// Implements the RSA family of signing methods signing methods
+// SigningMethodRSA implements the RSA family of signing methods.
// Expects *rsa.PrivateKey for signing and *rsa.PublicKey for validation
type SigningMethodRSA struct {
Name string
@@ -44,7 +44,7 @@ func (m *SigningMethodRSA) Alg() string {
return m.Name
}
-// Implements the Verify method from SigningMethod
+// Verify implements token verification for the SigningMethod
// For this signing method, must be an *rsa.PublicKey structure.
func (m *SigningMethodRSA) Verify(signingString, signature string, key interface{}) error {
var err error
@@ -73,7 +73,7 @@ func (m *SigningMethodRSA) Verify(signingString, signature string, key interface
return rsa.VerifyPKCS1v15(rsaKey, m.Hash, hasher.Sum(nil), sig)
}
-// Implements the Sign method from SigningMethod
+// Sign implements token signing for the SigningMethod
// For this signing method, must be an *rsa.PrivateKey structure.
func (m *SigningMethodRSA) Sign(signingString string, key interface{}) (string, error) {
var rsaKey *rsa.PrivateKey
diff --git a/vendor/github.com/form3tech-oss/jwt-go/rsa_pss.go b/vendor/github.com/golang-jwt/jwt/v4/rsa_pss.go
similarity index 94%
rename from vendor/github.com/form3tech-oss/jwt-go/rsa_pss.go
rename to vendor/github.com/golang-jwt/jwt/v4/rsa_pss.go
index c01470864803..5a8502feb34b 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/rsa_pss.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/rsa_pss.go
@@ -8,7 +8,7 @@ import (
"crypto/rsa"
)
-// Implements the RSAPSS family of signing methods signing methods
+// SigningMethodRSAPSS implements the RSAPSS family of signing methods signing methods
type SigningMethodRSAPSS struct {
*SigningMethodRSA
Options *rsa.PSSOptions
@@ -79,7 +79,7 @@ func init() {
})
}
-// Implements the Verify method from SigningMethod
+// Verify implements token verification for the SigningMethod.
// For this verify method, key must be an rsa.PublicKey struct
func (m *SigningMethodRSAPSS) Verify(signingString, signature string, key interface{}) error {
var err error
@@ -113,7 +113,7 @@ func (m *SigningMethodRSAPSS) Verify(signingString, signature string, key interf
return rsa.VerifyPSS(rsaKey, m.Hash, hasher.Sum(nil), sig, opts)
}
-// Implements the Sign method from SigningMethod
+// Sign implements token signing for the SigningMethod.
// For this signing method, key must be an rsa.PrivateKey struct
func (m *SigningMethodRSAPSS) Sign(signingString string, key interface{}) (string, error) {
var rsaKey *rsa.PrivateKey
diff --git a/vendor/github.com/form3tech-oss/jwt-go/rsa_utils.go b/vendor/github.com/golang-jwt/jwt/v4/rsa_utils.go
similarity index 72%
rename from vendor/github.com/form3tech-oss/jwt-go/rsa_utils.go
rename to vendor/github.com/golang-jwt/jwt/v4/rsa_utils.go
index 14c78c292a94..1966c450bf8b 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/rsa_utils.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/rsa_utils.go
@@ -8,12 +8,12 @@ import (
)
var (
- ErrKeyMustBePEMEncoded = errors.New("Invalid Key: Key must be a PEM encoded PKCS1 or PKCS8 key")
- ErrNotRSAPrivateKey = errors.New("Key is not a valid RSA private key")
- ErrNotRSAPublicKey = errors.New("Key is not a valid RSA public key")
+ ErrKeyMustBePEMEncoded = errors.New("invalid key: Key must be a PEM encoded PKCS1 or PKCS8 key")
+ ErrNotRSAPrivateKey = errors.New("key is not a valid RSA private key")
+ ErrNotRSAPublicKey = errors.New("key is not a valid RSA public key")
)
-// Parse PEM encoded PKCS1 or PKCS8 private key
+// ParseRSAPrivateKeyFromPEM parses a PEM encoded PKCS1 or PKCS8 private key
func ParseRSAPrivateKeyFromPEM(key []byte) (*rsa.PrivateKey, error) {
var err error
@@ -39,7 +39,11 @@ func ParseRSAPrivateKeyFromPEM(key []byte) (*rsa.PrivateKey, error) {
return pkey, nil
}
-// Parse PEM encoded PKCS1 or PKCS8 private key protected with password
+// ParseRSAPrivateKeyFromPEMWithPassword parses a PEM encoded PKCS1 or PKCS8 private key protected with password
+//
+// Deprecated: This function is deprecated and should not be used anymore. It uses the deprecated x509.DecryptPEMBlock
+// function, which was deprecated since RFC 1423 is regarded insecure by design. Unfortunately, there is no alternative
+// in the Go standard library for now. See https://github.com/golang/go/issues/8860.
func ParseRSAPrivateKeyFromPEMWithPassword(key []byte, password string) (*rsa.PrivateKey, error) {
var err error
@@ -71,7 +75,7 @@ func ParseRSAPrivateKeyFromPEMWithPassword(key []byte, password string) (*rsa.Pr
return pkey, nil
}
-// Parse PEM encoded PKCS1 or PKCS8 public key
+// ParseRSAPublicKeyFromPEM parses a PEM encoded PKCS1 or PKCS8 public key
func ParseRSAPublicKeyFromPEM(key []byte) (*rsa.PublicKey, error) {
var err error
diff --git a/vendor/github.com/form3tech-oss/jwt-go/signing_method.go b/vendor/github.com/golang-jwt/jwt/v4/signing_method.go
similarity index 66%
rename from vendor/github.com/form3tech-oss/jwt-go/signing_method.go
rename to vendor/github.com/golang-jwt/jwt/v4/signing_method.go
index ed1f212b21e1..241ae9c60d08 100644
--- a/vendor/github.com/form3tech-oss/jwt-go/signing_method.go
+++ b/vendor/github.com/golang-jwt/jwt/v4/signing_method.go
@@ -7,14 +7,14 @@ import (
var signingMethods = map[string]func() SigningMethod{}
var signingMethodLock = new(sync.RWMutex)
-// Implement SigningMethod to add new methods for signing or verifying tokens.
+// SigningMethod can be used add new methods for signing or verifying tokens.
type SigningMethod interface {
Verify(signingString, signature string, key interface{}) error // Returns nil if signature is valid
Sign(signingString string, key interface{}) (string, error) // Returns encoded signature or error
Alg() string // returns the alg identifier for this method (example: 'HS256')
}
-// Register the "alg" name and a factory function for signing method.
+// RegisterSigningMethod registers the "alg" name and a factory function for signing method.
// This is typically done during init() in the method's implementation
func RegisterSigningMethod(alg string, f func() SigningMethod) {
signingMethodLock.Lock()
@@ -23,7 +23,7 @@ func RegisterSigningMethod(alg string, f func() SigningMethod) {
signingMethods[alg] = f
}
-// Get a signing method from an "alg" string
+// GetSigningMethod retrieves a signing method from an "alg" string
func GetSigningMethod(alg string) (method SigningMethod) {
signingMethodLock.RLock()
defer signingMethodLock.RUnlock()
@@ -33,3 +33,14 @@ func GetSigningMethod(alg string) (method SigningMethod) {
}
return
}
+
+// GetAlgorithms returns a list of registered "alg" names
+func GetAlgorithms() (algs []string) {
+ signingMethodLock.RLock()
+ defer signingMethodLock.RUnlock()
+
+ for alg := range signingMethods {
+ algs = append(algs, alg)
+ }
+ return
+}
diff --git a/vendor/github.com/golang-jwt/jwt/v4/staticcheck.conf b/vendor/github.com/golang-jwt/jwt/v4/staticcheck.conf
new file mode 100644
index 000000000000..53745d51d7c7
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/staticcheck.conf
@@ -0,0 +1 @@
+checks = ["all", "-ST1000", "-ST1003", "-ST1016", "-ST1023"]
diff --git a/vendor/github.com/golang-jwt/jwt/v4/token.go b/vendor/github.com/golang-jwt/jwt/v4/token.go
new file mode 100644
index 000000000000..12344138bedc
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/token.go
@@ -0,0 +1,131 @@
+package jwt
+
+import (
+ "encoding/base64"
+ "encoding/json"
+ "strings"
+ "time"
+)
+
+
+// DecodePaddingAllowed will switch the codec used for decoding JWTs respectively. Note that the JWS RFC7515
+// states that the tokens will utilize a Base64url encoding with no padding. Unfortunately, some implementations
+// of JWT are producing non-standard tokens, and thus require support for decoding. Note that this is a global
+// variable, and updating it will change the behavior on a package level, and is also NOT go-routine safe.
+// To use the non-recommended decoding, set this boolean to `true` prior to using this package.
+var DecodePaddingAllowed bool
+
+// TimeFunc provides the current time when parsing token to validate "exp" claim (expiration time).
+// You can override it to use another time value. This is useful for testing or if your
+// server uses a different time zone than your tokens.
+var TimeFunc = time.Now
+
+// Keyfunc will be used by the Parse methods as a callback function to supply
+// the key for verification. The function receives the parsed,
+// but unverified Token. This allows you to use properties in the
+// Header of the token (such as `kid`) to identify which key to use.
+type Keyfunc func(*Token) (interface{}, error)
+
+// Token represents a JWT Token. Different fields will be used depending on whether you're
+// creating or parsing/verifying a token.
+type Token struct {
+ Raw string // The raw token. Populated when you Parse a token
+ Method SigningMethod // The signing method used or to be used
+ Header map[string]interface{} // The first segment of the token
+ Claims Claims // The second segment of the token
+ Signature string // The third segment of the token. Populated when you Parse a token
+ Valid bool // Is the token valid? Populated when you Parse/Verify a token
+}
+
+// New creates a new Token with the specified signing method and an empty map of claims.
+func New(method SigningMethod) *Token {
+ return NewWithClaims(method, MapClaims{})
+}
+
+// NewWithClaims creates a new Token with the specified signing method and claims.
+func NewWithClaims(method SigningMethod, claims Claims) *Token {
+ return &Token{
+ Header: map[string]interface{}{
+ "typ": "JWT",
+ "alg": method.Alg(),
+ },
+ Claims: claims,
+ Method: method,
+ }
+}
+
+// SignedString creates and returns a complete, signed JWT.
+// The token is signed using the SigningMethod specified in the token.
+func (t *Token) SignedString(key interface{}) (string, error) {
+ var sig, sstr string
+ var err error
+ if sstr, err = t.SigningString(); err != nil {
+ return "", err
+ }
+ if sig, err = t.Method.Sign(sstr, key); err != nil {
+ return "", err
+ }
+ return strings.Join([]string{sstr, sig}, "."), nil
+}
+
+// SigningString generates the signing string. This is the
+// most expensive part of the whole deal. Unless you
+// need this for something special, just go straight for
+// the SignedString.
+func (t *Token) SigningString() (string, error) {
+ var err error
+ parts := make([]string, 2)
+ for i := range parts {
+ var jsonValue []byte
+ if i == 0 {
+ if jsonValue, err = json.Marshal(t.Header); err != nil {
+ return "", err
+ }
+ } else {
+ if jsonValue, err = json.Marshal(t.Claims); err != nil {
+ return "", err
+ }
+ }
+
+ parts[i] = EncodeSegment(jsonValue)
+ }
+ return strings.Join(parts, "."), nil
+}
+
+// Parse parses, validates, verifies the signature and returns the parsed token.
+// keyFunc will receive the parsed token and should return the cryptographic key
+// for verifying the signature.
+// The caller is strongly encouraged to set the WithValidMethods option to
+// validate the 'alg' claim in the token matches the expected algorithm.
+// For more details about the importance of validating the 'alg' claim,
+// see https://auth0.com/blog/critical-vulnerabilities-in-json-web-token-libraries/
+func Parse(tokenString string, keyFunc Keyfunc, options ...ParserOption) (*Token, error) {
+ return NewParser(options...).Parse(tokenString, keyFunc)
+}
+
+func ParseWithClaims(tokenString string, claims Claims, keyFunc Keyfunc, options ...ParserOption) (*Token, error) {
+ return NewParser(options...).ParseWithClaims(tokenString, claims, keyFunc)
+}
+
+// EncodeSegment encodes a JWT specific base64url encoding with padding stripped
+//
+// Deprecated: In a future release, we will demote this function to a non-exported function, since it
+// should only be used internally
+func EncodeSegment(seg []byte) string {
+ return base64.RawURLEncoding.EncodeToString(seg)
+}
+
+// DecodeSegment decodes a JWT specific base64url encoding with padding stripped
+//
+// Deprecated: In a future release, we will demote this function to a non-exported function, since it
+// should only be used internally
+func DecodeSegment(seg string) ([]byte, error) {
+ if DecodePaddingAllowed {
+ if l := len(seg) % 4; l > 0 {
+ seg += strings.Repeat("=", 4-l)
+ }
+ return base64.URLEncoding.DecodeString(seg)
+ }
+
+ return base64.RawURLEncoding.DecodeString(seg)
+}
diff --git a/vendor/github.com/golang-jwt/jwt/v4/types.go b/vendor/github.com/golang-jwt/jwt/v4/types.go
new file mode 100644
index 000000000000..80b1b96948ec
--- /dev/null
+++ b/vendor/github.com/golang-jwt/jwt/v4/types.go
@@ -0,0 +1,127 @@
+package jwt
+
+import (
+ "encoding/json"
+ "fmt"
+ "math"
+ "reflect"
+ "strconv"
+ "time"
+)
+
+// TimePrecision sets the precision of times and dates within this library.
+// This has an influence on the precision of times when comparing expiry or
+// other related time fields. Furthermore, it is also the precision of times
+// when serializing.
+//
+// For backwards compatibility the default precision is set to seconds, so that
+// no fractional timestamps are generated.
+var TimePrecision = time.Second
+
+// MarshalSingleStringAsArray modifies the behaviour of the ClaimStrings type, especially
+// its MarshalJSON function.
+//
+// If it is set to true (the default), it will always serialize the type as an
+// array of strings, even if it just contains one element, defaulting to the behaviour
+// of the underlying []string. If it is set to false, it will serialize to a single
+// string, if it contains one element. Otherwise, it will serialize to an array of strings.
+var MarshalSingleStringAsArray = true
+
+// NumericDate represents a JSON numeric date value, as referenced at
+// https://datatracker.ietf.org/doc/html/rfc7519#section-2.
+type NumericDate struct {
+ time.Time
+}
+
+// NewNumericDate constructs a new *NumericDate from a standard library time.Time struct.
+// It will truncate the timestamp according to the precision specified in TimePrecision.
+func NewNumericDate(t time.Time) *NumericDate {
+ return &NumericDate{t.Truncate(TimePrecision)}
+}
+
+// newNumericDateFromSeconds creates a new *NumericDate out of a float64 representing a
+// UNIX epoch with the float fraction representing non-integer seconds.
+func newNumericDateFromSeconds(f float64) *NumericDate {
+ round, frac := math.Modf(f)
+ return NewNumericDate(time.Unix(int64(round), int64(frac*1e9)))
+}
+
+// MarshalJSON is an implementation of the json.RawMessage interface and serializes the UNIX epoch
+// represented in NumericDate to a byte array, using the precision specified in TimePrecision.
+func (date NumericDate) MarshalJSON() (b []byte, err error) {
+ f := float64(date.Truncate(TimePrecision).UnixNano()) / float64(time.Second)
+
+ return []byte(strconv.FormatFloat(f, 'f', -1, 64)), nil
+}
+
+// UnmarshalJSON is an implementation of the json.RawMessage interface and deserializses a
+// NumericDate from a JSON representation, i.e. a json.Number. This number represents an UNIX epoch
+// with either integer or non-integer seconds.
+func (date *NumericDate) UnmarshalJSON(b []byte) (err error) {
+ var (
+ number json.Number
+ f float64
+ )
+
+ if err = json.Unmarshal(b, &number); err != nil {
+ return fmt.Errorf("could not parse NumericData: %w", err)
+ }
+
+ if f, err = number.Float64(); err != nil {
+ return fmt.Errorf("could not convert json number value to float: %w", err)
+ }
+
+ n := newNumericDateFromSeconds(f)
+ *date = *n
+
+ return nil
+}
+
+// ClaimStrings is basically just a slice of strings, but it can be either serialized from a string array or just a string.
+// This type is necessary, since the "aud" claim can either be a single string or an array.
+type ClaimStrings []string
+
+func (s *ClaimStrings) UnmarshalJSON(data []byte) (err error) {
+ var value interface{}
+
+ if err = json.Unmarshal(data, &value); err != nil {
+ return err
+ }
+
+ var aud []string
+
+ switch v := value.(type) {
+ case string:
+ aud = append(aud, v)
+ case []string:
+ aud = ClaimStrings(v)
+ case []interface{}:
+ for _, vv := range v {
+ vs, ok := vv.(string)
+ if !ok {
+ return &json.UnsupportedTypeError{Type: reflect.TypeOf(vv)}
+ }
+ aud = append(aud, vs)
+ }
+ case nil:
+ return nil
+ default:
+ return &json.UnsupportedTypeError{Type: reflect.TypeOf(v)}
+ }
+
+ *s = aud
+
+ return
+}
+
+func (s ClaimStrings) MarshalJSON() (b []byte, err error) {
+ // This handles a special case in the JWT RFC. If the string array, e.g. used by the "aud" field,
+ // only contains one element, it MAY be serialized as a single string. This may or may not be
+ // desired based on the ecosystem of other JWT library used, so we make it configurable by the
+ // variable MarshalSingleStringAsArray.
+ if len(s) == 1 && !MarshalSingleStringAsArray {
+ return json.Marshal(s[0])
+ }
+
+ return json.Marshal([]string(s))
+}
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.mod b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.mod
index d725ccbcbfb5..1311dc1112b7 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.mod
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.mod
@@ -3,14 +3,20 @@ module github.com/google/go-containerregistry/pkg/authn/k8schain
go 1.14
require (
+ github.com/Azure/azure-sdk-for-go v61.2.0+incompatible // indirect
+ github.com/Azure/go-autorest/autorest/azure/auth v0.5.11 // indirect
github.com/aws/aws-sdk-go-v2/config v1.12.0 // indirect
github.com/aws/aws-sdk-go-v2/service/ecr v1.13.0 // indirect
github.com/aws/aws-sdk-go-v2/service/ecrpublic v1.10.0 // indirect
github.com/awslabs/amazon-ecr-credential-helper/ecr-login v0.0.0-20211215200129-69c85dc22db6
- github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86
+ github.com/chrismellard/docker-credential-acr-env v0.0.0-20220119192733-fe33c00cee21
+ github.com/form3tech-oss/jwt-go v3.2.5+incompatible // indirect
github.com/google/go-containerregistry v0.8.1-0.20220110151055-a61fd0a8e2bb
github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20220110151055-a61fd0a8e2bb
- golang.org/x/sys v0.0.0-20220111092808-5a964db01320 // indirect
+ github.com/spf13/afero v1.8.0 // indirect
+ github.com/spf13/viper v1.10.1 // indirect
+ golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce // indirect
+ golang.org/x/sys v0.0.0-20220114195835-da31bd327af9 // indirect
k8s.io/api v0.22.5
k8s.io/client-go v0.22.5
)
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.sum b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.sum
index 51049edf5b21..cbf68fb0ada4 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.sum
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/k8schain/go.sum
@@ -4,6 +4,7 @@ cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMT
cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU=
cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU=
cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
+cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc=
cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0=
cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To=
@@ -16,6 +17,7 @@ cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOY
cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY=
cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI=
cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk=
+cloud.google.com/go v0.75.0/go.mod h1:VGuuCn7PG0dwsd5XPVm2Mm3wlh3EL55/79EKB6hlPTY=
cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg=
cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8=
cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0=
@@ -48,10 +50,13 @@ cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0Zeo
cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk=
cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs=
cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0=
+cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo=
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
github.com/Azure/azure-sdk-for-go v16.2.1+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
github.com/Azure/azure-sdk-for-go v46.4.0+incompatible h1:fCN6Pi+tEiEwFa8RSmtVlFHRXEZ+DJm9gfx/MKqYWw4=
github.com/Azure/azure-sdk-for-go v46.4.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
+github.com/Azure/azure-sdk-for-go v61.2.0+incompatible h1:sSormXkfW0ov1vh6ihTBRQxdfg73fPqkccl50GbR9iM=
+github.com/Azure/azure-sdk-for-go v61.2.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
github.com/Azure/go-autorest v10.8.1+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
@@ -61,15 +66,23 @@ github.com/Azure/go-autorest/autorest v0.11.6/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNh
github.com/Azure/go-autorest/autorest v0.11.8/go.mod h1:V6p3pKZx1KKkJubbxnDWrzNhEIfOy/pTGasLqzHIPHs=
github.com/Azure/go-autorest/autorest v0.11.18 h1:90Y4srNYrwOtAgVo3ndrQkTYn6kf1Eg/AjTFJ8Is2aM=
github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA=
+github.com/Azure/go-autorest/autorest v0.11.24 h1:1fIGgHKqVm54KIPT+q8Zmd1QlVsmHqeUGso5qm2BqqE=
+github.com/Azure/go-autorest/autorest v0.11.24/go.mod h1:G6kyRlFnTuSbEYkQGawPfsCswgme4iYf6rfSKUDzbCc=
github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg=
github.com/Azure/go-autorest/autorest/adal v0.9.4/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
github.com/Azure/go-autorest/autorest/adal v0.9.13 h1:Mp5hbtOePIzM8pJVRa3YLrWWmZtoxRXqUEzCfJt3+/Q=
github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M=
+github.com/Azure/go-autorest/autorest/adal v0.9.18 h1:kLnPsRjzZZUF3K5REu/Kc+qMQrvuza2bwSnNdhmzLfQ=
+github.com/Azure/go-autorest/autorest/adal v0.9.18/go.mod h1:XVVeme+LZwABT8K5Lc3hA4nAe8LDBVle26gTrguhhPQ=
github.com/Azure/go-autorest/autorest/azure/auth v0.5.2 h1:R1pgoZkhXuv4+0ky9r3e5pcnRXWcXGIuPXpC/xkc7uI=
github.com/Azure/go-autorest/autorest/azure/auth v0.5.2/go.mod h1:q98IH4qgc3eWM4/WOeR5+YPmBuy8Lq0jNRDwSM0CuFk=
+github.com/Azure/go-autorest/autorest/azure/auth v0.5.11 h1:P6bYXFoao05z5uhOQzbC3Qd8JqF3jUoocoTeIxkp2cA=
+github.com/Azure/go-autorest/autorest/azure/auth v0.5.11/go.mod h1:84w/uV8E37feW2NCJ08uT9VBfjfUHpgLVnG2InYD6cg=
github.com/Azure/go-autorest/autorest/azure/cli v0.4.1 h1:jwcD1wURu0+hKceV04MubZmKLzwEYOCz6q4aOtVZ+Ng=
github.com/Azure/go-autorest/autorest/azure/cli v0.4.1/go.mod h1:JfDgiIO1/RPu6z42AdQTyjOoCM2MFhLqSBDvMEkDgcg=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.5 h1:0W/yGmFdTIT77fvdlGZ0LMISoLHFJ7Tx4U0yeB+uFs4=
+github.com/Azure/go-autorest/autorest/azure/cli v0.4.5/go.mod h1:ADQAXrkgm7acgWVUNamOgh8YNrv4p27l3Wc55oVfpzg=
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
github.com/Azure/go-autorest/autorest/mocks v0.4.0/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
@@ -186,6 +199,8 @@ github.com/checkpoint-restore/go-criu/v4 v4.1.0/go.mod h1:xUQBLp4RLc5zJtWY++yjOo
github.com/checkpoint-restore/go-criu/v5 v5.0.0/go.mod h1:cfwC0EG7HMUenopBsUf9d89JlCLQIfgVcNsNN0t6T2M=
github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86 h1:VZogJ199yfR3BRTzpDcejsFrBCJKLgi9V37K74/YWC8=
github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86/go.mod h1:Zlre/PVxuSI9y6/UV4NwGixQ48RHQDSPiUkofr6rbMU=
+github.com/chrismellard/docker-credential-acr-env v0.0.0-20220119192733-fe33c00cee21 h1:XlpL9EHrPOBJMLDDOf35/G4t5rGAFNNAZQ3cDcWavtc=
+github.com/chrismellard/docker-credential-acr-env v0.0.0-20220119192733-fe33c00cee21/go.mod h1:Zlre/PVxuSI9y6/UV4NwGixQ48RHQDSPiUkofr6rbMU=
github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
@@ -330,6 +345,8 @@ github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZm
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
+github.com/dimchansky/utfbom v1.1.1 h1:vV6w1AhK4VMnhBno/TPVCoK9U/LP0PkLCS9tbxHdi/U=
+github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE=
github.com/dnaeon/go-vcr v1.0.1/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E=
github.com/docker/cli v20.10.12+incompatible h1:lZlz0uzG+GH+c0plStMUdF/qk3ppmgnswpR5EbqzVGA=
github.com/docker/cli v20.10.12+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8=
@@ -377,6 +394,8 @@ github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYF
github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
github.com/form3tech-oss/jwt-go v3.2.3+incompatible h1:7ZaBxOI7TMoYBfyA3cQHErNNyAWIKUMIwqxEtgHOs5c=
github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
+github.com/form3tech-oss/jwt-go v3.2.5+incompatible h1:/l4kBbb4/vGSsdtB5nUe8L7B9mImVMaBPw9L/0TBHU8=
+github.com/form3tech-oss/jwt-go v3.2.5+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
@@ -423,6 +442,9 @@ github.com/gogo/protobuf v1.3.0/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXP
github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q=
github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
+github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
+github.com/golang-jwt/jwt/v4 v4.2.0 h1:besgBTC8w8HjP6NzQdxwKH9Z5oQMZ24ThTrHp3cZ8eU=
+github.com/golang-jwt/jwt/v4 v4.2.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg=
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
@@ -490,6 +512,7 @@ github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hf
github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM=
github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
@@ -508,6 +531,7 @@ github.com/googleapis/gnostic v0.4.1/go.mod h1:LRhVm6pbyptWbWbuZ38d1eyptfvIytN3i
github.com/googleapis/gnostic v0.5.1/go.mod h1:6U4PtQXGIEt/Z3h5MAT7FNofLnw9vXk2cUuW7uA/OeU=
github.com/googleapis/gnostic v0.5.5 h1:9fHAtK0uDfpveeqqo1hkEZJcFvYXAiCN3UutL8F9xHw=
github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA=
+github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g=
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
github.com/gorilla/handlers v0.0.0-20150720190736-60c7bfde3e33/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ=
github.com/gorilla/mux v1.7.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
@@ -524,6 +548,7 @@ github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t
github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw=
github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q=
github.com/hashicorp/consul/api v1.11.0/go.mod h1:XjsvQN+RJGWI2TWy1/kqaE16HrR2J/FWgkYjdZQsX9M=
+github.com/hashicorp/consul/api v1.12.0/go.mod h1:6pVBMo0ebnYdt2S3H87XhekM/HHrUoTD2XXb/VrZVy0=
github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8=
github.com/hashicorp/consul/sdk v0.8.0/go.mod h1:GBvyrGALthsZObzUGsfgHZQDXjg4lOjagTIwIR1vPms=
github.com/hashicorp/errwrap v0.0.0-20141028054710-7554cd9344ce/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
@@ -550,6 +575,7 @@ github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA
github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
+github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4=
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64=
github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ=
@@ -570,6 +596,7 @@ github.com/imdario/mergo v0.3.8/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJ
github.com/imdario/mergo v0.3.10/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
github.com/imdario/mergo v0.3.11/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
+github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM=
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
github.com/j-keck/arping v0.0.0-20160618110441-2cf9dc699c56/go.mod h1:ymszkNOg6tORTn+6F6j+Jc8TOr5osrynvN6ivFWZ2GA=
github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k=
@@ -616,6 +643,7 @@ github.com/lyft/protoc-gen-star v0.5.3/go.mod h1:V0xaHgaf5oCCqmcxYcWiDfTiKsZsRc8
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
github.com/magiconair/properties v1.8.4/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
+github.com/magiconair/properties v1.8.5 h1:b6kJs+EmPFMYGkow9GiUyCyOvIwYetYJ3fSaWak/Gls=
github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
@@ -653,6 +681,7 @@ github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0Qu
github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
github.com/mitchellh/mapstructure v1.3.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
+github.com/mitchellh/mapstructure v1.4.3 h1:OVowDSCllw/YjdLkam3/sm7wEtOy59d8ndGgCcyj8cs=
github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
github.com/mitchellh/osext v0.0.0-20151018003038-5e2d6d41470f/go.mod h1:OkQIRizQZAeMln+1tSwduZz7+Af5oFlKirV/MSYes2A=
github.com/moby/locker v1.0.1/go.mod h1:S7SDdo5zpBK84bzzVlKr2V0hz+7x9hWbYC/kq7oQppc=
@@ -727,6 +756,7 @@ github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FI
github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc=
+github.com/pelletier/go-toml v1.9.4 h1:tjENF6MfZAg8e4ZmZTeWaWiT2vXtsoO6+iuOjFhECwM=
github.com/pelletier/go-toml v1.9.4/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c=
github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU=
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
@@ -735,6 +765,7 @@ github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINE
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI=
+github.com/pkg/sftp v1.13.1/go.mod h1:3HaPG6Dq1ILlpPZRO0HVMrsydcdLt6HRDccSgb87qRg=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
@@ -779,6 +810,7 @@ github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQD
github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
github.com/safchain/ethtool v0.0.0-20190326074333-42ed695e3de8/go.mod h1:Z0q5wiBQGYcxhMZ6gUqHn6pYNLypFAvaL3UvgZLR0U4=
github.com/sagikazarmark/crypt v0.3.0/go.mod h1:uD/D+6UF4SrIR1uGEv7bBNkNqLGqUr43MRiaGWX1Nig=
+github.com/sagikazarmark/crypt v0.4.0/go.mod h1:ALv2SRj7GxYV4HO9elxH9nS6M9gW+xDNxqmyJ6RfDFM=
github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0=
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
github.com/seccomp/libseccomp-golang v0.9.1/go.mod h1:GbW5+tmTXfcxTToHLXlScSlAvWlF4P2Ca7zGrPiEpWo=
@@ -802,14 +834,19 @@ github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTd
github.com/spf13/afero v1.3.3/go.mod h1:5KUK8ByomD5Ti5Artl0RtHeI5pTF7MIDuXL3yY520V4=
github.com/spf13/afero v1.4.1/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
+github.com/spf13/afero v1.8.0 h1:5MmtuhAgYeU6qpa7w7bP0dv6MBYuup0vekhSpSkoq60=
+github.com/spf13/afero v1.8.0/go.mod h1:CtAatgMJh6bJEIs48Ay/FOnkljP3WeGUG0MC1RfAqwo=
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
+github.com/spf13/cast v1.4.1 h1:s0hze+J0196ZfEMTs80N7UlFt0BDuQ7Q+JDnHiMWKdA=
github.com/spf13/cast v1.4.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cobra v0.0.2-0.20171109065643-2da4a54c5cee/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE=
+github.com/spf13/cobra v1.3.0 h1:R7cSvGu+Vv+qX0gW5R/85dx2kmmJT5z5NM8ifdYjdn0=
github.com/spf13/cobra v1.3.0/go.mod h1:BrRVncBjOJa/eUcVVm9CE+oC6as8k+VYr4NY7WCi9V4=
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
+github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk=
github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
github.com/spf13/pflag v1.0.1-0.20171106142849-4c012f6dcd95/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
@@ -820,6 +857,8 @@ github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An
github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE=
github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg=
github.com/spf13/viper v1.10.0/go.mod h1:SoyBPwAtKDzypXNDFKN5kzH7ppppbGZtls1UpIy5AsM=
+github.com/spf13/viper v1.10.1 h1:nuJZuYpG7gTj/XqiUwg8bA0cp1+M2mC3J4g5luUYBKk=
+github.com/spf13/viper v1.10.1/go.mod h1:IGlFPqhNAPKRxohIzWpI5QEy4kuI7tcl5WvR+8qy1rU=
github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980/go.mod h1:AO3tvPzVZ/ayst6UlUKUv6rcPQInYe3IknH3jYhAKu8=
github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8=
github.com/stretchr/objx v0.0.0-20180129172003-8a3f7159479f/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
@@ -834,6 +873,7 @@ github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5
github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY=
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
+github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s=
github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw=
github.com/syndtr/gocapability v0.0.0-20170704070218-db04d3cc01c8/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww=
github.com/syndtr/gocapability v0.0.0-20180916011248-d98352740cb2/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww=
@@ -912,8 +952,14 @@ golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPh
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
+golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
golang.org/x/crypto v0.0.0-20210817164053-32db794688a5 h1:HWj/xjIHfjYU5nVXpTM0s39J9CbLn7Cc5a7IC5rwsMQ=
golang.org/x/crypto v0.0.0-20210817164053-32db794688a5/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
+golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce h1:Roh6XWxHFKrPgC/EQhVubSAGQ6Ozk6IdxHSzt1mR0EI=
+golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
@@ -1006,6 +1052,7 @@ golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy
golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20210813160813-60bc85c4be6d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211209124913-491a49abca63/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211216030914-fe4d6282115f h1:hEYJvxw1lSnWIl8X9ofsYMklzaDs90JI2az5YMd4fPM=
golang.org/x/net v0.0.0-20211216030914-fe4d6282115f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
@@ -1117,6 +1164,7 @@ golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1125,6 +1173,7 @@ golang.org/x/sys v0.0.0-20210324051608-47abb6519492/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210426230700-d19ff857e887/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
@@ -1141,9 +1190,12 @@ golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211205182925-97ca703d548d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220111092808-5a964db01320 h1:0jf+tOCoZ3LyutmCOWpVni1chK4VfFLhRsDK7MhqGRY=
golang.org/x/sys v0.0.0-20220111092808-5a964db01320/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20220114195835-da31bd327af9 h1:XfKQ4OlFl8okEOr5UvAqFRVj8pY/4yfcXrddB8qAbU0=
+golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
@@ -1222,6 +1274,7 @@ golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4f
golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
+golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0=
golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
@@ -1268,6 +1321,7 @@ google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdr
google.golang.org/api v0.59.0/go.mod h1:sT2boj7M9YJxZzgeZqXogmhfmRWDtPzT31xkieUbuZU=
google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I=
google.golang.org/api v0.62.0/go.mod h1:dKmwPCydfsad4qCH08MSdgWjfHOyfpd4VtDGgRFdavw=
+google.golang.org/api v0.63.0/go.mod h1:gs4ij2ffTRXwuzzgJl/56BdwJaA194ijkfn++9tDuPo=
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
@@ -1316,7 +1370,9 @@ google.golang.org/genproto v0.0.0-20201110150050-8816d57aaa9a/go.mod h1:FWY/as6D
google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
+google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
@@ -1408,6 +1464,7 @@ gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc=
gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
gopkg.in/ini.v1 v1.62.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
+gopkg.in/ini.v1 v1.66.2 h1:XfR1dOYubytKy4Shzc2LHrrGhU0lDCfDGG1yLPmpgsI=
gopkg.in/ini.v1 v1.66.2/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k=
gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo=
diff --git a/vendor/github.com/google/go-containerregistry/pkg/authn/keychain.go b/vendor/github.com/google/go-containerregistry/pkg/authn/keychain.go
index f79b7260e855..faf77ee6e511 100644
--- a/vendor/github.com/google/go-containerregistry/pkg/authn/keychain.go
+++ b/vendor/github.com/google/go-containerregistry/pkg/authn/keychain.go
@@ -101,10 +101,8 @@ func (dk *defaultKeychain) Resolve(target Resource) (Authenticator, error) {
}
} else {
f, err := os.Open(filepath.Join(os.Getenv("XDG_RUNTIME_DIR"), "containers/auth.json"))
- if os.IsNotExist(err) {
+ if err != nil {
return Anonymous, nil
- } else if err != nil {
- return nil, err
}
defer f.Close()
cf, err = config.LoadFromReader(f)
diff --git a/vendor/google.golang.org/api/dns/v1/dns-gen.go b/vendor/google.golang.org/api/dns/v1/dns-gen.go
index 73fe95954a69..0ad38c0dd50f 100644
--- a/vendor/google.golang.org/api/dns/v1/dns-gen.go
+++ b/vendor/google.golang.org/api/dns/v1/dns-gen.go
@@ -1899,7 +1899,7 @@ func (c *ChangesCreateCall) Header() http.Header {
func (c *ChangesCreateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2080,7 +2080,7 @@ func (c *ChangesGetCall) Header() http.Header {
func (c *ChangesGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2286,7 +2286,7 @@ func (c *ChangesListCall) Header() http.Header {
func (c *ChangesListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2516,7 +2516,7 @@ func (c *DnsKeysGetCall) Header() http.Header {
func (c *DnsKeysGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2719,7 +2719,7 @@ func (c *DnsKeysListCall) Header() http.Header {
func (c *DnsKeysListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -2928,7 +2928,7 @@ func (c *ManagedZoneOperationsGetCall) Header() http.Header {
func (c *ManagedZoneOperationsGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3127,7 +3127,7 @@ func (c *ManagedZoneOperationsListCall) Header() http.Header {
func (c *ManagedZoneOperationsListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3330,7 +3330,7 @@ func (c *ManagedZonesCreateCall) Header() http.Header {
func (c *ManagedZonesCreateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3488,7 +3488,7 @@ func (c *ManagedZonesDeleteCall) Header() http.Header {
func (c *ManagedZonesDeleteCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3629,7 +3629,7 @@ func (c *ManagedZonesGetCall) Header() http.Header {
func (c *ManagedZonesGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -3814,7 +3814,7 @@ func (c *ManagedZonesListCall) Header() http.Header {
func (c *ManagedZonesListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4003,7 +4003,7 @@ func (c *ManagedZonesPatchCall) Header() http.Header {
func (c *ManagedZonesPatchCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4171,7 +4171,7 @@ func (c *ManagedZonesUpdateCall) Header() http.Header {
func (c *ManagedZonesUpdateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4335,7 +4335,7 @@ func (c *PoliciesCreateCall) Header() http.Header {
func (c *PoliciesCreateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4494,7 +4494,7 @@ func (c *PoliciesDeleteCall) Header() http.Header {
func (c *PoliciesDeleteCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4635,7 +4635,7 @@ func (c *PoliciesGetCall) Header() http.Header {
func (c *PoliciesGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4812,7 +4812,7 @@ func (c *PoliciesListCall) Header() http.Header {
func (c *PoliciesListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -4996,7 +4996,7 @@ func (c *PoliciesPatchCall) Header() http.Header {
func (c *PoliciesPatchCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5164,7 +5164,7 @@ func (c *PoliciesUpdateCall) Header() http.Header {
func (c *PoliciesUpdateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5337,7 +5337,7 @@ func (c *ProjectsGetCall) Header() http.Header {
func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5494,7 +5494,7 @@ func (c *ResourceRecordSetsCreateCall) Header() http.Header {
func (c *ResourceRecordSetsCreateCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5666,7 +5666,7 @@ func (c *ResourceRecordSetsDeleteCall) Header() http.Header {
func (c *ResourceRecordSetsDeleteCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -5857,7 +5857,7 @@ func (c *ResourceRecordSetsGetCall) Header() http.Header {
func (c *ResourceRecordSetsGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -6070,7 +6070,7 @@ func (c *ResourceRecordSetsListCall) Header() http.Header {
func (c *ResourceRecordSetsListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
@@ -6278,7 +6278,7 @@ func (c *ResourceRecordSetsPatchCall) Header() http.Header {
func (c *ResourceRecordSetsPatchCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
- reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211207")
+ reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211212")
for k, v := range c.header_ {
reqHeaders[k] = v
}
diff --git a/vendor/google.golang.org/api/internal/gensupport/resumable.go b/vendor/google.golang.org/api/internal/gensupport/resumable.go
index edc87ec24f63..0fb74606c3aa 100644
--- a/vendor/google.golang.org/api/internal/gensupport/resumable.go
+++ b/vendor/google.golang.org/api/internal/gensupport/resumable.go
@@ -12,32 +12,6 @@ import (
"net/http"
"sync"
"time"
-
- gax "github.com/googleapis/gax-go/v2"
-)
-
-// Backoff is an interface around gax.Backoff's Pause method, allowing tests to provide their
-// own implementation.
-type Backoff interface {
- Pause() time.Duration
-}
-
-// These are declared as global variables so that tests can overwrite them.
-var (
- retryDeadline = 32 * time.Second
- backoff = func() Backoff {
- return &gax.Backoff{Initial: 100 * time.Millisecond}
- }
- // isRetryable is a platform-specific hook, specified in retryable_linux.go
- syscallRetryable func(error) bool = func(err error) bool { return false }
-)
-
-const (
- // statusTooManyRequests is returned by the storage API if the
- // per-project limits have been temporarily exceeded. The request
- // should be retried.
- // https://cloud.google.com/storage/docs/json_api/v1/status-codes#standardcodes
- statusTooManyRequests = 429
)
// ResumableUpload is used by the generated APIs to provide resumable uploads.
@@ -57,6 +31,9 @@ type ResumableUpload struct {
// Callback is an optional function that will be periodically called with the cumulative number of bytes uploaded.
Callback func(int64)
+
+ // Retry optionally configures retries for requests made against the upload.
+ Retry *RetryConfig
}
// Progress returns the number of bytes uploaded at this point.
@@ -176,13 +153,15 @@ func (rx *ResumableUpload) Upload(ctx context.Context) (resp *http.Response, err
}
return resp, nil
}
+ // Configure retryable error criteria.
+ errorFunc := rx.Retry.errorFunc()
// Send all chunks.
for {
var pause time.Duration
- // Each chunk gets its own initialized-at-zero retry.
- bo := backoff()
+ // Each chunk gets its own initialized-at-zero backoff.
+ bo := rx.Retry.backoff()
quitAfter := time.After(retryDeadline)
// Retry loop for a single chunk.
@@ -206,7 +185,7 @@ func (rx *ResumableUpload) Upload(ctx context.Context) (resp *http.Response, err
}
// Check if we should retry the request.
- if !shouldRetry(status, err) {
+ if !errorFunc(status, err) {
break
}
@@ -226,33 +205,3 @@ func (rx *ResumableUpload) Upload(ctx context.Context) (resp *http.Response, err
return prepareReturn(resp, err)
}
}
-
-// shouldRetry indicates whether an error is retryable for the purposes of this
-// package, following guidance from
-// https://cloud.google.com/storage/docs/exponential-backoff .
-func shouldRetry(status int, err error) bool {
- if 500 <= status && status <= 599 {
- return true
- }
- if status == statusTooManyRequests {
- return true
- }
- if err == io.ErrUnexpectedEOF {
- return true
- }
- // Transient network errors should be retried.
- if syscallRetryable(err) {
- return true
- }
- if err, ok := err.(interface{ Temporary() bool }); ok {
- if err.Temporary() {
- return true
- }
- }
- // If Go 1.13 error unwrapping is available, use this to examine wrapped
- // errors.
- if err, ok := err.(interface{ Unwrap() error }); ok {
- return shouldRetry(status, err.Unwrap())
- }
- return false
-}
diff --git a/vendor/google.golang.org/api/internal/gensupport/retry.go b/vendor/google.golang.org/api/internal/gensupport/retry.go
new file mode 100644
index 000000000000..4a4861b1b1a9
--- /dev/null
+++ b/vendor/google.golang.org/api/internal/gensupport/retry.go
@@ -0,0 +1,106 @@
+// Copyright 2021 Google LLC.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package gensupport
+
+import (
+ "io"
+ "time"
+
+ "github.com/googleapis/gax-go/v2"
+ "google.golang.org/api/googleapi"
+)
+
+// Backoff is an interface around gax.Backoff's Pause method, allowing tests to provide their
+// own implementation.
+type Backoff interface {
+ Pause() time.Duration
+}
+
+// These are declared as global variables so that tests can overwrite them.
+var (
+ // Per-chunk deadline for resumable uploads.
+ retryDeadline = 32 * time.Second
+ // Default backoff timer.
+ backoff = func() Backoff {
+ return &gax.Backoff{Initial: 100 * time.Millisecond}
+ }
+ // syscallRetryable is a platform-specific hook, specified in retryable_linux.go
+ syscallRetryable func(error) bool = func(err error) bool { return false }
+)
+
+const (
+ // statusTooManyRequests is returned by the storage API if the
+ // per-project limits have been temporarily exceeded. The request
+ // should be retried.
+ // https://cloud.google.com/storage/docs/json_api/v1/status-codes#standardcodes
+ statusTooManyRequests = 429
+)
+
+// shouldRetry indicates whether an error is retryable for the purposes of this
+// package, unless a ShouldRetry func is specified by the RetryConfig instead.
+// It follows guidance from
+// https://cloud.google.com/storage/docs/exponential-backoff .
+func shouldRetry(status int, err error) bool {
+ if 500 <= status && status <= 599 {
+ return true
+ }
+ if status == statusTooManyRequests {
+ return true
+ }
+ if err == io.ErrUnexpectedEOF {
+ return true
+ }
+ // Transient network errors should be retried.
+ if syscallRetryable(err) {
+ return true
+ }
+ if err, ok := err.(interface{ Temporary() bool }); ok {
+ if err.Temporary() {
+ return true
+ }
+ }
+ // If Go 1.13 error unwrapping is available, use this to examine wrapped
+ // errors.
+ if err, ok := err.(interface{ Unwrap() error }); ok {
+ return shouldRetry(status, err.Unwrap())
+ }
+ return false
+}
+
+// RetryConfig allows configuration of backoff timing and retryable errors.
+type RetryConfig struct {
+ Backoff *gax.Backoff
+ ShouldRetry func(err error) bool
+}
+
+// Get a new backoff object based on the configured values.
+func (r *RetryConfig) backoff() Backoff {
+ if r == nil || r.Backoff == nil {
+ return backoff()
+ }
+ return &gax.Backoff{
+ Initial: r.Backoff.Initial,
+ Max: r.Backoff.Max,
+ Multiplier: r.Backoff.Multiplier,
+ }
+}
+
+// This is kind of hacky; it is necessary because ShouldRetry expects to
+// handle HTTP errors via googleapi.Error, but the error has not yet been
+// wrapped with a googleapi.Error at this layer, and the ErrorFunc type
+// in the manual layer does not pass in a status explicitly as it does
+// here. So, we must wrap error status codes in a googleapi.Error so that
+// ShouldRetry can parse this correctly.
+func (r *RetryConfig) errorFunc() func(status int, err error) bool {
+ if r == nil || r.ShouldRetry == nil {
+ return shouldRetry
+ }
+ return func(status int, err error) bool {
+ if status >= 400 {
+ return r.ShouldRetry(&googleapi.Error{Code: status})
+ }
+ return r.ShouldRetry(err)
+ }
+}
diff --git a/vendor/google.golang.org/api/internal/gensupport/send.go b/vendor/google.golang.org/api/internal/gensupport/send.go
index 276d6f6963af..dab64aef367b 100644
--- a/vendor/google.golang.org/api/internal/gensupport/send.go
+++ b/vendor/google.golang.org/api/internal/gensupport/send.go
@@ -10,6 +10,8 @@ import (
"errors"
"net/http"
"time"
+
+ "github.com/googleapis/gax-go/v2"
)
// SendRequest sends a single HTTP request using the given client.
@@ -50,7 +52,7 @@ func send(ctx context.Context, client *http.Client, req *http.Request) (*http.Re
// If ctx is non-nil, it calls all hooks, then sends the request with
// req.WithContext, then calls any functions returned by the hooks in
// reverse order.
-func SendRequestWithRetry(ctx context.Context, client *http.Client, req *http.Request) (*http.Response, error) {
+func SendRequestWithRetry(ctx context.Context, client *http.Client, req *http.Request, retry *RetryConfig) (*http.Response, error) {
// Disallow Accept-Encoding because it interferes with the automatic gzip handling
// done by the default http.Transport. See https://github.com/google/google-api-go-client/issues/219.
if _, ok := req.Header["Accept-Encoding"]; ok {
@@ -59,10 +61,10 @@ func SendRequestWithRetry(ctx context.Context, client *http.Client, req *http.Re
if ctx == nil {
return client.Do(req)
}
- return sendAndRetry(ctx, client, req)
+ return sendAndRetry(ctx, client, req, retry)
}
-func sendAndRetry(ctx context.Context, client *http.Client, req *http.Request) (*http.Response, error) {
+func sendAndRetry(ctx context.Context, client *http.Client, req *http.Request, retry *RetryConfig) (*http.Response, error) {
if client == nil {
client = http.DefaultClient
}
@@ -72,7 +74,18 @@ func sendAndRetry(ctx context.Context, client *http.Client, req *http.Request) (
// Loop to retry the request, up to the context deadline.
var pause time.Duration
- bo := backoff()
+ var bo Backoff
+ if retry != nil && retry.Backoff != nil {
+ bo = &gax.Backoff{
+ Initial: retry.Backoff.Initial,
+ Max: retry.Backoff.Max,
+ Multiplier: retry.Backoff.Multiplier,
+ }
+ } else {
+ bo = backoff()
+ }
+
+ var errorFunc = retry.errorFunc()
for {
select {
@@ -96,7 +109,7 @@ func sendAndRetry(ctx context.Context, client *http.Client, req *http.Request) (
// Check if we can retry the request. A retry can only be done if the error
// is retryable and the request body can be re-created using GetBody (this
// will not be possible if the body was unbuffered).
- if req.GetBody == nil || !shouldRetry(status, err) {
+ if req.GetBody == nil || !errorFunc(status, err) {
break
}
var errBody error
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 7e3c61aeb1d3..0d510d3f4148 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -6,19 +6,19 @@ contrib.go.opencensus.io/exporter/ocagent
contrib.go.opencensus.io/exporter/prometheus
# contrib.go.opencensus.io/exporter/zipkin v0.1.2
contrib.go.opencensus.io/exporter/zipkin
-# github.com/Azure/azure-sdk-for-go v46.4.0+incompatible
+# github.com/Azure/azure-sdk-for-go v61.2.0+incompatible
github.com/Azure/azure-sdk-for-go/services/preview/containerregistry/runtime/2019-08-15-preview/containerregistry
github.com/Azure/azure-sdk-for-go/version
# github.com/Azure/go-autorest v14.2.0+incompatible
github.com/Azure/go-autorest
-# github.com/Azure/go-autorest/autorest v0.11.18
+# github.com/Azure/go-autorest/autorest v0.11.24
github.com/Azure/go-autorest/autorest
github.com/Azure/go-autorest/autorest/azure
-# github.com/Azure/go-autorest/autorest/adal v0.9.13
+# github.com/Azure/go-autorest/autorest/adal v0.9.18
github.com/Azure/go-autorest/autorest/adal
-# github.com/Azure/go-autorest/autorest/azure/auth v0.5.2
+# github.com/Azure/go-autorest/autorest/azure/auth v0.5.11
github.com/Azure/go-autorest/autorest/azure/auth
-# github.com/Azure/go-autorest/autorest/azure/cli v0.4.1
+# github.com/Azure/go-autorest/autorest/azure/cli v0.4.5
github.com/Azure/go-autorest/autorest/azure/cli
# github.com/Azure/go-autorest/autorest/date v0.3.0
github.com/Azure/go-autorest/autorest/date
@@ -129,7 +129,7 @@ github.com/census-instrumentation/opencensus-proto/gen-go/resource/v1
github.com/census-instrumentation/opencensus-proto/gen-go/trace/v1
# github.com/cespare/xxhash/v2 v2.1.2
github.com/cespare/xxhash/v2
-# github.com/chrismellard/docker-credential-acr-env v0.0.0-20210203204924-09e2b5a8ac86
+# github.com/chrismellard/docker-credential-acr-env v0.0.0-20220119192733-fe33c00cee21
github.com/chrismellard/docker-credential-acr-env/pkg/credhelper
github.com/chrismellard/docker-credential-acr-env/pkg/registry
github.com/chrismellard/docker-credential-acr-env/pkg/token
@@ -139,7 +139,7 @@ github.com/containerd/stargz-snapshotter/estargz/errorutil
# github.com/davecgh/go-spew v1.1.1
## explicit
github.com/davecgh/go-spew/spew
-# github.com/dimchansky/utfbom v1.1.0
+# github.com/dimchansky/utfbom v1.1.1
github.com/dimchansky/utfbom
# github.com/docker/cli v20.10.12+incompatible
github.com/docker/cli/cli/config
@@ -160,8 +160,6 @@ github.com/emicklei/go-restful/log
github.com/evanphx/json-patch
# github.com/evanphx/json-patch/v5 v5.6.0
github.com/evanphx/json-patch/v5
-# github.com/form3tech-oss/jwt-go v3.2.3+incompatible
-github.com/form3tech-oss/jwt-go
# github.com/go-kit/log v0.1.0
github.com/go-kit/log
github.com/go-kit/log/level
@@ -181,6 +179,8 @@ github.com/gobuffalo/flect
## explicit
github.com/gogo/protobuf/proto
github.com/gogo/protobuf/sortkeys
+# github.com/golang-jwt/jwt/v4 v4.2.0
+github.com/golang-jwt/jwt/v4
# github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da
github.com/golang/groupcache/lru
# github.com/golang/protobuf v1.5.2
@@ -201,7 +201,7 @@ github.com/google/go-cmp/cmp/internal/diff
github.com/google/go-cmp/cmp/internal/flags
github.com/google/go-cmp/cmp/internal/function
github.com/google/go-cmp/cmp/internal/value
-# github.com/google/go-containerregistry v0.8.1-0.20220114205711-890d5b362eb8
+# github.com/google/go-containerregistry v0.8.1-0.20220120151853-ac864e57b117
## explicit
github.com/google/go-containerregistry/internal/and
github.com/google/go-containerregistry/internal/estargz
@@ -225,7 +225,7 @@ github.com/google/go-containerregistry/pkg/v1/remote/transport
github.com/google/go-containerregistry/pkg/v1/stream
github.com/google/go-containerregistry/pkg/v1/tarball
github.com/google/go-containerregistry/pkg/v1/types
-# github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220114205711-890d5b362eb8
+# github.com/google/go-containerregistry/pkg/authn/k8schain v0.0.0-20220120151853-ac864e57b117
## explicit
github.com/google/go-containerregistry/pkg/authn/k8schain
# github.com/google/go-containerregistry/pkg/authn/kubernetes v0.0.0-20220110151055-a61fd0a8e2bb
@@ -384,7 +384,7 @@ go.uber.org/zap/internal/exit
go.uber.org/zap/internal/ztest
go.uber.org/zap/zapcore
go.uber.org/zap/zaptest
-# golang.org/x/crypto v0.0.0-20210920023735-84f357641f63
+# golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce
golang.org/x/crypto/pkcs12
golang.org/x/crypto/pkcs12/internal/rc2
# golang.org/x/mod v0.5.1
@@ -415,7 +415,7 @@ golang.org/x/oauth2/jwt
## explicit
golang.org/x/sync/errgroup
golang.org/x/sync/semaphore
-# golang.org/x/sys v0.0.0-20220111092808-5a964db01320
+# golang.org/x/sys v0.0.0-20220114195835-da31bd327af9
golang.org/x/sys/execabs
golang.org/x/sys/internal/unsafeheader
golang.org/x/sys/plan9
@@ -455,7 +455,7 @@ golang.org/x/xerrors
golang.org/x/xerrors/internal
# gomodules.xyz/jsonpatch/v2 v2.2.0
gomodules.xyz/jsonpatch/v2
-# google.golang.org/api v0.62.0
+# google.golang.org/api v0.63.0
## explicit
google.golang.org/api/dns/v1
google.golang.org/api/googleapi
From e648a2fe0b41c44835ba9ec3d85d4664a0abcb74 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 20 Jan 2022 20:34:03 -0800
Subject: [PATCH 102/733] Update net-contour nightly (#12534)
bumping knative.dev/net-contour de98775...a971f5d:
> a971f5d upgrade to latest dependencies (# 707)
> eab6d91 Bump k8s version to 1.23.0 in kind (# 708)
> d1b7fcc Update actions (# 704)
> 7f4571a upgrade to latest dependencies (# 705)
Signed-off-by: Knative Automation
---
third_party/contour-latest/net-contour.yaml | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/third_party/contour-latest/net-contour.yaml b/third_party/contour-latest/net-contour.yaml
index 1e567706f74e..d687f1ffedc0 100644
--- a/third_party/contour-latest/net-contour.yaml
+++ b/third_party/contour-latest/net-contour.yaml
@@ -8,7 +8,7 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220117-de98775a"
+ app.kubernetes.io/version: "20220120-a971f5d6"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["projectcontour.io"]
@@ -38,8 +38,8 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220117-de98775a"
- serving.knative.dev/release: "v20220117-de98775a"
+ app.kubernetes.io/version: "20220120-a971f5d6"
+ serving.knative.dev/release: "v20220120-a971f5d6"
data:
_example: |
################################
@@ -105,14 +105,14 @@ spec:
app: net-contour-controller
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220117-de98775a"
+ app.kubernetes.io/version: "20220120-a971f5d6"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:5f446852a99dd5ea82399e21804c1fd7e9513be211571832c5465660c1526b73
+ image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:a02595e592b48534136cd9f4001b2a34e56de149a6144aeaede850110f7f8d41
resources:
requests:
cpu: 40m
From ab339400f3a14962ad59b9449b72015368ed1c74 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Fri, 21 Jan 2022 07:23:05 -0800
Subject: [PATCH 103/733] Update net-contour nightly (#12542)
bumping knative.dev/net-contour a971f5d...a248e38:
> a248e38 Update community files (# 711)
> 169ded4 drop dead/unused symlink (# 706)
> d5cb481 upgrade to latest dependencies (# 710)
Signed-off-by: Knative Automation
---
third_party/contour-latest/net-contour.yaml | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/third_party/contour-latest/net-contour.yaml b/third_party/contour-latest/net-contour.yaml
index d687f1ffedc0..b1a8f1846079 100644
--- a/third_party/contour-latest/net-contour.yaml
+++ b/third_party/contour-latest/net-contour.yaml
@@ -8,7 +8,7 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220120-a971f5d6"
+ app.kubernetes.io/version: "20220121-a248e38c"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["projectcontour.io"]
@@ -38,8 +38,8 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220120-a971f5d6"
- serving.knative.dev/release: "v20220120-a971f5d6"
+ app.kubernetes.io/version: "20220121-a248e38c"
+ serving.knative.dev/release: "v20220121-a248e38c"
data:
_example: |
################################
@@ -105,14 +105,14 @@ spec:
app: net-contour-controller
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220120-a971f5d6"
+ app.kubernetes.io/version: "20220121-a248e38c"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:a02595e592b48534136cd9f4001b2a34e56de149a6144aeaede850110f7f8d41
+ image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:28215f178dfac25985ecc6c54b41ad582c754f61f62b94a3c4eafed799423c30
resources:
requests:
cpu: 40m
From e0b028e7fbb9547c997a5a844dd31685eedbcc1a Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Fri, 21 Jan 2022 09:12:04 -0800
Subject: [PATCH 104/733] upgrade to latest dependencies (#12525)
bumping knative.dev/hack 59b0cf1...9b2ed84:
> 9b2ed84 Update community files (# 139)
bumping knative.dev/networking 52fb6ee...ec78554:
> ec78554 Add transport option (# 606)
> c7164d4 upgrade to latest dependencies (# 604)
> 37ab2ef upgrade to latest dependencies (# 603)
> 075f9b9 Update community files (# 602)
bumping knative.dev/caching 9df2c0c...0c1cc09:
> 0c1cc09 upgrade to latest dependencies (# 595)
> 4ececed upgrade to latest dependencies (# 594)
> cef45ba Update community files (# 593)
bumping knative.dev/pkg 0a429cb...77555ea:
> 77555ea upgrade to latest dependencies (# 2398)
> 768f44f bump our min version to 1.21 (# 2397)
> e989c22 Update community files (# 2393)
Signed-off-by: Knative Automation
---
go.mod | 8 ++++----
go.sum | 17 ++++++++---------
vendor/knative.dev/pkg/version/version.go | 2 +-
vendor/modules.txt | 8 ++++----
4 files changed, 17 insertions(+), 18 deletions(-)
diff --git a/go.mod b/go.mod
index 6bdfd11938f5..e558e0f9fba9 100644
--- a/go.mod
+++ b/go.mod
@@ -36,9 +36,9 @@ require (
k8s.io/code-generator v0.22.5
k8s.io/klog v1.0.0 // indirect
k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65
- knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931
- knative.dev/hack v0.0.0-20220111151514-59b0cf17578e
- knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9
- knative.dev/pkg v0.0.0-20220114141842-0a429cba1c73
+ knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4
+ knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30
+ knative.dev/networking v0.0.0-20220120043934-ec785540a732
+ knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4
sigs.k8s.io/yaml v1.3.0
)
diff --git a/go.sum b/go.sum
index a194ca0e3ebf..7fa32211131f 100644
--- a/go.sum
+++ b/go.sum
@@ -1781,15 +1781,14 @@ k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b h1:wxEMGetGMur3J1xuGLQY7GEQYg9bZxKn3tKo5k/eYcs=
k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
-knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931 h1:hyZfmjpW2ZNR2cAJUWaDagcDdcyupozf+7BpN0ApHt8=
-knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931/go.mod h1:kHPJyq2W2ADNAwB6lmmJcleEZfNWioIL5yEs/p5WHU0=
-knative.dev/hack v0.0.0-20220111151514-59b0cf17578e h1:tESsFI1iMD2Al+6FZueFN9CddxJ8Fa2cd9KmyNINe3w=
-knative.dev/hack v0.0.0-20220111151514-59b0cf17578e/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9 h1:wX0XDJhZelDUO5IwENO32gEwwB1pYrRyuRq42z8z3GI=
-knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9/go.mod h1:h4JrHof14QSggAnthL3DPFw1cieenumKDaT+wg0EPmE=
-knative.dev/pkg v0.0.0-20220113045912-c0e1594c2fb1/go.mod h1:X5B0/SR3tzOioS2WQtS9uJTO71M52qcrDkWQ5wtyLVc=
-knative.dev/pkg v0.0.0-20220114141842-0a429cba1c73 h1:O2rdhNu49InR/IciU06z+vtTa/ygtFFBGHBdZPcGMdE=
-knative.dev/pkg v0.0.0-20220114141842-0a429cba1c73/go.mod h1:X5B0/SR3tzOioS2WQtS9uJTO71M52qcrDkWQ5wtyLVc=
+knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4 h1:CXojQdgLKqvxtmVBuGMURUjgnfPRSUeT2d/veVJL370=
+knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4/go.mod h1:OHsK3XaWmdi2/mPaNBiX8LbefbtM6TptnT90eVbYGSA=
+knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30 h1:UkNpCWCMM5C4AeQ8aTrPTuR/6OeARiqk+LEQ6tuMP7c=
+knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
+knative.dev/networking v0.0.0-20220120043934-ec785540a732 h1:fUUb5NWfYm8TQkhv1uFYlEn91YNKp+E4BD7ax7WYHW0=
+knative.dev/networking v0.0.0-20220120043934-ec785540a732/go.mod h1:6cKBV/h/vIQWCPOkds/RvzUmMR8Vz6Dks2NWb0+3xks=
+knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4 h1:b9aXVrcfM/ajjHE/lGvlJOHZNAR5FF2TOTLWG7eMhzQ=
+knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4/go.mod h1:etVT7Tm8pSDf4RKhGk4r7j/hj3dNBpvT7bO6a6wpahs=
pgregory.net/rapid v0.3.3 h1:jCjBsY4ln4Atz78QoBWxUEvAHaFyNDQg9+WU62aCn1U=
pgregory.net/rapid v0.3.3/go.mod h1:UYpPVyjFHzYBGHIxLFoupi8vwk6rXNzRY9OMvVxFIOU=
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
diff --git a/vendor/knative.dev/pkg/version/version.go b/vendor/knative.dev/pkg/version/version.go
index 56b7ae958255..b304f2b0a5e0 100644
--- a/vendor/knative.dev/pkg/version/version.go
+++ b/vendor/knative.dev/pkg/version/version.go
@@ -33,7 +33,7 @@ const (
// NOTE: If you are changing this line, please also update the minimum kubernetes
// version listed here:
// https://github.com/knative/docs/blob/mkdocs/docs/snippets/prerequisites.md
- defaultMinimumVersion = "v1.20.0"
+ defaultMinimumVersion = "v1.21.0"
)
func getMinimumVersion() string {
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 0d510d3f4148..db10010cbb68 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -1020,7 +1020,7 @@ k8s.io/utils/buffer
k8s.io/utils/integer
k8s.io/utils/pointer
k8s.io/utils/trace
-# knative.dev/caching v0.0.0-20220113145613-9df2c0c8a931
+# knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4
## explicit
knative.dev/caching/config
knative.dev/caching/pkg/apis/caching
@@ -1041,11 +1041,11 @@ knative.dev/caching/pkg/client/injection/informers/caching/v1alpha1/image/fake
knative.dev/caching/pkg/client/injection/informers/factory
knative.dev/caching/pkg/client/injection/informers/factory/fake
knative.dev/caching/pkg/client/listers/caching/v1alpha1
-# knative.dev/hack v0.0.0-20220111151514-59b0cf17578e
+# knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30
## explicit
knative.dev/hack
knative.dev/hack/shell
-# knative.dev/networking v0.0.0-20220117015928-52fb6ee37bf9
+# knative.dev/networking v0.0.0-20220120043934-ec785540a732
## explicit
knative.dev/networking/config
knative.dev/networking/pkg
@@ -1075,7 +1075,7 @@ knative.dev/networking/pkg/client/injection/reconciler/networking/v1alpha1/serve
knative.dev/networking/pkg/client/listers/networking/v1alpha1
knative.dev/networking/pkg/ingress
knative.dev/networking/pkg/prober
-# knative.dev/pkg v0.0.0-20220114141842-0a429cba1c73
+# knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4
## explicit
knative.dev/pkg/apiextensions/storageversion
knative.dev/pkg/apiextensions/storageversion/cmd/migrate
From a71162c8c221003f2ddb8e63f87f9fbf4432b6c4 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Fri, 21 Jan 2022 09:12:11 -0800
Subject: [PATCH 105/733] Update net-istio nightly (#12535)
bumping knative.dev/net-istio 957190f...3fc0d95:
> 3fc0d95 upgrade to latest dependencies (# 853)
> bd4fd44 Bump k8s version to 1.23.0 in kind (# 849)
> 5b0ea5d upgrade to latest dependencies (# 845)
> 08a7462 Update actions (# 837)
Signed-off-by: Knative Automation
---
third_party/istio-latest/net-istio.yaml | 70 ++++++++++++-------------
1 file changed, 35 insertions(+), 35 deletions(-)
diff --git a/third_party/istio-latest/net-istio.yaml b/third_party/istio-latest/net-istio.yaml
index d84e8c75751b..0e65ec8641f7 100644
--- a/third_party/istio-latest/net-istio.yaml
+++ b/third_party/istio-latest/net-istio.yaml
@@ -1,4 +1,4 @@
-# Generated when HEAD was 957190f981391911d2a660999c3d0af35f1f43ad
+# Generated when HEAD was 3fc0d95f42423c171b40496f9c21ed351f35840f
#
# Copyright 2019 The Knative Authors
#
@@ -22,8 +22,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
serving.knative.dev/controller: "true"
networking.knative.dev/ingress-provider: istio
rules:
@@ -55,8 +55,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -95,8 +95,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -117,8 +117,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -153,8 +153,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
data:
_example: |
@@ -220,8 +220,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -239,8 +239,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -258,8 +258,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -292,8 +292,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -311,15 +311,15 @@ spec:
app: net-istio-controller
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:be615cbd54949ea98a62567e159de15c2e8c15036d5ebc8c1218373cc0bc1b75
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:b5b229ded2ee86dbf35866f529802bda2172b9463ed86cd541ebed4ea41f73a8
resources:
requests:
cpu: 30m
@@ -378,8 +378,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -395,15 +395,15 @@ spec:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:6b381296aad9e6da52291d3adac0563b32d0cf9e977f171c5e18b160ec7a6a07
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:411950434c0230aa5df735accc87bd4e282d1af3b654909548e4dd4b4426db8f
resources:
requests:
cpu: 20m
@@ -458,8 +458,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
---
@@ -486,8 +486,8 @@ metadata:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
spec:
ports:
@@ -526,8 +526,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -566,8 +566,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220118-957190f9"
- serving.knative.dev/release: "v20220118-957190f9"
+ app.kubernetes.io/version: "20220121-3fc0d95f"
+ serving.knative.dev/release: "v20220121-3fc0d95f"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
From 3785e9f6beea487bd70e9a90c08d8956819bdc82 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Fri, 21 Jan 2022 10:14:05 -0800
Subject: [PATCH 106/733] Update net-kourier nightly (#12543)
bumping knative.dev/net-kourier bdac0fe...bea86d6:
> bea86d6 upgrade to latest dependencies (# 757)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index 52d817f93659..5166e369925b 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
+ serving.knative.dev/release: "v20220121-bea86d68"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:5cbc4cd41dff8381de7d9497b865af7d416ef5e6057547b5db07aa8467c0375a
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:d481354fff8bf89257d4d6a61afbf37220c25b9fac8fb6b3c1cd65e2df317e8a
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220120-bdac0fe7"
+ app.kubernetes.io/version: "20220121-bea86d68"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-bdac0fe7"
+ serving.knative.dev/release: "v20220121-bea86d68"
spec:
ports:
- name: http2
From 65a92df090d347165e23db264cf39142a3a6ef7c Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Fri, 21 Jan 2022 11:20:04 -0800
Subject: [PATCH 107/733] Update net-gateway-api nightly (#12541)
bumping knative.dev/net-gateway-api 1b2ff08...a6f4141:
> a6f4141 upgrade to latest dependencies (# 237)
Signed-off-by: Knative Automation
---
third_party/gateway-api-latest/istio-gateway.yaml | 2 +-
third_party/gateway-api-latest/net-gateway-api.yaml | 12 ++++++------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/third_party/gateway-api-latest/istio-gateway.yaml b/third_party/gateway-api-latest/istio-gateway.yaml
index 955da1aabc8e..62e1191a13e3 100644
--- a/third_party/gateway-api-latest/istio-gateway.yaml
+++ b/third_party/gateway-api-latest/istio-gateway.yaml
@@ -20,7 +20,7 @@ metadata:
name: knative-local-gateway
namespace: istio-system
labels:
- serving.knative.dev/release: "v20220119-1b2ff089"
+ serving.knative.dev/release: "v20220121-a6f41410"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
diff --git a/third_party/gateway-api-latest/net-gateway-api.yaml b/third_party/gateway-api-latest/net-gateway-api.yaml
index 5db599e320ca..caf16a7afaef 100644
--- a/third_party/gateway-api-latest/net-gateway-api.yaml
+++ b/third_party/gateway-api-latest/net-gateway-api.yaml
@@ -2125,7 +2125,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-admin
labels:
- serving.knative.dev/release: "v20220119-1b2ff089"
+ serving.knative.dev/release: "v20220121-a6f41410"
aggregationRule:
clusterRoleSelectors:
- matchLabels:
@@ -2137,7 +2137,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-core
labels:
- serving.knative.dev/release: "v20220119-1b2ff089"
+ serving.knative.dev/release: "v20220121-a6f41410"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["networking.x-k8s.io"]
@@ -2165,7 +2165,7 @@ metadata:
name: config-gateway
namespace: knative-serving
labels:
- serving.knative.dev/release: "v20220119-1b2ff089"
+ serving.knative.dev/release: "v20220121-a6f41410"
data:
_example: |
################################
@@ -2219,9 +2219,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: net-gateway-api
app.kubernetes.io/component: net-gateway-api
- app.kubernetes.io/version: "20220119-1b2ff089"
+ app.kubernetes.io/version: "20220121-a6f41410"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220119-1b2ff089"
+ serving.knative.dev/release: "v20220121-a6f41410"
spec:
replicas: 1
selector:
@@ -2247,7 +2247,7 @@ spec:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:70d1ddb29e13fe1802529bd9a4f187a92a174c438fef77906810dab72953b713
+ image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:09de6cff3c60cb561b4005a87f79a881bf09668b76b94f3c9b54675c46134b36
resources:
requests:
cpu: 100m
From ff545005beabd30a1eb584e3e3573e2ab07bc581 Mon Sep 17 00:00:00 2001
From: Martin Gencur
Date: Fri, 21 Jan 2022 21:23:04 +0100
Subject: [PATCH 108/733] Upgrade tests - properly clean up resources (#12395)
* Ensure service cleanup in upgrade tests
* clean the services within Golang test, either in post-upgrade or
post-downgrade test if it is executed
* re-use code from updateService function in servicePostDowngrade test
* Fix service names in ScaleToZero post upgrade test
---
test/upgrade/postdowngrade.go | 54 ++++++-----------------------------
test/upgrade/postupgrade.go | 43 +++++++++++++++++-----------
test/upgrade/preupgrade.go | 30 ++++---------------
test/upgrade/upgrade.go | 31 ++++++++++++++------
4 files changed, 63 insertions(+), 95 deletions(-)
diff --git a/test/upgrade/postdowngrade.go b/test/upgrade/postdowngrade.go
index 61a8aee8e81f..a516200f3cdc 100644
--- a/test/upgrade/postdowngrade.go
+++ b/test/upgrade/postdowngrade.go
@@ -17,18 +17,11 @@ limitations under the License.
package upgrade
import (
- "context"
"testing"
- metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
- ptest "knative.dev/pkg/test"
-
pkgupgrade "knative.dev/pkg/test/upgrade"
- serviceresourcenames "knative.dev/serving/pkg/reconciler/service/resources/names"
- rtesting "knative.dev/serving/pkg/testing/v1"
"knative.dev/serving/test"
"knative.dev/serving/test/e2e"
- v1test "knative.dev/serving/test/v1"
)
// ServingPostDowngradeTests is an umbrella function for grouping all Serving post-downgrade tests.
@@ -48,49 +41,18 @@ func ServicePostDowngradeTest() pkgupgrade.Operation {
func servicePostDowngrade(t *testing.T) {
t.Parallel()
- clients := e2e.Setup(t)
-
- names := test.ResourceNames{
- Service: serviceName,
- }
-
- t.Logf("Getting service %q", names.Service)
- svc, err := clients.ServingClient.Services.Get(context.Background(), names.Service, metav1.GetOptions{})
- if err != nil {
- t.Fatal("Failed to get Service:", err)
- }
- names.Route = serviceresourcenames.Route(svc)
- names.Config = serviceresourcenames.Configuration(svc)
- names.Revision = svc.Status.LatestCreatedRevisionName
-
- url := svc.Status.URL
-
- t.Log("Check that we can hit the old service and get the old response.")
- assertServiceResourcesUpdated(t, clients, names, url.URL(), test.PizzaPlanetText2)
-
- t.Log("Updating the Service to use a different image")
- newImage := ptest.ImagePath(test.PizzaPlanet1)
- if _, err := v1test.PatchService(t, clients, svc, rtesting.WithServiceImage(newImage)); err != nil {
- t.Fatalf("Patch update for Service %s with new image %s failed: %v", names.Service, newImage, err)
- }
-
- t.Log("Since the Service was updated a new Revision will be created and the Service will be updated")
- revisionName, err := v1test.WaitForServiceLatestRevision(clients, names)
- if err != nil {
- t.Fatalf("Service %s was not updated with the Revision for image %s: %v", names.Service, test.PizzaPlanet1, err)
- }
- names.Revision = revisionName
-
- t.Log("When the Service reports as Ready, everything should be ready.")
- if err := v1test.WaitForServiceState(clients.ServingClient, names.Service, v1test.IsServiceReady, "ServiceIsReady"); err != nil {
- t.Fatalf("The Service %s was not marked as Ready to serve traffic to Revision %s: %v", names.Service, names.Revision, err)
- }
- assertServiceResourcesUpdated(t, clients, names, url.URL(), test.PizzaPlanetText1)
+ test.EnsureTearDown(t, e2e.Setup(t), &upgradeServiceNames)
+ updateServiceAndCheck(t,
+ upgradeServiceNames.Service,
+ test.PizzaPlanet1,
+ test.PizzaPlanetText2,
+ test.PizzaPlanetText1,
+ )
}
// CreateNewServicePostDowngradeTest verifies creating a new service after downgrade.
func CreateNewServicePostDowngradeTest() pkgupgrade.Operation {
return pkgupgrade.NewOperation("CreateNewServicePostDowngradeTest", func(c pkgupgrade.Context) {
- createNewService(postDowngradeServiceName, c.T)
+ createNewService("pizzaplanet-post-downgrade-service", c.T)
})
}
diff --git a/test/upgrade/postupgrade.go b/test/upgrade/postupgrade.go
index cc26411a6526..299e9a4c2370 100644
--- a/test/upgrade/postupgrade.go
+++ b/test/upgrade/postupgrade.go
@@ -58,18 +58,22 @@ func servicePostUpgrade(t *testing.T) {
// Before updating the service, the route and configuration objects should
// not be updated just because there has been an upgrade.
- if hasGeneration, err := configHasGeneration(clients, serviceName, 1); err != nil {
+ if hasGeneration, err := configHasGeneration(clients, upgradeServiceNames.Service, 1); err != nil {
t.Fatal("Error comparing Configuration generation", err)
} else if !hasGeneration {
t.Fatal("Configuration is updated after an upgrade.")
}
- if hasGeneration, err := routeHasGeneration(clients, serviceName, 1); err != nil {
+ if hasGeneration, err := routeHasGeneration(clients, upgradeServiceNames.Service, 1); err != nil {
t.Fatal("Error comparing Route generation", err)
} else if !hasGeneration {
t.Fatal("Route is updated after an upgrade.")
}
-
- updateService(serviceName, t)
+ updateServiceAndCheck(t,
+ upgradeServiceNames.Service,
+ test.PizzaPlanet2,
+ test.PizzaPlanetText1,
+ test.PizzaPlanetText2,
+ )
}
func configHasGeneration(clients *test.Clients, serviceName string, generation int) (bool, error) {
@@ -91,7 +95,13 @@ func routeHasGeneration(clients *test.Clients, serviceName string, generation in
// ServicePostUpgradeFromScaleToZeroTest verifies a scaled-to-zero service after upgrade.
func ServicePostUpgradeFromScaleToZeroTest() pkgupgrade.Operation {
return pkgupgrade.NewOperation("PostUpgradeFromScaleToZeroTest", func(c pkgupgrade.Context) {
- updateService(scaleToZeroServiceName, c.T)
+ test.EnsureTearDown(c.T, e2e.Setup(c.T), &scaleToZeroServiceNames)
+ updateServiceAndCheck(c.T,
+ scaleToZeroServiceNames.Service,
+ test.PizzaPlanet2,
+ test.PizzaPlanetText1,
+ test.PizzaPlanetText2,
+ )
})
}
@@ -106,11 +116,9 @@ func BYORevisionPostUpgradeTest() pkgupgrade.Operation {
func bYORevisionPostUpgrade(t *testing.T) {
t.Parallel()
clients := e2e.Setup(t)
- names := test.ResourceNames{
- Service: byoServiceName,
- }
+ test.EnsureTearDown(t, clients, &byoServiceNames)
- if _, err := v1test.PatchServiceRouteSpec(t, clients, names, v1.RouteSpec{
+ if _, err := v1test.PatchServiceRouteSpec(t, clients, byoServiceNames, v1.RouteSpec{
Traffic: []v1.TrafficTarget{{
Tag: "example-tag",
RevisionName: byoRevName,
@@ -121,7 +129,7 @@ func bYORevisionPostUpgrade(t *testing.T) {
}
}
-func updateService(serviceName string, t *testing.T) {
+func updateServiceAndCheck(t *testing.T, serviceName, toImage, textBeforeUpdate, textAfterUpdate string) {
t.Helper()
clients := e2e.Setup(t)
names := test.ResourceNames{
@@ -140,10 +148,10 @@ func updateService(serviceName string, t *testing.T) {
routeURL := svc.Status.URL.URL()
t.Log("Check that we can hit the old service and get the old response.")
- assertServiceResourcesUpdated(t, clients, names, routeURL, test.PizzaPlanetText1)
+ assertServiceResourcesUpdated(t, clients, names, routeURL, textBeforeUpdate)
t.Log("Updating the Service to use a different image")
- newImage := ptest.ImagePath(test.PizzaPlanet2)
+ newImage := ptest.ImagePath(toImage)
if _, err := v1test.PatchService(t, clients, svc, rtesting.WithServiceImage(newImage)); err != nil {
t.Fatalf("Patch update for Service %s with new image %s failed: %v", names.Service, newImage, err)
}
@@ -151,7 +159,7 @@ func updateService(serviceName string, t *testing.T) {
t.Log("Since the Service was updated a new Revision will be created and the Service will be updated")
revisionName, err := v1test.WaitForServiceLatestRevision(clients, names)
if err != nil {
- t.Fatalf("Service %s was not updated with the Revision for image %s: %v", names.Service, test.PizzaPlanet2, err)
+ t.Fatalf("Service %s was not updated with the Revision for image %s: %v", names.Service, toImage, err)
}
names.Revision = revisionName
@@ -159,13 +167,13 @@ func updateService(serviceName string, t *testing.T) {
if err := v1test.WaitForServiceState(clients.ServingClient, names.Service, v1test.IsServiceReady, "ServiceIsReady"); err != nil {
t.Fatalf("The Service %s was not marked as Ready to serve traffic to Revision %s: %v", names.Service, names.Revision, err)
}
- assertServiceResourcesUpdated(t, clients, names, routeURL, test.PizzaPlanetText2)
+ assertServiceResourcesUpdated(t, clients, names, routeURL, textAfterUpdate)
}
// CreateNewServicePostUpgradeTest verifies creating a new service after upgrade.
func CreateNewServicePostUpgradeTest() pkgupgrade.Operation {
return pkgupgrade.NewOperation("CreateNewServicePostUpgradeTest", func(c pkgupgrade.Context) {
- createNewService(postUpgradeServiceName, c.T)
+ createNewService("pizzaplanet-post-upgrade-service", c.T)
})
}
@@ -180,9 +188,10 @@ func InitialScalePostUpgradeTest() pkgupgrade.Operation {
func initialScalePostUpgrade(t *testing.T) {
t.Parallel()
clients := e2e.Setup(t)
+ test.EnsureTearDown(t, clients, &initialScaleServiceNames)
- t.Logf("Getting service %q", initialScaleServiceName)
- svc, err := clients.ServingClient.Services.Get(context.Background(), initialScaleServiceName, metav1.GetOptions{})
+ t.Logf("Getting service %q", initialScaleServiceNames.Service)
+ svc, err := clients.ServingClient.Services.Get(context.Background(), initialScaleServiceNames.Service, metav1.GetOptions{})
if err != nil {
t.Fatal("Failed to get Service:", err)
}
diff --git a/test/upgrade/preupgrade.go b/test/upgrade/preupgrade.go
index 77fb99dfbb1f..3edcdde8266e 100644
--- a/test/upgrade/preupgrade.go
+++ b/test/upgrade/preupgrade.go
@@ -49,12 +49,7 @@ func servicePreUpgrade(t *testing.T) {
t.Parallel()
clients := e2e.Setup(t)
- names := test.ResourceNames{
- Service: serviceName,
- Image: test.PizzaPlanet1,
- }
-
- resources, err := v1test.CreateServiceReady(t, clients, &names,
+ resources, err := v1test.CreateServiceReady(t, clients, &upgradeServiceNames,
rtesting.WithConfigAnnotations(map[string]string{
autoscaling.MinScaleAnnotationKey: "1", //make sure we don't scale to zero during the test
}),
@@ -63,7 +58,7 @@ func servicePreUpgrade(t *testing.T) {
t.Fatal("Failed to create Service:", err)
}
url := resources.Service.Status.URL.URL()
- assertServiceResourcesUpdated(t, clients, names, url, test.PizzaPlanetText1)
+ assertServiceResourcesUpdated(t, clients, upgradeServiceNames, url, test.PizzaPlanetText1)
}
// ServicePreUpgradeAndScaleToZeroTest creates a new service before
@@ -78,12 +73,7 @@ func servicePreUpgradeAndScaleToZero(t *testing.T) {
t.Parallel()
clients := e2e.Setup(t)
- names := test.ResourceNames{
- Service: scaleToZeroServiceName,
- Image: test.PizzaPlanet1,
- }
-
- resources, err := v1test.CreateServiceReady(t, clients, &names,
+ resources, err := v1test.CreateServiceReady(t, clients, &scaleToZeroServiceNames,
rtesting.WithConfigAnnotations(map[string]string{
autoscaling.WindowAnnotationKey: autoscaling.WindowMin.String(), //make sure we scale to zero quickly
}),
@@ -92,7 +82,7 @@ func servicePreUpgradeAndScaleToZero(t *testing.T) {
t.Fatal("Failed to create Service:", err)
}
url := resources.Service.Status.URL.URL()
- assertServiceResourcesUpdated(t, clients, names, url, test.PizzaPlanetText1)
+ assertServiceResourcesUpdated(t, clients, scaleToZeroServiceNames, url, test.PizzaPlanetText1)
if err := e2e.WaitForScaleToZero(t, revisionresourcenames.Deployment(resources.Revision), clients); err != nil {
t.Fatal("Could not scale to zero:", err)
@@ -110,12 +100,8 @@ func BYORevisionPreUpgradeTest() pkgupgrade.Operation {
func bYORevisionPreUpgrade(t *testing.T) {
t.Parallel()
clients := e2e.Setup(t)
- names := test.ResourceNames{
- Service: byoServiceName,
- Image: test.PizzaPlanet1,
- }
- if _, err := v1test.CreateServiceReady(t, clients, &names,
+ if _, err := v1test.CreateServiceReady(t, clients, &byoServiceNames,
rtesting.WithBYORevisionName(byoRevName)); err != nil {
t.Fatal("Failed to create Service:", err)
}
@@ -132,12 +118,8 @@ func InitialScalePreUpgradeTest() pkgupgrade.Operation {
func initialScalePreUpgrade(t *testing.T) {
t.Parallel()
clients := e2e.Setup(t)
- names := test.ResourceNames{
- Service: initialScaleServiceName,
- Image: test.PizzaPlanet1,
- }
- resources, err := v1test.CreateServiceReady(t, clients, &names)
+ resources, err := v1test.CreateServiceReady(t, clients, &initialScaleServiceNames)
if err != nil {
t.Fatal("Failed to create Service:", err)
}
diff --git a/test/upgrade/upgrade.go b/test/upgrade/upgrade.go
index 0ba0aa538a30..98a261843898 100644
--- a/test/upgrade/upgrade.go
+++ b/test/upgrade/upgrade.go
@@ -40,15 +40,29 @@ import (
)
const (
+ byoServiceName = "byo-revision-name-upgrade-test"
+ byoRevName = byoServiceName + "-" + "rev1"
+)
+
+var (
// These service names need to be stable, since we use them across
- // multiple "go test" invocations.
- serviceName = "pizzaplanet-upgrade-service"
- postUpgradeServiceName = "pizzaplanet-post-upgrade-service"
- postDowngradeServiceName = "pizzaplanet-post-downgrade-service"
- scaleToZeroServiceName = "scale-to-zero-upgrade-service"
- byoServiceName = "byo-revision-name-upgrade-test"
- byoRevName = byoServiceName + "-" + "rev1"
- initialScaleServiceName = "init-scale-service"
+ // multiple tests.
+ upgradeServiceNames = test.ResourceNames{
+ Service: "pizzaplanet-upgrade-service",
+ Image: test.PizzaPlanet1,
+ }
+ scaleToZeroServiceNames = test.ResourceNames{
+ Service: "scale-to-zero-upgrade-service",
+ Image: test.PizzaPlanet1,
+ }
+ byoServiceNames = test.ResourceNames{
+ Service: byoServiceName,
+ Image: test.PizzaPlanet1,
+ }
+ initialScaleServiceNames = test.ResourceNames{
+ Service: "init-scale-service",
+ Image: test.PizzaPlanet1,
+ }
)
// Shamelessly cribbed from conformance/service_test.
@@ -75,6 +89,7 @@ func createNewService(serviceName string, t *testing.T) {
Service: serviceName,
Image: test.PizzaPlanet1,
}
+ test.EnsureTearDown(t, clients, &names)
resources, err := v1test.CreateServiceReady(t, clients, &names)
if err != nil {
From f9532305b5ce7ea243f4abbf6db2a09c6f3a7a1a Mon Sep 17 00:00:00 2001
From: Hongyu <39747921+HongyuHe@users.noreply.github.com>
Date: Mon, 24 Jan 2022 15:30:29 +0100
Subject: [PATCH 109/733] Change the name of the default autoscaler (#12537)
Signed-off-by: Hongyu
---
config/core/configmaps/autoscaler.yaml | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/config/core/configmaps/autoscaler.yaml b/config/core/configmaps/autoscaler.yaml
index 620bcaa26eac..c0068f314b03 100644
--- a/config/core/configmaps/autoscaler.yaml
+++ b/config/core/configmaps/autoscaler.yaml
@@ -23,7 +23,7 @@ metadata:
app.kubernetes.io/version: devel
serving.knative.dev/release: devel
annotations:
- knative.dev/example-checksum: "b4401cf4"
+ knative.dev/example-checksum: "16af78ce"
data:
_example: |
################################
@@ -165,8 +165,8 @@ data:
scale-to-zero-pod-retention-period: "0s"
# pod-autoscaler-class specifies the default pod autoscaler class
- # that should be used if none is specified. If omitted, the Knative
- # Horizontal Pod Autoscaler (KPA) is used by default.
+ # that should be used if none is specified. If omitted,
+ # the Knative Pod Autoscaler (KPA) is used by default.
pod-autoscaler-class: "kpa.autoscaling.knative.dev"
# The capacity of a single activator task.
From 501df8c9609ec2f3c0a4395aba59fd83cf4c4cfc Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 25 Jan 2022 06:10:49 -0800
Subject: [PATCH 110/733] Update net-certmanager nightly (#12553)
bumping knative.dev/net-certmanager ab46e24...ef41464:
> ef41464 Update community files (# 344)
> 7c5d53f upgrade to latest dependencies (# 342)
Signed-off-by: Knative Automation
---
.../cert-manager-latest/net-certmanager.yaml | 44 +++++++++----------
1 file changed, 22 insertions(+), 22 deletions(-)
diff --git a/third_party/cert-manager-latest/net-certmanager.yaml b/third_party/cert-manager-latest/net-certmanager.yaml
index 1a779ac6730a..8b50518ac26a 100644
--- a/third_party/cert-manager-latest/net-certmanager.yaml
+++ b/third_party/cert-manager-latest/net-certmanager.yaml
@@ -19,9 +19,9 @@ metadata:
name: knative-serving-certmanager
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
serving.knative.dev/controller: "true"
networking.knative.dev/certificate-provider: cert-manager
rules:
@@ -53,9 +53,9 @@ metadata:
name: config.webhook.net-certmanager.networking.internal.knative.dev
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
networking.knative.dev/certificate-provider: cert-manager
webhooks:
- admissionReviewVersions:
@@ -95,9 +95,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
networking.knative.dev/certificate-provider: cert-manager
---
@@ -122,9 +122,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
networking.knative.dev/certificate-provider: cert-manager
data:
_example: |
@@ -172,9 +172,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
networking.knative.dev/certificate-provider: cert-manager
spec:
selector:
@@ -187,16 +187,16 @@ spec:
labels:
app: net-certmanager-controller
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/controller@sha256:92a08ce1ce0e98fb5752fa2334c042373cb3b33a086b07b7f2f247bbc4dd8ba5
+ image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/controller@sha256:3a6713e479dbb54d1c38ed0cce4c2cabaaad87c26c291a9a2b1875a7f6b0324a
resources:
requests:
cpu: 30m
@@ -235,9 +235,9 @@ metadata:
labels:
app: net-certmanager-controller
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
networking.knative.dev/certificate-provider: cert-manager
name: net-certmanager-controller
namespace: knative-serving
@@ -275,9 +275,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
networking.knative.dev/certificate-provider: cert-manager
spec:
selector:
@@ -291,17 +291,17 @@ spec:
labels:
app: net-certmanager-webhook
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
role: net-certmanager-webhook
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/webhook@sha256:4e208521fa6ae5b3a649034997df0eeef202b3a2377382d924843ddc336e55f5
+ image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/webhook@sha256:4a9fec4d9f810f4d72c939e506073ea755c99de03db5a3d0efc6d68c057f89f0
resources:
requests:
cpu: 20m
@@ -361,9 +361,9 @@ metadata:
labels:
role: net-certmanager-webhook
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220120-ab46e242"
+ app.kubernetes.io/version: "20220125-ef414645"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220120-ab46e242"
+ serving.knative.dev/release: "v20220125-ef414645"
networking.knative.dev/certificate-provider: cert-manager
spec:
ports:
From 91d2fa9554ea333fbba82331f42b16910f8aca66 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 25 Jan 2022 07:16:49 -0800
Subject: [PATCH 111/733] Update net-kourier nightly (#12556)
bumping knative.dev/net-kourier bea86d6...306979c:
> 306979c Update community files (# 758)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index 5166e369925b..c35a55700595 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
- serving.knative.dev/release: "v20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
+ serving.knative.dev/release: "v20220125-306979cf"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:d481354fff8bf89257d4d6a61afbf37220c25b9fac8fb6b3c1cd65e2df317e8a
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:15b60b48a85d15490f1836585c01eb939dc468727e375585e66ff4646a2c6cfc
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220121-bea86d68"
+ app.kubernetes.io/version: "20220125-306979cf"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-bea86d68"
+ serving.knative.dev/release: "v20220125-306979cf"
spec:
ports:
- name: http2
From 1ac434dc59fa9aaef332aaafb43d645ee3840e1e Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 25 Jan 2022 08:20:49 -0800
Subject: [PATCH 112/733] Update net-gateway-api nightly (#12554)
bumping knative.dev/net-gateway-api a6f4141...1a7d3eb:
> 1a7d3eb Update community files (# 238)
Signed-off-by: Knative Automation
---
third_party/gateway-api-latest/istio-gateway.yaml | 2 +-
third_party/gateway-api-latest/net-gateway-api.yaml | 12 ++++++------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/third_party/gateway-api-latest/istio-gateway.yaml b/third_party/gateway-api-latest/istio-gateway.yaml
index 62e1191a13e3..969ad07a760b 100644
--- a/third_party/gateway-api-latest/istio-gateway.yaml
+++ b/third_party/gateway-api-latest/istio-gateway.yaml
@@ -20,7 +20,7 @@ metadata:
name: knative-local-gateway
namespace: istio-system
labels:
- serving.knative.dev/release: "v20220121-a6f41410"
+ serving.knative.dev/release: "v20220125-1a7d3eb6"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
diff --git a/third_party/gateway-api-latest/net-gateway-api.yaml b/third_party/gateway-api-latest/net-gateway-api.yaml
index caf16a7afaef..31195b1d9109 100644
--- a/third_party/gateway-api-latest/net-gateway-api.yaml
+++ b/third_party/gateway-api-latest/net-gateway-api.yaml
@@ -2125,7 +2125,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-admin
labels:
- serving.knative.dev/release: "v20220121-a6f41410"
+ serving.knative.dev/release: "v20220125-1a7d3eb6"
aggregationRule:
clusterRoleSelectors:
- matchLabels:
@@ -2137,7 +2137,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-core
labels:
- serving.knative.dev/release: "v20220121-a6f41410"
+ serving.knative.dev/release: "v20220125-1a7d3eb6"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["networking.x-k8s.io"]
@@ -2165,7 +2165,7 @@ metadata:
name: config-gateway
namespace: knative-serving
labels:
- serving.knative.dev/release: "v20220121-a6f41410"
+ serving.knative.dev/release: "v20220125-1a7d3eb6"
data:
_example: |
################################
@@ -2219,9 +2219,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: net-gateway-api
app.kubernetes.io/component: net-gateway-api
- app.kubernetes.io/version: "20220121-a6f41410"
+ app.kubernetes.io/version: "20220125-1a7d3eb6"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220121-a6f41410"
+ serving.knative.dev/release: "v20220125-1a7d3eb6"
spec:
replicas: 1
selector:
@@ -2247,7 +2247,7 @@ spec:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:09de6cff3c60cb561b4005a87f79a881bf09668b76b94f3c9b54675c46134b36
+ image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:11fe78f11c506273390046f284564c541f18c562745a190abba218971d3542ca
resources:
requests:
cpu: 100m
From 046e275aee5f18f388ddf2d2849a868b27e3fc28 Mon Sep 17 00:00:00 2001
From: Paul Schweigert
Date: Tue, 25 Jan 2022 12:47:49 -0500
Subject: [PATCH 113/733] updates to GA version of PodDisruptionBudget (#12548)
---
config/core/deployments/activator-hpa.yaml | 2 +-
config/core/deployments/webhook-hpa.yaml | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/config/core/deployments/activator-hpa.yaml b/config/core/deployments/activator-hpa.yaml
index 8153937c308f..6c7133723bb6 100644
--- a/config/core/deployments/activator-hpa.yaml
+++ b/config/core/deployments/activator-hpa.yaml
@@ -41,7 +41,7 @@ spec:
# Activator PDB. Currently we permit unavailability of 20% of tasks at the same time.
# Given the subsetting and that the activators are partially stateful systems, we want
# a slow rollout of the new versions and slow migration during node upgrades.
-apiVersion: policy/v1beta1
+apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: activator-pdb
diff --git a/config/core/deployments/webhook-hpa.yaml b/config/core/deployments/webhook-hpa.yaml
index 2243083aa9aa..c3bd9d00ebad 100644
--- a/config/core/deployments/webhook-hpa.yaml
+++ b/config/core/deployments/webhook-hpa.yaml
@@ -39,7 +39,7 @@ spec:
averageUtilization: 100
---
# Webhook PDB.
-apiVersion: policy/v1beta1
+apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: webhook-pdb
From 5ec1118ce6eb33d9583e0f403e7cd774c922312a Mon Sep 17 00:00:00 2001
From: Paul Schweigert
Date: Tue, 25 Jan 2022 12:47:56 -0500
Subject: [PATCH 114/733] removes periodSeconds hack for k8s < v1.21 (#12550)
---
pkg/reconciler/revision/resources/deploy_test.go | 2 +-
pkg/reconciler/revision/resources/queue.go | 7 -------
pkg/reconciler/revision/resources/queue_test.go | 2 +-
3 files changed, 2 insertions(+), 9 deletions(-)
diff --git a/pkg/reconciler/revision/resources/deploy_test.go b/pkg/reconciler/revision/resources/deploy_test.go
index 90cc05545b45..a18282e0498c 100644
--- a/pkg/reconciler/revision/resources/deploy_test.go
+++ b/pkg/reconciler/revision/resources/deploy_test.go
@@ -86,7 +86,7 @@ var (
}},
},
},
- PeriodSeconds: 1,
+ PeriodSeconds: 0,
},
SecurityContext: queueSecurityContext,
Env: []corev1.EnvVar{{
diff --git a/pkg/reconciler/revision/resources/queue.go b/pkg/reconciler/revision/resources/queue.go
index df40d6367561..52c688f985fd 100644
--- a/pkg/reconciler/revision/resources/queue.go
+++ b/pkg/reconciler/revision/resources/queue.go
@@ -240,13 +240,6 @@ func makeQueueContainer(rev *v1.Revision, cfg *config.Config) (*corev1.Container
}},
},
}
-
- // Default PeriodSeconds to 1 if not set to make for the quickest possible startup
- // time.
- // TODO(#10973): Remove this once we're on K8s 1.21
- if httpProbe.PeriodSeconds == 0 {
- httpProbe.PeriodSeconds = 1
- }
}
c := &corev1.Container{
diff --git a/pkg/reconciler/revision/resources/queue_test.go b/pkg/reconciler/revision/resources/queue_test.go
index fa28d84594e5..a3f811a42382 100644
--- a/pkg/reconciler/revision/resources/queue_test.go
+++ b/pkg/reconciler/revision/resources/queue_test.go
@@ -724,7 +724,7 @@ func TestTCPProbeGeneration(t *testing.T) {
}},
},
},
- PeriodSeconds: 1,
+ PeriodSeconds: 0,
TimeoutSeconds: 0,
SuccessThreshold: 3,
}
From b3bd14fea105bc482d41a1729a2e8b7bfe1dd094 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 25 Jan 2022 11:15:48 -0800
Subject: [PATCH 115/733] Update net-istio nightly (#12555)
bumping knative.dev/net-istio 3fc0d95...dc8f82e:
> dc8f82e Update community files (# 854)
Signed-off-by: Knative Automation
---
third_party/istio-latest/net-istio.yaml | 70 ++++++++++++-------------
1 file changed, 35 insertions(+), 35 deletions(-)
diff --git a/third_party/istio-latest/net-istio.yaml b/third_party/istio-latest/net-istio.yaml
index 0e65ec8641f7..7273da4ed7be 100644
--- a/third_party/istio-latest/net-istio.yaml
+++ b/third_party/istio-latest/net-istio.yaml
@@ -1,4 +1,4 @@
-# Generated when HEAD was 3fc0d95f42423c171b40496f9c21ed351f35840f
+# Generated when HEAD was dc8f82eb4cc1573fbaa6b7085b27dc77918d5233
#
# Copyright 2019 The Knative Authors
#
@@ -22,8 +22,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
serving.knative.dev/controller: "true"
networking.knative.dev/ingress-provider: istio
rules:
@@ -55,8 +55,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -95,8 +95,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -117,8 +117,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -153,8 +153,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
data:
_example: |
@@ -220,8 +220,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -239,8 +239,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -258,8 +258,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -292,8 +292,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -311,15 +311,15 @@ spec:
app: net-istio-controller
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:b5b229ded2ee86dbf35866f529802bda2172b9463ed86cd541ebed4ea41f73a8
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:7baa538a9ec435cb9f75e94c27a640e3a5f83c2af92185eb1c345ab5306eef52
resources:
requests:
cpu: 30m
@@ -378,8 +378,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -395,15 +395,15 @@ spec:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:411950434c0230aa5df735accc87bd4e282d1af3b654909548e4dd4b4426db8f
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:51cec96ea95c5939abfd9ec8f200d1dfe4f62473236db3689d299b90adc06504
resources:
requests:
cpu: 20m
@@ -458,8 +458,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
---
@@ -486,8 +486,8 @@ metadata:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
spec:
ports:
@@ -526,8 +526,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -566,8 +566,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-3fc0d95f"
- serving.knative.dev/release: "v20220121-3fc0d95f"
+ app.kubernetes.io/version: "20220125-dc8f82eb"
+ serving.knative.dev/release: "v20220125-dc8f82eb"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
From ff30afc5fa738236181f50bc2e480061ad5a097d Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 25 Jan 2022 12:47:48 -0800
Subject: [PATCH 116/733] Update net-contour nightly (#12552)
bumping knative.dev/net-contour a248e38...8253890:
> 8253890 Copy parent HTTPOption to endpoint probe, if present. (# 713)
Signed-off-by: Knative Automation
---
third_party/contour-latest/net-contour.yaml | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/third_party/contour-latest/net-contour.yaml b/third_party/contour-latest/net-contour.yaml
index b1a8f1846079..144094e41612 100644
--- a/third_party/contour-latest/net-contour.yaml
+++ b/third_party/contour-latest/net-contour.yaml
@@ -8,7 +8,7 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-a248e38c"
+ app.kubernetes.io/version: "20220125-8253890e"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["projectcontour.io"]
@@ -38,8 +38,8 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-a248e38c"
- serving.knative.dev/release: "v20220121-a248e38c"
+ app.kubernetes.io/version: "20220125-8253890e"
+ serving.knative.dev/release: "v20220125-8253890e"
data:
_example: |
################################
@@ -105,14 +105,14 @@ spec:
app: net-contour-controller
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220121-a248e38c"
+ app.kubernetes.io/version: "20220125-8253890e"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:28215f178dfac25985ecc6c54b41ad582c754f61f62b94a3c4eafed799423c30
+ image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:38573c42f5f74cb1d3d2774bc986b96625dda71c8085069b40ae2b8d1f21a29f
resources:
requests:
cpu: 40m
From 7d527f28e08ddc8f954f8e2773562b14052cc507 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Sat, 29 Jan 2022 11:41:28 -0800
Subject: [PATCH 117/733] Update community files (#12566)
Signed-off-by: Knative Automation
---
OWNERS_ALIASES | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/OWNERS_ALIASES b/OWNERS_ALIASES
index 4a3752e39e4e..c0169064dfc0 100644
--- a/OWNERS_ALIASES
+++ b/OWNERS_ALIASES
@@ -149,16 +149,16 @@ aliases:
- efiturri
- evankanderson
- gerardo-lc
- - joshua-bone
- kvmware
- shinigambit
- - steuhs
productivity-wg-leads:
- chizhg
productivity-writers:
+ - cardil
- chaodaiG
- chizhg
- coryrc
+ - psschwei
security-wg-leads:
- evankanderson
- julz
From 422f10a3a10b1541c0aec64f96dba3744550bd79 Mon Sep 17 00:00:00 2001
From: Pierangelo Di Pilato
Date: Mon, 31 Jan 2022 17:56:30 +0100
Subject: [PATCH 118/733] Upgrade knative.dev/pkg@main and fix DomainMapping
error (#12560)
* Upgrade knative.dev/pkg@main
- Run `go get -u knative.dev/pkg@main`
- Run `hack/upgrade-deps.sh`
Signed-off-by: Pierangelo Di Pilato
* Fix DomainMapping TableTest error
Signed-off-by: Pierangelo Di Pilato
---
go.mod | 2 +-
go.sum | 3 ++-
pkg/reconciler/domainmapping/table_test.go | 6 ++++--
vendor/knative.dev/pkg/resolver/addressable_resolver.go | 8 +++++---
vendor/modules.txt | 2 +-
5 files changed, 13 insertions(+), 8 deletions(-)
diff --git a/go.mod b/go.mod
index e558e0f9fba9..4f0813d75776 100644
--- a/go.mod
+++ b/go.mod
@@ -39,6 +39,6 @@ require (
knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4
knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30
knative.dev/networking v0.0.0-20220120043934-ec785540a732
- knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4
+ knative.dev/pkg v0.0.0-20220121092305-3ba5d72e310a
sigs.k8s.io/yaml v1.3.0
)
diff --git a/go.sum b/go.sum
index 7fa32211131f..fffab93850eb 100644
--- a/go.sum
+++ b/go.sum
@@ -1787,8 +1787,9 @@ knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30 h1:UkNpCWCMM5C4AeQ8aTrPTuR/6
knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/networking v0.0.0-20220120043934-ec785540a732 h1:fUUb5NWfYm8TQkhv1uFYlEn91YNKp+E4BD7ax7WYHW0=
knative.dev/networking v0.0.0-20220120043934-ec785540a732/go.mod h1:6cKBV/h/vIQWCPOkds/RvzUmMR8Vz6Dks2NWb0+3xks=
-knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4 h1:b9aXVrcfM/ajjHE/lGvlJOHZNAR5FF2TOTLWG7eMhzQ=
knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4/go.mod h1:etVT7Tm8pSDf4RKhGk4r7j/hj3dNBpvT7bO6a6wpahs=
+knative.dev/pkg v0.0.0-20220121092305-3ba5d72e310a h1:Fkk1AtQ9bnC9hfasInH5TWeRL+wJX046W5ogR1kK2eU=
+knative.dev/pkg v0.0.0-20220121092305-3ba5d72e310a/go.mod h1:etVT7Tm8pSDf4RKhGk4r7j/hj3dNBpvT7bO6a6wpahs=
pgregory.net/rapid v0.3.3 h1:jCjBsY4ln4Atz78QoBWxUEvAHaFyNDQg9+WU62aCn1U=
pgregory.net/rapid v0.3.3/go.mod h1:UYpPVyjFHzYBGHIxLFoupi8vwk6rXNzRY9OMvVxFIOU=
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
diff --git a/pkg/reconciler/domainmapping/table_test.go b/pkg/reconciler/domainmapping/table_test.go
index 129c553c38fa..5f62f5d02ed9 100644
--- a/pkg/reconciler/domainmapping/table_test.go
+++ b/pkg/reconciler/domainmapping/table_test.go
@@ -42,6 +42,7 @@ import (
pkgreconciler "knative.dev/pkg/reconciler"
"knative.dev/pkg/resolver"
"knative.dev/pkg/tracker"
+
"knative.dev/serving/pkg/apis/serving"
servingv1 "knative.dev/serving/pkg/apis/serving/v1"
"knative.dev/serving/pkg/apis/serving/v1alpha1"
@@ -52,6 +53,7 @@ import (
"knative.dev/pkg/client/injection/ducks/duck/v1/addressable"
. "knative.dev/pkg/reconciler/testing"
+
. "knative.dev/serving/pkg/reconciler/testing/v1"
. "knative.dev/serving/pkg/testing"
)
@@ -217,7 +219,7 @@ func TestReconcile(t *testing.T) {
withInitDomainMappingConditions,
withTLSNotEnabled,
withDomainClaimed,
- withReferenceNotResolved(`services.serving.knative.dev "target" not found`),
+ withReferenceNotResolved(`failed to get object default/target: services.serving.knative.dev "target" not found`),
),
}},
SkipNamespaceValidation: true, // allow creation of ClusterDomainClaim.
@@ -229,7 +231,7 @@ func TestReconcile(t *testing.T) {
},
WantEvents: []string{
Eventf(corev1.EventTypeNormal, "FinalizerUpdate", "Updated %q finalizers", "first-reconcile.com"),
- Eventf(corev1.EventTypeWarning, "InternalError", `resolving reference: services.serving.knative.dev "target" not found`),
+ Eventf(corev1.EventTypeWarning, "InternalError", `resolving reference: failed to get object default/target: services.serving.knative.dev "target" not found`),
},
}, {
Name: "first reconcile, ref has a path",
diff --git a/vendor/knative.dev/pkg/resolver/addressable_resolver.go b/vendor/knative.dev/pkg/resolver/addressable_resolver.go
index 0e50a25784ac..d6995947a14f 100644
--- a/vendor/knative.dev/pkg/resolver/addressable_resolver.go
+++ b/vendor/knative.dev/pkg/resolver/addressable_resolver.go
@@ -23,12 +23,14 @@ import (
"k8s.io/apimachinery/pkg/runtime/schema"
"k8s.io/client-go/tools/cache"
+
"knative.dev/pkg/client/injection/ducks/duck/v1/addressable"
"knative.dev/pkg/controller"
corev1 "k8s.io/api/core/v1"
apierrs "k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/api/meta"
+
"knative.dev/pkg/apis"
pkgapisduck "knative.dev/pkg/apis/duck"
duckv1 "knative.dev/pkg/apis/duck/v1"
@@ -169,17 +171,17 @@ func (r *URIResolver) URIFromObjectReference(ctx context.Context, ref *corev1.Ob
Namespace: ref.Namespace,
Name: ref.Name,
}, parent); err != nil {
- return nil, apierrs.NewNotFound(gvr.GroupResource(), ref.Name)
+ return nil, fmt.Errorf("failed to track reference %s %s/%s: %w", gvr.String(), ref.Namespace, ref.Name, err)
}
lister, err := r.listerFactory(gvr)
if err != nil {
- return nil, apierrs.NewNotFound(gvr.GroupResource(), "Lister")
+ return nil, fmt.Errorf("failed to get lister for %s: %w", gvr.String(), err)
}
obj, err := lister.ByNamespace(ref.Namespace).Get(ref.Name)
if err != nil {
- return nil, apierrs.NewNotFound(gvr.GroupResource(), ref.Name)
+ return nil, fmt.Errorf("failed to get object %s/%s: %w", ref.Namespace, ref.Name, err)
}
// K8s Services are special cased. They can be called, even though they do not satisfy the
diff --git a/vendor/modules.txt b/vendor/modules.txt
index db10010cbb68..eef143a62e20 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -1075,7 +1075,7 @@ knative.dev/networking/pkg/client/injection/reconciler/networking/v1alpha1/serve
knative.dev/networking/pkg/client/listers/networking/v1alpha1
knative.dev/networking/pkg/ingress
knative.dev/networking/pkg/prober
-# knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4
+# knative.dev/pkg v0.0.0-20220121092305-3ba5d72e310a
## explicit
knative.dev/pkg/apiextensions/storageversion
knative.dev/pkg/apiextensions/storageversion/cmd/migrate
From 7faad9a68ef8229ece7eb2e7775228a94d7c43e7 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Mon, 31 Jan 2022 10:45:31 -0800
Subject: [PATCH 119/733] Update net-kourier nightly (#12563)
bumping knative.dev/net-kourier 306979c...a31d8bc:
> a31d8bc Update actions (# 763)
> 8d34dde Update community files (# 760)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index c35a55700595..2b679fee32c5 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
- serving.knative.dev/release: "v20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
+ serving.knative.dev/release: "v20220131-a31d8bca"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:15b60b48a85d15490f1836585c01eb939dc468727e375585e66ff4646a2c6cfc
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:5c0e3043cddad52c8f856c12f462800a74f99ef432e0fd74a6600824739e715d
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220125-306979cf"
+ app.kubernetes.io/version: "20220131-a31d8bca"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-306979cf"
+ serving.knative.dev/release: "v20220131-a31d8bca"
spec:
ports:
- name: http2
From d7bd949d8ed217b5d8c11393e7dec91dea1e1137 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Mon, 31 Jan 2022 10:45:38 -0800
Subject: [PATCH 120/733] Update net-contour nightly (#12570)
bumping knative.dev/net-contour 8253890...3e18bed:
> 3e18bed Update actions (# 715)
> 849bbf9 Update community files (# 714)
Signed-off-by: Knative Automation
---
third_party/contour-latest/net-contour.yaml | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/third_party/contour-latest/net-contour.yaml b/third_party/contour-latest/net-contour.yaml
index 144094e41612..76e162e0fe41 100644
--- a/third_party/contour-latest/net-contour.yaml
+++ b/third_party/contour-latest/net-contour.yaml
@@ -8,7 +8,7 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-8253890e"
+ app.kubernetes.io/version: "20220131-3e18bed0"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["projectcontour.io"]
@@ -38,8 +38,8 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-8253890e"
- serving.knative.dev/release: "v20220125-8253890e"
+ app.kubernetes.io/version: "20220131-3e18bed0"
+ serving.knative.dev/release: "v20220131-3e18bed0"
data:
_example: |
################################
@@ -105,14 +105,14 @@ spec:
app: net-contour-controller
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-8253890e"
+ app.kubernetes.io/version: "20220131-3e18bed0"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:38573c42f5f74cb1d3d2774bc986b96625dda71c8085069b40ae2b8d1f21a29f
+ image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:e13527176a8c2af2d9d067b557ee86d8f9c4495dd9bfc4e9fece8f267039e8af
resources:
requests:
cpu: 40m
From 770b91180d4396eb69d562761e802eb0a50d8019 Mon Sep 17 00:00:00 2001
From: Carlisia Thompson
Date: Mon, 31 Jan 2022 11:46:31 -0800
Subject: [PATCH 121/733] Add loglevel option for contour (#12567)
* Add loglevel option for contour
* Update codegen
---
config/core/configmaps/logging.yaml | 3 ++-
test/config/ytt/core/overlay-config-logging.yaml | 1 +
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/config/core/configmaps/logging.yaml b/config/core/configmaps/logging.yaml
index 2fb35264eb75..5a54df6482e2 100644
--- a/config/core/configmaps/logging.yaml
+++ b/config/core/configmaps/logging.yaml
@@ -22,7 +22,7 @@ metadata:
app.kubernetes.io/version: devel
app.kubernetes.io/name: knative-serving
annotations:
- knative.dev/example-checksum: "be93ff10"
+ knative.dev/example-checksum: "b0f3c6f2"
data:
_example: |
################################
@@ -75,3 +75,4 @@ data:
loglevel.hpaautoscaler: "info"
loglevel.net-certmanager-controller: "info"
loglevel.net-istio-controller: "info"
+ loglevel.net-contour-controller: "info"
diff --git a/test/config/ytt/core/overlay-config-logging.yaml b/test/config/ytt/core/overlay-config-logging.yaml
index 098a9a44868b..79a06db8b912 100644
--- a/test/config/ytt/core/overlay-config-logging.yaml
+++ b/test/config/ytt/core/overlay-config-logging.yaml
@@ -35,3 +35,4 @@ data:
loglevel.domainmapping: "debug"
loglevel.net-istio-controller: "debug"
loglevel.net-certmanager-controller: "debug"
+ loglevel.net-contour-controller: "debug"
From fb1b4c158ad89a804919dd8b7e6e3c4d9b54730e Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 1 Feb 2022 08:02:32 -0800
Subject: [PATCH 122/733] Update net-istio nightly (#12576)
bumping knative.dev/net-istio dc8f82e...7a6405e:
> 7a6405e upgrade to latest dependencies (# 857)
Signed-off-by: Knative Automation
---
third_party/istio-latest/net-istio.yaml | 70 ++++++++++++-------------
1 file changed, 35 insertions(+), 35 deletions(-)
diff --git a/third_party/istio-latest/net-istio.yaml b/third_party/istio-latest/net-istio.yaml
index 7273da4ed7be..f9408ca38316 100644
--- a/third_party/istio-latest/net-istio.yaml
+++ b/third_party/istio-latest/net-istio.yaml
@@ -1,4 +1,4 @@
-# Generated when HEAD was dc8f82eb4cc1573fbaa6b7085b27dc77918d5233
+# Generated when HEAD was 7a6405e03cc99b3e82cc56c5fc1e09ba7ddcd837
#
# Copyright 2019 The Knative Authors
#
@@ -22,8 +22,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
serving.knative.dev/controller: "true"
networking.knative.dev/ingress-provider: istio
rules:
@@ -55,8 +55,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -95,8 +95,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -117,8 +117,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -153,8 +153,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
data:
_example: |
@@ -220,8 +220,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -239,8 +239,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -258,8 +258,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -292,8 +292,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -311,15 +311,15 @@ spec:
app: net-istio-controller
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:7baa538a9ec435cb9f75e94c27a640e3a5f83c2af92185eb1c345ab5306eef52
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:1f00ca86138719ad064b76eb80f31e5e0538e62198d5c409f60461703a38083f
resources:
requests:
cpu: 30m
@@ -378,8 +378,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -395,15 +395,15 @@ spec:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:51cec96ea95c5939abfd9ec8f200d1dfe4f62473236db3689d299b90adc06504
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:85f8de4c433d1c1e03322cba5e073ca90384ad1e23a0738a7fe724bdde10daf8
resources:
requests:
cpu: 20m
@@ -458,8 +458,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
---
@@ -486,8 +486,8 @@ metadata:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
spec:
ports:
@@ -526,8 +526,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -566,8 +566,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220125-dc8f82eb"
- serving.knative.dev/release: "v20220125-dc8f82eb"
+ app.kubernetes.io/version: "20220201-7a6405e0"
+ serving.knative.dev/release: "v20220201-7a6405e0"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
From 72ae543520ebe7a1220d5497f8a70a449865a2b2 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 1 Feb 2022 09:06:33 -0800
Subject: [PATCH 123/733] Update community files (#12573)
Signed-off-by: Knative Automation
---
OWNERS_ALIASES | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/OWNERS_ALIASES b/OWNERS_ALIASES
index c0169064dfc0..f2b31361fbe7 100644
--- a/OWNERS_ALIASES
+++ b/OWNERS_ALIASES
@@ -66,6 +66,7 @@ aliases:
- pierDipi
- vaikas
knative-admin:
+ - carlisia
- csantanapr
- dprotaso
- duglin
@@ -77,14 +78,14 @@ aliases:
- knative-test-reporter-robot
- lance
- pmorie
- - psschwei
- rhuss
- spencerdillard
- thisisnotapril
- vaikas
+ - xtreme-sameer-vohra
knative-release-leads:
- - dprotaso
- - psschwei
+ - carlisia
+ - xtreme-sameer-vohra
knative-robots:
- knative-prow-releaser-robot
- knative-prow-robot
From 923b4fa437eebce3dad8ab3355d26098e713f6f4 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 1 Feb 2022 09:06:40 -0800
Subject: [PATCH 124/733] Update actions (#12574)
Signed-off-by: Knative Automation
---
.github/workflows/knative-security.yaml | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/.github/workflows/knative-security.yaml b/.github/workflows/knative-security.yaml
index fbfe531d9f68..9f7bb3eda905 100644
--- a/.github/workflows/knative-security.yaml
+++ b/.github/workflows/knative-security.yaml
@@ -48,3 +48,9 @@ jobs:
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
+
+ - name: Find Unicode Control Characters
+ uses: pierdipi/unicode-control-characters-action@v0.1.1
+ with:
+ args: -d .
+
From 5ce87a4d9a1b48597a4d0e0055eb0bad92c805ee Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 1 Feb 2022 09:06:47 -0800
Subject: [PATCH 125/733] Update net-certmanager nightly (#12577)
bumping knative.dev/net-certmanager ef41464...6b6cb57:
> 6b6cb57 upgrade to latest dependencies (# 348)
> 186eb94 Update actions (# 346)
Signed-off-by: Knative Automation
---
.../cert-manager-latest/net-certmanager.yaml | 44 +++++++++----------
1 file changed, 22 insertions(+), 22 deletions(-)
diff --git a/third_party/cert-manager-latest/net-certmanager.yaml b/third_party/cert-manager-latest/net-certmanager.yaml
index 8b50518ac26a..45ea46a57d69 100644
--- a/third_party/cert-manager-latest/net-certmanager.yaml
+++ b/third_party/cert-manager-latest/net-certmanager.yaml
@@ -19,9 +19,9 @@ metadata:
name: knative-serving-certmanager
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
serving.knative.dev/controller: "true"
networking.knative.dev/certificate-provider: cert-manager
rules:
@@ -53,9 +53,9 @@ metadata:
name: config.webhook.net-certmanager.networking.internal.knative.dev
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
networking.knative.dev/certificate-provider: cert-manager
webhooks:
- admissionReviewVersions:
@@ -95,9 +95,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
networking.knative.dev/certificate-provider: cert-manager
---
@@ -122,9 +122,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
networking.knative.dev/certificate-provider: cert-manager
data:
_example: |
@@ -172,9 +172,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
networking.knative.dev/certificate-provider: cert-manager
spec:
selector:
@@ -187,16 +187,16 @@ spec:
labels:
app: net-certmanager-controller
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/controller@sha256:3a6713e479dbb54d1c38ed0cce4c2cabaaad87c26c291a9a2b1875a7f6b0324a
+ image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/controller@sha256:c4156eac574c2367d112781d0061ed3501c91af1cc0040e823cc269f82cef406
resources:
requests:
cpu: 30m
@@ -235,9 +235,9 @@ metadata:
labels:
app: net-certmanager-controller
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
networking.knative.dev/certificate-provider: cert-manager
name: net-certmanager-controller
namespace: knative-serving
@@ -275,9 +275,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
networking.knative.dev/certificate-provider: cert-manager
spec:
selector:
@@ -291,17 +291,17 @@ spec:
labels:
app: net-certmanager-webhook
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
role: net-certmanager-webhook
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/webhook@sha256:4a9fec4d9f810f4d72c939e506073ea755c99de03db5a3d0efc6d68c057f89f0
+ image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/webhook@sha256:795a02555aa7ff6d359bd399aae626d8810c7f1b82b96099e3806f8caa622cb4
resources:
requests:
cpu: 20m
@@ -361,9 +361,9 @@ metadata:
labels:
role: net-certmanager-webhook
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220125-ef414645"
+ app.kubernetes.io/version: "20220201-6b6cb57f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-ef414645"
+ serving.knative.dev/release: "v20220201-6b6cb57f"
networking.knative.dev/certificate-provider: cert-manager
spec:
ports:
From 721c2bb186a79b000e15400af893ecd20f93d07f Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 1 Feb 2022 10:10:31 -0800
Subject: [PATCH 126/733] upgrade to latest dependencies (#12575)
bumping knative.dev/hack 9b2ed84...82bfca1:
> 82bfca1 Update community files (# 147)
> 51a42b2 Update community files (# 146)
> 81ef5cc Update community files (# 145)
> cfb3eb8 Enable opting out Preemptible/Spot GKE Worker Nodes (# 144)
> 9dd1ec1 Look at package name when checking whether the shell package can be used (# 142)
> f1822b1 Disable Logs/Metrics on GKE and Run Preemptible Nodes (# 138)
> 32375dc remove clusteradmin grant (# 141)
> 987528e Temporarily fix the unit tests for library.sh (# 143)
> da09733 print commit hash (# 140)
bumping knative.dev/caching 0c1cc09...f91093f:
> f91093f upgrade to latest dependencies (# 597)
> c046e6a Update community files (# 596)
> 33dad0f Update community files (# 596)
bumping knative.dev/networking ec78554...d23a068:
> d23a068 upgrade to latest dependencies (# 611)
> 8acb8e7 Add transport option (# 605)
bumping knative.dev/pkg 3ba5d72...f4b57ae:
> f4b57ae Fix invalid creator or lastModifier annotations on core resources (# 2409)
> 21b467b upgrade to latest dependencies (# 2406)
> ca64d3b Update community files (# 2404)
> 2783cd8 Do not block NotFound error during patching resources (# 2403)
> d7b329c :bug: Update required Go version to 1.17 to fix # 2399 (# 2400)
Signed-off-by: Knative Automation
---
go.mod | 8 +++---
go.sum | 18 +++++++------
vendor/knative.dev/hack/README.md | 5 ++++
vendor/knative.dev/hack/e2e-tests.sh | 3 ---
vendor/knative.dev/hack/infra-library.sh | 26 ++++++++-----------
vendor/knative.dev/hack/presubmit-tests.sh | 4 +--
vendor/knative.dev/hack/shell/project.go | 15 ++++++-----
.../apiextensions/storageversion/migrator.go | 3 ++-
.../resourcesemantics/defaulting/user_info.go | 18 ++++++++++---
vendor/modules.txt | 8 +++---
10 files changed, 61 insertions(+), 47 deletions(-)
diff --git a/go.mod b/go.mod
index 4f0813d75776..16acf76e3fd8 100644
--- a/go.mod
+++ b/go.mod
@@ -36,9 +36,9 @@ require (
k8s.io/code-generator v0.22.5
k8s.io/klog v1.0.0 // indirect
k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65
- knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4
- knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30
- knative.dev/networking v0.0.0-20220120043934-ec785540a732
- knative.dev/pkg v0.0.0-20220121092305-3ba5d72e310a
+ knative.dev/caching v0.0.0-20220131155330-f91093f141e7
+ knative.dev/hack v0.0.0-20220201013531-82bfca153560
+ knative.dev/networking v0.0.0-20220131174231-d23a06807e6c
+ knative.dev/pkg v0.0.0-20220131144930-f4b57aef0006
sigs.k8s.io/yaml v1.3.0
)
diff --git a/go.sum b/go.sum
index fffab93850eb..1db032281072 100644
--- a/go.sum
+++ b/go.sum
@@ -1781,15 +1781,17 @@ k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b h1:wxEMGetGMur3J1xuGLQY7GEQYg9bZxKn3tKo5k/eYcs=
k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
-knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4 h1:CXojQdgLKqvxtmVBuGMURUjgnfPRSUeT2d/veVJL370=
-knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4/go.mod h1:OHsK3XaWmdi2/mPaNBiX8LbefbtM6TptnT90eVbYGSA=
-knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30 h1:UkNpCWCMM5C4AeQ8aTrPTuR/6OeARiqk+LEQ6tuMP7c=
+knative.dev/caching v0.0.0-20220131155330-f91093f141e7 h1:0p4b9UlTItvD+zWj2JeRl0MrTXWyqy59kHsetdjhxAY=
+knative.dev/caching v0.0.0-20220131155330-f91093f141e7/go.mod h1:kWv5fckKHd9e/OSe6tUHKjUtJryWjytea9mnZxJoPLA=
knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/networking v0.0.0-20220120043934-ec785540a732 h1:fUUb5NWfYm8TQkhv1uFYlEn91YNKp+E4BD7ax7WYHW0=
-knative.dev/networking v0.0.0-20220120043934-ec785540a732/go.mod h1:6cKBV/h/vIQWCPOkds/RvzUmMR8Vz6Dks2NWb0+3xks=
-knative.dev/pkg v0.0.0-20220118160532-77555ea48cd4/go.mod h1:etVT7Tm8pSDf4RKhGk4r7j/hj3dNBpvT7bO6a6wpahs=
-knative.dev/pkg v0.0.0-20220121092305-3ba5d72e310a h1:Fkk1AtQ9bnC9hfasInH5TWeRL+wJX046W5ogR1kK2eU=
-knative.dev/pkg v0.0.0-20220121092305-3ba5d72e310a/go.mod h1:etVT7Tm8pSDf4RKhGk4r7j/hj3dNBpvT7bO6a6wpahs=
+knative.dev/hack v0.0.0-20220128200847-51a42b2eb63e/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
+knative.dev/hack v0.0.0-20220201013531-82bfca153560 h1:JTQwe928hZokY181gjYKeVdxr+s3v95LDkMs7R0fxfE=
+knative.dev/hack v0.0.0-20220201013531-82bfca153560/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
+knative.dev/networking v0.0.0-20220131174231-d23a06807e6c h1:0mPVfMikv8wz37qEMSUVXAqoDOn3qRPRSQuxx91nACs=
+knative.dev/networking v0.0.0-20220131174231-d23a06807e6c/go.mod h1:RzkiJ/LyijMaMUa6tOerhI9lGvQYpfDY0VttqQIX0yk=
+knative.dev/pkg v0.0.0-20220129160148-ca64d3b3ea8c/go.mod h1:BML2uvSEBhY/cpEsAyWv1+vLy2fxNk8VDJ9fT+D0tj4=
+knative.dev/pkg v0.0.0-20220131144930-f4b57aef0006 h1:0Kv7dIOimyHno/7jbQ6LCi15ME+e/b5tY0pwi99kanQ=
+knative.dev/pkg v0.0.0-20220131144930-f4b57aef0006/go.mod h1:bZMFTPDPHV3wXuiQ09UJuEGYYQnfpe81MCxNvsMAiJk=
pgregory.net/rapid v0.3.3 h1:jCjBsY4ln4Atz78QoBWxUEvAHaFyNDQg9+WU62aCn1U=
pgregory.net/rapid v0.3.3/go.mod h1:UYpPVyjFHzYBGHIxLFoupi8vwk6rXNzRY9OMvVxFIOU=
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
diff --git a/vendor/knative.dev/hack/README.md b/vendor/knative.dev/hack/README.md
index a6a98c78400b..570f370977d6 100644
--- a/vendor/knative.dev/hack/README.md
+++ b/vendor/knative.dev/hack/README.md
@@ -167,6 +167,11 @@ This is a helper script for Knative E2E test scripts. To use it:
1. By default Istio is installed on the cluster via Addon, use
`--skip-istio-addon` if you choose not to have it preinstalled.
+1. By default Google Kubernetes Engine telemetry to Cloud Logging and Monitoring is disabled.
+ This can be enabled by setting `ENABLE_GKE_TELEMETRY` to `true`.
+
+1. By default Spot Worker nodes are disabled. This can be enabled by setting `ENABLE_PREEMPTIBLE_NODES`
+ to `true`.
### Sample end-to-end test script
This script will test that the latest Knative Serving nightly release works. It
diff --git a/vendor/knative.dev/hack/e2e-tests.sh b/vendor/knative.dev/hack/e2e-tests.sh
index 537b3867e238..9178eac2ccae 100644
--- a/vendor/knative.dev/hack/e2e-tests.sh
+++ b/vendor/knative.dev/hack/e2e-tests.sh
@@ -73,9 +73,6 @@ function setup_test_cluster() {
is_protected_cluster "${k8s_cluster}" && \
abort "kubeconfig context set to ${k8s_cluster}, which is forbidden"
- # Acquire cluster admin role for the current user.
- acquire_cluster_admin_role "${k8s_cluster}"
-
# Setup KO_DOCKER_REPO if it is a GKE cluster. Incorporate an element of
# randomness to ensure that each run properly publishes images. Don't
# owerwrite KO_DOCKER_REPO if already set.
diff --git a/vendor/knative.dev/hack/infra-library.sh b/vendor/knative.dev/hack/infra-library.sh
index f87c259d1da0..a96210e2e1fd 100644
--- a/vendor/knative.dev/hack/infra-library.sh
+++ b/vendor/knative.dev/hack/infra-library.sh
@@ -77,20 +77,6 @@ function dump_cluster_state() {
echo "***************************************"
}
-# Sets the current user as cluster admin for the given cluster.
-# Parameters: $1 - cluster context name
-function acquire_cluster_admin_role() {
- if [[ -z "$(kubectl get clusterrolebinding cluster-admin-binding 2> /dev/null)" ]]; then
- if [[ "$1" =~ ^gke_.* ]]; then
- kubectl create clusterrolebinding cluster-admin-binding \
- --clusterrole=cluster-admin --user="$(gcloud config get-value core/account)"
- else
- kubectl create clusterrolebinding cluster-admin-binding \
- --clusterrole=cluster-admin --user="prow"
- fi
- fi
-}
-
# Create a test cluster and run the tests if provided.
# Parameters: $1 - cluster provider name, e.g. gke
# $2 - custom flags supported by kntest
@@ -137,5 +123,15 @@ function create_gke_test_cluster() {
local -n _custom_flags=$1
local -n _test_command=$2
- run_kntest kubetest2 gke "${_custom_flags[@]}" --test-command="${_test_command[*]}"
+ # We are disabling logs and metrics on Boskos Clusters by default as they are not used. Manually set ENABLE_GKE_TELEMETRY to true to enable telemetry
+ # and ENABLE_PREEMPTIBLE_NODES to true to create preemptible/spot VMs. VM Preemption is a rare event and shouldn't be distruptive given the fault tolerant nature of our tests.
+ local extra_gcloud_flags=""
+ if [[ "$ENABLE_GKE_TELEMETRY" != "true" ]]; then
+ extra_gcloud_flags="${extra_gcloud_flags} --logging=NONE --monitoring=NONE"
+ fi
+
+ if [[ "$ENABLE_PREEMPTIBLE_NODES" == "true" ]]; then
+ extra_gcloud_flags="${extra_gcloud_flags} --preemptible"
+ fi
+ run_kntest kubetest2 gke "${_custom_flags[@]}" --test-command="${_test_command[*]}" --extra-gcloud-flags="${extra_gcloud_flags}"
}
diff --git a/vendor/knative.dev/hack/presubmit-tests.sh b/vendor/knative.dev/hack/presubmit-tests.sh
index 70a399c8e3c3..08bd85d4a1b3 100644
--- a/vendor/knative.dev/hack/presubmit-tests.sh
+++ b/vendor/knative.dev/hack/presubmit-tests.sh
@@ -266,8 +266,6 @@ function main() {
git version
echo ">> ko version"
[[ -f /ko_version ]] && cat /ko_version || echo "unknown"
- echo ">> bazel version"
- [[ -f /bazel_version ]] && cat /bazel_version || echo "unknown"
if [[ "${DOCKER_IN_DOCKER_ENABLED}" == "true" ]]; then
echo ">> docker version"
docker version
@@ -281,6 +279,8 @@ function main() {
echo ">> maven version"
mvn --version
fi
+ echo ">> prow-tests image version"
+ [[ -f /commit_hash ]] && echo "Prow test image was built from $(cat /commit_hash) commit which is viewable at https://github.com/knative/test-infra/tree/$(cat /commit_hash) " || echo "unknown"
fi
[[ -z ${1:-} ]] && set -- "--all-tests"
diff --git a/vendor/knative.dev/hack/shell/project.go b/vendor/knative.dev/hack/shell/project.go
index f4cd1681adc0..a6df6c4a665f 100644
--- a/vendor/knative.dev/hack/shell/project.go
+++ b/vendor/knative.dev/hack/shell/project.go
@@ -37,11 +37,12 @@ var (
// NewProjectLocation creates a ProjectLocation that is used to calculate
// relative paths within the project.
func NewProjectLocation(pathToRoot string) (ProjectLocation, error) {
- _, filename, _, ok := runtime.Caller(1)
+ pc, filename, _, ok := runtime.Caller(1)
if !ok {
return nil, ErrCantGetCaller
}
- err := ensureIsValid(filename)
+ funcName := runtime.FuncForPC(pc).Name()
+ err := isCallsiteAllowed(funcName)
if err != nil {
return nil, err
}
@@ -64,17 +65,17 @@ type callerLocation struct {
pathToRoot string
}
-func ensureIsValid(filename string) error {
+func isCallsiteAllowed(funcName string) error {
validPaths := []string{
- "knative.+/test/upgrade/",
- "knative(:?\\.dev/|-)hack/shell/",
+ "knative.+/test/upgrade",
+ "knative(:?\\.dev/|-)hack/shell",
}
for _, validPath := range validPaths {
r := regexp.MustCompile(validPath)
- if loc := r.FindStringIndex(filename); loc != nil {
+ if loc := r.FindStringIndex(funcName); loc != nil {
return nil
}
}
return fmt.Errorf("%w, tried using from: %s",
- ErrCallerNotAllowed, filename)
+ ErrCallerNotAllowed, funcName)
}
diff --git a/vendor/knative.dev/pkg/apiextensions/storageversion/migrator.go b/vendor/knative.dev/pkg/apiextensions/storageversion/migrator.go
index 2d1cb47ac38a..7ac1cc932687 100644
--- a/vendor/knative.dev/pkg/apiextensions/storageversion/migrator.go
+++ b/vendor/knative.dev/pkg/apiextensions/storageversion/migrator.go
@@ -22,6 +22,7 @@ import (
apix "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1"
apixclient "k8s.io/apiextensions-apiserver/pkg/client/clientset/clientset"
+ apierrs "k8s.io/apimachinery/pkg/api/errors"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema"
@@ -93,7 +94,7 @@ func (m *Migrator) migrateResources(ctx context.Context, gvr schema.GroupVersion
_, err := client.Namespace(item.GetNamespace()).
Patch(ctx, item.GetName(), types.MergePatchType, []byte("{}"), metav1.PatchOptions{})
- if err != nil {
+ if err != nil && !apierrs.IsNotFound(err) {
return fmt.Errorf("unable to patch resource %s/%s (gvr: %s) - %w",
item.GetNamespace(), item.GetName(),
gvr, err)
diff --git a/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/user_info.go b/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/user_info.go
index fcd97a45617d..f206588e46d1 100644
--- a/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/user_info.go
+++ b/vendor/knative.dev/pkg/webhook/resourcesemantics/defaulting/user_info.go
@@ -27,6 +27,11 @@ import (
"knative.dev/pkg/apis"
)
+var (
+ emptyGroupUpdaterAnnotation = apis.UpdaterAnnotationSuffix[1:]
+ emptyGroupCreatorAnnotation = apis.CreatorAnnotationSuffix[1:]
+)
+
// setUserInfoAnnotations sets creator and updater annotations on a resource.
func setUserInfoAnnotations(ctx context.Context, resource apis.HasSpec, groupName string) {
if ui := apis.GetUserInfo(ctx); ui != nil {
@@ -41,15 +46,22 @@ func setUserInfoAnnotations(ctx context.Context, resource apis.HasSpec, groupNam
objectMetaAccessor.GetObjectMeta().SetAnnotations(annotations)
}
+ updaterAnnotation := emptyGroupUpdaterAnnotation
+ creatorAnnotation := emptyGroupCreatorAnnotation
+ if groupName != "" {
+ updaterAnnotation = groupName + apis.UpdaterAnnotationSuffix
+ creatorAnnotation = groupName + apis.CreatorAnnotationSuffix
+ }
+
if apis.IsInUpdate(ctx) {
old := apis.GetBaseline(ctx).(apis.HasSpec)
if equality.Semantic.DeepEqual(old.GetUntypedSpec(), resource.GetUntypedSpec()) {
return
}
- annotations[groupName+apis.UpdaterAnnotationSuffix] = ui.Username
+ annotations[updaterAnnotation] = ui.Username
} else {
- annotations[groupName+apis.CreatorAnnotationSuffix] = ui.Username
- annotations[groupName+apis.UpdaterAnnotationSuffix] = ui.Username
+ annotations[creatorAnnotation] = ui.Username
+ annotations[updaterAnnotation] = ui.Username
}
objectMetaAccessor.GetObjectMeta().SetAnnotations(annotations)
}
diff --git a/vendor/modules.txt b/vendor/modules.txt
index eef143a62e20..c7d487792148 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -1020,7 +1020,7 @@ k8s.io/utils/buffer
k8s.io/utils/integer
k8s.io/utils/pointer
k8s.io/utils/trace
-# knative.dev/caching v0.0.0-20220118175933-0c1cc094a7f4
+# knative.dev/caching v0.0.0-20220131155330-f91093f141e7
## explicit
knative.dev/caching/config
knative.dev/caching/pkg/apis/caching
@@ -1041,11 +1041,11 @@ knative.dev/caching/pkg/client/injection/informers/caching/v1alpha1/image/fake
knative.dev/caching/pkg/client/injection/informers/factory
knative.dev/caching/pkg/client/injection/informers/factory/fake
knative.dev/caching/pkg/client/listers/caching/v1alpha1
-# knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30
+# knative.dev/hack v0.0.0-20220201013531-82bfca153560
## explicit
knative.dev/hack
knative.dev/hack/shell
-# knative.dev/networking v0.0.0-20220120043934-ec785540a732
+# knative.dev/networking v0.0.0-20220131174231-d23a06807e6c
## explicit
knative.dev/networking/config
knative.dev/networking/pkg
@@ -1075,7 +1075,7 @@ knative.dev/networking/pkg/client/injection/reconciler/networking/v1alpha1/serve
knative.dev/networking/pkg/client/listers/networking/v1alpha1
knative.dev/networking/pkg/ingress
knative.dev/networking/pkg/prober
-# knative.dev/pkg v0.0.0-20220121092305-3ba5d72e310a
+# knative.dev/pkg v0.0.0-20220131144930-f4b57aef0006
## explicit
knative.dev/pkg/apiextensions/storageversion
knative.dev/pkg/apiextensions/storageversion/cmd/migrate
From 4e17128158b206220eccbfa8b60c749811dab9a1 Mon Sep 17 00:00:00 2001
From: "Amanda H. L. de Andrade Katz"
Date: Wed, 2 Feb 2022 11:57:32 -0300
Subject: [PATCH 127/733] Add flag disable-test-cleanup (#10001) (#12482)
---
test/cleanup.go | 8 +++++++-
test/e2e_flags.go | 4 ++++
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/test/cleanup.go b/test/cleanup.go
index 336f7825626e..b24a1832264d 100644
--- a/test/cleanup.go
+++ b/test/cleanup.go
@@ -80,5 +80,11 @@ func EnsureCleanup(t *testing.T, cleanup func()) {
// EnsureTearDown will delete created names when the test ends, either via
// t.Cleanup, or on interrupt via CleanupOnInterrupt.
func EnsureTearDown(t *testing.T, clients *Clients, names *ResourceNames) {
- EnsureCleanup(t, func() { TearDown(clients, names) })
+ EnsureCleanup(t, func() {
+ if ServingFlags.SkipCleanupOnFail {
+ t.Log("skipping cleanup")
+ return
+ }
+ TearDown(clients, names)
+ })
}
diff --git a/test/e2e_flags.go b/test/e2e_flags.go
index 73214d7d82d9..1885373fe982 100644
--- a/test/e2e_flags.go
+++ b/test/e2e_flags.go
@@ -40,10 +40,12 @@ type ServingEnvironmentFlags struct {
EnableBetaFeatures bool // Indicates whether we run tests for beta features
DisableLogStream bool // Indicates whether log streaming is disabled
DisableOptionalAPI bool // Indicates whether to skip conformance tests against optional API
+ SkipCleanupOnFail bool // Indicates whether to skip cleanup if test fails
TestNamespace string // Default namespace for Serving E2E/Conformance tests
AltTestNamespace string // Alternative namespace for running cross-namespace tests in
TLSTestNamespace string // Namespace for Serving TLS tests
ExceedingMemoryLimitSize int // Memory size used to trigger a non-200 response when the service is set with 300MB memory limit.
+
}
func initializeServingFlags() *ServingEnvironmentFlags {
@@ -76,6 +78,8 @@ func initializeServingFlags() *ServingEnvironmentFlags {
flag.BoolVar(&f.DisableOptionalAPI, "disable-optional-api", false,
"Set this flag to skip conformance tests against optional API.")
+ flag.BoolVar(&f.SkipCleanupOnFail, "skip-cleanup-on-fail", false, "Set this flag to skip cleanup if test fails.")
+
flag.StringVar(&f.TestNamespace, "test-namespace", "serving-tests",
"Set this flag to change the default namespace for running tests.")
From 2d23214393f2c8ac051d29f33447856dd0c296c6 Mon Sep 17 00:00:00 2001
From: Yanwei Guo
Date: Wed, 2 Feb 2022 07:59:55 -0800
Subject: [PATCH 128/733] Move maxDurationSeconds tests from conformance tests
to e2e tests (#12526)
* move tests to e2e
* fix year
* remove
---
.../api/v1/revision_timeout_test.go | 79 ++------
test/e2e/revision_timeout_test.go | 177 ++++++++++++++++++
2 files changed, 191 insertions(+), 65 deletions(-)
create mode 100644 test/e2e/revision_timeout_test.go
diff --git a/test/conformance/api/v1/revision_timeout_test.go b/test/conformance/api/v1/revision_timeout_test.go
index 15c883d27f94..8033c9ce8704 100644
--- a/test/conformance/api/v1/revision_timeout_test.go
+++ b/test/conformance/api/v1/revision_timeout_test.go
@@ -37,7 +37,7 @@ import (
// sendRequests send a request to "endpoint", returns error if unexpected response code, nil otherwise.
func sendRequest(t *testing.T, clients *test.Clients, endpoint *url.URL,
- initialSleep, sleep time.Duration, expectedResponseCode int, expectedBody string) error {
+ initialSleep, sleep time.Duration, expectedResponseCode int) error {
client, err := pkgtest.NewSpoofingClient(context.Background(), clients.KubeClient, t.Logf, endpoint.Hostname(), test.ServingFlags.ResolvableDomain, test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))
if err != nil {
return fmt.Errorf("error creating Spoofing client: %w", err)
@@ -67,12 +67,6 @@ func sendRequest(t *testing.T, clients *test.Clients, endpoint *url.URL,
if expectedResponseCode != resp.StatusCode {
return fmt.Errorf("response status code = %v, want = %v, response = %v", resp.StatusCode, expectedResponseCode, resp)
}
- if expectedBody != "" {
- gotBody := string(resp.Body)
- if expectedBody != gotBody {
- return fmt.Errorf("response body = %v, want = %v, response = %v", gotBody, expectedBody, resp)
- }
- }
return nil
}
@@ -80,75 +74,30 @@ func sendRequest(t *testing.T, clients *test.Clients, endpoint *url.URL,
func TestRevisionTimeout(t *testing.T) {
t.Parallel()
clients := test.Setup(t)
- neverExpireMaxDurationSeconds := int64(100)
testCases := []struct {
- name string
- timeoutSeconds int64
- maxDurationSeconds int64
- initialSleep time.Duration
- sleep time.Duration
- expectedStatus int
- expectedBody string
+ name string
+ timeoutSeconds int64
+ initialSleep time.Duration
+ sleep time.Duration
+ expectedStatus int
+ expectedBody string
}{{
- name: "does not exceed timeout seconds, no max duration timeout set",
+ name: "does not exceed timeout seconds",
timeoutSeconds: 10,
initialSleep: 2 * time.Second,
expectedStatus: http.StatusOK,
}, {
- name: "exceeds timeout seconds, no max duration timeout set",
+ name: "exceeds timeout seconds",
timeoutSeconds: 10,
initialSleep: 12 * time.Second,
expectedStatus: http.StatusGatewayTimeout,
- expectedBody: "request timeout",
}, {
- name: "writes first byte before timeout, no max duration timeout set",
+ name: "writes first byte before timeout",
timeoutSeconds: 10,
expectedStatus: http.StatusOK,
sleep: 15 * time.Second,
initialSleep: 0,
- }, {
- name: "does not exceed timeout seconds, long max duration timeout has no effect",
- timeoutSeconds: 10,
- maxDurationSeconds: neverExpireMaxDurationSeconds,
- initialSleep: 2 * time.Second,
- expectedStatus: http.StatusOK,
- }, {
- name: "exceeds timeout seconds, long max duration timeout has no effect",
- timeoutSeconds: 10,
- maxDurationSeconds: neverExpireMaxDurationSeconds,
- initialSleep: 12 * time.Second,
- expectedStatus: http.StatusGatewayTimeout,
- expectedBody: "request timeout",
- }, {
- name: "writes first byte before timeout, long max duration timeout has no effect",
- timeoutSeconds: 10,
- maxDurationSeconds: neverExpireMaxDurationSeconds,
- expectedStatus: http.StatusOK,
- sleep: 15 * time.Second,
- initialSleep: 0,
- }, {
- name: "exceeds max duration timeout",
- timeoutSeconds: 15,
- maxDurationSeconds: 10,
- initialSleep: 12 * time.Second,
- expectedStatus: http.StatusGatewayTimeout,
- expectedBody: "request timeout",
- }, {
- name: "exceeds multiple timeouts",
- timeoutSeconds: 10,
- maxDurationSeconds: 10,
- initialSleep: 12 * time.Second,
- expectedStatus: http.StatusGatewayTimeout,
- expectedBody: "request timeout",
- }, {
- name: "writes first byte (HTTP OK), max duration violated, request can still timeout",
- timeoutSeconds: 10,
- maxDurationSeconds: 12,
- expectedStatus: http.StatusOK,
- sleep: 15 * time.Second,
- initialSleep: 0,
- expectedBody: "request timeout",
}}
for _, tc := range testCases {
@@ -165,7 +114,7 @@ func TestRevisionTimeout(t *testing.T) {
test.EnsureTearDown(t, clients, &names)
t.Log("Creating a new Service ")
- resources, err := v1test.CreateServiceReady(t, clients, &names, WithRevisionTimeoutSeconds(tc.timeoutSeconds), WithMaxDurationSeconds(tc.maxDurationSeconds))
+ resources, err := v1test.CreateServiceReady(t, clients, &names, WithRevisionTimeoutSeconds(tc.timeoutSeconds))
if err != nil {
t.Fatal("Failed to create Service:", err)
}
@@ -185,9 +134,9 @@ func TestRevisionTimeout(t *testing.T) {
t.Fatalf("Error probing %s: %v", serviceURL, err)
}
- if err := sendRequest(t, clients, serviceURL, tc.initialSleep, tc.sleep, tc.expectedStatus, tc.expectedBody); err != nil {
- t.Errorf("Failed request with initialSleep %v, sleep %v, with revision timeout %ds, expecting status %v and body %q: %v",
- tc.initialSleep, tc.sleep, tc.timeoutSeconds, tc.expectedStatus, tc.expectedBody, err)
+ if err := sendRequest(t, clients, serviceURL, tc.initialSleep, tc.sleep, tc.expectedStatus); err != nil {
+ t.Errorf("Failed request with initialSleep %v, sleep %v, with revision timeout %ds, expecting status %v: %v",
+ tc.initialSleep, tc.sleep, tc.timeoutSeconds, tc.expectedStatus, err)
}
})
}
diff --git a/test/e2e/revision_timeout_test.go b/test/e2e/revision_timeout_test.go
new file mode 100644
index 000000000000..9f3cdeee6d14
--- /dev/null
+++ b/test/e2e/revision_timeout_test.go
@@ -0,0 +1,177 @@
+//go:build e2e
+// +build e2e
+
+/*
+Copyright 2022 The Knative Authors
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+
+package e2e
+
+import (
+ "context"
+ "fmt"
+ "net/http"
+ "net/url"
+ "testing"
+ "time"
+
+ pkgtest "knative.dev/pkg/test"
+ "knative.dev/pkg/test/spoof"
+ "knative.dev/serving/test"
+ v1test "knative.dev/serving/test/v1"
+
+ . "knative.dev/serving/pkg/testing/v1"
+)
+
+// sendRequests send a request to "endpoint", returns error if unexpected response code, nil otherwise.
+func sendRequestWithTimeout(t *testing.T, clients *test.Clients, endpoint *url.URL,
+ initialSleep, sleep time.Duration, expectedResponseCode int, expectedBody string) error {
+ client, err := pkgtest.NewSpoofingClient(context.Background(), clients.KubeClient, t.Logf, endpoint.Hostname(), test.ServingFlags.ResolvableDomain, test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))
+ if err != nil {
+ return fmt.Errorf("error creating Spoofing client: %w", err)
+ }
+
+ start := time.Now()
+ defer func() {
+ t.Logf("URL: %v, initialSleep: %v, sleep: %v, request elapsed %v ms", endpoint, initialSleep, sleep,
+ time.Since(start).Milliseconds())
+ }()
+ u, _ := url.Parse(endpoint.String())
+ q := u.Query()
+ q.Set("initialTimeout", fmt.Sprint(initialSleep.Milliseconds()))
+ q.Set("timeout", fmt.Sprint(sleep.Milliseconds()))
+ u.RawQuery = q.Encode()
+ req, err := http.NewRequest(http.MethodGet, u.String(), nil)
+ if err != nil {
+ return fmt.Errorf("failed to create new HTTP request: %w", err)
+ }
+
+ resp, err := client.Do(req)
+ if err != nil {
+ return fmt.Errorf("failed roundtripping: %w", err)
+ }
+
+ t.Logf("Response status code: %v, expected: %v", resp.StatusCode, expectedResponseCode)
+ if expectedResponseCode != resp.StatusCode {
+ return fmt.Errorf("response status code = %v, want = %v, response = %v", resp.StatusCode, expectedResponseCode, resp)
+ }
+ if expectedBody != "" {
+ gotBody := string(resp.Body)
+ if expectedBody != gotBody {
+ return fmt.Errorf("response body = %v, want = %v, response = %v", gotBody, expectedBody, resp)
+ }
+ }
+
+ return nil
+}
+
+func TestRevisionTimeoutAndMaxDuration(t *testing.T) {
+ t.Parallel()
+ clients := test.Setup(t)
+ neverExpireMaxDurationSeconds := int64(100)
+
+ testCases := []struct {
+ name string
+ timeoutSeconds int64
+ maxDurationSeconds int64
+ initialSleep time.Duration
+ sleep time.Duration
+ expectedStatus int
+ expectedBody string
+ }{{
+ name: "does not exceed timeout seconds, long max duration timeout has no effect",
+ timeoutSeconds: 10,
+ maxDurationSeconds: neverExpireMaxDurationSeconds,
+ initialSleep: 2 * time.Second,
+ expectedStatus: http.StatusOK,
+ }, {
+ name: "exceeds timeout seconds, long max duration timeout has no effect",
+ timeoutSeconds: 10,
+ maxDurationSeconds: neverExpireMaxDurationSeconds,
+ initialSleep: 12 * time.Second,
+ expectedStatus: http.StatusGatewayTimeout,
+ expectedBody: "request timeout",
+ }, {
+ name: "writes first byte before timeout, long max duration timeout has no effect",
+ timeoutSeconds: 10,
+ maxDurationSeconds: neverExpireMaxDurationSeconds,
+ expectedStatus: http.StatusOK,
+ sleep: 15 * time.Second,
+ initialSleep: 0,
+ }, {
+ name: "exceeds max duration timeout",
+ timeoutSeconds: 15,
+ maxDurationSeconds: 10,
+ initialSleep: 12 * time.Second,
+ expectedStatus: http.StatusGatewayTimeout,
+ expectedBody: "request timeout",
+ }, {
+ name: "exceeds multiple timeouts",
+ timeoutSeconds: 10,
+ maxDurationSeconds: 10,
+ initialSleep: 12 * time.Second,
+ expectedStatus: http.StatusGatewayTimeout,
+ expectedBody: "request timeout",
+ }, {
+ name: "writes first byte (HTTP OK), max duration violated, request can still timeout",
+ timeoutSeconds: 10,
+ maxDurationSeconds: 12,
+ expectedStatus: http.StatusOK,
+ sleep: 15 * time.Second,
+ initialSleep: 0,
+ expectedBody: "request timeout",
+ }}
+
+ for _, tc := range testCases {
+ tc := tc
+
+ t.Run(tc.name, func(t *testing.T) {
+ t.Parallel()
+
+ names := test.ResourceNames{
+ Service: test.ObjectNameForTest(t),
+ Image: test.Timeout,
+ }
+
+ test.EnsureTearDown(t, clients, &names)
+
+ t.Log("Creating a new Service ")
+ resources, err := v1test.CreateServiceReady(t, clients, &names, WithRevisionTimeoutSeconds(tc.timeoutSeconds), WithMaxDurationSeconds(tc.maxDurationSeconds))
+ if err != nil {
+ t.Fatal("Failed to create Service:", err)
+ }
+
+ serviceURL := resources.Service.Status.URL.URL()
+
+ t.Log("Probing to force at least one pod", serviceURL)
+ if _, err := pkgtest.CheckEndpointState(
+ context.Background(),
+ clients.KubeClient,
+ t.Logf,
+ serviceURL,
+ spoof.IsOneOfStatusCodes(http.StatusOK, http.StatusGatewayTimeout),
+ "CheckSuccessfulResponse",
+ test.ServingFlags.ResolvableDomain,
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ t.Fatalf("Error probing %s: %v", serviceURL, err)
+ }
+
+ if err := sendRequestWithTimeout(t, clients, serviceURL, tc.initialSleep, tc.sleep, tc.expectedStatus, tc.expectedBody); err != nil {
+ t.Errorf("Failed request with initialSleep %v, sleep %v, with revision timeout %ds, expecting status %v and body %q: %v",
+ tc.initialSleep, tc.sleep, tc.timeoutSeconds, tc.expectedStatus, tc.expectedBody, err)
+ }
+ })
+ }
+}
From 26a2553ba4cac1da148b4f7ec7760385230fed08 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Wed, 2 Feb 2022 09:08:55 -0800
Subject: [PATCH 129/733] Update actions (#12582)
Signed-off-by: Knative Automation
---
.github/workflows/knative-release-notes.yaml | 70 +++++++++++---------
1 file changed, 39 insertions(+), 31 deletions(-)
diff --git a/.github/workflows/knative-release-notes.yaml b/.github/workflows/knative-release-notes.yaml
index 999231ca74e7..5b011ba2a700 100644
--- a/.github/workflows/knative-release-notes.yaml
+++ b/.github/workflows/knative-release-notes.yaml
@@ -21,13 +21,13 @@ on:
workflow_dispatch:
inputs:
branch:
- description: 'Branch? (main)'
+ description: 'Branch'
required: true
default: 'main'
- start-sha:
- description: 'Starting SHA? (last tag on branch)'
- end-sha:
- description: 'Ending SHA? (latest HEAD)'
+ start-rev:
+ description: 'Start Tag (defaults to merge-base(branch, prev-branch))'
+ end-rev:
+ description: 'End Tag (defaults to HEAD of the target branch)'
jobs:
release-notes:
@@ -44,6 +44,7 @@ jobs:
go-version: 1.17.x
- name: Install Dependencies
+ # https://github.com/kubernetes/release/tree/master/cmd/release-notes
run: go install k8s.io/release/cmd/release-notes@latest
- name: Check out code
@@ -52,38 +53,45 @@ jobs:
# fetch-depth of 0 indicates all history for all branches and tags.
fetch-depth: 0
- # Note: Defaults needs to run after we check out the repo.
- - name: Defaults
+ - name: Generate Notes
run: |
- echo ORG=$(echo '${{ github.repository }}' | awk -F '/' '{print $1}') >> $GITHUB_ENV
- echo REPO=$(echo '${{ github.repository }}' | awk -F '/' '{print $2}') >> $GITHUB_ENV
-
- echo "BRANCH=${{ github.event.inputs.branch }}" >> $GITHUB_ENV
-
- if [[ "${{ github.event.inputs.start-sha }}" != "" ]]; then
- echo "START_SHA=${{ github.event.inputs.start-sha }}" >> $GITHUB_ENV
- else
- # Default Starting SHA (thanks @dprotaso)
- export semver=$(git describe --match "v[0-9]*" --abbrev=0)
- echo "Using ${semver} tag for starting sha."
- echo START_SHA=$(git rev-list -n 1 "${semver}") >> $GITHUB_ENV
+ set -x
+ # The release-notes tool access ENV vars as options
+ # https://github.com/kubernetes/release/tree/master/cmd/release-notes#options
+
+ export ORG=$(echo '${{ github.repository }}' | awk -F '/' '{print $1}')
+ export REPO=$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')
+ export BRANCH="${{ github.event.inputs.branch }}"
+
+ export START_REV=${{ github.event.inputs.start-rev }}
+ export END_REV=${{ github.event.inputs.end-rev }}
+
+ if [[ -z "$END_REV" ]]; then
+ END_REV="origin/$BRANCH"
fi
- if [[ "${{ github.event.inputs.end-sha }}" != "" ]]; then
- echo "END_SHA=${{ github.event.inputs.end-sha }}" >> $GITHUB_ENV
- else
- # Default Ending SHA (thanks @dprotaso)
- echo "END_SHA=$(git rev-list -n 1 HEAD)" >> $GITHUB_ENV
+ # If start rev isn't set find the merge base of
+ # the target branch and the previous branch
+ if [[ -z "$START_REV" ]]; then
+ BRANCHES=$(mktemp)
+ # List of branches sorted by semver descending
+ git branch -r -l "origin/release-[0-9]*\.[0-9]*" | sed 's/ //g' | sort -Vr > "$BRANCHES"
+
+ if [[ "$BRANCH" == "main" ]]; then
+ LAST_BRANCH="$(head -n1 "$BRANCHES")"
+ else
+ # use grep magic to find the next branch
+ # '-A 1' - prints the line after the match which we can parse
+ LAST_BRANCH="$(grep -A 1 "$BRANCH" "$BRANCHES" | tail -n1)"
+ fi
+
+ export START_SHA=$(git merge-base $LAST_BRANCH origin/$BRANCH)
fi
- - name: Generate Notes
- run: |
- # See https://github.com/kubernetes/release/tree/master/cmd/release-notes for options.
- # Note: we are setting env vars in the Defaults step.
release-notes \
- --required-author "" \
- --repo-path "$(pwd)" \
- --output release-notes.md
+ --required-author="" \
+ --output=release-notes.md \
+ --repo-path="$PWD" \
- name: Display Notes
run: |
From 0e6c2d8297fd436bddb8af3e929c8a55d3eb01db Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Wed, 2 Feb 2022 17:36:20 -0800
Subject: [PATCH 130/733] Update community files (#12589)
Signed-off-by: Knative Automation
---
OWNERS_ALIASES | 2 ++
1 file changed, 2 insertions(+)
diff --git a/OWNERS_ALIASES b/OWNERS_ALIASES
index f2b31361fbe7..b10726b64bd5 100644
--- a/OWNERS_ALIASES
+++ b/OWNERS_ALIASES
@@ -71,6 +71,7 @@ aliases:
- dprotaso
- duglin
- evankanderson
+ - itsmurugappan
- julz
- knative-prow-releaser-robot
- knative-prow-robot
@@ -188,6 +189,7 @@ aliases:
- lionelvillard
steering-committee:
- csantanapr
+ - itsmurugappan
- lance
- pmorie
- thisisnotapril
From 792260de988c772d1b1b97934f8e088c320df321 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Wed, 2 Feb 2022 19:50:21 -0800
Subject: [PATCH 131/733] upgrade to latest dependencies (#12583)
bumping knative.dev/caching f91093f...33800d3:
> 33800d3 Update actions (# 599)
> bd74d8c Update community files (# 598)
bumping knative.dev/networking d23a068...8ea3045:
> 8ea3045 Update actions (# 613)
> e266de2 Update actions (# 612)
> 7002b9a Update community files (# 610)
bumping knative.dev/pkg f4b57ae...b619c92:
> b619c92 Update actions (# 2417)
> bab3d0d Update actions (# 2413)
> 671e46d :dizzy: we must use `flags` instead of `pflags`, since this is not working. It seems like pflag.* adds the var to its own flag set, not the one package flag uses, and it doesn't expose the internal flag.Var externally - hence this fix. (# 2414)
> 7880fb4 Update community files (# 2412)
> 8681fe2 Continual tests logging within test scope (# 2293)
Signed-off-by: Knative Automation
---
go.mod | 6 +-
go.sum | 12 +-
.../pkg/injection/sharedmain/main.go | 8 +-
.../knative.dev/pkg/test/upgrade/functions.go | 85 ++++++++++++--
vendor/knative.dev/pkg/test/upgrade/logger.go | 110 ++++++++++++++++++
.../pkg/test/upgrade/private_types.go | 13 ++-
vendor/knative.dev/pkg/test/upgrade/steps.go | 34 +++++-
.../pkg/test/upgrade/suite_execution.go | 9 +-
vendor/knative.dev/pkg/test/upgrade/types.go | 31 ++++-
vendor/modules.txt | 6 +-
10 files changed, 276 insertions(+), 38 deletions(-)
create mode 100644 vendor/knative.dev/pkg/test/upgrade/logger.go
diff --git a/go.mod b/go.mod
index 16acf76e3fd8..fbed9bf16298 100644
--- a/go.mod
+++ b/go.mod
@@ -36,9 +36,9 @@ require (
k8s.io/code-generator v0.22.5
k8s.io/klog v1.0.0 // indirect
k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65
- knative.dev/caching v0.0.0-20220131155330-f91093f141e7
+ knative.dev/caching v0.0.0-20220202132833-33800d337f17
knative.dev/hack v0.0.0-20220201013531-82bfca153560
- knative.dev/networking v0.0.0-20220131174231-d23a06807e6c
- knative.dev/pkg v0.0.0-20220131144930-f4b57aef0006
+ knative.dev/networking v0.0.0-20220202023132-8ea30455281d
+ knative.dev/pkg v0.0.0-20220202132633-b619c92456b9
sigs.k8s.io/yaml v1.3.0
)
diff --git a/go.sum b/go.sum
index 1db032281072..5aa32f79e5bd 100644
--- a/go.sum
+++ b/go.sum
@@ -1781,17 +1781,17 @@ k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b h1:wxEMGetGMur3J1xuGLQY7GEQYg9bZxKn3tKo5k/eYcs=
k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
-knative.dev/caching v0.0.0-20220131155330-f91093f141e7 h1:0p4b9UlTItvD+zWj2JeRl0MrTXWyqy59kHsetdjhxAY=
-knative.dev/caching v0.0.0-20220131155330-f91093f141e7/go.mod h1:kWv5fckKHd9e/OSe6tUHKjUtJryWjytea9mnZxJoPLA=
+knative.dev/caching v0.0.0-20220202132833-33800d337f17 h1:ZgaM/BMHpCpKo9BUhjBKEw5yg96brKiz6g9EBkwjPbg=
+knative.dev/caching v0.0.0-20220202132833-33800d337f17/go.mod h1:kWv5fckKHd9e/OSe6tUHKjUtJryWjytea9mnZxJoPLA=
knative.dev/hack v0.0.0-20220118141833-9b2ed8471e30/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/hack v0.0.0-20220128200847-51a42b2eb63e/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/hack v0.0.0-20220201013531-82bfca153560 h1:JTQwe928hZokY181gjYKeVdxr+s3v95LDkMs7R0fxfE=
knative.dev/hack v0.0.0-20220201013531-82bfca153560/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
-knative.dev/networking v0.0.0-20220131174231-d23a06807e6c h1:0mPVfMikv8wz37qEMSUVXAqoDOn3qRPRSQuxx91nACs=
-knative.dev/networking v0.0.0-20220131174231-d23a06807e6c/go.mod h1:RzkiJ/LyijMaMUa6tOerhI9lGvQYpfDY0VttqQIX0yk=
+knative.dev/networking v0.0.0-20220202023132-8ea30455281d h1:VL/p/arwlyjffwWmTGhs6v9vY3lNIAR+oSgV0tuWqkQ=
+knative.dev/networking v0.0.0-20220202023132-8ea30455281d/go.mod h1:RzkiJ/LyijMaMUa6tOerhI9lGvQYpfDY0VttqQIX0yk=
knative.dev/pkg v0.0.0-20220129160148-ca64d3b3ea8c/go.mod h1:BML2uvSEBhY/cpEsAyWv1+vLy2fxNk8VDJ9fT+D0tj4=
-knative.dev/pkg v0.0.0-20220131144930-f4b57aef0006 h1:0Kv7dIOimyHno/7jbQ6LCi15ME+e/b5tY0pwi99kanQ=
-knative.dev/pkg v0.0.0-20220131144930-f4b57aef0006/go.mod h1:bZMFTPDPHV3wXuiQ09UJuEGYYQnfpe81MCxNvsMAiJk=
+knative.dev/pkg v0.0.0-20220202132633-b619c92456b9 h1:/Q3j07pv8xzdIJaJAbcRYHVpXBAwjWuHyJQywmRuHu0=
+knative.dev/pkg v0.0.0-20220202132633-b619c92456b9/go.mod h1:bZMFTPDPHV3wXuiQ09UJuEGYYQnfpe81MCxNvsMAiJk=
pgregory.net/rapid v0.3.3 h1:jCjBsY4ln4Atz78QoBWxUEvAHaFyNDQg9+WU62aCn1U=
pgregory.net/rapid v0.3.3/go.mod h1:UYpPVyjFHzYBGHIxLFoupi8vwk6rXNzRY9OMvVxFIOU=
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
diff --git a/vendor/knative.dev/pkg/injection/sharedmain/main.go b/vendor/knative.dev/pkg/injection/sharedmain/main.go
index b2a1d5117b37..faf0625e194f 100644
--- a/vendor/knative.dev/pkg/injection/sharedmain/main.go
+++ b/vendor/knative.dev/pkg/injection/sharedmain/main.go
@@ -24,10 +24,9 @@ import (
"log"
"net/http"
"os"
+ "strings"
"time"
- "github.com/spf13/pflag"
-
"go.uber.org/automaxprocs/maxprocs" // automatically set GOMAXPROCS based on cgroups
"go.uber.org/zap"
"golang.org/x/sync/errgroup"
@@ -120,13 +119,12 @@ var (
// by name.
func MainNamed(ctx context.Context, component string, ctors ...injection.NamedControllerConstructor) {
- disabledControllers := pflag.StringSlice("disable-controllers", []string{}, "Comma-separated list of disabled controllers.")
+ disabledControllers := flag.String("disable-controllers", "", "Comma-separated list of disabled controllers.")
// HACK: This parses flags, so the above should be set once this runs.
cfg := injection.ParseAndGetRESTConfigOrDie()
- enabledCtors := enabledControllers(*disabledControllers, ctors)
-
+ enabledCtors := enabledControllers(strings.Split(*disabledControllers, ","), ctors)
MainWithConfig(ctx, component, cfg, toControllerConstructors(enabledCtors)...)
}
diff --git a/vendor/knative.dev/pkg/test/upgrade/functions.go b/vendor/knative.dev/pkg/test/upgrade/functions.go
index 07cd80e92ac5..98bf28340dc5 100644
--- a/vendor/knative.dev/pkg/test/upgrade/functions.go
+++ b/vendor/knative.dev/pkg/test/upgrade/functions.go
@@ -17,19 +17,26 @@ limitations under the License.
package upgrade
import (
+ "bytes"
+ "strings"
"time"
+ "go.uber.org/zap/zapcore"
+
"go.uber.org/zap"
)
// Execute the Suite of upgrade tests with a Configuration given.
func (s *Suite) Execute(c Configuration) {
- l := c.logger()
+ l, err := c.logger(c.T)
+ if err != nil {
+ c.T.Fatal("Failed to build logger:", err)
+ return
+ }
se := suiteExecution{
suite: enrichSuite(s),
configuration: c,
failed: false,
- logger: l,
}
l.Info("🏃 Running upgrade test suite...")
@@ -93,10 +100,6 @@ func WaitForStopEvent(bc BackgroundContext, w WaitForStopEventConfiguration) {
}
}
-func (c Configuration) logger() *zap.SugaredLogger {
- return c.Log.Sugar()
-}
-
// Name returns a friendly human readable text.
func (s *StopEvent) Name() string {
return s.name
@@ -107,8 +110,19 @@ func handleStopEvent(
bc BackgroundContext,
wc WaitForStopEventConfiguration,
) {
- bc.Log.Infof("%s have received a stop event: %s", wc.Name, se.Name())
- defer close(se.Finished)
+ bc.Log.Debugf("%s have received a stop event: %s", wc.Name, se.Name())
+
+ logFn := se.logger.Info
+ logFn(wrapLog(bc.logBuffer.Dump()))
+
+ defer func() {
+ defer close(se.Finished)
+ if se.T.Failed() {
+ logFn = se.logger.Error
+ }
+ logFn(wrapLog(bc.logBuffer.Dump()))
+ }()
+
wc.OnStop(se)
}
@@ -160,3 +174,58 @@ func (s *simpleBackgroundOperation) Setup() func(c Context) {
func (s *simpleBackgroundOperation) Handler() func(bc BackgroundContext) {
return s.handler
}
+
+func (b *threadSafeBuffer) Read(p []byte) (n int, err error) {
+ b.Mutex.Lock()
+ defer b.Mutex.Unlock()
+ return b.Buffer.Read(p)
+}
+
+func (b *threadSafeBuffer) Write(p []byte) (n int, err error) {
+ b.Mutex.Lock()
+ defer b.Mutex.Unlock()
+ return b.Buffer.Write(p)
+}
+
+// Dump returns the previous content of the buffer and creates a new
+// empty buffer for future writes.
+func (b *threadSafeBuffer) Dump() string {
+ b.Mutex.Lock()
+ defer b.Mutex.Unlock()
+ buf := b.Buffer.String()
+ b.Buffer = bytes.Buffer{}
+ return buf
+}
+
+// newInMemoryLoggerBuffer creates a logger that writes logs into a byte buffer.
+// This byte buffer is returned and can be used to process the logs at later stage.
+func newInMemoryLoggerBuffer(config Configuration) (*zap.Logger, *threadSafeBuffer) {
+ logConfig := config.logConfig()
+ buf := &threadSafeBuffer{}
+ core := zapcore.NewCore(
+ zapcore.NewConsoleEncoder(logConfig.Config.EncoderConfig),
+ zapcore.AddSync(buf),
+ logConfig.Config.Level)
+
+ var opts []zap.Option
+ if logConfig.Config.Development {
+ opts = append(opts, zap.Development())
+ }
+ if !logConfig.Config.DisableCaller {
+ opts = append(opts, zap.AddCaller())
+ }
+ stackLevel := zap.ErrorLevel
+ if logConfig.Config.Development {
+ stackLevel = zap.WarnLevel
+ }
+ if !logConfig.Config.DisableStacktrace {
+ opts = append(opts, zap.AddStacktrace(stackLevel))
+ }
+ return zap.New(core, opts...), buf
+}
+
+func wrapLog(log string) string {
+ s := strings.Join(strings.Split(log, "\n"), "\n⏳ ")
+ return "Rewind of background logs (prefix ⏳):\n" +
+ "⏳ " + strings.TrimSuffix(s, "⏳ ")
+}
diff --git a/vendor/knative.dev/pkg/test/upgrade/logger.go b/vendor/knative.dev/pkg/test/upgrade/logger.go
new file mode 100644
index 000000000000..903544286577
--- /dev/null
+++ b/vendor/knative.dev/pkg/test/upgrade/logger.go
@@ -0,0 +1,110 @@
+/*
+Copyright 2021 The Knative Authors
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+
+package upgrade
+
+import (
+ "errors"
+ "fmt"
+ "net/url"
+ "strings"
+ "testing"
+
+ "go.uber.org/zap"
+)
+
+const testingTScheme = "testing-t"
+
+var (
+ // ErrInvalidTestingOutputMethod when given invalid testing output method.
+ ErrInvalidTestingOutputMethod = errors.New("invalid testing output method")
+ // ErrNoTestingTRegisteredForTest when no testing.TB registered for test.
+ ErrNoTestingTRegisteredForTest = errors.New("no testing.TB registered for test")
+
+ testingTeeBees = make(map[string]testing.TB)
+)
+
+func (c Configuration) logger(tb testing.TB) (*zap.SugaredLogger, error) {
+ // TODO(mgencur): Remove when dependent repositories use LogConfig instead of Log.
+ // This is for backwards compatibility.
+ if c.Log != nil {
+ return c.Log.Sugar(), nil
+ }
+
+ testName := tb.Name()
+ testingTeeBees[testName] = tb
+ cfg := c.logConfig().Config
+ outs := []string{fmt.Sprintf("%s://Log/%s", testingTScheme, testName)}
+ if isStandardOutputOnly(cfg.OutputPaths) {
+ cfg.OutputPaths = outs
+ } else {
+ cfg.OutputPaths = append(cfg.OutputPaths, outs...)
+ }
+ errOuts := []string{fmt.Sprintf("%s://Error/%s", testingTScheme, testName)}
+ if isStandardOutputOnly(cfg.ErrorOutputPaths) {
+ cfg.ErrorOutputPaths = errOuts
+ } else {
+ cfg.ErrorOutputPaths = append(cfg.ErrorOutputPaths, errOuts...)
+ }
+ err := zap.RegisterSink(testingTScheme, func(url *url.URL) (zap.Sink, error) {
+ var ok bool
+ testName = strings.TrimPrefix(url.Path, "/")
+ tb, ok = testingTeeBees[testName]
+ if !ok {
+ return nil, fmt.Errorf("%w: %s", ErrNoTestingTRegisteredForTest, testName)
+ }
+ switch url.Host {
+ case "Log":
+ return sink{writer: tb.Log}, nil
+ case "Error":
+ return sink{writer: tb.Error}, nil
+ }
+ return nil, fmt.Errorf("%w: %s", ErrInvalidTestingOutputMethod, url.Host)
+ })
+ if err != nil && !strings.HasPrefix(err.Error(), "sink factory already registered") {
+ return nil, err
+ }
+ var logger *zap.Logger
+ logger, err = cfg.Build(c.logConfig().Options...)
+ if err != nil {
+ return nil, err
+ }
+ return logger.Sugar(), nil
+}
+
+type sink struct {
+ writer func(args ...interface{})
+}
+
+func (t sink) Write(bytes []byte) (n int, err error) {
+ msg := string(bytes)
+ t.writer(msg)
+ return len(bytes), nil
+}
+
+func (t sink) Sync() error {
+ return nil
+}
+
+func (t sink) Close() error {
+ return nil
+}
+
+// isStandardOutputOnly checks the output paths and returns true, if they
+// contain only standard outputs.
+func isStandardOutputOnly(paths []string) bool {
+ return len(paths) == 1 && (paths[0] == "stderr" || paths[0] == "stdout")
+}
diff --git a/vendor/knative.dev/pkg/test/upgrade/private_types.go b/vendor/knative.dev/pkg/test/upgrade/private_types.go
index ab930e41bf62..d301b5d68a3f 100644
--- a/vendor/knative.dev/pkg/test/upgrade/private_types.go
+++ b/vendor/knative.dev/pkg/test/upgrade/private_types.go
@@ -16,13 +16,15 @@ limitations under the License.
package upgrade
-import "go.uber.org/zap"
+import (
+ "bytes"
+ "sync"
+)
type suiteExecution struct {
suite *enrichedSuite
configuration Configuration
failed bool
- logger *zap.SugaredLogger
}
type enrichedSuite struct {
@@ -61,3 +63,10 @@ type simpleBackgroundOperation struct {
setup func(c Context)
handler func(bc BackgroundContext)
}
+
+// threadSafeBuffer avoids race conditions on bytes.Buffer.
+// See: https://stackoverflow.com/a/36226525/844449
+type threadSafeBuffer struct {
+ bytes.Buffer
+ sync.Mutex
+}
diff --git a/vendor/knative.dev/pkg/test/upgrade/steps.go b/vendor/knative.dev/pkg/test/upgrade/steps.go
index 1c08038ec74e..e4c270c0a5c4 100644
--- a/vendor/knative.dev/pkg/test/upgrade/steps.go
+++ b/vendor/knative.dev/pkg/test/upgrade/steps.go
@@ -46,13 +46,16 @@ func (se *suiteExecution) preUpgradeTests(num int) {
}
func (se *suiteExecution) startContinualTests(num int) {
- l := se.logger
operations := se.suite.tests.continual
groupTemplate := "%d) 🔄 Starting continual tests. " +
"%d tests are registered."
elementTemplate := `%d.%d) Starting continual tests of "%s".`
numOps := len(operations)
se.configuration.T.Run("ContinualTests", func(t *testing.T) {
+ l, err := se.configuration.logger(t)
+ if err != nil {
+ t.Fatal(err)
+ }
if numOps > 0 {
l.Infof(groupTemplate, num, numOps)
for i := range operations {
@@ -63,17 +66,28 @@ func (se *suiteExecution) startContinualTests(num int) {
return
}
setup := operation.Setup()
+
+ logger, buffer := newInMemoryLoggerBuffer(se.configuration)
t.Run("Setup"+operation.Name(), func(t *testing.T) {
- setup(Context{T: t, Log: l})
+ l, err = se.configuration.logger(t)
+ if err != nil {
+ t.Fatal(err)
+ }
+ setup(Context{T: t, Log: logger.Sugar()})
})
+
handler := operation.Handler()
go func() {
- bc := BackgroundContext{Log: l, Stop: operation.stop}
- handler(bc)
+ handler(BackgroundContext{
+ Log: logger.Sugar(),
+ Stop: operation.stop,
+ logBuffer: buffer,
+ })
}()
-
se.failed = se.failed || t.Failed()
if se.failed {
+ // need to dump logs here, because verify will not be executed.
+ l.Error(wrapLog(buffer.Dump()))
return
}
}
@@ -85,18 +99,26 @@ func (se *suiteExecution) startContinualTests(num int) {
}
func (se *suiteExecution) verifyContinualTests(num int) {
- l := se.logger
testsCount := len(se.suite.tests.continual)
if testsCount > 0 {
se.configuration.T.Run("VerifyContinualTests", func(t *testing.T) {
+ l, err := se.configuration.logger(t)
+ if err != nil {
+ t.Fatal(err)
+ }
l.Infof("%d) ✋ Verifying %d running continual tests.", num, testsCount)
for i, operation := range se.suite.tests.continual {
t.Run(operation.Name(), func(t *testing.T) {
+ l, err = se.configuration.logger(t)
+ if err != nil {
+ t.Fatal(err)
+ }
l.Infof(`%d.%d) Verifying "%s".`, num, i+1, operation.Name())
finished := make(chan struct{})
operation.stop <- StopEvent{
T: t,
Finished: finished,
+ logger: l,
name: "Stop of " + operation.Name(),
}
<-finished
diff --git a/vendor/knative.dev/pkg/test/upgrade/suite_execution.go b/vendor/knative.dev/pkg/test/upgrade/suite_execution.go
index d926d4076187..9f1783e683e4 100644
--- a/vendor/knative.dev/pkg/test/upgrade/suite_execution.go
+++ b/vendor/knative.dev/pkg/test/upgrade/suite_execution.go
@@ -21,8 +21,11 @@ import (
)
func (se *suiteExecution) processOperationGroup(op operationGroup) {
- l := se.logger
se.configuration.T.Run(op.groupName, func(t *testing.T) {
+ l, err := se.configuration.logger(t)
+ if err != nil {
+ t.Fatal(err)
+ }
if len(op.operations) > 0 {
l.Infof(op.groupTemplate, op.num, len(op.operations))
for i, operation := range op.operations {
@@ -33,6 +36,10 @@ func (se *suiteExecution) processOperationGroup(op operationGroup) {
}
handler := operation.Handler()
t.Run(operation.Name(), func(t *testing.T) {
+ l, err = se.configuration.logger(t)
+ if err != nil {
+ t.Fatal(err)
+ }
handler(Context{T: t, Log: l})
})
se.failed = se.failed || t.Failed()
diff --git a/vendor/knative.dev/pkg/test/upgrade/types.go b/vendor/knative.dev/pkg/test/upgrade/types.go
index e4324f4a0c8f..e46a516a4727 100644
--- a/vendor/knative.dev/pkg/test/upgrade/types.go
+++ b/vendor/knative.dev/pkg/test/upgrade/types.go
@@ -84,10 +84,12 @@ type Context struct {
// down to each handler of BackgroundOperation. It contains a StopEvent channel
// which end user should use to obtain a testing.T for error reporting. Until
// StopEvent is sent user may use zap.SugaredLogger to log state of execution if
-// necessary.
+// necessary. The logs are stored in a threadSafeBuffer and flushed to the test
+// output when the test fails.
type BackgroundContext struct {
- Log *zap.SugaredLogger
- Stop <-chan StopEvent
+ Log *zap.SugaredLogger
+ Stop <-chan StopEvent
+ logBuffer *threadSafeBuffer
}
// StopEvent represents an event that is to be received by background operation
@@ -98,6 +100,7 @@ type StopEvent struct {
T *testing.T
Finished chan<- struct{}
name string
+ logger *zap.SugaredLogger
}
// WaitForStopEventConfiguration holds a values to be used be WaitForStopEvent
@@ -113,8 +116,28 @@ type WaitForStopEventConfiguration struct {
// Configuration holds required and optional configuration to run upgrade tests.
type Configuration struct {
- T *testing.T
+ T *testing.T
+ // TODO(mgencur): Remove when dependent repositories migrate to LogConfig.
+ // Keep this for backwards compatibility.
Log *zap.Logger
+ LogConfig
+}
+
+func (c Configuration) logConfig() LogConfig {
+ if len(c.LogConfig.Config.OutputPaths) == 0 {
+ c.LogConfig.Config = zap.NewDevelopmentConfig()
+ }
+ return c.LogConfig
+}
+
+// LogConfig holds the logger configuration. It allows for passing just the
+// logger configuration and also a custom function for building the resulting
+// logger.
+type LogConfig struct {
+ // Config from which the zap.Logger be created.
+ Config zap.Config
+ // Options holds options for the zap.Logger.
+ Options []zap.Option
}
// SuiteExecutor is to execute upgrade test suite.
diff --git a/vendor/modules.txt b/vendor/modules.txt
index c7d487792148..583cf3f2a99b 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -1020,7 +1020,7 @@ k8s.io/utils/buffer
k8s.io/utils/integer
k8s.io/utils/pointer
k8s.io/utils/trace
-# knative.dev/caching v0.0.0-20220131155330-f91093f141e7
+# knative.dev/caching v0.0.0-20220202132833-33800d337f17
## explicit
knative.dev/caching/config
knative.dev/caching/pkg/apis/caching
@@ -1045,7 +1045,7 @@ knative.dev/caching/pkg/client/listers/caching/v1alpha1
## explicit
knative.dev/hack
knative.dev/hack/shell
-# knative.dev/networking v0.0.0-20220131174231-d23a06807e6c
+# knative.dev/networking v0.0.0-20220202023132-8ea30455281d
## explicit
knative.dev/networking/config
knative.dev/networking/pkg
@@ -1075,7 +1075,7 @@ knative.dev/networking/pkg/client/injection/reconciler/networking/v1alpha1/serve
knative.dev/networking/pkg/client/listers/networking/v1alpha1
knative.dev/networking/pkg/ingress
knative.dev/networking/pkg/prober
-# knative.dev/pkg v0.0.0-20220131144930-f4b57aef0006
+# knative.dev/pkg v0.0.0-20220202132633-b619c92456b9
## explicit
knative.dev/pkg/apiextensions/storageversion
knative.dev/pkg/apiextensions/storageversion/cmd/migrate
From 1d9529495e175e7b36d3636d4d5c8739774ef876 Mon Sep 17 00:00:00 2001
From: Yanwei Guo
Date: Wed, 2 Feb 2022 21:52:20 -0800
Subject: [PATCH 132/733] Adds a flag to allow customized request headers in
conformance tests (#12540)
* add flag
* add validation
* add comment
* check empty
---
test/conformance/api/shared/util.go | 1 +
test/conformance/api/v1/blue_green_test.go | 3 ++-
test/conformance/api/v1/generatename_test.go | 3 ++-
test/conformance/api/v1/resources_test.go | 4 ++-
.../api/v1/revision_timeout_test.go | 4 ++-
test/conformance/api/v1/route_test.go | 3 ++-
test/conformance/api/v1/service_test.go | 14 ++++++++--
.../api/v1/single_threaded_test.go | 4 ++-
test/conformance/api/v1/util.go | 4 ++-
test/conformance/api/v1/volumes_test.go | 3 ++-
.../api/v1alpha1/domain_mapping_test.go | 9 ++++---
.../api/v1beta1/domain_mapping_test.go | 9 ++++---
.../runtime/readiness_probe_test.go | 2 ++
test/conformance/runtime/util.go | 2 +-
test/e2e_flags.go | 26 ++++++++++++++++++-
test/prober.go | 22 +++++++++++++---
16 files changed, 91 insertions(+), 22 deletions(-)
diff --git a/test/conformance/api/shared/util.go b/test/conformance/api/shared/util.go
index 497057b12d77..34a5aed9d439 100644
--- a/test/conformance/api/shared/util.go
+++ b/test/conformance/api/shared/util.go
@@ -103,6 +103,7 @@ func sendRequests(ctx context.Context, client *spoof.SpoofingClient, url *url.UR
if err != nil {
return err
}
+ spoof.WithHeader(test.ServingFlags.RequestHeader())(req)
resp, err := client.Do(req)
if err != nil {
diff --git a/test/conformance/api/v1/blue_green_test.go b/test/conformance/api/v1/blue_green_test.go
index 9f709aafa9f7..fee68c5e02f6 100644
--- a/test/conformance/api/v1/blue_green_test.go
+++ b/test/conformance/api/v1/blue_green_test.go
@@ -138,7 +138,8 @@ func TestBlueGreenRoute(t *testing.T) {
spoof.IsStatusOK,
"CheckSuccessfulResponse",
test.ServingFlags.ResolvableDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", greenURL, err)
}
diff --git a/test/conformance/api/v1/generatename_test.go b/test/conformance/api/v1/generatename_test.go
index a9de309568dc..9fae99658297 100644
--- a/test/conformance/api/v1/generatename_test.go
+++ b/test/conformance/api/v1/generatename_test.go
@@ -102,7 +102,8 @@ func canServeRequests(t *testing.T, clients *test.Clients, route *v1.Route) erro
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(test.HelloWorldText)),
"CheckEndpointToServeText",
test.ServingFlags.ResolvableDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader()))
if err != nil {
return fmt.Errorf("the endpoint for Route %s at %s didn't serve the expected text %q: %w", route.Name, url, test.HelloWorldText, err)
}
diff --git a/test/conformance/api/v1/resources_test.go b/test/conformance/api/v1/resources_test.go
index fa6ddfcb168f..af8107d35822 100644
--- a/test/conformance/api/v1/resources_test.go
+++ b/test/conformance/api/v1/resources_test.go
@@ -72,7 +72,8 @@ func TestCustomResourcesLimits(t *testing.T) {
spoof.MatchesAllOf(spoof.IsStatusOK),
"ResourceTestServesText",
test.ServingFlags.ResolvableDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader()))
if err != nil {
t.Fatalf("Error probing %s: %v", endpoint, err)
}
@@ -88,6 +89,7 @@ func TestCustomResourcesLimits(t *testing.T) {
if err != nil {
return nil, err
}
+ spoof.WithHeader(test.ServingFlags.RequestHeader())(req)
return client.Do(req)
}
diff --git a/test/conformance/api/v1/revision_timeout_test.go b/test/conformance/api/v1/revision_timeout_test.go
index 8033c9ce8704..9f29bbfe28f6 100644
--- a/test/conformance/api/v1/revision_timeout_test.go
+++ b/test/conformance/api/v1/revision_timeout_test.go
@@ -57,6 +57,7 @@ func sendRequest(t *testing.T, clients *test.Clients, endpoint *url.URL,
if err != nil {
return fmt.Errorf("failed to create new HTTP request: %w", err)
}
+ spoof.WithHeader(test.ServingFlags.RequestHeader())(req)
resp, err := client.Do(req)
if err != nil {
@@ -130,7 +131,8 @@ func TestRevisionTimeout(t *testing.T) {
spoof.IsOneOfStatusCodes(http.StatusOK, http.StatusGatewayTimeout),
"CheckSuccessfulResponse",
test.ServingFlags.ResolvableDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", serviceURL, err)
}
diff --git a/test/conformance/api/v1/route_test.go b/test/conformance/api/v1/route_test.go
index 36bdd9778602..d1d823365350 100644
--- a/test/conformance/api/v1/route_test.go
+++ b/test/conformance/api/v1/route_test.go
@@ -52,7 +52,8 @@ func assertResourcesUpdatedWhenRevisionIsReady(t *testing.T, clients *test.Clien
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(expectedText)),
"CheckEndpointToServeText",
test.ServingFlags.ResolvableDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader()))
if err != nil {
t.Fatalf("The endpoint for Route %s at %s didn't serve the expected text %q: %v", names.Route, url, expectedText, err)
}
diff --git a/test/conformance/api/v1/service_test.go b/test/conformance/api/v1/service_test.go
index 90bb0089f458..3a0d9787ecec 100644
--- a/test/conformance/api/v1/service_test.go
+++ b/test/conformance/api/v1/service_test.go
@@ -29,6 +29,7 @@ import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"knative.dev/pkg/ptr"
pkgtest "knative.dev/pkg/test"
+ "knative.dev/pkg/test/spoof"
v1 "knative.dev/serving/pkg/apis/serving/v1"
"knative.dev/serving/test"
v1test "knative.dev/serving/test/v1"
@@ -130,7 +131,11 @@ func TestServiceCreateAndUpdate(t *testing.T) {
}
// We start a background prober to test if Route is always healthy even during Route update.
- prober := test.RunRouteProber(t.Logf, clients, names.URL, test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))
+ prober := test.RunRouteProber(
+ t.Logf,
+ clients, names.URL,
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader()))
defer test.AssertProberDefault(t, prober)
// Update Container Image
@@ -287,7 +292,12 @@ func TestServiceBYOName(t *testing.T) {
}
// We start a background prober to test if Route is always healthy even during Route update.
- prober := test.RunRouteProber(t.Logf, clients, names.URL, test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))
+ prober := test.RunRouteProber(
+ t.Logf,
+ clients,
+ names.URL,
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader()))
defer test.AssertProberDefault(t, prober)
// Update Container Image
diff --git a/test/conformance/api/v1/single_threaded_test.go b/test/conformance/api/v1/single_threaded_test.go
index 04c68347f988..0a740ae067c6 100644
--- a/test/conformance/api/v1/single_threaded_test.go
+++ b/test/conformance/api/v1/single_threaded_test.go
@@ -71,7 +71,8 @@ func TestSingleConcurrency(t *testing.T) {
spoof.IsStatusOK,
"CheckSuccessfulResponse",
test.ServingFlags.ResolvableDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", url, err)
}
@@ -94,6 +95,7 @@ func TestSingleConcurrency(t *testing.T) {
if err != nil {
return fmt.Errorf("error creating http request: %w", err)
}
+ spoof.WithHeader(test.ServingFlags.RequestHeader())(req)
for {
select {
diff --git a/test/conformance/api/v1/util.go b/test/conformance/api/v1/util.go
index 0ae094aa2c77..67891885aa6d 100644
--- a/test/conformance/api/v1/util.go
+++ b/test/conformance/api/v1/util.go
@@ -50,6 +50,7 @@ func checkForExpectedResponses(ctx context.Context, t testing.TB, clients *test.
if err != nil {
return err
}
+ spoof.WithHeader(test.ServingFlags.RequestHeader())(req)
_, err = client.Poll(req, spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesAllBodies(expectedResponses...)))
return err
}
@@ -136,7 +137,8 @@ func validateDataPlane(t testing.TB, clients *test.Clients, names test.ResourceN
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(expectedText)),
"WaitForEndpointToServeText",
test.ServingFlags.ResolvableDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader()))
if err != nil {
return fmt.Errorf("the endpoint for Route %s at %s didn't serve the expected text %q: %w", names.Route, names.URL, expectedText, err)
}
diff --git a/test/conformance/api/v1/volumes_test.go b/test/conformance/api/v1/volumes_test.go
index c0d37a3e0a00..db3f541b50f6 100644
--- a/test/conformance/api/v1/volumes_test.go
+++ b/test/conformance/api/v1/volumes_test.go
@@ -480,7 +480,8 @@ func TestProjectedServiceAccountToken(t *testing.T) {
spoof.MatchesAllOf(spoof.IsStatusOK, isJWT),
"CheckEndpointToServeTheToken",
test.ServingFlags.ResolvableDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Error(err)
}
}
diff --git a/test/conformance/api/v1alpha1/domain_mapping_test.go b/test/conformance/api/v1alpha1/domain_mapping_test.go
index 03d6f06bf9a2..a3645e596ee4 100644
--- a/test/conformance/api/v1alpha1/domain_mapping_test.go
+++ b/test/conformance/api/v1alpha1/domain_mapping_test.go
@@ -117,7 +117,8 @@ func TestDomainMapping(t *testing.T) {
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(test.PizzaPlanetText1)),
"CheckSuccessfulResponse",
resolvableCustomDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", endpoint, err)
}
@@ -184,7 +185,8 @@ func TestDomainMapping(t *testing.T) {
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(test.PizzaPlanetText1)),
"CheckSuccessfulResponse",
resolvableCustomDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", endpoint, err)
}
@@ -217,7 +219,8 @@ func TestDomainMapping(t *testing.T) {
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(test.PizzaPlanetText2)),
"CheckSuccessfulResponse",
resolvableCustomDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", endpoint, err)
}
}
diff --git a/test/conformance/api/v1beta1/domain_mapping_test.go b/test/conformance/api/v1beta1/domain_mapping_test.go
index 0d04ace65a16..f18b790c800f 100644
--- a/test/conformance/api/v1beta1/domain_mapping_test.go
+++ b/test/conformance/api/v1beta1/domain_mapping_test.go
@@ -117,7 +117,8 @@ func TestDomainMapping(t *testing.T) {
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(test.PizzaPlanetText1)),
"CheckSuccessfulResponse",
resolvableCustomDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", endpoint, err)
}
@@ -184,7 +185,8 @@ func TestDomainMapping(t *testing.T) {
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(test.PizzaPlanetText1)),
"CheckSuccessfulResponse",
resolvableCustomDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", endpoint, err)
}
@@ -217,7 +219,8 @@ func TestDomainMapping(t *testing.T) {
spoof.MatchesAllOf(spoof.IsStatusOK, spoof.MatchesBody(test.PizzaPlanetText2)),
"CheckSuccessfulResponse",
resolvableCustomDomain,
- test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS)); err != nil {
+ test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader())); err != nil {
t.Fatalf("Error probing %s: %v", endpoint, err)
}
}
diff --git a/test/conformance/runtime/readiness_probe_test.go b/test/conformance/runtime/readiness_probe_test.go
index 6541681a4a71..70e243b214b9 100644
--- a/test/conformance/runtime/readiness_probe_test.go
+++ b/test/conformance/runtime/readiness_probe_test.go
@@ -135,6 +135,7 @@ func TestProbeRuntime(t *testing.T) {
"readinessIsReady",
test.ServingFlags.ResolvableDomain,
test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader()),
); err != nil {
t.Fatalf("The endpoint for Route %s at %s didn't return success: %v", names.Route, url, err)
}
@@ -240,6 +241,7 @@ func waitReadyThenStartFailing(t *testing.T, clients *test.Clients, names test.R
"readinessIsReady",
test.ServingFlags.ResolvableDomain,
test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS),
+ spoof.WithHeader(test.ServingFlags.RequestHeader()),
); err != nil {
t.Fatalf("The endpoint for Route %s at %s didn't return success: %v", names.Route, url, err)
}
diff --git a/test/conformance/runtime/util.go b/test/conformance/runtime/util.go
index 1b1d3923a571..0dcdbba3c47f 100644
--- a/test/conformance/runtime/util.go
+++ b/test/conformance/runtime/util.go
@@ -63,7 +63,7 @@ func fetchRuntimeInfo(
spoof.IsStatusOK,
"RuntimeInfo",
test.ServingFlags.ResolvableDomain,
- append(reqOpts, test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))...)
+ append(reqOpts, spoof.WithHeader(test.ServingFlags.RequestHeader()), test.AddRootCAtoTransport(context.Background(), t.Logf, clients, test.ServingFlags.HTTPS))...)
if err != nil {
return nil, nil, err
}
diff --git a/test/e2e_flags.go b/test/e2e_flags.go
index 1885373fe982..a0cc8e6eb202 100644
--- a/test/e2e_flags.go
+++ b/test/e2e_flags.go
@@ -21,6 +21,8 @@ package test
import (
"flag"
+ "net/http"
+ "strings"
// Load the generic flags of knative.dev/pkg too.
_ "knative.dev/pkg/test"
@@ -45,7 +47,7 @@ type ServingEnvironmentFlags struct {
AltTestNamespace string // Alternative namespace for running cross-namespace tests in
TLSTestNamespace string // Namespace for Serving TLS tests
ExceedingMemoryLimitSize int // Memory size used to trigger a non-200 response when the service is set with 300MB memory limit.
-
+ RequestHeaders string // Extra HTTP request headers sent to the testing deployed KServices.
}
func initializeServingFlags() *ServingEnvironmentFlags {
@@ -93,5 +95,27 @@ func initializeServingFlags() *ServingEnvironmentFlags {
"Set this flag to the MB of memory consumed by your service in resource limit tests. "+
"You service is set with 300 MB memory limit and shoud return a non-200 response when consuming such amount of memory.")
+ flag.StringVar(&f.RequestHeaders, "request-headers", "",
+ "Set this flag to add extra HTTP request headers sent to the testing deployed KServices. "+
+ "Format: -request-headers=key1,value1,key2,value2")
+
return &f
}
+
+// RequestHeader returns a http.Header object including key-value header pairs passed via testing flag.
+func (f *ServingEnvironmentFlags) RequestHeader() http.Header {
+ header := make(http.Header)
+
+ if f.RequestHeaders != "" {
+ headers := strings.Split(f.RequestHeaders, ",")
+ if len(headers)%2 != 0 {
+ panic("incorrect input of request headers: " + f.RequestHeaders)
+ }
+
+ for i := 0; i < len(headers); i += 2 {
+ header.Add(headers[i], headers[i+1])
+ }
+ }
+
+ return header
+}
diff --git a/test/prober.go b/test/prober.go
index 226c5a59b3e8..b70e77ce2b59 100644
--- a/test/prober.go
+++ b/test/prober.go
@@ -108,6 +108,7 @@ type manager struct {
m sync.RWMutex
probes map[*url.URL]Prober
transportOptions []spoof.TransportOption
+ requestOptions []spoof.RequestOption
}
var _ ProberManager = (*manager)(nil)
@@ -149,6 +150,9 @@ func (m *manager) Spawn(url *url.URL) Prober {
if err != nil {
return fmt.Errorf("failed to generate request: %w", err)
}
+ for _, o := range m.requestOptions {
+ o(req)
+ }
// We keep polling the domain and accumulate success rates
// to ultimately establish the SLI and compare to the SLO.
@@ -212,18 +216,28 @@ func (m *manager) Foreach(f func(url *url.URL, p Prober)) {
}
// NewProberManager creates a new manager for probes.
-func NewProberManager(logf logging.FormatLogger, clients *Clients, minProbes int64, opts ...spoof.TransportOption) ProberManager {
- return &manager{
+func NewProberManager(logf logging.FormatLogger, clients *Clients, minProbes int64, opts ...interface{}) ProberManager {
+ m := manager{
logf: logf,
clients: clients,
minProbes: minProbes,
probes: make(map[*url.URL]Prober),
- transportOptions: opts,
+ transportOptions: []spoof.TransportOption{},
+ requestOptions: []spoof.RequestOption{},
+ }
+ for _, opt := range opts {
+ switch o := opt.(type) {
+ case spoof.RequestOption:
+ m.requestOptions = append(m.requestOptions, o)
+ case spoof.TransportOption:
+ m.transportOptions = append(m.transportOptions, o)
+ }
}
+ return &m
}
// RunRouteProber starts a single Prober of the given domain.
-func RunRouteProber(logf logging.FormatLogger, clients *Clients, url *url.URL, opts ...spoof.TransportOption) Prober {
+func RunRouteProber(logf logging.FormatLogger, clients *Clients, url *url.URL, opts ...interface{}) Prober {
// Default to 10 probes
pm := NewProberManager(logf, clients, 10, opts...)
pm.Spawn(url)
From 82ad2cdac709b88ed9190daa18594c3d7ec0e3d5 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 3 Feb 2022 09:09:21 -0800
Subject: [PATCH 133/733] Update net-certmanager nightly (#12590)
bumping knative.dev/net-certmanager 6b6cb57...d2a7c41:
> d2a7c41 upgrade to latest dependencies (# 350)
> 55a76bd Update community files (# 345)
Signed-off-by: Knative Automation
---
.../cert-manager-latest/net-certmanager.yaml | 44 +++++++++----------
1 file changed, 22 insertions(+), 22 deletions(-)
diff --git a/third_party/cert-manager-latest/net-certmanager.yaml b/third_party/cert-manager-latest/net-certmanager.yaml
index 45ea46a57d69..f49cd52da7ff 100644
--- a/third_party/cert-manager-latest/net-certmanager.yaml
+++ b/third_party/cert-manager-latest/net-certmanager.yaml
@@ -19,9 +19,9 @@ metadata:
name: knative-serving-certmanager
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
serving.knative.dev/controller: "true"
networking.knative.dev/certificate-provider: cert-manager
rules:
@@ -53,9 +53,9 @@ metadata:
name: config.webhook.net-certmanager.networking.internal.knative.dev
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
networking.knative.dev/certificate-provider: cert-manager
webhooks:
- admissionReviewVersions:
@@ -95,9 +95,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
networking.knative.dev/certificate-provider: cert-manager
---
@@ -122,9 +122,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
networking.knative.dev/certificate-provider: cert-manager
data:
_example: |
@@ -172,9 +172,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
networking.knative.dev/certificate-provider: cert-manager
spec:
selector:
@@ -187,16 +187,16 @@ spec:
labels:
app: net-certmanager-controller
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/controller@sha256:c4156eac574c2367d112781d0061ed3501c91af1cc0040e823cc269f82cef406
+ image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/controller@sha256:076de0c3d2e5c22346808ac3a44910d6cdb9d42824adc5fdb10280383974d2e9
resources:
requests:
cpu: 30m
@@ -235,9 +235,9 @@ metadata:
labels:
app: net-certmanager-controller
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
networking.knative.dev/certificate-provider: cert-manager
name: net-certmanager-controller
namespace: knative-serving
@@ -275,9 +275,9 @@ metadata:
namespace: knative-serving
labels:
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
networking.knative.dev/certificate-provider: cert-manager
spec:
selector:
@@ -291,17 +291,17 @@ spec:
labels:
app: net-certmanager-webhook
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
role: net-certmanager-webhook
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/webhook@sha256:795a02555aa7ff6d359bd399aae626d8810c7f1b82b96099e3806f8caa622cb4
+ image: gcr.io/knative-nightly/knative.dev/net-certmanager/cmd/webhook@sha256:65da247587a5187f2e38f6fb3400582bb72a4dd26d531ed833d179730e0831cb
resources:
requests:
cpu: 20m
@@ -361,9 +361,9 @@ metadata:
labels:
role: net-certmanager-webhook
app.kubernetes.io/component: net-certmanager
- app.kubernetes.io/version: "20220201-6b6cb57f"
+ app.kubernetes.io/version: "20220203-d2a7c418"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220201-6b6cb57f"
+ serving.knative.dev/release: "v20220203-d2a7c418"
networking.knative.dev/certificate-provider: cert-manager
spec:
ports:
From 997dea3cd481a4eb5d508aacc11fcaee3c23c35d Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 3 Feb 2022 11:32:21 -0800
Subject: [PATCH 134/733] Update net-kourier nightly (#12592)
bumping knative.dev/net-kourier a31d8bc...0f26684:
> 0f26684 Update community files (# 762)
Signed-off-by: Knative Automation
---
third_party/kourier-latest/kourier.yaml | 46 ++++++++++++-------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/third_party/kourier-latest/kourier.yaml b/third_party/kourier-latest/kourier.yaml
index 2b679fee32c5..e70bcc68addc 100644
--- a/third_party/kourier-latest/kourier.yaml
+++ b/third_party/kourier-latest/kourier.yaml
@@ -20,8 +20,8 @@ metadata:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/name: knative-serving
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
- serving.knative.dev/release: "v20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
+ serving.knative.dev/release: "v20220203-0f26684f"
---
# Copyright 2020 The Knative Authors
@@ -46,9 +46,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
data:
envoy-bootstrap.yaml: |
dynamic_resources:
@@ -152,9 +152,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
data:
_example: |
################################
@@ -200,9 +200,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
@@ -212,9 +212,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
rules:
- apiGroups: [""]
resources: ["events"]
@@ -242,9 +242,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
@@ -277,9 +277,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
spec:
replicas: 1
selector:
@@ -291,7 +291,7 @@ spec:
app: net-kourier-controller
spec:
containers:
- - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:5c0e3043cddad52c8f856c12f462800a74f99ef432e0fd74a6600824739e715d
+ - image: gcr.io/knative-nightly/knative.dev/net-kourier/cmd/kourier@sha256:1ea042c230bd1b0b31c2b7789192bb8b2129fd59fed2c7e3771fe8e200c5435e
name: controller
env:
- name: CERTS_SECRET_NAMESPACE
@@ -331,9 +331,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
spec:
ports:
- name: grpc-xds
@@ -367,9 +367,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
spec:
strategy:
type: RollingUpdate
@@ -445,9 +445,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
spec:
ports:
- name: http2
@@ -470,9 +470,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: kourier
app.kubernetes.io/component: net-kourier
- app.kubernetes.io/version: "20220131-a31d8bca"
+ app.kubernetes.io/version: "20220203-0f26684f"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220131-a31d8bca"
+ serving.knative.dev/release: "v20220203-0f26684f"
spec:
ports:
- name: http2
From 62d5aa396363b0aea0fa259e2c4dbd9a7507f682 Mon Sep 17 00:00:00 2001
From: Paul Schweigert
Date: Thu, 3 Feb 2022 16:33:21 -0500
Subject: [PATCH 135/733] Updates selector labels to `app.kubernetes.io`
(#12587)
* updates selector labels to k8s recommended ones
* one more to fix
* using the right label
* match labels not expressions
---
config/core/webhooks/configmap-validation.yaml | 5 ++---
test/e2e-auto-tls-tests.sh | 3 ++-
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/config/core/webhooks/configmap-validation.yaml b/config/core/webhooks/configmap-validation.yaml
index 2ddb1f61982a..9991724afa0c 100644
--- a/config/core/webhooks/configmap-validation.yaml
+++ b/config/core/webhooks/configmap-validation.yaml
@@ -31,7 +31,6 @@ webhooks:
sideEffects: None
name: config.webhook.serving.knative.dev
namespaceSelector:
- matchExpressions:
- - key: serving.knative.dev/release
- operator: Exists
+ matchLabels:
+ app.kubernetes.io/name: knative-serving
timeoutSeconds: 10
diff --git a/test/e2e-auto-tls-tests.sh b/test/e2e-auto-tls-tests.sh
index d893e0d4c568..4eda7f30bb18 100755
--- a/test/e2e-auto-tls-tests.sh
+++ b/test/e2e-auto-tls-tests.sh
@@ -51,7 +51,8 @@ metadata:
name: config-domain
namespace: ${SYSTEM_NAMESPACE}
labels:
- serving.knative.dev/release: devel
+ app.kubernetes.io/name: knative-serving
+ app.kubernetes.io/version: devel
data:
${CUSTOM_DOMAIN_SUFFIX}: ""
EOF
From fc43e7cbfc20d7559de7845427cc8454f87c71a0 Mon Sep 17 00:00:00 2001
From: Nader Ziada
Date: Thu, 3 Feb 2022 18:21:20 -0500
Subject: [PATCH 136/733] add script to run performance tests using kperf
(#12549)
* add script to run performance tests using kperf
* update script with review comments
* add run_kperf_tool func and don't use enable_ha
* fix linter issues
add fail_test in case of failure from kperf
* move cluster updates to ytt overlay files
* use verbose command option for kperf
---
.../ytt/performance/kperf-test-namespace.yaml | 5 ++
.../overlay-activator-min-replicas.yaml | 11 ++++
.../overlay-config-autoscaler.yaml | 8 +++
.../performance/overlay-config-network.yaml | 10 +++
test/e2e-common.sh | 9 +++
test/performance/performance-tests.sh | 65 +++++++++++++++++++
6 files changed, 108 insertions(+)
create mode 100644 test/config/ytt/performance/kperf-test-namespace.yaml
create mode 100644 test/config/ytt/performance/overlay-activator-min-replicas.yaml
create mode 100644 test/config/ytt/performance/overlay-config-autoscaler.yaml
create mode 100644 test/config/ytt/performance/overlay-config-network.yaml
create mode 100755 test/performance/performance-tests.sh
diff --git a/test/config/ytt/performance/kperf-test-namespace.yaml b/test/config/ytt/performance/kperf-test-namespace.yaml
new file mode 100644
index 000000000000..0c05831a93e2
--- /dev/null
+++ b/test/config/ytt/performance/kperf-test-namespace.yaml
@@ -0,0 +1,5 @@
+---
+apiVersion: v1
+kind: Namespace
+metadata:
+ name: kperf
diff --git a/test/config/ytt/performance/overlay-activator-min-replicas.yaml b/test/config/ytt/performance/overlay-activator-min-replicas.yaml
new file mode 100644
index 000000000000..7fdcf2a1a003
--- /dev/null
+++ b/test/config/ytt/performance/overlay-activator-min-replicas.yaml
@@ -0,0 +1,11 @@
+#@ load("@ytt:overlay", "overlay")
+#@ load("@ytt:data", "data")
+
+#@ load("helpers.lib.yaml", "system_resource")
+
+#@overlay/match by=system_resource(name="activator", kind="HorizontalPodAutoscaler"), expects=1
+---
+#@overlay/match-child-defaults missing_ok=True
+spec:
+ minReplicas: 10
+ maxReplicas: 10
diff --git a/test/config/ytt/performance/overlay-config-autoscaler.yaml b/test/config/ytt/performance/overlay-config-autoscaler.yaml
new file mode 100644
index 000000000000..cb232fff3fad
--- /dev/null
+++ b/test/config/ytt/performance/overlay-config-autoscaler.yaml
@@ -0,0 +1,8 @@
+#@ load("@ytt:overlay", "overlay")
+#@ load("helpers.lib.yaml", "system_configmap")
+
+#@overlay/match by=system_configmap("config-autoscaler"), expects=1
+---
+#@overlay/match-child-defaults missing_ok=True
+data:
+ scale-to-zero-grace-period: "10s"
diff --git a/test/config/ytt/performance/overlay-config-network.yaml b/test/config/ytt/performance/overlay-config-network.yaml
new file mode 100644
index 000000000000..3cf5cb519f7e
--- /dev/null
+++ b/test/config/ytt/performance/overlay-config-network.yaml
@@ -0,0 +1,10 @@
+#@ load("@ytt:overlay", "overlay")
+#@ load("helpers.lib.yaml", "system_configmap")
+
+#@overlay/match by=system_configmap("config-network"), expects=1
+---
+#! Ensure gradual rollout is enabled.
+
+#@overlay/match-child-defaults missing_ok=True
+data:
+ rolloutDuration: "240"
diff --git a/test/e2e-common.sh b/test/e2e-common.sh
index 514814fb547d..5648fe560fda 100644
--- a/test/e2e-common.sh
+++ b/test/e2e-common.sh
@@ -35,6 +35,7 @@ export HTTPS=0
export SHORT=0
export ENABLE_HA=0
export MESH=0
+export PERF=0
export KIND=0
export CLUSTER_DOMAIN=cluster.local
@@ -109,6 +110,10 @@ function parse_flags() {
readonly MESH=0
return 1
;;
+ --perf)
+ readonly PERF=1
+ return 1
+ ;;
--enable-ha)
readonly ENABLE_HA=1
return 1
@@ -281,6 +286,10 @@ function install() {
YTT_FILES+=("${REPO_ROOT_DIR}/test/config/ytt/ha")
fi
+ if (( PERF )); then
+ YTT_FILES+=("${REPO_ROOT_DIR}/test/config/ytt/performance")
+ fi
+
if (( KIND )); then
YTT_FILES+=("${REPO_ROOT_DIR}/test/config/ytt/kind/core")
YTT_FILES+=("${REPO_ROOT_DIR}/test/config/ytt/kind/ingress/${ingress}-kind.yaml")
diff --git a/test/performance/performance-tests.sh b/test/performance/performance-tests.sh
new file mode 100755
index 000000000000..d63964dd368b
--- /dev/null
+++ b/test/performance/performance-tests.sh
@@ -0,0 +1,65 @@
+#!/usr/bin/env bash
+
+# Copyright 2022 The Knative Authors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# This script runs the end-to-end tests against Knative Serving built from source.
+# It is started by prow for each PR. For convenience, it can also be executed manually.
+
+# If you already have a Kubernetes cluster setup and kubectl pointing
+# to it, call this script with the --run-tests arguments and it will use
+# the cluster and run the tests.
+
+# Calling this script without arguments will create a new cluster in
+# project $PROJECT_ID, start knative in it, run the tests and delete the
+# cluster.
+
+source $(dirname $0)/../e2e-common.sh
+
+# Skip installing istio as an add-on.
+# Temporarily increasing the cluster size for serving tests to rule out
+# resource/eviction as causes of flakiness.
+initialize --skip-istio-addon --min-nodes=4 --max-nodes=4 --perf --cluster-version=1.21 "$@"
+
+header "Running tests"
+
+function run_kperf() {
+ run_go_tool knative.dev/kperf/cmd/kperf kperf "$@"
+}
+
+mkdir -p "${ARTIFACTS}/kperf"
+
+header "Running performance tests"
+export TIMEOUT=30m
+
+# create services
+run_kperf service generate --number 100 --batch 30 --concurrency 10 --interval 15 --namespace kperf --svc-prefix ktest --wait --timeout 30s --max-scale 3 --min-scale 0 || fail_test "kperf service generate failed"
+
+# wait for scale to zero
+counter=100
+until counter=0
+do
+ sleep 1
+ counter="kubectl get pods -n kperf | awk '{print $1}' | grep domain | wc -l"
+done
+
+#scale and measure
+run_kperf service scale --namespace kperf --svc-prefix ktest --range 0,99 --verbose --output "${ARTIFACTS}/kperf" || fail_test "kperf service scale failed"
+
+run_kperf service clean --namespace kperf --svc-prefix ktest || fail_test "kperf service clean failed"
+
+# Remove the kail log file if the test flow passes.
+# This is for preventing too many large log files to be uploaded to GCS in CI.
+rm "${ARTIFACTS}/k8s.log-$(basename "${E2E_SCRIPT}").txt"
+success
From d454d6710a2f3533afc2218e819674f47da6204f Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 3 Feb 2022 15:21:27 -0800
Subject: [PATCH 137/733] Update net-contour nightly (#12584)
bumping knative.dev/net-contour 3e18bed...2f7655b:
> 2f7655b upgrade to latest dependencies (# 717)
> 34c547d Update actions (# 720)
> a9742b6 Update community files (# 719)
Signed-off-by: Knative Automation
---
third_party/contour-latest/net-contour.yaml | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/third_party/contour-latest/net-contour.yaml b/third_party/contour-latest/net-contour.yaml
index 76e162e0fe41..413bfcb01708 100644
--- a/third_party/contour-latest/net-contour.yaml
+++ b/third_party/contour-latest/net-contour.yaml
@@ -8,7 +8,7 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220131-3e18bed0"
+ app.kubernetes.io/version: "20220203-2f7655b2"
serving.knative.dev/controller: "true"
rules:
- apiGroups: ["projectcontour.io"]
@@ -38,8 +38,8 @@ metadata:
networking.knative.dev/ingress-provider: contour
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220131-3e18bed0"
- serving.knative.dev/release: "v20220131-3e18bed0"
+ app.kubernetes.io/version: "20220203-2f7655b2"
+ serving.knative.dev/release: "v20220203-2f7655b2"
data:
_example: |
################################
@@ -105,14 +105,14 @@ spec:
app: net-contour-controller
app.kubernetes.io/component: net-contour
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220131-3e18bed0"
+ app.kubernetes.io/version: "20220203-2f7655b2"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:e13527176a8c2af2d9d067b557ee86d8f9c4495dd9bfc4e9fece8f267039e8af
+ image: gcr.io/knative-nightly/knative.dev/net-contour/cmd/controller@sha256:2fb707cac80ebdafc6a461bc2b3720025a70627cf2ede5b3de0b62d06cce26be
resources:
requests:
cpu: 40m
From fe023e3ac57de371bb7fdeff2a5d5e77d3e73705 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Thu, 3 Feb 2022 16:26:19 -0800
Subject: [PATCH 138/733] Update net-istio nightly (#12591)
bumping knative.dev/net-istio 7a6405e...5034633:
> 5034633 Update actions (# 859)
> 5284c66 upgrade to latest dependencies (# 860)
> d74c0c9 Update community files (# 855)
> 059bbb5 upgrade to latest dependencies (# 858)
> 78ab380 Update actions (# 856)
Signed-off-by: Knative Automation
---
third_party/istio-latest/net-istio.yaml | 70 ++++++++++++-------------
1 file changed, 35 insertions(+), 35 deletions(-)
diff --git a/third_party/istio-latest/net-istio.yaml b/third_party/istio-latest/net-istio.yaml
index f9408ca38316..97bd13f0c304 100644
--- a/third_party/istio-latest/net-istio.yaml
+++ b/third_party/istio-latest/net-istio.yaml
@@ -1,4 +1,4 @@
-# Generated when HEAD was 7a6405e03cc99b3e82cc56c5fc1e09ba7ddcd837
+# Generated when HEAD was 5034633120f9204624c8fc79e7e80562b34f4f79
#
# Copyright 2019 The Knative Authors
#
@@ -22,8 +22,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
serving.knative.dev/controller: "true"
networking.knative.dev/ingress-provider: istio
rules:
@@ -55,8 +55,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -95,8 +95,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -117,8 +117,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -153,8 +153,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
data:
_example: |
@@ -220,8 +220,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -239,8 +239,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -258,8 +258,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -292,8 +292,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -311,15 +311,15 @@ spec:
app: net-istio-controller
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:1f00ca86138719ad064b76eb80f31e5e0538e62198d5c409f60461703a38083f
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:42078d9c20043b287d3bd2d942500b65eff68a4df8e14c0d20d64e4c6946bee8
resources:
requests:
cpu: 30m
@@ -378,8 +378,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -395,15 +395,15 @@ spec:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:85f8de4c433d1c1e03322cba5e073ca90384ad1e23a0738a7fe724bdde10daf8
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:d6de7dcb77ff26426c26d8afd51dcce56e6369375d92fcff5457c60d120faad2
resources:
requests:
cpu: 20m
@@ -458,8 +458,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
---
@@ -486,8 +486,8 @@ metadata:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
spec:
ports:
@@ -526,8 +526,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -566,8 +566,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220201-7a6405e0"
- serving.knative.dev/release: "v20220201-7a6405e0"
+ app.kubernetes.io/version: "20220203-50346331"
+ serving.knative.dev/release: "v20220203-50346331"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
From 77a0443c52fba683abd88a76e645244cb38e30ac Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Sun, 6 Feb 2022 17:42:53 -0800
Subject: [PATCH 139/733] Update net-istio nightly (#12595)
Signed-off-by: Knative Automation
---
third_party/istio-latest/net-istio.yaml | 75 ++++++++++++-------------
1 file changed, 37 insertions(+), 38 deletions(-)
diff --git a/third_party/istio-latest/net-istio.yaml b/third_party/istio-latest/net-istio.yaml
index 97bd13f0c304..27f800982d02 100644
--- a/third_party/istio-latest/net-istio.yaml
+++ b/third_party/istio-latest/net-istio.yaml
@@ -1,4 +1,4 @@
-# Generated when HEAD was 5034633120f9204624c8fc79e7e80562b34f4f79
+# Generated when HEAD was 34b6c47e6d0bb7a0e5e44772297502b82e52bdc4
#
# Copyright 2019 The Knative Authors
#
@@ -22,8 +22,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
serving.knative.dev/controller: "true"
networking.knative.dev/ingress-provider: istio
rules:
@@ -55,8 +55,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -95,8 +95,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -117,8 +117,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -153,8 +153,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
data:
_example: |
@@ -220,8 +220,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -239,8 +239,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -258,8 +258,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -292,8 +292,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -311,15 +311,15 @@ spec:
app: net-istio-controller
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:42078d9c20043b287d3bd2d942500b65eff68a4df8e14c0d20d64e4c6946bee8
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:0e92ef025934e4a7f9e898c640091f81e6cc635b5cd945c61beb62742a19ea0c
resources:
requests:
cpu: 30m
@@ -378,8 +378,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -395,15 +395,15 @@ spec:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:d6de7dcb77ff26426c26d8afd51dcce56e6369375d92fcff5457c60d120faad2
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:bb2996191b93d97af33c7a4e01a458545bb106240e51fa7035a8873c8dbf4ba3
resources:
requests:
cpu: 20m
@@ -458,8 +458,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
---
@@ -486,8 +486,8 @@ metadata:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
spec:
ports:
@@ -526,8 +526,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -566,8 +566,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220203-50346331"
- serving.knative.dev/release: "v20220203-50346331"
+ app.kubernetes.io/version: "20220204-34b6c47e"
+ serving.knative.dev/release: "v20220204-34b6c47e"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -581,8 +581,7 @@ webhooks:
sideEffects: None
name: config.webhook.istio.networking.internal.knative.dev
namespaceSelector:
- matchExpressions:
- - key: serving.knative.dev/release
- operator: Exists
+ matchLabels:
+ app.kubernetes.io/name: knative-serving
---
From 4262dcbdeb1d54491e1a81582062b57d111c3200 Mon Sep 17 00:00:00 2001
From: Martin Gencur
Date: Mon, 7 Feb 2022 16:12:53 +0100
Subject: [PATCH 140/733] Use default logger configuration (#12597)
This is a follow up on knative/pkg#2293 and uses a default logger which
is defined in the upgrade framework.
---
test/upgrade/upgrade_test.go | 12 +-----------
1 file changed, 1 insertion(+), 11 deletions(-)
diff --git a/test/upgrade/upgrade_test.go b/test/upgrade/upgrade_test.go
index 663e130d16eb..53f24fced475 100644
--- a/test/upgrade/upgrade_test.go
+++ b/test/upgrade/upgrade_test.go
@@ -22,14 +22,12 @@ package upgrade
import (
"testing"
- "go.uber.org/zap"
_ "knative.dev/pkg/system/testing"
pkgupgrade "knative.dev/pkg/test/upgrade"
"knative.dev/serving/test/upgrade/installation"
)
func TestServingUpgrades(t *testing.T) {
- c := newUpgradeConfig(t)
suite := pkgupgrade.Suite{
Tests: pkgupgrade.Tests{
PreUpgrade: ServingPreUpgradeTests(),
@@ -50,13 +48,5 @@ func TestServingUpgrades(t *testing.T) {
},
},
}
- suite.Execute(c)
-}
-
-func newUpgradeConfig(t *testing.T) pkgupgrade.Configuration {
- log, err := zap.NewDevelopment()
- if err != nil {
- t.Fatal(err)
- }
- return pkgupgrade.Configuration{T: t, Log: log}
+ suite.Execute(pkgupgrade.Configuration{T: t})
}
From b3b8882f20f55f6d003f8e64cfce3b07feee5f99 Mon Sep 17 00:00:00 2001
From: Kenjiro Nakayama
Date: Tue, 8 Feb 2022 03:41:53 +0900
Subject: [PATCH 141/733] Bump Istio version for gateway-api to 1.12.2 (#12596)
* Update net-gateway-api nightly
bumping knative.dev/net-gateway-api 1a7d3eb...285bccc:
> 285bccc upgrade to latest dependencies (# 242)
> 4fa1fb2 Update actions (# 241)
> 9d93e55 Update community files (# 240)
> c2ccaec Bump Gateway API v0.3.0 to v0.4.0 (# 239)
Signed-off-by: Knative Automation
* Do not run beta for gateway-api
* Bump istio version for gateway-api
Co-authored-by: Knative Automation
---
.github/workflows/kind-e2e.yaml | 6 +-
test/e2e-networking-library.sh | 2 +-
.../gateway-api-latest/istio-gateway.yaml | 49 +-
.../gateway-api-latest/net-gateway-api.yaml | 2123 +++++++++--------
4 files changed, 1152 insertions(+), 1028 deletions(-)
diff --git a/.github/workflows/kind-e2e.yaml b/.github/workflows/kind-e2e.yaml
index f536e6afc9e1..cea09899856b 100644
--- a/.github/workflows/kind-e2e.yaml
+++ b/.github/workflows/kind-e2e.yaml
@@ -37,24 +37,28 @@ jobs:
kind-version: v0.11.1
kind-image-sha: sha256:69860bda5563ac81e3c0057d654b5253219618a22ec3a346306239bba8cfa1a6
kingress: kourier
+ test-flags: "--enable-alpha --enable-beta"
cluster-suffix: c${{ github.run_id }}.local
- cluster: v1.22.2/istio
k8s-version: v1.22.2
kind-version: v0.11.1
kind-image-sha: sha256:f638a08c1f68fe2a99e724ace6df233a546eaf6713019a0b310130a4f91ebe7f
kingress: istio
+ test-flags: "--enable-alpha --enable-beta"
cluster-suffix: c${{ github.run_id }}.local
- cluster: v1.23.0/contour
k8s-version: v1.23.0
kind-version: v0.11.1
kind-image-sha: sha256:49824ab1727c04e56a21a5d8372a402fcd32ea51ac96a2706a12af38934f81ac
kingress: contour
+ test-flags: "--enable-alpha --enable-beta"
cluster-suffix: c${{ github.run_id }}.local
- cluster: v1.23.0/gateway-api
k8s-version: v1.23.0
kind-version: v0.11.1
kind-image-sha: sha256:49824ab1727c04e56a21a5d8372a402fcd32ea51ac96a2706a12af38934f81ac
kingress: gateway-api
+ test-flags: "--enable-alpha"
cluster-suffix: c${{ github.run_id }}.local
env:
@@ -215,5 +219,5 @@ jobs:
toggle_feature kubernetes.podspec-volumes-emptydir Enabled
go test -race -count=1 -parallel=1 -timeout=30m -tags=e2e ${{ matrix.test-suite }} \
--ingressendpoint="${IPS[0]}" \
- --enable-alpha --enable-beta
+ ${{ matrix.test-flags }}
toggle_feature kubernetes.podspec-volumes-emptydir Disabled
diff --git a/test/e2e-networking-library.sh b/test/e2e-networking-library.sh
index f2b83c646d88..b849dbcd2a3e 100644
--- a/test/e2e-networking-library.sh
+++ b/test/e2e-networking-library.sh
@@ -26,7 +26,7 @@ function stage_gateway_api_resources() {
mkdir -p "${gateway_dir}"
# TODO: if we switch to istio 1.12 we can reuse stage_istio_head
- curl -sL https://istio.io/downloadIstioctl | ISTIO_VERSION=1.11.4 sh -
+ curl -sL https://istio.io/downloadIstioctl | ISTIO_VERSION=1.12.2 sh -
local params="--set values.global.proxy.clusterDomain=${CLUSTER_DOMAIN}"
if (( KIND )); then
diff --git a/third_party/gateway-api-latest/istio-gateway.yaml b/third_party/gateway-api-latest/istio-gateway.yaml
index 969ad07a760b..750a6e2695a9 100644
--- a/third_party/gateway-api-latest/istio-gateway.yaml
+++ b/third_party/gateway-api-latest/istio-gateway.yaml
@@ -20,7 +20,7 @@ metadata:
name: knative-local-gateway
namespace: istio-system
labels:
- serving.knative.dev/release: "v20220125-1a7d3eb6"
+ serving.knative.dev/release: "v20220204-285bccce"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -48,25 +48,22 @@ spec:
# limitations under the License.
kind: Gateway
-apiVersion: networking.x-k8s.io/v1alpha1
+apiVersion: gateway.networking.k8s.io/v1alpha2
metadata:
name: knative-local-gateway
namespace: istio-system
spec:
gatewayClassName: istio
addresses:
- - type: NamedAddress
+ - type: Hostname
value: knative-local-gateway
listeners:
- - protocol: HTTP
+ - name: default
port: 80
- routes:
- kind: HTTPRoute
- selector:
- matchLabels:
- networking.knative.dev/visibility: "cluster-local"
+ protocol: HTTP
+ allowedRoutes:
namespaces:
- from: "All"
+ from: All
---
# Copyright 2021 The Knative Authors
@@ -84,38 +81,22 @@ spec:
# limitations under the License.
kind: Gateway
-apiVersion: networking.x-k8s.io/v1alpha1
+apiVersion: gateway.networking.k8s.io/v1alpha2
metadata:
name: knative-gateway
namespace: istio-system
spec:
gatewayClassName: istio
addresses:
- - type: NamedAddress
+ - type: Hostname
value: istio-ingressgateway
listeners:
- - protocol: HTTP
+ - name: default
port: 80
- routes:
- kind: HTTPRoute
- selector:
- matchLabels:
- networking.knative.dev/visibility: ""
+ protocol: HTTP
+ allowedRoutes:
namespaces:
- from: "All"
- - protocol: HTTPS
- port: 443
- tls:
- mode: Terminate
- routeOverride:
- certificate: Allow
- routes:
- kind: HTTPRoute
- selector:
- matchLabels:
- networking.knative.dev/visibility: ""
- namespaces:
- from: "All"
+ from: All
---
# Copyright 2021 The Knative Authors
@@ -132,11 +113,11 @@ spec:
# See the License for the specific language governing permissions and
# limitations under the License.
-apiVersion: networking.x-k8s.io/v1alpha1
+apiVersion: gateway.networking.k8s.io/v1alpha2
kind: GatewayClass
metadata:
name: istio
spec:
- controller: istio.io/gateway-controller
+ controllerName: istio.io/gateway-controller
---
diff --git a/third_party/gateway-api-latest/net-gateway-api.yaml b/third_party/gateway-api-latest/net-gateway-api.yaml
index 31195b1d9109..2d0074cd891f 100644
--- a/third_party/gateway-api-latest/net-gateway-api.yaml
+++ b/third_party/gateway-api-latest/net-gateway-api.yaml
@@ -1,182 +1,13 @@
-# Generated with "kubectl kustomize https://github.com/kubernetes-sigs/gateway-api/config/crd?ref=v0.3.0"
+# Generated with "kubectl kustomize https://github.com/kubernetes-sigs/gateway-api/config/crd?ref=v0.4.0"
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ api-approved.kubernetes.io: https://github.com/kubernetes-sigs/gateway-api/pull/891
creationTimestamp: null
- name: backendpolicies.networking.x-k8s.io
+ name: gatewayclasses.gateway.networking.k8s.io
spec:
- group: networking.x-k8s.io
- names:
- categories:
- - gateway-api
- kind: BackendPolicy
- listKind: BackendPolicyList
- plural: backendpolicies
- shortNames:
- - bp
- singular: backendpolicy
- scope: Namespaced
- versions:
- - additionalPrinterColumns:
- - jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1alpha1
- schema:
- openAPIV3Schema:
- description: BackendPolicy defines policies associated with backends. For the purpose of this API, a backend is defined as any resource that a route can forward traffic to. A common example of a backend is a Service. Configuration that is implementation specific may be represented with similar implementation specific custom resources.
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Spec defines the desired state of BackendPolicy.
- properties:
- backendRefs:
- description: "BackendRefs define which backends this policy should be applied to. This policy can only apply to backends within the same namespace. If more than one BackendPolicy targets the same backend, precedence must be given to the oldest BackendPolicy. \n Support: Core"
- items:
- description: BackendRef identifies an API object within the same namespace as the BackendPolicy.
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- type: string
- kind:
- description: Kind is the kind of the referent.
- maxLength: 253
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- type: string
- port:
- description: Port is the port of the referent. If unspecified, this policy applies to all ports on the backend.
- format: int32
- maximum: 65535
- minimum: 1
- type: integer
- required:
- - group
- - kind
- - name
- type: object
- maxItems: 16
- type: array
- tls:
- description: "TLS is the TLS configuration for these backends. \n Support: Extended"
- properties:
- certificateAuthorityRef:
- description: "CertificateAuthorityRef is a reference to a Kubernetes object that contains one or more trusted CA certificates. The CA certificates are used to establish a TLS handshake to backends listed in BackendRefs. The referenced object MUST reside in the same namespace as BackendPolicy. \n CertificateAuthorityRef can reference a standard Kubernetes resource, i.e. ConfigMap, or an implementation-specific custom resource. \n When stored in a Secret, certificates must be PEM encoded and specified within the \"ca.crt\" data field of the Secret. When multiple certificates are specified, the certificates MUST be concatenated by new lines. \n CertificateAuthorityRef can also reference a standard Kubernetes resource, i.e. ConfigMap, or an implementation-specific custom resource. \n Support: Extended"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
- options:
- additionalProperties:
- type: string
- description: "Options are a list of key/value pairs to give extended options to the provider. \n Support: Implementation-specific"
- type: object
- type: object
- required:
- - backendRefs
- type: object
- status:
- description: Status defines the current state of BackendPolicy.
- properties:
- conditions:
- description: Conditions describe the current conditions of the BackendPolicy.
- items:
- description: "Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example, type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }"
- properties:
- lastTransitionTime:
- description: lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
- format: date-time
- type: string
- message:
- description: message is a human readable message indicating details about the transition. This may be an empty string.
- maxLength: 32768
- type: string
- observedGeneration:
- description: observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.
- format: int64
- minimum: 0
- type: integer
- reason:
- description: reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.
- maxLength: 1024
- minLength: 1
- pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
- type: string
- status:
- description: status of the condition, one of True, False, Unknown.
- enum:
- - "True"
- - "False"
- - Unknown
- type: string
- type:
- description: type of condition in CamelCase or in foo.example.com/CamelCase. --- Many .condition.type values are consistent across resources like Available, but because arbitrary conditions can be useful (see .node.status.conditions), the ability to deconflict is important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)
- maxLength: 316
- pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
- type: string
- required:
- - lastTransitionTime
- - message
- - reason
- - status
- - type
- type: object
- maxItems: 8
- type: array
- x-kubernetes-list-map-keys:
- - type
- x-kubernetes-list-type: map
- type: object
- type: object
- served: true
- storage: true
- subresources:
- status: {}
-status:
- acceptedNames:
- kind: ""
- plural: ""
- conditions: []
- storedVersions: []
----
-apiVersion: apiextensions.k8s.io/v1
-kind: CustomResourceDefinition
-metadata:
- annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
- creationTimestamp: null
- name: gatewayclasses.networking.x-k8s.io
-spec:
- group: networking.x-k8s.io
+ group: gateway.networking.k8s.io
names:
categories:
- gateway-api
@@ -195,10 +26,14 @@ spec:
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
- name: v1alpha1
+ - jsonPath: .spec.description
+ name: Description
+ priority: 1
+ type: string
+ name: v1alpha2
schema:
openAPIV3Schema:
- description: "GatewayClass describes a class of Gateways available to the user for creating Gateway resources. \n GatewayClass is a Cluster level resource."
+ description: "GatewayClass describes a class of Gateways available to the user for creating Gateway resources. \n It is recommended that this resource be used as a template for Gateways. This means that a Gateway is based on the state of the GatewayClass at the time it was created and changes to the GatewayClass or associated parameters are not propagated down to existing Gateways. This recommendation is intended to limit the blast radius of changes to GatewayClass or associated parameters. If implementations choose to propagate GatewayClass changes to existing Gateways, that MUST be clearly documented by the implementation. \n Whenever one or more Gateways are using a GatewayClass, implementations MUST add the `gateway-exists-finalizer.gateway.networking.k8s.io` finalizer on the associated GatewayClass. This ensures that a GatewayClass associated with a Gateway is not deleted while in use. \n GatewayClass is a Cluster level resource."
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
@@ -211,9 +46,15 @@ spec:
spec:
description: Spec defines the desired state of GatewayClass.
properties:
- controller:
- description: "Controller is a domain/path string that indicates the controller that is managing Gateways of this class. \n Example: \"acme.io/gateway-controller\". \n This field is not mutable and cannot be empty. \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names). \n Support: Core"
+ controllerName:
+ description: "ControllerName is the name of the controller that is managing Gateways of this class. The value of this field MUST be a domain prefixed path. \n Example: \"example.net/gateway-controller\". \n This field is not mutable and cannot be empty. \n Support: Core"
maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*\/[A-Za-z0-9\/\-._~%!$&'()*+,;=:]+$
+ type: string
+ description:
+ description: Description helps describe a GatewayClass with more details.
+ maxLength: 64
type: string
parametersRef:
description: "ParametersRef is a reference to a resource that contains the configuration parameters corresponding to the GatewayClass. This is optional if the controller does not require any additional configuration. \n ParametersRef can reference a standard Kubernetes resource, i.e. ConfigMap, or an implementation-specific custom resource. The resource can be cluster-scoped or namespace-scoped. \n If the referent cannot be found, the GatewayClass's \"InvalidParameters\" status condition will be true. \n Support: Custom"
@@ -221,12 +62,13 @@ spec:
group:
description: Group is the group of the referent.
maxLength: 253
- minLength: 1
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
description: Kind is kind of the referent.
- maxLength: 253
+ maxLength: 63
minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
@@ -234,16 +76,10 @@ spec:
minLength: 1
type: string
namespace:
- description: Namespace is the namespace of the referent. This field is required when scope is set to "Namespace" and ignored when scope is set to "Cluster".
- maxLength: 253
+ description: Namespace is the namespace of the referent. This field is required when referring to a Namespace-scoped resource and MUST be unset when referring to a Cluster-scoped resource.
+ maxLength: 63
minLength: 1
- type: string
- scope:
- default: Cluster
- description: Scope represents if the referent is a Cluster or Namespace scoped resource. This may be set to "Cluster" or "Namespace".
- enum:
- - Cluster
- - Namespace
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
type: string
required:
- group
@@ -251,7 +87,7 @@ spec:
- name
type: object
required:
- - controller
+ - controllerName
type: object
status:
default:
@@ -259,8 +95,8 @@ spec:
- lastTransitionTime: "1970-01-01T00:00:00Z"
message: Waiting for controller
reason: Waiting
- status: "False"
- type: Admitted
+ status: Unknown
+ type: Accepted
description: Status defines the current state of GatewayClass.
properties:
conditions:
@@ -268,8 +104,8 @@ spec:
- lastTransitionTime: "1970-01-01T00:00:00Z"
message: Waiting for controller
reason: Waiting
- status: "False"
- type: Admitted
+ status: Unknown
+ type: Accepted
description: "Conditions is the current status from the controller for this GatewayClass. \n Controllers should prefer to publish conditions using values of GatewayClassConditionType for the type of each Condition."
items:
description: "Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example, type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }"
@@ -318,6 +154,8 @@ spec:
- type
x-kubernetes-list-type: map
type: object
+ required:
+ - spec
type: object
served: true
storage: true
@@ -334,11 +172,11 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ api-approved.kubernetes.io: https://github.com/kubernetes-sigs/gateway-api/pull/891
creationTimestamp: null
- name: gateways.networking.x-k8s.io
+ name: gateways.gateway.networking.k8s.io
spec:
- group: networking.x-k8s.io
+ group: gateway.networking.k8s.io
names:
categories:
- gateway-api
@@ -354,13 +192,19 @@ spec:
- jsonPath: .spec.gatewayClassName
name: Class
type: string
+ - jsonPath: .status.addresses[*].value
+ name: Address
+ type: string
+ - jsonPath: .status.conditions[?(@.type=="Ready")].status
+ name: Ready
+ type: string
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
- name: v1alpha1
+ name: v1alpha2
schema:
openAPIV3Schema:
- description: "Gateway represents an instantiation of a service-traffic handling infrastructure by binding Listeners to a set of IP addresses. \n Implementations should add the `gateway-exists-finalizer.networking.x-k8s.io` finalizer on the associated GatewayClass whenever Gateway(s) is running. This ensures that a GatewayClass associated with a Gateway(s) is not deleted while in use."
+ description: Gateway represents an instance of a service-traffic handling infrastructure by binding Listeners to a set of IP addresses.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
@@ -374,15 +218,16 @@ spec:
description: Spec defines the desired state of Gateway.
properties:
addresses:
- description: "Addresses requested for this gateway. This is optional and behavior can depend on the GatewayClass. If a value is set in the spec and the requested address is invalid, the GatewayClass MUST indicate this in the associated entry in GatewayStatus.Addresses. \n If no Addresses are specified, the GatewayClass may schedule the Gateway in an implementation-defined manner, assigning an appropriate set of Addresses. \n The GatewayClass MUST bind all Listeners to every GatewayAddress that it assigns to the Gateway. \n Support: Core"
+ description: "Addresses requested for this Gateway. This is optional and behavior can depend on the implementation. If a value is set in the spec and the requested address is invalid or unavailable, the implementation MUST indicate this in the associated entry in GatewayStatus.Addresses. \n The Addresses field represents a request for the address(es) on the \"outside of the Gateway\", that traffic bound for this Gateway will use. This could be the IP address or hostname of an external load balancer or other networking infrastructure, or some other address that traffic will be sent to. \n The .listener.hostname field is used to route traffic that has already arrived at the Gateway to the correct in-cluster destination. \n If no Addresses are specified, the implementation MAY schedule the Gateway in an implementation-specific manner, assigning an appropriate set of Addresses. \n The implementation MUST bind all Listeners to every GatewayAddress that it assigns to the Gateway and add a corresponding entry in GatewayStatus.Addresses. \n Support: Core"
items:
description: GatewayAddress describes an address that can be bound to a Gateway.
properties:
type:
default: IPAddress
- description: "Type of the address. \n Support: Extended"
+ description: Type of the address.
enum:
- IPAddress
+ - Hostname
- NamedAddress
type: string
value:
@@ -401,40 +246,42 @@ spec:
minLength: 1
type: string
listeners:
- description: "Listeners associated with this Gateway. Listeners define logical endpoints that are bound on this Gateway's addresses. At least one Listener MUST be specified. \n An implementation MAY group Listeners by Port and then collapse each group of Listeners into a single Listener if the implementation determines that the Listeners in the group are \"compatible\". An implementation MAY also group together and collapse compatible Listeners belonging to different Gateways. \n For example, an implementation might consider Listeners to be compatible with each other if all of the following conditions are met: \n 1. Either each Listener within the group specifies the \"HTTP\" Protocol or each Listener within the group specifies either the \"HTTPS\" or \"TLS\" Protocol. \n 2. Each Listener within the group specifies a Hostname that is unique within the group. \n 3. As a special case, one Listener within a group may omit Hostname, in which case this Listener matches when no other Listener matches. \n If the implementation does collapse compatible Listeners, the hostname provided in the incoming client request MUST be matched to a Listener to find the correct set of Routes. The incoming hostname MUST be matched using the Hostname field for each Listener in order of most to least specific. That is, exact matches must be processed before wildcard matches. \n If this field specifies multiple Listeners that have the same Port value but are not compatible, the implementation must raise a \"Conflicted\" condition in the Listener status. \n Support: Core"
+ description: "Listeners associated with this Gateway. Listeners define logical endpoints that are bound on this Gateway's addresses. At least one Listener MUST be specified. \n Each listener in a Gateway must have a unique combination of Hostname, Port, and Protocol. \n An implementation MAY group Listeners by Port and then collapse each group of Listeners into a single Listener if the implementation determines that the Listeners in the group are \"compatible\". An implementation MAY also group together and collapse compatible Listeners belonging to different Gateways. \n For example, an implementation might consider Listeners to be compatible with each other if all of the following conditions are met: \n 1. Either each Listener within the group specifies the \"HTTP\" Protocol or each Listener within the group specifies either the \"HTTPS\" or \"TLS\" Protocol. \n 2. Each Listener within the group specifies a Hostname that is unique within the group. \n 3. As a special case, one Listener within a group may omit Hostname, in which case this Listener matches when no other Listener matches. \n If the implementation does collapse compatible Listeners, the hostname provided in the incoming client request MUST be matched to a Listener to find the correct set of Routes. The incoming hostname MUST be matched using the Hostname field for each Listener in order of most to least specific. That is, exact matches must be processed before wildcard matches. \n If this field specifies multiple Listeners that have the same Port value but are not compatible, the implementation must raise a \"Conflicted\" condition in the Listener status. \n Support: Core"
items:
- description: Listener embodies the concept of a logical endpoint where a Gateway can accept network connections. Each listener in a Gateway must have a unique combination of Hostname, Port, and Protocol. This will be enforced by a validating webhook.
+ description: Listener embodies the concept of a logical endpoint where a Gateway accepts network connections.
properties:
- hostname:
- description: "Hostname specifies the virtual hostname to match for protocol types that define this concept. When unspecified, \"\", or `*`, all hostnames are matched. This field can be omitted for protocols that don't require hostname based matching. \n Hostname is the fully qualified domain name of a network host, as defined by RFC 3986. Note the following deviations from the \"host\" part of the URI as defined in the RFC: \n 1. IP literals are not allowed. 2. The `:` delimiter is not respected because ports are not allowed. \n Hostname can be \"precise\" which is a domain name without the terminating dot of a network host (e.g. \"foo.example.com\") or \"wildcard\", which is a domain name prefixed with a single wildcard label (e.g. `*.example.com`). The wildcard character `*` must appear by itself as the first DNS label and matches only a single label. \n Support: Core"
- maxLength: 253
- minLength: 1
- type: string
- port:
- description: "Port is the network port. Multiple listeners may use the same port, subject to the Listener compatibility rules. \n Support: Core"
- format: int32
- maximum: 65535
- minimum: 1
- type: integer
- protocol:
- description: "Protocol specifies the network protocol this listener expects to receive. The GatewayClass MUST apply the Hostname match appropriately for each protocol: \n * For the \"TLS\" protocol, the Hostname match MUST be applied to the [SNI](https://tools.ietf.org/html/rfc6066#section-3) server name offered by the client. * For the \"HTTP\" protocol, the Hostname match MUST be applied to the host portion of the [effective request URI](https://tools.ietf.org/html/rfc7230#section-5.5) or the [:authority pseudo-header](https://tools.ietf.org/html/rfc7540#section-8.1.2.3) * For the \"HTTPS\" protocol, the Hostname match MUST be applied at both the TLS and HTTP protocol layers. \n Support: Core"
- type: string
- routes:
- description: "Routes specifies a schema for associating routes with the Listener using selectors. A Route is a resource capable of servicing a request and allows a cluster operator to expose a cluster resource (i.e. Service) by externally-reachable URL, load-balance traffic and terminate SSL/TLS. Typically, a route is a \"HTTPRoute\" or \"TCPRoute\" in group \"networking.x-k8s.io\", however, an implementation may support other types of resources. \n The Routes selector MUST select a set of objects that are compatible with the application protocol specified in the Protocol field. \n Although a client request may technically match multiple route rules, only one rule may ultimately receive the request. Matching precedence MUST be determined in order of the following criteria: \n * The most specific match. For example, the most specific HTTPRoute match is determined by the longest matching combination of hostname and path. * The oldest Route based on creation timestamp. For example, a Route with a creation timestamp of \"2020-09-08 01:02:03\" is given precedence over a Route with a creation timestamp of \"2020-09-08 01:02:04\". * If everything else is equivalent, the Route appearing first in alphabetical order (namespace/name) should be given precedence. For example, foo/bar is given precedence over foo/baz. \n All valid portions of a Route selected by this field should be supported. Invalid portions of a Route can be ignored (sometimes that will mean the full Route). If a portion of a Route transitions from valid to invalid, support for that portion of the Route should be dropped to ensure consistency. For example, even if a filter specified by a Route is invalid, the rest of the Route should still be supported. \n Support: Core"
+ allowedRoutes:
+ default:
+ namespaces:
+ from: Same
+ description: "AllowedRoutes defines the types of routes that MAY be attached to a Listener and the trusted namespaces where those Route resources MAY be present. \n Although a client request may match multiple route rules, only one rule may ultimately receive the request. Matching precedence MUST be determined in order of the following criteria: \n * The most specific match as defined by the Route type. * The oldest Route based on creation timestamp. For example, a Route with a creation timestamp of \"2020-09-08 01:02:03\" is given precedence over a Route with a creation timestamp of \"2020-09-08 01:02:04\". * If everything else is equivalent, the Route appearing first in alphabetical order (namespace/name) should be given precedence. For example, foo/bar is given precedence over foo/baz. \n All valid rules within a Route attached to this Listener should be implemented. Invalid Route rules can be ignored (sometimes that will mean the full Route). If a Route rule transitions from valid to invalid, support for that Route rule should be dropped to ensure consistency. For example, even if a filter specified by a Route rule is invalid, the rest of the rules within that Route should still be supported. \n Support: Core"
properties:
- group:
- default: networking.x-k8s.io
- description: "Group is the group of the route resource to select. Omitting the value or specifying the empty string indicates the networking.x-k8s.io API group. For example, use the following to select an HTTPRoute: \n routes: kind: HTTPRoute \n Otherwise, if an alternative API group is desired, specify the desired group: \n routes: group: acme.io kind: FooRoute \n Support: Core"
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: "Kind is the kind of the route resource to select. \n Kind MUST correspond to kinds of routes that are compatible with the application protocol specified in the Listener's Protocol field. \n If an implementation does not support or recognize this resource type, it SHOULD set the \"ResolvedRefs\" condition to false for this listener with the \"InvalidRoutesRef\" reason. \n Support: Core"
- type: string
+ kinds:
+ description: "Kinds specifies the groups and kinds of Routes that are allowed to bind to this Gateway Listener. When unspecified or empty, the kinds of Routes selected are determined using the Listener protocol. \n A RouteGroupKind MUST correspond to kinds of Routes that are compatible with the application protocol specified in the Listener's Protocol field. If an implementation does not support or recognize this resource type, it MUST set the \"ResolvedRefs\" condition to False for this Listener with the \"InvalidRoutesRef\" reason. \n Support: Core"
+ items:
+ description: RouteGroupKind indicates the group and kind of a Route resource.
+ properties:
+ group:
+ default: gateway.networking.k8s.io
+ description: Group is the group of the Route.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ description: Kind is the kind of the Route.
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ required:
+ - kind
+ type: object
+ maxItems: 8
+ type: array
namespaces:
default:
from: Same
- description: "Namespaces indicates in which namespaces Routes should be selected for this Gateway. This is restricted to the namespace of this Gateway by default. \n Support: Core"
+ description: "Namespaces indicates namespaces from which Routes may be attached to this Listener. This is restricted to the namespace of this Gateway by default. \n Support: Core"
properties:
from:
default: Same
@@ -475,99 +322,96 @@ spec:
type: object
type: object
type: object
- selector:
- description: "Selector specifies a set of route labels used for selecting routes to associate with the Gateway. If this Selector is defined, only routes matching the Selector are associated with the Gateway. An empty Selector matches all routes. \n Support: Core"
- properties:
- matchExpressions:
- description: matchExpressions is a list of label selector requirements. The requirements are ANDed.
- items:
- description: A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.
- properties:
- key:
- description: key is the label key that the selector applies to.
- type: string
- operator:
- description: operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
- type: string
- values:
- description: values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.
- items:
- type: string
- type: array
- required:
- - key
- - operator
- type: object
- type: array
- matchLabels:
- additionalProperties:
- type: string
- description: matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed.
- type: object
- type: object
- required:
- - kind
type: object
+ hostname:
+ description: "Hostname specifies the virtual hostname to match for protocol types that define this concept. When unspecified, all hostnames are matched. This field is ignored for protocols that don't require hostname based matching. \n Implementations MUST apply Hostname matching appropriately for each of the following protocols: \n * TLS: The Listener Hostname MUST match the SNI. * HTTP: The Listener Hostname MUST match the Host header of the request. * HTTPS: The Listener Hostname SHOULD match at both the TLS and HTTP protocol layers as described above. If an implementation does not ensure that both the SNI and Host header match the Listener hostname, it MUST clearly document that. \n For HTTPRoute and TLSRoute resources, there is an interaction with the `spec.hostnames` array. When both listener and route specify hostnames, there MUST be an intersection between the values for a Route to be accepted. For more information, refer to the Route specific Hostnames documentation. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ pattern: ^(\*\.)?[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ name:
+ description: "Name is the name of the Listener. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ port:
+ description: "Port is the network port. Multiple listeners may use the same port, subject to the Listener compatibility rules. \n Support: Core"
+ format: int32
+ maximum: 65535
+ minimum: 1
+ type: integer
+ protocol:
+ description: "Protocol specifies the network protocol this listener expects to receive. \n Support: Core"
+ maxLength: 255
+ minLength: 1
+ pattern: ^[a-zA-Z0-9]([-a-zSA-Z0-9]*[a-zA-Z0-9])?$|[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*\/[A-Za-z0-9]+$
+ type: string
tls:
- description: "TLS is the TLS configuration for the Listener. This field is required if the Protocol field is \"HTTPS\" or \"TLS\" and ignored otherwise. \n The association of SNIs to Certificate defined in GatewayTLSConfig is defined based on the Hostname field for this listener. \n The GatewayClass MUST use the longest matching SNI out of all available certificates for any TLS handshake. \n Support: Core"
+ description: "TLS is the TLS configuration for the Listener. This field is required if the Protocol field is \"HTTPS\" or \"TLS\". It is invalid to set this field if the Protocol field is \"HTTP\", \"TCP\", or \"UDP\". \n The association of SNIs to Certificate defined in GatewayTLSConfig is defined based on the Hostname field for this listener. \n The GatewayClass MUST use the longest matching SNI out of all available certificates for any TLS handshake. \n Support: Core"
properties:
- certificateRef:
- description: "CertificateRef is a reference to a Kubernetes object that contains a TLS certificate and private key. This certificate is used to establish a TLS handshake for requests that match the hostname of the associated listener. The referenced object MUST reside in the same namespace as Gateway. \n This field is required when mode is set to \"Terminate\" (default) and optional otherwise. \n CertificateRef can reference a standard Kubernetes resource, i.e. Secret, or an implementation-specific custom resource. \n Support: Core (Kubernetes Secrets) \n Support: Implementation-specific (Other resource types)"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
+ certificateRefs:
+ description: "CertificateRefs contains a series of references to Kubernetes objects that contains TLS certificates and private keys. These certificates are used to establish a TLS handshake for requests that match the hostname of the associated listener. \n A single CertificateRef to a Kubernetes Secret has \"Core\" support. Implementations MAY choose to support attaching multiple certificates to a Listener, but this behavior is implementation-specific. \n References to a resource in different namespace are invalid UNLESS there is a ReferencePolicy in the target namespace that allows the certificate to be attached. If a ReferencePolicy does not allow this reference, the \"ResolvedRefs\" condition MUST be set to False for this listener with the \"InvalidCertificateRef\" reason. \n This field is required to have at least one element when the mode is set to \"Terminate\" (default) and is optional otherwise. \n CertificateRefs can reference to standard Kubernetes resources, i.e. Secret, or implementation-specific custom resources. \n Support: Core - A single reference to a Kubernetes Secret \n Support: Implementation-specific (More than one reference or other resource types)"
+ items:
+ description: "SecretObjectReference identifies an API object including its namespace, defaulting to Secret. \n The API object must be valid in the cluster; the Group and Kind must be registered in the cluster for this reference to be valid. \n References to objects with invalid Group and Kind are not valid, and must be rejected by the implementation, with appropriate Conditions set on the containing object."
+ properties:
+ group:
+ default: ""
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Secret
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: Name is the name of the referent.
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the backend. When unspecified, the local namespace is inferred. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ required:
+ - name
+ type: object
+ maxItems: 64
+ type: array
mode:
default: Terminate
- description: "Mode defines the TLS behavior for the TLS session initiated by the client. There are two possible modes: - Terminate: The TLS session between the downstream client and the Gateway is terminated at the Gateway. This mode requires certificateRef to be set. - Passthrough: The TLS session is NOT terminated by the Gateway. This implies that the Gateway can't decipher the TLS stream except for the ClientHello message of the TLS protocol. CertificateRef field is ignored in this mode. \n Support: Core"
+ description: "Mode defines the TLS behavior for the TLS session initiated by the client. There are two possible modes: \n - Terminate: The TLS session between the downstream client and the Gateway is terminated at the Gateway. This mode requires certificateRefs to be set and contain at least one element. - Passthrough: The TLS session is NOT terminated by the Gateway. This implies that the Gateway can't decipher the TLS stream except for the ClientHello message of the TLS protocol. CertificateRefs field is ignored in this mode. \n Support: Core"
enum:
- Terminate
- Passthrough
type: string
options:
additionalProperties:
+ description: AnnotationValue is the value of an annotation in Gateway API. This is used for validation of maps such as TLS options. This roughly matches Kubernetes annotation validation, although the length validation in that case is based on the entire size of the annotations struct.
+ maxLength: 4096
+ minLength: 0
type: string
- description: "Options are a list of key/value pairs to give extended options to the provider. \n There variation among providers as to how ciphersuites are expressed. If there is a common subset for expressing ciphers then it will make sense to loft that as a core API construct. \n Support: Implementation-specific"
- type: object
- routeOverride:
- default:
- certificate: Deny
- description: "RouteOverride dictates if TLS settings can be configured via Routes or not. \n CertificateRef must be defined even if `routeOverride.certificate` is set to 'Allow' as it will be used as the default certificate for the listener. \n Support: Core"
- properties:
- certificate:
- default: Deny
- description: "Certificate dictates if TLS certificates can be configured via Routes. If set to 'Allow', a TLS certificate for a hostname defined in a Route takes precedence over the certificate defined in Gateway. \n Support: Core"
- enum:
- - Allow
- - Deny
- type: string
+ description: "Options are a list of key/value pairs to enable extended TLS configuration for each implementation. For example, configuring the minimum TLS version or supported cipher suites. \n A set of common keys MAY be defined by the API in the future. To avoid any ambiguity, implementation-specific definitions MUST use domain-prefixed names, such as `example.com/my-custom-option`. Un-prefixed names are reserved for key names defined by Gateway API. \n Support: Implementation-specific"
+ maxProperties: 16
type: object
type: object
required:
+ - name
- port
- protocol
- - routes
type: object
maxItems: 64
minItems: 1
type: array
+ x-kubernetes-list-map-keys:
+ - name
+ x-kubernetes-list-type: map
required:
- gatewayClassName
- listeners
@@ -578,20 +422,21 @@ spec:
- lastTransitionTime: "1970-01-01T00:00:00Z"
message: Waiting for controller
reason: NotReconciled
- status: "False"
+ status: Unknown
type: Scheduled
description: Status defines the current state of Gateway.
properties:
addresses:
- description: "Addresses lists the IP addresses that have actually been bound to the Gateway. These addresses may differ from the addresses in the Spec, e.g. if the Gateway automatically assigns an address from a reserved pool. \n These addresses should all be of type \"IPAddress\"."
+ description: Addresses lists the IP addresses that have actually been bound to the Gateway. These addresses may differ from the addresses in the Spec, e.g. if the Gateway automatically assigns an address from a reserved pool.
items:
description: GatewayAddress describes an address that can be bound to a Gateway.
properties:
type:
default: IPAddress
- description: "Type of the address. \n Support: Extended"
+ description: Type of the address.
enum:
- IPAddress
+ - Hostname
- NamedAddress
type: string
value:
@@ -609,7 +454,7 @@ spec:
- lastTransitionTime: "1970-01-01T00:00:00Z"
message: Waiting for controller
reason: NotReconciled
- status: "False"
+ status: Unknown
type: Scheduled
description: "Conditions describe the current conditions of the Gateway. \n Implementations should prefer to express Gateway conditions using the `GatewayConditionType` and `GatewayConditionReason` constants so that operators and tools can converge on a common vocabulary to describe Gateway state. \n Known condition types are: \n * \"Scheduled\" * \"Ready\""
items:
@@ -663,6 +508,10 @@ spec:
items:
description: ListenerStatus is the status associated with a Listener.
properties:
+ attachedRoutes:
+ description: AttachedRoutes represents the total number of Routes that have been successfully attached to this Listener.
+ format: int32
+ type: integer
conditions:
description: Conditions describe the current condition of this listener.
items:
@@ -711,31 +560,48 @@ spec:
x-kubernetes-list-map-keys:
- type
x-kubernetes-list-type: map
- hostname:
- description: Hostname is the Listener hostname value for which this message is reporting the status.
+ name:
+ description: Name is the name of the Listener that this status corresponds to.
maxLength: 253
minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
- port:
- description: Port is the unique Listener port value for which this message is reporting the status.
- format: int32
- maximum: 65535
- minimum: 1
- type: integer
- protocol:
- description: Protocol is the Listener protocol value for which this message is reporting the status.
- type: string
+ supportedKinds:
+ description: "SupportedKinds is the list indicating the Kinds supported by this listener. This MUST represent the kinds an implementation supports for that Listener configuration. \n If kinds are specified in Spec that are not supported, they MUST NOT appear in this list and an implementation MUST set the \"ResolvedRefs\" condition to \"False\" with the \"InvalidRouteKinds\" reason. If both valid and invalid Route kinds are specified, the implementation MUST reference the valid Route kinds that have been specified."
+ items:
+ description: RouteGroupKind indicates the group and kind of a Route resource.
+ properties:
+ group:
+ default: gateway.networking.k8s.io
+ description: Group is the group of the Route.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ description: Kind is the kind of the Route.
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ required:
+ - kind
+ type: object
+ maxItems: 8
+ type: array
required:
+ - attachedRoutes
- conditions
- - port
- - protocol
+ - name
+ - supportedKinds
type: object
maxItems: 64
type: array
x-kubernetes-list-map-keys:
- - port
+ - name
x-kubernetes-list-type: map
type: object
+ required:
+ - spec
type: object
served: true
storage: true
@@ -752,11 +618,11 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ api-approved.kubernetes.io: https://github.com/kubernetes-sigs/gateway-api/pull/891
creationTimestamp: null
- name: httproutes.networking.x-k8s.io
+ name: httproutes.gateway.networking.k8s.io
spec:
- group: networking.x-k8s.io
+ group: gateway.networking.k8s.io
names:
categories:
- gateway-api
@@ -773,10 +639,10 @@ spec:
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
- name: v1alpha1
+ name: v1alpha2
schema:
openAPIV3Schema:
- description: HTTPRoute is the Schema for the HTTPRoute resource.
+ description: HTTPRoute provides a way to route HTTP requests. This includes the capability to match requests by hostname, path, header, or query param. Filters can be used to specify additional processing steps. Backends specify where matching requests should be routed.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
@@ -789,201 +655,89 @@ spec:
spec:
description: Spec defines the desired state of HTTPRoute.
properties:
- gateways:
- default:
- allow: SameNamespace
- description: Gateways defines which Gateways can use this Route.
- properties:
- allow:
- default: SameNamespace
- description: 'Allow indicates which Gateways will be allowed to use this route. Possible values are: * All: Gateways in any namespace can use this route. * FromList: Only Gateways specified in GatewayRefs may use this route. * SameNamespace: Only Gateways in the same namespace may use this route.'
- enum:
- - All
- - FromList
- - SameNamespace
- type: string
- gatewayRefs:
- description: GatewayRefs must be specified when Allow is set to "FromList". In that case, only Gateways referenced in this list will be allowed to use this route. This field is ignored for other values of "Allow".
- items:
- description: GatewayReference identifies a Gateway in a specified namespace.
- properties:
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- namespace:
- description: Namespace is the namespace of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - name
- - namespace
- type: object
- type: array
- type: object
hostnames:
- description: "Hostnames defines a set of hostname that should match against the HTTP Host header to select a HTTPRoute to process the request. Hostname is the fully qualified domain name of a network host, as defined by RFC 3986. Note the following deviations from the \"host\" part of the URI as defined in the RFC: \n 1. IPs are not allowed. 2. The `:` delimiter is not respected because ports are not allowed. \n Incoming requests are matched against the hostnames before the HTTPRoute rules. If no hostname is specified, traffic is routed based on the HTTPRouteRules. \n Hostname can be \"precise\" which is a domain name without the terminating dot of a network host (e.g. \"foo.example.com\") or \"wildcard\", which is a domain name prefixed with a single wildcard label (e.g. `*.example.com`). The wildcard character `*` must appear by itself as the first DNS label and matches only a single label. You cannot have a wildcard label by itself (e.g. Host == `*`). Requests will be matched against the Host field in the following order: \n 1. If Host is precise, the request matches this rule if the HTTP Host header is equal to Host. 2. If Host is a wildcard, then the request matches this rule if the HTTP Host header is to equal to the suffix (removing the first label) of the wildcard rule. \n Support: Core"
+ description: "Hostnames defines a set of hostname that should match against the HTTP Host header to select a HTTPRoute to process the request. This matches the RFC 1123 definition of a hostname with 2 notable exceptions: \n 1. IPs are not allowed. 2. A hostname may be prefixed with a wildcard label (`*.`). The wildcard label must appear by itself as the first label. \n If a hostname is specified by both the Listener and HTTPRoute, there must be at least one intersecting hostname for the HTTPRoute to be attached to the Listener. For example: \n * A Listener with `test.example.com` as the hostname matches HTTPRoutes that have either not specified any hostnames, or have specified at least one of `test.example.com` or `*.example.com`. * A Listener with `*.example.com` as the hostname matches HTTPRoutes that have either not specified any hostnames or have specified at least one hostname that matches the Listener hostname. For example, `test.example.com` and `*.example.com` would both match. On the other hand, `example.com` and `test.example.net` would not match. \n If both the Listener and HTTPRoute have specified hostnames, any HTTPRoute hostnames that do not match the Listener hostname MUST be ignored. For example, if a Listener specified `*.example.com`, and the HTTPRoute specified `test.example.com` and `test.example.net`, `test.example.net` must not be considered for a match. \n If both the Listener and HTTPRoute have specified hostnames, and none match with the criteria above, then the HTTPRoute is not accepted. The implementation must raise an 'Accepted' Condition with a status of `False` in the corresponding RouteParentStatus. \n Support: Core"
items:
- description: Hostname is used to specify a hostname that should be matched.
+ description: "Hostname is the fully qualified domain name of a network host. This matches the RFC 1123 definition of a hostname with 2 notable exceptions: \n 1. IPs are not allowed. 2. A hostname may be prefixed with a wildcard label (`*.`). The wildcard label must appear by itself as the first label. \n Hostname can be \"precise\" which is a domain name without the terminating dot of a network host (e.g. \"foo.example.com\") or \"wildcard\", which is a domain name prefixed with a single wildcard label (e.g. `*.example.com`). \n Note that as per RFC1035 and RFC1123, a *label* must consist of lower case alphanumeric characters or '-', and must start and end with an alphanumeric character. No other punctuation is allowed."
maxLength: 253
minLength: 1
+ pattern: ^(\*\.)?[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
maxItems: 16
type: array
+ parentRefs:
+ description: "ParentRefs references the resources (usually Gateways) that a Route wants to be attached to. Note that the referenced parent resource needs to allow this for the attachment to be complete. For Gateways, that means the Gateway needs to allow attachment from Routes of this kind and namespace. \n The only kind of parent resource with \"Core\" support is Gateway. This API may be extended in the future to support additional kinds of parent resources such as one of the route kinds. \n It is invalid to reference an identical parent more than once. It is valid to reference multiple distinct sections within the same parent resource, such as 2 Listeners within a Gateway. \n It is possible to separately reference multiple distinct objects that may be collapsed by an implementation. For example, some implementations may choose to merge compatible Gateway Listeners together. If that is the case, the list of routes attached to those resources should also be merged."
+ items:
+ description: "ParentRef identifies an API object (usually a Gateway) that can be considered a parent of this resource (usually a route). The only kind of parent resource with \"Core\" support is Gateway. This API may be extended in the future to support additional kinds of parent resources, such as HTTPRoute. \n The API object must be valid in the cluster; the Group and Kind must be registered in the cluster for this reference to be valid. \n References to objects with invalid Group and Kind are not valid, and must be rejected by the implementation, with appropriate Conditions set on the containing object."
+ properties:
+ group:
+ default: gateway.networking.k8s.io
+ description: "Group is the group of the referent. \n Support: Core"
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Gateway
+ description: "Kind is kind of the referent. \n Support: Core (Gateway) Support: Custom (Other Resources)"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: "Name is the name of the referent. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the referent. When unspecified (or empty string), this refers to the local namespace of the Route. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ sectionName:
+ description: "SectionName is the name of a section within the target resource. In the following resources, SectionName is interpreted as the following: \n * Gateway: Listener Name \n Implementations MAY choose to support attaching Routes to other resources. If that is the case, they MUST clearly document how SectionName is interpreted. \n When unspecified (empty string), this will reference the entire resource. For the purpose of status, an attachment is considered successful if at least one section in the parent resource accepts it. For example, Gateway listeners can restrict which Routes can attach to them by Route kind, namespace, or hostname. If 1 of 2 Gateway listeners accept attachment from the referencing Route, the Route MUST be considered successfully attached. If no Gateway listeners accept attachment from this Route, the Route MUST be considered detached from the Gateway. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ required:
+ - name
+ type: object
+ maxItems: 32
+ type: array
rules:
default:
- matches:
- path:
- type: Prefix
+ type: PathPrefix
value: /
description: Rules are a list of HTTP matchers, filters and actions.
items:
- description: HTTPRouteRule defines semantics for matching an HTTP request based on conditions, optionally executing additional processing steps, and forwarding the request to an API object.
+ description: HTTPRouteRule defines semantics for matching an HTTP request based on conditions (matches), processing it (filters), and forwarding the request to an API object (backendRefs).
properties:
- filters:
- description: "Filters define the filters that are applied to requests that match this rule. \n The effects of ordering of multiple behaviors are currently unspecified. This can change in the future based on feedback during the alpha stage. \n Conformance-levels at this level are defined based on the type of filter: \n - ALL core filters MUST be supported by all implementations. - Implementers are encouraged to support extended filters. - Implementation-specific custom filters have no API guarantees across implementations. \n Specifying a core filter multiple times has unspecified or custom conformance. \n Support: Core"
- items:
- description: 'HTTPRouteFilter defines additional processing steps that must be completed during the request or response lifecycle. HTTPRouteFilters are meant as an extension point to express additional processing that may be done in Gateway implementations. Some examples include request or response modification, implementing authentication strategies, rate-limiting, and traffic shaping. API guarantee/conformance is defined based on the type of the filter. TODO(hbagdi): re-render CRDs once controller-tools supports union tags: - https://github.com/kubernetes-sigs/controller-tools/pull/298 - https://github.com/kubernetes-sigs/controller-tools/issues/461'
- properties:
- extensionRef:
- description: "ExtensionRef is an optional, implementation-specific extension to the \"filter\" behavior. For example, resource \"myroutefilter\" in group \"networking.acme.io\"). ExtensionRef MUST NOT be used for core and extended filters. \n Support: Implementation-specific"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
- requestHeaderModifier:
- description: "RequestHeaderModifier defines a schema for a filter that modifies request headers. \n Support: Core"
- properties:
- add:
- additionalProperties:
- type: string
- description: "Add adds the given header (name, value) to the request before the action. It appends to any existing values associated with the header name. \n Input: GET /foo HTTP/1.1 my-header: foo \n Config: add: {\"my-header\": \"bar\"} \n Output: GET /foo HTTP/1.1 my-header: foo my-header: bar \n Support: Extended"
- type: object
- remove:
- description: "Remove the given header(s) from the HTTP request before the action. The value of RemoveHeader is a list of HTTP header names. Note that the header names are case-insensitive [RFC-2616 4.2]. \n Input: GET /foo HTTP/1.1 my-header1: foo my-header2: bar my-header3: baz \n Config: remove: [\"my-header1\", \"my-header3\"] \n Output: GET /foo HTTP/1.1 my-header2: bar \n Support: Extended"
- items:
- type: string
- maxItems: 16
- type: array
- set:
- additionalProperties:
- type: string
- description: "Set overwrites the request with the given header (name, value) before the action. \n Input: GET /foo HTTP/1.1 my-header: foo \n Config: set: {\"my-header\": \"bar\"} \n Output: GET /foo HTTP/1.1 my-header: bar \n Support: Extended"
- type: object
- type: object
- requestMirror:
- description: "RequestMirror defines a schema for a filter that mirrors requests. \n Support: Extended"
- properties:
- backendRef:
- description: "BackendRef is a local object reference to mirror matched requests to. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
- port:
- description: "Port specifies the destination port number to use for the backend referenced by the ServiceName or BackendRef field. \n If unspecified, the destination port in the request is used when forwarding to a backendRef or serviceName."
- format: int32
- maximum: 65535
- minimum: 1
- type: integer
- serviceName:
- description: "ServiceName refers to the name of the Service to mirror matched requests to. When specified, this takes the place of BackendRef. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Core"
- maxLength: 253
- type: string
- type: object
- type:
- description: "Type identifies the type of filter to apply. As with other API fields, types are classified into three conformance levels: \n - Core: Filter types and their corresponding configuration defined by \"Support: Core\" in this package, e.g. \"RequestHeaderModifier\". All implementations must support core filters. \n - Extended: Filter types and their corresponding configuration defined by \"Support: Extended\" in this package, e.g. \"RequestMirror\". Implementers are encouraged to support extended filters. \n - Custom: Filters that are defined and supported by specific vendors. In the future, filters showing convergence in behavior across multiple implementations will be considered for inclusion in extended or core conformance levels. Filter-specific configuration for such filters is specified using the ExtensionRef field. `Type` should be set to \"ExtensionRef\" for custom filters. \n Implementers are encouraged to define custom implementation types to extend the core API with implementation-specific behavior."
- enum:
- - RequestHeaderModifier
- - RequestMirror
- - ExtensionRef
- type: string
- required:
- - type
- type: object
- maxItems: 16
- type: array
- forwardTo:
- description: ForwardTo defines the backend(s) where matching requests should be sent. If unspecified, the rule performs no forwarding. If unspecified and no filters are specified that would result in a response being sent, a 503 error code is returned.
+ backendRefs:
+ description: "If unspecified or invalid (refers to a non-existent resource or a Service with no endpoints), the rule performs no forwarding. If there are also no filters specified that would result in a response being sent, a HTTP 503 status code is returned. 503 responses must be sent so that the overall weight is respected; if an invalid backend is requested to have 80% of requests, then 80% of requests must get a 503 instead. \n Support: Core for Kubernetes Service Support: Custom for any other resource \n Support for weight: Core"
items:
- description: HTTPRouteForwardTo defines how a HTTPRoute should forward a request.
+ description: HTTPBackendRef defines how a HTTPRoute should forward an HTTP request.
properties:
- backendRef:
- description: "BackendRef is a reference to a backend to forward matched requests to. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the route must be dropped from the Gateway. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
filters:
- description: "Filters defined at this-level should be executed if and only if the request is being forwarded to the backend defined here. \n Support: Custom (For broader support of filters, use the Filters field in HTTPRouteRule.)"
+ description: "Filters defined at this level should be executed if and only if the request is being forwarded to the backend defined here. \n Support: Custom (For broader support of filters, use the Filters field in HTTPRouteRule.)"
items:
- description: 'HTTPRouteFilter defines additional processing steps that must be completed during the request or response lifecycle. HTTPRouteFilters are meant as an extension point to express additional processing that may be done in Gateway implementations. Some examples include request or response modification, implementing authentication strategies, rate-limiting, and traffic shaping. API guarantee/conformance is defined based on the type of the filter. TODO(hbagdi): re-render CRDs once controller-tools supports union tags: - https://github.com/kubernetes-sigs/controller-tools/pull/298 - https://github.com/kubernetes-sigs/controller-tools/issues/461'
+ description: HTTPRouteFilter defines processing steps that must be completed during the request or response lifecycle. HTTPRouteFilters are meant as an extension point to express processing that may be done in Gateway implementations. Some examples include request or response modification, implementing authentication strategies, rate-limiting, and traffic shaping. API guarantee/conformance is defined based on the type of the filter.
properties:
extensionRef:
- description: "ExtensionRef is an optional, implementation-specific extension to the \"filter\" behavior. For example, resource \"myroutefilter\" in group \"networking.acme.io\"). ExtensionRef MUST NOT be used for core and extended filters. \n Support: Implementation-specific"
+ description: "ExtensionRef is an optional, implementation-specific extension to the \"filter\" behavior. For example, resource \"myroutefilter\" in group \"networking.example.net\"). ExtensionRef MUST NOT be used for core and extended filters. \n Support: Implementation-specific"
properties:
group:
- description: Group is the group of the referent.
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
maxLength: 253
- minLength: 1
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
- description: Kind is kind of the referent.
- maxLength: 253
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
@@ -999,64 +753,139 @@ spec:
description: "RequestHeaderModifier defines a schema for a filter that modifies request headers. \n Support: Core"
properties:
add:
- additionalProperties:
- type: string
- description: "Add adds the given header (name, value) to the request before the action. It appends to any existing values associated with the header name. \n Input: GET /foo HTTP/1.1 my-header: foo \n Config: add: {\"my-header\": \"bar\"} \n Output: GET /foo HTTP/1.1 my-header: foo my-header: bar \n Support: Extended"
- type: object
+ description: "Add adds the given header(s) (name, value) to the request before the action. It appends to any existing values associated with the header name. \n Input: GET /foo HTTP/1.1 my-header: foo \n Config: add: - name: \"my-header\" value: \"bar\" \n Output: GET /foo HTTP/1.1 my-header: foo my-header: bar"
+ items:
+ description: HTTPHeader represents an HTTP Header name and value as defined by RFC 7230.
+ properties:
+ name:
+ description: "Name is the name of the HTTP Header to be matched. Name matching MUST be case insensitive. (See https://tools.ietf.org/html/rfc7230#section-3.2). \n If multiple entries specify equivalent header names, the first entry with an equivalent name MUST be considered for a match. Subsequent entries with an equivalent header name MUST be ignored. Due to the case-insensitivity of header names, \"foo\" and \"Foo\" are considered equivalent."
+ maxLength: 256
+ minLength: 1
+ pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
+ type: string
+ value:
+ description: Value is the value of HTTP Header to be matched.
+ maxLength: 4096
+ minLength: 1
+ type: string
+ required:
+ - name
+ - value
+ type: object
+ maxItems: 16
+ type: array
+ x-kubernetes-list-map-keys:
+ - name
+ x-kubernetes-list-type: map
remove:
- description: "Remove the given header(s) from the HTTP request before the action. The value of RemoveHeader is a list of HTTP header names. Note that the header names are case-insensitive [RFC-2616 4.2]. \n Input: GET /foo HTTP/1.1 my-header1: foo my-header2: bar my-header3: baz \n Config: remove: [\"my-header1\", \"my-header3\"] \n Output: GET /foo HTTP/1.1 my-header2: bar \n Support: Extended"
+ description: "Remove the given header(s) from the HTTP request before the action. The value of Remove is a list of HTTP header names. Note that the header names are case-insensitive (see https://datatracker.ietf.org/doc/html/rfc2616#section-4.2). \n Input: GET /foo HTTP/1.1 my-header1: foo my-header2: bar my-header3: baz \n Config: remove: [\"my-header1\", \"my-header3\"] \n Output: GET /foo HTTP/1.1 my-header2: bar"
items:
type: string
maxItems: 16
type: array
set:
- additionalProperties:
- type: string
- description: "Set overwrites the request with the given header (name, value) before the action. \n Input: GET /foo HTTP/1.1 my-header: foo \n Config: set: {\"my-header\": \"bar\"} \n Output: GET /foo HTTP/1.1 my-header: bar \n Support: Extended"
- type: object
+ description: "Set overwrites the request with the given header (name, value) before the action. \n Input: GET /foo HTTP/1.1 my-header: foo \n Config: set: - name: \"my-header\" value: \"bar\" \n Output: GET /foo HTTP/1.1 my-header: bar"
+ items:
+ description: HTTPHeader represents an HTTP Header name and value as defined by RFC 7230.
+ properties:
+ name:
+ description: "Name is the name of the HTTP Header to be matched. Name matching MUST be case insensitive. (See https://tools.ietf.org/html/rfc7230#section-3.2). \n If multiple entries specify equivalent header names, the first entry with an equivalent name MUST be considered for a match. Subsequent entries with an equivalent header name MUST be ignored. Due to the case-insensitivity of header names, \"foo\" and \"Foo\" are considered equivalent."
+ maxLength: 256
+ minLength: 1
+ pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
+ type: string
+ value:
+ description: Value is the value of HTTP Header to be matched.
+ maxLength: 4096
+ minLength: 1
+ type: string
+ required:
+ - name
+ - value
+ type: object
+ maxItems: 16
+ type: array
+ x-kubernetes-list-map-keys:
+ - name
+ x-kubernetes-list-type: map
type: object
requestMirror:
- description: "RequestMirror defines a schema for a filter that mirrors requests. \n Support: Extended"
+ description: "RequestMirror defines a schema for a filter that mirrors requests. Requests are sent to the specified destination, but responses from that destination are ignored. \n Support: Extended"
properties:
backendRef:
- description: "BackendRef is a local object reference to mirror matched requests to. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
+ description: "BackendRef references a resource where mirrored requests are sent. \n If the referent cannot be found, this BackendRef is invalid and must be dropped from the Gateway. The controller must ensure the \"ResolvedRefs\" condition on the Route status is set to `status: False` and not configure this backend in the underlying implementation. \n If there is a cross-namespace reference to an *existing* object that is not allowed by a ReferencePolicy, the controller must ensure the \"ResolvedRefs\" condition on the Route is set to `status: False`, with the \"RefNotPermitted\" reason and not configure this backend in the underlying implementation. \n In either error case, the Message of the `ResolvedRefs` Condition should be used to provide more detail about the problem. \n Support: Extended for Kubernetes Service Support: Custom for any other resource"
properties:
group:
- description: Group is the group of the referent.
+ default: ""
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
maxLength: 253
- minLength: 1
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
- description: Kind is kind of the referent.
- maxLength: 253
+ default: Service
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
maxLength: 253
minLength: 1
type: string
+ namespace:
+ description: "Namespace is the namespace of the backend. When unspecified, the local namespace is inferred. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ port:
+ description: Port specifies the destination port number to use for this resource. Port is required when the referent is a Kubernetes Service. For other resources, destination port might be derived from the referent resource or this field.
+ format: int32
+ maximum: 65535
+ minimum: 1
+ type: integer
required:
- - group
- - kind
- name
type: object
+ required:
+ - backendRef
+ type: object
+ requestRedirect:
+ description: "RequestRedirect defines a schema for a filter that responds to the request with an HTTP redirection. \n Support: Core"
+ properties:
+ hostname:
+ description: "Hostname is the hostname to be used in the value of the `Location` header in the response. When empty, the hostname of the request is used. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ pattern: ^(\*\.)?[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
port:
- description: "Port specifies the destination port number to use for the backend referenced by the ServiceName or BackendRef field. \n If unspecified, the destination port in the request is used when forwarding to a backendRef or serviceName."
+ description: "Port is the port to be used in the value of the `Location` header in the response. When empty, port (if specified) of the request is used. \n Support: Extended"
format: int32
maximum: 65535
minimum: 1
type: integer
- serviceName:
- description: "ServiceName refers to the name of the Service to mirror matched requests to. When specified, this takes the place of BackendRef. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Core"
- maxLength: 253
+ scheme:
+ description: "Scheme is the scheme to be used in the value of the `Location` header in the response. When empty, the scheme of the request is used. \n Support: Extended"
+ enum:
+ - http
+ - https
type: string
+ statusCode:
+ default: 302
+ description: "StatusCode is the HTTP status code to be used in response. \n Support: Core"
+ enum:
+ - 301
+ - 302
+ type: integer
type: object
type:
- description: "Type identifies the type of filter to apply. As with other API fields, types are classified into three conformance levels: \n - Core: Filter types and their corresponding configuration defined by \"Support: Core\" in this package, e.g. \"RequestHeaderModifier\". All implementations must support core filters. \n - Extended: Filter types and their corresponding configuration defined by \"Support: Extended\" in this package, e.g. \"RequestMirror\". Implementers are encouraged to support extended filters. \n - Custom: Filters that are defined and supported by specific vendors. In the future, filters showing convergence in behavior across multiple implementations will be considered for inclusion in extended or core conformance levels. Filter-specific configuration for such filters is specified using the ExtensionRef field. `Type` should be set to \"ExtensionRef\" for custom filters. \n Implementers are encouraged to define custom implementation types to extend the core API with implementation-specific behavior."
+ description: "Type identifies the type of filter to apply. As with other API fields, types are classified into three conformance levels: \n - Core: Filter types and their corresponding configuration defined by \"Support: Core\" in this package, e.g. \"RequestHeaderModifier\". All implementations must support core filters. \n - Extended: Filter types and their corresponding configuration defined by \"Support: Extended\" in this package, e.g. \"RequestMirror\". Implementers are encouraged to support extended filters. \n - Custom: Filters that are defined and supported by specific vendors. In the future, filters showing convergence in behavior across multiple implementations will be considered for inclusion in extended or core conformance levels. Filter-specific configuration for such filters is specified using the ExtensionRef field. `Type` should be set to \"ExtensionRef\" for custom filters. \n Implementers are encouraged to define custom implementation types to extend the core API with implementation-specific behavior. \n If a reference to a custom filter type cannot be resolved, the filter MUST NOT be skipped. Instead, requests that would have been processed by that filter MUST receive a HTTP error response."
enum:
- RequestHeaderModifier
- RequestMirror
+ - RequestRedirect
- ExtensionRef
type: string
required:
@@ -1064,47 +893,66 @@ spec:
type: object
maxItems: 16
type: array
+ group:
+ default: ""
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Service
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: Name is the name of the referent.
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the backend. When unspecified, the local namespace is inferred. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
port:
- description: "Port specifies the destination port number to use for the backend referenced by the ServiceName or BackendRef field. If unspecified, the destination port in the request is used when forwarding to a backendRef or serviceName. \n Support: Core"
+ description: Port specifies the destination port number to use for this resource. Port is required when the referent is a Kubernetes Service. For other resources, destination port might be derived from the referent resource or this field.
format: int32
maximum: 65535
minimum: 1
type: integer
- serviceName:
- description: "ServiceName refers to the name of the Service to forward matched requests to. When specified, this takes the place of BackendRef. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the route must be dropped from the Gateway. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n The protocol to use should be specified with the AppProtocol field on Service resources. This field was introduced in Kubernetes 1.18. If using an earlier version of Kubernetes, a `networking.x-k8s.io/app-protocol` annotation on the BackendPolicy resource may be used to define the protocol. If the AppProtocol field is available, this annotation should not be used. The AppProtocol field, when populated, takes precedence over the annotation in the BackendPolicy resource. For custom backends, it is encouraged to add a semantically-equivalent field in the Custom Resource Definition. \n Support: Core"
- maxLength: 253
- type: string
weight:
default: 1
- description: "Weight specifies the proportion of HTTP requests forwarded to the backend referenced by the ServiceName or BackendRef field. This is computed as weight/(sum of all weights in this ForwardTo list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. Weight is not a percentage and the sum of weights does not need to equal 100. \n If only one backend is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weight is set to 0, no traffic should be forwarded for this entry. If unspecified, weight defaults to 1. \n Support: Core"
+ description: "Weight specifies the proportion of requests forwarded to the referenced backend. This is computed as weight/(sum of all weights in this BackendRefs list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. Weight is not a percentage and the sum of weights does not need to equal 100. \n If only one backend is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weight is set to 0, no traffic should be forwarded for this entry. If unspecified, weight defaults to 1. \n Support for this field varies based on the context where used."
format: int32
maximum: 1000000
minimum: 0
type: integer
+ required:
+ - name
type: object
maxItems: 16
type: array
- matches:
- default:
- - path:
- type: Prefix
- value: /
- description: "Matches define conditions used for matching the rule against incoming HTTP requests. Each match is independent, i.e. this rule will be matched if **any** one of the matches is satisfied. \n For example, take the following matches configuration: \n ``` matches: - path: value: \"/foo\" headers: values: version: \"2\" - path: value: \"/v2/foo\" ``` \n For a request to match against this rule, a request should satisfy EITHER of the two conditions: \n - path prefixed with `/foo` AND contains the header `version: \"2\"` - path prefix of `/v2/foo` \n See the documentation for HTTPRouteMatch on how to specify multiple match conditions that should be ANDed together. \n If no matches are specified, the default is a prefix path match on \"/\", which has the effect of matching every HTTP request. \n Each client request MUST map to a maximum of one route rule. If a request matches multiple rules, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The longest matching hostname. * The longest matching path. * The largest number of header matches. \n If ties still exist across multiple Routes, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The oldest Route based on creation timestamp. For example, a Route with a creation timestamp of \"2020-09-08 01:02:03\" is given precedence over a Route with a creation timestamp of \"2020-09-08 01:02:04\". * The Route appearing first in alphabetical order by \"/\". For example, foo/bar is given precedence over foo/baz. \n If ties still exist within the Route that has been given precedence, matching precedence MUST be granted to the first matching rule meeting the above criteria."
+ filters:
+ description: "Filters define the filters that are applied to requests that match this rule. \n The effects of ordering of multiple behaviors are currently unspecified. This can change in the future based on feedback during the alpha stage. \n Conformance-levels at this level are defined based on the type of filter: \n - ALL core filters MUST be supported by all implementations. - Implementers are encouraged to support extended filters. - Implementation-specific custom filters have no API guarantees across implementations. \n Specifying a core filter multiple times has unspecified or custom conformance. \n Support: Core"
items:
- description: "HTTPRouteMatch defines the predicate used to match requests to a given action. Multiple match types are ANDed together, i.e. the match will evaluate to true only if all conditions are satisfied. \n For example, the match below will match a HTTP request only if its path starts with `/foo` AND it contains the `version: \"1\"` header: \n ``` match: path: value: \"/foo\" headers: values: version: \"1\" ```"
+ description: HTTPRouteFilter defines processing steps that must be completed during the request or response lifecycle. HTTPRouteFilters are meant as an extension point to express processing that may be done in Gateway implementations. Some examples include request or response modification, implementing authentication strategies, rate-limiting, and traffic shaping. API guarantee/conformance is defined based on the type of the filter.
properties:
extensionRef:
- description: "ExtensionRef is an optional, implementation-specific extension to the \"match\" behavior. For example, resource \"myroutematcher\" in group \"networking.acme.io\". If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
+ description: "ExtensionRef is an optional, implementation-specific extension to the \"filter\" behavior. For example, resource \"myroutefilter\" in group \"networking.example.net\"). ExtensionRef MUST NOT be used for core and extended filters. \n Support: Implementation-specific"
properties:
group:
- description: Group is the group of the referent.
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
maxLength: 253
- minLength: 1
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
- description: Kind is kind of the referent.
- maxLength: 253
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
description: Name is the name of the referent.
@@ -1116,110 +964,272 @@ spec:
- kind
- name
type: object
- headers:
- description: Headers specifies a HTTP request header matcher.
+ requestHeaderModifier:
+ description: "RequestHeaderModifier defines a schema for a filter that modifies request headers. \n Support: Core"
properties:
- type:
- default: Exact
- description: "Type specifies how to match against the value of the header. \n Support: Core (Exact) \n Support: Custom (RegularExpression, ImplementationSpecific) \n Since RegularExpression PathType has custom conformance, implementations can support POSIX, PCRE or any other dialects of regular expressions. Please read the implementation's documentation to determine the supported dialect. \n HTTP Header name matching MUST be case-insensitive (RFC 2616 - section 4.2)."
- enum:
- - Exact
- - RegularExpression
- - ImplementationSpecific
- type: string
- values:
- additionalProperties:
+ add:
+ description: "Add adds the given header(s) (name, value) to the request before the action. It appends to any existing values associated with the header name. \n Input: GET /foo HTTP/1.1 my-header: foo \n Config: add: - name: \"my-header\" value: \"bar\" \n Output: GET /foo HTTP/1.1 my-header: foo my-header: bar"
+ items:
+ description: HTTPHeader represents an HTTP Header name and value as defined by RFC 7230.
+ properties:
+ name:
+ description: "Name is the name of the HTTP Header to be matched. Name matching MUST be case insensitive. (See https://tools.ietf.org/html/rfc7230#section-3.2). \n If multiple entries specify equivalent header names, the first entry with an equivalent name MUST be considered for a match. Subsequent entries with an equivalent header name MUST be ignored. Due to the case-insensitivity of header names, \"foo\" and \"Foo\" are considered equivalent."
+ maxLength: 256
+ minLength: 1
+ pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
+ type: string
+ value:
+ description: Value is the value of HTTP Header to be matched.
+ maxLength: 4096
+ minLength: 1
+ type: string
+ required:
+ - name
+ - value
+ type: object
+ maxItems: 16
+ type: array
+ x-kubernetes-list-map-keys:
+ - name
+ x-kubernetes-list-type: map
+ remove:
+ description: "Remove the given header(s) from the HTTP request before the action. The value of Remove is a list of HTTP header names. Note that the header names are case-insensitive (see https://datatracker.ietf.org/doc/html/rfc2616#section-4.2). \n Input: GET /foo HTTP/1.1 my-header1: foo my-header2: bar my-header3: baz \n Config: remove: [\"my-header1\", \"my-header3\"] \n Output: GET /foo HTTP/1.1 my-header2: bar"
+ items:
type: string
- description: "Values is a map of HTTP Headers to be matched. It MUST contain at least one entry. \n The HTTP header field name to match is the map key, and the value of the HTTP header is the map value. HTTP header field name matching MUST be case-insensitive. \n Multiple match values are ANDed together, meaning, a request must match all the specified headers to select the route."
+ maxItems: 16
+ type: array
+ set:
+ description: "Set overwrites the request with the given header (name, value) before the action. \n Input: GET /foo HTTP/1.1 my-header: foo \n Config: set: - name: \"my-header\" value: \"bar\" \n Output: GET /foo HTTP/1.1 my-header: bar"
+ items:
+ description: HTTPHeader represents an HTTP Header name and value as defined by RFC 7230.
+ properties:
+ name:
+ description: "Name is the name of the HTTP Header to be matched. Name matching MUST be case insensitive. (See https://tools.ietf.org/html/rfc7230#section-3.2). \n If multiple entries specify equivalent header names, the first entry with an equivalent name MUST be considered for a match. Subsequent entries with an equivalent header name MUST be ignored. Due to the case-insensitivity of header names, \"foo\" and \"Foo\" are considered equivalent."
+ maxLength: 256
+ minLength: 1
+ pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
+ type: string
+ value:
+ description: Value is the value of HTTP Header to be matched.
+ maxLength: 4096
+ minLength: 1
+ type: string
+ required:
+ - name
+ - value
+ type: object
+ maxItems: 16
+ type: array
+ x-kubernetes-list-map-keys:
+ - name
+ x-kubernetes-list-type: map
+ type: object
+ requestMirror:
+ description: "RequestMirror defines a schema for a filter that mirrors requests. Requests are sent to the specified destination, but responses from that destination are ignored. \n Support: Extended"
+ properties:
+ backendRef:
+ description: "BackendRef references a resource where mirrored requests are sent. \n If the referent cannot be found, this BackendRef is invalid and must be dropped from the Gateway. The controller must ensure the \"ResolvedRefs\" condition on the Route status is set to `status: False` and not configure this backend in the underlying implementation. \n If there is a cross-namespace reference to an *existing* object that is not allowed by a ReferencePolicy, the controller must ensure the \"ResolvedRefs\" condition on the Route is set to `status: False`, with the \"RefNotPermitted\" reason and not configure this backend in the underlying implementation. \n In either error case, the Message of the `ResolvedRefs` Condition should be used to provide more detail about the problem. \n Support: Extended for Kubernetes Service Support: Custom for any other resource"
+ properties:
+ group:
+ default: ""
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Service
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: Name is the name of the referent.
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the backend. When unspecified, the local namespace is inferred. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ port:
+ description: Port specifies the destination port number to use for this resource. Port is required when the referent is a Kubernetes Service. For other resources, destination port might be derived from the referent resource or this field.
+ format: int32
+ maximum: 65535
+ minimum: 1
+ type: integer
+ required:
+ - name
type: object
required:
- - values
+ - backendRef
+ type: object
+ requestRedirect:
+ description: "RequestRedirect defines a schema for a filter that responds to the request with an HTTP redirection. \n Support: Core"
+ properties:
+ hostname:
+ description: "Hostname is the hostname to be used in the value of the `Location` header in the response. When empty, the hostname of the request is used. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ pattern: ^(\*\.)?[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ port:
+ description: "Port is the port to be used in the value of the `Location` header in the response. When empty, port (if specified) of the request is used. \n Support: Extended"
+ format: int32
+ maximum: 65535
+ minimum: 1
+ type: integer
+ scheme:
+ description: "Scheme is the scheme to be used in the value of the `Location` header in the response. When empty, the scheme of the request is used. \n Support: Extended"
+ enum:
+ - http
+ - https
+ type: string
+ statusCode:
+ default: 302
+ description: "StatusCode is the HTTP status code to be used in response. \n Support: Core"
+ enum:
+ - 301
+ - 302
+ type: integer
type: object
+ type:
+ description: "Type identifies the type of filter to apply. As with other API fields, types are classified into three conformance levels: \n - Core: Filter types and their corresponding configuration defined by \"Support: Core\" in this package, e.g. \"RequestHeaderModifier\". All implementations must support core filters. \n - Extended: Filter types and their corresponding configuration defined by \"Support: Extended\" in this package, e.g. \"RequestMirror\". Implementers are encouraged to support extended filters. \n - Custom: Filters that are defined and supported by specific vendors. In the future, filters showing convergence in behavior across multiple implementations will be considered for inclusion in extended or core conformance levels. Filter-specific configuration for such filters is specified using the ExtensionRef field. `Type` should be set to \"ExtensionRef\" for custom filters. \n Implementers are encouraged to define custom implementation types to extend the core API with implementation-specific behavior. \n If a reference to a custom filter type cannot be resolved, the filter MUST NOT be skipped. Instead, requests that would have been processed by that filter MUST receive a HTTP error response."
+ enum:
+ - RequestHeaderModifier
+ - RequestMirror
+ - RequestRedirect
+ - ExtensionRef
+ type: string
+ required:
+ - type
+ type: object
+ maxItems: 16
+ type: array
+ matches:
+ default:
+ - path:
+ type: PathPrefix
+ value: /
+ description: "Matches define conditions used for matching the rule against incoming HTTP requests. Each match is independent, i.e. this rule will be matched if **any** one of the matches is satisfied. \n For example, take the following matches configuration: \n ``` matches: - path: value: \"/foo\" headers: - name: \"version\" value: \"v2\" - path: value: \"/v2/foo\" ``` \n For a request to match against this rule, a request must satisfy EITHER of the two conditions: \n - path prefixed with `/foo` AND contains the header `version: v2` - path prefix of `/v2/foo` \n See the documentation for HTTPRouteMatch on how to specify multiple match conditions that should be ANDed together. \n If no matches are specified, the default is a prefix path match on \"/\", which has the effect of matching every HTTP request. \n Proxy or Load Balancer routing configuration generated from HTTPRoutes MUST prioritize rules based on the following criteria, continuing on ties. Precedence must be given to the the Rule with the largest number of: \n * Characters in a matching non-wildcard hostname. * Characters in a matching hostname. * Characters in a matching path. * Header matches. * Query param matches. \n If ties still exist across multiple Routes, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The oldest Route based on creation timestamp. * The Route appearing first in alphabetical order by \"/\". \n If ties still exist within the Route that has been given precedence, matching precedence MUST be granted to the first matching rule meeting the above criteria."
+ items:
+ description: "HTTPRouteMatch defines the predicate used to match requests to a given action. Multiple match types are ANDed together, i.e. the match will evaluate to true only if all conditions are satisfied. \n For example, the match below will match a HTTP request only if its path starts with `/foo` AND it contains the `version: v1` header: \n ``` match: path: value: \"/foo\" headers: - name: \"version\" value \"v1\" ```"
+ properties:
+ headers:
+ description: Headers specifies HTTP request header matchers. Multiple match values are ANDed together, meaning, a request must match all the specified headers to select the route.
+ items:
+ description: HTTPHeaderMatch describes how to select a HTTP route by matching HTTP request headers.
+ properties:
+ name:
+ description: "Name is the name of the HTTP Header to be matched. Name matching MUST be case insensitive. (See https://tools.ietf.org/html/rfc7230#section-3.2). \n If multiple entries specify equivalent header names, only the first entry with an equivalent name MUST be considered for a match. Subsequent entries with an equivalent header name MUST be ignored. Due to the case-insensitivity of header names, \"foo\" and \"Foo\" are considered equivalent. \n When a header is repeated in an HTTP request, it is implementation-specific behavior as to how this is represented. Generally, proxies should follow the guidance from the RFC: https://www.rfc-editor.org/rfc/rfc7230.html#section-3.2.2 regarding processing a repeated header, with special handling for \"Set-Cookie\"."
+ maxLength: 256
+ minLength: 1
+ pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
+ type: string
+ type:
+ default: Exact
+ description: "Type specifies how to match against the value of the header. \n Support: Core (Exact) \n Support: Custom (RegularExpression) \n Since RegularExpression HeaderMatchType has custom conformance, implementations can support POSIX, PCRE or any other dialects of regular expressions. Please read the implementation's documentation to determine the supported dialect."
+ enum:
+ - Exact
+ - RegularExpression
+ type: string
+ value:
+ description: Value is the value of HTTP Header to be matched.
+ maxLength: 4096
+ minLength: 1
+ type: string
+ required:
+ - name
+ - value
+ type: object
+ maxItems: 16
+ type: array
+ x-kubernetes-list-map-keys:
+ - name
+ x-kubernetes-list-type: map
+ method:
+ description: "Method specifies HTTP method matcher. When specified, this route will be matched only if the request has the specified method. \n Support: Extended"
+ enum:
+ - GET
+ - HEAD
+ - POST
+ - PUT
+ - DELETE
+ - CONNECT
+ - OPTIONS
+ - TRACE
+ - PATCH
+ type: string
path:
default:
- type: Prefix
+ type: PathPrefix
value: /
description: Path specifies a HTTP request path matcher. If this field is not specified, a default prefix match on the "/" path is provided.
properties:
type:
- default: Prefix
- description: "Type specifies how to match against the path Value. \n Support: Core (Exact, Prefix) \n Support: Custom (RegularExpression, ImplementationSpecific) \n Since RegularExpression PathType has custom conformance, implementations can support POSIX, PCRE or any other dialects of regular expressions. Please read the implementation's documentation to determine the supported dialect."
+ default: PathPrefix
+ description: "Type specifies how to match against the path Value. \n Support: Core (Exact, PathPrefix) \n Support: Custom (RegularExpression)"
enum:
- Exact
- - Prefix
+ - PathPrefix
- RegularExpression
- - ImplementationSpecific
type: string
value:
default: /
description: Value of the HTTP path to match against.
+ maxLength: 1024
type: string
type: object
queryParams:
- description: QueryParams specifies a HTTP query parameter matcher.
- properties:
- type:
- default: Exact
- description: "Type specifies how to match against the value of the query parameter. \n Support: Extended (Exact) \n Support: Custom (RegularExpression, ImplementationSpecific) \n Since RegularExpression QueryParamMatchType has custom conformance, implementations can support POSIX, PCRE or any other dialects of regular expressions. Please read the implementation's documentation to determine the supported dialect."
- enum:
- - Exact
- - RegularExpression
- - ImplementationSpecific
- type: string
- values:
- additionalProperties:
+ description: QueryParams specifies HTTP query parameter matchers. Multiple match values are ANDed together, meaning, a request must match all the specified query parameters to select the route.
+ items:
+ description: HTTPQueryParamMatch describes how to select a HTTP route by matching HTTP query parameters.
+ properties:
+ name:
+ description: Name is the name of the HTTP query param to be matched. This must be an exact string match. (See https://tools.ietf.org/html/rfc7230#section-2.7.3).
+ maxLength: 256
+ minLength: 1
type: string
- description: "Values is a map of HTTP query parameters to be matched. It MUST contain at least one entry. \n The query parameter name to match is the map key, and the value of the query parameter is the map value. \n Multiple match values are ANDed together, meaning, a request must match all the specified query parameters to select the route. \n HTTP query parameter matching MUST be case-sensitive for both keys and values. (See https://tools.ietf.org/html/rfc7230#section-2.7.3). \n Note that the query parameter key MUST always be an exact match by string comparison."
- type: object
- required:
- - values
- type: object
+ type:
+ default: Exact
+ description: "Type specifies how to match against the value of the query parameter. \n Support: Extended (Exact) \n Support: Custom (RegularExpression) \n Since RegularExpression QueryParamMatchType has custom conformance, implementations can support POSIX, PCRE or any other dialects of regular expressions. Please read the implementation's documentation to determine the supported dialect."
+ enum:
+ - Exact
+ - RegularExpression
+ type: string
+ value:
+ description: Value is the value of HTTP query param to be matched.
+ maxLength: 1024
+ minLength: 1
+ type: string
+ required:
+ - name
+ - value
+ type: object
+ maxItems: 16
+ type: array
+ x-kubernetes-list-map-keys:
+ - name
+ x-kubernetes-list-type: map
type: object
maxItems: 8
type: array
type: object
maxItems: 16
type: array
- tls:
- description: "TLS defines the TLS certificate to use for Hostnames defined in this Route. This configuration only takes effect if the AllowRouteOverride field is set to true in the associated Gateway resource. \n Collisions can happen if multiple HTTPRoutes define a TLS certificate for the same hostname. In such a case, conflict resolution guiding principles apply, specifically, if hostnames are same and two different certificates are specified then the certificate in the oldest resource wins. \n Please note that HTTP Route-selection takes place after the TLS Handshake (ClientHello). Due to this, TLS certificate defined here will take precedence even if the request has the potential to match multiple routes (in case multiple HTTPRoutes share the same hostname). \n Support: Core"
- properties:
- certificateRef:
- description: "CertificateRef is a reference to a Kubernetes object that contains a TLS certificate and private key. This certificate is used to establish a TLS handshake for requests that match the hostname of the associated HTTPRoute. The referenced object MUST reside in the same namespace as HTTPRoute. \n This field is required when the TLS configuration mode of the associated Gateway listener is set to \"Passthrough\". \n CertificateRef can reference a standard Kubernetes resource, i.e. Secret, or an implementation-specific custom resource. \n Support: Core (Kubernetes Secrets) \n Support: Implementation-specific (Other resource types)"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
- required:
- - certificateRef
- type: object
type: object
status:
description: Status defines the current state of HTTPRoute.
properties:
- gateways:
- description: "Gateways is a list of Gateways that are associated with the route, and the status of the route with respect to each Gateway. When a Gateway selects this route, the controller that manages the Gateway must add an entry to this list when the controller first sees the route and should update the entry as appropriate when the route is modified. \n A maximum of 100 Gateways will be represented in this list. If this list is full, there may be additional Gateways using this Route that are not included in the list. An empty list means the route has not been admitted by any Gateway."
+ parents:
+ description: "Parents is a list of parent resources (usually Gateways) that are associated with the route, and the status of the route with respect to each parent. When this route attaches to a parent, the controller that manages the parent must add an entry to this list when the controller first sees the route and should update the entry as appropriate when the route or gateway is modified. \n Note that parent references that cannot be resolved by an implementation of this API will not be added to this list. Implementations of this API can only populate Route status for the Gateways/parent resources they are responsible for. \n A maximum of 32 Gateways will be represented in this list. An empty list means the route has not been attached to any Gateway."
items:
- description: RouteGatewayStatus describes the status of a route with respect to an associated Gateway.
+ description: RouteParentStatus describes the status of a route with respect to an associated Parent.
properties:
conditions:
- description: Conditions describes the status of the route with respect to the Gateway. The "Admitted" condition must always be specified by controllers to indicate whether the route has been admitted or rejected by the Gateway, and why. Note that the route's availability is also subject to the Gateway's own status conditions and listener status.
+ description: "Conditions describes the status of the route with respect to the Gateway. Note that the route's availability is also subject to the Gateway's own status conditions and listener status. \n If the Route's ParentRef specifies an existing Gateway that supports Routes of this kind AND that Gateway's controller has sufficient access, then that Gateway's controller MUST set the \"Accepted\" condition on the Route, to indicate whether the route has been accepted or rejected by the Gateway, and why. \n A Route MUST be considered \"Accepted\" if at least one of the Route's rules is implemented by the Gateway. \n There are a number of cases where the \"Accepted\" condition may not be set due to lack of controller visibility, that includes when: \n * The Route refers to a non-existent parent. * The Route is of a type that the controller does not support. * The Route is in a namespace the the controller does not have access to."
items:
description: "Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example, type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }"
properties:
@@ -1262,39 +1272,64 @@ spec:
- type
type: object
maxItems: 8
+ minItems: 1
type: array
x-kubernetes-list-map-keys:
- type
x-kubernetes-list-type: map
- gatewayRef:
- description: GatewayRef is a reference to a Gateway object that is associated with the route.
+ controllerName:
+ description: "ControllerName is a domain/path string that indicates the name of the controller that wrote this status. This corresponds with the controllerName field on GatewayClass. \n Example: \"example.net/gateway-controller\". \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names)."
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*\/[A-Za-z0-9\/\-._~%!$&'()*+,;=:]+$
+ type: string
+ parentRef:
+ description: ParentRef corresponds with a ParentRef in the spec that this RouteParentStatus struct describes the status of.
properties:
- controller:
- description: "Controller is a domain/path string that indicates the controller implementing the Gateway. This corresponds with the controller field on GatewayClass. \n Example: \"acme.io/gateway-controller\". \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names)."
+ group:
+ default: gateway.networking.k8s.io
+ description: "Group is the group of the referent. \n Support: Core"
maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Gateway
+ description: "Kind is kind of the referent. \n Support: Core (Gateway) Support: Custom (Other Resources)"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
- description: Name is the name of the referent.
+ description: "Name is the name of the referent. \n Support: Core"
maxLength: 253
minLength: 1
type: string
namespace:
- description: Namespace is the namespace of the referent.
+ description: "Namespace is the namespace of the referent. When unspecified (or empty string), this refers to the local namespace of the Route. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ sectionName:
+ description: "SectionName is the name of a section within the target resource. In the following resources, SectionName is interpreted as the following: \n * Gateway: Listener Name \n Implementations MAY choose to support attaching Routes to other resources. If that is the case, they MUST clearly document how SectionName is interpreted. \n When unspecified (empty string), this will reference the entire resource. For the purpose of status, an attachment is considered successful if at least one section in the parent resource accepts it. For example, Gateway listeners can restrict which Routes can attach to them by Route kind, namespace, or hostname. If 1 of 2 Gateway listeners accept attachment from the referencing Route, the Route MUST be considered successfully attached. If no Gateway listeners accept attachment from this Route, the Route MUST be considered detached from the Gateway. \n Support: Core"
maxLength: 253
minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
required:
- name
- - namespace
type: object
required:
- - gatewayRef
+ - controllerName
+ - parentRef
type: object
- maxItems: 100
+ maxItems: 32
type: array
required:
- - gateways
+ - parents
type: object
+ required:
+ - spec
type: object
served: true
storage: true
@@ -1311,11 +1346,123 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ api-approved.kubernetes.io: https://github.com/kubernetes-sigs/gateway-api/pull/891
creationTimestamp: null
- name: tcproutes.networking.x-k8s.io
+ name: referencepolicies.gateway.networking.k8s.io
spec:
- group: networking.x-k8s.io
+ group: gateway.networking.k8s.io
+ names:
+ categories:
+ - gateway-api
+ kind: ReferencePolicy
+ listKind: ReferencePolicyList
+ plural: referencepolicies
+ shortNames:
+ - refpol
+ singular: referencepolicy
+ scope: Namespaced
+ versions:
+ - additionalPrinterColumns:
+ - jsonPath: .metadata.creationTimestamp
+ name: Age
+ type: date
+ name: v1alpha2
+ schema:
+ openAPIV3Schema:
+ description: "ReferencePolicy identifies kinds of resources in other namespaces that are trusted to reference the specified kinds of resources in the same namespace as the policy. \n Each ReferencePolicy can be used to represent a unique trust relationship. Additional Reference Policies can be used to add to the set of trusted sources of inbound references for the namespace they are defined within. \n All cross-namespace references in Gateway API (with the exception of cross-namespace Gateway-route attachment) require a ReferencePolicy. \n Support: Core"
+ properties:
+ apiVersion:
+ description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
+ type: string
+ kind:
+ description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
+ type: string
+ metadata:
+ type: object
+ spec:
+ description: Spec defines the desired state of ReferencePolicy.
+ properties:
+ from:
+ description: "From describes the trusted namespaces and kinds that can reference the resources described in \"To\". Each entry in this list must be considered to be an additional place that references can be valid from, or to put this another way, entries must be combined using OR. \n Support: Core"
+ items:
+ description: ReferencePolicyFrom describes trusted namespaces and kinds.
+ properties:
+ group:
+ description: "Group is the group of the referent. When empty, the Kubernetes core API group is inferred. \n Support: Core"
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ description: "Kind is the kind of the referent. Although implementations may support additional resources, the following Route types are part of the \"Core\" support level for this field: \n * HTTPRoute * TCPRoute * TLSRoute * UDPRoute"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the referent. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ required:
+ - group
+ - kind
+ type: object
+ maxItems: 16
+ minItems: 1
+ type: array
+ to:
+ description: "To describes the resources that may be referenced by the resources described in \"From\". Each entry in this list must be considered to be an additional place that references can be valid to, or to put this another way, entries must be combined using OR. \n Support: Core"
+ items:
+ description: ReferencePolicyTo describes what Kinds are allowed as targets of the references.
+ properties:
+ group:
+ description: "Group is the group of the referent. When empty, the Kubernetes core API group is inferred. \n Support: Core"
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ description: "Kind is the kind of the referent. Although implementations may support additional resources, the following types are part of the \"Core\" support level for this field: \n * Service"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: Name is the name of the referent. When unspecified or empty, this policy refers to all resources of the specified Group and Kind in the local namespace.
+ maxLength: 253
+ minLength: 1
+ type: string
+ required:
+ - group
+ - kind
+ type: object
+ maxItems: 16
+ minItems: 1
+ type: array
+ required:
+ - from
+ - to
+ type: object
+ type: object
+ served: true
+ storage: true
+ subresources: {}
+status:
+ acceptedNames:
+ kind: ""
+ plural: ""
+ conditions: []
+ storedVersions: []
+---
+apiVersion: apiextensions.k8s.io/v1
+kind: CustomResourceDefinition
+metadata:
+ annotations:
+ api-approved.kubernetes.io: https://github.com/kubernetes-sigs/gateway-api/pull/891
+ creationTimestamp: null
+ name: tcproutes.gateway.networking.k8s.io
+spec:
+ group: gateway.networking.k8s.io
names:
categories:
- gateway-api
@@ -1329,10 +1476,10 @@ spec:
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
- name: v1alpha1
+ name: v1alpha2
schema:
openAPIV3Schema:
- description: TCPRoute is the Schema for the TCPRoute resource.
+ description: TCPRoute provides a way to route TCP requests. When combined with a Gateway listener, it can be used to forward connections on the port specified by the listener to a set of backends specified by the TCPRoute.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
@@ -1345,127 +1492,99 @@ spec:
spec:
description: Spec defines the desired state of TCPRoute.
properties:
- gateways:
- default:
- allow: SameNamespace
- description: Gateways defines which Gateways can use this Route.
- properties:
- allow:
- default: SameNamespace
- description: 'Allow indicates which Gateways will be allowed to use this route. Possible values are: * All: Gateways in any namespace can use this route. * FromList: Only Gateways specified in GatewayRefs may use this route. * SameNamespace: Only Gateways in the same namespace may use this route.'
- enum:
- - All
- - FromList
- - SameNamespace
- type: string
- gatewayRefs:
- description: GatewayRefs must be specified when Allow is set to "FromList". In that case, only Gateways referenced in this list will be allowed to use this route. This field is ignored for other values of "Allow".
- items:
- description: GatewayReference identifies a Gateway in a specified namespace.
- properties:
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- namespace:
- description: Namespace is the namespace of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - name
- - namespace
- type: object
- type: array
- type: object
+ parentRefs:
+ description: "ParentRefs references the resources (usually Gateways) that a Route wants to be attached to. Note that the referenced parent resource needs to allow this for the attachment to be complete. For Gateways, that means the Gateway needs to allow attachment from Routes of this kind and namespace. \n The only kind of parent resource with \"Core\" support is Gateway. This API may be extended in the future to support additional kinds of parent resources such as one of the route kinds. \n It is invalid to reference an identical parent more than once. It is valid to reference multiple distinct sections within the same parent resource, such as 2 Listeners within a Gateway. \n It is possible to separately reference multiple distinct objects that may be collapsed by an implementation. For example, some implementations may choose to merge compatible Gateway Listeners together. If that is the case, the list of routes attached to those resources should also be merged."
+ items:
+ description: "ParentRef identifies an API object (usually a Gateway) that can be considered a parent of this resource (usually a route). The only kind of parent resource with \"Core\" support is Gateway. This API may be extended in the future to support additional kinds of parent resources, such as HTTPRoute. \n The API object must be valid in the cluster; the Group and Kind must be registered in the cluster for this reference to be valid. \n References to objects with invalid Group and Kind are not valid, and must be rejected by the implementation, with appropriate Conditions set on the containing object."
+ properties:
+ group:
+ default: gateway.networking.k8s.io
+ description: "Group is the group of the referent. \n Support: Core"
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Gateway
+ description: "Kind is kind of the referent. \n Support: Core (Gateway) Support: Custom (Other Resources)"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: "Name is the name of the referent. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the referent. When unspecified (or empty string), this refers to the local namespace of the Route. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ sectionName:
+ description: "SectionName is the name of a section within the target resource. In the following resources, SectionName is interpreted as the following: \n * Gateway: Listener Name \n Implementations MAY choose to support attaching Routes to other resources. If that is the case, they MUST clearly document how SectionName is interpreted. \n When unspecified (empty string), this will reference the entire resource. For the purpose of status, an attachment is considered successful if at least one section in the parent resource accepts it. For example, Gateway listeners can restrict which Routes can attach to them by Route kind, namespace, or hostname. If 1 of 2 Gateway listeners accept attachment from the referencing Route, the Route MUST be considered successfully attached. If no Gateway listeners accept attachment from this Route, the Route MUST be considered detached from the Gateway. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ required:
+ - name
+ type: object
+ maxItems: 32
+ type: array
rules:
description: Rules are a list of TCP matchers and actions.
items:
description: TCPRouteRule is the configuration for a given rule.
properties:
- forwardTo:
- description: ForwardTo defines the backend(s) where matching requests should be sent.
+ backendRefs:
+ description: "BackendRefs defines the backend(s) where matching requests should be sent. If unspecified or invalid (refers to a non-existent resource or a Service with no endpoints), the underlying implementation MUST actively reject connection attempts to this backend. Connection rejections must respect weight; if an invalid backend is requested to have 80% of connections, then 80% of connections must be rejected instead. \n Support: Core for Kubernetes Service Support: Custom for any other resource \n Support for weight: Extended"
items:
- description: RouteForwardTo defines how a Route should forward a request.
+ description: "BackendRef defines how a Route should forward a request to a Kubernetes resource. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details."
properties:
- backendRef:
- description: "BackendRef is a reference to a backend to forward matched requests to. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
- port:
- description: "Port specifies the destination port number to use for the backend referenced by the ServiceName or BackendRef field. If unspecified, the destination port in the request is used when forwarding to a backendRef or serviceName. \n Support: Core"
- format: int32
- maximum: 65535
- minimum: 1
- type: integer
- serviceName:
- description: "ServiceName refers to the name of the Service to forward matched requests to. When specified, this takes the place of BackendRef. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n The protocol to use is defined using AppProtocol field (introduced in Kubernetes 1.18) in the Service resource. In the absence of the AppProtocol field a `networking.x-k8s.io/app-protocol` annotation on the BackendPolicy resource may be used to define the protocol. If the AppProtocol field is available, this annotation should not be used. The AppProtocol field, when populated, takes precedence over the annotation in the BackendPolicy resource. For custom backends, it is encouraged to add a semantically-equivalent field in the Custom Resource Definition. \n Support: Core"
- maxLength: 253
- type: string
- weight:
- default: 1
- description: "Weight specifies the proportion of HTTP requests forwarded to the backend referenced by the ServiceName or BackendRef field. This is computed as weight/(sum of all weights in this ForwardTo list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. Weight is not a percentage and the sum of weights does not need to equal 100. \n If only one backend is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weight is set to 0, no traffic should be forwarded for this entry. If unspecified, weight defaults to 1. \n Support: Extended"
- format: int32
- maximum: 1000000
- minimum: 0
- type: integer
- type: object
- maxItems: 16
- minItems: 1
- type: array
- matches:
- description: "Matches define conditions used for matching the rule against incoming TCP connections. Each match is independent, i.e. this rule will be matched if **any** one of the matches is satisfied. If unspecified (i.e. empty), this Rule will match all requests for the associated Listener. \n Each client request MUST map to a maximum of one route rule. If a request matches multiple rules, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The most specific match specified by ExtensionRef. Each implementation that supports ExtensionRef may have different ways of determining the specificity of the referenced extension. \n If ties still exist across multiple Routes, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The oldest Route based on creation timestamp. For example, a Route with a creation timestamp of \"2020-09-08 01:02:03\" is given precedence over a Route with a creation timestamp of \"2020-09-08 01:02:04\". * The Route appearing first in alphabetical order by \"/\". For example, foo/bar is given precedence over foo/baz. \n If ties still exist within the Route that has been given precedence, matching precedence MUST be granted to the first matching rule meeting the above criteria."
- items:
- description: TCPRouteMatch defines the predicate used to match connections to a given action.
- properties:
- extensionRef:
- description: "ExtensionRef is an optional, implementation-specific extension to the \"match\" behavior. For example, resource \"mytcproutematcher\" in group \"networking.acme.io\". If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
+ group:
+ default: ""
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Service
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: Name is the name of the referent.
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the backend. When unspecified, the local namespace is inferred. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ port:
+ description: Port specifies the destination port number to use for this resource. Port is required when the referent is a Kubernetes Service. For other resources, destination port might be derived from the referent resource or this field.
+ format: int32
+ maximum: 65535
+ minimum: 1
+ type: integer
+ weight:
+ default: 1
+ description: "Weight specifies the proportion of requests forwarded to the referenced backend. This is computed as weight/(sum of all weights in this BackendRefs list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. Weight is not a percentage and the sum of weights does not need to equal 100. \n If only one backend is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weight is set to 0, no traffic should be forwarded for this entry. If unspecified, weight defaults to 1. \n Support for this field varies based on the context where used."
+ format: int32
+ maximum: 1000000
+ minimum: 0
+ type: integer
+ required:
+ - name
type: object
- maxItems: 8
+ maxItems: 16
+ minItems: 1
type: array
- required:
- - forwardTo
type: object
maxItems: 16
minItems: 1
@@ -1476,13 +1595,13 @@ spec:
status:
description: Status defines the current state of TCPRoute.
properties:
- gateways:
- description: "Gateways is a list of Gateways that are associated with the route, and the status of the route with respect to each Gateway. When a Gateway selects this route, the controller that manages the Gateway must add an entry to this list when the controller first sees the route and should update the entry as appropriate when the route is modified. \n A maximum of 100 Gateways will be represented in this list. If this list is full, there may be additional Gateways using this Route that are not included in the list. An empty list means the route has not been admitted by any Gateway."
+ parents:
+ description: "Parents is a list of parent resources (usually Gateways) that are associated with the route, and the status of the route with respect to each parent. When this route attaches to a parent, the controller that manages the parent must add an entry to this list when the controller first sees the route and should update the entry as appropriate when the route or gateway is modified. \n Note that parent references that cannot be resolved by an implementation of this API will not be added to this list. Implementations of this API can only populate Route status for the Gateways/parent resources they are responsible for. \n A maximum of 32 Gateways will be represented in this list. An empty list means the route has not been attached to any Gateway."
items:
- description: RouteGatewayStatus describes the status of a route with respect to an associated Gateway.
+ description: RouteParentStatus describes the status of a route with respect to an associated Parent.
properties:
conditions:
- description: Conditions describes the status of the route with respect to the Gateway. The "Admitted" condition must always be specified by controllers to indicate whether the route has been admitted or rejected by the Gateway, and why. Note that the route's availability is also subject to the Gateway's own status conditions and listener status.
+ description: "Conditions describes the status of the route with respect to the Gateway. Note that the route's availability is also subject to the Gateway's own status conditions and listener status. \n If the Route's ParentRef specifies an existing Gateway that supports Routes of this kind AND that Gateway's controller has sufficient access, then that Gateway's controller MUST set the \"Accepted\" condition on the Route, to indicate whether the route has been accepted or rejected by the Gateway, and why. \n A Route MUST be considered \"Accepted\" if at least one of the Route's rules is implemented by the Gateway. \n There are a number of cases where the \"Accepted\" condition may not be set due to lack of controller visibility, that includes when: \n * The Route refers to a non-existent parent. * The Route is of a type that the controller does not support. * The Route is in a namespace the the controller does not have access to."
items:
description: "Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example, type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }"
properties:
@@ -1525,39 +1644,64 @@ spec:
- type
type: object
maxItems: 8
+ minItems: 1
type: array
x-kubernetes-list-map-keys:
- type
x-kubernetes-list-type: map
- gatewayRef:
- description: GatewayRef is a reference to a Gateway object that is associated with the route.
+ controllerName:
+ description: "ControllerName is a domain/path string that indicates the name of the controller that wrote this status. This corresponds with the controllerName field on GatewayClass. \n Example: \"example.net/gateway-controller\". \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names)."
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*\/[A-Za-z0-9\/\-._~%!$&'()*+,;=:]+$
+ type: string
+ parentRef:
+ description: ParentRef corresponds with a ParentRef in the spec that this RouteParentStatus struct describes the status of.
properties:
- controller:
- description: "Controller is a domain/path string that indicates the controller implementing the Gateway. This corresponds with the controller field on GatewayClass. \n Example: \"acme.io/gateway-controller\". \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names)."
+ group:
+ default: gateway.networking.k8s.io
+ description: "Group is the group of the referent. \n Support: Core"
maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Gateway
+ description: "Kind is kind of the referent. \n Support: Core (Gateway) Support: Custom (Other Resources)"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
- description: Name is the name of the referent.
+ description: "Name is the name of the referent. \n Support: Core"
maxLength: 253
minLength: 1
type: string
namespace:
- description: Namespace is the namespace of the referent.
+ description: "Namespace is the namespace of the referent. When unspecified (or empty string), this refers to the local namespace of the Route. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ sectionName:
+ description: "SectionName is the name of a section within the target resource. In the following resources, SectionName is interpreted as the following: \n * Gateway: Listener Name \n Implementations MAY choose to support attaching Routes to other resources. If that is the case, they MUST clearly document how SectionName is interpreted. \n When unspecified (empty string), this will reference the entire resource. For the purpose of status, an attachment is considered successful if at least one section in the parent resource accepts it. For example, Gateway listeners can restrict which Routes can attach to them by Route kind, namespace, or hostname. If 1 of 2 Gateway listeners accept attachment from the referencing Route, the Route MUST be considered successfully attached. If no Gateway listeners accept attachment from this Route, the Route MUST be considered detached from the Gateway. \n Support: Core"
maxLength: 253
minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
required:
- name
- - namespace
type: object
required:
- - gatewayRef
+ - controllerName
+ - parentRef
type: object
- maxItems: 100
+ maxItems: 32
type: array
required:
- - gateways
+ - parents
type: object
+ required:
+ - spec
type: object
served: true
storage: true
@@ -1574,11 +1718,11 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ api-approved.kubernetes.io: https://github.com/kubernetes-sigs/gateway-api/pull/891
creationTimestamp: null
- name: tlsroutes.networking.x-k8s.io
+ name: tlsroutes.gateway.networking.k8s.io
spec:
- group: networking.x-k8s.io
+ group: gateway.networking.k8s.io
names:
categories:
- gateway-api
@@ -1592,7 +1736,7 @@ spec:
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
- name: v1alpha1
+ name: v1alpha2
schema:
openAPIV3Schema:
description: "The TLSRoute resource is similar to TCPRoute, but can be configured to match against TLS-specific metadata. This allows more flexibility in matching streams for a given TLS listener. \n If you need to forward traffic to a single target for a TLS listener, you could choose to use a TCPRoute with a TLS listener."
@@ -1608,136 +1752,109 @@ spec:
spec:
description: Spec defines the desired state of TLSRoute.
properties:
- gateways:
- default:
- allow: SameNamespace
- description: Gateways defines which Gateways can use this Route.
- properties:
- allow:
- default: SameNamespace
- description: 'Allow indicates which Gateways will be allowed to use this route. Possible values are: * All: Gateways in any namespace can use this route. * FromList: Only Gateways specified in GatewayRefs may use this route. * SameNamespace: Only Gateways in the same namespace may use this route.'
- enum:
- - All
- - FromList
- - SameNamespace
- type: string
- gatewayRefs:
- description: GatewayRefs must be specified when Allow is set to "FromList". In that case, only Gateways referenced in this list will be allowed to use this route. This field is ignored for other values of "Allow".
- items:
- description: GatewayReference identifies a Gateway in a specified namespace.
- properties:
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- namespace:
- description: Namespace is the namespace of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - name
- - namespace
- type: object
- type: array
- type: object
+ hostnames:
+ description: "Hostnames defines a set of SNI names that should match against the SNI attribute of TLS ClientHello message in TLS handshake. This matches the RFC 1123 definition of a hostname with 2 notable exceptions: \n 1. IPs are not allowed in SNI names per RFC 6066. 2. A hostname may be prefixed with a wildcard label (`*.`). The wildcard label must appear by itself as the first label. \n If a hostname is specified by both the Listener and TLSRoute, there must be at least one intersecting hostname for the TLSRoute to be attached to the Listener. For example: \n * A Listener with `test.example.com` as the hostname matches TLSRoutes that have either not specified any hostnames, or have specified at least one of `test.example.com` or `*.example.com`. * A Listener with `*.example.com` as the hostname matches TLSRoutes that have either not specified any hostnames or have specified at least one hostname that matches the Listener hostname. For example, `test.example.com` and `*.example.com` would both match. On the other hand, `example.com` and `test.example.net` would not match. \n If both the Listener and TLSRoute have specified hostnames, any TLSRoute hostnames that do not match the Listener hostname MUST be ignored. For example, if a Listener specified `*.example.com`, and the TLSRoute specified `test.example.com` and `test.example.net`, `test.example.net` must not be considered for a match. \n If both the Listener and TLSRoute have specified hostnames, and none match with the criteria above, then the TLSRoute is not accepted. The implementation must raise an 'Accepted' Condition with a status of `False` in the corresponding RouteParentStatus. \n Support: Core"
+ items:
+ description: "Hostname is the fully qualified domain name of a network host. This matches the RFC 1123 definition of a hostname with 2 notable exceptions: \n 1. IPs are not allowed. 2. A hostname may be prefixed with a wildcard label (`*.`). The wildcard label must appear by itself as the first label. \n Hostname can be \"precise\" which is a domain name without the terminating dot of a network host (e.g. \"foo.example.com\") or \"wildcard\", which is a domain name prefixed with a single wildcard label (e.g. `*.example.com`). \n Note that as per RFC1035 and RFC1123, a *label* must consist of lower case alphanumeric characters or '-', and must start and end with an alphanumeric character. No other punctuation is allowed."
+ maxLength: 253
+ minLength: 1
+ pattern: ^(\*\.)?[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ maxItems: 16
+ type: array
+ parentRefs:
+ description: "ParentRefs references the resources (usually Gateways) that a Route wants to be attached to. Note that the referenced parent resource needs to allow this for the attachment to be complete. For Gateways, that means the Gateway needs to allow attachment from Routes of this kind and namespace. \n The only kind of parent resource with \"Core\" support is Gateway. This API may be extended in the future to support additional kinds of parent resources such as one of the route kinds. \n It is invalid to reference an identical parent more than once. It is valid to reference multiple distinct sections within the same parent resource, such as 2 Listeners within a Gateway. \n It is possible to separately reference multiple distinct objects that may be collapsed by an implementation. For example, some implementations may choose to merge compatible Gateway Listeners together. If that is the case, the list of routes attached to those resources should also be merged."
+ items:
+ description: "ParentRef identifies an API object (usually a Gateway) that can be considered a parent of this resource (usually a route). The only kind of parent resource with \"Core\" support is Gateway. This API may be extended in the future to support additional kinds of parent resources, such as HTTPRoute. \n The API object must be valid in the cluster; the Group and Kind must be registered in the cluster for this reference to be valid. \n References to objects with invalid Group and Kind are not valid, and must be rejected by the implementation, with appropriate Conditions set on the containing object."
+ properties:
+ group:
+ default: gateway.networking.k8s.io
+ description: "Group is the group of the referent. \n Support: Core"
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Gateway
+ description: "Kind is kind of the referent. \n Support: Core (Gateway) Support: Custom (Other Resources)"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: "Name is the name of the referent. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the referent. When unspecified (or empty string), this refers to the local namespace of the Route. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ sectionName:
+ description: "SectionName is the name of a section within the target resource. In the following resources, SectionName is interpreted as the following: \n * Gateway: Listener Name \n Implementations MAY choose to support attaching Routes to other resources. If that is the case, they MUST clearly document how SectionName is interpreted. \n When unspecified (empty string), this will reference the entire resource. For the purpose of status, an attachment is considered successful if at least one section in the parent resource accepts it. For example, Gateway listeners can restrict which Routes can attach to them by Route kind, namespace, or hostname. If 1 of 2 Gateway listeners accept attachment from the referencing Route, the Route MUST be considered successfully attached. If no Gateway listeners accept attachment from this Route, the Route MUST be considered detached from the Gateway. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ required:
+ - name
+ type: object
+ maxItems: 32
+ type: array
rules:
description: Rules are a list of TLS matchers and actions.
items:
description: TLSRouteRule is the configuration for a given rule.
properties:
- forwardTo:
- description: ForwardTo defines the backend(s) where matching requests should be sent.
+ backendRefs:
+ description: "BackendRefs defines the backend(s) where matching requests should be sent. If unspecified or invalid (refers to a non-existent resource or a Service with no endpoints), the rule performs no forwarding; if no filters are specified that would result in a response being sent, the underlying implementation must actively reject request attempts to this backend, by rejecting the connection or returning a 503 status code. Request rejections must respect weight; if an invalid backend is requested to have 80% of requests, then 80% of requests must be rejected instead. \n Support: Core for Kubernetes Service Support: Custom for any other resource \n Support for weight: Extended"
items:
- description: RouteForwardTo defines how a Route should forward a request.
+ description: "BackendRef defines how a Route should forward a request to a Kubernetes resource. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details."
properties:
- backendRef:
- description: "BackendRef is a reference to a backend to forward matched requests to. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
+ group:
+ default: ""
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Service
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: Name is the name of the referent.
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the backend. When unspecified, the local namespace is inferred. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
port:
- description: "Port specifies the destination port number to use for the backend referenced by the ServiceName or BackendRef field. If unspecified, the destination port in the request is used when forwarding to a backendRef or serviceName. \n Support: Core"
+ description: Port specifies the destination port number to use for this resource. Port is required when the referent is a Kubernetes Service. For other resources, destination port might be derived from the referent resource or this field.
format: int32
maximum: 65535
minimum: 1
type: integer
- serviceName:
- description: "ServiceName refers to the name of the Service to forward matched requests to. When specified, this takes the place of BackendRef. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n The protocol to use is defined using AppProtocol field (introduced in Kubernetes 1.18) in the Service resource. In the absence of the AppProtocol field a `networking.x-k8s.io/app-protocol` annotation on the BackendPolicy resource may be used to define the protocol. If the AppProtocol field is available, this annotation should not be used. The AppProtocol field, when populated, takes precedence over the annotation in the BackendPolicy resource. For custom backends, it is encouraged to add a semantically-equivalent field in the Custom Resource Definition. \n Support: Core"
- maxLength: 253
- type: string
weight:
default: 1
- description: "Weight specifies the proportion of HTTP requests forwarded to the backend referenced by the ServiceName or BackendRef field. This is computed as weight/(sum of all weights in this ForwardTo list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. Weight is not a percentage and the sum of weights does not need to equal 100. \n If only one backend is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weight is set to 0, no traffic should be forwarded for this entry. If unspecified, weight defaults to 1. \n Support: Extended"
+ description: "Weight specifies the proportion of requests forwarded to the referenced backend. This is computed as weight/(sum of all weights in this BackendRefs list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. Weight is not a percentage and the sum of weights does not need to equal 100. \n If only one backend is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weight is set to 0, no traffic should be forwarded for this entry. If unspecified, weight defaults to 1. \n Support for this field varies based on the context where used."
format: int32
maximum: 1000000
minimum: 0
type: integer
+ required:
+ - name
type: object
maxItems: 16
minItems: 1
type: array
- matches:
- description: "Matches define conditions used for matching the rule against incoming TLS connections. Each match is independent, i.e. this rule will be matched if **any** one of the matches is satisfied. If unspecified (i.e. empty), this Rule will match all requests for the associated Listener. \n Each client request MUST map to a maximum of one route rule. If a request matches multiple rules, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The longest matching SNI. * The longest matching precise SNI (without a wildcard). This means that \"b.example.com\" should be given precedence over \"*.example.com\". * The most specific match specified by ExtensionRef. Each implementation that supports ExtensionRef may have different ways of determining the specificity of the referenced extension. \n If ties still exist across multiple Routes, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The oldest Route based on creation timestamp. For example, a Route with a creation timestamp of \"2020-09-08 01:02:03\" is given precedence over a Route with a creation timestamp of \"2020-09-08 01:02:04\". * The Route appearing first in alphabetical order by \"/\". For example, foo/bar is given precedence over foo/baz. \n If ties still exist within the Route that has been given precedence, matching precedence MUST be granted to the first matching rule meeting the above criteria."
- items:
- description: TLSRouteMatch defines the predicate used to match connections to a given action.
- properties:
- extensionRef:
- description: "ExtensionRef is an optional, implementation-specific extension to the \"match\" behavior. For example, resource \"mytlsroutematcher\" in group \"networking.acme.io\". If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
- snis:
- description: "SNIs defines a set of SNI names that should match against the SNI attribute of TLS ClientHello message in TLS handshake. \n SNI can be \"precise\" which is a domain name without the terminating dot of a network host (e.g. \"foo.example.com\") or \"wildcard\", which is a domain name prefixed with a single wildcard label (e.g. `*.example.com`). The wildcard character `*` must appear by itself as the first DNS label and matches only a single label. You cannot have a wildcard label by itself (e.g. Host == `*`). \n Requests will be matched against the Host field in the following order: \n 1. If SNI is precise, the request matches this rule if the SNI in ClientHello is equal to one of the defined SNIs. 2. If SNI is a wildcard, then the request matches this rule if the SNI is to equal to the suffix (removing the first label) of the wildcard rule. 3. If SNIs is unspecified, all requests associated with the gateway TLS listener will match. This can be used to define a default backend for a TLS listener. \n Support: Core"
- items:
- description: Hostname is used to specify a hostname that should be matched.
- maxLength: 253
- minLength: 1
- type: string
- maxItems: 16
- type: array
- type: object
- maxItems: 8
- type: array
- required:
- - forwardTo
type: object
maxItems: 16
minItems: 1
@@ -1748,13 +1865,13 @@ spec:
status:
description: Status defines the current state of TLSRoute.
properties:
- gateways:
- description: "Gateways is a list of Gateways that are associated with the route, and the status of the route with respect to each Gateway. When a Gateway selects this route, the controller that manages the Gateway must add an entry to this list when the controller first sees the route and should update the entry as appropriate when the route is modified. \n A maximum of 100 Gateways will be represented in this list. If this list is full, there may be additional Gateways using this Route that are not included in the list. An empty list means the route has not been admitted by any Gateway."
+ parents:
+ description: "Parents is a list of parent resources (usually Gateways) that are associated with the route, and the status of the route with respect to each parent. When this route attaches to a parent, the controller that manages the parent must add an entry to this list when the controller first sees the route and should update the entry as appropriate when the route or gateway is modified. \n Note that parent references that cannot be resolved by an implementation of this API will not be added to this list. Implementations of this API can only populate Route status for the Gateways/parent resources they are responsible for. \n A maximum of 32 Gateways will be represented in this list. An empty list means the route has not been attached to any Gateway."
items:
- description: RouteGatewayStatus describes the status of a route with respect to an associated Gateway.
+ description: RouteParentStatus describes the status of a route with respect to an associated Parent.
properties:
conditions:
- description: Conditions describes the status of the route with respect to the Gateway. The "Admitted" condition must always be specified by controllers to indicate whether the route has been admitted or rejected by the Gateway, and why. Note that the route's availability is also subject to the Gateway's own status conditions and listener status.
+ description: "Conditions describes the status of the route with respect to the Gateway. Note that the route's availability is also subject to the Gateway's own status conditions and listener status. \n If the Route's ParentRef specifies an existing Gateway that supports Routes of this kind AND that Gateway's controller has sufficient access, then that Gateway's controller MUST set the \"Accepted\" condition on the Route, to indicate whether the route has been accepted or rejected by the Gateway, and why. \n A Route MUST be considered \"Accepted\" if at least one of the Route's rules is implemented by the Gateway. \n There are a number of cases where the \"Accepted\" condition may not be set due to lack of controller visibility, that includes when: \n * The Route refers to a non-existent parent. * The Route is of a type that the controller does not support. * The Route is in a namespace the the controller does not have access to."
items:
description: "Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example, type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }"
properties:
@@ -1797,39 +1914,64 @@ spec:
- type
type: object
maxItems: 8
+ minItems: 1
type: array
x-kubernetes-list-map-keys:
- type
x-kubernetes-list-type: map
- gatewayRef:
- description: GatewayRef is a reference to a Gateway object that is associated with the route.
+ controllerName:
+ description: "ControllerName is a domain/path string that indicates the name of the controller that wrote this status. This corresponds with the controllerName field on GatewayClass. \n Example: \"example.net/gateway-controller\". \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names)."
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*\/[A-Za-z0-9\/\-._~%!$&'()*+,;=:]+$
+ type: string
+ parentRef:
+ description: ParentRef corresponds with a ParentRef in the spec that this RouteParentStatus struct describes the status of.
properties:
- controller:
- description: "Controller is a domain/path string that indicates the controller implementing the Gateway. This corresponds with the controller field on GatewayClass. \n Example: \"acme.io/gateway-controller\". \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names)."
+ group:
+ default: gateway.networking.k8s.io
+ description: "Group is the group of the referent. \n Support: Core"
maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Gateway
+ description: "Kind is kind of the referent. \n Support: Core (Gateway) Support: Custom (Other Resources)"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
- description: Name is the name of the referent.
+ description: "Name is the name of the referent. \n Support: Core"
maxLength: 253
minLength: 1
type: string
namespace:
- description: Namespace is the namespace of the referent.
+ description: "Namespace is the namespace of the referent. When unspecified (or empty string), this refers to the local namespace of the Route. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ sectionName:
+ description: "SectionName is the name of a section within the target resource. In the following resources, SectionName is interpreted as the following: \n * Gateway: Listener Name \n Implementations MAY choose to support attaching Routes to other resources. If that is the case, they MUST clearly document how SectionName is interpreted. \n When unspecified (empty string), this will reference the entire resource. For the purpose of status, an attachment is considered successful if at least one section in the parent resource accepts it. For example, Gateway listeners can restrict which Routes can attach to them by Route kind, namespace, or hostname. If 1 of 2 Gateway listeners accept attachment from the referencing Route, the Route MUST be considered successfully attached. If no Gateway listeners accept attachment from this Route, the Route MUST be considered detached from the Gateway. \n Support: Core"
maxLength: 253
minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
required:
- name
- - namespace
type: object
required:
- - gatewayRef
+ - controllerName
+ - parentRef
type: object
- maxItems: 100
+ maxItems: 32
type: array
required:
- - gateways
+ - parents
type: object
+ required:
+ - spec
type: object
served: true
storage: true
@@ -1846,11 +1988,11 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
- controller-gen.kubebuilder.io/version: v0.5.0
+ api-approved.kubernetes.io: https://github.com/kubernetes-sigs/gateway-api/pull/891
creationTimestamp: null
- name: udproutes.networking.x-k8s.io
+ name: udproutes.gateway.networking.k8s.io
spec:
- group: networking.x-k8s.io
+ group: gateway.networking.k8s.io
names:
categories:
- gateway-api
@@ -1864,10 +2006,10 @@ spec:
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
- name: v1alpha1
+ name: v1alpha2
schema:
openAPIV3Schema:
- description: UDPRoute is a resource that specifies how a Gateway should forward UDP traffic.
+ description: UDPRoute provides a way to route UDP traffic. When combined with a Gateway listener, it can be used to forward traffic on the port specified by the listener to a set of backends specified by the UDPRoute.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
@@ -1880,127 +2022,99 @@ spec:
spec:
description: Spec defines the desired state of UDPRoute.
properties:
- gateways:
- default:
- allow: SameNamespace
- description: Gateways defines which Gateways can use this Route.
- properties:
- allow:
- default: SameNamespace
- description: 'Allow indicates which Gateways will be allowed to use this route. Possible values are: * All: Gateways in any namespace can use this route. * FromList: Only Gateways specified in GatewayRefs may use this route. * SameNamespace: Only Gateways in the same namespace may use this route.'
- enum:
- - All
- - FromList
- - SameNamespace
- type: string
- gatewayRefs:
- description: GatewayRefs must be specified when Allow is set to "FromList". In that case, only Gateways referenced in this list will be allowed to use this route. This field is ignored for other values of "Allow".
- items:
- description: GatewayReference identifies a Gateway in a specified namespace.
- properties:
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- namespace:
- description: Namespace is the namespace of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - name
- - namespace
- type: object
- type: array
- type: object
+ parentRefs:
+ description: "ParentRefs references the resources (usually Gateways) that a Route wants to be attached to. Note that the referenced parent resource needs to allow this for the attachment to be complete. For Gateways, that means the Gateway needs to allow attachment from Routes of this kind and namespace. \n The only kind of parent resource with \"Core\" support is Gateway. This API may be extended in the future to support additional kinds of parent resources such as one of the route kinds. \n It is invalid to reference an identical parent more than once. It is valid to reference multiple distinct sections within the same parent resource, such as 2 Listeners within a Gateway. \n It is possible to separately reference multiple distinct objects that may be collapsed by an implementation. For example, some implementations may choose to merge compatible Gateway Listeners together. If that is the case, the list of routes attached to those resources should also be merged."
+ items:
+ description: "ParentRef identifies an API object (usually a Gateway) that can be considered a parent of this resource (usually a route). The only kind of parent resource with \"Core\" support is Gateway. This API may be extended in the future to support additional kinds of parent resources, such as HTTPRoute. \n The API object must be valid in the cluster; the Group and Kind must be registered in the cluster for this reference to be valid. \n References to objects with invalid Group and Kind are not valid, and must be rejected by the implementation, with appropriate Conditions set on the containing object."
+ properties:
+ group:
+ default: gateway.networking.k8s.io
+ description: "Group is the group of the referent. \n Support: Core"
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Gateway
+ description: "Kind is kind of the referent. \n Support: Core (Gateway) Support: Custom (Other Resources)"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: "Name is the name of the referent. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the referent. When unspecified (or empty string), this refers to the local namespace of the Route. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ sectionName:
+ description: "SectionName is the name of a section within the target resource. In the following resources, SectionName is interpreted as the following: \n * Gateway: Listener Name \n Implementations MAY choose to support attaching Routes to other resources. If that is the case, they MUST clearly document how SectionName is interpreted. \n When unspecified (empty string), this will reference the entire resource. For the purpose of status, an attachment is considered successful if at least one section in the parent resource accepts it. For example, Gateway listeners can restrict which Routes can attach to them by Route kind, namespace, or hostname. If 1 of 2 Gateway listeners accept attachment from the referencing Route, the Route MUST be considered successfully attached. If no Gateway listeners accept attachment from this Route, the Route MUST be considered detached from the Gateway. \n Support: Core"
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ required:
+ - name
+ type: object
+ maxItems: 32
+ type: array
rules:
description: Rules are a list of UDP matchers and actions.
items:
description: UDPRouteRule is the configuration for a given rule.
properties:
- forwardTo:
- description: ForwardTo defines the backend(s) where matching requests should be sent.
+ backendRefs:
+ description: "BackendRefs defines the backend(s) where matching requests should be sent. If unspecified or invalid (refers to a non-existent resource or a Service with no endpoints), the underlying implementation MUST actively reject connection attempts to this backend. Packet drops must respect weight; if an invalid backend is requested to have 80% of the packets, then 80% of packets must be dropped instead. \n Support: Core for Kubernetes Service Support: Custom for any other resource \n Support for weight: Extended"
items:
- description: RouteForwardTo defines how a Route should forward a request.
+ description: "BackendRef defines how a Route should forward a request to a Kubernetes resource. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details."
properties:
- backendRef:
- description: "BackendRef is a reference to a backend to forward matched requests to. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
+ group:
+ default: ""
+ description: Group is the group of the referent. For example, "networking.k8s.io". When unspecified (empty string), core API group is inferred.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Service
+ description: Kind is kind of the referent. For example "HTTPRoute" or "Service".
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
+ type: string
+ name:
+ description: Name is the name of the referent.
+ maxLength: 253
+ minLength: 1
+ type: string
+ namespace:
+ description: "Namespace is the namespace of the backend. When unspecified, the local namespace is inferred. \n Note that when a namespace is specified, a ReferencePolicy object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferencePolicy documentation for details. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
port:
- description: "Port specifies the destination port number to use for the backend referenced by the ServiceName or BackendRef field. If unspecified, the destination port in the request is used when forwarding to a backendRef or serviceName. \n Support: Core"
+ description: Port specifies the destination port number to use for this resource. Port is required when the referent is a Kubernetes Service. For other resources, destination port might be derived from the referent resource or this field.
format: int32
maximum: 65535
minimum: 1
type: integer
- serviceName:
- description: "ServiceName refers to the name of the Service to forward matched requests to. When specified, this takes the place of BackendRef. If both BackendRef and ServiceName are specified, ServiceName will be given precedence. \n If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n The protocol to use is defined using AppProtocol field (introduced in Kubernetes 1.18) in the Service resource. In the absence of the AppProtocol field a `networking.x-k8s.io/app-protocol` annotation on the BackendPolicy resource may be used to define the protocol. If the AppProtocol field is available, this annotation should not be used. The AppProtocol field, when populated, takes precedence over the annotation in the BackendPolicy resource. For custom backends, it is encouraged to add a semantically-equivalent field in the Custom Resource Definition. \n Support: Core"
- maxLength: 253
- type: string
weight:
default: 1
- description: "Weight specifies the proportion of HTTP requests forwarded to the backend referenced by the ServiceName or BackendRef field. This is computed as weight/(sum of all weights in this ForwardTo list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. Weight is not a percentage and the sum of weights does not need to equal 100. \n If only one backend is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weight is set to 0, no traffic should be forwarded for this entry. If unspecified, weight defaults to 1. \n Support: Extended"
+ description: "Weight specifies the proportion of requests forwarded to the referenced backend. This is computed as weight/(sum of all weights in this BackendRefs list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. Weight is not a percentage and the sum of weights does not need to equal 100. \n If only one backend is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weight is set to 0, no traffic should be forwarded for this entry. If unspecified, weight defaults to 1. \n Support for this field varies based on the context where used."
format: int32
maximum: 1000000
minimum: 0
type: integer
+ required:
+ - name
type: object
maxItems: 16
minItems: 1
type: array
- matches:
- description: "Matches define conditions used for matching the rule against incoming UDP connections. Each match is independent, i.e. this rule will be matched if **any** one of the matches is satisfied. If unspecified (i.e. empty), this Rule will match all requests for the associated Listener. \n Each client request MUST map to a maximum of one route rule. If a request matches multiple rules, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The most specific match specified by ExtensionRef. Each implementation that supports ExtensionRef may have different ways of determining the specificity of the referenced extension. \n If ties still exist across multiple Routes, matching precedence MUST be determined in order of the following criteria, continuing on ties: \n * The oldest Route based on creation timestamp. For example, a Route with a creation timestamp of \"2020-09-08 01:02:03\" is given precedence over a Route with a creation timestamp of \"2020-09-08 01:02:04\". * The Route appearing first in alphabetical order by \"/\". For example, foo/bar is given precedence over foo/baz. \n If ties still exist within the Route that has been given precedence, matching precedence MUST be granted to the first matching rule meeting the above criteria."
- items:
- description: UDPRouteMatch defines the predicate used to match packets to a given action.
- properties:
- extensionRef:
- description: "ExtensionRef is an optional, implementation-specific extension to the \"match\" behavior. For example, resource \"myudproutematcher\" in group \"networking.acme.io\". If the referent cannot be found, the rule is not included in the route. The controller should raise the \"ResolvedRefs\" condition on the Gateway with the \"DegradedRoutes\" reason. The gateway status for this route should be updated with a condition that describes the error more specifically. \n Support: Custom"
- properties:
- group:
- description: Group is the group of the referent.
- maxLength: 253
- minLength: 1
- type: string
- kind:
- description: Kind is kind of the referent.
- maxLength: 253
- minLength: 1
- type: string
- name:
- description: Name is the name of the referent.
- maxLength: 253
- minLength: 1
- type: string
- required:
- - group
- - kind
- - name
- type: object
- type: object
- maxItems: 8
- type: array
- required:
- - forwardTo
type: object
maxItems: 16
minItems: 1
@@ -2011,13 +2125,13 @@ spec:
status:
description: Status defines the current state of UDPRoute.
properties:
- gateways:
- description: "Gateways is a list of Gateways that are associated with the route, and the status of the route with respect to each Gateway. When a Gateway selects this route, the controller that manages the Gateway must add an entry to this list when the controller first sees the route and should update the entry as appropriate when the route is modified. \n A maximum of 100 Gateways will be represented in this list. If this list is full, there may be additional Gateways using this Route that are not included in the list. An empty list means the route has not been admitted by any Gateway."
+ parents:
+ description: "Parents is a list of parent resources (usually Gateways) that are associated with the route, and the status of the route with respect to each parent. When this route attaches to a parent, the controller that manages the parent must add an entry to this list when the controller first sees the route and should update the entry as appropriate when the route or gateway is modified. \n Note that parent references that cannot be resolved by an implementation of this API will not be added to this list. Implementations of this API can only populate Route status for the Gateways/parent resources they are responsible for. \n A maximum of 32 Gateways will be represented in this list. An empty list means the route has not been attached to any Gateway."
items:
- description: RouteGatewayStatus describes the status of a route with respect to an associated Gateway.
+ description: RouteParentStatus describes the status of a route with respect to an associated Parent.
properties:
conditions:
- description: Conditions describes the status of the route with respect to the Gateway. The "Admitted" condition must always be specified by controllers to indicate whether the route has been admitted or rejected by the Gateway, and why. Note that the route's availability is also subject to the Gateway's own status conditions and listener status.
+ description: "Conditions describes the status of the route with respect to the Gateway. Note that the route's availability is also subject to the Gateway's own status conditions and listener status. \n If the Route's ParentRef specifies an existing Gateway that supports Routes of this kind AND that Gateway's controller has sufficient access, then that Gateway's controller MUST set the \"Accepted\" condition on the Route, to indicate whether the route has been accepted or rejected by the Gateway, and why. \n A Route MUST be considered \"Accepted\" if at least one of the Route's rules is implemented by the Gateway. \n There are a number of cases where the \"Accepted\" condition may not be set due to lack of controller visibility, that includes when: \n * The Route refers to a non-existent parent. * The Route is of a type that the controller does not support. * The Route is in a namespace the the controller does not have access to."
items:
description: "Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example, type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }"
properties:
@@ -2060,39 +2174,64 @@ spec:
- type
type: object
maxItems: 8
+ minItems: 1
type: array
x-kubernetes-list-map-keys:
- type
x-kubernetes-list-type: map
- gatewayRef:
- description: GatewayRef is a reference to a Gateway object that is associated with the route.
+ controllerName:
+ description: "ControllerName is a domain/path string that indicates the name of the controller that wrote this status. This corresponds with the controllerName field on GatewayClass. \n Example: \"example.net/gateway-controller\". \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names)."
+ maxLength: 253
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*\/[A-Za-z0-9\/\-._~%!$&'()*+,;=:]+$
+ type: string
+ parentRef:
+ description: ParentRef corresponds with a ParentRef in the spec that this RouteParentStatus struct describes the status of.
properties:
- controller:
- description: "Controller is a domain/path string that indicates the controller implementing the Gateway. This corresponds with the controller field on GatewayClass. \n Example: \"acme.io/gateway-controller\". \n The format of this field is DOMAIN \"/\" PATH, where DOMAIN and PATH are valid Kubernetes names (https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names)."
+ group:
+ default: gateway.networking.k8s.io
+ description: "Group is the group of the referent. \n Support: Core"
maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
+ type: string
+ kind:
+ default: Gateway
+ description: "Kind is kind of the referent. \n Support: Core (Gateway) Support: Custom (Other Resources)"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
- description: Name is the name of the referent.
+ description: "Name is the name of the referent. \n Support: Core"
maxLength: 253
minLength: 1
type: string
namespace:
- description: Namespace is the namespace of the referent.
+ description: "Namespace is the namespace of the referent. When unspecified (or empty string), this refers to the local namespace of the Route. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
+ type: string
+ sectionName:
+ description: "SectionName is the name of a section within the target resource. In the following resources, SectionName is interpreted as the following: \n * Gateway: Listener Name \n Implementations MAY choose to support attaching Routes to other resources. If that is the case, they MUST clearly document how SectionName is interpreted. \n When unspecified (empty string), this will reference the entire resource. For the purpose of status, an attachment is considered successful if at least one section in the parent resource accepts it. For example, Gateway listeners can restrict which Routes can attach to them by Route kind, namespace, or hostname. If 1 of 2 Gateway listeners accept attachment from the referencing Route, the Route MUST be considered successfully attached. If no Gateway listeners accept attachment from this Route, the Route MUST be considered detached from the Gateway. \n Support: Core"
maxLength: 253
minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
required:
- name
- - namespace
type: object
required:
- - gatewayRef
+ - controllerName
+ - parentRef
type: object
- maxItems: 100
+ maxItems: 32
type: array
required:
- - gateways
+ - parents
type: object
+ required:
+ - spec
type: object
served: true
storage: true
@@ -2125,7 +2264,7 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-admin
labels:
- serving.knative.dev/release: "v20220125-1a7d3eb6"
+ serving.knative.dev/release: "v20220204-285bccce"
aggregationRule:
clusterRoleSelectors:
- matchLabels:
@@ -2137,10 +2276,10 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: knative-gateway-api-core
labels:
- serving.knative.dev/release: "v20220125-1a7d3eb6"
+ serving.knative.dev/release: "v20220204-285bccce"
serving.knative.dev/controller: "true"
rules:
- - apiGroups: ["networking.x-k8s.io"]
+ - apiGroups: ["gateway.networking.k8s.io"]
resources: ["httproutes", "gateways"]
verbs: ["get", "list", "create", "update", "delete", "patch", "watch"]
@@ -2165,7 +2304,7 @@ metadata:
name: config-gateway
namespace: knative-serving
labels:
- serving.knative.dev/release: "v20220125-1a7d3eb6"
+ serving.knative.dev/release: "v20220204-285bccce"
data:
_example: |
################################
@@ -2219,9 +2358,9 @@ metadata:
labels:
networking.knative.dev/ingress-provider: net-gateway-api
app.kubernetes.io/component: net-gateway-api
- app.kubernetes.io/version: "20220125-1a7d3eb6"
+ app.kubernetes.io/version: "20220204-285bccce"
app.kubernetes.io/name: knative-serving
- serving.knative.dev/release: "v20220125-1a7d3eb6"
+ serving.knative.dev/release: "v20220204-285bccce"
spec:
replicas: 1
selector:
@@ -2247,7 +2386,7 @@ spec:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:11fe78f11c506273390046f284564c541f18c562745a190abba218971d3542ca
+ image: gcr.io/knative-nightly/knative.dev/net-gateway-api/cmd/controller@sha256:f6a13d853686aabab5fc82713f06d03b94ca5f5f0047565ffc809ec63f0a60f7
resources:
requests:
cpu: 100m
From 0b4ef84741509d6d8b67454a09fd15849ba48b93 Mon Sep 17 00:00:00 2001
From: Nader Ziada
Date: Mon, 7 Feb 2022 16:43:15 -0500
Subject: [PATCH 142/733] update the performance test section in test readme
(#12600)
---
test/README.md | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/test/README.md b/test/README.md
index 7c11be231993..0086aeb1571f 100644
--- a/test/README.md
+++ b/test/README.md
@@ -100,13 +100,10 @@ go test -tags=e2e -count=1 ./test/conformance/... \
## Running performance tests
-Each performance test case in Knative serving is a benchmark, to run these
-benchmarks, please follow
-[dev.md](https://github.com/knative/serving/blob/main/test/performance/dev.md).
+Performance tests using [kperf](https://github.com/knative-sandbox/kperf) can be run in
+a pull request using the optional test job `/test pull-knative-serving-performance-tests-kperf`
-> As of now, only Googlers can run these benchmarks due to one issue of
-> [Mako](https://github.com/google/mako) - the benchmarking tool we use. Details
-> can be found in the [issue report](https://github.com/google/mako/issues/2).
+A report will be generated in the artifacts folder of the test run.
### Running a single test case
From 52f07b02254b42f18fa0f71dbb0462410a5bc7b1 Mon Sep 17 00:00:00 2001
From: knative-automation
Date: Tue, 8 Feb 2022 10:45:17 -0800
Subject: [PATCH 143/733] Update net-istio nightly (#12602)
bumping knative.dev/net-istio 34b6c47...73a9798:
> 73a9798 Bump Istio to 1.12.2 (# 865)
Signed-off-by: Knative Automation
---
third_party/istio-latest/net-istio.yaml | 70 ++++++++++++-------------
1 file changed, 35 insertions(+), 35 deletions(-)
diff --git a/third_party/istio-latest/net-istio.yaml b/third_party/istio-latest/net-istio.yaml
index 27f800982d02..8aae1390dee5 100644
--- a/third_party/istio-latest/net-istio.yaml
+++ b/third_party/istio-latest/net-istio.yaml
@@ -1,4 +1,4 @@
-# Generated when HEAD was 34b6c47e6d0bb7a0e5e44772297502b82e52bdc4
+# Generated when HEAD was 73a9798454000a88754e8547bad184934391b1ff
#
# Copyright 2019 The Knative Authors
#
@@ -22,8 +22,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
serving.knative.dev/controller: "true"
networking.knative.dev/ingress-provider: istio
rules:
@@ -55,8 +55,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -95,8 +95,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -117,8 +117,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
experimental.istio.io/disable-gateway-port-translation: "true"
spec:
@@ -153,8 +153,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
data:
_example: |
@@ -220,8 +220,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -239,8 +239,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -258,8 +258,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -292,8 +292,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -311,15 +311,15 @@ spec:
app: net-istio-controller
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
spec:
serviceAccountName: controller
containers:
- name: controller
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:0e92ef025934e4a7f9e898c640091f81e6cc635b5cd945c61beb62742a19ea0c
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/controller@sha256:7edc8b02100e5f11d5d6582c2acd2a5f49c987127f0d4d3de5abecde5ffa0a43
resources:
requests:
cpu: 30m
@@ -378,8 +378,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
spec:
selector:
@@ -395,15 +395,15 @@ spec:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
spec:
serviceAccountName: controller
containers:
- name: webhook
# This is the Go import path for the binary that is containerized
# and substituted here.
- image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:bb2996191b93d97af33c7a4e01a458545bb106240e51fa7035a8873c8dbf4ba3
+ image: gcr.io/knative-nightly/knative.dev/net-istio/cmd/webhook@sha256:7ca140f79a2d43b9d408c3f2e802891aa28cee11775d2166b333f90612dbd57d
resources:
requests:
cpu: 20m
@@ -458,8 +458,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
---
@@ -486,8 +486,8 @@ metadata:
role: net-istio-webhook
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
spec:
ports:
@@ -526,8 +526,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
@@ -566,8 +566,8 @@ metadata:
labels:
app.kubernetes.io/component: net-istio
app.kubernetes.io/name: knative-serving
- app.kubernetes.io/version: "20220204-34b6c47e"
- serving.knative.dev/release: "v20220204-34b6c47e"
+ app.kubernetes.io/version: "20220208-73a97984"
+ serving.knative.dev/release: "v20220208-73a97984"
networking.knative.dev/ingress-provider: istio
webhooks:
- admissionReviewVersions:
From 6c0fdecf33b1c5b953baae832e52d3a34be40e6d Mon Sep 17 00:00:00 2001
From: Kenjiro Nakayama
Date: Wed, 9 Feb 2022 23:54:41 +0900
Subject: [PATCH 144/733] Bump cert-manager to 1.7.1 (#12605)
* Bump cert-manager to 1.7.1
* Fix owner-ref patch
* Drop owner-ref patch
---
.../cert-manager-latest/cert-manager.yaml | 30880 +++-------------
.../download-cert-manager.sh | 6 +-
.../cert-manager-latest/owner-ref.patch | 10 -
3 files changed, 4627 insertions(+), 26269 deletions(-)
delete mode 100644 third_party/cert-manager-latest/owner-ref.patch
diff --git a/third_party/cert-manager-latest/cert-manager.yaml b/third_party/cert-manager-latest/cert-manager.yaml
index 40cbe0866c39..a5c4ba13fe9b 100644
--- a/third_party/cert-manager-latest/cert-manager.yaml
+++ b/third_party/cert-manager-latest/cert-manager.yaml
@@ -1,4 +1,4 @@
-# Copyright The cert-manager Authors.
+# Copyright 2022 The cert-manager Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -12,26452 +12,4785 @@
# See the License for the specific language governing permissions and
# limitations under the License.
+---
+# Source: cert-manager/templates/templates.out
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
+ name: certificaterequests.cert-manager.io
annotations:
- cert-manager.io/inject-ca-from-secret: cert-manager/cert-manager-webhook-ca
+ cert-manager.io/inject-ca-from-secret: 'cert-manager/cert-manager-webhook-ca'
labels:
- app: cert-manager
- app.kubernetes.io/instance: cert-manager
- app.kubernetes.io/name: cert-manager
- name: certificaterequests.cert-manager.io
+ app: 'cert-manager'
+ app.kubernetes.io/name: 'cert-manager'
+ app.kubernetes.io/instance: 'cert-manager'
+ # Generated labels
+ app.kubernetes.io/version: "v1.7.1"
spec:
- conversion:
- strategy: Webhook
- webhook:
- clientConfig:
- service:
- name: cert-manager-webhook
- namespace: cert-manager
- path: /convert
- conversionReviewVersions:
- - v1
- - v1beta1
group: cert-manager.io
names:
- categories:
- - cert-manager
kind: CertificateRequest
listKind: CertificateRequestList
plural: certificaterequests
shortNames:
- - cr
- - crs
+ - cr
+ - crs
singular: certificaterequest
+ categories:
+ - cert-manager
scope: Namespaced
versions:
- - additionalPrinterColumns:
- - jsonPath: .status.conditions[?(@.type=="Approved")].status
- name: Approved
- type: string
- - jsonPath: .status.conditions[?(@.type=="Denied")].status
- name: Denied
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].status
- name: Ready
- type: string
- - jsonPath: .spec.issuerRef.name
- name: Issuer
- type: string
- - jsonPath: .spec.username
- name: Requestor
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].message
- name: Status
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1alpha2
- schema:
- openAPIV3Schema:
- description: "A CertificateRequest is used to request a signed certificate
- from one of the configured issuers. \n All fields within the CertificateRequest's
- `spec` are immutable after creation. A CertificateRequest will either succeed
- or fail, as denoted by its `status.state` field. \n A CertificateRequest
- is a one-shot resource, meaning it represents a single point in time request
- for a certificate and cannot be re-used."
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Desired state of the CertificateRequest resource.
- properties:
- csr:
- description: The PEM-encoded x509 certificate signing request to be
- submitted to the CA for signing.
- format: byte
- type: string
- duration:
- description: The requested 'duration' (i.e. lifetime) of the Certificate.
- This option may be ignored/overridden by some issuer types.
- type: string
- extra:
- additionalProperties:
- items:
- type: string
- type: array
- description: Extra contains extra attributes of the user that created
- the CertificateRequest. Populated by the cert-manager webhook on
- creation and immutable.
- type: object
- groups:
- description: Groups contains group membership of the user that created
- the CertificateRequest. Populated by the cert-manager webhook on
- creation and immutable.
- items:
- type: string
- type: array
- x-kubernetes-list-type: atomic
- isCA:
- description: IsCA will request to mark the certificate as valid for
- certificate signing when submitting to the issuer. This will automatically
- add the `cert sign` usage to the list of `usages`.
- type: boolean
- issuerRef:
- description: IssuerRef is a reference to the issuer for this CertificateRequest. If
- the `kind` field is not set, or set to `Issuer`, an Issuer resource
- with the given name in the same namespace as the CertificateRequest
- will be used. If the `kind` field is set to `ClusterIssuer`, a
- ClusterIssuer with the provided name will be used. The `name` field
- in this stanza is required at all times. The group field refers
- to the API group of the issuer which defaults to `cert-manager.io`
- if empty.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
- type: string
- name:
- description: Name of the resource being referred to.
- type: string
- required:
- - name
- type: object
- uid:
- description: UID contains the uid of the user that created the CertificateRequest.
- Populated by the cert-manager webhook on creation and immutable.
- type: string
- usages:
- description: Usages is the set of x509 usages that are requested for
- the certificate. Defaults to `digital signature` and `key encipherment`
- if not specified.
- items:
- description: 'KeyUsage specifies valid usage contexts for keys.
- See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12
- Valid KeyUsage values are as follows: "signing", "digital signature",
- "content commitment", "key encipherment", "key agreement", "data
- encipherment", "cert sign", "crl sign", "encipher only", "decipher
- only", "any", "server auth", "client auth", "code signing", "email
- protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec
- user", "timestamping", "ocsp signing", "microsoft sgc", "netscape
- sgc"'
- enum:
- - signing
- - digital signature
- - content commitment
- - key encipherment
- - key agreement
- - data encipherment
- - cert sign
- - crl sign
- - encipher only
- - decipher only
- - any
- - server auth
- - client auth
- - code signing
- - email protection
- - s/mime
- - ipsec end system
- - ipsec tunnel
- - ipsec user
- - timestamping
- - ocsp signing
- - microsoft sgc
- - netscape sgc
+ - name: v1
+ subresources:
+ status: {}
+ additionalPrinterColumns:
+ - jsonPath: .status.conditions[?(@.type=="Approved")].status
+ name: Approved
+ type: string
+ - jsonPath: .status.conditions[?(@.type=="Denied")].status
+ name: Denied
+ type: string
+ - jsonPath: .status.conditions[?(@.type=="Ready")].status
+ name: Ready
+ type: string
+ - jsonPath: .spec.issuerRef.name
+ name: Issuer
+ type: string
+ - jsonPath: .spec.username
+ name: Requestor
+ type: string
+ - jsonPath: .status.conditions[?(@.type=="Ready")].message
+ name: Status
+ priority: 1
+ type: string
+ - jsonPath: .metadata.creationTimestamp
+ description: CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.
+ name: Age
+ type: date
+ schema:
+ openAPIV3Schema:
+ description: "A CertificateRequest is used to request a signed certificate from one of the configured issuers. \n All fields within the CertificateRequest's `spec` are immutable after creation. A CertificateRequest will either succeed or fail, as denoted by its `status.state` field. \n A CertificateRequest is a one-shot resource, meaning it represents a single point in time request for a certificate and cannot be re-used."
+ type: object
+ required:
+ - spec
+ properties:
+ apiVersion:
+ description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
+ type: string
+ kind:
+ description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
+ type: string
+ metadata:
+ type: object
+ spec:
+ description: Desired state of the CertificateRequest resource.
+ type: object
+ required:
+ - issuerRef
+ - request
+ properties:
+ duration:
+ description: The requested 'duration' (i.e. lifetime) of the Certificate. This option may be ignored/overridden by some issuer types.
type: string
- type: array
- username:
- description: Username contains the name of the user that created the
- CertificateRequest. Populated by the cert-manager webhook on creation
- and immutable.
- type: string
- required:
- - csr
- - issuerRef
- type: object
- status:
- description: Status of the CertificateRequest. This is set and managed
- automatically.
- properties:
- ca:
- description: The PEM encoded x509 certificate of the signer, also
- known as the CA (Certificate Authority). This is set on a best-effort
- basis by different issuers. If not set, the CA is assumed to be
- unknown/not available.
- format: byte
- type: string
- certificate:
- description: The PEM encoded x509 certificate resulting from the certificate
- signing request. If not set, the CertificateRequest has either not
- been completed or has failed. More information on failure can be
- found by checking the `conditions` field.
- format: byte
- type: string
- conditions:
- description: List of status conditions to indicate the status of a
- CertificateRequest. Known condition types are `Ready` and `InvalidRequest`.
- items:
- description: CertificateRequestCondition contains condition information
- for a CertificateRequest.
- properties:
- lastTransitionTime:
- description: LastTransitionTime is the timestamp corresponding
- to the last status change of this condition.
- format: date-time
- type: string
- message:
- description: Message is a human readable description of the
- details of the last transition, complementing reason.
- type: string
- reason:
- description: Reason is a brief machine readable explanation
- for the condition's last transition.
- type: string
- status:
- description: Status of the condition, one of (`True`, `False`,
- `Unknown`).
- enum:
- - "True"
- - "False"
- - Unknown
- type: string
- type:
- description: Type of the condition, known values are (`Ready`,
- `InvalidRequest`, `Approved`, `Denied`).
- type: string
- required:
- - status
- - type
+ extra:
+ description: Extra contains extra attributes of the user that created the CertificateRequest. Populated by the cert-manager webhook on creation and immutable.
type: object
- type: array
- failureTime:
- description: FailureTime stores the time that this CertificateRequest
- failed. This is used to influence garbage collection and back-off.
- format: date-time
- type: string
- type: object
- type: object
- served: true
- storage: false
- subresources:
- status: {}
- - additionalPrinterColumns:
- - jsonPath: .status.conditions[?(@.type=="Approved")].status
- name: Approved
- type: string
- - jsonPath: .status.conditions[?(@.type=="Denied")].status
- name: Denied
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].status
- name: Ready
- type: string
- - jsonPath: .spec.issuerRef.name
- name: Issuer
- type: string
- - jsonPath: .spec.username
- name: Requestor
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].message
- name: Status
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1alpha3
- schema:
- openAPIV3Schema:
- description: "A CertificateRequest is used to request a signed certificate
- from one of the configured issuers. \n All fields within the CertificateRequest's
- `spec` are immutable after creation. A CertificateRequest will either succeed
- or fail, as denoted by its `status.state` field. \n A CertificateRequest
- is a one-shot resource, meaning it represents a single point in time request
- for a certificate and cannot be re-used."
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Desired state of the CertificateRequest resource.
- properties:
- csr:
- description: The PEM-encoded x509 certificate signing request to be
- submitted to the CA for signing.
- format: byte
- type: string
- duration:
- description: The requested 'duration' (i.e. lifetime) of the Certificate.
- This option may be ignored/overridden by some issuer types.
- type: string
- extra:
- additionalProperties:
- items:
- type: string
+ additionalProperties:
+ type: array
+ items:
+ type: string
+ groups:
+ description: Groups contains group membership of the user that created the CertificateRequest. Populated by the cert-manager webhook on creation and immutable.
type: array
- description: Extra contains extra attributes of the user that created
- the CertificateRequest. Populated by the cert-manager webhook on
- creation and immutable.
- type: object
- groups:
- description: Groups contains group membership of the user that created
- the CertificateRequest. Populated by the cert-manager webhook on
- creation and immutable.
- items:
- type: string
- type: array
- x-kubernetes-list-type: atomic
- isCA:
- description: IsCA will request to mark the certificate as valid for
- certificate signing when submitting to the issuer. This will automatically
- add the `cert sign` usage to the list of `usages`.
- type: boolean
- issuerRef:
- description: IssuerRef is a reference to the issuer for this CertificateRequest. If
- the `kind` field is not set, or set to `Issuer`, an Issuer resource
- with the given name in the same namespace as the CertificateRequest
- will be used. If the `kind` field is set to `ClusterIssuer`, a
- ClusterIssuer with the provided name will be used. The `name` field
- in this stanza is required at all times. The group field refers
- to the API group of the issuer which defaults to `cert-manager.io`
- if empty.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
- type: string
- name:
- description: Name of the resource being referred to.
+ items:
type: string
- required:
- - name
- type: object
- uid:
- description: UID contains the uid of the user that created the CertificateRequest.
- Populated by the cert-manager webhook on creation and immutable.
- type: string
- usages:
- description: Usages is the set of x509 usages that are requested for
- the certificate. Defaults to `digital signature` and `key encipherment`
- if not specified.
- items:
- description: 'KeyUsage specifies valid usage contexts for keys.
- See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12
- Valid KeyUsage values are as follows: "signing", "digital signature",
- "content commitment", "key encipherment", "key agreement", "data
- encipherment", "cert sign", "crl sign", "encipher only", "decipher
- only", "any", "server auth", "client auth", "code signing", "email
- protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec
- user", "timestamping", "ocsp signing", "microsoft sgc", "netscape
- sgc"'
- enum:
- - signing
- - digital signature
- - content commitment
- - key encipherment
- - key agreement
- - data encipherment
- - cert sign
- - crl sign
- - encipher only
- - decipher only
- - any
- - server auth
- - client auth
- - code signing
- - email protection
- - s/mime
- - ipsec end system
- - ipsec tunnel
- - ipsec user
- - timestamping
- - ocsp signing
- - microsoft sgc
- - netscape sgc
- type: string
- type: array
- username:
- description: Username contains the name of the user that created the
- CertificateRequest. Populated by the cert-manager webhook on creation
- and immutable.
- type: string
- required:
- - csr
- - issuerRef
- type: object
- status:
- description: Status of the CertificateRequest. This is set and managed
- automatically.
- properties:
- ca:
- description: The PEM encoded x509 certificate of the signer, also
- known as the CA (Certificate Authority). This is set on a best-effort
- basis by different issuers. If not set, the CA is assumed to be
- unknown/not available.
- format: byte
- type: string
- certificate:
- description: The PEM encoded x509 certificate resulting from the certificate
- signing request. If not set, the CertificateRequest has either not
- been completed or has failed. More information on failure can be
- found by checking the `conditions` field.
- format: byte
- type: string
- conditions:
- description: List of status conditions to indicate the status of a
- CertificateRequest. Known condition types are `Ready` and `InvalidRequest`.
- items:
- description: CertificateRequestCondition contains condition information
- for a CertificateRequest.
+ x-kubernetes-list-type: atomic
+ isCA:
+ description: IsCA will request to mark the certificate as valid for certificate signing when submitting to the issuer. This will automatically add the `cert sign` usage to the list of `usages`.
+ type: boolean
+ issuerRef:
+ description: IssuerRef is a reference to the issuer for this CertificateRequest. If the `kind` field is not set, or set to `Issuer`, an Issuer resource with the given name in the same namespace as the CertificateRequest will be used. If the `kind` field is set to `ClusterIssuer`, a ClusterIssuer with the provided name will be used. The `name` field in this stanza is required at all times. The group field refers to the API group of the issuer which defaults to `cert-manager.io` if empty.
+ type: object
+ required:
+ - name
properties:
- lastTransitionTime:
- description: LastTransitionTime is the timestamp corresponding
- to the last status change of this condition.
- format: date-time
- type: string
- message:
- description: Message is a human readable description of the
- details of the last transition, complementing reason.
+ group:
+ description: Group of the resource being referred to.
type: string
- reason:
- description: Reason is a brief machine readable explanation
- for the condition's last transition.
+ kind:
+ description: Kind of the resource being referred to.
type: string
- status:
- description: Status of the condition, one of (`True`, `False`,
- `Unknown`).
- enum:
- - "True"
- - "False"
- - Unknown
- type: string
- type:
- description: Type of the condition, known values are (`Ready`,
- `InvalidRequest`, `Approved`, `Denied`).
+ name:
+ description: Name of the resource being referred to.
type: string
- required:
- - status
- - type
- type: object
- type: array
- failureTime:
- description: FailureTime stores the time that this CertificateRequest
- failed. This is used to influence garbage collection and back-off.
- format: date-time
- type: string
- type: object
- type: object
- served: true
- storage: false
- subresources:
- status: {}
- - additionalPrinterColumns:
- - jsonPath: .status.conditions[?(@.type=="Approved")].status
- name: Approved
- type: string
- - jsonPath: .status.conditions[?(@.type=="Denied")].status
- name: Denied
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].status
- name: Ready
- type: string
- - jsonPath: .spec.issuerRef.name
- name: Issuer
- type: string
- - jsonPath: .spec.username
- name: Requestor
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].message
- name: Status
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1beta1
- schema:
- openAPIV3Schema:
- description: "A CertificateRequest is used to request a signed certificate
- from one of the configured issuers. \n All fields within the CertificateRequest's
- `spec` are immutable after creation. A CertificateRequest will either succeed
- or fail, as denoted by its `status.state` field. \n A CertificateRequest
- is a one-shot resource, meaning it represents a single point in time request
- for a certificate and cannot be re-used."
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Desired state of the CertificateRequest resource.
- properties:
- duration:
- description: The requested 'duration' (i.e. lifetime) of the Certificate.
- This option may be ignored/overridden by some issuer types.
- type: string
- extra:
- additionalProperties:
- items:
- type: string
- type: array
- description: Extra contains extra attributes of the user that created
- the CertificateRequest. Populated by the cert-manager webhook on
- creation and immutable.
- type: object
- groups:
- description: Groups contains group membership of the user that created
- the CertificateRequest. Populated by the cert-manager webhook on
- creation and immutable.
- items:
+ request:
+ description: The PEM-encoded x509 certificate signing request to be submitted to the CA for signing.
type: string
- type: array
- x-kubernetes-list-type: atomic
- isCA:
- description: IsCA will request to mark the certificate as valid for
- certificate signing when submitting to the issuer. This will automatically
- add the `cert sign` usage to the list of `usages`.
- type: boolean
- issuerRef:
- description: IssuerRef is a reference to the issuer for this CertificateRequest. If
- the `kind` field is not set, or set to `Issuer`, an Issuer resource
- with the given name in the same namespace as the CertificateRequest
- will be used. If the `kind` field is set to `ClusterIssuer`, a
- ClusterIssuer with the provided name will be used. The `name` field
- in this stanza is required at all times. The group field refers
- to the API group of the issuer which defaults to `cert-manager.io`
- if empty.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
- type: string
- name:
- description: Name of the resource being referred to.
- type: string
- required:
- - name
- type: object
- request:
- description: The PEM-encoded x509 certificate signing request to be
- submitted to the CA for signing.
- format: byte
- type: string
- uid:
- description: UID contains the uid of the user that created the CertificateRequest.
- Populated by the cert-manager webhook on creation and immutable.
- type: string
- usages:
- description: Usages is the set of x509 usages that are requested for
- the certificate. Defaults to `digital signature` and `key encipherment`
- if not specified.
- items:
- description: 'KeyUsage specifies valid usage contexts for keys.
- See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12
- Valid KeyUsage values are as follows: "signing", "digital signature",
- "content commitment", "key encipherment", "key agreement", "data
- encipherment", "cert sign", "crl sign", "encipher only", "decipher
- only", "any", "server auth", "client auth", "code signing", "email
- protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec
- user", "timestamping", "ocsp signing", "microsoft sgc", "netscape
- sgc"'
- enum:
- - signing
- - digital signature
- - content commitment
- - key encipherment
- - key agreement
- - data encipherment
- - cert sign
- - crl sign
- - encipher only
- - decipher only
- - any
- - server auth
- - client auth
- - code signing
- - email protection
- - s/mime
- - ipsec end system
- - ipsec tunnel
- - ipsec user
- - timestamping
- - ocsp signing
- - microsoft sgc
- - netscape sgc
+ format: byte
+ uid:
+ description: UID contains the uid of the user that created the CertificateRequest. Populated by the cert-manager webhook on creation and immutable.
type: string
- type: array
- username:
- description: Username contains the name of the user that created the
- CertificateRequest. Populated by the cert-manager webhook on creation
- and immutable.
- type: string
- required:
- - issuerRef
- - request
- type: object
- status:
- description: Status of the CertificateRequest. This is set and managed
- automatically.
- properties:
- ca:
- description: The PEM encoded x509 certificate of the signer, also
- known as the CA (Certificate Authority). This is set on a best-effort
- basis by different issuers. If not set, the CA is assumed to be
- unknown/not available.
- format: byte
- type: string
- certificate:
- description: The PEM encoded x509 certificate resulting from the certificate
- signing request. If not set, the CertificateRequest has either not
- been completed or has failed. More information on failure can be
- found by checking the `conditions` field.
- format: byte
- type: string
- conditions:
- description: List of status conditions to indicate the status of a
- CertificateRequest. Known condition types are `Ready` and `InvalidRequest`.
- items:
- description: CertificateRequestCondition contains condition information
- for a CertificateRequest.
- properties:
- lastTransitionTime:
- description: LastTransitionTime is the timestamp corresponding
- to the last status change of this condition.
- format: date-time
- type: string
- message:
- description: Message is a human readable description of the
- details of the last transition, complementing reason.
- type: string
- reason:
- description: Reason is a brief machine readable explanation
- for the condition's last transition.
- type: string
- status:
- description: Status of the condition, one of (`True`, `False`,
- `Unknown`).
- enum:
- - "True"
- - "False"
- - Unknown
- type: string
- type:
- description: Type of the condition, known values are (`Ready`,
- `InvalidRequest`, `Approved`, `Denied`).
- type: string
- required:
- - status
- - type
- type: object
- type: array
- failureTime:
- description: FailureTime stores the time that this CertificateRequest
- failed. This is used to influence garbage collection and back-off.
- format: date-time
- type: string
- type: object
- required:
- - spec
- type: object
- served: true
- storage: false
- subresources:
- status: {}
- - additionalPrinterColumns:
- - jsonPath: .status.conditions[?(@.type=="Approved")].status
- name: Approved
- type: string
- - jsonPath: .status.conditions[?(@.type=="Denied")].status
- name: Denied
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].status
- name: Ready
- type: string
- - jsonPath: .spec.issuerRef.name
- name: Issuer
- type: string
- - jsonPath: .spec.username
- name: Requestor
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].message
- name: Status
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1
- schema:
- openAPIV3Schema:
- description: "A CertificateRequest is used to request a signed certificate
- from one of the configured issuers. \n All fields within the CertificateRequest's
- `spec` are immutable after creation. A CertificateRequest will either succeed
- or fail, as denoted by its `status.state` field. \n A CertificateRequest
- is a one-shot resource, meaning it represents a single point in time request
- for a certificate and cannot be re-used."
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Desired state of the CertificateRequest resource.
- properties:
- duration:
- description: The requested 'duration' (i.e. lifetime) of the Certificate.
- This option may be ignored/overridden by some issuer types.
- type: string
- extra:
- additionalProperties:
+ usages:
+ description: Usages is the set of x509 usages that are requested for the certificate. If usages are set they SHOULD be encoded inside the CSR spec Defaults to `digital signature` and `key encipherment` if not specified.
+ type: array
items:
+ description: 'KeyUsage specifies valid usage contexts for keys. See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12 Valid KeyUsage values are as follows: "signing", "digital signature", "content commitment", "key encipherment", "key agreement", "data encipherment", "cert sign", "crl sign", "encipher only", "decipher only", "any", "server auth", "client auth", "code signing", "email protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec user", "timestamping", "ocsp signing", "microsoft sgc", "netscape sgc"'
type: string
- type: array
- description: Extra contains extra attributes of the user that created
- the CertificateRequest. Populated by the cert-manager webhook on
- creation and immutable.
- type: object
- groups:
- description: Groups contains group membership of the user that created
- the CertificateRequest. Populated by the cert-manager webhook on
- creation and immutable.
- items:
+ enum:
+ - signing
+ - digital signature
+ - content commitment
+ - key encipherment
+ - key agreement
+ - data encipherment
+ - cert sign
+ - crl sign
+ - encipher only
+ - decipher only
+ - any
+ - server auth
+ - client auth
+ - code signing
+ - email protection
+ - s/mime
+ - ipsec end system
+ - ipsec tunnel
+ - ipsec user
+ - timestamping
+ - ocsp signing
+ - microsoft sgc
+ - netscape sgc
+ username:
+ description: Username contains the name of the user that created the CertificateRequest. Populated by the cert-manager webhook on creation and immutable.
type: string
- type: array
- x-kubernetes-list-type: atomic
- isCA:
- description: IsCA will request to mark the certificate as valid for
- certificate signing when submitting to the issuer. This will automatically
- add the `cert sign` usage to the list of `usages`.
- type: boolean
- issuerRef:
- description: IssuerRef is a reference to the issuer for this CertificateRequest. If
- the `kind` field is not set, or set to `Issuer`, an Issuer resource
- with the given name in the same namespace as the CertificateRequest
- will be used. If the `kind` field is set to `ClusterIssuer`, a
- ClusterIssuer with the provided name will be used. The `name` field
- in this stanza is required at all times. The group field refers
- to the API group of the issuer which defaults to `cert-manager.io`
- if empty.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
- type: string
- name:
- description: Name of the resource being referred to.
- type: string
- required:
- - name
- type: object
- request:
- description: The PEM-encoded x509 certificate signing request to be
- submitted to the CA for signing.
- format: byte
- type: string
- uid:
- description: UID contains the uid of the user that created the CertificateRequest.
- Populated by the cert-manager webhook on creation and immutable.
- type: string
- usages:
- description: Usages is the set of x509 usages that are requested for
- the certificate. If usages are set they SHOULD be encoded inside
- the CSR spec Defaults to `digital signature` and `key encipherment`
- if not specified.
- items:
- description: 'KeyUsage specifies valid usage contexts for keys.
- See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12
- Valid KeyUsage values are as follows: "signing", "digital signature",
- "content commitment", "key encipherment", "key agreement", "data
- encipherment", "cert sign", "crl sign", "encipher only", "decipher
- only", "any", "server auth", "client auth", "code signing", "email
- protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec
- user", "timestamping", "ocsp signing", "microsoft sgc", "netscape
- sgc"'
- enum:
- - signing
- - digital signature
- - content commitment
- - key encipherment
- - key agreement
- - data encipherment
- - cert sign
- - crl sign
- - encipher only
- - decipher only
- - any
- - server auth
- - client auth
- - code signing
- - email protection
- - s/mime
- - ipsec end system
- - ipsec tunnel
- - ipsec user
- - timestamping
- - ocsp signing
- - microsoft sgc
- - netscape sgc
+ status:
+ description: Status of the CertificateRequest. This is set and managed automatically.
+ type: object
+ properties:
+ ca:
+ description: The PEM encoded x509 certificate of the signer, also known as the CA (Certificate Authority). This is set on a best-effort basis by different issuers. If not set, the CA is assumed to be unknown/not available.
type: string
- type: array
- username:
- description: Username contains the name of the user that created the
- CertificateRequest. Populated by the cert-manager webhook on creation
- and immutable.
- type: string
- required:
- - issuerRef
- - request
- type: object
- status:
- description: Status of the CertificateRequest. This is set and managed
- automatically.
- properties:
- ca:
- description: The PEM encoded x509 certificate of the signer, also
- known as the CA (Certificate Authority). This is set on a best-effort
- basis by different issuers. If not set, the CA is assumed to be
- unknown/not available.
- format: byte
- type: string
- certificate:
- description: The PEM encoded x509 certificate resulting from the certificate
- signing request. If not set, the CertificateRequest has either not
- been completed or has failed. More information on failure can be
- found by checking the `conditions` field.
- format: byte
- type: string
- conditions:
- description: List of status conditions to indicate the status of a
- CertificateRequest. Known condition types are `Ready` and `InvalidRequest`.
- items:
- description: CertificateRequestCondition contains condition information
- for a CertificateRequest.
- properties:
- lastTransitionTime:
- description: LastTransitionTime is the timestamp corresponding
- to the last status change of this condition.
- format: date-time
- type: string
- message:
- description: Message is a human readable description of the
- details of the last transition, complementing reason.
- type: string
- reason:
- description: Reason is a brief machine readable explanation
- for the condition's last transition.
- type: string
- status:
- description: Status of the condition, one of (`True`, `False`,
- `Unknown`).
- enum:
- - "True"
- - "False"
- - Unknown
- type: string
- type:
- description: Type of the condition, known values are (`Ready`,
- `InvalidRequest`, `Approved`, `Denied`).
- type: string
- required:
- - status
- - type
- type: object
- type: array
- failureTime:
- description: FailureTime stores the time that this CertificateRequest
- failed. This is used to influence garbage collection and back-off.
- format: date-time
- type: string
- type: object
- required:
- - spec
- type: object
- served: true
- storage: true
- subresources:
- status: {}
-status:
- acceptedNames:
- kind: ""
- plural: ""
- conditions: []
- storedVersions: []
+ format: byte
+ certificate:
+ description: The PEM encoded x509 certificate resulting from the certificate signing request. If not set, the CertificateRequest has either not been completed or has failed. More information on failure can be found by checking the `conditions` field.
+ type: string
+ format: byte
+ conditions:
+ description: List of status conditions to indicate the status of a CertificateRequest. Known condition types are `Ready` and `InvalidRequest`.
+ type: array
+ items:
+ description: CertificateRequestCondition contains condition information for a CertificateRequest.
+ type: object
+ required:
+ - status
+ - type
+ properties:
+ lastTransitionTime:
+ description: LastTransitionTime is the timestamp corresponding to the last status change of this condition.
+ type: string
+ format: date-time
+ message:
+ description: Message is a human readable description of the details of the last transition, complementing reason.
+ type: string
+ reason:
+ description: Reason is a brief machine readable explanation for the condition's last transition.
+ type: string
+ status:
+ description: Status of the condition, one of (`True`, `False`, `Unknown`).
+ type: string
+ enum:
+ - "True"
+ - "False"
+ - Unknown
+ type:
+ description: Type of the condition, known values are (`Ready`, `InvalidRequest`, `Approved`, `Denied`).
+ type: string
+ failureTime:
+ description: FailureTime stores the time that this CertificateRequest failed. This is used to influence garbage collection and back-off.
+ type: string
+ format: date-time
+ served: true
+ storage: true
---
+# Source: cert-manager/templates/templates.out
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
+ name: certificates.cert-manager.io
annotations:
- cert-manager.io/inject-ca-from-secret: cert-manager/cert-manager-webhook-ca
+ cert-manager.io/inject-ca-from-secret: 'cert-manager/cert-manager-webhook-ca'
labels:
- app: cert-manager
- app.kubernetes.io/instance: cert-manager
- app.kubernetes.io/name: cert-manager
- name: certificates.cert-manager.io
+ app: 'cert-manager'
+ app.kubernetes.io/name: 'cert-manager'
+ app.kubernetes.io/instance: 'cert-manager'
+ # Generated labels
+ app.kubernetes.io/version: "v1.7.1"
spec:
- conversion:
- strategy: Webhook
- webhook:
- clientConfig:
- service:
- name: cert-manager-webhook
- namespace: cert-manager
- path: /convert
- conversionReviewVersions:
- - v1
- - v1beta1
group: cert-manager.io
names:
- categories:
- - cert-manager
kind: Certificate
listKind: CertificateList
plural: certificates
shortNames:
- - cert
- - certs
+ - cert
+ - certs
singular: certificate
+ categories:
+ - cert-manager
scope: Namespaced
versions:
- - additionalPrinterColumns:
- - jsonPath: .status.conditions[?(@.type=="Ready")].status
- name: Ready
- type: string
- - jsonPath: .spec.secretName
- name: Secret
- type: string
- - jsonPath: .spec.issuerRef.name
- name: Issuer
- priority: 1
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].message
- name: Status
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1alpha2
- schema:
- openAPIV3Schema:
- description: "A Certificate resource should be created to ensure an up to
- date and signed x509 certificate is stored in the Kubernetes Secret resource
- named in `spec.secretName`. \n The stored certificate will be renewed before
- it expires (as configured by `spec.renewBefore`)."
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Desired state of the Certificate resource.
- properties:
- commonName:
- description: 'CommonName is a common name to be used on the Certificate.
- The CommonName should have a length of 64 characters or fewer to
- avoid generating invalid CSRs. This value is ignored by TLS clients
- when any subject alt name is set. This is x509 behaviour: https://tools.ietf.org/html/rfc6125#section-6.4.4'
- type: string
- dnsNames:
- description: DNSNames is a list of DNS subjectAltNames to be set on
- the Certificate.
- items:
- type: string
- type: array
- duration:
- description: The requested 'duration' (i.e. lifetime) of the Certificate.
- This option may be ignored/overridden by some issuer types. If overridden
- and `renewBefore` is greater than the actual certificate duration,
- the certificate will be automatically renewed 2/3rds of the way
- through the certificate's duration.
- type: string
- emailSANs:
- description: EmailSANs is a list of email subjectAltNames to be set
- on the Certificate.
- items:
- type: string
- type: array
- encodeUsagesInRequest:
- description: EncodeUsagesInRequest controls whether key usages should
- be present in the CertificateRequest
- type: boolean
- ipAddresses:
- description: IPAddresses is a list of IP address subjectAltNames to
- be set on the Certificate.
- items:
- type: string
- type: array
- isCA:
- description: IsCA will mark this Certificate as valid for certificate
- signing. This will automatically add the `cert sign` usage to the
- list of `usages`.
- type: boolean
- issuerRef:
- description: IssuerRef is a reference to the issuer for this certificate.
- If the `kind` field is not set, or set to `Issuer`, an Issuer resource
- with the given name in the same namespace as the Certificate will
- be used. If the `kind` field is set to `ClusterIssuer`, a ClusterIssuer
- with the provided name will be used. The `name` field in this stanza
- is required at all times.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
- type: string
- name:
- description: Name of the resource being referred to.
- type: string
- required:
- - name
- type: object
- keyAlgorithm:
- description: KeyAlgorithm is the private key algorithm of the corresponding
- private key for this certificate. If provided, allowed values are
- either `rsa` or `ecdsa` If `keyAlgorithm` is specified and `keySize`
- is not provided, key size of 256 will be used for `ecdsa` key algorithm
- and key size of 2048 will be used for `rsa` key algorithm.
- enum:
- - rsa
- - ecdsa
- type: string
- keyEncoding:
- description: KeyEncoding is the private key cryptography standards
- (PKCS) for this certificate's private key to be encoded in. If provided,
- allowed values are `pkcs1` and `pkcs8` standing for PKCS#1 and PKCS#8,
- respectively. If KeyEncoding is not specified, then `pkcs1` will
- be used by default.
- enum:
- - pkcs1
- - pkcs8
- type: string
- keySize:
- description: KeySize is the key bit size of the corresponding private
- key for this certificate. If `keyAlgorithm` is set to `rsa`, valid
- values are `2048`, `4096` or `8192`, and will default to `2048`
- if not specified. If `keyAlgorithm` is set to `ecdsa`, valid values
- are `256`, `384` or `521`, and will default to `256` if not specified.
- No other values are allowed.
- type: integer
- keystores:
- description: Keystores configures additional keystore output formats
- stored in the `secretName` Secret resource.
- properties:
- jks:
- description: JKS configures options for storing a JKS keystore
- in the `spec.secretName` Secret resource.
- properties:
- create:
- description: Create enables JKS keystore creation for the
- Certificate. If true, a file named `keystore.jks` will be
- created in the target Secret resource, encrypted using the
- password stored in `passwordSecretRef`. The keystore file
- will only be updated upon re-issuance.
- type: boolean
- passwordSecretRef:
- description: PasswordSecretRef is a reference to a key in
- a Secret resource containing the password used to encrypt
- the JKS keystore.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this field
- may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred to.
- More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - create
- - passwordSecretRef
+ - name: v1
+ subresources:
+ status: {}
+ additionalPrinterColumns:
+ - jsonPath: .status.conditions[?(@.type=="Ready")].status
+ name: Ready
+ type: string
+ - jsonPath: .spec.secretName
+ name: Secret
+ type: string
+ - jsonPath: .spec.issuerRef.name
+ name: Issuer
+ priority: 1
+ type: string
+ - jsonPath: .status.conditions[?(@.type=="Ready")].message
+ name: Status
+ priority: 1
+ type: string
+ - jsonPath: .metadata.creationTimestamp
+ description: CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.
+ name: Age
+ type: date
+ schema:
+ openAPIV3Schema:
+ description: "A Certificate resource should be created to ensure an up to date and signed x509 certificate is stored in the Kubernetes Secret resource named in `spec.secretName`. \n The stored certificate will be renewed before it expires (as configured by `spec.renewBefore`)."
+ type: object
+ required:
+ - spec
+ properties:
+ apiVersion:
+ description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
+ type: string
+ kind:
+ description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
+ type: string
+ metadata:
+ type: object
+ spec:
+ description: Desired state of the Certificate resource.
+ type: object
+ required:
+ - issuerRef
+ - secretName
+ properties:
+ additionalOutputFormats:
+ description: AdditionalOutputFormats defines extra output formats of the private key and signed certificate chain to be written to this Certificate's target Secret. This is an Alpha Feature and is only enabled with the `--feature-gates=AdditionalCertificateOutputFormats=true` option on both the controller and webhook components.
+ type: array
+ items:
+ description: CertificateAdditionalOutputFormat defines an additional output format of a Certificate resource. These contain supplementary data formats of the signed certificate chain and paired private key.
type: object
- pkcs12:
- description: PKCS12 configures options for storing a PKCS12 keystore
- in the `spec.secretName` Secret resource.
- properties:
- create:
- description: Create enables PKCS12 keystore creation for the
- Certificate. If true, a file named `keystore.p12` will be
- created in the target Secret resource, encrypted using the
- password stored in `passwordSecretRef`. The keystore file
- will only be updated upon re-issuance.
- type: boolean
- passwordSecretRef:
- description: PasswordSecretRef is a reference to a key in
- a Secret resource containing the password used to encrypt
- the PKCS12 keystore.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this field
- may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred to.
- More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
required:
- - create
- - passwordSecretRef
- type: object
- type: object
- organization:
- description: Organization is a list of organizations to be used on
- the Certificate.
- items:
+ - type
+ properties:
+ type:
+ description: Type is the name of the format type that should be written to the Certificate's target Secret.
+ type: string
+ enum:
+ - DER
+ - CombinedPEM
+ commonName:
+ description: 'CommonName is a common name to be used on the Certificate. The CommonName should have a length of 64 characters or fewer to avoid generating invalid CSRs. This value is ignored by TLS clients when any subject alt name is set. This is x509 behaviour: https://tools.ietf.org/html/rfc6125#section-6.4.4'
type: string
- type: array
- privateKey:
- description: Options to control private keys used for the Certificate.
- properties:
- rotationPolicy:
- description: RotationPolicy controls how private keys should be
- regenerated when a re-issuance is being processed. If set to
- Never, a private key will only be generated if one does not
- already exist in the target `spec.secretName`. If one does exists
- but it does not have the correct algorithm or size, a warning
- will be raised to await user intervention. If set to Always,
- a private key matching the specified requirements will be generated
- whenever a re-issuance occurs. Default is 'Never' for backward
- compatibility.
- type: string
- type: object
- renewBefore:
- description: The amount of time before the currently issued certificate's
- `notAfter` time that cert-manager will begin to attempt to renew
- the certificate. If this value is greater than the total duration
- of the certificate (i.e. notAfter - notBefore), it will be automatically
- renewed 2/3rds of the way through the certificate's duration.
- type: string
- revisionHistoryLimit:
- description: revisionHistoryLimit is the maximum number of CertificateRequest
- revisions that are maintained in the Certificate's history. Each
- revision represents a single `CertificateRequest` created by this
- Certificate, either when it was created, renewed, or Spec was changed.
- Revisions will be removed by oldest first if the number of revisions
- exceeds this number. If set, revisionHistoryLimit must be a value
- of `1` or greater. If unset (`nil`), revisions will not be garbage
- collected. Default value is `nil`.
- format: int32
- type: integer
- secretName:
- description: SecretName is the name of the secret resource that will
- be automatically created and managed by this Certificate resource.
- It will be populated with a private key and certificate, signed
- by the denoted issuer.
- type: string
- subject:
- description: Full X509 name specification (https://golang.org/pkg/crypto/x509/pkix/#Name).
- properties:
- countries:
- description: Countries to be used on the Certificate.
- items:
- type: string
- type: array
- localities:
- description: Cities to be used on the Certificate.
- items:
- type: string
- type: array
- organizationalUnits:
- description: Organizational Units to be used on the Certificate.
- items:
- type: string
- type: array
- postalCodes:
- description: Postal codes to be used on the Certificate.
- items:
- type: string
- type: array
- provinces:
- description: State/Provinces to be used on the Certificate.
- items:
- type: string
- type: array
- serialNumber:
- description: Serial number to be used on the Certificate.
+ dnsNames:
+ description: DNSNames is a list of DNS subjectAltNames to be set on the Certificate.
+ type: array
+ items:
type: string
- streetAddresses:
- description: Street addresses to be used on the Certificate.
- items:
- type: string
- type: array
- type: object
- uriSANs:
- description: URISANs is a list of URI subjectAltNames to be set on
- the Certificate.
- items:
- type: string
- type: array
- usages:
- description: Usages is the set of x509 usages that are requested for
- the certificate. Defaults to `digital signature` and `key encipherment`
- if not specified.
- items:
- description: 'KeyUsage specifies valid usage contexts for keys.
- See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12
- Valid KeyUsage values are as follows: "signing", "digital signature",
- "content commitment", "key encipherment", "key agreement", "data
- encipherment", "cert sign", "crl sign", "encipher only", "decipher
- only", "any", "server auth", "client auth", "code signing", "email
- protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec
- user", "timestamping", "ocsp signing", "microsoft sgc", "netscape
- sgc"'
- enum:
- - signing
- - digital signature
- - content commitment
- - key encipherment
- - key agreement
- - data encipherment
- - cert sign
- - crl sign
- - encipher only
- - decipher only
- - any
- - server auth
- - client auth
- - code signing
- - email protection
- - s/mime
- - ipsec end system
- - ipsec tunnel
- - ipsec user
- - timestamping
- - ocsp signing
- - microsoft sgc
- - netscape sgc
+ duration:
+ description: The requested 'duration' (i.e. lifetime) of the Certificate. This option may be ignored/overridden by some issuer types. If unset this defaults to 90 days. Certificate will be renewed either 2/3 through its duration or `renewBefore` period before its expiry, whichever is later. Minimum accepted duration is 1 hour. Value must be in units accepted by Go time.ParseDuration https://golang.org/pkg/time/#ParseDuration
type: string
- type: array
- required:
- - issuerRef
- - secretName
- type: object
- status:
- description: Status of the Certificate. This is set and managed automatically.
- properties:
- conditions:
- description: List of status conditions to indicate the status of certificates.
- Known condition types are `Ready` and `Issuing`.
- items:
- description: CertificateCondition contains condition information
- for an Certificate.
+ emailAddresses:
+ description: EmailAddresses is a list of email subjectAltNames to be set on the Certificate.
+ type: array
+ items:
+ type: string
+ encodeUsagesInRequest:
+ description: EncodeUsagesInRequest controls whether key usages should be present in the CertificateRequest
+ type: boolean
+ ipAddresses:
+ description: IPAddresses is a list of IP address subjectAltNames to be set on the Certificate.
+ type: array
+ items:
+ type: string
+ isCA:
+ description: IsCA will mark this Certificate as valid for certificate signing. This will automatically add the `cert sign` usage to the list of `usages`.
+ type: boolean
+ issuerRef:
+ description: IssuerRef is a reference to the issuer for this certificate. If the `kind` field is not set, or set to `Issuer`, an Issuer resource with the given name in the same namespace as the Certificate will be used. If the `kind` field is set to `ClusterIssuer`, a ClusterIssuer with the provided name will be used. The `name` field in this stanza is required at all times.
+ type: object
+ required:
+ - name
properties:
- lastTransitionTime:
- description: LastTransitionTime is the timestamp corresponding
- to the last status change of this condition.
- format: date-time
+ group:
+ description: Group of the resource being referred to.
type: string
- message:
- description: Message is a human readable description of the
- details of the last transition, complementing reason.
+ kind:
+ description: Kind of the resource being referred to.
type: string
- observedGeneration:
- description: If set, this represents the .metadata.generation
- that the condition was set based upon. For instance, if .metadata.generation
- is currently 12, but the .status.condition[x].observedGeneration
- is 9, the condition is out of date with respect to the current
- state of the Certificate.
- format: int64
- type: integer
- reason:
- description: Reason is a brief machine readable explanation
- for the condition's last transition.
+ name:
+ description: Name of the resource being referred to.
+ type: string
+ keystores:
+ description: Keystores configures additional keystore output formats stored in the `secretName` Secret resource.
+ type: object
+ properties:
+ jks:
+ description: JKS configures options for storing a JKS keystore in the `spec.secretName` Secret resource.
+ type: object
+ required:
+ - create
+ - passwordSecretRef
+ properties:
+ create:
+ description: Create enables JKS keystore creation for the Certificate. If true, a file named `keystore.jks` will be created in the target Secret resource, encrypted using the password stored in `passwordSecretRef`. The keystore file will only be updated upon re-issuance. A file named `truststore.jks` will also be created in the target Secret resource, encrypted using the password stored in `passwordSecretRef` containing the issuing Certificate Authority
+ type: boolean
+ passwordSecretRef:
+ description: PasswordSecretRef is a reference to a key in a Secret resource containing the password used to encrypt the JKS keystore.
+ type: object
+ required:
+ - name
+ properties:
+ key:
+ description: The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be defaulted, in others it may be required.
+ type: string
+ name:
+ description: 'Name of the resource being referred to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
+ type: string
+ pkcs12:
+ description: PKCS12 configures options for storing a PKCS12 keystore in the `spec.secretName` Secret resource.
+ type: object
+ required:
+ - create
+ - passwordSecretRef
+ properties:
+ create:
+ description: Create enables PKCS12 keystore creation for the Certificate. If true, a file named `keystore.p12` will be created in the target Secret resource, encrypted using the password stored in `passwordSecretRef`. The keystore file will only be updated upon re-issuance. A file named `truststore.p12` will also be created in the target Secret resource, encrypted using the password stored in `passwordSecretRef` containing the issuing Certificate Authority
+ type: boolean
+ passwordSecretRef:
+ description: PasswordSecretRef is a reference to a key in a Secret resource containing the password used to encrypt the PKCS12 keystore.
+ type: object
+ required:
+ - name
+ properties:
+ key:
+ description: The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be defaulted, in others it may be required.
+ type: string
+ name:
+ description: 'Name of the resource being referred to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
+ type: string
+ privateKey:
+ description: Options to control private keys used for the Certificate.
+ type: object
+ properties:
+ algorithm:
+ description: Algorithm is the private key algorithm of the corresponding private key for this certificate. If provided, allowed values are either `RSA`,`Ed25519` or `ECDSA` If `algorithm` is specified and `size` is not provided, key size of 256 will be used for `ECDSA` key algorithm and key size of 2048 will be used for `RSA` key algorithm. key size is ignored when using the `Ed25519` key algorithm.
type: string
- status:
- description: Status of the condition, one of (`True`, `False`,
- `Unknown`).
enum:
- - "True"
- - "False"
- - Unknown
+ - RSA
+ - ECDSA
+ - Ed25519
+ encoding:
+ description: The private key cryptography standards (PKCS) encoding for this certificate's private key to be encoded in. If provided, allowed values are `PKCS1` and `PKCS8` standing for PKCS#1 and PKCS#8, respectively. Defaults to `PKCS1` if not specified.
type: string
- type:
- description: Type of the condition, known values are (`Ready`,
- `Issuing`).
+ enum:
+ - PKCS1
+ - PKCS8
+ rotationPolicy:
+ description: RotationPolicy controls how private keys should be regenerated when a re-issuance is being processed. If set to Never, a private key will only be generated if one does not already exist in the target `spec.secretName`. If one does exists but it does not have the correct algorithm or size, a warning will be raised to await user intervention. If set to Always, a private key matching the specified requirements will be generated whenever a re-issuance occurs. Default is 'Never' for backward compatibility.
type: string
- required:
- - status
- - type
- type: object
- type: array
- lastFailureTime:
- description: LastFailureTime is the time as recorded by the Certificate
- controller of the most recent failure to complete a CertificateRequest
- for this Certificate resource. If set, cert-manager will not re-request
- another Certificate until 1 hour has elapsed from this time.
- format: date-time
- type: string
- nextPrivateKeySecretName:
- description: The name of the Secret resource containing the private
- key to be used for the next certificate iteration. The keymanager
- controller will automatically set this field if the `Issuing` condition
- is set to `True`. It will automatically unset this field when the
- Issuing condition is not set or False.
- type: string
- notAfter:
- description: The expiration time of the certificate stored in the
- secret named by this resource in `spec.secretName`.
- format: date-time
- type: string
- notBefore:
- description: The time after which the certificate stored in the secret
- named by this resource in spec.secretName is valid.
- format: date-time
- type: string
- renewalTime:
- description: RenewalTime is the time at which the certificate will
- be next renewed. If not set, no upcoming renewal is scheduled.
- format: date-time
- type: string
- revision:
- description: "The current 'revision' of the certificate as issued.
- \n When a CertificateRequest resource is created, it will have the
- `cert-manager.io/certificate-revision` set to one greater than the
- current value of this field. \n Upon issuance, this field will be
- set to the value of the annotation on the CertificateRequest resource
- used to issue the certificate. \n Persisting the value on the CertificateRequest
- resource allows the certificates controller to know whether a request
- is part of an old issuance or if it is part of the ongoing revision's
- issuance by checking if the revision value in the annotation is
- greater than this field."
- type: integer
- type: object
- type: object
- served: true
- storage: false
- subresources:
- status: {}
- - additionalPrinterColumns:
- - jsonPath: .status.conditions[?(@.type=="Ready")].status
- name: Ready
- type: string
- - jsonPath: .spec.secretName
- name: Secret
- type: string
- - jsonPath: .spec.issuerRef.name
- name: Issuer
- priority: 1
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].message
- name: Status
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1alpha3
- schema:
- openAPIV3Schema:
- description: "A Certificate resource should be created to ensure an up to
- date and signed x509 certificate is stored in the Kubernetes Secret resource
- named in `spec.secretName`. \n The stored certificate will be renewed before
- it expires (as configured by `spec.renewBefore`)."
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Desired state of the Certificate resource.
- properties:
- commonName:
- description: 'CommonName is a common name to be used on the Certificate.
- The CommonName should have a length of 64 characters or fewer to
- avoid generating invalid CSRs. This value is ignored by TLS clients
- when any subject alt name is set. This is x509 behaviour: https://tools.ietf.org/html/rfc6125#section-6.4.4'
- type: string
- dnsNames:
- description: DNSNames is a list of DNS subjectAltNames to be set on
- the Certificate.
- items:
- type: string
- type: array
- duration:
- description: The requested 'duration' (i.e. lifetime) of the Certificate.
- This option may be ignored/overridden by some issuer types. If overridden
- and `renewBefore` is greater than the actual certificate duration,
- the certificate will be automatically renewed 2/3rds of the way
- through the certificate's duration.
- type: string
- emailSANs:
- description: EmailSANs is a list of email subjectAltNames to be set
- on the Certificate.
- items:
+ size:
+ description: Size is the key bit size of the corresponding private key for this certificate. If `algorithm` is set to `RSA`, valid values are `2048`, `4096` or `8192`, and will default to `2048` if not specified. If `algorithm` is set to `ECDSA`, valid values are `256`, `384` or `521`, and will default to `256` if not specified. If `algorithm` is set to `Ed25519`, Size is ignored. No other values are allowed.
+ type: integer
+ renewBefore:
+ description: How long before the currently issued certificate's expiry cert-manager should renew the certificate. The default is 2/3 of the issued certificate's duration. Minimum accepted value is 5 minutes. Value must be in units accepted by Go time.ParseDuration https://golang.org/pkg/time/#ParseDuration
type: string
- type: array
- encodeUsagesInRequest:
- description: EncodeUsagesInRequest controls whether key usages should
- be present in the CertificateRequest
- type: boolean
- ipAddresses:
- description: IPAddresses is a list of IP address subjectAltNames to
- be set on the Certificate.
- items:
+ revisionHistoryLimit:
+ description: revisionHistoryLimit is the maximum number of CertificateRequest revisions that are maintained in the Certificate's history. Each revision represents a single `CertificateRequest` created by this Certificate, either when it was created, renewed, or Spec was changed. Revisions will be removed by oldest first if the number of revisions exceeds this number. If set, revisionHistoryLimit must be a value of `1` or greater. If unset (`nil`), revisions will not be garbage collected. Default value is `nil`.
+ type: integer
+ format: int32
+ secretName:
+ description: SecretName is the name of the secret resource that will be automatically created and managed by this Certificate resource. It will be populated with a private key and certificate, signed by the denoted issuer.
type: string
- type: array
- isCA:
- description: IsCA will mark this Certificate as valid for certificate
- signing. This will automatically add the `cert sign` usage to the
- list of `usages`.
- type: boolean
- issuerRef:
- description: IssuerRef is a reference to the issuer for this certificate.
- If the `kind` field is not set, or set to `Issuer`, an Issuer resource
- with the given name in the same namespace as the Certificate will
- be used. If the `kind` field is set to `ClusterIssuer`, a ClusterIssuer
- with the provided name will be used. The `name` field in this stanza
- is required at all times.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
+ secretTemplate:
+ description: SecretTemplate defines annotations and labels to be copied to the Certificate's Secret. Labels and annotations on the Secret will be changed as they appear on the SecretTemplate when added or removed. SecretTemplate annotations are added in conjunction with, and cannot overwrite, the base set of annotations cert-manager sets on the Certificate's Secret.
+ type: object
+ properties:
+ annotations:
+ description: Annotations is a key value map to be copied to the target Kubernetes Secret.
+ type: object
+ additionalProperties:
+ type: string
+ labels:
+ description: Labels is a key value map to be copied to the target Kubernetes Secret.
+ type: object
+ additionalProperties:
+ type: string
+ subject:
+ description: Full X509 name specification (https://golang.org/pkg/crypto/x509/pkix/#Name).
+ type: object
+ properties:
+ countries:
+ description: Countries to be used on the Certificate.
+ type: array
+ items:
+ type: string
+ localities:
+ description: Cities to be used on the Certificate.
+ type: array
+ items:
+ type: string
+ organizationalUnits:
+ description: Organizational Units to be used on the Certificate.
+ type: array
+ items:
+ type: string
+ organizations:
+ description: Organizations to be used on the Certificate.
+ type: array
+ items:
+ type: string
+ postalCodes:
+ description: Postal codes to be used on the Certificate.
+ type: array
+ items:
+ type: string
+ provinces:
+ description: State/Provinces to be used on the Certificate.
+ type: array
+ items:
+ type: string
+ serialNumber:
+ description: Serial number to be used on the Certificate.
+ type: string
+ streetAddresses:
+ description: Street addresses to be used on the Certificate.
+ type: array
+ items:
+ type: string
+ uris:
+ description: URIs is a list of URI subjectAltNames to be set on the Certificate.
+ type: array
+ items:
type: string
- name:
- description: Name of the resource being referred to.
+ usages:
+ description: Usages is the set of x509 usages that are requested for the certificate. Defaults to `digital signature` and `key encipherment` if not specified.
+ type: array
+ items:
+ description: 'KeyUsage specifies valid usage contexts for keys. See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12 Valid KeyUsage values are as follows: "signing", "digital signature", "content commitment", "key encipherment", "key agreement", "data encipherment", "cert sign", "crl sign", "encipher only", "decipher only", "any", "server auth", "client auth", "code signing", "email protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec user", "timestamping", "ocsp signing", "microsoft sgc", "netscape sgc"'
type: string
- required:
- - name
- type: object
- keyAlgorithm:
- description: KeyAlgorithm is the private key algorithm of the corresponding
- private key for this certificate. If provided, allowed values are
- either `rsa` or `ecdsa` If `keyAlgorithm` is specified and `keySize`
- is not provided, key size of 256 will be used for `ecdsa` key algorithm
- and key size of 2048 will be used for `rsa` key algorithm.
- enum:
- - rsa
- - ecdsa
- type: string
- keyEncoding:
- description: KeyEncoding is the private key cryptography standards
- (PKCS) for this certificate's private key to be encoded in. If provided,
- allowed values are `pkcs1` and `pkcs8` standing for PKCS#1 and PKCS#8,
- respectively. If KeyEncoding is not specified, then `pkcs1` will
- be used by default.
- enum:
- - pkcs1
- - pkcs8
- type: string
- keySize:
- description: KeySize is the key bit size of the corresponding private
- key for this certificate. If `keyAlgorithm` is set to `rsa`, valid
- values are `2048`, `4096` or `8192`, and will default to `2048`
- if not specified. If `keyAlgorithm` is set to `ecdsa`, valid values
- are `256`, `384` or `521`, and will default to `256` if not specified.
- No other values are allowed.
- type: integer
- keystores:
- description: Keystores configures additional keystore output formats
- stored in the `secretName` Secret resource.
- properties:
- jks:
- description: JKS configures options for storing a JKS keystore
- in the `spec.secretName` Secret resource.
- properties:
- create:
- description: Create enables JKS keystore creation for the
- Certificate. If true, a file named `keystore.jks` will be
- created in the target Secret resource, encrypted using the
- password stored in `passwordSecretRef`. The keystore file
- will only be updated upon re-issuance. A file named `truststore.jks`
- will also be created in the target Secret resource, encrypted
- using the password stored in `passwordSecretRef` containing
- the issuing Certificate Authority.
- type: boolean
- passwordSecretRef:
- description: PasswordSecretRef is a reference to a key in
- a Secret resource containing the password used to encrypt
- the JKS keystore.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this field
- may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred to.
- More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - create
- - passwordSecretRef
+ enum:
+ - signing
+ - digital signature
+ - content commitment
+ - key encipherment
+ - key agreement
+ - data encipherment
+ - cert sign
+ - crl sign
+ - encipher only
+ - decipher only
+ - any
+ - server auth
+ - client auth
+ - code signing
+ - email protection
+ - s/mime
+ - ipsec end system
+ - ipsec tunnel
+ - ipsec user
+ - timestamping
+ - ocsp signing
+ - microsoft sgc
+ - netscape sgc
+ status:
+ description: Status of the Certificate. This is set and managed automatically.
+ type: object
+ properties:
+ conditions:
+ description: List of status conditions to indicate the status of certificates. Known condition types are `Ready` and `Issuing`.
+ type: array
+ items:
+ description: CertificateCondition contains condition information for an Certificate.
type: object
- pkcs12:
- description: PKCS12 configures options for storing a PKCS12 keystore
- in the `spec.secretName` Secret resource.
- properties:
- create:
- description: Create enables PKCS12 keystore creation for the
- Certificate. If true, a file named `keystore.p12` will be
- created in the target Secret resource, encrypted using the
- password stored in `passwordSecretRef`. The keystore file
- will only be updated upon re-issuance. A file named `truststore.p12`
- will also be created in the target Secret resource, encrypted
- using the password stored in `passwordSecretRef` containing
- the issuing Certificate Authority.
- type: boolean
- passwordSecretRef:
- description: PasswordSecretRef is a reference to a key in
- a Secret resource containing the password used to encrypt
- the PKCS12 keystore.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this field
- may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred to.
- More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
required:
- - create
- - passwordSecretRef
- type: object
- type: object
- privateKey:
- description: Options to control private keys used for the Certificate.
- properties:
- rotationPolicy:
- description: RotationPolicy controls how private keys should be
- regenerated when a re-issuance is being processed. If set to
- Never, a private key will only be generated if one does not
- already exist in the target `spec.secretName`. If one does exists
- but it does not have the correct algorithm or size, a warning
- will be raised to await user intervention. If set to Always,
- a private key matching the specified requirements will be generated
- whenever a re-issuance occurs. Default is 'Never' for backward
- compatibility.
- type: string
- type: object
- renewBefore:
- description: The amount of time before the currently issued certificate's
- `notAfter` time that cert-manager will begin to attempt to renew
- the certificate. If this value is greater than the total duration
- of the certificate (i.e. notAfter - notBefore), it will be automatically
- renewed 2/3rds of the way through the certificate's duration.
- type: string
- revisionHistoryLimit:
- description: revisionHistoryLimit is the maximum number of CertificateRequest
- revisions that are maintained in the Certificate's history. Each
- revision represents a single `CertificateRequest` created by this
- Certificate, either when it was created, renewed, or Spec was changed.
- Revisions will be removed by oldest first if the number of revisions
- exceeds this number. If set, revisionHistoryLimit must be a value
- of `1` or greater. If unset (`nil`), revisions will not be garbage
- collected. Default value is `nil`.
- format: int32
- type: integer
- secretName:
- description: SecretName is the name of the secret resource that will
- be automatically created and managed by this Certificate resource.
- It will be populated with a private key and certificate, signed
- by the denoted issuer.
- type: string
- subject:
- description: Full X509 name specification (https://golang.org/pkg/crypto/x509/pkix/#Name).
- properties:
- countries:
- description: Countries to be used on the Certificate.
- items:
- type: string
- type: array
- localities:
- description: Cities to be used on the Certificate.
- items:
- type: string
- type: array
- organizationalUnits:
- description: Organizational Units to be used on the Certificate.
- items:
- type: string
- type: array
- organizations:
- description: Organizations to be used on the Certificate.
- items:
- type: string
- type: array
- postalCodes:
- description: Postal codes to be used on the Certificate.
- items:
- type: string
- type: array
- provinces:
- description: State/Provinces to be used on the Certificate.
- items:
- type: string
- type: array
- serialNumber:
- description: Serial number to be used on the Certificate.
- type: string
- streetAddresses:
- description: Street addresses to be used on the Certificate.
- items:
- type: string
- type: array
- type: object
- uriSANs:
- description: URISANs is a list of URI subjectAltNames to be set on
- the Certificate.
- items:
- type: string
- type: array
- usages:
- description: Usages is the set of x509 usages that are requested for
- the certificate. Defaults to `digital signature` and `key encipherment`
- if not specified.
- items:
- description: 'KeyUsage specifies valid usage contexts for keys.
- See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12
- Valid KeyUsage values are as follows: "signing", "digital signature",
- "content commitment", "key encipherment", "key agreement", "data
- encipherment", "cert sign", "crl sign", "encipher only", "decipher
- only", "any", "server auth", "client auth", "code signing", "email
- protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec
- user", "timestamping", "ocsp signing", "microsoft sgc", "netscape
- sgc"'
- enum:
- - signing
- - digital signature
- - content commitment
- - key encipherment
- - key agreement
- - data encipherment
- - cert sign
- - crl sign
- - encipher only
- - decipher only
- - any
- - server auth
- - client auth
- - code signing
- - email protection
- - s/mime
- - ipsec end system
- - ipsec tunnel
- - ipsec user
- - timestamping
- - ocsp signing
- - microsoft sgc
- - netscape sgc
- type: string
- type: array
- required:
- - issuerRef
- - secretName
- type: object
- status:
- description: Status of the Certificate. This is set and managed automatically.
- properties:
- conditions:
- description: List of status conditions to indicate the status of certificates.
- Known condition types are `Ready` and `Issuing`.
- items:
- description: CertificateCondition contains condition information
- for an Certificate.
- properties:
- lastTransitionTime:
- description: LastTransitionTime is the timestamp corresponding
- to the last status change of this condition.
- format: date-time
- type: string
- message:
- description: Message is a human readable description of the
- details of the last transition, complementing reason.
- type: string
- observedGeneration:
- description: If set, this represents the .metadata.generation
- that the condition was set based upon. For instance, if .metadata.generation
- is currently 12, but the .status.condition[x].observedGeneration
- is 9, the condition is out of date with respect to the current
- state of the Certificate.
- format: int64
- type: integer
- reason:
- description: Reason is a brief machine readable explanation
- for the condition's last transition.
- type: string
- status:
- description: Status of the condition, one of (`True`, `False`,
- `Unknown`).
- enum:
- - "True"
- - "False"
- - Unknown
- type: string
- type:
- description: Type of the condition, known values are (`Ready`,
- `Issuing`).
- type: string
- required:
- - status
- - type
- type: object
- type: array
- lastFailureTime:
- description: LastFailureTime is the time as recorded by the Certificate
- controller of the most recent failure to complete a CertificateRequest
- for this Certificate resource. If set, cert-manager will not re-request
- another Certificate until 1 hour has elapsed from this time.
- format: date-time
- type: string
- nextPrivateKeySecretName:
- description: The name of the Secret resource containing the private
- key to be used for the next certificate iteration. The keymanager
- controller will automatically set this field if the `Issuing` condition
- is set to `True`. It will automatically unset this field when the
- Issuing condition is not set or False.
- type: string
- notAfter:
- description: The expiration time of the certificate stored in the
- secret named by this resource in `spec.secretName`.
- format: date-time
- type: string
- notBefore:
- description: The time after which the certificate stored in the secret
- named by this resource in spec.secretName is valid.
- format: date-time
- type: string
- renewalTime:
- description: RenewalTime is the time at which the certificate will
- be next renewed. If not set, no upcoming renewal is scheduled.
- format: date-time
- type: string
- revision:
- description: "The current 'revision' of the certificate as issued.
- \n When a CertificateRequest resource is created, it will have the
- `cert-manager.io/certificate-revision` set to one greater than the
- current value of this field. \n Upon issuance, this field will be
- set to the value of the annotation on the CertificateRequest resource
- used to issue the certificate. \n Persisting the value on the CertificateRequest
- resource allows the certificates controller to know whether a request
- is part of an old issuance or if it is part of the ongoing revision's
- issuance by checking if the revision value in the annotation is
- greater than this field."
- type: integer
- type: object
- type: object
- served: true
- storage: false
- subresources:
- status: {}
- - additionalPrinterColumns:
- - jsonPath: .status.conditions[?(@.type=="Ready")].status
- name: Ready
- type: string
- - jsonPath: .spec.secretName
- name: Secret
- type: string
- - jsonPath: .spec.issuerRef.name
- name: Issuer
- priority: 1
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].message
- name: Status
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1beta1
- schema:
- openAPIV3Schema:
- description: "A Certificate resource should be created to ensure an up to
- date and signed x509 certificate is stored in the Kubernetes Secret resource
- named in `spec.secretName`. \n The stored certificate will be renewed before
- it expires (as configured by `spec.renewBefore`)."
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Desired state of the Certificate resource.
- properties:
- commonName:
- description: 'CommonName is a common name to be used on the Certificate.
- The CommonName should have a length of 64 characters or fewer to
- avoid generating invalid CSRs. This value is ignored by TLS clients
- when any subject alt name is set. This is x509 behaviour: https://tools.ietf.org/html/rfc6125#section-6.4.4'
- type: string
- dnsNames:
- description: DNSNames is a list of DNS subjectAltNames to be set on
- the Certificate.
- items:
- type: string
- type: array
- duration:
- description: The requested 'duration' (i.e. lifetime) of the Certificate.
- This option may be ignored/overridden by some issuer types. If overridden
- and `renewBefore` is greater than the actual certificate duration,
- the certificate will be automatically renewed 2/3rds of the way
- through the certificate's duration.
- type: string
- emailSANs:
- description: EmailSANs is a list of email subjectAltNames to be set
- on the Certificate.
- items:
- type: string
- type: array
- encodeUsagesInRequest:
- description: EncodeUsagesInRequest controls whether key usages should
- be present in the CertificateRequest
- type: boolean
- ipAddresses:
- description: IPAddresses is a list of IP address subjectAltNames to
- be set on the Certificate.
- items:
- type: string
- type: array
- isCA:
- description: IsCA will mark this Certificate as valid for certificate
- signing. This will automatically add the `cert sign` usage to the
- list of `usages`.
- type: boolean
- issuerRef:
- description: IssuerRef is a reference to the issuer for this certificate.
- If the `kind` field is not set, or set to `Issuer`, an Issuer resource
- with the given name in the same namespace as the Certificate will
- be used. If the `kind` field is set to `ClusterIssuer`, a ClusterIssuer
- with the provided name will be used. The `name` field in this stanza
- is required at all times.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
- type: string
- name:
- description: Name of the resource being referred to.
- type: string
- required:
- - name
- type: object
- keystores:
- description: Keystores configures additional keystore output formats
- stored in the `secretName` Secret resource.
- properties:
- jks:
- description: JKS configures options for storing a JKS keystore
- in the `spec.secretName` Secret resource.
- properties:
- create:
- description: Create enables JKS keystore creation for the
- Certificate. If true, a file named `keystore.jks` will be
- created in the target Secret resource, encrypted using the
- password stored in `passwordSecretRef`. The keystore file
- will only be updated upon re-issuance.
- type: boolean
- passwordSecretRef:
- description: PasswordSecretRef is a reference to a key in
- a Secret resource containing the password used to encrypt
- the JKS keystore.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this field
- may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred to.
- More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - create
- - passwordSecretRef
- type: object
- pkcs12:
- description: PKCS12 configures options for storing a PKCS12 keystore
- in the `spec.secretName` Secret resource.
+ - status
+ - type
properties:
- create:
- description: Create enables PKCS12 keystore creation for the
- Certificate. If true, a file named `keystore.p12` will be
- created in the target Secret resource, encrypted using the
- password stored in `passwordSecretRef`. The keystore file
- will only be updated upon re-issuance.
- type: boolean
- passwordSecretRef:
- description: PasswordSecretRef is a reference to a key in
- a Secret resource containing the password used to encrypt
- the PKCS12 keystore.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this field
- may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred to.
- More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - create
- - passwordSecretRef
- type: object
- type: object
- privateKey:
- description: Options to control private keys used for the Certificate.
- properties:
- algorithm:
- description: Algorithm is the private key algorithm of the corresponding
- private key for this certificate. If provided, allowed values
- are either `RSA` or `ECDSA` If `algorithm` is specified and
- `size` is not provided, key size of 256 will be used for `ECDSA`
- key algorithm and key size of 2048 will be used for `RSA` key
- algorithm.
- enum:
- - RSA
- - ECDSA
- type: string
- encoding:
- description: The private key cryptography standards (PKCS) encoding
- for this certificate's private key to be encoded in. If provided,
- allowed values are `PKCS1` and `PKCS8` standing for PKCS#1 and
- PKCS#8, respectively. Defaults to `PKCS1` if not specified.
- enum:
- - PKCS1
- - PKCS8
- type: string
- rotationPolicy:
- description: RotationPolicy controls how private keys should be
- regenerated when a re-issuance is being processed. If set to
- Never, a private key will only be generated if one does not
- already exist in the target `spec.secretName`. If one does exists
- but it does not have the correct algorithm or size, a warning
- will be raised to await user intervention. If set to Always,
- a private key matching the specified requirements will be generated
- whenever a re-issuance occurs. Default is 'Never' for backward
- compatibility.
- type: string
- size:
- description: Size is the key bit size of the corresponding private
- key for this certificate. If `algorithm` is set to `RSA`, valid
- values are `2048`, `4096` or `8192`, and will default to `2048`
- if not specified. If `algorithm` is set to `ECDSA`, valid values
- are `256`, `384` or `521`, and will default to `256` if not
- specified. No other values are allowed.
- type: integer
- type: object
- renewBefore:
- description: The amount of time before the currently issued certificate's
- `notAfter` time that cert-manager will begin to attempt to renew
- the certificate. If this value is greater than the total duration
- of the certificate (i.e. notAfter - notBefore), it will be automatically
- renewed 2/3rds of the way through the certificate's duration.
- type: string
- revisionHistoryLimit:
- description: revisionHistoryLimit is the maximum number of CertificateRequest
- revisions that are maintained in the Certificate's history. Each
- revision represents a single `CertificateRequest` created by this
- Certificate, either when it was created, renewed, or Spec was changed.
- Revisions will be removed by oldest first if the number of revisions
- exceeds this number. If set, revisionHistoryLimit must be a value
- of `1` or greater. If unset (`nil`), revisions will not be garbage
- collected. Default value is `nil`.
- format: int32
- type: integer
- secretName:
- description: SecretName is the name of the secret resource that will
- be automatically created and managed by this Certificate resource.
- It will be populated with a private key and certificate, signed
- by the denoted issuer.
- type: string
- subject:
- description: Full X509 name specification (https://golang.org/pkg/crypto/x509/pkix/#Name).
- properties:
- countries:
- description: Countries to be used on the Certificate.
- items:
- type: string
- type: array
- localities:
- description: Cities to be used on the Certificate.
- items:
- type: string
- type: array
- organizationalUnits:
- description: Organizational Units to be used on the Certificate.
- items:
- type: string
- type: array
- organizations:
- description: Organizations to be used on the Certificate.
- items:
- type: string
- type: array
- postalCodes:
- description: Postal codes to be used on the Certificate.
- items:
- type: string
- type: array
- provinces:
- description: State/Provinces to be used on the Certificate.
- items:
- type: string
- type: array
- serialNumber:
- description: Serial number to be used on the Certificate.
- type: string
- streetAddresses:
- description: Street addresses to be used on the Certificate.
- items:
- type: string
- type: array
- type: object
- uriSANs:
- description: URISANs is a list of URI subjectAltNames to be set on
- the Certificate.
- items:
- type: string
- type: array
- usages:
- description: Usages is the set of x509 usages that are requested for
- the certificate. Defaults to `digital signature` and `key encipherment`
- if not specified.
- items:
- description: 'KeyUsage specifies valid usage contexts for keys.
- See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12
- Valid KeyUsage values are as follows: "signing", "digital signature",
- "content commitment", "key encipherment", "key agreement", "data
- encipherment", "cert sign", "crl sign", "encipher only", "decipher
- only", "any", "server auth", "client auth", "code signing", "email
- protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec
- user", "timestamping", "ocsp signing", "microsoft sgc", "netscape
- sgc"'
- enum:
- - signing
- - digital signature
- - content commitment
- - key encipherment
- - key agreement
- - data encipherment
- - cert sign
- - crl sign
- - encipher only
- - decipher only
- - any
- - server auth
- - client auth
- - code signing
- - email protection
- - s/mime
- - ipsec end system
- - ipsec tunnel
- - ipsec user
- - timestamping
- - ocsp signing
- - microsoft sgc
- - netscape sgc
- type: string
- type: array
- required:
- - issuerRef
- - secretName
- type: object
- status:
- description: Status of the Certificate. This is set and managed automatically.
- properties:
- conditions:
- description: List of status conditions to indicate the status of certificates.
- Known condition types are `Ready` and `Issuing`.
- items:
- description: CertificateCondition contains condition information
- for an Certificate.
- properties:
- lastTransitionTime:
- description: LastTransitionTime is the timestamp corresponding
- to the last status change of this condition.
- format: date-time
- type: string
- message:
- description: Message is a human readable description of the
- details of the last transition, complementing reason.
- type: string
- observedGeneration:
- description: If set, this represents the .metadata.generation
- that the condition was set based upon. For instance, if .metadata.generation
- is currently 12, but the .status.condition[x].observedGeneration
- is 9, the condition is out of date with respect to the current
- state of the Certificate.
- format: int64
- type: integer
- reason:
- description: Reason is a brief machine readable explanation
- for the condition's last transition.
- type: string
- status:
- description: Status of the condition, one of (`True`, `False`,
- `Unknown`).
- enum:
- - "True"
- - "False"
- - Unknown
- type: string
- type:
- description: Type of the condition, known values are (`Ready`,
- `Issuing`).
- type: string
- required:
- - status
- - type
- type: object
- type: array
- lastFailureTime:
- description: LastFailureTime is the time as recorded by the Certificate
- controller of the most recent failure to complete a CertificateRequest
- for this Certificate resource. If set, cert-manager will not re-request
- another Certificate until 1 hour has elapsed from this time.
- format: date-time
- type: string
- nextPrivateKeySecretName:
- description: The name of the Secret resource containing the private
- key to be used for the next certificate iteration. The keymanager
- controller will automatically set this field if the `Issuing` condition
- is set to `True`. It will automatically unset this field when the
- Issuing condition is not set or False.
- type: string
- notAfter:
- description: The expiration time of the certificate stored in the
- secret named by this resource in `spec.secretName`.
- format: date-time
- type: string
- notBefore:
- description: The time after which the certificate stored in the secret
- named by this resource in spec.secretName is valid.
- format: date-time
- type: string
- renewalTime:
- description: RenewalTime is the time at which the certificate will
- be next renewed. If not set, no upcoming renewal is scheduled.
- format: date-time
- type: string
- revision:
- description: "The current 'revision' of the certificate as issued.
- \n When a CertificateRequest resource is created, it will have the
- `cert-manager.io/certificate-revision` set to one greater than the
- current value of this field. \n Upon issuance, this field will be
- set to the value of the annotation on the CertificateRequest resource
- used to issue the certificate. \n Persisting the value on the CertificateRequest
- resource allows the certificates controller to know whether a request
- is part of an old issuance or if it is part of the ongoing revision's
- issuance by checking if the revision value in the annotation is
- greater than this field."
- type: integer
- type: object
- required:
- - spec
- type: object
- served: true
- storage: false
- subresources:
- status: {}
- - additionalPrinterColumns:
- - jsonPath: .status.conditions[?(@.type=="Ready")].status
- name: Ready
- type: string
- - jsonPath: .spec.secretName
- name: Secret
- type: string
- - jsonPath: .spec.issuerRef.name
- name: Issuer
- priority: 1
- type: string
- - jsonPath: .status.conditions[?(@.type=="Ready")].message
- name: Status
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1
- schema:
- openAPIV3Schema:
- description: "A Certificate resource should be created to ensure an up to
- date and signed x509 certificate is stored in the Kubernetes Secret resource
- named in `spec.secretName`. \n The stored certificate will be renewed before
- it expires (as configured by `spec.renewBefore`)."
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- description: Desired state of the Certificate resource.
- properties:
- commonName:
- description: 'CommonName is a common name to be used on the Certificate.
- The CommonName should have a length of 64 characters or fewer to
- avoid generating invalid CSRs. This value is ignored by TLS clients
- when any subject alt name is set. This is x509 behaviour: https://tools.ietf.org/html/rfc6125#section-6.4.4'
- type: string
- dnsNames:
- description: DNSNames is a list of DNS subjectAltNames to be set on
- the Certificate.
- items:
+ lastTransitionTime:
+ description: LastTransitionTime is the timestamp corresponding to the last status change of this condition.
+ type: string
+ format: date-time
+ message:
+ description: Message is a human readable description of the details of the last transition, complementing reason.
+ type: string
+ observedGeneration:
+ description: If set, this represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.condition[x].observedGeneration is 9, the condition is out of date with respect to the current state of the Certificate.
+ type: integer
+ format: int64
+ reason:
+ description: Reason is a brief machine readable explanation for the condition's last transition.
+ type: string
+ status:
+ description: Status of the condition, one of (`True`, `False`, `Unknown`).
+ type: string
+ enum:
+ - "True"
+ - "False"
+ - Unknown
+ type:
+ description: Type of the condition, known values are (`Ready`, `Issuing`).
+ type: string
+ lastFailureTime:
+ description: LastFailureTime is the time as recorded by the Certificate controller of the most recent failure to complete a CertificateRequest for this Certificate resource. If set, cert-manager will not re-request another Certificate until 1 hour has elapsed from this time.
type: string
- type: array
- duration:
- description: The requested 'duration' (i.e. lifetime) of the Certificate.
- This option may be ignored/overridden by some issuer types. If unset
- this defaults to 90 days. If overridden and `renewBefore` is greater
- than the actual certificate duration, the certificate will be automatically
- renewed 2/3rds of the way through the certificate's duration.
- type: string
- emailAddresses:
- description: EmailAddresses is a list of email subjectAltNames to
- be set on the Certificate.
- items:
+ format: date-time
+ nextPrivateKeySecretName:
+ description: The name of the Secret resource containing the private key to be used for the next certificate iteration. The keymanager controller will automatically set this field if the `Issuing` condition is set to `True`. It will automatically unset this field when the Issuing condition is not set or False.
type: string
- type: array
- encodeUsagesInRequest:
- description: EncodeUsagesInRequest controls whether key usages should
- be present in the CertificateRequest
- type: boolean
- ipAddresses:
- description: IPAddresses is a list of IP address subjectAltNames to
- be set on the Certificate.
- items:
+ notAfter:
+ description: The expiration time of the certificate stored in the secret named by this resource in `spec.secretName`.
type: string
- type: array
- isCA:
- description: IsCA will mark this Certificate as valid for certificate
- signing. This will automatically add the `cert sign` usage to the
- list of `usages`.
- type: boolean
- issuerRef:
- description: IssuerRef is a reference to the issuer for this certificate.
- If the `kind` field is not set, or set to `Issuer`, an Issuer resource
- with the given name in the same namespace as the Certificate will
- be used. If the `kind` field is set to `ClusterIssuer`, a ClusterIssuer
- with the provided name will be used. The `name` field in this stanza
- is required at all times.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
- type: string
- name:
- description: Name of the resource being referred to.
- type: string
- required:
- - name
- type: object
- keystores:
- description: Keystores configures additional keystore output formats
- stored in the `secretName` Secret resource.
- properties:
- jks:
- description: JKS configures options for storing a JKS keystore
- in the `spec.secretName` Secret resource.
- properties:
- create:
- description: Create enables JKS keystore creation for the
- Certificate. If true, a file named `keystore.jks` will be
- created in the target Secret resource, encrypted using the
- password stored in `passwordSecretRef`. The keystore file
- will only be updated upon re-issuance. A file named `truststore.jks`
- will also be created in the target Secret resource, encrypted
- using the password stored in `passwordSecretRef` containing
- the issuing Certificate Authority
- type: boolean
- passwordSecretRef:
- description: PasswordSecretRef is a reference to a key in
- a Secret resource containing the password used to encrypt
- the JKS keystore.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this field
- may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred to.
- More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - create
- - passwordSecretRef
- type: object
- pkcs12:
- description: PKCS12 configures options for storing a PKCS12 keystore
- in the `spec.secretName` Secret resource.
- properties:
- create:
- description: Create enables PKCS12 keystore creation for the
- Certificate. If true, a file named `keystore.p12` will be
- created in the target Secret resource, encrypted using the
- password stored in `passwordSecretRef`. The keystore file
- will only be updated upon re-issuance. A file named `truststore.p12`
- will also be created in the target Secret resource, encrypted
- using the password stored in `passwordSecretRef` containing
- the issuing Certificate Authority
- type: boolean
- passwordSecretRef:
- description: PasswordSecretRef is a reference to a key in
- a Secret resource containing the password used to encrypt
- the PKCS12 keystore.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this field
- may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred to.
- More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - create
- - passwordSecretRef
- type: object
- type: object
- privateKey:
- description: Options to control private keys used for the Certificate.
- properties:
- algorithm:
- description: Algorithm is the private key algorithm of the corresponding
- private key for this certificate. If provided, allowed values
- are either `RSA` or `ECDSA` If `algorithm` is specified and
- `size` is not provided, key size of 256 will be used for `ECDSA`
- key algorithm and key size of 2048 will be used for `RSA` key
- algorithm.
- enum:
- - RSA
- - ECDSA
- type: string
- encoding:
- description: The private key cryptography standards (PKCS) encoding
- for this certificate's private key to be encoded in. If provided,
- allowed values are `PKCS1` and `PKCS8` standing for PKCS#1 and
- PKCS#8, respectively. Defaults to `PKCS1` if not specified.
- enum:
- - PKCS1
- - PKCS8
- type: string
- rotationPolicy:
- description: RotationPolicy controls how private keys should be
- regenerated when a re-issuance is being processed. If set to
- Never, a private key will only be generated if one does not
- already exist in the target `spec.secretName`. If one does exists
- but it does not have the correct algorithm or size, a warning
- will be raised to await user intervention. If set to Always,
- a private key matching the specified requirements will be generated
- whenever a re-issuance occurs. Default is 'Never' for backward
- compatibility.
- type: string
- size:
- description: Size is the key bit size of the corresponding private
- key for this certificate. If `algorithm` is set to `RSA`, valid
- values are `2048`, `4096` or `8192`, and will default to `2048`
- if not specified. If `algorithm` is set to `ECDSA`, valid values
- are `256`, `384` or `521`, and will default to `256` if not
- specified. No other values are allowed.
- type: integer
- type: object
- renewBefore:
- description: The amount of time before the currently issued certificate's
- `notAfter` time that cert-manager will begin to attempt to renew
- the certificate. If unset this defaults to 30 days. If this value
- is greater than the total duration of the certificate (i.e. notAfter
- - notBefore), it will be automatically renewed 2/3rds of the way
- through the certificate's duration.
- type: string
- revisionHistoryLimit:
- description: revisionHistoryLimit is the maximum number of CertificateRequest
- revisions that are maintained in the Certificate's history. Each
- revision represents a single `CertificateRequest` created by this
- Certificate, either when it was created, renewed, or Spec was changed.
- Revisions will be removed by oldest first if the number of revisions
- exceeds this number. If set, revisionHistoryLimit must be a value
- of `1` or greater. If unset (`nil`), revisions will not be garbage
- collected. Default value is `nil`.
- format: int32
- type: integer
- secretName:
- description: SecretName is the name of the secret resource that will
- be automatically created and managed by this Certificate resource.
- It will be populated with a private key and certificate, signed
- by the denoted issuer.
- type: string
- subject:
- description: Full X509 name specification (https://golang.org/pkg/crypto/x509/pkix/#Name).
- properties:
- countries:
- description: Countries to be used on the Certificate.
- items:
- type: string
- type: array
- localities:
- description: Cities to be used on the Certificate.
- items:
- type: string
- type: array
- organizationalUnits:
- description: Organizational Units to be used on the Certificate.
- items:
- type: string
- type: array
- organizations:
- description: Organizations to be used on the Certificate.
- items:
- type: string
- type: array
- postalCodes:
- description: Postal codes to be used on the Certificate.
- items:
- type: string
- type: array
- provinces:
- description: State/Provinces to be used on the Certificate.
- items:
- type: string
- type: array
- serialNumber:
- description: Serial number to be used on the Certificate.
- type: string
- streetAddresses:
- description: Street addresses to be used on the Certificate.
- items:
- type: string
- type: array
- type: object
- uris:
- description: URIs is a list of URI subjectAltNames to be set on the
- Certificate.
- items:
+ format: date-time
+ notBefore:
+ description: The time after which the certificate stored in the secret named by this resource in spec.secretName is valid.
type: string
- type: array
- usages:
- description: Usages is the set of x509 usages that are requested for
- the certificate. Defaults to `digital signature` and `key encipherment`
- if not specified.
- items:
- description: 'KeyUsage specifies valid usage contexts for keys.
- See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 https://tools.ietf.org/html/rfc5280#section-4.2.1.12
- Valid KeyUsage values are as follows: "signing", "digital signature",
- "content commitment", "key encipherment", "key agreement", "data
- encipherment", "cert sign", "crl sign", "encipher only", "decipher
- only", "any", "server auth", "client auth", "code signing", "email
- protection", "s/mime", "ipsec end system", "ipsec tunnel", "ipsec
- user", "timestamping", "ocsp signing", "microsoft sgc", "netscape
- sgc"'
- enum:
- - signing
- - digital signature
- - content commitment
- - key encipherment
- - key agreement
- - data encipherment
- - cert sign
- - crl sign
- - encipher only
- - decipher only
- - any
- - server auth
- - client auth
- - code signing
- - email protection
- - s/mime
- - ipsec end system
- - ipsec tunnel
- - ipsec user
- - timestamping
- - ocsp signing
- - microsoft sgc
- - netscape sgc
+ format: date-time
+ renewalTime:
+ description: RenewalTime is the time at which the certificate will be next renewed. If not set, no upcoming renewal is scheduled.
type: string
- type: array
- required:
- - issuerRef
- - secretName
- type: object
- status:
- description: Status of the Certificate. This is set and managed automatically.
- properties:
- conditions:
- description: List of status conditions to indicate the status of certificates.
- Known condition types are `Ready` and `Issuing`.
- items:
- description: CertificateCondition contains condition information
- for an Certificate.
- properties:
- lastTransitionTime:
- description: LastTransitionTime is the timestamp corresponding
- to the last status change of this condition.
- format: date-time
- type: string
- message:
- description: Message is a human readable description of the
- details of the last transition, complementing reason.
- type: string
- observedGeneration:
- description: If set, this represents the .metadata.generation
- that the condition was set based upon. For instance, if .metadata.generation
- is currently 12, but the .status.condition[x].observedGeneration
- is 9, the condition is out of date with respect to the current
- state of the Certificate.
- format: int64
- type: integer
- reason:
- description: Reason is a brief machine readable explanation
- for the condition's last transition.
- type: string
- status:
- description: Status of the condition, one of (`True`, `False`,
- `Unknown`).
- enum:
- - "True"
- - "False"
- - Unknown
- type: string
- type:
- description: Type of the condition, known values are (`Ready`,
- `Issuing`).
- type: string
- required:
- - status
- - type
- type: object
- type: array
- lastFailureTime:
- description: LastFailureTime is the time as recorded by the Certificate
- controller of the most recent failure to complete a CertificateRequest
- for this Certificate resource. If set, cert-manager will not re-request
- another Certificate until 1 hour has elapsed from this time.
- format: date-time
- type: string
- nextPrivateKeySecretName:
- description: The name of the Secret resource containing the private
- key to be used for the next certificate iteration. The keymanager
- controller will automatically set this field if the `Issuing` condition
- is set to `True`. It will automatically unset this field when the
- Issuing condition is not set or False.
- type: string
- notAfter:
- description: The expiration time of the certificate stored in the
- secret named by this resource in `spec.secretName`.
- format: date-time
- type: string
- notBefore:
- description: The time after which the certificate stored in the secret
- named by this resource in spec.secretName is valid.
- format: date-time
- type: string
- renewalTime:
- description: RenewalTime is the time at which the certificate will
- be next renewed. If not set, no upcoming renewal is scheduled.
- format: date-time
- type: string
- revision:
- description: "The current 'revision' of the certificate as issued.
- \n When a CertificateRequest resource is created, it will have the
- `cert-manager.io/certificate-revision` set to one greater than the
- current value of this field. \n Upon issuance, this field will be
- set to the value of the annotation on the CertificateRequest resource
- used to issue the certificate. \n Persisting the value on the CertificateRequest
- resource allows the certificates controller to know whether a request
- is part of an old issuance or if it is part of the ongoing revision's
- issuance by checking if the revision value in the annotation is
- greater than this field."
- type: integer
- type: object
- required:
- - spec
- type: object
- served: true
- storage: true
- subresources:
- status: {}
-status:
- acceptedNames:
- kind: ""
- plural: ""
- conditions: []
- storedVersions: []
+ format: date-time
+ revision:
+ description: "The current 'revision' of the certificate as issued. \n When a CertificateRequest resource is created, it will have the `cert-manager.io/certificate-revision` set to one greater than the current value of this field. \n Upon issuance, this field will be set to the value of the annotation on the CertificateRequest resource used to issue the certificate. \n Persisting the value on the CertificateRequest resource allows the certificates controller to know whether a request is part of an old issuance or if it is part of the ongoing revision's issuance by checking if the revision value in the annotation is greater than this field."
+ type: integer
+ served: true
+ storage: true
---
+# Source: cert-manager/templates/templates.out
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
+ name: challenges.acme.cert-manager.io
annotations:
- cert-manager.io/inject-ca-from-secret: cert-manager/cert-manager-webhook-ca
+ cert-manager.io/inject-ca-from-secret: 'cert-manager/cert-manager-webhook-ca'
labels:
- app: cert-manager
- app.kubernetes.io/instance: cert-manager
- app.kubernetes.io/name: cert-manager
- name: challenges.acme.cert-manager.io
+ app: 'cert-manager'
+ app.kubernetes.io/name: 'cert-manager'
+ app.kubernetes.io/instance: 'cert-manager'
+ # Generated labels
+ app.kubernetes.io/version: "v1.7.1"
spec:
- conversion:
- strategy: Webhook
- webhook:
- clientConfig:
- service:
- name: cert-manager-webhook
- namespace: cert-manager
- path: /convert
- conversionReviewVersions:
- - v1
- - v1beta1
group: acme.cert-manager.io
names:
- categories:
- - cert-manager
- - cert-manager-acme
kind: Challenge
listKind: ChallengeList
plural: challenges
singular: challenge
+ categories:
+ - cert-manager
+ - cert-manager-acme
scope: Namespaced
versions:
- - additionalPrinterColumns:
- - jsonPath: .status.state
- name: State
- type: string
- - jsonPath: .spec.dnsName
- name: Domain
- type: string
- - jsonPath: .status.reason
- name: Reason
- priority: 1
- type: string
- - description: CreationTimestamp is a timestamp representing the server time when
- this object was created. It is not guaranteed to be set in happens-before
- order across separate operations. Clients may not set this value. It is represented
- in RFC3339 form and is in UTC.
- jsonPath: .metadata.creationTimestamp
- name: Age
- type: date
- name: v1alpha2
- schema:
- openAPIV3Schema:
- description: Challenge is a type to represent a Challenge request with an
- ACME server
- properties:
- apiVersion:
- description: 'APIVersion defines the versioned schema of this representation
- of an object. Servers should convert recognized schemas to the latest
- internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
- type: string
- kind:
- description: 'Kind is a string value representing the REST resource this
- object represents. Servers may infer this from the endpoint the client
- submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
- type: string
- metadata:
- type: object
- spec:
- properties:
- authzURL:
- description: AuthzURL is the URL to the ACME Authorization resource
- that this challenge is a part of.
- type: string
- dnsName:
- description: DNSName is the identifier that this challenge is for,
- e.g. example.com. If the requested DNSName is a 'wildcard', this
- field MUST be set to the non-wildcard domain, e.g. for `*.example.com`,
- it must be `example.com`.
- type: string
- issuerRef:
- description: IssuerRef references a properly configured ACME-type
- Issuer which should be used to create this Challenge. If the Issuer
- does not exist, processing will be retried. If the Issuer is not
- an 'ACME' Issuer, an error will be returned and the Challenge will
- be marked as failed.
- properties:
- group:
- description: Group of the resource being referred to.
- type: string
- kind:
- description: Kind of the resource being referred to.
- type: string
- name:
- description: Name of the resource being referred to.
- type: string
- required:
- - name
- type: object
- key:
- description: 'Key is the ACME challenge key for this challenge For
- HTTP01 challenges, this is the value that must be responded with
- to complete the HTTP01 challenge in the format: `.`. For DNS01 challenges,
- this is the base64 encoded SHA256 sum of the `.` text that must be set as the TXT
- record content.'
- type: string
- solver:
- description: Solver contains the domain solving configuration that
- should be used to solve this challenge resource.
- properties:
- dns01:
- description: Configures cert-manager to attempt to complete authorizations
- by performing the DNS01 challenge flow.
- properties:
- acmedns:
- description: Use the 'ACME DNS' (https://github.com/joohoi/acme-dns)
- API to manage DNS01 challenge records.
- properties:
- accountSecretRef:
- description: A reference to a specific 'key' within a
- Secret resource. In some instances, `key` is a required
- field.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- host:
- type: string
- required:
- - accountSecretRef
- - host
- type: object
- akamai:
- description: Use the Akamai DNS zone management API to manage
- DNS01 challenge records.
- properties:
- accessTokenSecretRef:
- description: A reference to a specific 'key' within a
- Secret resource. In some instances, `key` is a required
- field.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- clientSecretSecretRef:
- description: A reference to a specific 'key' within a
- Secret resource. In some instances, `key` is a required
- field.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- clientTokenSecretRef:
- description: A reference to a specific 'key' within a
- Secret resource. In some instances, `key` is a required
- field.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- serviceConsumerDomain:
- type: string
- required:
- - accessTokenSecretRef
- - clientSecretSecretRef
- - clientTokenSecretRef
- - serviceConsumerDomain
- type: object
- azuredns:
- description: Use the Microsoft Azure DNS API to manage DNS01
- challenge records.
- properties:
- clientID:
- description: if both this and ClientSecret are left unset
- MSI will be used
- type: string
- clientSecretSecretRef:
- description: if both this and ClientID are left unset
- MSI will be used
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- environment:
- enum:
- - AzurePublicCloud
- - AzureChinaCloud
- - AzureGermanCloud
- - AzureUSGovernmentCloud
- type: string
- hostedZoneName:
- type: string
- resourceGroupName:
- type: string
- subscriptionID:
- type: string
- tenantID:
- description: when specifying ClientID and ClientSecret
- then this field is also needed
- type: string
- required:
- - resourceGroupName
- - subscriptionID
- type: object
- clouddns:
- description: Use the Google Cloud DNS API to manage DNS01
- challenge records.
- properties:
- hostedZoneName:
- description: HostedZoneName is an optional field that
- tells cert-manager in which Cloud DNS zone the challenge
- record has to be created. If left empty cert-manager
- will automatically choose a zone.
- type: string
- project:
- type: string
- serviceAccountSecretRef:
- description: A reference to a specific 'key' within a
- Secret resource. In some instances, `key` is a required
- field.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - project
- type: object
- cloudflare:
- description: Use the Cloudflare API to manage DNS01 challenge
- records.
- properties:
- apiKeySecretRef:
- description: 'API key to use to authenticate with Cloudflare.
- Note: using an API token to authenticate is now the
- recommended method as it allows greater control of permissions.'
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- apiTokenSecretRef:
- description: API token used to authenticate with Cloudflare.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- email:
- description: Email of the account, only required when
- using API key based authentication.
- type: string
- type: object
- cnameStrategy:
- description: CNAMEStrategy configures how the DNS01 provider
- should handle CNAME records when found in DNS zones.
- enum:
- - None
- - Follow
- type: string
- digitalocean:
- description: Use the DigitalOcean DNS API to manage DNS01
- challenge records.
- properties:
- tokenSecretRef:
- description: A reference to a specific 'key' within a
- Secret resource. In some instances, `key` is a required
- field.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - tokenSecretRef
- type: object
- rfc2136:
- description: Use RFC2136 ("Dynamic Updates in the Domain Name
- System") (https://datatracker.ietf.org/doc/rfc2136/) to
- manage DNS01 challenge records.
- properties:
- nameserver:
- description: The IP address or hostname of an authoritative
- DNS server supporting RFC2136 in the form host:port.
- If the host is an IPv6 address it must be enclosed in
- square brackets (e.g [2001:db8::1]) ; port is optional.
- This field is required.
- type: string
- tsigAlgorithm:
- description: 'The TSIG Algorithm configured in the DNS
- supporting RFC2136. Used only when ``tsigSecretSecretRef``
- and ``tsigKeyName`` are defined. Supported values are
- (case-insensitive): ``HMACMD5`` (default), ``HMACSHA1``,
- ``HMACSHA256`` or ``HMACSHA512``.'
- type: string
- tsigKeyName:
- description: The TSIG Key name configured in the DNS.
- If ``tsigSecretSecretRef`` is defined, this field is
- required.
- type: string
- tsigSecretSecretRef:
- description: The name of the secret containing the TSIG
- value. If ``tsigKeyName`` is defined, this field is
- required.
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - nameserver
- type: object
- route53:
- description: Use the AWS Route53 API to manage DNS01 challenge
- records.
- properties:
- accessKeyID:
- description: 'The AccessKeyID is used for authentication.
- If not set we fall-back to using env vars, shared credentials
- file or AWS Instance metadata see: https://docs.aws.amazon.com/sdk-for-go/v1/developer-guide/configuring-sdk.html#specifying-credentials'
- type: string
- hostedZoneID:
- description: If set, the provider will manage only this
- zone in Route53 and will not do an lookup using the
- route53:ListHostedZonesByName api call.
- type: string
- region:
- description: Always set the region when using AccessKeyID
- and SecretAccessKey
- type: string
- role:
- description: Role is a Role ARN which the Route53 provider
- will assume using either the explicit credentials AccessKeyID/SecretAccessKey
- or the inferred credentials from environment variables,
- shared credentials file or AWS Instance metadata
- type: string
- secretAccessKeySecretRef:
- description: The SecretAccessKey is used for authentication.
- If not set we fall-back to using env vars, shared credentials
- file or AWS Instance metadata https://docs.aws.amazon.com/sdk-for-go/v1/developer-guide/configuring-sdk.html#specifying-credentials
- properties:
- key:
- description: The key of the entry in the Secret resource's
- `data` field to be used. Some instances of this
- field may be defaulted, in others it may be required.
- type: string
- name:
- description: 'Name of the resource being referred
- to. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
- type: string
- required:
- - name
- type: object
- required:
- - region
- type: object
- webhook:
- description: Configure an external webhook based DNS01 challenge
- solver to manage DNS01 challenge records.
- properties:
- config:
- description: Additional configuration that should be passed
- to the webhook apiserver when challenges are processed.
- This can contain arbitrary JSON data. Secret values
- should not be specified in this stanza. If secret values
- are needed (e.g. credentials for a DNS service), you
- should use a SecretKeySelector to reference a Secret
- resource. For details on the schema of this field, consult
- the webhook provider implementation's documentation.
- x-kubernetes-preserve-unknown-fields: true
- groupName:
- description: The API group name that should be used when
- POSTing ChallengePayload resources to the webhook apiserver.
- This should be the same as the GroupName specified in
- the webhook provider implementation.
- type: string
- solverName:
- description: The name of the solver to use, as defined
- in the webhook provider implementation. This will typically
- be the name of the provider, e.g. 'cloudflare'.
- type: string
- required:
- - groupName
- - solverName
- type: object
- type: object
- http01:
- description: Configures cert-manager to attempt to complete authorizations
- by performing the HTTP01 challenge flow. It is not possible
- to obtain certificates for wildcard domain names (e.g. `*.example.com`)
- using the HTTP01 challenge mechanism.
- properties:
- ingress:
- description: The ingress based HTTP01 challenge solver will
- solve challenges by creating or modifying Ingress resources
- in order to route requests for '/.well-known/acme-challenge/XYZ'
- to 'challenge solver' pods that are provisioned by cert-manager
- for each Challenge to be completed.
- properties:
- class:
- description: The ingress class to use when creating Ingress
- resources to solve ACME challenges that use this challenge
- solver. Only one of 'class' or 'name' may be specified.
- type: string
- ingressTemplate:
- description: Optional ingress template used to configure
- the ACME challenge solver ingress used for HTTP01 challenges
- properties:
- metadata:
- description: ObjectMeta overrides for the ingress
- used to solve HTTP01 challenges. Only the 'labels'
- and 'annotations' fields may be set. If labels or
- annotations overlap with in-built values, the values
- here will override the in-built values.
- properties:
- annotations:
- additionalProperties:
- type: string
- description: Annotations that should be added
- to the created ACME HTTP01 solver ingress.
- type: object
- labels:
- additionalProperties:
- type: string
- description: Labels that should be added to the
- created ACME HTTP01 solver ingress.
- type: object
- type: object
- type: object
- name:
- description: The name of the ingress resource that should
- have ACME challenge solving routes inserted into it
- in order to solve HTTP01 challenges. This is typically
- used in conjunction with ingress controllers like ingress-gce,
- which maintains a 1:1 mapping between external IPs and
- ingress resources.
- type: string
- podTemplate:
- description: Optional pod template used to configure the
- ACME challenge solver pods used for HTTP01 challenges
- properties:
- metadata:
- description: ObjectMeta overrides for the pod used
- to solve HTTP01 challenges. Only the 'labels' and
- 'annotations' fields may be set. If labels or annotations
- overlap with in-built values, the values here will
- override the in-built values.
- properties:
- annotations:
- additionalProperties:
- type: string
- description: Annotations that should be added
- to the create ACME HTTP01 solver pods.
- type: object
- labels:
- additionalProperties:
- type: string
- description: Labels that should be added to the
- created ACME HTTP01 solver pods.
- type: object
- type: object
- spec:
- description: PodSpec defines overrides for the HTTP01
- challenge solver pod. Only the 'priorityClassName',
- 'nodeSelector', 'affinity', 'serviceAccountName'
- and 'tolerations' fields are supported currently.
- All other fields will be ignored.
- properties:
- affinity:
- description: If specified, the pod's scheduling
- constraints
- properties:
- nodeAffinity:
- description: Describes node affinity scheduling
- rules for the pod.
- properties:
- preferredDuringSchedulingIgnoredDuringExecution:
- description: The scheduler will prefer
- to schedule pods to nodes that satisfy
- the affinity expressions specified by
- this field, but it may choose a node
- that violates one or more of the expressions.
- The node that is most preferred is the
- one with the greatest sum of weights,
- i.e. for each node that meets all of
- the scheduling requirements (resource
- request, requiredDuringScheduling affinity
- expressions, etc.), compute a sum by
- iterating through the elements of this
- field and adding "weight" to the sum
- if the node matches the corresponding
- matchExpressions; the node(s) with the
- highest sum are the most preferred.
- items:
- description: An empty preferred scheduling
- term matches all objects with implicit
- weight 0 (i.e. it's a no-op). A null
- preferred scheduling term matches
- no objects (i.e. is also a no-op).
- properties:
- preference:
- description: A node selector term,
- associated with the corresponding
- weight.
- properties:
- matchExpressions:
- description: A list of node
- selector requirements by node's
- labels.
- items:
- description: A node selector
- requirement is a selector
- that contains values, a
- key, and an operator that
- relates the key and values.
- properties:
- key:
- description: The label
- key that the selector
- applies to.
- type: string
- operator:
- description: Represents
- a key's relationship
- to a set of values.
- Valid operators are
- In, NotIn, Exists, DoesNotExist.
- Gt, and Lt.
- type: string
- values:
- description: An array
- of string values. If
- the operator is In or
- NotIn, the values array
- must be non-empty. If
- the operator is Exists
- or DoesNotExist, the
- values array must be
- empty. If the operator
- is Gt or Lt, the values
- array must have a single
- element, which will
- be interpreted as an
- integer. This array
- is replaced during a
- strategic merge patch.
- items:
+ - additionalPrinterColumns:
+ - jsonPath: .status.state
+ name: State
+ type: string
+ - jsonPath: .spec.dnsName
+ name: Domain
+ type: string
+ - jsonPath: .status.reason
+ name: Reason
+ priority: 1
+ type: string
+ - description: CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.
+ jsonPath: .metadata.creationTimestamp
+ name: Age
+ type: date
+ name: v1
+ schema:
+ openAPIV3Schema:
+ description: Challenge is a type to represent a Challenge request with an ACME server
+ type: object
+ required:
+ - metadata
+ - spec
+ properties:
+ apiVersion:
+ description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
+ type: string
+ kind:
+ description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
+ type: string
+ metadata:
+ type: object
+ spec:
+ type: object
+ required:
+ - authorizationURL
+ - dnsName
+ - issuerRef
+ - key
+ - solver
+ - token
+ - type
+ - url
+ properties:
+ authorizationURL:
+ description: The URL to the ACME Authorization resource that this challenge is a part of.
+ type: string
+ dnsName:
+ description: dnsName is the identifier that this challenge is for, e.g. example.com. If the requested DNSName is a 'wildcard', this field MUST be set to the non-wildcard domain, e.g. for `*.example.com`, it must be `example.com`.
+ type: string
+ issuerRef:
+ description: References a properly configured ACME-type Issuer which should be used to create this Challenge. If the Issuer does not exist, processing will be retried. If the Issuer is not an 'ACME' Issuer, an error will be returned and the Challenge will be marked as failed.
+ type: object
+ required:
+ - name
+ properties:
+ group:
+ description: Group of the resource being referred to.
+ type: string
+ kind:
+ description: Kind of the resource being referred to.
+ type: string
+ name:
+ description: Name of the resource being referred to.
+ type: string
+ key:
+ description: 'The ACME challenge key for this challenge For HTTP01 challenges, this is the value that must be responded with to complete the HTTP01 challenge in the format: ` |