Securing Your Remote Access: A Guide to Changing the RDP Port Number and Why It Matters

Securing Your Remote Access: A Guide to Changing the RDP Port Number and Why It Matters
Changing the Remote Desktop Protocol (RDP) port number is a security measure that can help protect your system from unauthorized access. The default RDP port is 3389, and many attackers know about it. Changing the port number adds an extra layer of security, making it more difficult for automated tools to find and target your RDP service. Here's how you can change the RDP port number:

Note: Before making any changes, make sure you have administrative access to the system, and be careful not to lock yourself out of remote access if you are accessing the system remotely.

Changing the RDP Port on Windows:

  1. Access the Registry Editor:

    • Press Win + R to open the Run window.
    • Type regedit and press Enter.
  2. Navigate to the RDP Port Registry Key:

    • Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp.
  3. Find the "PortNumber" Entry:

    • Locate the "PortNumber" DWORD entry.
  4. Change the Port Number:

    • Double-click on "PortNumber" and choose the Decimal base.
    • Enter a new port number (e.g., 5000) and click OK.
  5. Restart the Remote Desktop Services:

    • Open the Services snap-in (services.msc in the Run dialog).
    • Find "Remote Desktop Services" or "Remote Desktop Services UserMode Port Redirector" in the list.
    • Right-click and choose Restart.

Changing the RDP Port on Windows Firewall:

  1. Access the Windows Firewall Settings:

    • Open the Control Panel and navigate to "System and Security" > "Windows Defender Firewall."
  2. Create a New Inbound Rule:

    • Click on "Advanced settings" on the left panel.
    • In the left pane, right-click on "Inbound Rules" and choose "New Rule..."
    • Select "Port" and click Next.
    • Choose "TCP" and specify the new port number.
  3. Complete the Rule Setup:

    • Allow the connection and click Next.
    • Specify when the rule applies (Domain, Private, Public), and give the rule a name.
    • Click Finish.

Update Firewall and Router Settings:

  • Ensure that the new port is allowed through any external firewalls and routers. You may need to log in to your router's web interface and set up port forwarding to redirect external traffic to the new RDP port.

Connect Using the New Port:

  • When connecting via RDP, specify the new port in the format hostname:port (e.g., 192.168.1.1:5000).
Share :

Add New Comment

 Your Comment has been sent successfully. Thank you!   Refresh
Error: Please try again