{"id":1106,"date":"2023-06-24T10:32:22","date_gmt":"2023-06-24T10:32:22","guid":{"rendered":"https:\/\/ml-gis-service.com\/?p=1106"},"modified":"2023-06-24T10:32:23","modified_gmt":"2023-06-24T10:32:23","slug":"toolbox-set-a-permanent-cognito-user-password-from-a-browser","status":"publish","type":"post","link":"https:\/\/ml-gis-service.com\/index.php\/2023\/06\/24\/toolbox-set-a-permanent-cognito-user-password-from-a-browser\/","title":{"rendered":"Toolbox: Set a permanent Cognito user password from a browser"},"content":{"rendered":"\n<p>I\u2019m on vacation and can\u2019t access my working environment with AWS SAM and AWS CLI. What are my options to set the user password? Skim-reading internet discussions doesn\u2019t give any answers, but one option is to perform <code>aws cognito-idp admin-set-user-password<\/code> from a browser! All you need to have:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>AWS Account with access to AWS Console,<\/li>\n\n\n\n<li>Access to the AWS shell.<\/li>\n<\/ul>\n\n\n\n<p>Then:<\/p>\n\n\n\n<ul class=\"wp-block-list\" type=\"1\">\n<li>Login to AWS Console.<\/li>\n\n\n\n<li>Type <code>Shell<\/code> in a search window and choose <code>CloudShell<\/code>.<\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"585\" src=\"https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img1-aws-1024x585.jpg\" alt=\"\" class=\"wp-image-1107\" srcset=\"https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img1-aws-1024x585.jpg 1024w, https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img1-aws-300x171.jpg 300w, https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img1-aws-768x439.jpg 768w, https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img1-aws-1536x877.jpg 1536w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure><\/div>\n\n\n<ul class=\"wp-block-list\" type=\"1\">\n<li>In <code>CloudShell<\/code> type the command below that will affect your Cognito user password.<\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"581\" src=\"https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img2-aws-1024x581.jpg\" alt=\"\" class=\"wp-image-1108\" srcset=\"https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img2-aws-1024x581.jpg 1024w, https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img2-aws-300x170.jpg 300w, https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img2-aws-768x436.jpg 768w, https:\/\/ml-gis-service.com\/wp-content\/uploads\/2023\/06\/img2-aws-1536x872.jpg 1536w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure><\/div>\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"shell\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">aws cognito-idp admin-set-user-password --user-pool-id 'user_pool_id' --username 'user_to_change_password' --password 'new_password' --permanent --region 'aws_region'<\/pre>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>user_pool_id<\/code> &#8211; can be obtained from the Cognito service. Type <code>Cognito<\/code> in a search field and check your user pools. By default, it starts with your app\u2019s AWS region name followed by random characters,<\/li>\n\n\n\n<li><code>user_to_change_password<\/code> &#8211; user whose password will be changed,<\/li>\n\n\n\n<li><code>new_password<\/code> &#8211; your password that will be set,<\/li>\n<\/ul>\n\n\n\n<p><strong>Hint:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Do not use double quotes for variables in your command.<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Set AWS Cognito user password from a browser<\/p>\n","protected":false},"author":1,"featured_media":1109,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[243,2,242],"tags":[244,246,245,247,248],"class_list":["post-1106","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-aws","category-data-engineering","category-infrastructure","tag-aws","tag-cludshell","tag-cognito","tag-console","tag-password-change"],"_links":{"self":[{"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/posts\/1106","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/comments?post=1106"}],"version-history":[{"count":5,"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/posts\/1106\/revisions"}],"predecessor-version":[{"id":1114,"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/posts\/1106\/revisions\/1114"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/media\/1109"}],"wp:attachment":[{"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/media?parent=1106"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/categories?post=1106"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ml-gis-service.com\/index.php\/wp-json\/wp\/v2\/tags?post=1106"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}