diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..86b613e --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/gtk-vnc-0.9.0.tar.xz diff --git a/0001-fix-crash-when-connection-fails-early.patch b/0001-fix-crash-when-connection-fails-early.patch new file mode 100644 index 0000000..555e3d9 --- /dev/null +++ b/0001-fix-crash-when-connection-fails-early.patch @@ -0,0 +1,86 @@ +From ac1960bcc8e2678c0431d11eb7603ad674937f6d Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= +Date: Fri, 24 Aug 2018 17:18:04 +0100 +Subject: [PATCH] fix crash when connection fails early +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +When reading the initial greeting a timer is set in the background. If +the connection fails early, we can jump to cleanup code before the timer +is disable. The timer will later fire, read a coroutine context from +freed memory, and likely jump to somewhere awful with predictably crashy +results. + + https://bugzilla.redhat.com/show_bug.cgi?id=1620203 + +Signed-off-by: Daniel P. Berrangé +(cherry picked from commit 06a27a4fb52653b4cbf67b75b8116cf6692b435d) +--- + src/vncconnection.c | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +diff --git a/src/vncconnection.c b/src/vncconnection.c +index b6e13d5..afc1418 100644 +--- a/src/vncconnection.c ++++ b/src/vncconnection.c +@@ -319,7 +319,9 @@ static gboolean vnc_connection_timeout(gpointer data) + { + struct wait_queue *wait = data; + ++ VNC_DEBUG("Connection timeout wakeup start %p", data); + g_io_wakeup(wait); ++ VNC_DEBUG("Connection timeout wakeup done %p", data); + + return FALSE; + } +@@ -5318,6 +5320,7 @@ static gboolean vnc_connection_initialize(VncConnection *conn) + + priv->absPointer = TRUE; + ++ VNC_DEBUG("Schedule greeting timeout %p", &priv->wait); + timeout = g_timeout_add_seconds(2, vnc_connection_timeout, &priv->wait); + want = 12; + while (want > 0) { +@@ -5369,7 +5372,9 @@ static gboolean vnc_connection_initialize(VncConnection *conn) + } + + if (timeout != 0) { ++ VNC_DEBUG("Remove timeout %p", &priv->wait); + g_source_remove(timeout); ++ timeout = 0; + } + + version[12] = 0; +@@ -5449,6 +5454,11 @@ static gboolean vnc_connection_initialize(VncConnection *conn) + return !vnc_connection_has_error(conn); + + fail: ++ if (timeout != 0) { ++ VNC_DEBUG("Remove timeout %p", &priv->wait); ++ g_source_remove(timeout); ++ timeout = 0; ++ } + return !vnc_connection_has_error(conn); + } + +@@ -5481,6 +5491,7 @@ static GSocket *vnc_connection_connect_socket(struct wait_queue *wait, + if (!sock) + return NULL; + ++ VNC_DEBUG("Schedule socket timeout %p", wait); + guint timeout = g_timeout_add_seconds(10, vnc_connection_timeout, wait); + + g_socket_set_blocking(sock, FALSE); +@@ -5513,8 +5524,10 @@ timeout: + sock = NULL; + + end: +- if (timeout != 0) ++ if (timeout != 0) { ++ VNC_DEBUG("Remove timeout %p", wait); + g_source_remove(timeout); ++ } + + return sock; + } diff --git a/0002-gvnc-1.0.pc.in-Use-GLIB_REQUIRED.patch b/0002-gvnc-1.0.pc.in-Use-GLIB_REQUIRED.patch new file mode 100644 index 0000000..be0b3d0 --- /dev/null +++ b/0002-gvnc-1.0.pc.in-Use-GLIB_REQUIRED.patch @@ -0,0 +1,25 @@ +From fe11054a9940cdb9a9d6bd4b05bd2276a51d0abf Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Guido=20G=C3=BCnther?= +Date: Thu, 30 Aug 2018 18:08:35 +0200 +Subject: [PATCH] gvnc-1.0.pc.in: Use GLIB_REQUIRED + +GOBJECT_REQUIRED is no more + +(cherry picked from commit 41c32208248b028f2c96da4d20ba6dc8e51b83ad) +--- + gvnc-1.0.pc.in | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/gvnc-1.0.pc.in b/gvnc-1.0.pc.in +index da95b65..b79fdf7 100644 +--- a/gvnc-1.0.pc.in ++++ b/gvnc-1.0.pc.in +@@ -5,7 +5,7 @@ includedir=@includedir@ + + Name: GVNC + Description: GObject for VNC client connections +-Requires: gobject-2.0 >= @GOBJECT_REQUIRED@ ++Requires: gobject-2.0 >= @GLIB_REQUIRED@ + Version: @VERSION@ + Libs: -L${libdir} -lgvnc-1.0 + Cflags: -I${includedir}/gvnc-1.0 diff --git a/0003-sasl-Factor-common-code-auth-failure.patch b/0003-sasl-Factor-common-code-auth-failure.patch new file mode 100644 index 0000000..826364a --- /dev/null +++ b/0003-sasl-Factor-common-code-auth-failure.patch @@ -0,0 +1,63 @@ +From 9fc84302bb18ffb552f2405df7820df9c4bfa2ec Mon Sep 17 00:00:00 2001 +From: Christophe Fergeau +Date: Wed, 9 Jan 2019 14:01:22 +0100 +Subject: [PATCH] sasl: Factor common code auth failure + +The new vnc_connection_auth_failure() method will be reused in the +next commit. + +Signed-off-by: Christophe Fergeau +(cherry picked from commit 83cac0cbe8b8006c50d177650459aaa47f1fd129) +Resolves: rhbz#1688275 +--- + src/vncconnection.c | 17 +++++++++++------ + 1 file changed, 11 insertions(+), 6 deletions(-) + +diff --git a/src/vncconnection.c b/src/vncconnection.c +index afc1418..58455df 100644 +--- a/src/vncconnection.c ++++ b/src/vncconnection.c +@@ -124,6 +124,7 @@ static void vnc_connection_close(VncConnection *conn); + static void vnc_connection_set_error(VncConnection *conn, + const char *format, + ...) G_GNUC_PRINTF(2, 3); ++static void vnc_connection_auth_failure(VncConnection *conn, const char *reason); + + /* + * A special GSource impl which allows us to wait on a certain +@@ -660,6 +661,14 @@ static G_GNUC_PRINTF(2, 3) void vnc_connection_set_error(VncConnection *conn, + vnc_connection_emit_main_context(conn, VNC_ERROR, &s); + } + ++static void vnc_connection_auth_failure(VncConnection *conn, ++ const char *reason) ++{ ++ struct signal_data sigdata; ++ ++ sigdata.params.authReason = reason; ++ vnc_connection_emit_main_context(conn, VNC_AUTH_FAILURE, &sigdata); ++} + + static gboolean vnc_connection_use_compression(VncConnection *conn) + { +@@ -3571,18 +3580,14 @@ static gboolean vnc_connection_check_auth_result(VncConnection *conn) + reason[len] = '\0'; + VNC_DEBUG("Fail %s", reason); + if (!priv->coroutine_stop) { +- struct signal_data sigdata; +- sigdata.params.authReason = reason; + vnc_connection_set_error(conn, "%s", reason); +- vnc_connection_emit_main_context(conn, VNC_AUTH_FAILURE, &sigdata); ++ vnc_connection_auth_failure(conn, reason); + } + } else { + VNC_DEBUG("Fail auth no result"); + if (!priv->coroutine_stop) { +- struct signal_data sigdata; +- sigdata.params.authReason = "Unknown authentication failure"; + vnc_connection_set_error(conn, "%s", "Unknown authentication failure"); +- vnc_connection_emit_main_context(conn, VNC_AUTH_FAILURE, &sigdata); ++ vnc_connection_auth_failure(conn, "Unknown authentication failure"); + } + } + return FALSE; diff --git a/0004-sasl-Emit-vnc-auth-failure-signal-on-SASL-auth-failu.patch b/0004-sasl-Emit-vnc-auth-failure-signal-on-SASL-auth-failu.patch new file mode 100644 index 0000000..2962825 --- /dev/null +++ b/0004-sasl-Emit-vnc-auth-failure-signal-on-SASL-auth-failu.patch @@ -0,0 +1,33 @@ +From 9cadf0ab5071d14066af233a11f994b166454267 Mon Sep 17 00:00:00 2001 +From: Christophe Fergeau +Date: Wed, 9 Jan 2019 14:01:23 +0100 +Subject: [PATCH] sasl: Emit vnc-auth-failure signal on SASL auth failures + +When the SASL username or password are wrong, at the moment client +application will not get any specific notification for it, they will +just know that the remote connection was closed because of an error. + +This commit adds the emission of the vnc-auth-failure signal when +vnc_connection_perform_auth_sasl() fails. + +https://bugzilla.redhat.com/show_bug.cgi?id=1456175 + +Signed-off-by: Christophe Fergeau +(cherry picked from commit 3f4f79ffbf74f31ae65055c03a8eb523ac631422) +Resolves: rhbz#1688275 +--- + src/vncconnection.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/vncconnection.c b/src/vncconnection.c +index 58455df..aceb31d 100644 +--- a/src/vncconnection.c ++++ b/src/vncconnection.c +@@ -4419,6 +4419,7 @@ static gboolean vnc_connection_perform_auth_sasl(VncConnection *conn) + error: + if (saslconn) + sasl_dispose(&saslconn); ++ vnc_connection_auth_failure(conn, "Unknown authentication failure"); + return FALSE; + } + #endif /* HAVE_SASL */ diff --git a/0005-conn-Report-error-if-vnc_connection_perform_auth_vnc.patch b/0005-conn-Report-error-if-vnc_connection_perform_auth_vnc.patch new file mode 100644 index 0000000..ef7f5b2 --- /dev/null +++ b/0005-conn-Report-error-if-vnc_connection_perform_auth_vnc.patch @@ -0,0 +1,66 @@ +From bfc434015456687388370ccfc0fc92fd54c58b4b Mon Sep 17 00:00:00 2001 +From: Christophe Fergeau +Date: Wed, 9 Jan 2019 14:01:24 +0100 +Subject: [PATCH] conn: Report error if vnc_connection_perform_auth_vnc fails + +At the moment, when the various crypto operations that +vnc_connection_perform_auth_vnc performs fail, no error is reported to +the client application. This commit adds the emission of a vnc-error +signal when this happens. This is not reported as an auth failure as +these errors are not something which is recoverable, they indicate +system failures. + +Signed-off-by: Christophe Fergeau +(cherry picked from commit fa21beab5b44354c890699663a71b07d6ce18d40) +Resolves: rhbz#1688275 +--- + src/vncconnection.c | 13 +++++++++---- + 1 file changed, 9 insertions(+), 4 deletions(-) + +diff --git a/src/vncconnection.c b/src/vncconnection.c +index aceb31d..65111fd 100644 +--- a/src/vncconnection.c ++++ b/src/vncconnection.c +@@ -3638,33 +3638,38 @@ static gboolean vnc_connection_perform_auth_vnc(VncConnection *conn) + error = gcry_cipher_open(&c, GCRY_CIPHER_DES, GCRY_CIPHER_MODE_ECB, 0); + if (gcry_err_code (error) != GPG_ERR_NO_ERROR) { + VNC_DEBUG("gcry_cipher_open error: %s\n", gcry_strerror(error)); +- return FALSE; ++ goto error; + } + + error = gcry_cipher_setkey(c, key, 8); + if (gcry_err_code (error) != GPG_ERR_NO_ERROR) { + VNC_DEBUG("gcry_cipher_setkey error: %s\n", gcry_strerror(error)); + gcry_cipher_close(c); +- return FALSE; ++ goto error; + } + + error = gcry_cipher_encrypt(c, challenge, 8, challenge, 8); + if (gcry_err_code (error) != GPG_ERR_NO_ERROR) { + VNC_DEBUG("gcry_cipher_encrypt error: %s\n", gcry_strerror(error)); + gcry_cipher_close(c); +- return FALSE; ++ goto error; + } + error = gcry_cipher_encrypt(c, challenge + 8, 8, challenge + 8, 8); + if (gcry_err_code (error) != GPG_ERR_NO_ERROR) { + VNC_DEBUG("gcry_cipher_encrypt error: %s\n", gcry_strerror(error)); + gcry_cipher_close(c); +- return FALSE; ++ goto error; + } + gcry_cipher_close(c); + + vnc_connection_write(conn, challenge, 16); + vnc_connection_flush(conn); + return vnc_connection_check_auth_result(conn); ++ ++error: ++ vnc_connection_set_error(conn, "%s: %s", "Unknown authentication failure: %s", ++ gcry_strerror(error)); ++ return FALSE; + } + + /* diff --git a/0006-conn-Remove-redundant-vnc_connection_has_error-calls.patch b/0006-conn-Remove-redundant-vnc_connection_has_error-calls.patch new file mode 100644 index 0000000..452de49 --- /dev/null +++ b/0006-conn-Remove-redundant-vnc_connection_has_error-calls.patch @@ -0,0 +1,73 @@ +From 74fcc039b313a0d3b91d15b83b4d4df4aa84536e Mon Sep 17 00:00:00 2001 +From: Christophe Fergeau +Date: Wed, 9 Jan 2019 14:01:25 +0100 +Subject: [PATCH] conn: Remove redundant vnc_connection_has_error() calls + +No need to call it twice in: +if (vnc_connection_has_error(conn)) + return !vnc_connection_has_error(conn); + +and no need to call it after calling vnc_connection_set_error() as it +will always return TRUE in this scenario. + +Signed-off-by: Christophe Fergeau +(cherry picked from commit 247eaddd7455ee4eb80efe4971167ab0636a4509) +Resolves: rhbz#1688275 +--- + src/vncconnection.c | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +diff --git a/src/vncconnection.c b/src/vncconnection.c +index 65111fd..fd7468b 100644 +--- a/src/vncconnection.c ++++ b/src/vncconnection.c +@@ -3120,7 +3120,7 @@ static gboolean vnc_connection_framebuffer_update(VncConnection *conn, gint32 et + etype, width, height, x, y); + + if (vnc_connection_has_error(conn)) +- return !vnc_connection_has_error(conn); ++ return FALSE; + + switch (etype) { + case VNC_CONNECTION_ENCODING_RAW: +@@ -3292,7 +3292,7 @@ static gboolean vnc_connection_server_message(VncConnection *conn) + int ret; + + if (vnc_connection_has_error(conn)) +- return !vnc_connection_has_error(conn); ++ return FALSE; + + /* NB: make sure that all server message functions + handle has_error appropriately */ +@@ -5838,7 +5838,7 @@ gboolean vnc_connection_set_auth_type(VncConnection *conn, unsigned int type) + VNC_DEBUG("Thinking about auth type %u", type); + if (priv->auth_type != VNC_CONNECTION_AUTH_INVALID) { + vnc_connection_set_error(conn, "%s", "Auth type has already been set"); +- return !vnc_connection_has_error(conn); ++ return FALSE; + } + if (type != VNC_CONNECTION_AUTH_NONE && + type != VNC_CONNECTION_AUTH_VNC && +@@ -5851,7 +5851,7 @@ gboolean vnc_connection_set_auth_type(VncConnection *conn, unsigned int type) + vnc_connection_set_error(conn, "Auth type %u is not supported", + type); + g_signal_emit(conn, VNC_AUTH_UNSUPPORTED, 0, type); +- return !vnc_connection_has_error(conn); ++ return FALSE; + } + VNC_DEBUG("Decided on auth type %u", type); + priv->auth_type = type; +@@ -5880,11 +5880,11 @@ gboolean vnc_connection_set_auth_subtype(VncConnection *conn, unsigned int type) + priv->auth_type != VNC_CONNECTION_AUTH_TLS) { + vnc_connection_set_error(conn, "Auth type %u does not support subauth", + priv->auth_type); +- return !vnc_connection_has_error(conn); ++ return FALSE; + } + if (priv->auth_subtype != VNC_CONNECTION_AUTH_INVALID) { + vnc_connection_set_error(conn, "%s", "Auth subtype has already been set"); +- return !vnc_connection_has_error(conn); ++ return FALSE; + } + priv->auth_subtype = type; + diff --git a/0007-conn-Use-vnc_connection_has_error-extensively.patch b/0007-conn-Use-vnc_connection_has_error-extensively.patch new file mode 100644 index 0000000..8583b52 --- /dev/null +++ b/0007-conn-Use-vnc_connection_has_error-extensively.patch @@ -0,0 +1,333 @@ +From fe4d5599a9aec8bcd2ad53d8e124630a53cd8394 Mon Sep 17 00:00:00 2001 +From: Christophe Fergeau +Date: Wed, 9 Jan 2019 14:01:26 +0100 +Subject: [PATCH] conn: Use vnc_connection_has_error() extensively + +It's better to call this helper rather than directly checking for +priv->coroutine_stop. + +Signed-off-by: Christophe Fergeau +(cherry picked from commit ad6478a1e522f5e0c2f396ac3600dc35df5871a8) +Resolves: rhbz#1688275 +--- + src/vncconnection.c | 77 ++++++++++++++++++++++----------------------- + 1 file changed, 37 insertions(+), 40 deletions(-) + +diff --git a/src/vncconnection.c b/src/vncconnection.c +index fd7468b..bbf4373 100644 +--- a/src/vncconnection.c ++++ b/src/vncconnection.c +@@ -736,7 +736,7 @@ static int vnc_connection_read_wire(VncConnection *conn, void *data, size_t len) + + reread: + +- if (priv->coroutine_stop) return -EINVAL; ++ if (vnc_connection_has_error(conn)) return -EINVAL; + + if (priv->tls_session) { + ret = gnutls_read(priv->tls_session, data, len); +@@ -885,7 +885,7 @@ static int vnc_connection_read(VncConnection *conn, void *data, size_t len) + char *ptr = data; + size_t offset = 0; + +- if (priv->coroutine_stop) return -EINVAL; ++ if (vnc_connection_has_error(conn)) return -EINVAL; + + while (offset < len) { + size_t tmp; +@@ -941,7 +941,7 @@ static void vnc_connection_flush_wire(VncConnection *conn, + int ret; + gboolean blocking = FALSE; + +- if (priv->coroutine_stop) return; ++ if (vnc_connection_has_error(conn)) return; + + if (priv->tls_session) { + ret = gnutls_write(priv->tls_session, +@@ -2878,10 +2878,9 @@ static void vnc_connection_tight_update(VncConnection *conn, + + static void vnc_connection_update(VncConnection *conn, int x, int y, int width, int height) + { +- VncConnectionPrivate *priv = conn->priv; + struct signal_data sigdata; + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return; + + VNC_DEBUG("Notify update area (%dx%d) at location %d,%d", width, height, x, y); +@@ -2896,10 +2895,9 @@ static void vnc_connection_update(VncConnection *conn, int x, int y, int width, + + static void vnc_connection_bell(VncConnection *conn) + { +- VncConnectionPrivate *priv = conn->priv; + struct signal_data sigdata; + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return; + + VNC_DEBUG("Server beep"); +@@ -2911,11 +2909,10 @@ static void vnc_connection_server_cut_text(VncConnection *conn, + const void *data, + size_t len) + { +- VncConnectionPrivate *priv = conn->priv; + struct signal_data sigdata; + GString *text; + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return; + + text = g_string_new_len ((const gchar *)data, len); +@@ -2933,7 +2930,7 @@ static void vnc_connection_resize(VncConnection *conn, int width, int height) + + VNC_DEBUG("Desktop resize w=%d h=%d", width, height); + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return; + + priv->width = width; +@@ -2949,7 +2946,7 @@ static void vnc_connection_pixel_format(VncConnection *conn) + VncConnectionPrivate *priv = conn->priv; + struct signal_data sigdata; + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return; + + sigdata.params.pixelFormat = &priv->fmt; +@@ -2967,7 +2964,7 @@ static void vnc_connection_pointer_type_change(VncConnection *conn, gboolean abs + return; + priv->absPointer = absPointer; + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return; + + sigdata.params.absPointer = absPointer; +@@ -3028,7 +3025,7 @@ static void vnc_connection_rich_cursor(VncConnection *conn, guint16 x, guint16 y + priv->cursor = vnc_cursor_new(pixbuf, x, y, width, height); + } + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return; + + sigdata.params.cursor = priv->cursor; +@@ -3093,7 +3090,7 @@ static void vnc_connection_xcursor(VncConnection *conn, guint16 x, guint16 y, gu + priv->cursor = vnc_cursor_new(pixbuf, x, y, width, height); + } + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return; + + sigdata.params.cursor = priv->cursor; +@@ -3405,7 +3402,7 @@ static gboolean vnc_connection_server_message(VncConnection *conn) + + n_type = vnc_connection_read_u8(conn); + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + break; + + switch (n_type) { +@@ -3423,7 +3420,7 @@ static gboolean vnc_connection_server_message(VncConnection *conn) + n_length, 1024 * 1024); + break; + } +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + break; + + if (!priv->audio) { +@@ -3491,7 +3488,7 @@ static gboolean vnc_connection_has_credentials(gpointer data) + VncConnection *conn = data; + VncConnectionPrivate *priv = conn->priv; + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return TRUE; + if (priv->want_cred_username && !priv->cred_username) + return FALSE; +@@ -3508,7 +3505,7 @@ static gboolean vnc_connection_gather_credentials(VncConnection *conn) + + VNC_DEBUG("Checking if credentials are needed"); + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + + if (!vnc_connection_has_credentials(conn)) { +@@ -3546,7 +3543,7 @@ static gboolean vnc_connection_gather_credentials(VncConnection *conn) + + g_value_array_free(authCred); + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + VNC_DEBUG("Waiting for missing credentials"); + g_condition_wait(vnc_connection_has_credentials, conn); +@@ -3579,13 +3576,13 @@ static gboolean vnc_connection_check_auth_result(VncConnection *conn) + vnc_connection_read(conn, reason, len); + reason[len] = '\0'; + VNC_DEBUG("Fail %s", reason); +- if (!priv->coroutine_stop) { ++ if (!vnc_connection_has_error(conn)) { + vnc_connection_set_error(conn, "%s", reason); + vnc_connection_auth_failure(conn, reason); + } + } else { + VNC_DEBUG("Fail auth no result"); +- if (!priv->coroutine_stop) { ++ if (!vnc_connection_has_error(conn)) { + vnc_connection_set_error(conn, "%s", "Unknown authentication failure"); + vnc_connection_auth_failure(conn, "Unknown authentication failure"); + } +@@ -4197,7 +4194,7 @@ static gboolean vnc_connection_perform_auth_sasl(VncConnection *conn) + + /* Get the supported mechanisms from the server */ + mechlistlen = vnc_connection_read_u32(conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + goto error; + if (mechlistlen > SASL_MAX_MECHLIST_LEN) { + vnc_connection_set_error(conn, +@@ -4209,7 +4206,7 @@ static gboolean vnc_connection_perform_auth_sasl(VncConnection *conn) + mechlist = g_malloc(mechlistlen+1); + vnc_connection_read(conn, mechlist, mechlistlen); + mechlist[mechlistlen] = '\0'; +- if (priv->coroutine_stop) { ++ if (vnc_connection_has_error(conn)) { + g_free(mechlist); + mechlist = NULL; + goto error; +@@ -4266,14 +4263,14 @@ static gboolean vnc_connection_perform_auth_sasl(VncConnection *conn) + vnc_connection_write_u32(conn, 0); + } + vnc_connection_flush(conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + goto error; + + + VNC_DEBUG("%s", "Getting sever start negotiation reply"); + /* Read the 'START' message reply from server */ + serverinlen = vnc_connection_read_u32(conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + goto error; + if (serverinlen > SASL_MAX_DATA_LEN) { + vnc_connection_set_error(conn, +@@ -4292,7 +4289,7 @@ static gboolean vnc_connection_perform_auth_sasl(VncConnection *conn) + serverin = NULL; + } + complete = vnc_connection_read_u8(conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + goto error; + + VNC_DEBUG("Client start result complete: %d. Data %u bytes %p '%s'", +@@ -4354,13 +4351,13 @@ static gboolean vnc_connection_perform_auth_sasl(VncConnection *conn) + vnc_connection_write_u32(conn, 0); + } + vnc_connection_flush(conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + goto error; + + VNC_DEBUG("Server step with %u bytes %p", clientoutlen, clientout); + + serverinlen = vnc_connection_read_u32(conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + goto error; + if (serverinlen > SASL_MAX_DATA_LEN) { + vnc_connection_set_error(conn, +@@ -4379,7 +4376,7 @@ static gboolean vnc_connection_perform_auth_sasl(VncConnection *conn) + serverin = NULL; + } + complete = vnc_connection_read_u8(conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + goto error; + + VNC_DEBUG("Client step result complete: %d. Data %u bytes %p '%s'", +@@ -4524,7 +4521,7 @@ static gboolean vnc_connection_has_auth_subtype(gpointer data) + VncConnection *conn = data; + VncConnectionPrivate *priv = conn->priv; + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return TRUE; + if (priv->auth_subtype == VNC_CONNECTION_AUTH_INVALID) + return FALSE; +@@ -4597,15 +4594,15 @@ static gboolean vnc_connection_perform_auth_tls(VncConnection *conn) + VNC_DEBUG("Possible TLS sub-auth %u", auth[i]); + } + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + vnc_connection_choose_auth(conn, VNC_AUTH_CHOOSE_SUBTYPE, nauth, auth); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + + VNC_DEBUG("Waiting for TLS auth subtype"); + g_condition_wait(vnc_connection_has_auth_subtype, conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + + VNC_DEBUG("Choose auth %u", priv->auth_subtype); +@@ -4672,15 +4669,15 @@ static gboolean vnc_connection_perform_auth_vencrypt(VncConnection *conn) + VNC_DEBUG("Possible VeNCrypt sub-auth %u", auth[i]); + } + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + vnc_connection_choose_auth(conn, VNC_AUTH_CHOOSE_SUBTYPE, nauth, auth); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + + VNC_DEBUG("Waiting for VeNCrypt auth subtype"); + g_condition_wait(vnc_connection_has_auth_subtype, conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + + VNC_DEBUG("Choose auth %u", priv->auth_subtype); +@@ -4753,7 +4750,7 @@ static gboolean vnc_connection_has_auth_type(gpointer data) + VncConnection *conn = data; + VncConnectionPrivate *priv = conn->priv; + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return TRUE; + if (priv->auth_type == VNC_CONNECTION_AUTH_INVALID) + return FALSE; +@@ -4790,15 +4787,15 @@ static gboolean vnc_connection_perform_auth(VncConnection *conn) + VNC_DEBUG("Possible auth %u", auth[i]); + } + +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + vnc_connection_choose_auth(conn, VNC_AUTH_CHOOSE_TYPE, nauth, auth); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + + VNC_DEBUG("Waiting for auth type"); + g_condition_wait(vnc_connection_has_auth_type, conn); +- if (priv->coroutine_stop) ++ if (vnc_connection_has_error(conn)) + return FALSE; + + VNC_DEBUG("Choose auth %u", priv->auth_type); diff --git a/0008-vnc_connection_start_tls-add-deinit-label.patch b/0008-vnc_connection_start_tls-add-deinit-label.patch new file mode 100644 index 0000000..6f689af --- /dev/null +++ b/0008-vnc_connection_start_tls-add-deinit-label.patch @@ -0,0 +1,75 @@ +From a820d8623e5eae48cb08b624c85fc846a198df16 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?J=C3=A1n=20Tomko?= +Date: Fri, 11 Jan 2019 16:34:30 +0100 +Subject: [PATCH] vnc_connection_start_tls: add deinit label +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Introduce a deinit label to unify cleanup paths which call gnutls_deinit. + +Signed-off-by: Ján Tomko +(cherry picked from commit e62d010777eecda47829e9da54bad3387f4d6231) +Resolves: rhbz#1665837 +--- + src/vncconnection.c | 19 +++++++++---------- + 1 file changed, 9 insertions(+), 10 deletions(-) + +diff --git a/src/vncconnection.c b/src/vncconnection.c +index bbf4373..7b15211 100644 +--- a/src/vncconnection.c ++++ b/src/vncconnection.c +@@ -4445,22 +4445,19 @@ static gboolean vnc_connection_start_tls(VncConnection *conn, int anonTLS) + } + + if (gnutls_priority_set_direct(priv->tls_session, priority, NULL) < 0) { +- gnutls_deinit(priv->tls_session); + vnc_connection_set_error(conn, "%s", "Failed to set priority"); +- return FALSE; ++ goto deinit; + } + + if (anonTLS) { + gnutls_anon_client_credentials anon_cred = vnc_connection_tls_initialize_anon_cred(); + if (!anon_cred) { +- gnutls_deinit(priv->tls_session); + vnc_connection_set_error(conn, "%s", "Failed to allocate credentials"); +- return FALSE; ++ goto deinit; + } + if (gnutls_credentials_set(priv->tls_session, GNUTLS_CRD_ANON, anon_cred) < 0) { +- gnutls_deinit(priv->tls_session); + vnc_connection_set_error(conn, "%s", "Failed to initialize credentials"); +- return FALSE; ++ goto deinit; + } + } else { + priv->want_cred_password = FALSE; +@@ -4471,14 +4468,12 @@ static gboolean vnc_connection_start_tls(VncConnection *conn, int anonTLS) + + gnutls_certificate_credentials_t x509_cred = vnc_connection_tls_initialize_cert_cred(conn); + if (!x509_cred) { +- gnutls_deinit(priv->tls_session); + vnc_connection_set_error(conn, "%s", "Failed to allocate credentials"); +- return FALSE; ++ goto deinit; + } + if (gnutls_credentials_set(priv->tls_session, GNUTLS_CRD_CERTIFICATE, x509_cred) < 0) { +- gnutls_deinit(priv->tls_session); + vnc_connection_set_error(conn, "%s", "Failed to initialize credentials"); +- return FALSE; ++ goto deinit; + } + } + +@@ -4514,6 +4509,10 @@ static gboolean vnc_connection_start_tls(VncConnection *conn, int anonTLS) + } + return TRUE; + } ++ ++ deinit: ++ gnutls_deinit(priv->tls_session); ++ return FALSE; + } + + static gboolean vnc_connection_has_auth_subtype(gpointer data) diff --git a/0009-vnc_connection_start_tls-set-tls_session-to-NULL-aft.patch b/0009-vnc_connection_start_tls-set-tls_session-to-NULL-aft.patch new file mode 100644 index 0000000..b8df57e --- /dev/null +++ b/0009-vnc_connection_start_tls-set-tls_session-to-NULL-aft.patch @@ -0,0 +1,60 @@ +From 47fdacf72c35cb89071084171e020b4846b3fbd6 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?J=C3=A1n=20Tomko?= +Date: Fri, 11 Jan 2019 16:34:31 +0100 +Subject: [PATCH] vnc_connection_start_tls: set tls_session to NULL after + deinit +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Avoid a double free in case of a failure, e.g. when vnc_connection_tls_initialize_cert_cred +fails to read the certificate: + +==1154== Invalid read of size 4 +==1154== at 0x60870FB: gnutls_bye (record.c:288) +==1154== by 0x4A46B73: vnc_connection_close (vncconnection.c:5120) +==1154== by 0x4A4E6CA: vnc_connection_coroutine (vncconnection.c:5650) +==1154== by 0x4A51BCE: coroutine_trampoline (coroutine_ucontext.c:55) +==1154== by 0x5BD81FF: ??? (in /usr/lib64/libc-2.28.so) +==1154== by 0x175DB277: ??? +==1154== Address 0x1847fcf0 is 384 bytes inside a block of size 6,496 free'd +==1154== at 0x4839A0C: free (vg_replace_malloc.c:540) +==1154== by 0x4A4B019: vnc_connection_start_tls (vncconnection.c:4466) +==1154== by 0x4A4CBE8: vnc_connection_perform_auth_vencrypt (vncconnection.c:4708) +==1154== by 0x4A4CBE8: vnc_connection_perform_auth (vncconnection.c:4818) +==1154== by 0x4A4CBE8: vnc_connection_initialize (vncconnection.c:5415) +==1154== by 0x4A4E50F: vnc_connection_coroutine (vncconnection.c:5639) +==1154== by 0x4A51BCE: coroutine_trampoline (coroutine_ucontext.c:55) +==1154== by 0x5BD81FF: ??? (in /usr/lib64/libc-2.28.so) +==1154== by 0x175DB277: ??? +==1154== Block was alloc'd at +==1154== at 0x483AB1A: calloc (vg_replace_malloc.c:762) +==1154== by 0x60B6FDE: gnutls_init (state.c:465) +==1154== by 0x4A4AB28: vnc_connection_start_tls (vncconnection.c:4434) +==1154== by 0x4A4CBE8: vnc_connection_perform_auth_vencrypt (vncconnection.c:4708) +==1154== by 0x4A4CBE8: vnc_connection_perform_auth (vncconnection.c:4818) +==1154== by 0x4A4CBE8: vnc_connection_initialize (vncconnection.c:5415) +==1154== by 0x4A4E50F: vnc_connection_coroutine (vncconnection.c:5639) +==1154== by 0x4A51BCE: coroutine_trampoline (coroutine_ucontext.c:55) +==1154== by 0x5BD81FF: ??? (in /usr/lib64/libc-2.28.so) +==1154== by 0x175DB277: ??? + +Signed-off-by: Ján Tomko +(cherry picked from commit 7879ae9c747b4e95bb3850c4e67ca57d3ded82e3) +Resolves: rhbz#1665837 +--- + src/vncconnection.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/vncconnection.c b/src/vncconnection.c +index 7b15211..5321731 100644 +--- a/src/vncconnection.c ++++ b/src/vncconnection.c +@@ -4512,6 +4512,7 @@ static gboolean vnc_connection_start_tls(VncConnection *conn, int anonTLS) + + deinit: + gnutls_deinit(priv->tls_session); ++ priv->tls_session = NULL; + return FALSE; + } + diff --git a/EMPTY b/EMPTY deleted file mode 100644 index 0519ecb..0000000 --- a/EMPTY +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/gtk-vnc.spec b/gtk-vnc.spec new file mode 100644 index 0000000..098f6de --- /dev/null +++ b/gtk-vnc.spec @@ -0,0 +1,672 @@ +# -*- rpm-spec -*- + +# This spec file assumes you are building for Fedora 26 or newer, +# or for RHEL 6 or newer. It may need some tweaks for other distros. + +%global with_gir 0 +%if 0%{?fedora} || 0%{?rhel} >= 7 +%global with_gir 1 +%endif + +%global with_gtk2 1 +%if 0%{?rhel} >= 8 +%global with_gtk2 0 +%endif + +%global with_gtk3 0 +%if 0%{?fedora} || 0%{?rhel} >= 7 +%global with_gtk3 1 +%endif + +%global with_vala 0 +%if 0%{with_gtk3} +%global with_vala 1 +%endif + +%if 0%{?fedora} || 0%{?rhel} >= 8 + %global tls_priority "@LIBVIRT,SYSTEM" +%else + %global tls_priority "NORMAL" +%endif + +Summary: A GTK2 widget for VNC clients +Name: gtk-vnc +Version: 0.9.0 +Release: 2%{?dist}%{?extra_release} +License: LGPLv2+ +Source: http://ftp.gnome.org/pub/GNOME/sources/%{name}/0.5/%{name}-%{version}.tar.xz +Patch1: 0001-fix-crash-when-connection-fails-early.patch +Patch2: 0002-gvnc-1.0.pc.in-Use-GLIB_REQUIRED.patch +Patch3: 0003-sasl-Factor-common-code-auth-failure.patch +Patch4: 0004-sasl-Emit-vnc-auth-failure-signal-on-SASL-auth-failu.patch +Patch5: 0005-conn-Report-error-if-vnc_connection_perform_auth_vnc.patch +Patch6: 0006-conn-Remove-redundant-vnc_connection_has_error-calls.patch +Patch7: 0007-conn-Use-vnc_connection_has_error-extensively.patch +Patch8: 0008-vnc_connection_start_tls-add-deinit-label.patch +Patch9: 0009-vnc_connection_start_tls-set-tls_session-to-NULL-aft.patch +URL: https://wiki.gnome.org/Projects/gtk-vnc +Requires: gvnc = %{version}-%{release} +%if %{with_gtk2} +BuildRequires: gtk2-devel >= 2.14 +%endif +%if 0%{?fedora} +BuildRequires: python3 +%else +%if 0%{?rhel} > 7 +BuildRequires: python3-devel +%else +BuildRequires: python +%endif +%endif +BuildRequires: gnutls-devel libgcrypt-devel cyrus-sasl-devel zlib-devel intltool +%if %{with_gir} +BuildRequires: gobject-introspection-devel +%endif +%if %{with_gtk3} +BuildRequires: gtk3-devel +%endif +%if %{with_vala} +BuildRequires: vala-tools +%endif +BuildRequires: pulseaudio-libs-devel +BuildRequires: /usr/bin/pod2man + +%description +gtk-vnc is a VNC viewer widget for GTK2. It is built using coroutines +allowing it to be completely asynchronous while remaining single threaded. + +%if %{with_gtk2} +%package devel +Summary: Development files to build GTK2 applications with gtk-vnc +Requires: %{name} = %{version}-%{release} +Requires: pkgconfig +Requires: gtk2-devel + +%description devel +gtk-vnc is a VNC viewer widget for GTK2. It is built using coroutines +allowing it to be completely asynchronous while remaining single threaded. + +Libraries, includes, etc. to compile with the gtk-vnc library +%endif + +%package -n gvnc +Summary: A GObject for VNC connections + +%description -n gvnc +gvnc is a GObject for managing a VNC connection. It provides all the +infrastructure required to build a VNC client without having to deal +with the raw protocol itself. + +%package -n gvnc-devel +Summary: Libraries, includes, etc. to compile with the gvnc library +Requires: gvnc = %{version}-%{release} +Requires: pkgconfig + +%description -n gvnc-devel +gvnc is a GObject for managing a VNC connection. It provides all the +infrastructure required to build a VNC client without having to deal +with the raw protocol itself. + +Libraries, includes, etc. to compile with the gvnc library + +%package -n gvncpulse +Summary: A Pulse Audio bridge for VNC connections +Requires: gvnc = %{version}-%{release} + +%description -n gvncpulse +gvncpulse is a bridge to the Pulse Audio system for VNC. +It allows VNC clients to play back audio on the local +system + +%package -n gvncpulse-devel +Summary: Libraries, includes, etc. to compile with the gvncpulse library +Requires: gvncpulse = %{version}-%{release} +Requires: pkgconfig + +%description -n gvncpulse-devel +gvncpulse is a bridge to the Pulse Audio system for VNC. +It allows VNC clients to play back audio on the local +system + +Libraries, includes, etc. to compile with the gvnc library + +%package -n gvnc-tools +Summary: Command line VNC tools +Requires: gvnc = %{version}-%{release} + +%description -n gvnc-tools +Provides useful command line utilities for interacting with +VNC servers. Includes the gvnccapture program for capturing +screenshots of a VNC desktop + +%if %{with_gtk3} +%package -n gtk-vnc2 +Summary: A GTK3 widget for VNC clients +Requires: gvnc = %{version}-%{release} + +%description -n gtk-vnc2 +gtk-vnc is a VNC viewer widget for GTK3. It is built using coroutines +allowing it to be completely asynchronous while remaining single threaded. + +%package -n gtk-vnc2-devel +Summary: Development files to build GTK3 applications with gtk-vnc +Requires: gtk-vnc2 = %{version}-%{release} +Requires: pkgconfig +Requires: gtk3-devel + +%description -n gtk-vnc2-devel +gtk-vnc is a VNC viewer widget for GTK3. It is built using coroutines +allowing it to be completely asynchronous while remaining single threaded. + +Libraries, includes, etc. to compile with the gtk-vnc library +%endif + +%prep +%setup -q -n gtk-vnc-%{version} -c +cd gtk-vnc-%{version} +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 +%patch4 -p1 +%patch5 -p1 +%patch6 -p1 +%patch7 -p1 +%patch8 -p1 +%patch9 -p1 +cd .. + +%if %{with_gtk3} +cp -a gtk-vnc-%{version} gtk-vnc2-%{version} +%endif + +%build +%if %{with_gir} +%define gir_arg --enable-introspection=yes +%else +%define gir_arg --enable-introspection=no +%endif + +%if %{with_gtk2} +cd gtk-vnc-%{version} +%configure --with-gtk=2.0 %{gir_arg} \ + --with-tls-priority=%{tls_priority} +%__make %{?_smp_mflags} V=1 +chmod -x examples/*.pl examples/*.js examples/*.py +cd .. +%endif + +%if %{with_gtk3} +cd gtk-vnc2-%{version} + +%configure --with-gtk=3.0 %{gir_arg} \ + --with-tls-priority=%{tls_priority} +%__make %{?_smp_mflags} V=1 +chmod -x examples/*.pl examples/*.js examples/*.py +cd .. +%endif + +%install +rm -fr %{buildroot} +%if %{with_gtk2} +cd gtk-vnc-%{version} +%__make install DESTDIR=%{buildroot} +cd .. +%endif + +%if %{with_gtk3} +cd gtk-vnc2-%{version} +%__make install DESTDIR=%{buildroot} +cd .. +%endif + +rm -f %{buildroot}%{_libdir}/*.a +rm -f %{buildroot}%{_libdir}/*.la + +%find_lang %{name} + +%post -p /sbin/ldconfig + +%postun -p /sbin/ldconfig + +%post -n gvnc -p /sbin/ldconfig + +%postun -n gvnc -p /sbin/ldconfig + +%post -n gvncpulse -p /sbin/ldconfig + +%postun -n gvncpulse -p /sbin/ldconfig + +%if %{with_gtk3} +%post -n gtk-vnc2 -p /sbin/ldconfig + +%postun -n gtk-vnc2 -p /sbin/ldconfig +%endif + +%if %{with_gtk2} +%files +%{_libdir}/libgtk-vnc-1.0.so.* +%if %{with_gir} +%{_libdir}/girepository-1.0/GtkVnc-1.0.typelib +%endif + +%files devel +%doc gtk-vnc-%{version}/examples/gvncviewer.c +%{_libdir}/libgtk-vnc-1.0.so +%dir %{_includedir}/%{name}-1.0/ +%{_includedir}/%{name}-1.0/*.h +%{_libdir}/pkgconfig/%{name}-1.0.pc +%if %{with_gir} +%{_datadir}/gir-1.0/GtkVnc-1.0.gir +%endif +%endif + +%files -n gvnc -f %{name}.lang +%{_libdir}/libgvnc-1.0.so.* +%if %{with_gir} +%{_libdir}/girepository-1.0/GVnc-1.0.typelib +%endif +%if %{with_vala} +%{_datadir}/vala/vapi/gvnc-1.0.deps +%{_datadir}/vala/vapi/gvnc-1.0.vapi +%endif + +%files -n gvnc-devel +%{_libdir}/libgvnc-1.0.so +%dir %{_includedir}/gvnc-1.0/ +%{_includedir}/gvnc-1.0/*.h +%{_libdir}/pkgconfig/gvnc-1.0.pc +%if %{with_gir} +%{_datadir}/gir-1.0/GVnc-1.0.gir +%endif + +%files -n gvncpulse -f %{name}.lang +%{_libdir}/libgvncpulse-1.0.so.* +%if %{with_gir} +%{_libdir}/girepository-1.0/GVncPulse-1.0.typelib +%endif +%if %{with_vala} +%{_datadir}/vala/vapi/gvncpulse-1.0.deps +%{_datadir}/vala/vapi/gvncpulse-1.0.vapi +%endif + +%files -n gvncpulse-devel +%{_libdir}/libgvncpulse-1.0.so +%dir %{_includedir}/gvncpulse-1.0/ +%{_includedir}/gvncpulse-1.0/*.h +%{_libdir}/pkgconfig/gvncpulse-1.0.pc +%if %{with_gir} +%{_datadir}/gir-1.0/GVncPulse-1.0.gir +%endif + +%files -n gvnc-tools +%doc gtk-vnc-%{version}/AUTHORS +%doc gtk-vnc-%{version}/ChangeLog +%doc gtk-vnc-%{version}/ChangeLog-old +%doc gtk-vnc-%{version}/NEWS +%doc gtk-vnc-%{version}/README +%doc gtk-vnc-%{version}/COPYING.LIB +%{_bindir}/gvnccapture +%{_mandir}/man1/gvnccapture.1* + +%if %{with_gtk3} +%files -n gtk-vnc2 +%{_libdir}/libgtk-vnc-2.0.so.* +%if %{with_gir} +%{_libdir}/girepository-1.0/GtkVnc-2.0.typelib +%endif +%if %{with_vala} +%{_datadir}/vala/vapi/gtk-vnc-2.0.deps +%{_datadir}/vala/vapi/gtk-vnc-2.0.vapi +%endif + +%files -n gtk-vnc2-devel +%doc gtk-vnc2-%{version}/examples/gvncviewer.c +%if %{with_gir} +%doc gtk-vnc2-%{version}/examples/gvncviewer.js +%doc gtk-vnc2-%{version}/examples/gvncviewer.pl +%doc gtk-vnc2-%{version}/examples/gvncviewer.py +%endif +%{_libdir}/libgtk-vnc-2.0.so +%dir %{_includedir}/%{name}-2.0/ +%{_includedir}/%{name}-2.0/*.h +%{_libdir}/pkgconfig/%{name}-2.0.pc +%if %{with_gir} +%{_datadir}/gir-1.0/GtkVnc-2.0.gir +%endif +%endif + +%changelog +* Thu Nov 28 2019 Daniel P. Berrangé - 0.9.0-2 +- Fix crash when TLS handshake fails (rhbz #1665837) +- Ensure auth failure signal is emitted when SASL fails (rhbz #1688275) + +* Thu Aug 30 2018 Daniel P. Berrangé - 0.9.0-1 +- Update to 0.9.0 release +- Use gcrypt for DES impl instead of local DES impl (rhbz #1618426) +- Fix crash if connection fails early (rhbz #1622189) + +* Mon Aug 13 2018 Troy Dawson - 0.8.0-2 +- Add BuildRequest python3-devel + +* Wed Aug 1 2018 Daniel P. Berrangé - 0.8.0-1 +- Update to 0.8.0 release + +* Mon Jul 23 2018 Daniel P. Berrangé - 0.7.2-2 +- Force python3 for build +- Disable GTK2 library build + +* Fri Mar 23 2018 Daniel P. Berrangé - 0.7.2-1 +- Rebase to 0.7.2 release +- Disable python2 sub-RPM + +* Wed Feb 14 2018 Iryna Shcherbina - 0.7.1-7 +- Update Python 2 dependency declarations to new packaging standards + (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3) + +* Wed Feb 07 2018 Fedora Release Engineering - 0.7.1-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild + +* Sun Aug 20 2017 Zbigniew Jędrzejewski-Szmek - 0.7.1-5 +- Add Provides for the old name without %%_isa + +* Sat Aug 19 2017 Zbigniew Jędrzejewski-Szmek - 0.7.1-4 +- Python 2 binary package renamed to python2-gtk-vnc + See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3 + +* Wed Aug 02 2017 Fedora Release Engineering - 0.7.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild + +* Wed Jul 26 2017 Fedora Release Engineering - 0.7.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild + +* Fri May 19 2017 Daniel P. Berrange - 0.7.1-1 +- Update to 0.7.1 release +- Fix incompatibility with libvncserver/x11vnc (rhbz #1421785) + +* Thu Feb 9 2017 Daniel P. Berrange - 0.7.0-1 +- Update to 0.7.0 release +- CVE-2017-5884 - fix bounds checking for RRE, hextile and + copyrect encodings +- CVE-2017-5885 - fix color map index bounds checking + +* Thu Oct 6 2016 Daniel P. Berrange - 0.6.0-1 +- Update to 0.6.0 release + +* Tue Jul 19 2016 Fedora Release Engineering - 0.5.4-4 +- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages + +* Wed Feb 03 2016 Fedora Release Engineering - 0.5.4-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + +* Wed Jun 17 2015 Fedora Release Engineering - 0.5.4-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + +* Tue Feb 10 2015 Daniel P. Berrange - 0.5.4-1 +- Update to 0.5.4 release + +* Wed Oct 29 2014 Cole Robinson - 0.5.3-6 +- Fix virt-viewer fullscreen widget (bz #1036824) + +* Sat Aug 16 2014 Fedora Release Engineering +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + +* Tue Jul 22 2014 Kalev Lember - 0.5.3-4 +- Rebuilt for gobject-introspection 1.41.4 + +* Sat Jun 07 2014 Fedora Release Engineering - 0.5.3-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + +* Wed Apr 23 2014 Tomáš Mráz - 0.5.3-2 +- Rebuild for new libgcrypt + +* Wed Sep 18 2013 Daniel P. Berrange - 0.5.3-1 +- Update to 0.5.3 release + +* Sat Aug 03 2013 Fedora Release Engineering - 0.5.2-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + +* Thu Jul 18 2013 Petr Pisar - 0.5.2-3 +- Perl 5.18 rebuild +- Build-require libgcrypt-devel + +* Wed May 8 2013 Daniel P. Berrange - 0.5.2-2 +- Turn off execute bit on examples to stop auto-deps being added + +* Fri Feb 22 2013 Daniel P. Berrange - 0.5.2-1 +- Update to 0.5.2 release +- Fix auth credential type (rhbz #697067) + +* Sat Feb 16 2013 Cole Robinson - 0.5.1-7 +- Fix send_key introspection bindings + +* Thu Feb 14 2013 Fedora Release Engineering - 0.5.1-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Mon Dec 10 2012 Adam Jackson 0.5.1-5 +- gtk-vnc-0.5.1-bigendian.patch: Fix pixel swizzling on big-endian. + +* Tue Sep 4 2012 Daniel P. Berrange - 0.5.1-4 +- Add missing deps on gvnc (rhbz #852053) + +* Thu Jul 19 2012 Fedora Release Engineering - 0.5.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Sat Jul 14 2012 Ville Skyttä - 0.5.1-2 +- Call ldconfig at gvnc, gvncpulse, and gtk-vnc2 post(un)install time. + +* Thu Jul 12 2012 Daniel P. Berrange - 0.5.1-1 +- Update to 0.5.1 release + +* Fri Jan 13 2012 Fedora Release Engineering - 0.5.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Wed Dec 21 2011 Daniel P. Berrange - 0.5.0-1 +- Update to 0.5.0 release + +* Thu Nov 10 2011 Daniel P. Berrange - 0.4.4-1 +- Update to 0.4.4 release + +* Tue Nov 08 2011 Adam Jackson - 0.4.3-2 +- Rebuild to break bogus libpng dep + +* Fri Feb 18 2011 Daniel P. Berrange - 0.4.3-1 +- Update to 0.4.3 release + +* Thu Feb 10 2011 Matthias Clasen - 0.4.2-10 +- Rebuild against newer gtk + +* Wed Feb 09 2011 Fedora Release Engineering - 0.4.2-9 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Wed Feb 2 2011 Matthias Clasen - 0.4.2-8 +- Rebuild against newer gtk + +* Thu Jan 13 2011 Daniel P. Berrange - 0.4.2-7 +- Cope with multiple GDK backends in GTK3 + +* Tue Jan 11 2011 Daniel P. Berrange - 0.4.2-6 +- Rebuild for change in GTK3 soname + +* Mon Jan 10 2011 Daniel P. Berrange - 0.4.2-5 +- Add fix to remove use of GdkDrawble for GTK3 compat + +* Sun Jan 9 2011 Matthias Clasen - 0.4.2-5 +- Rebuild against newer gtk3 + +* Tue Dec 14 2010 Daniel P. Berrange - 0.4.2-4 +- Fix unref of GSource objects to address performance degradation (rhbz #657847) + +* Mon Nov 29 2010 Daniel P. Berrange - 0.4.2-3 +- Re-introduce a server side pixmap via cairo to cache framebuffer (rhbz #657542) + +* Mon Nov 29 2010 Daniel P. Berrange - 0.4.2-2 +- Fix crash in TLS shutdown code (rhbz #650601) +- Fix crash in motion event handler (rhbz #650104) +- Fix framebuffer update bounds checking (rhbz #655630) + +* Fri Nov 5 2010 Daniel P. Berrange - 0.4.2-1 +- Update to 0.4.2 release. +- Enable experimental GTK3 build + +* Mon Oct 18 2010 Colin Walters - 0.4.1-9 +- Rebuild to use old pygobject2-python2 API again: + https://bugzilla.redhat.com/show_bug.cgi?id=638457 + +* Wed Sep 29 2010 jkeating - 0.4.1-8 +- Rebuilt for gcc bug 634757 + +* Tue Sep 21 2010 Matthias Clasen - 0.4.1-7 +- Rebuild against newer gobject-introspection + +* Tue Aug 31 2010 Daniel P. Berrange - 0.4.1-6 +- Prevent RPM picking up a dep on gjs (rhbz 628604) + +* Fri Aug 6 2010 Daniel P. Berrange - 0.4.1-5 +- Reset buffer offsets on connection close (rhbz 620843) + +* Thu Aug 5 2010 Daniel P. Berrange - 0.4.1-4 +- Reset buffer pointer on connection close (rhbz 620843) + +* Wed Jul 21 2010 David Malcolm - 0.4.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild + +* Thu Jul 15 2010 Colin Walters - 0.4.1-2 +- Rebuild with new gobject-introspection + +* Wed Jul 14 2010 Daniel P. Berrange - 0.4.1-1 +- Update to 0.4.1 release + +* Sun Jul 11 2010 Daniel P. Berrange - 0.4.0-1 +- Update to 0.4.0 release +- Add new sub-packages for gvnc + +* Tue Apr 27 2010 Daniel P. Berrange - 0.3.10-3 +- Drop VNC connection if the server sends a update spaning outside bounds of desktop (rhbz #540810) +- Fix gcrypt threading initialization (rhbz #537489) + +* Tue Oct 20 2009 Matthias Clasen - 0.3.10-1 +- Update to 0.3.10 + +* Thu Oct 8 2009 Matthias Clasen - 0.3.9-2 +- Request a full screen refresh when receives a desktop-resize encoding + +* Tue Aug 11 2009 Daniel P. Berrange - 0.3.9-1 +- Update to 0.3.9 release + +* Tue Aug 11 2009 Ville Skyttä - 0.3.8-10 +- Use bzipped upstream tarball. + +* Fri Jul 24 2009 Fedora Release Engineering - 0.3.8-9 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Fri Mar 27 2009 Daniel P. Berrange - 0.3.8-8.fc11 +- Fix ungrab when pointer type changes + +* Tue Mar 24 2009 Daniel P. Berrange - 0.3.8-7.fc11 +- Fix release of keyboard grab when releasing mouse grab outside app window (rhbz #491167) + +* Thu Mar 5 2009 Daniel P. Berrange - 0.3.8-6.fc11 +- Fix SASL address generation when using AF_UNIX sockets + +* Tue Mar 3 2009 Daniel P. Berrange - 0.3.8-5.fc11 +- Support SASL authentication extension + +* Thu Feb 26 2009 Daniel P. Berrange - 0.3.8-4.fc11 +- Fix relative mouse handling to avoid 'invisible wall' + +* Tue Feb 24 2009 Fedora Release Engineering - 0.3.8-3.fc11 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Tue Feb 24 2009 Daniel P. Berrange - 0.3.8-2.fc11 +- Update URLs to gnome.org hosting + +* Sun Dec 7 2008 Daniel P. Berrange - 0.3.8-1.fc11 +- Update to 0.3.8 release + +* Sat Nov 29 2008 Ignacio Vazquez-Abrams - 0.3.7-4 +- Rebuild for Python 2.6 + +* Thu Oct 9 2008 Daniel P. Berrange - 0.3.7-3.fc10 +- Avoid bogus framebuffer updates for psuedo-encodings +- Fix scancode translation for evdev + +* Thu Sep 25 2008 Daniel P. Berrange - 0.3.7-2.fc10 +- Allow pointer ungrab keysequence if already grabbed (rhbz #463729) + +* Fri Sep 5 2008 Matthias Clasen - 0.3.7-1 +- Update to 0.3.7 + +* Thu Aug 28 2008 Daniel P. Berrange - 0.3.6-4.fc10 +- Fix key/mouse event propagation (rhbz #454627) + +* Mon Jul 7 2008 Tom "spot" Callaway - 0.3.6-3 +- fix conditional comparison + +* Wed Jun 25 2008 Daniel P. Berrange - 0.3.6-2.fc10 +- Rebuild for GNU TLS ABI change + +* Wed May 7 2008 Daniel P. Berrange - 0.3.6-1.fc10 +- Updated to 0.3.6 release + +* Fri Apr 25 2008 Matthias Clasen - 0.3.5-1.fc9 +- Update to 0.3.5 + +* Fri Apr 4 2008 Daniel P. Berrange - 0.3.4-4.fc9 +- Remove bogus chunk of render patch + +* Thu Apr 3 2008 Daniel P. Berrange - 0.3.4-3.fc9 +- Fix OpenGL rendering artifacts (rhbz #440184) + +* Thu Apr 3 2008 Daniel P. Berrange - 0.3.4-2.fc9 +- Fixed endianness conversions +- Fix makecontext() args crash on x86_64 +- Fix protocol version negotiation + +* Thu Mar 6 2008 Daniel P. Berrange - 0.3.4-1.fc9 +- Update to 0.3.4 release +- Fix crash with OpenGL scaling code + +* Sun Feb 3 2008 Daniel P. Berrange - 0.3.3-1.fc9 +- Update to 0.3.3 release + +* Mon Jan 14 2008 Daniel P. Berrange - 0.3.2-2.fc9 +- Track keystate to avoid stuck modifier keys + +* Mon Dec 31 2007 Daniel P. Berrange - 0.3.2-1.fc9 +- Update to 0.3.2 release +- Added dep on zlib-devel + +* Thu Dec 13 2007 Daniel P. Berrange - 0.3.1-1.fc9 +- Update to 0.3.1 release + +* Wed Oct 10 2007 Daniel P. Berrange - 0.2.0-4.fc8 +- Fixed coroutine cleanup to avoid SEGV (rhbz #325731) + +* Thu Oct 4 2007 Daniel P. Berrange - 0.2.0-3.fc8 +- Fixed coroutine caller to avoid SEGV + +* Wed Sep 26 2007 Daniel P. Berrange - 0.2.0-2.fc8 +- Remove use of PROT_EXEC for coroutine stack (rhbz #307531 ) + +* Thu Sep 13 2007 Daniel P. Berrange - 0.2.0-1.fc8 +- Update to 0.2.0 release + +* Wed Aug 29 2007 Daniel P. Berrange - 0.1.0-5.fc8 +- Fixed handling of mis-matched client/server colour depths + +* Wed Aug 22 2007 Daniel P. Berrange - 0.1.0-4.fc8 +- Fix mixed endian handling & BGR pixel format (rhbz #253597) +- Clear widget areas outside of framebuffer (rhbz #253599) +- Fix off-by-one in python demo + +* Thu Aug 16 2007 Daniel P. Berrange - 0.1.0-3.fc8 +- Tweaked post scripts +- Removed docs from sub-packages +- Explicitly set license to LGPLv2+ +- Remove use of macro for install rule + +* Wed Aug 15 2007 Daniel P. Berrange - 0.1.0-2.fc8 +- Added gnutls-devel requirement to -devel package + +* Wed Aug 15 2007 Daniel P. Berrange - 0.1.0-1.fc8 +- Initial official release diff --git a/sources b/sources new file mode 100644 index 0000000..72fa4ff --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (gtk-vnc-0.9.0.tar.xz) = 498b368eb53ac58172db280c80f9da71ce82b636c39f186046e4f674e44c574ff4b63c3f777acc79d32c17d70e4efcdc207768ed49b3d1842bc4b73618296215