Skip to content

PowerShell script to change the default RDP port on Windows Server, update firewall rules, and enable RDP if disabled. Ideal for hardening remote access. Compatible with Windows Server 2012, 2016, 2019, and 2022.

License

Notifications You must be signed in to change notification settings

hosteons/Windows-RDP-Port-Changer-Script

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

Windows RDP Port Changer Script

This PowerShell script by Hosteons allows you to:

  • Change the default RDP port on your Windows server
  • Enable RDP if it is disabled
  • Configure Windows Firewall to allow the new RDP port
  • Restart the RDP service automatically

⚠️ Use with caution! Ensure you have console/VNC/IPMI access before applying changes.

How to Use

  1. Run the script as Administrator.
  2. Enter a new RDP port (between 1025 and 65535).
  3. The script will apply changes and restart RDP service.

License

MIT License

About

PowerShell script to change the default RDP port on Windows Server, update firewall rules, and enable RDP if disabled. Ideal for hardening remote access. Compatible with Windows Server 2012, 2016, 2019, and 2022.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published