1
0
mirror of https://github.com/dkmstr/openuds.git synced 2024-12-22 13:34:04 +03:00

* Testing guacamole with parameters (we need to pass in the url from where to get credentials, etc...)

This commit is contained in:
Adolfo Gómez 2013-03-03 13:31:14 +00:00
parent 7353155158
commit 9afbbc3efb
2 changed files with 12 additions and 5 deletions

View File

@ -17,12 +17,18 @@ public class TunnelServlet
@Override @Override
protected GuacamoleTunnel doConnect(HttpServletRequest request) protected GuacamoleTunnel doConnect(HttpServletRequest request)
throws GuacamoleException { throws GuacamoleException {
String data = request.getParameter("data");
if( data == null )
return null;
System.out.println("Valor: " + data);
// Create our configuration // Create our configuration
GuacamoleConfiguration config = new GuacamoleConfiguration(); GuacamoleConfiguration config = new GuacamoleConfiguration();
config.setProtocol("rdp"); config.setProtocol("rdp");
config.setParameter("hostname", "dc.ad.dkmon.com"); config.setParameter("hostname", "w7adolfo");
config.setParameter("username", "administrador"); config.setParameter("username", "admin");
config.setParameter("password", "temporal"); config.setParameter("password", "temporal");
// Connect to guacd - everything is hard-coded here. // Connect to guacd - everything is hard-coded here.

View File

@ -6,11 +6,12 @@
<title>Simple RDP Tunneling Test</title> <title>Simple RDP Tunneling Test</title>
<!-- Client core scripts --> <!-- Client core scripts -->
<script type="text/javascript" src="guacamole-common-js/keyboard.js"></script>
<script type="text/javascript" src="guacamole-common-js/mouse.js"></script>
<script type="text/javascript" src="guacamole-common-js/layer.js"></script> <script type="text/javascript" src="guacamole-common-js/layer.js"></script>
<script type="text/javascript" src="guacamole-common-js/tunnel.js"></script> <script type="text/javascript" src="guacamole-common-js/tunnel.js"></script>
<script type="text/javascript" src="guacamole-common-js/guacamole.js"></script> <script type="text/javascript" src="guacamole-common-js/guacamole.js"></script>
<script type="text/javascript" src="guacamole-common-js/audio.js"></script>
<script type="text/javascript" src="guacamole-common-js/keyboard.js"></script>
<script type="text/javascript" src="guacamole-common-js/mouse.js"></script>
</head> </head>
@ -39,7 +40,7 @@
}; };
// Connect // Connect
guac.connect(); guac.connect("data=1");
// Disconnect on close // Disconnect on close
window.onunload = function() { window.onunload = function() {