Skip to content

Commit 2e20e95

Browse files
author
awstools
committed
feat(client-iam): Make the LastUsedDate field in the GetAccessKeyLastUsed response optional. This may break customers who only call the API for access keys with a valid LastUsedDate. This fixes a deserialization issue for access keys without a LastUsedDate, because the field was marked as required but could be null.
1 parent e56be69 commit 2e20e95

File tree

6 files changed

+24
-25
lines changed

6 files changed

+24
-25
lines changed

clients/client-iam/src/commands/CreateOpenIDConnectProviderCommand.ts

+7-7
Original file line numberDiff line numberDiff line change
@@ -60,12 +60,11 @@ export interface CreateOpenIDConnectProviderCommandOutput
6060
* <p>You get all of this information from the OIDC IdP you want to use to access
6161
* Amazon Web Services.</p>
6262
* <note>
63-
* <p>Amazon Web Services secures communication with some OIDC identity providers (IdPs) through our library
64-
* of trusted root certificate authorities (CAs) instead of using a certificate thumbprint to
65-
* verify your IdP server certificate. In these cases, your legacy thumbprint remains in your
66-
* configuration, but is no longer used for validation. These OIDC IdPs include Auth0, GitHub,
67-
* GitLab, Google, and those that use an Amazon S3 bucket to host a JSON Web Key Set (JWKS)
68-
* endpoint.</p>
63+
* <p>Amazon Web Services secures communication with OIDC identity providers (IdPs) using our library of
64+
* trusted root certificate authorities (CAs) to verify the JSON Web Key Set (JWKS)
65+
* endpoint's TLS certificate. If your OIDC IdP relies on a certificate that is not signed
66+
* by one of these trusted CAs, only then we secure communication using the thumbprints set
67+
* in the IdP's configuration.</p>
6968
* </note>
7069
* <note>
7170
* <p>The trust for the OIDC provider is derived from the IAM provider that this
@@ -130,7 +129,8 @@ export interface CreateOpenIDConnectProviderCommandOutput
130129
* Amazon Web Services account limits. The error message describes the limit exceeded.</p>
131130
*
132131
* @throws {@link OpenIdIdpCommunicationErrorException} (client fault)
133-
* <p>The request failed because IAM cannot connect to the OpenID Connect identity provider URL.</p>
132+
* <p>The request failed because IAM cannot connect to the OpenID Connect identity provider
133+
* URL.</p>
134134
*
135135
* @throws {@link ServiceFailureException} (server fault)
136136
* <p>The request processing has failed because of an unknown error, exception or

clients/client-iam/src/commands/GetAccessKeyLastUsedCommand.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ export interface GetAccessKeyLastUsedCommandOutput extends GetAccessKeyLastUsedR
4545
* // { // GetAccessKeyLastUsedResponse
4646
* // UserName: "STRING_VALUE",
4747
* // AccessKeyLastUsed: { // AccessKeyLastUsed
48-
* // LastUsedDate: new Date("TIMESTAMP"), // required
48+
* // LastUsedDate: new Date("TIMESTAMP"),
4949
* // ServiceName: "STRING_VALUE", // required
5050
* // Region: "STRING_VALUE", // required
5151
* // },

clients/client-iam/src/commands/ListAccountAliasesCommand.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ export interface ListAccountAliasesCommandOutput extends ListAccountAliasesRespo
2929

3030
/**
3131
* <p>Lists the account alias associated with the Amazon Web Services account (Note: you can have only
32-
* one). For information about using an Amazon Web Services account alias, see <a href="https://docs.aws.amazon.com/signin/latest/userguide/CreateAccountAlias.html">Creating,
33-
* deleting, and listing an Amazon Web Services account alias</a> in the <i>Amazon Web Services Sign-In
34-
* User Guide</i>.</p>
32+
* one). For information about using an Amazon Web Services account alias, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/console_account-alias.html#CreateAccountAlias">Creating,
33+
* deleting, and listing an Amazon Web Services account alias</a> in the
34+
* <i>IAM User Guide</i>.</p>
3535
* @example
3636
* Use a bare-bones client and the command you need to make an API call.
3737
* ```javascript

clients/client-iam/src/commands/UpdateOpenIDConnectProviderThumbprintCommand.ts

+5-6
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,11 @@ export interface UpdateOpenIDConnectProviderThumbprintCommandOutput extends __Me
4242
* the OIDC provider as a principal fails until the certificate thumbprint is
4343
* updated.</p>
4444
* <note>
45-
* <p>Amazon Web Services secures communication with some OIDC identity providers (IdPs) through our library
46-
* of trusted root certificate authorities (CAs) instead of using a certificate thumbprint to
47-
* verify your IdP server certificate. In these cases, your legacy thumbprint remains in your
48-
* configuration, but is no longer used for validation. These OIDC IdPs include Auth0, GitHub,
49-
* GitLab, Google, and those that use an Amazon S3 bucket to host a JSON Web Key Set (JWKS)
50-
* endpoint.</p>
45+
* <p>Amazon Web Services secures communication with OIDC identity providers (IdPs) using our library of
46+
* trusted root certificate authorities (CAs) to verify the JSON Web Key Set (JWKS)
47+
* endpoint's TLS certificate. If your OIDC IdP relies on a certificate that is not signed
48+
* by one of these trusted CAs, only then we secure communication using the thumbprints set
49+
* in the IdP's configuration.</p>
5150
* </note>
5251
* <note>
5352
* <p>Trust for the OIDC provider is derived from the provider certificate and is

clients/client-iam/src/models/models_0.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ export interface AccessKeyLastUsed {
163163
* </ul>
164164
* @public
165165
*/
166-
LastUsedDate: Date | undefined;
166+
LastUsedDate?: Date;
167167

