RDP in the browser: Apache Guacamole and Sophos UTM

Although the UTM also has a solution with the HTML5 VPN to display RDP connections in the browser, this runs as within the user portal. If you only have a public IP, you have to switch to a different port, as I did with the built-in Sophos solution. In other networks, however, often only the common ports such as 80 and 443 are open.

I faced exactly this problem, only one public IP, often I could not connect to the UTM user portal via other ports. The HTTPS port is already occupied by the web server protection and other services.

I first tested the Windows Admin Center, which is a pretty useful solution, but unfortunately not in conjunction with UTM Webserver Protection. The Windows Admin Center uses WebSockets, but this is not supported by UTM Webserver Protection.

However, there is the Apache Guacamole project, which has worked perfectly for me so far in conjunction with Webserver Protection. Maybe this little article will help other people, so here is a brief description of how to set up Webserver Protection for Guacamole.

My setup looks something like this:

Sophos UTM Webserver Protection uses a free wildcard certificate from Let's Encrypt. The web server protection runs on port 443 (https) and forwards to the real web servers depending on the host name. Currently, these are, for example, an Exchange server and another web server:

RDP in the browser: Apache Guacamole and Sophos UTM

In addition, I am now adding a small CentOS VM to run Guacamole. I am using the CentOS minimal installation with 1 GB RAM and 1 CPU. The installation of Guacamole is pretty simple, I just used this installation script:

The script asks for a few settings and installs a ready-made Guacamole environment.

RDP in the browser: Apache Guacamole and Sophos UTM

Small hint: I installed Guacamole with NGINX, more on that later.

As soon as Guacamole is installed, a new web server can be created on the UTM:

RDP in the browser: Apache Guacamole and Sophos UTM

A firewall profile is then required:

RDP in the browser: Apache Guacamole and Sophos UTM

For guacamole to work, a few exceptions are necessary. I had to skip these rules:

  • 981257
  • 981245
  • 981246
  • 981243
  • 981204
  • 981172
  • 981173
  • 960015
  • 981203
  • 981318
  • 981176

The virtual web server can now be created (do not forget the firewall profile):

RDP in the browser: Apache Guacamole and Sophos UTM

Since the Guacamole installation is called via the /guacamole directory, I have adapted the NGIX configuration a little. This means that /guacamole does not have to be appended each time it is called:

  • /etc/nginx/conf.d/guacamole_ssl.conf

RDP in the browser: Apache Guacamole and Sophos UTM

For example, a call from https://rdp.frankysweb.de is now redirected to https://rdp.frankyweb.de/guacamole. With a corresponding redirection directly in the UTM, it would not work for me. So it's currently double (UTM + NGNIX). Maybe someone else has a tip?

So far I have not noticed any restrictions in connection with the UTM, everything works like clockwork:

RDP in the browser: Apache Guacamole and Sophos UTM

Although the range of functions cannot be compared with the Windows Admin Center, the RDP connection in the browser works first-class and is extremely fast:

RDP in the browser: Apache Guacamole and Sophos UTM

I have also activated Reverse Authentication, but this currently prompts for the user name and password twice. I'll see if I can switch Guacamole to basic authentication. Of course, you could also leave it as 2-factor authentication as it is Smile

4 thoughts on “RDP im Browser: Apache Guacamole und Sophos UTM”

  1. Hi
    Ich möchte Guacomole auch von extern nutzen und bin deinem Beispiel mit dem virtuellen Webserver gefolgt. Das klappt auch soweit gut. Benötige ich, wenn man die Reverse Proxy Fähigkeiten der Sophos UTM nutzt, auch noch nginx als Reverse Proxy Server?

    Gruß
    Andreas

    Reply
  2. Noch ne kleine Anregung, da das Problem häufiger Auftritt, auch schon bei sehr simplen Szenarien.
    Man kann über eine öffentliche IP die Webserver Protection, als auch das Userportal auf Port 443 laufen haben.
    Dazu könnte man einfach das Userportal auf ein anderes Interface legen(notfalls Dummyinterface) und dort lauschen lassen, dann kann man es ganz normal über die Webserver Protection nach außen freigeben.

    Reply
  3. Hi Frank

    beim downloaden des scripts bekomme ich immer einen 404 not found angezeigt , an was kann das liegen ?

    Reply
  4. Hallo,

    vielen Dank für den Artikel!

    Wir haben ebenfalls Guacamole als Lösung installiert, falls VPN und Konsorten mal nicht möglich / zugelassen ist.

    Wir haben die Erfahrung gemacht, dass Arbeiten hiermit zwar möglich, aber etwas unschön ist. Folgende Probleme haben wir hierbei:
    – Die Zwischenablage ist sehr umständlich (direktes Strg+C und Strg+V ist nicht möglich, synchronisierter Zwischenspeicher über Strg+Alt+Shift)
    – Bestimmte Tastenkombinationen werden vom Browser abgefangen anstatt durchgeleitet zu werden (z.B. F5, welches beim ABAP-Debugging der Einzelschritt ist, im Browser ein Refresh der gesamten Seite verursacht)

    Können Sie diese Dinge bestätigen oder ist dies ein lokales Problem bei uns?

    Auf Grund dieser Einschränkungen ist es bei uns eher eine Notlösung als eine echte Alternative.

    Reply

Leave a Comment