[gentoo-commits] repo/gentoo:master commit in: net-misc/rdesktop/files/, net-misc/rdesktop/

2019-10-16 Thread Bernard Cafarelli
commit: dc9895ac02962c11f813ec096411d6910ef672cf
Author: Bernard Cafarelli  gentoo  org>
AuthorDate: Wed Oct 16 21:13:52 2019 +
Commit: Bernard Cafarelli  gentoo  org>
CommitDate: Wed Oct 16 21:39:37 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dc9895ac

net-misc/rdesktop: drop old

Package-Manager: Portage-2.3.77, Repoman-2.3.17
Signed-off-by: Bernard Cafarelli  gentoo.org>

 net-misc/rdesktop/Manifest |  1 -
 .../files/rdesktop-1.8.4-use_standard_gssapi.patch | 82 --
 net-misc/rdesktop/metadata.xml |  2 +-
 net-misc/rdesktop/rdesktop-1.8.4-r1.ebuild | 70 --
 net-misc/rdesktop/rdesktop-1.8.4-r2.ebuild | 71 ---
 5 files changed, 1 insertion(+), 225 deletions(-)

diff --git a/net-misc/rdesktop/Manifest b/net-misc/rdesktop/Manifest
index f7712845f43..e521b8ca528 100644
--- a/net-misc/rdesktop/Manifest
+++ b/net-misc/rdesktop/Manifest
@@ -1,2 +1 @@
-DIST rdesktop-1.8.4.tar.gz 321448 BLAKE2B 
b4d5a91f77a63258d08823c860b2d7045b0ee7ad0feb144746c904146c410c6456391eb3f2b7b9a6a40c2fb34515bb751c2c9da8dfcaf17c5309ff21cad3
 SHA512 
9e4f6723eb0baab31ad11f1c5c29a4753c655386c2381d01646b7834c959ffc2ec1e0c2f3f73626255aa018889709758d97387c7563da98bb1b7f269610929ae
 DIST rdesktop-1.8.6.tar.gz 321061 BLAKE2B 
bd61ecfbdca3f05b2a8d7f84c10296af3845870f5bd2522ecd768ce27cdbf790787ba9af2f53c85bcd674926488b77a610e48cafbb891fced9a458f86a2ee9e1
 SHA512 
a7d624dad27e531cf38d73bd879e66aaf72e527d082a4adb59e259e4e5b9a779ee6938db74601fbb2be7e7b015c806109fe8dfc99d78cbd06f0ba4d8f89b28ee

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.4-use_standard_gssapi.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.4-use_standard_gssapi.patch
deleted file mode 100644
index 5befcf02e55..000
--- a/net-misc/rdesktop/files/rdesktop-1.8.4-use_standard_gssapi.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-From 71f1cfb909c0a955632001cf9fad80a321a43372 Mon Sep 17 00:00:00 2001
-From: Pierre Ossman 
-Date: Mon, 10 Jul 2017 15:12:26 +0200
-Subject: [PATCH 1/2] Fix pointer types for gss_wrap()/gss_unrap()
-
-We were using the incorrect type for the context for these two calls.
-No practical effects, but some noise from the compiler about the wrong
-pointer type.

- cssp.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/cssp.c b/cssp.c
-index 9f4c0829..6ac37746 100644
 a/cssp.c
