It seems to be a need to know the used ports by the Remote Desktop RD Gateway. Find a short overview bellow:
Internet –> Gateway WAN NIC:
TCP: 443
UDP: 3391 (You have to enable UDP on the RD Gateway)
Gateway LAN NIC –> Session Host Servers:
TCP / UDP: 3389
Gateway LAN NIC –> Connection Broker Servers:
TCP / UDP: 3389
TCP: 5504
TCP: 5985
Gateway LAN NIC –> Domain Controllers:
TCP / UDP: 88
TCP: 135
UDP: 123
UDP 137
TCP: 139
TCP / UDP: 389
TCP: 3268
TCP / UDP: 53
TCP / UDP: 445
TCP: 5985
TCP Dynamic Ports (NTDS RPC service )
Connection Broker Servers –> Gateway LAN NIC
TCP 5985 (WS-Management and PowerShell Remoting)
TCP: 3389 (Remote Desktop)
Let me know if this helps.
Cheers,
Al