-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(cognito): support password history size #33164
feat(cognito): support password history size #33164
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(This review is outdated)
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #33164 +/- ##
=======================================
Coverage 80.79% 80.79%
=======================================
Files 232 232
Lines 14110 14110
Branches 2453 2453
=======================================
Hits 11400 11400
Misses 2430 2430
Partials 280 280
Flags with carried forward coverage won't be shown. Click here to find out more.
|
✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks 👍 Couple of nits on docs
Co-authored-by: Luca Pizzini <lpizzini7@gmail.com>
if (props.featurePlan === FeaturePlan.LITE) { | ||
throw new Error('`passwordHistorySize` can not be set when `featurePlan` is `FeaturePlan.LITE`.'); | ||
} | ||
if (passwordHistorySize < 0 || passwordHistorySize > 24) { | ||
throw new Error(`\`passwordHistorySize\` must be between 0 and 24 (received: ${passwordHistorySize})`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you please change the Error to be ValidationError according to the ongoing change the team is doing now .. see tracking issue #32324
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the comment.
Am I correct in understanding that in this PR, you want to replace all Errors within aws-cognito with ValidationErrors? I was aware that the replacement was in progress, but I thought the maintenance team would handle it, so I left the Errors as they were.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
at least do it for the new added throw statements .. I believe we can have both in the sam construct .. and if you like to help more, you can open a new pr to replace the Errors in this construct with the validation error :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you. I've replaced only the Errors added this time. If this PR is merged before the maintainer starts work, I'm considering creating a PR to replace other Errors in aws-cognito.
Pull request has been modified.
4bc10c3
to
03cccb6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks @mazyu36 for your quick response and contribution :)
@mergify update |
❌ Sorry but I didn't understand the command. Please consult the commands documentation 📚. |
✅ Branch has been successfully updated |
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
@Mergifyio requeue |
❌ Command disallowed due to command restrictions in the Mergify configuration.
|
@Mergifyio update |
☑️ Nothing to do
|
@Mergifyio refresh |
✅ Pull request refreshed |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
Comments on closed issues and PRs are hard for our team to see. |
Issue # (if applicable)
Closes #33106.
Reason for this change
To enable password reuse prevention settings in Cognito user pools.
Description of changes
Add
passwordHistorySize
property.Describe any new or updated permissions being added
No permission update.
Description of how you validated changes
Add unit tests and an integ test.
Checklist
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license