-+++ b/cssp.c
-@@ -173,7 +173,7 @@ cssp_gss_get_service_name(char *server, gss_name_t * name)
- }
- 
- static RD_BOOL
--cssp_gss_wrap(gss_ctx_id_t * ctx, STREAM in, STREAM out)
-+cssp_gss_wrap(gss_ctx_id_t ctx, STREAM in, STREAM out)
- {
-   int conf_state;
-   OM_uint32 major_status;
-@@ -212,7 +212,7 @@ cssp_gss_wrap(gss_ctx_id_t * ctx, STREAM in, STREAM out)
- }
- 
- static RD_BOOL
--cssp_gss_unwrap(gss_ctx_id_t * ctx, STREAM in, STREAM out)
-+cssp_gss_unwrap(gss_ctx_id_t ctx, STREAM in, STREAM out)
- {
-   OM_uint32 major_status;
-   OM_uint32 minor_status;
-
-From b556651fe109c8802a0c798b8a680e5ff883bf4e Mon Sep 17 00:00:00 2001
-From: Pierre Ossman 
-Date: Mon, 10 Jul 2017 15:14:01 +0200
-Subject: [PATCH 2/2] Use standard GSSAPI rather than libgssglue
-
-That project is abandoned and the distributions aren't including
-it anymore.

- configure.ac | 15 ---
- 1 file changed, 4 insertions(+), 11 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index e045c409..a969ad5d 100644
 a/configure.ac
-+++ b/configure.ac
-@@ -122,27 +122,20 @@ fi
- 
- dnl CredSSP feature
- AC_ARG_ENABLE([credssp], AS_HELP_STRING([--disable-credssp], [disable support 
for CredSSP]))
--AC_ARG_ENABLE([static-gssglue], AS_HELP_STRING([--enable-static-gssglue]), 
--[static_gssglue=yes], [static_gssglue=no])
- AS_IF([test "x$enable_credssp" != "xno"], [
- if test -n "$PKG_CONFIG"; then
--  PKG_CHECK_MODULES(GSSGLUE, libgssglue, [WITH_CREDSSP=1], 
[WITH_CREDSSP=0])
-+  PKG_CHECK_MODULES(GSSAPI, krb5-gssapi, [WITH_CREDSSP=1], 
[WITH_CREDSSP=0])
- fi
- 
- if test x"$WITH_CREDSSP" = "x1"; then
- CREDSSPOBJ="cssp.o"
--CFLAGS="$CFLAGS $GSSGLUE_CFLAGS"
--
--AS_IF([test "x$static_gssglue" != "xno"], [
--LIBS="$LIBS -Wl,-Bstatic -lgssglue -Wl,-Bdynamic"
--], [
--LIBS="$LIBS -lgssglue"
--])
-+CFLAGS="$CFLAGS $GSSAPI_CFLAGS"
-+LIBS="$LIBS $GSSAPI_LIBS"
- 
- AC_DEFINE(WITH_CREDSSP)
- else
-   echo
--  echo "CredSSP support requires libgssglue, install the 
dependency"
-+  echo "CredSSP support requires GSSAPI, install the dependency"
-   echo "or disable the feature using --disable-credssp."
-   echo
-   exit 1

diff --git a/net-misc/rdesktop/metadata.xml b/net-misc/rdesktop/metadata.xml
index 905d0e56c9b..8e11088a21d 100644
--- 

[gentoo-commits] repo/gentoo:master commit in: net-misc/rdesktop/files/, net-misc/rdesktop/

2019-08-26 Thread Bernard Cafarelli
commit: d542c2249df5d4c2a05ec486b4365591220f7b2d
Author: Bernard Cafarelli  gentoo  org>
AuthorDate: Mon Aug 26 19:27:44 2019 +
Commit: Bernard Cafarelli  gentoo  org>
CommitDate: Mon Aug 26 19:28:02 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d542c224

net-misc/rdesktop: backport fix for some failing connections

1.8.6 fails with some servers (like W2003)

Closes: https://bugs.gentoo.org/692042
Package-Manager: Portage-2.3.73, Repoman-2.3.17
Signed-off-by: Bernard Cafarelli  gentoo.org>

 .../files/rdesktop-1.8.6-sec_decrypt.patch | 59 ++
 net-misc/rdesktop/rdesktop-1.8.6-r1.ebuild | 72 ++
 2 files changed, 131 insertions(+)

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.6-sec_decrypt.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.6-sec_decrypt.patch
new file mode 100644
index 000..dbb0d0e9baf
--- /dev/null
+++ b/net-misc/rdesktop/files/rdesktop-1.8.6-sec_decrypt.patch
@@ -0,0 +1,59 @@
+From 7841030279c5300d5073b2348b58f3f41e136f82 Mon Sep 17 00:00:00 2001
+From: Markus Beth 
+Date: Tue, 11 Jun 2019 22:57:31 +0200
+Subject: [PATCH] sec_decrypt() the correct amount of data
+
+Save the correct amount of data to sec_decrypt() because after
+inout_uint8p() the macro s_remaining(s) will find nothing left.
+---
+ secure.c | 16 ++--
+ 1 file changed, 10 insertions(+), 6 deletions(-)
+
+diff --git a/secure.c b/secure.c
+index 8f65b3aa..9b301e1f 100644
+--- a/secure.c
 b/secure.c
+@@ -813,6 +813,7 @@ sec_recv(uint8 * rdpver)
+   STREAM s;
+   struct stream packet;
+   size_t data_offset;
++  size_t remaining;
+   unsigned char *data;
+ 
+   while ((s = mcs_recv(, rdpver)) != NULL)
+@@ -832,8 +833,9 @@ sec_recv(uint8 * rdpver)
+ 
+   data_offset = s_tell(s);
+ 
+-  inout_uint8p(s, data, s_remaining(s));
+-  sec_decrypt(data, s_remaining(s));
++  remaining = s_remaining(s);
++  inout_uint8p(s, data, remaining);
++  sec_decrypt(data, remaining);
+ 
+   s_seek(s, data_offset);
+   }
+@@ -860,8 +862,9 @@ sec_recv(uint8 * rdpver)
+ 
+   data_offset = s_tell(s);
+ 
+-  inout_uint8p(s, data, s_remaining(s));
+-  sec_decrypt(data, s_remaining(s));
++  remaining = s_remaining(s);
++  inout_uint8p(s, data, remaining);
++  sec_decrypt(data, remaining);
+   }
+ 
+   if (sec_flags & SEC_LICENCE_NEG)
+@@ -883,8 +886,9 @@ sec_recv(uint8 * rdpver)
+ 
+   data_offset = s_tell(s);
+ 
+-  inout_uint8p(s, data, s_remaining(s));
+-  sec_decrypt(data, s_remaining(s));
++  remaining = s_remaining(s);
++  inout_uint8p(s, data, remaining);
++  sec_decrypt(data, remaining);
+ 
+   /* Check for a redirect packet, starts 
with 00 04 */
+   if (data[0] == 0 && data[1] == 4)

diff --git a/net-misc/rdesktop/rdesktop-1.8.6-r1.ebuild 
b/net-misc/rdesktop/rdesktop-1.8.6-r1.ebuild
new file mode 100644
index 000..023a23ca970
--- /dev/null
+++ b/net-misc/rdesktop/rdesktop-1.8.6-r1.ebuild
@@ -0,0 +1,72 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit autotools eutils
+
+MY_PV=${PV/_/-}
+
+DESCRIPTION="A Remote Desktop Protocol Client"
+HOMEPAGE="http://www.rdesktop.org/;
+SRC_URI="https://github.com/${PN}/${PN}/releases/download/v${PV}/${P}.tar.gz;
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 
~x86-fbsd ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="alsa ao debug ipv6 kerberos libressl libsamplerate oss pcsc-lite xrandr"
+
+S=${WORKDIR}/${PN}-${MY_PV}
+
+RDEPEND="
+   !libressl? ( dev-libs/openssl:0= )
+   libressl? ( dev-libs/libressl:= )
+   x11-libs/libX11
+   x11-libs/libXext
+   x11-libs/libXau
+   x11-libs/libXdmcp
+   alsa? ( media-libs/alsa-lib )
+   ao? ( >=media-libs/libao-0.8.6 )
+   kerberos? ( virtual/krb5 )
+   libsamplerate? ( media-libs/libsamplerate )
+   pcsc-lite? ( >=sys-apps/pcsc-lite-1.6.6 )
+   xrandr? ( x11-libs/libXrandr )"
+DEPEND="${RDEPEND}
+   x11-libs/libXt"
+BDEPEND=virtual/pkgconfig
+
+PATCHES=(
+   

[gentoo-commits] repo/gentoo:master commit in: net-misc/rdesktop/files/, net-misc/rdesktop/

2019-05-14 Thread Bernard Cafarelli
commit: baa5e9e54c8c8c8f18be301c4ca909ff04ef6e45
Author: Bernard Cafarelli  gentoo  org>
AuthorDate: Tue May 14 16:38:35 2019 +
Commit: Bernard Cafarelli  gentoo  org>
CommitDate: Tue May 14 16:38:35 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=baa5e9e5

net-misc/rdesktop: restore patch to use standard GSSAPI

Closes: https://bugs.gentoo.org/685942
Package-Manager: Portage-2.3.66, Repoman-2.3.12
Signed-off-by: Bernard Cafarelli  gentoo.org>

 .../files/rdesktop-1.8.5-use_standard_gssapi.patch | 56 ++
 ...sktop-1.8.5.ebuild => rdesktop-1.8.5-r1.ebuild} |  1 +
 2 files changed, 57 insertions(+)

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.5-use_standard_gssapi.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.5-use_standard_gssapi.patch
new file mode 100644
index 000..a5e14c3aff0
--- /dev/null
+++ b/net-misc/rdesktop/files/rdesktop-1.8.5-use_standard_gssapi.patch
@@ -0,0 +1,56 @@
+diff -Naur rdesktop-1.8.5.orig/configure.ac rdesktop-1.8.5/configure.ac
+--- rdesktop-1.8.5.orig/configure.ac   2019-05-08 11:24:50.0 +0200
 rdesktop-1.8.5/configure.ac2019-05-14 18:33:49.479354354 +0200
+@@ -122,27 +122,20 @@
+ 
+ dnl CredSSP feature
+ AC_ARG_ENABLE([credssp], AS_HELP_STRING([--disable-credssp], [disable support 
for CredSSP]))
+-AC_ARG_ENABLE([static-gssglue], AS_HELP_STRING([--enable-static-gssglue]), 
+-[static_gssglue=yes], [static_gssglue=no])
+ AS_IF([test "x$enable_credssp" != "xno"], [
+ if test -n "$PKG_CONFIG"; then
+-  PKG_CHECK_MODULES(GSSGLUE, libgssglue, [WITH_CREDSSP=1], 
[WITH_CREDSSP=0])
++  PKG_CHECK_MODULES(GSSAPI, krb5-gssapi, [WITH_CREDSSP=1], 
[WITH_CREDSSP=0])
+ fi
+ 
+ if test x"$WITH_CREDSSP" = "x1"; then
+ CREDSSPOBJ="cssp.o"
+-CFLAGS="$CFLAGS $GSSGLUE_CFLAGS"
+-
+-AS_IF([test "x$static_gssglue" != "xno"], [
+-LIBS="$LIBS -Wl,-Bstatic -lgssglue -Wl,-Bdynamic"
+-], [
+-LIBS="$LIBS -lgssglue"
+-])
++CFLAGS="$CFLAGS $GSSAPI_CFLAGS"
++LIBS="$LIBS $GSSAPI_LIBS"
+ 
+ AC_DEFINE(WITH_CREDSSP)
+ else
+   echo
+-  echo "CredSSP support requires libgssglue, install the 
dependency"
++  echo "CredSSP support requires GSSAPI, install the dependency"
+   echo "or disable the feature using --disable-credssp."
+   echo
+   exit 1
+diff -Naur rdesktop-1.8.5.orig/cssp.c rdesktop-1.8.5/cssp.c
+--- rdesktop-1.8.5.orig/cssp.c 2019-05-08 11:22:39.0 +0200
 rdesktop-1.8.5/cssp.c  2019-05-14 18:34:49.559368755 +0200
+@@ -140,7 +140,7 @@
+ }
+ 
+ static STREAM
+-cssp_gss_wrap(gss_ctx_id_t * ctx, STREAM in)
++cssp_gss_wrap(gss_ctx_id_t ctx, STREAM in)
+ {
+   int conf_state;
+   OM_uint32 major_status;
+@@ -181,7 +181,7 @@
+ }
+ 
+ static STREAM
+-cssp_gss_unwrap(gss_ctx_id_t * ctx, STREAM in)
++cssp_gss_unwrap(gss_ctx_id_t ctx, STREAM in)
+ {
+   OM_uint32 major_status;
+   OM_uint32 minor_status;

diff --git a/net-misc/rdesktop/rdesktop-1.8.5.ebuild 
b/net-misc/rdesktop/rdesktop-1.8.5-r1.ebuild
similarity index 97%
rename from net-misc/rdesktop/rdesktop-1.8.5.ebuild
rename to net-misc/rdesktop/rdesktop-1.8.5-r1.ebuild
index 26385608089..8a54a1e507b 100644
--- a/net-misc/rdesktop/rdesktop-1.8.5.ebuild
+++ b/net-misc/rdesktop/rdesktop-1.8.5-r1.ebuild
@@ -39,6 +39,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-1.8.3-no_strip.patch
"${FILESDIR}"/${PN}-1.8.3-xrandr_configure.patch
"${FILESDIR}"/${PN}-1.8.4-libressl.patch
+   "${FILESDIR}"/${P}-use_standard_gssapi.patch
 )
 
 DOCS=( doc/HACKING doc/TODO doc/keymapping.txt )



[gentoo-commits] repo/gentoo:master commit in: net-misc/rdesktop/files/, net-misc/rdesktop/

2019-04-16 Thread Bernard Cafarelli
commit: 290bb3e92f5be41c5693ce86a9d04d05046c62ba
Author: Bernard Cafarelli  gentoo  org>
AuthorDate: Tue Apr 16 08:50:55 2019 +
Commit: Bernard Cafarelli  gentoo  org>
CommitDate: Tue Apr 16 08:50:55 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=290bb3e9

net-misc/rdesktop: use standard GSSAPI

Backport upstream master patch to switch away from using abandoned
project libgssglue

Bug: https://bugs.gentoo.org/646126
Package-Manager: Portage-2.3.63, Repoman-2.3.12
Signed-off-by: Bernard Cafarelli  gentoo.org>

 .../files/rdesktop-1.8.4-use_standard_gssapi.patch | 82 ++
 net-misc/rdesktop/rdesktop-1.8.4-r2.ebuild | 71 +++
 2 files changed, 153 insertions(+)

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.4-use_standard_gssapi.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.4-use_standard_gssapi.patch
new file mode 100644
index 000..5befcf02e55
--- /dev/null
+++ b/net-misc/rdesktop/files/rdesktop-1.8.4-use_standard_gssapi.patch
@@ -0,0 +1,82 @@
+From 71f1cfb909c0a955632001cf9fad80a321a43372 Mon Sep 17 00:00:00 2001
+From: Pierre Ossman 
+Date: Mon, 10 Jul 2017 15:12:26 +0200
+Subject: [PATCH 1/2] Fix pointer types for gss_wrap()/gss_unrap()
+
+We were using the incorrect type for the context for these two calls.
+No practical effects, but some noise from the compiler about the wrong
+pointer type.
+---
+ cssp.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/cssp.c b/cssp.c
+index 9f4c0829..6ac37746 100644
+--- a/cssp.c
 b/cssp.c
+@@ -173,7 +173,7 @@ cssp_gss_get_service_name(char *server, gss_name_t * name)
+ }
+ 
+ static RD_BOOL
+-cssp_gss_wrap(gss_ctx_id_t * ctx, STREAM in, STREAM out)
++cssp_gss_wrap(gss_ctx_id_t ctx, STREAM in, STREAM out)
+ {
+   int conf_state;
+   OM_uint32 major_status;
+@@ -212,7 +212,7 @@ cssp_gss_wrap(gss_ctx_id_t * ctx, STREAM in, STREAM out)
+ }
+ 
+ static RD_BOOL
+-cssp_gss_unwrap(gss_ctx_id_t * ctx, STREAM in, STREAM out)
++cssp_gss_unwrap(gss_ctx_id_t ctx, STREAM in, STREAM out)
+ {
+   OM_uint32 major_status;
+   OM_uint32 minor_status;
+
+From b556651fe109c8802a0c798b8a680e5ff883bf4e Mon Sep 17 00:00:00 2001
+From: Pierre Ossman 
+Date: Mon, 10 Jul 2017 15:14:01 +0200
+Subject: [PATCH 2/2] Use standard GSSAPI rather than libgssglue
+
+That project is abandoned and the distributions aren't including
+it anymore.
+---
+ configure.ac | 15 ---
+ 1 file changed, 4 insertions(+), 11 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index e045c409..a969ad5d 100644
+--- a/configure.ac
 b/configure.ac
+@@ -122,27 +122,20 @@ fi
+ 
+ dnl CredSSP feature
+ AC_ARG_ENABLE([credssp], AS_HELP_STRING([--disable-credssp], [disable support 
for CredSSP]))
+-AC_ARG_ENABLE([static-gssglue], AS_HELP_STRING([--enable-static-gssglue]), 
+-[static_gssglue=yes], [static_gssglue=no])
+ AS_IF([test "x$enable_credssp" != "xno"], [
+ if test -n "$PKG_CONFIG"; then
+-  PKG_CHECK_MODULES(GSSGLUE, libgssglue, [WITH_CREDSSP=1], 
[WITH_CREDSSP=0])
++  PKG_CHECK_MODULES(GSSAPI, krb5-gssapi, [WITH_CREDSSP=1], 
[WITH_CREDSSP=0])
+ fi
+ 
+ if test x"$WITH_CREDSSP" = "x1"; then
+ CREDSSPOBJ="cssp.o"
+-CFLAGS="$CFLAGS $GSSGLUE_CFLAGS"
+-
+-AS_IF([test "x$static_gssglue" != "xno"], [
+-LIBS="$LIBS -Wl,-Bstatic -lgssglue -Wl,-Bdynamic"
+-], [
+-LIBS="$LIBS -lgssglue"
+-])
++CFLAGS="$CFLAGS $GSSAPI_CFLAGS"
++LIBS="$LIBS $GSSAPI_LIBS"
+ 
+ AC_DEFINE(WITH_CREDSSP)
+ else
+   echo
+-  echo "CredSSP support requires libgssglue, install the 
dependency"
++  echo "CredSSP support requires GSSAPI, install the dependency"
+   echo "or disable the feature using --disable-credssp."
+   echo
+   exit 1

diff --git a/net-misc/rdesktop/rdesktop-1.8.4-r2.ebuild 
b/net-misc/rdesktop/rdesktop-1.8.4-r2.ebuild
new file mode 100644
index 000..ea7ed235070
--- /dev/null
+++ b/net-misc/rdesktop/rdesktop-1.8.4-r2.ebuild
@@ -0,0 +1,71 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit autotools eutils
+
+MY_PV=${PV/_/-}
+
+DESCRIPTION="A Remote Desktop Protocol Client"
+HOMEPAGE="http://www.rdesktop.org/;
+SRC_URI="https://github.com/${PN}/${PN}/releases/download/v${PV}/${P}.tar.gz;
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 
~x86-fbsd ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="alsa ao debug ipv6 kerberos libressl libsamplerate oss pcsc-lite xrandr"
+
+S=${WORKDIR}/${PN}-${MY_PV}
+
+RDEPEND="
+   !libressl? ( dev-libs/openssl:0= )
+   libressl? ( dev-libs/libressl:= )
+   x11-libs/libX11
+   x11-libs/libXext
+   x11-libs/libXau

[gentoo-commits] repo/gentoo:master commit in: net-misc/rdesktop/files/, net-misc/rdesktop/

2019-03-11 Thread Bernard Cafarelli
commit: e745dcaa8b9020f635aee9d6aec03c8e46ddbd56
Author: Bernard Cafarelli  gentoo  org>
AuthorDate: Mon Mar 11 07:48:18 2019 +
Commit: Bernard Cafarelli  gentoo  org>
CommitDate: Mon Mar 11 07:49:29 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e745dcaa

net-misc/rdesktop: drop vulnerable versions

Bug: https://bugs.gentoo.org/674558
Package-Manager: Portage-2.3.62, Repoman-2.3.12
Signed-off-by: Bernard Cafarelli  gentoo.org>

 net-misc/rdesktop/Manifest |   1 -
 .../files/rdesktop-1.7.0-libao_crash.patch |  18 ---
 .../files/rdesktop-1.8.3-openssl-1.1.patch | 125 -
 net-misc/rdesktop/rdesktop-1.8.3-r1.ebuild |  74 
 net-misc/rdesktop/rdesktop-1.8.3-r2.ebuild |  76 -
 net-misc/rdesktop/rdesktop-1.8.3-r3.ebuild |  70 
 net-misc/rdesktop/rdesktop-1.8.3.ebuild|  74 
 net-misc/rdesktop/rdesktop-1.8.4.ebuild|  69 
 8 files changed, 507 deletions(-)

diff --git a/net-misc/rdesktop/Manifest b/net-misc/rdesktop/Manifest
index ba8eea641aa..4e04d770212 100644
--- a/net-misc/rdesktop/Manifest
+++ b/net-misc/rdesktop/Manifest
@@ -1,2 +1 @@
-DIST rdesktop-1.8.3.tar.gz 320212 BLAKE2B 
daca0b78a8fcd0461f1c3251135bd980aaafacf8e0cd51ab731b576adb23006ec9f51858586e7e3a1a7f192b7830308e585984b4a31fb013748f8c6b3a8c47bb
 SHA512 
06b94ad3b09430b05e424ef31a3e6f2388190b4920e348603cb66a414244896e0dc8906b9f12920e9406cf153ffa7f6507b23bf6713c3a675c0540a8ef57902d
 DIST rdesktop-1.8.4.tar.gz 321448 BLAKE2B 
b4d5a91f77a63258d08823c860b2d7045b0ee7ad0feb144746c904146c410c6456391eb3f2b7b9a6a40c2fb34515bb751c2c9da8dfcaf17c5309ff21cad3
 SHA512 
9e4f6723eb0baab31ad11f1c5c29a4753c655386c2381d01646b7834c959ffc2ec1e0c2f3f73626255aa018889709758d97387c7563da98bb1b7f269610929ae

diff --git a/net-misc/rdesktop/files/rdesktop-1.7.0-libao_crash.patch 
b/net-misc/rdesktop/files/rdesktop-1.7.0-libao_crash.patch
deleted file mode 100644
index 3afb9b2b0f2..000
--- a/net-misc/rdesktop/files/rdesktop-1.7.0-libao_crash.patch
+++ /dev/null
@@ -1,18 +0,0 @@
 rdpsnd_libao.c.orig2010-11-29 14:55:31.124907038 +0100
-+++ rdpsnd_libao.c 2010-11-29 14:55:51.708464083 +0100
-@@ -76,6 +76,7 @@
-   format.channels = 2;
-   format.rate = 44100;
-   format.byte_format = AO_FMT_NATIVE;
-+  format.matrix = NULL;
- 
- 
-   o_device = ao_open_live(default_driver, , NULL);
-@@ -115,6 +116,7 @@
-   format.channels = pwfx->nChannels;
-   format.rate = 44100;
-   format.byte_format = AO_FMT_NATIVE;
-+  format.matrix = NULL;
- 
-   if (o_device != NULL)
-   ao_close(o_device);

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch
deleted file mode 100644
index c74bd48c5aa..000
--- a/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch
+++ /dev/null
@@ -1,125 +0,0 @@
-From bd6aa6acddf0ba640a49834807872f4cc0d0a773 Mon Sep 17 00:00:00 2001
-From: Jani Hakala 
-Date: Thu, 16 Jun 2016 14:28:15 +0300
-Subject: [PATCH] Fix OpenSSL 1.1 compability issues
-
-Some data types have been made opaque in OpenSSL version 1.1 so
-stack allocation and accessing struct fields directly does not work.

- ssl.c | 65 ---
- 1 file changed, 40 insertions(+), 25 deletions(-)
-
-diff --git a/ssl.c b/ssl.c
-index 48751255..032e9b9e 100644
 a/ssl.c
-+++ b/ssl.c
-@@ -88,7 +88,7 @@ rdssl_rsa_encrypt(uint8 * out, uint8 * in, int len, uint32 
modulus_size, uint8 *
- uint8 * exponent)
- {
-   BN_CTX *ctx;
--  BIGNUM mod, exp, x, y;
-+  BIGNUM *mod, *exp, *x, *y;
-   uint8 inr[SEC_MAX_MODULUS_SIZE];
-   int outlen;
- 
-@@ -98,24 +98,24 @@ rdssl_rsa_encrypt(uint8 * out, uint8 * in, int len, uint32 
modulus_size, uint8 *
-   reverse(inr, len);
- 
-   ctx = BN_CTX_new();
--  BN_init();
--  BN_init();
--  BN_init();
--  BN_init();
--
--  BN_bin2bn(modulus, modulus_size, );
--  BN_bin2bn(exponent, SEC_EXPONENT_SIZE, );
--  BN_bin2bn(inr, len, );
--  BN_mod_exp(, , , , ctx);
--  outlen = BN_bn2bin(, out);
-+  mod = BN_new();
-+  exp = BN_new();
-+  x = BN_new();
-+  y = BN_new();
-+
-+  BN_bin2bn(modulus, modulus_size, mod);
-+  BN_bin2bn(exponent, SEC_EXPONENT_SIZE, exp);
-+  BN_bin2bn(inr, len, x);
-+  BN_mod_exp(y, x, exp, mod, ctx);
-+  outlen = BN_bn2bin(y, out);
-   reverse(out, outlen);
-   if (outlen < (int) modulus_size)
-   memset(out + outlen, 0, modulus_size - outlen);
- 
--  BN_free();
--  BN_clear_free();
--  BN_free();
--  BN_free();
-+  BN_free(y);
-+  BN_clear_free(x);
-+  BN_free(exp);
-+  BN_free(mod);
-   BN_CTX_free(ctx);
- }
- 
-@@ -146,12 +146,20 @@ rdssl_cert_to_rkey(RDSSL_CERT * cert, 

[gentoo-commits] repo/gentoo:master commit in: net-misc/rdesktop/files/, net-misc/rdesktop/

2019-01-29 Thread Bernard Cafarelli
commit: 314daf2f1ee5933326ebe0dde344d10e11501d1d
Author: Bernard Cafarelli  gentoo  org>
AuthorDate: Tue Jan 29 13:02:08 2019 +
Commit: Bernard Cafarelli  gentoo  org>
CommitDate: Tue Jan 29 13:02:19 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=314daf2f

net-misc/rdesktop: restore libressl fix

It was lost in the 1.8.4 bump

Closes: https://bugs.gentoo.org/664202
Package-Manager: Portage-2.3.59, Repoman-2.3.12
Signed-off-by: Bernard Cafarelli  gentoo.org>

 .../rdesktop/files/rdesktop-1.8.4-libressl.patch   | 16 +
 net-misc/rdesktop/rdesktop-1.8.4-r1.ebuild | 70 ++
 2 files changed, 86 insertions(+)

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.4-libressl.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.4-libressl.patch
new file mode 100644
index 000..b56cbfc3053
--- /dev/null
+++ b/net-misc/rdesktop/files/rdesktop-1.8.4-libressl.patch
@@ -0,0 +1,16 @@
+diff --git a/ssl.c b/ssl.c
+index 07d7aa5..45df34f 100644
+--- a/ssl.c
 b/ssl.c
+@@ -225,7 +225,7 @@ rdssl_rkey_get_exp_mod(RDSSL_RKEY * rkey, uint8 * 
exponent, uint32 max_exp_len,
+   BIGNUM *e = NULL;
+   BIGNUM *n = NULL;
+ 
+-#if OPENSSL_VERSION_NUMBER < 0x1010L
++#if (OPENSSL_VERSION_NUMBER < 0x1010L  || 
defined(LIBRESSL_VERSION_NUMBER))
+   e = rkey->e;
+   n = rkey->n;
+ #else
+-- 
+2.20.1
+

diff --git a/net-misc/rdesktop/rdesktop-1.8.4-r1.ebuild 
b/net-misc/rdesktop/rdesktop-1.8.4-r1.ebuild
new file mode 100644
index 000..d0abef7c4ac
--- /dev/null
+++ b/net-misc/rdesktop/rdesktop-1.8.4-r1.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit autotools eutils
+
+MY_PV=${PV/_/-}
+
+DESCRIPTION="A Remote Desktop Protocol Client"
+HOMEPAGE="http://www.rdesktop.org/;
+SRC_URI="https://github.com/${PN}/${PN}/releases/download/v${PV}/${P}.tar.gz;
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 
~x86-fbsd ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="alsa ao debug ipv6 kerberos libressl libsamplerate oss pcsc-lite xrandr"
+
+S=${WORKDIR}/${PN}-${MY_PV}
+
+RDEPEND="
+   !libressl? ( dev-libs/openssl:0= )
+   libressl? ( dev-libs/libressl:= )
+   x11-libs/libX11
+   x11-libs/libXext
+   x11-libs/libXau
+   x11-libs/libXdmcp
+   alsa? ( media-libs/alsa-lib )
+   ao? ( >=media-libs/libao-0.8.6 )
+   kerberos? ( net-libs/libgssglue )
+   libsamplerate? ( media-libs/libsamplerate )
+   pcsc-lite? ( >=sys-apps/pcsc-lite-1.6.6 )
+   xrandr? ( x11-libs/libXrandr )"
+DEPEND="${RDEPEND}
+   x11-libs/libXt"
+BDEPEND=virtual/pkgconfig
+
+PATCHES=(
+   "${FILESDIR}"/${PN}-1.6.0-sound_configure.patch
+   "${FILESDIR}"/${PN}-1.8.3-no_strip.patch
+   "${FILESDIR}"/${PN}-1.8.3-xrandr_configure.patch
+   "${FILESDIR}"/${P}-libressl.patch
+)
+
+DOCS=( doc/HACKING doc/TODO doc/keymapping.txt )
+
+src_prepare() {
+   default
+   eautoreconf
+}
+
+src_configure() {
+   if use ao; then
+   sound_conf=$(use_with ao sound libao)
+   else if use alsa; then
+   sound_conf=$(use_with alsa sound alsa)
+   else
+   sound_conf=$(use_with oss sound oss)
+   fi
+   fi
+
+   econf \
+   --with-openssl="${EPREFIX}"/usr \
+   $(use_with debug) \
+   $(use_with ipv6) \
+   $(use_with libsamplerate) \
+   $(use_with xrandr) \
+   $(use_enable kerberos credssp) \
+   $(use_enable pcsc-lite smartcard) \
+   ${sound_conf}
+}



[gentoo-commits] repo/gentoo:master commit in: net-misc/rdesktop/files/

2018-08-21 Thread Bernard Cafarelli
commit: c987c9feec42910b20ffdee9b72dddbf5a6978ca
Author: Bernard Cafarelli  gentoo  org>
AuthorDate: Tue Aug 21 20:33:59 2018 +
Commit: Bernard Cafarelli  gentoo  org>
CommitDate: Tue Aug 21 20:34:10 2018 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c987c9fe

net-misc/rdesktop: support libressl in openssl 1.1 patch

This patch uses openssl-1.1 specific functions when openssl version is
new enough. This fails for libressl (reporting itself as higher
version), the patch is updated to check for libressl version number too

Package-Manager: Portage-2.3.48, Repoman-2.3.10

 net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch
index bea047cce9a..c74bd48c5aa 100644
--- a/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch
+++ b/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch
@@ -94,7 +94,7 @@ index 48751255..032e9b9e 100644
 +  BIGNUM *e = NULL;
 +  BIGNUM *n = NULL;
 +
-+#if OPENSSL_VERSION_NUMBER < 0x1010L
++#if (OPENSSL_VERSION_NUMBER < 0x1010L || defined(LIBRESSL_VERSION_NUMBER))
 +  e = rkey->e;
 +  n = rkey->n;
 +#else



[gentoo-commits] repo/gentoo:master commit in: net-misc/rdesktop/files/, net-misc/rdesktop/

2018-08-20 Thread Bernard Cafarelli
commit: 3368f33b04e6c2368ecc2b5de7099783947a512e
Author: Bernard Cafarelli  gentoo  org>
AuthorDate: Mon Aug 20 16:09:35 2018 +
Commit: Bernard Cafarelli  gentoo  org>
CommitDate: Mon Aug 20 16:13:52 2018 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3368f33b

net-misc/rdesktop: openssl 1.1 support and EAPI bump

Simplify and clean ebuild

Package-Manager: Portage-2.3.47, Repoman-2.3.10

 .../files/rdesktop-1.6.0-sound_configure.patch |   4 +-
 .../rdesktop/files/rdesktop-1.8.3-no_strip.patch   |  12 ++
 .../files/rdesktop-1.8.3-openssl-1.1.patch | 125 +
 .../files/rdesktop-1.8.3-xrandr_configure.patch|   4 +-
 net-misc/rdesktop/rdesktop-1.8.3-r3.ebuild |  70 
 5 files changed, 211 insertions(+), 4 deletions(-)

diff --git a/net-misc/rdesktop/files/rdesktop-1.6.0-sound_configure.patch 
b/net-misc/rdesktop/files/rdesktop-1.6.0-sound_configure.patch
index 8e64ba8b48c..b2f492b1071 100644
--- a/net-misc/rdesktop/files/rdesktop-1.6.0-sound_configure.patch
+++ b/net-misc/rdesktop/files/rdesktop-1.6.0-sound_configure.patch
@@ -1,5 +1,5 @@
 configure.ac.orig  2009-06-30 10:35:14.0 +0200
-+++ configure.ac   2009-06-30 11:35:10.0 +0200
+--- rdesktop.orig/configure.ac 2009-06-30 10:35:14.0 +0200
 rdesktop/configure.ac  2009-06-30 11:35:10.0 +0200
 @@ -228,7 +228,11 @@
  if test -n "$PKG_CONFIG"; then
  PKG_CHECK_MODULES(LIBAO, ao, [HAVE_LIBAO=1], [HAVE_LIBAO=0])

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.3-no_strip.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.3-no_strip.patch
new file mode 100644
index 000..018ceeedacf
--- /dev/null
+++ b/net-misc/rdesktop/files/rdesktop-1.8.3-no_strip.patch
@@ -0,0 +1,12 @@
+diff -Naur rdesktop-1.8.3.orig/Makefile.in rdesktop-1.8.3/Makefile.in
+--- rdesktop-1.8.3.orig/Makefile.in2013-01-21 13:28:14.0 +0100
 rdesktop-1.8.3/Makefile.in 2018-08-20 18:05:38.401218002 +0200
+@@ -60,7 +60,7 @@
+ installbin: rdesktop
+   mkdir -p $(DESTDIR)$(bindir)
+   $(INSTALL) rdesktop $(DESTDIR)$(bindir)
+-  $(STRIP) $(DESTDIR)$(bindir)/rdesktop
++  
+   chmod 755 $(DESTDIR)$(bindir)/rdesktop
+ 
+ .PHONY: installman

diff --git a/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch 
b/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch
new file mode 100644
index 000..bea047cce9a
--- /dev/null
+++ b/net-misc/rdesktop/files/rdesktop-1.8.3-openssl-1.1.patch
@@ -0,0 +1,125 @@
+From bd6aa6acddf0ba640a49834807872f4cc0d0a773 Mon Sep 17 00:00:00 2001
+From: Jani Hakala 
+Date: Thu, 16 Jun 2016 14:28:15 +0300
+Subject: [PATCH] Fix OpenSSL 1.1 compability issues
+
+Some data types have been made opaque in OpenSSL version 1.1 so
+stack allocation and accessing struct fields directly does not work.
+---
+ ssl.c | 65 ---
+ 1 file changed, 40 insertions(+), 25 deletions(-)
+
+diff --git a/ssl.c b/ssl.c
+index 48751255..032e9b9e 100644
+--- a/ssl.c
 b/ssl.c
+@@ -88,7 +88,7 @@ rdssl_rsa_encrypt(uint8 * out, uint8 * in, int len, uint32 
modulus_size, uint8 *
+ uint8 * exponent)
+ {
+   BN_CTX *ctx;
+-  BIGNUM mod, exp, x, y;
++  BIGNUM *mod, *exp, *x, *y;
+   uint8 inr[SEC_MAX_MODULUS_SIZE];
+   int outlen;
+ 
+@@ -98,24 +98,24 @@ rdssl_rsa_encrypt(uint8 * out, uint8 * in, int len, uint32 
modulus_size, uint8 *
+   reverse(inr, len);
+ 
+   ctx = BN_CTX_new();
+-  BN_init();
+-  BN_init();
+-  BN_init();
+-  BN_init();
+-
+-  BN_bin2bn(modulus, modulus_size, );
+-  BN_bin2bn(exponent, SEC_EXPONENT_SIZE, );
+-  BN_bin2bn(inr, len, );
+-  BN_mod_exp(, , , , ctx);
+-  outlen = BN_bn2bin(, out);
++  mod = BN_new();
++  exp = BN_new();
++  x = BN_new();
++  y = BN_new();
++
++  BN_bin2bn(modulus, modulus_size, mod);
++  BN_bin2bn(exponent, SEC_EXPONENT_SIZE, exp);
++  BN_bin2bn(inr, len, x);
++  BN_mod_exp(y, x, exp, mod, ctx);
++  outlen = BN_bn2bin(y, out);
+   reverse(out, outlen);
+   if (outlen < (int) modulus_size)
+   memset(out + outlen, 0, modulus_size - outlen);
+ 
+-  BN_free();
+-  BN_clear_free();
+-  BN_free();
+-  BN_free();
++  BN_free(y);
++  BN_clear_free(x);
++  BN_free(exp);
++  BN_free(mod);
+   BN_CTX_free(ctx);
+ }
+ 
+@@ -146,12 +146,20 @@ rdssl_cert_to_rkey(RDSSL_CERT * cert, uint32 * key_len)
+ 
+  Kudos to Richard Levitte for the following (. intiutive .) 
+  lines of code that resets the OID and let's us extract the key. */
+-  nid = OBJ_obj2nid(cert->cert_info->key->algor->algorithm);
++
++  X509_PUBKEY *key = NULL;
++  X509_ALGOR *algor = NULL;
++
++  key = X509_get_X509_PUBKEY(cert);
++  algor = X509_PUBKEY_get0_param(NULL, NULL, 0, , key);
++
++  nid = OBJ_obj2nid(algor->algorithm);
++
+   if