168168
/**
169169
* <p>The name of the Amazon Web Services service with which this access key was most recently used. The
@@ -1275,7 +1275,8 @@ export interface CreateOpenIDConnectProviderResponse {
12751275
}
12761276

12771277
/**
1278-
* <p>The request failed because IAM cannot connect to the OpenID Connect identity provider URL.</p>
1278+
* <p>The request failed because IAM cannot connect to the OpenID Connect identity provider
1279+
* URL.</p>
12791280
* @public
12801281
*/
12811282
export class OpenIdIdpCommunicationErrorException extends __BaseException {

codegen/sdk-codegen/aws-models/iam.json

+5-6
Original file line numberDiff line numberDiff line change
@@ -1995,8 +1995,7 @@
19951995
"LastUsedDate": {
19961996
"target": "com.amazonaws.iam#dateType",
19971997
"traits": {
1998-
"smithy.api#documentation": "<p>The date and time, in <a href=\"http://www.iso.org/iso/iso8601\">ISO 8601 date-time\n format</a>, when the access key was most recently used. This field is null in the\n following situations:</p>\n <ul>\n <li>\n <p>The user does not have an access key.</p>\n </li>\n <li>\n <p>An access key exists but has not been used since IAM began tracking this\n information.</p>\n </li>\n <li>\n <p>There is no sign-in data associated with the user.</p>\n </li>\n </ul>",
1999-
"smithy.api#required": {}
1998+
"smithy.api#documentation": "<p>The date and time, in <a href=\"http://www.iso.org/iso/iso8601\">ISO 8601 date-time\n format</a>, when the access key was most recently used. This field is null in the\n following situations:</p>\n <ul>\n <li>\n <p>The user does not have an access key.</p>\n </li>\n <li>\n <p>An access key exists but has not been used since IAM began tracking this\n information.</p>\n </li>\n <li>\n <p>There is no sign-in data associated with the user.</p>\n </li>\n </ul>"
20001999
}
20012000
},
20022001
"ServiceName": {
@@ -3140,7 +3139,7 @@
31403139
}
31413140
],
31423141
"traits": {
3143-
"smithy.api#documentation": "<p>Creates an IAM entity to describe an identity provider (IdP) that supports <a href=\"http://openid.net/connect/\">OpenID Connect (OIDC)</a>.</p>\n <p>The OIDC provider that you create with this operation can be used as a principal in a\n role's trust policy. Such a policy establishes a trust relationship between Amazon Web Services and\n the OIDC provider.</p>\n <p>If you are using an OIDC identity provider from Google, Facebook, or Amazon Cognito, you don't\n need to create a separate IAM identity provider. These OIDC identity providers are\n already built-in to Amazon Web Services and are available for your use. Instead, you can move directly\n to creating new roles using your identity provider. To learn more, see <a href=\"https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-idp_oidc.html\">Creating\n a role for web identity or OpenID connect federation</a> in the <i>IAM\n User Guide</i>.</p>\n <p>When you create the IAM OIDC provider, you specify the following:</p>\n <ul>\n <li>\n <p>The URL of the OIDC identity provider (IdP) to trust</p>\n </li>\n <li>\n <p>A list of client IDs (also known as audiences) that identify the application\n or applications allowed to authenticate using the OIDC provider</p>\n </li>\n <li>\n <p>A list of tags that are attached to the specified IAM OIDC provider</p>\n </li>\n <li>\n <p>A list of thumbprints of one or more server certificates that the IdP\n uses</p>\n </li>\n </ul>\n <p>You get all of this information from the OIDC IdP you want to use to access\n Amazon Web Services.</p>\n <note>\n <p>Amazon Web Services secures communication with some OIDC identity providers (IdPs) through our library\n of trusted root certificate authorities (CAs) instead of using a certificate thumbprint to\n verify your IdP server certificate. In these cases, your legacy thumbprint remains in your\n configuration, but is no longer used for validation. These OIDC IdPs include Auth0, GitHub,\n GitLab, Google, and those that use an Amazon S3 bucket to host a JSON Web Key Set (JWKS)\n endpoint.</p>\n </note>\n <note>\n <p>The trust for the OIDC provider is derived from the IAM provider that this\n operation creates. Therefore, it is best to limit access to the <a>CreateOpenIDConnectProvider</a> operation to highly privileged\n users.</p>\n </note>",
3142+
"smithy.api#documentation": "<p>Creates an IAM entity to describe an identity provider (IdP) that supports <a href=\"http://openid.net/connect/\">OpenID Connect (OIDC)</a>.</p>\n <p>The OIDC provider that you create with this operation can be used as a principal in a\n role's trust policy. Such a policy establishes a trust relationship between Amazon Web Services and\n the OIDC provider.</p>\n <p>If you are using an OIDC identity provider from Google, Facebook, or Amazon Cognito, you don't\n need to create a separate IAM identity provider. These OIDC identity providers are\n already built-in to Amazon Web Services and are available for your use. Instead, you can move directly\n to creating new roles using your identity provider. To learn more, see <a href=\"https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-idp_oidc.html\">Creating\n a role for web identity or OpenID connect federation</a> in the <i>IAM\n User Guide</i>.</p>\n <p>When you create the IAM OIDC provider, you specify the following:</p>\n <ul>\n <li>\n <p>The URL of the OIDC identity provider (IdP) to trust</p>\n </li>\n <li>\n <p>A list of client IDs (also known as audiences) that identify the application\n or applications allowed to authenticate using the OIDC provider</p>\n </li>\n <li>\n <p>A list of tags that are attached to the specified IAM OIDC provider</p>\n </li>\n <li>\n <p>A list of thumbprints of one or more server certificates that the IdP\n uses</p>\n </li>\n </ul>\n <p>You get all of this information from the OIDC IdP you want to use to access\n Amazon Web Services.</p>\n <note>\n <p>Amazon Web Services secures communication with OIDC identity providers (IdPs) using our library of\n trusted root certificate authorities (CAs) to verify the JSON Web Key Set (JWKS)\n endpoint's TLS certificate. If your OIDC IdP relies on a certificate that is not signed\n by one of these trusted CAs, only then we secure communication using the thumbprints set\n in the IdP's configuration.</p>\n </note>\n <note>\n <p>The trust for the OIDC provider is derived from the IAM provider that this\n operation creates. Therefore, it is best to limit access to the <a>CreateOpenIDConnectProvider</a> operation to highly privileged\n users.</p>\n </note>",
31443143
"smithy.api#examples": [
31453144
{
31463145
"title": "To create an instance profile",
@@ -8215,7 +8214,7 @@
82158214
}
82168215
],
82178216
"traits": {
8218-
"smithy.api#documentation": "<p>Lists the account alias associated with the Amazon Web Services account (Note: you can have only\n one). For information about using an Amazon Web Services account alias, see <a href=\"https://docs.aws.amazon.com/signin/latest/userguide/CreateAccountAlias.html\">Creating,\n deleting, and listing an Amazon Web Services account alias</a> in the <i>Amazon Web Services Sign-In\n User Guide</i>.</p>",
8217+
"smithy.api#documentation": "<p>Lists the account alias associated with the Amazon Web Services account (Note: you can have only\n one). For information about using an Amazon Web Services account alias, see <a href=\"https://docs.aws.amazon.com/IAM/latest/UserGuide/console_account-alias.html#CreateAccountAlias\">Creating,\n deleting, and listing an Amazon Web Services account alias</a> in the\n <i>IAM User Guide</i>.</p>",
82198218
"smithy.api#examples": [
82208219
{
82218220
"title": "To list account aliases",
@@ -11310,7 +11309,7 @@
1131011309
"code": "OpenIdIdpCommunicationError",
1131111310
"httpResponseCode": 400
1131211311
},
11313-
"smithy.api#documentation": "<p>The request failed because IAM cannot connect to the OpenID Connect identity provider URL.</p>",
11312+
"smithy.api#documentation": "<p>The request failed because IAM cannot connect to the OpenID Connect identity provider\n URL.</p>",
1131411313
"smithy.api#error": "client",
1131511314
"smithy.api#httpError": 400
1131611315
}
@@ -14924,7 +14923,7 @@
1492414923
}
1492514924
],
1492614925
"traits": {
14927-
"smithy.api#documentation": "<p>Replaces the existing list of server certificate thumbprints associated with an OpenID\n Connect (OIDC) provider resource object with a new list of thumbprints.</p>\n <p>The list that you pass with this operation completely replaces the existing list of\n thumbprints. (The lists are not merged.)</p>\n <p>Typically, you need to update a thumbprint only when the identity provider certificate\n changes, which occurs rarely. However, if the provider's certificate\n <i>does</i> change, any attempt to assume an IAM role that specifies\n the OIDC provider as a principal fails until the certificate thumbprint is\n updated.</p>\n <note>\n <p>Amazon Web Services secures communication with some OIDC identity providers (IdPs) through our library\n of trusted root certificate authorities (CAs) instead of using a certificate thumbprint to\n verify your IdP server certificate. In these cases, your legacy thumbprint remains in your\n configuration, but is no longer used for validation. These OIDC IdPs include Auth0, GitHub,\n GitLab, Google, and those that use an Amazon S3 bucket to host a JSON Web Key Set (JWKS)\n endpoint.</p>\n </note>\n <note>\n <p>Trust for the OIDC provider is derived from the provider certificate and is\n validated by the thumbprint. Therefore, it is best to limit access to the\n <code>UpdateOpenIDConnectProviderThumbprint</code> operation to highly\n privileged users.</p>\n </note>"
14926+
"smithy.api#documentation": "<p>Replaces the existing list of server certificate thumbprints associated with an OpenID\n Connect (OIDC) provider resource object with a new list of thumbprints.</p>\n <p>The list that you pass with this operation completely replaces the existing list of\n thumbprints. (The lists are not merged.)</p>\n <p>Typically, you need to update a thumbprint only when the identity provider certificate\n changes, which occurs rarely. However, if the provider's certificate\n <i>does</i> change, any attempt to assume an IAM role that specifies\n the OIDC provider as a principal fails until the certificate thumbprint is\n updated.</p>\n <note>\n <p>Amazon Web Services secures communication with OIDC identity providers (IdPs) using our library of\n trusted root certificate authorities (CAs) to verify the JSON Web Key Set (JWKS)\n endpoint's TLS certificate. If your OIDC IdP relies on a certificate that is not signed\n by one of these trusted CAs, only then we secure communication using the thumbprints set\n in the IdP's configuration.</p>\n </note>\n <note>\n <p>Trust for the OIDC provider is derived from the provider certificate and is\n validated by the thumbprint. Therefore, it is best to limit access to the\n <code>UpdateOpenIDConnectProviderThumbprint</code> operation to highly\n privileged users.</p>\n </note>"
1492814927
}
1492914928
},
1493014929
"com.amazonaws.iam#UpdateOpenIDConnectProviderThumbprintRequest": {

0 commit comments

Comments
 (0)