Skip to content

Cognito | Delay in Receiving LimitExceededException #2011

Closed
@Raoufaaali

Description

@Raoufaaali

Describe the bug

Delay in Receiving LimitExceededException for ResendConfirmationCode using the AWS SDK for .NET

The AWS SDK for .NET has the following bug related to Cognito

When calling ResendConfirmationCode using the SDK more than the allowed limit (5 calls per/ hour per/user), the call takes way too long to respond with a LimitExceededException.
This behavior seems to be isolated to the AWS SDK for .NET.
In comparison, the ResendConfirmationCode return LimitExceedException in less than 1 second when called via the cli.

The same issue is observed with the ConfirmForgotPassword

Expected Behavior

Receiving LimitExceededException should be taking around 1 second

Current Behavior

Receiving LimitExceededException is taking around 30 seconds

Reproduction Steps

  1. Configure Cognito user pool and SNS to send SMS for account confirmation
  2. Sign a user up in Cognito, set the phone_number attribute
  3. Observe that a code is sent to the user device
  4. Don’t confirm the user.
  5. Instead, call ResendConfirmationCode and observe the immediate response. Repeat this for 5 time until LimitExceededException is received.
  6. Observe the time taken to receive LimitExceededException is taking longer than 30 seconds

Possible Solution

No response

Additional Information/Context

No response

AWS .NET SDK and/or Package version used

AWSSDK.CognitoIdentityProvider 3.3.103.3 and current latest stable AWSSDK.CognitoIdenitityProvider 3.7.2.14

Targeted .NET Platform

.NET Framework 4.5

Operating System and version

Windows 10, Windows 11, WindowsServer 2016 Core

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions