Hey,

Here is my working reverse proxy parameters for Guacamole 1.4 using Apache2:

#Reverse Proxy for Guacamole
        <Location /vlab/>
                Order allow,deny
                Allow from all
                ProxyPass http://127.0.0.1:8080/guacamole/ flushpackets=on
                ProxyPassReverse http://127.0.0.1:8080/guacamole/
                ProxyPassReverseCookiePath /guacamole/ /vlab/
        </Location>

        <Location /vlab/websocket-tunnel>
                Order allow,deny
                Allow from all
                ProxyPass ws://127.0.0.1:8080/guacamole/websocket-tunnel
                ProxyPassReverse ws://
127.0.0.1:8080/guacamole/websocket-tunnel
        </Location>

        SetEnvIf Request_URI "^/tunnel" dontlog
        CustomLog  /var/log/apache2/guac.log common env=!dontlog

-Pradip

On Fri, 1 Apr 2022, 6:59 pm Laurent Bardi, <[email protected]> wrote:

> Hi,
>
> playing with guacamole 1.4 under debian 11; guacamole server and client
> recompiled with no error, everything is ok with the exception ok proxying
> with apache2.
>
> apache conf :
>
>         <Location /guacamole/ >
>                 Order allow,deny
>                 Allow from all
>                 ProxyPass http://127.0.0.1:8080/guacamole-1.4.0/
> flushpackets=on
>                 ProxyPassReverse http://127.0.0.1:8080/guacamole-1.4.0/
>         </Location>
>         <Location /guacamole/websocket-tunnel>
>                 Order allow,deny
>                 Allow from all
>                 ProxyPass
> ws://127.0.0.1:8080/guacamole-1.4.0/websocket-tunnel
>                 ProxyPassReverse
> ws://127.0.0.1:8080/guacamole-1.4.0/websocket-tunnel
>         </Location>
>
> everything works fine with a browser; now playing with the API under bash:
>
> the command :
>
> curl -X POST -d 'username=&password='
> http://10.59.64.84:8080/guacamole-1.4.0/api/tokens
>
> give me :
>
>
> {"authToken":"30753A410E23ECF8F4755236095712EE852ACCDE8F244A17E339D84CFCE14DA9","username":"afa9d4e1-3f54-4e88-926e-76ea9ea8ab59","dataSource":"default","availableDataSources":["quickconnect","default"]}
>
> ok
>
> the command :
>
> curl -X POST -d 'username=&password='
> http://10.59.64.84/guacamole/api/tokens
>
> give me  :
>
> <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
> <html><head>
> <title>401 Unauthorized</title>
> </head><body>
> <h1>Unauthorized</h1>
> <p>This server could not verify that you
> are authorized to access the document
> requested.  Either you supplied the wrong
> credentials (e.g., bad password), or your
> browser doesn't understand how to supply
> the credentials required.</p>
> <hr>
> <address>Apache/2.4.53 (Debian) Server at 10.59.64.84 Port 80</address>
> </body></html>
>
> Even if i add
>
> <Location /guacamole/api/tokens >
>                 Order allow,deny
>                 Allow from all
>                 ProxyPass http://127.0.0.1:8080/guacamole-1.4.0/api/tokens
> flushpackets=on
>                 ProxyPassReverse
> http://127.0.0.1:8080/guacamole-1.4.0/api/tokens
> </Location>
>
> in apache conf it doesn t works.
>
> Could you help me ?
>
> Many thanks in advance
>
>
>

Reply via email to