You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@guacamole.apache.org by jm...@apache.org on 2017/04/21 04:40:24 UTC
[1/4] incubator-guacamole-server git commit: GUACAMOLE-40: Test
whether FreeRDP supports RD gateways and/or load balancing.
Repository: incubator-guacamole-server
Updated Branches:
refs/heads/master d3fa5e7fb -> 69caa9936
GUACAMOLE-40: Test whether FreeRDP supports RD gateways and/or load balancing.
Project: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/commit/af8ef9f5
Tree: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/tree/af8ef9f5
Diff: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/diff/af8ef9f5
Branch: refs/heads/master
Commit: af8ef9f526546acc6682cb8ea591f7dad7f849d8
Parents: 37fe354
Author: Michael Jumper <mj...@apache.org>
Authored: Sun Apr 9 23:17:01 2017 -0700
Committer: Michael Jumper <mj...@apache.org>
Committed: Sun Apr 9 23:17:01 2017 -0700
----------------------------------------------------------------------
configure.ac | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/blob/af8ef9f5/configure.ac
----------------------------------------------------------------------
diff --git a/configure.ac b/configure.ac
index c9391ed..a61534a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -609,6 +609,24 @@ then
#include <winpr/collections.h>])
fi
+# Support for RDP gateways
+if test "x${have_freerdp}" = "xyes"
+then
+ AC_CHECK_MEMBERS([rdpSettings.GatewayEnabled],
+ [AC_DEFINE([HAVE_FREERDP_GATEWAY_SUPPORT],,
+ [Whether FreeRDP supports RDP gateways])],,
+ [[#include <freerdp/freerdp.h>]])
+fi
+
+# Support for load balancing via connection brokers
+if test "x${have_freerdp}" = "xyes"
+then
+ AC_CHECK_MEMBERS([rdpSettings.LoadBalanceInfo],
+ [AC_DEFINE([HAVE_FREERDP_LOAD_BALANCER_SUPPORT],,
+ [Whether FreeRDP supports load balancers])],,
+ [[#include <freerdp/freerdp.h>]])
+fi
+
# Support for "PubSub" event system
if test "x${have_freerdp}" = "xyes"
then
[4/4] incubator-guacamole-server git commit: GUACAMOLE-40: Merge RD
gateway support.
Posted by jm...@apache.org.
GUACAMOLE-40: Merge RD gateway support.
Project: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/commit/69caa993
Tree: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/tree/69caa993
Diff: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/diff/69caa993
Branch: refs/heads/master
Commit: 69caa9936b4be726ab7effc8e9c613c0d32cecfe
Parents: d3fa5e7 0909905
Author: James Muehlner <ja...@guac-dev.org>
Authored: Thu Apr 20 21:36:44 2017 -0700
Committer: James Muehlner <ja...@guac-dev.org>
Committed: Thu Apr 20 21:36:44 2017 -0700
----------------------------------------------------------------------
configure.ac | 18 +++++
src/protocols/rdp/rdp_settings.c | 134 ++++++++++++++++++++++++++++++++++
src/protocols/rdp/rdp_settings.h | 45 ++++++++++++
3 files changed, 197 insertions(+)
----------------------------------------------------------------------
[2/4] incubator-guacamole-server git commit: GUACAMOLE-40: Add and
parse RD gateway connection parameters.
Posted by jm...@apache.org.
GUACAMOLE-40: Add and parse RD gateway connection parameters.
Project: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/commit/da8636ef
Tree: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/tree/da8636ef
Diff: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/diff/da8636ef
Branch: refs/heads/master
Commit: da8636ef546add9f71db6ffcc0d873e085d5e13f
Parents: af8ef9f
Author: Michael Jumper <mj...@apache.org>
Authored: Sun Apr 9 23:58:11 2017 -0700
Committer: Michael Jumper <mj...@apache.org>
Committed: Sun Apr 9 23:58:11 2017 -0700
----------------------------------------------------------------------
src/protocols/rdp/rdp_settings.c | 106 ++++++++++++++++++++++++++++++++++
src/protocols/rdp/rdp_settings.h | 45 +++++++++++++++
2 files changed, 151 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/blob/da8636ef/src/protocols/rdp/rdp_settings.c
----------------------------------------------------------------------
diff --git a/src/protocols/rdp/rdp_settings.c b/src/protocols/rdp/rdp_settings.c
index e8161b1..1ec34b9 100644
--- a/src/protocols/rdp/rdp_settings.c
+++ b/src/protocols/rdp/rdp_settings.c
@@ -93,6 +93,18 @@ const char* GUAC_RDP_CLIENT_ARGS[] = {
"enable-audio-input",
"read-only",
+#ifdef HAVE_FREERDP_GATEWAY_SUPPORT
+ "gateway-hostname",
+ "gateway-port",
+ "gateway-domain",
+ "gateway-username",
+ "gateway-password",
+#endif
+
+#ifdef HAVE_FREERDP_LOAD_BALANCER_SUPPORT
+ "load-balance-info",
+#endif
+
NULL
};
@@ -392,6 +404,53 @@ enum RDP_ARGS_IDX {
*/
IDX_READ_ONLY,
+#ifdef HAVE_FREERDP_GATEWAY_SUPPORT
+ /**
+ * The hostname of the remote desktop gateway that should be used as an
+ * intermediary for the remote desktop connection. If omitted, a gateway
+ * will not be used.
+ */
+ IDX_GATEWAY_HOSTNAME,
+
+ /**
+ * The port of the remote desktop gateway that should be used as an
+ * intermediary for the remote desktop connection. By default, this will be
+ * 443.
+ *
+ * NOTE: If using a version of FreeRDP prior to 1.2, this setting has no
+ * effect. FreeRDP instead uses a hard-coded value of 443.
+ */
+ IDX_GATEWAY_PORT,
+
+ /**
+ * The domain of the user authenticating with the remote desktop gateway,
+ * if a gateway is being used. This is not necessarily the same as the
+ * user actually using the remote desktop connection.
+ */
+ IDX_GATEWAY_DOMAIN,
+
+ /**
+ * The username of the user authenticating with the remote desktop gateway,
+ * if a gateway is being used. This is not necessarily the same as the
+ * user actually using the remote desktop connection.
+ */
+ IDX_GATEWAY_USERNAME,
+
+ /**
+ * The password to provide when authenticating with the remote desktop
+ * gateway, if a gateway is being used.
+ */
+ IDX_GATEWAY_PASSWORD,
+#endif
+
+#ifdef HAVE_FREERDP_LOAD_BALANCER_SUPPORT
+ /**
+ * The load balancing information/cookie which should be provided to
+ * the connection broker, if a connection broker is being used.
+ */
+ IDX_LOAD_BALANCE_INFO,
+#endif
+
RDP_ARGS_COUNT
};
@@ -763,6 +822,40 @@ guac_rdp_settings* guac_rdp_parse_args(guac_user* user,
guac_user_parse_args_boolean(user, GUAC_RDP_CLIENT_ARGS, argv,
IDX_ENABLE_AUDIO_INPUT, 0);
+#ifdef HAVE_FREERDP_GATEWAY_SUPPORT
+ /* Set gateway hostname */
+ settings->gateway_hostname =
+ guac_user_parse_args_string(user, GUAC_RDP_CLIENT_ARGS, argv,
+ IDX_GATEWAY_HOSTNAME, NULL);
+
+ /* If gateway port specified, use it */
+ settings->gateway_port =
+ guac_user_parse_args_int(user, GUAC_RDP_CLIENT_ARGS, argv,
+ IDX_GATEWAY_PORT, 443);
+
+ /* Set gateway domain */
+ settings->gateway_domain =
+ guac_user_parse_args_string(user, GUAC_RDP_CLIENT_ARGS, argv,
+ IDX_GATEWAY_DOMAIN, NULL);
+
+ /* Set gateway username */
+ settings->gateway_username =
+ guac_user_parse_args_string(user, GUAC_RDP_CLIENT_ARGS, argv,
+ IDX_GATEWAY_USERNAME, NULL);
+
+ /* Set gateway password */
+ settings->gateway_password =
+ guac_user_parse_args_string(user, GUAC_RDP_CLIENT_ARGS, argv,
+ IDX_GATEWAY_PASSWORD, NULL);
+#endif
+
+#ifdef HAVE_FREERDP_LOAD_BALANCER_SUPPORT
+ /* Set load balance info */
+ settings->load_balance_info =
+ guac_user_parse_args_string(user, GUAC_RDP_CLIENT_ARGS, argv,
+ IDX_LOAD_BALANCE_INFO, NULL);
+#endif
+
/* Success */
return settings;
@@ -811,6 +904,19 @@ void guac_rdp_settings_free(guac_rdp_settings* settings) {
free(settings->sftp_username);
#endif
+#ifdef HAVE_FREERDP_GATEWAY_SUPPORT
+ /* Free RD gateway information */
+ free(settings->gateway_hostname);
+ free(settings->gateway_domain);
+ free(settings->gateway_username);
+ free(settings->gateway_password);
+#endif
+
+#ifdef HAVE_FREERDP_LOAD_BALANCER_SUPPORT
+ /* Free load balancer information string */
+ free(settings->load_balance_info);
+#endif
+
/* Free settings structure */
free(settings);
http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/blob/da8636ef/src/protocols/rdp/rdp_settings.h
----------------------------------------------------------------------
diff --git a/src/protocols/rdp/rdp_settings.h b/src/protocols/rdp/rdp_settings.h
index bcbe9b6..3ff634a 100644
--- a/src/protocols/rdp/rdp_settings.h
+++ b/src/protocols/rdp/rdp_settings.h
@@ -388,6 +388,51 @@ typedef struct guac_rdp_settings {
*/
int enable_audio_input;
+#ifdef HAVE_FREERDP_GATEWAY_SUPPORT
+ /**
+ * The hostname of the remote desktop gateway that should be used as an
+ * intermediary for the remote desktop connection. If no gateway should
+ * be used, this will be NULL.
+ */
+ char* gateway_hostname;
+
+ /**
+ * The port of the remote desktop gateway that should be used as an
+ * intermediary for the remote desktop connection. NOTE: versions of
+ * FreeRDP prior to 1.2 which have gateway support ignore this value, and
+ * instead use a hard-coded value of 443.
+ */
+ int gateway_port;
+
+ /**
+ * The domain of the user authenticating with the remote desktop gateway,
+ * if a gateway is being used. This is not necessarily the same as the
+ * user actually using the remote desktop connection.
+ */
+ char* gateway_domain;
+
+ /**
+ * The username of the user authenticating with the remote desktop gateway,
+ * if a gateway is being used. This is not necessarily the same as the
+ * user actually using the remote desktop connection.
+ */
+ char* gateway_username;
+
+ /**
+ * The password to provide when authenticating with the remote desktop
+ * gateway, if a gateway is being used.
+ */
+ char* gateway_password;
+#endif
+
+#ifdef HAVE_FREERDP_LOAD_BALANCER_SUPPORT
+ /**
+ * The load balancing information/cookie which should be provided to
+ * the connection broker, if a connection broker is being used.
+ */
+ char* load_balance_info;
+#endif
+
} guac_rdp_settings;
/**
[3/4] incubator-guacamole-server git commit: GUACAMOLE-40: Set RD
gateway and load balancing settings for FreeRDP where applicable.
Posted by jm...@apache.org.
GUACAMOLE-40: Set RD gateway and load balancing settings for FreeRDP where applicable.
Project: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/commit/09099050
Tree: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/tree/09099050
Diff: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/diff/09099050
Branch: refs/heads/master
Commit: 09099050cb2448a6b40ac3b17eab59f47c57d6a2
Parents: da8636e
Author: Michael Jumper <mj...@apache.org>
Authored: Mon Apr 10 00:13:38 2017 -0700
Committer: Michael Jumper <mj...@apache.org>
Committed: Mon Apr 10 00:13:38 2017 -0700
----------------------------------------------------------------------
src/protocols/rdp/rdp_settings.c | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/blob/09099050/src/protocols/rdp/rdp_settings.c
----------------------------------------------------------------------
diff --git a/src/protocols/rdp/rdp_settings.c b/src/protocols/rdp/rdp_settings.c
index 1ec34b9..998f0a2 100644
--- a/src/protocols/rdp/rdp_settings.c
+++ b/src/protocols/rdp/rdp_settings.c
@@ -1249,6 +1249,34 @@ void guac_rdp_push_settings(guac_rdp_settings* guac_settings, freerdp* rdp) {
}
#endif
+#ifdef HAVE_FREERDP_GATEWAY_SUPPORT
+ /* Enable use of RD gateway if a gateway hostname is provided */
+ if (guac_settings->gateway_hostname != NULL) {
+
+ /* Enable RD gateway */
+ rdp_settings->GatewayEnabled = TRUE;
+
+ /* RD gateway connection details */
+ rdp_settings->GatewayHostname = guac_rdp_strdup(guac_settings->gateway_hostname);
+ rdp_settings->GatewayPort = guac_settings->gateway_port;
+
+ /* RD gateway credentials */
+ rdp_settings->GatewayUseSameCredentials = FALSE;
+ rdp_settings->GatewayDomain = guac_rdp_strdup(guac_settings->gateway_domain);
+ rdp_settings->GatewayUsername = guac_rdp_strdup(guac_settings->gateway_username);
+ rdp_settings->GatewayPassword = guac_rdp_strdup(guac_settings->gateway_password);
+
+ }
+#endif
+
+#ifdef HAVE_FREERDP_LOAD_BALANCER_SUPPORT
+ /* Store load balance info (and calculate length) if provided */
+ if (guac_settings->load_balance_info != NULL) {
+ rdp_settings->LoadBalanceInfo = (BYTE*) guac_rdp_strdup(guac_settings->load_balance_info);
+ rdp_settings->LoadBalanceInfoLength = strlen(guac_settings->load_balance_info);
+ }
+#endif
+
/* Order support */
#ifdef LEGACY_RDPSETTINGS
bitmap_cache = rdp_settings->bitmap_cache;