1

I'm trying to change RDP port for my Windows Server 2019 Core. I've edited the registry successfully and was able to update the port in firewall rules so that everything works:

PS C:\Windows\system32> Get-NetFirewallRule -Name "RemoteDesktop-UserMode-In-TCP" | Get-NetFirewallPortFilter


Protocol      : TCP
LocalPort     : 3355
RemotePort    : Any
IcmpType      : Any
DynamicTarget : Any



PS C:\Windows\system32> Get-NetFirewallRule -Name "RemoteDesktop-UserMode-In-TCP"


Name                  : RemoteDesktop-UserMode-In-TCP
DisplayName           : Remote Desktop - User Mode (TCP-In)
Description           : Inbound rule for the Remote Desktop service to allow RDP traffic. [TCP 3389]
DisplayGroup          : Remote Desktop
Group                 : @FirewallAPI.dll,-28752
Enabled               : True
Profile               : Any
Platform              : {}
Direction             : Inbound
Action                : Allow
EdgeTraversalPolicy   : Block
LooseSourceMapping    : False
LocalOnlyMapping      : False
Owner                 :
PrimaryStatus         : OK
Status                : The rule was parsed successfully from the store. (65536)
EnforcementStatus     : NotApplicable
PolicyStoreSource     : PersistentStore
PolicyStoreSourceType : Local


Now I try to change the rule's Description correspondingly for clarity:

PS C:\Windows\system32> Set-NetFirewallRule -Name "RemoteDesktop-UserMode-In-TCP" -Description "Inbound rule for the Remote Desktop service to allow RDP traffic. [TCP 3355]"

The output is empty and the command apparently does not work:

PS C:\Windows\system32> Get-NetFirewallRule -Name "RemoteDesktop-UserMode-In-TCP"


Name                  : RemoteDesktop-UserMode-In-TCP
DisplayName           : Remote Desktop - User Mode (TCP-In)
Description           : Inbound rule for the Remote Desktop service to allow RDP traffic. [TCP 3389]
DisplayGroup          : Remote Desktop
Group                 : @FirewallAPI.dll,-28752
Enabled               : True
Profile               : Any
Platform              : {}
Direction             : Inbound
Action                : Allow
EdgeTraversalPolicy   : Block
LooseSourceMapping    : False
LocalOnlyMapping      : False
Owner                 :
PrimaryStatus         : OK
Status                : The rule was parsed successfully from the store. (65536)
EnforcementStatus     : NotApplicable
PolicyStoreSource     : PersistentStore
PolicyStoreSourceType : Local

Changing description for a manually created rule works.

What is the reason and/or how do I fix this? Should I maybe copy these rules to new rules, fix their description and disable these old rules instead?

0

You must log in to answer this question.