# HAProxy + Remote desktop Gateway

**URL:** <https://discourse.haproxy.org/t/haproxy-remote-desktop-gateway/8036>\
**Category:** Help!\
**Created:** [October 20, 2022, 2:07pm UTC](https://discourse.haproxy.org/t/haproxy-remote-desktop-gateway/8036 "2022-10-20T14:07:22Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![AndyOne](https://avatars.discourse-cdn.com/v4/letter/a/22d042/32.png) [@AndyOne](https://discourse.haproxy.org/u/AndyOne)\
**Post date:** [October 20, 2022, 2:07pm UTC](https://discourse.haproxy.org/t/haproxy-remote-desktop-gateway/8036/1 "2022-10-20T14:07:22Z")

</div>

Hello

Is there a way to configure HAProxy pass “pure” http for RDP clients to RD gateway (we use Win 2019 SRV)?

Now it works if deny remoteDesktopGateway path in config file.

Connections made as RPC over HTTP, not http – as it gets directly connected to RD gateway.

I wanna use HAProxy layer 7 not layer 4 (tcp).

It is possible?

regards

---

<div class="post-metadata">

**Author:** ![Markus](https://avatars.discourse-cdn.com/v4/letter/m/b782af/32.png) [@Markus](https://discourse.haproxy.org/u/Markus)\
**Post date:** [October 23, 2022, 7:43pm UTC](https://discourse.haproxy.org/t/haproxy-remote-desktop-gateway/8036/2 "2022-10-23T19:43:54Z")

</div>

HAPeoxy can act as http or tcp proxy.  
Just googled and found

> **[Microsoft Terminal Server / RemoteApp Load Balancing](https://www.haproxy.com/blog/microsoft-terminal-server-remoteapp-load-balancing)**
>
> Microsoft Terminal Services or remoteapps both use the RDP protocol. One issue when using RDP is being able to stick a user to a server.

> [@HAProxy + Remote desktop Gateway](https://discourse.haproxy.org/t/haproxy-remote-desktop-gateway/8036):
>
> Hello Is there a way to configure HAProxy pass “pure” http for RDP clients to RD gateway (we use Win 2019 SRV)? Now it works if deny remoteDesktopGateway path in config file. Connections made as RPC over HTTP, not http – as it gets directly connected to RD gateway. I wanna use HAProxy layer 7 not layer 4 (tcp). It is possible? regards

---

<div class="post-metadata">

**Author:** ![AndyOne](https://avatars.discourse-cdn.com/v4/letter/a/22d042/32.png) [@AndyOne](https://discourse.haproxy.org/u/AndyOne)\
**Post date:** [October 24, 2022, 7:18am UTC](https://discourse.haproxy.org/t/haproxy-remote-desktop-gateway/8036/3 "2022-10-24T07:18:17Z")

</div>

Thank u reply.  
As I mentioned – It is not terminal server – it is remote desktop gateway.  
Link you provided described RDP connections. In case of remote desktop gateway all connections made via https protocol not RDP.  
Now we could achieve “pure” http – only rpc over http.  
It is a little bit confused us. All work, but not native as directly connected to MS RD gateway.

Regards
