- Install packages
$ sudo aptitude install guacamole-tomcat
$ sudo aptitude install libguac-client-ssh0 libguac-client-rdp0
$ cd /etc/guacamole
$ sudo cp user-mapping.xml user-mapping.xml.orig
- Edit user-mapping.xml
user-mapping.xml
<user-mapping>
<!-- User with one connection only -->
<authorize username="USERNAME" password="PASSWORD">
<protocol>vnc</protocol>
<param name="hostname">localhost</param>
<param name="port">5900</param>
<param name="password">VNCPASS</param>
</authorize>
<!-- Another user, but using md5 to hash the password
(example below uses the md5 hash of "PASSWORD"),
and providing two connections -->
<authorize
username="USERNAME2"
password="319f4d26e3c536b5dd871bb2c52e3178"
encoding="md5">
<connection name="VNC Desktop 1">
<protocol>vnc</protocol>
<param name="hostname">localhost</param>
<param name="port">5901</param>
<param name="password">VNCPASS</param>
</connection>
<connection name="VNC Desktop 2">
<protocol>vnc</protocol>
<param name="hostname">localhost</param>
<param name="port">5902</param>
<param name="password">VNCPASS</param>
</connection>
<connection name="RDP Desktop">
<protocol>rdp</protocol>
<param name="hostname">localhost</param>
<param name="port">3389</param>
<param name="domain"></param>
<param name="username"></param>
<param name="password"></param>
<!-- <param name="initial-program">explorer.exe</param> -->
<param name="color-depth">32</param><!-- 8,16,24 or 32 -->
<param name="width">1024</param>
<param name="height">768</param>
</connection>
<connection name="Unique Name">
<protocol>ssh</protocol>
<param name="hostname">localhost</param>
<param name="port">22</param>
</connection>
</authorize>
</user-mapping>
- Generate md5 hash value
echo -n 'PASSWORD' | md5sum
- Restart Guacamole daemon
sudo service guacd restart
- Install VNC Server on Guacamole client
sudo aptitude install vnc4server
- Launch VM with vnc password
kvm image -vnc ${dpy},password -monitor stdio
(qemu) set_password vnc password
guacamole.properties
# Guacamole - Clientless Remote Desktop
# Copyright (C) 2010 Michael Jumper
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# Hostname and port of guacamole proxy
guacd-hostname: localhost
guacd-port: 4822
# Auth provider class (authenticates user/pass combination, needed if using the provided login screen)
auth-provider: net.sourceforge.guacamole.net.basic.BasicFileAuthenticationProvider
basic-user-mapping: /etc/guacamole/user-mapping.xml