Close Menu
    DevStackTipsDevStackTips
    • Home
    • News & Updates
      1. Tech & Work
      2. View All

      Sunshine And March Vibes (2025 Wallpapers Edition)

      June 3, 2025

      The Case For Minimal WordPress Setups: A Contrarian View On Theme Frameworks

      June 3, 2025

      How To Fix Largest Contentful Paint Issues With Subpart Analysis

      June 3, 2025

      How To Prevent WordPress SQL Injection Attacks

      June 3, 2025

      All the WWE 2K25 locker codes that are currently active

      June 3, 2025

      PSA: You don’t need to spend $400+ to upgrade your Xbox Series X|S storage

      June 3, 2025

      UK civil servants saved 24 minutes per day using Microsoft Copilot, saving two weeks each per year according to a new report

      June 3, 2025

      These solid-state fans will revolutionize cooling in our PCs and laptops

      June 3, 2025
    • Development
      1. Algorithms & Data Structures
      2. Artificial Intelligence
      3. Back-End Development
      4. Databases
      5. Front-End Development
      6. Libraries & Frameworks
      7. Machine Learning
      8. Security
      9. Software Engineering
      10. Tools & IDEs
      11. Web Design
      12. Web Development
      13. Web Security
      14. Programming Languages
        • PHP
        • JavaScript
      Featured

      Community News: Latest PECL Releases (06.03.2025)

      June 3, 2025
      Recent

      Community News: Latest PECL Releases (06.03.2025)

      June 3, 2025

      A Comprehensive Guide to Azure Firewall

      June 3, 2025

      Test Job Failures Precisely with Laravel’s assertFailedWith Method

      June 3, 2025
    • Operating Systems
      1. Windows
      2. Linux
      3. macOS
      Featured

      All the WWE 2K25 locker codes that are currently active

      June 3, 2025
      Recent

      All the WWE 2K25 locker codes that are currently active

      June 3, 2025

      PSA: You don’t need to spend $400+ to upgrade your Xbox Series X|S storage

      June 3, 2025

      UK civil servants saved 24 minutes per day using Microsoft Copilot, saving two weeks each per year according to a new report

      June 3, 2025
    • Learning Resources
      • Books
      • Cheatsheets
      • Tutorials & Guides
    Home»Development»Windows Password Recovery with AWS SSM

    Windows Password Recovery with AWS SSM

    February 26, 2025

    The Systems Manager (SSM) streamlines managing Windows instances in AWS. If you’ve ever forgotten the password for your Windows EC2 instance, SSM offers a secure and efficient way to reset it without additional tools or manual intervention.

    Objective & Business Requirement

    In a production environment, losing access to a Windows EC2 instance due to an unknown or non-working password can cause significant downtime. Instead of taking a backup, creating a new instance, and reconfiguring the environment—which is time-consuming and impacts business operations—we leverage AWS Systems Manager (SSM) to efficiently recover access without disruption.

    • Recovery Process
    • Prerequisites
    • Configuration Overview
    • Best Practices
    • Conclusion

    Prerequisites

    Before you start, ensure the following prerequisites are met:

    1. SSM Agent Installed: The SSM agent must be installed and run on the Windows instance. AWS provides pre-configured AMIs with the agent installed.
    2. IAM Role Attached: Attach an IAM role to your instance with the necessary permissions. The policy should include:
      • AmazonSSMManagedInstanceCore
      • AmazonSSMFullAccess (or custom permissions to allow session management and run commands).
    3. Instance Managed by SSM: The instance must be registered as a managed instance in Systems Manager.

    Configuration Overview

    Follow this procedure if all you need is a PowerShell prompt on the target instance.

    1. Log in to the AWS Management Console

    • Navigate to the EC2 service in the AWS Management Console.
    • Open the instance in the AWS console & click Connect.

    S1

    • This opens a PowerShell session with “ssm-user”.

    Picture2

    2. Verify the Active Users

    Run Commands to Reset the Password

    With the session active, follow these steps to reset the password:

    • Run the following PowerShell command to list the local users: get-localuser

    Picture3

    • Identify the username for which you need to reset the password.
    • Reset the password using the following command:

    Replace <username> with the actual username and <password> with your new password.

    net user Username password

    3. Validate the New Password

    • Use Remote Desktop Protocol (RDP) to log into the Windows instance using the updated credentials.
    • To open an RDP connection to the instance in your browser, follow this procedure.
    • Open the instance in the AWS console & click Connect:
    • Switch to the “RDP client” tab & use Fleet Manager:

    Picture4

    • Able to access the server using “RDP client,” Please refer to the below screenshot.

    Picture5

     

    Best Practices

    1. Strong Password Policy: Ensure the new password adheres to your organization’s password policy for security.
    2. Audit Logs: Use AWS CloudTrail to monitor who initiated the SSM session and track changes made.
    3. Restrict Access: Limit who can access SSM and manage your instances by defining strict IAM policies.

    Troubleshooting Tips for Password Recovery

    • SSM Agent Issues: If the instance isn’t listed in SSM, verify that the SSM agent is installed and running.
    • IAM Role Misconfigurations: Ensure the IAM role attached to the instance has the correct permissions.
    • Session Manager Setup: If using the CLI, confirm that the Session Manager plugin is installed and correctly configured on your local machine.

     

    Conclusion

    AWS Systems Manager is a powerful tool that simplifies Windows password recovery and enhances the overall management and security of your instances. By leveraging SSM, you can avoid downtime, maintain access to critical instances, and adhere to AWS best practices for operational efficiency.

     

    Source: Read More 

    Facebook Twitter Reddit Email Copy Link
    Previous ArticleSetting up CloudFront using Python
    Next Article Leveraging Power Automate to Create Interactive Emails with Embedded Images and Links

    Related Posts

    Security

    BitoPro Silent on $11.5M Hack: Investigator Uncovers Massive Crypto Theft

    June 3, 2025
    Security

    New Linux Vulnerabilities

    June 3, 2025
    Leave A Reply Cancel Reply

    Continue Reading

    CISA Issues Urgent Security Alerts: Critical Vulnerabilities in Schneider Electric, Chrome, and Sitecore

    Development

    My top 5 must-play PC games for the second half of 2025 — Will they live up to the hype?

    News & Updates

    Build Your Own Tools with Penpot’s New Plugin System and Join the Contest

    Development

    Webdesigners Favorite Comfort Purchases

    Development

    Highlights

    LogicForm is an AI-powered survey tool

    February 22, 2025

    Post Content Source: Read More 

    This Week in Laravel: React Native, PhpStorm Junie, and more

    May 16, 2025

    US sets AI safety aside in favor of ‘AI dominance’

    February 7, 2025

    With U.S. Plea Deal, WikiLeaks Founder Assange is Free after 14-Year Legal Battle

    June 25, 2024
    © DevStackTips 2025. All rights reserved.
    • Contact
    • Privacy Policy

    Type above and press Enter to search. Press Esc to cancel.