Share via

How to define an GPO for Remote desktop User for specify Computer and user

SSE@TUE 300 Reputation points
2026-03-02T15:13:58.69+00:00

Hi,

How can I create an GPO for RDP Connection that user X does allow connect to the Computer Y?

It mean the User X can connect only to the Computer Y.

Regards

Nick

Windows for business | Windows Server | Directory services | Deploy group policy objects
0 comments No comments
{count} votes

Answer accepted by question author
  1. Marcin Policht 81,790 Reputation points MVP Volunteer Moderator
    2026-03-02T15:42:09.4433333+00:00

    To allow User X to connect via RDP only to Computer Y, you need to control two things: where the user is allowed to log on through Remote Desktop Services, and ensure they are denied everywhere else.

    First, on Computer Y, make sure User X is allowed to log on via RDP. In Group Policy, create or edit a GPO that applies only to Computer Y (link it to the OU containing Computer Y). Go to Computer Configuration → Policies → Windows Settings → Security Settings → Local Policies → User Rights Assignment. Configure “Allow log on through Remote Desktop Services” and add either User X directly or, preferably, a security group that contains User X. Also ensure User X is not listed in “Deny log on through Remote Desktop Services” in that same GPO.

    Next, prevent User X from connecting to any other computers. Create another GPO that applies to all other computers (for example, link it at the domain level or to the relevant OUs, excluding Computer Y). In that GPO, go to Computer Configuration → Policies → Windows Settings → Security Settings → Local Policies → User Rights Assignment and configure “Deny log on through Remote Desktop Services” to include User X (or the group containing User X). Because deny rights override allow rights, make sure this deny GPO does not apply to Computer Y. You can exclude Computer Y either by placing it in a separate OU and not linking the deny GPO there, or by using security filtering so the deny GPO does not apply to Computer Y.

    A clean design is to create a group such as “RDP-Only-ComputerY”, add User X to it, allow that group in the “Allow log on through Remote Desktop Services” setting on Computer Y, and configure a domain-wide GPO that denies that same group the “Log on through Remote Desktop Services” right, excluding Computer Y from that deny GPO scope. After configuring, run gpupdate /force on the target machines and verify effective rights with rsop.msc or gpresult /h report.html.


    If the above response helps answer your question, remember to "Accept Answer" so that others in the community facing similar issues can easily find the solution. Your contribution is highly appreciated.

    hth

    Marcin


1 additional answer

Sort by: Most helpful
  1. SSE@TUE 300 Reputation points
    2026-03-03T12:42:10.6766667+00:00

    Thank you for your replay. I have many Users and Computers. According to your description I have to create many OUs and GPOs for all the users and Computers.

    for example user Z, T, R, Computer Z, T, R, and so on.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.