how to enable built in firewall rules using intune

hyugai 31 Reputation points
2022-09-28T02:19:21.013+00:00

Hi All,

I want to enable rdp (but only for when people are in office)
I manage to setup the Allow remote remote connection to this computer to be tick
245286-image.png

However, i need to enable the built in firewall rules 'Remote Desktop - User Mode (TCP-In)' using intune.
245353-image.png

Does anyone can help me?

Microsoft Intune Configuration
Microsoft Intune Configuration
Microsoft Intune: A Microsoft cloud-based management solution that offers mobile device management, mobile application management, and PC management capabilities.Configuration: The process of arranging or setting up computer systems, hardware, or software.
1,734 questions
Microsoft Intune
Microsoft Intune
A Microsoft cloud-based management solution that offers mobile device management, mobile application management, and PC management capabilities.
4,412 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Crystal-MSFT 43,721 Reputation points Microsoft Vendor
    2022-09-28T06:29:16.713+00:00

    @hyugai , Based on my test, we can save the following command in ps1 PowerShell script, then deploy the script via Intune to enable the built in windows firewall rule:

    Get-NetFirewallRule | where {$_.displayname -eq 'Remote Desktop - User Mode (TCP-In)'} | Enable-NetFirewallRule  
    

    245403-image.png
    Hope it can help.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.
    0 comments No comments

  2. hyugai 31 Reputation points
    2022-09-28T02:20:38.907+00:00

    how do i use intune to enable the built in firewall 'Remote Desktop - User Mode (TCP-In)'?

    0 comments No comments

  3. hyugai 31 Reputation points
    2022-09-28T21:37:10.05+00:00

    hi thanks for the reply.
    So there is no built in intune policy to enable this built in firewall rule in windows 10?

    Further, what if i want to enable this firewall rules but the scope profile only for domain profile?
    How would the powershell script look like?