Publishing Windows 2000 Terminal Services to a Non-Standard Port

Terminal Services publishing allows you to access internal network Terminal Servers over the Internet. This is great! But for security reasons, you might want to change the default port number. In this article Steve Moffat gives you a step by step that will allow you to make short work out of publishing your Terminal Servers.

Publishing Windows 2000 Terminal Servers To a Non-Standard Port

By Steve Moffat

Edited by Thomas W Shinder

Check out MSTerminalServices.org, a new resource for Windows Terminal Services and Citrix focusing on all aspects of server based computing and thin client computing.

Going by the number of posts in the ISAServer.org discussion list there are still a lot of Terminal Servers being published on the standard port of TCP 3389. This can have severe security implications as well as restricting the number of published terminal Servers to one.

Client Address Sets should be created and used to establish inbound access control to the Terminal Servers.

This tutorial will show you how to securely publish Terminal Server to ports other than 3389.

Step 1:

    1. On the Terminal Server you want to publish.
    2. Open regedit and navigate to:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp

    1. Right click on PortNumber in the right hand pane and change it to an unused port of your choice. Restart your Server

Step 2:

  1. If publishing Terminal Services on the ISA Server computer, then you should also restrict the listening port to the internal network interface. This prevents connections to the Terminal Server on the machine's external interface.
  2. Start the Terminal Services Configuration Console, right click on RDP-Tcp connections

  1. Select Properties, and then click on the Network Adapter tab. Select your internal interface via the drop down box.

  1. Restart your Server

Step 3:

  1. Open the ISA Management Console.
  2. Create a new Protocol Definition for each Server and port to be published.
  3. Right Click on on the Protocol Definitions node, point to New and then click Definition.

  1. Click Next.

  1. Enter the port number you have chosen to use, make sure it’s TCP and Inbound.
  2. Click Next.
  3. Do not use any Secondary Connections.

  1. Click Next.

  1. Click Finish.

Step 4:

  1. Create your Publishing Rule.
  2. In the ISA Management Console, Right click on Server Publishing Rules.
  3. Point to New and then click Rule.

  1. Click Next.
  2. Enter your Terminal Server's address on the internal network and the IP address address on the external interface of the ISA Server that you want to publish the Terminal Server on.

  1. Click Next.
  2. Choose the Protocol definition previously created

  1. Click Next.
  2. At this point I cannot stress how important security is therefore I recommend that you use Client Address Sets to allow or deny access.

  1. Click Next.
  2. Add your Client Address Set(s)

  1. Click OK then click Next. (Just for a change)
  2. Click Finish.

Step 5:

On the client PC you have to change the port within the RDP client to the Terminal Server port you wish to connect to.

I recommend downloading the RDP 5 Client from Microsoft as it is a lot easier to configure. It also have more features and works much better. Don’t worry about compatibility, it works on all Windows platforms, from Windows 95 and up.

You can get it from here

http://download.microsoft.com/download/whistler/tools/1.0/wxp/en-us/msrdpcli.exe

With the RDP 5 client just append the port no. to your server address xxx.xxx.xxx.xxx:12345

And that’s all there is to it. Test from outside of your firewall and every thing should work perfectly.

You can also use the FQDN to reach your server as long as the port no. is reflected in this also.

Check out MSTerminalServices.org, a new resource for Windows Terminal Services and Citrix focusing on all aspects of server based computing and thin client computing.

Steve Moffat

6/13/2002

About Steve Moffat

Steve Moffat, ACT, is living and working in paradise, has worked in IT support services for the last 23 years. Currently working through his MCSE with great success so far. Since moving to Bermuda he has been responsible for server builds for TexacoChevron and Bermuda International Airport amongst others.

Receive all the latest articles by email!

Get all articles delivered directly to your mailbox as and when they are released on ISAserver.org! Choose between receiving instant updates with the Real-Time Article Update, or a monthly summary with the Monthly Article Update. Sign up to the ISAserver.org Monthly Newsletter, written by ISA expert Dr. Tom Shinder, containing news, the hottest tips, ISA links of the month and much more. Subscribe today and don't miss a thing!



Receive all the latest articles by email!

Receive Real-Time & Monthly ISAserver.org article updates in your mailbox. Enter your email below!
Click for Real-Time sample & Monthly sample

Become an ISAserver.org member!

Discuss your ISA Server issues with thousands of other ISA Server experts. Click here to join!

Readers' Choice

Which is your favorite Access Control solution?

Follow TechGenix on Twitter