From: Brian P. Hinz Date: Mon, 4 Jan 2016 03:04:02 +0000 (-0500) Subject: Remove uncessary Xauth cookie patch from deb & rpm packages X-Git-Tag: v1.6.90~48^2~11 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=4e1a609753428dcc8afeb5e9aab75a0a7a6b5bb6;p=tigervnc.git Remove uncessary Xauth cookie patch from deb & rpm packages Obsoleted by 7461517 --- diff --git a/contrib/packages/deb/ubuntu-precise/debian/patches/504_tigervnc-cookie.patch b/contrib/packages/deb/ubuntu-precise/debian/patches/504_tigervnc-cookie.patch deleted file mode 100644 index 1fc93c86..00000000 --- a/contrib/packages/deb/ubuntu-precise/debian/patches/504_tigervnc-cookie.patch +++ /dev/null @@ -1,36 +0,0 @@ ---- a/unix/vncserver 2009-11-12 11:39:54.000000000 +0100 -+++ b/unix/vncserver 2009-12-21 16:15:01.907799091 +0100 -@@ -189,27 +189,12 @@ $vncPort = 5900 + $displayNumber; - $desktopLog = "$vncUserDir/$host:$displayNumber.log"; - unlink($desktopLog); - --# Make an X server cookie - use /dev/urandom on systems that have it, --# otherwise use perl's random number generator, seeded with the sum --# of the current time, our PID and part of the encrypted form of the password. -- --my $cookie = ""; --if (open(URANDOM, '<', '/dev/urandom')) { -- my $randata; -- if (sysread(URANDOM, $randata, 16) == 16) { -- $cookie = unpack 'h*', $randata; -- } -- close(URANDOM); --} --if ($cookie eq "") { -- srand(time+$$+unpack("L",`cat $vncUserDir/passwd`)); -- for (1..16) { -- $cookie .= sprintf("%02x", int(rand(256)) % 256); -- } --} -- --system("xauth -f $xauthorityFile add $host:$displayNumber . $cookie"); --system("xauth -f $xauthorityFile add $host/unix:$displayNumber . $cookie"); -+# Make an X server cookie - use mcookie -+$cookie = `/usr/bin/mcookie`; -+open (XAUTH, "|xauth -f $xauthorityFile source -"); -+print XAUTH "add $host:$displayNumber . $cookie\n"; -+print XAUTH "add $host/unix:$displayNumber . $cookie\n"; -+close XAUTH; - - if ($opt{'-name'}) { - $desktopName = $opt{'-name'}; diff --git a/contrib/packages/deb/ubuntu-precise/debian/patches/series b/contrib/packages/deb/ubuntu-precise/debian/patches/series index 3a4ceba2..b57b12ad 100644 --- a/contrib/packages/deb/ubuntu-precise/debian/patches/series +++ b/contrib/packages/deb/ubuntu-precise/debian/patches/series @@ -5,5 +5,4 @@ 100_rethrow_signals.patch # Upstream patches -504_tigervnc-cookie.patch 516_tigervnc-xorg-manpages.patch diff --git a/contrib/packages/deb/ubuntu-trusty/debian/patches/504_tigervnc-cookie.patch b/contrib/packages/deb/ubuntu-trusty/debian/patches/504_tigervnc-cookie.patch deleted file mode 100644 index 1fc93c86..00000000 --- a/contrib/packages/deb/ubuntu-trusty/debian/patches/504_tigervnc-cookie.patch +++ /dev/null @@ -1,36 +0,0 @@ ---- a/unix/vncserver 2009-11-12 11:39:54.000000000 +0100 -+++ b/unix/vncserver 2009-12-21 16:15:01.907799091 +0100 -@@ -189,27 +189,12 @@ $vncPort = 5900 + $displayNumber; - $desktopLog = "$vncUserDir/$host:$displayNumber.log"; - unlink($desktopLog); - --# Make an X server cookie - use /dev/urandom on systems that have it, --# otherwise use perl's random number generator, seeded with the sum --# of the current time, our PID and part of the encrypted form of the password. -- --my $cookie = ""; --if (open(URANDOM, '<', '/dev/urandom')) { -- my $randata; -- if (sysread(URANDOM, $randata, 16) == 16) { -- $cookie = unpack 'h*', $randata; -- } -- close(URANDOM); --} --if ($cookie eq "") { -- srand(time+$$+unpack("L",`cat $vncUserDir/passwd`)); -- for (1..16) { -- $cookie .= sprintf("%02x", int(rand(256)) % 256); -- } --} -- --system("xauth -f $xauthorityFile add $host:$displayNumber . $cookie"); --system("xauth -f $xauthorityFile add $host/unix:$displayNumber . $cookie"); -+# Make an X server cookie - use mcookie -+$cookie = `/usr/bin/mcookie`; -+open (XAUTH, "|xauth -f $xauthorityFile source -"); -+print XAUTH "add $host:$displayNumber . $cookie\n"; -+print XAUTH "add $host/unix:$displayNumber . $cookie\n"; -+close XAUTH; - - if ($opt{'-name'}) { - $desktopName = $opt{'-name'}; diff --git a/contrib/packages/deb/ubuntu-trusty/debian/patches/series b/contrib/packages/deb/ubuntu-trusty/debian/patches/series index 3a4ceba2..b57b12ad 100644 --- a/contrib/packages/deb/ubuntu-trusty/debian/patches/series +++ b/contrib/packages/deb/ubuntu-trusty/debian/patches/series @@ -5,5 +5,4 @@ 100_rethrow_signals.patch # Upstream patches -504_tigervnc-cookie.patch 516_tigervnc-xorg-manpages.patch diff --git a/contrib/packages/rpm/el5/SPECS/tigervnc.spec b/contrib/packages/rpm/el5/SPECS/tigervnc.spec index daa7d897..3ef3455d 100644 --- a/contrib/packages/rpm/el5/SPECS/tigervnc.spec +++ b/contrib/packages/rpm/el5/SPECS/tigervnc.spec @@ -141,7 +141,6 @@ Provides: tightvnc = 1.5.0-0.15.20090204svn3586 Obsoletes: tightvnc < 1.5.0-0.15.20090204svn3586 # tigervnc patches -Patch4: tigervnc-cookie.patch Patch12: tigervnc14-static-build-fixes.patch Patch13: tigervnc14-Add-dridir-param.patch Patch14: tigervnc14-Add-xkbcompdir-param.patch @@ -298,7 +297,6 @@ rm -rf %{_builddir}/%{name}-%{version}%{?snap:-%{snap}} cp %SOURCE9 cmake/Modules/ sed -i -e "s#@_includedir@#%{xorg_buildroot}%{_includedir}#" cmake/Modules/FindX11.cmake sed -i -e "s#@_libdir@#%{xorg_buildroot}%{_libdir}#" cmake/Modules/FindX11.cmake -%patch4 -p1 -b .cookie %patch12 -p1 -b .static-build-fixes %if %{_bootstrap} diff --git a/contrib/packages/rpm/el6/SPECS/tigervnc.spec b/contrib/packages/rpm/el6/SPECS/tigervnc.spec index 1e07af59..1f68a5f2 100644 --- a/contrib/packages/rpm/el6/SPECS/tigervnc.spec +++ b/contrib/packages/rpm/el6/SPECS/tigervnc.spec @@ -60,7 +60,6 @@ Obsoletes: vnc < 4.1.3-2, vnc-libs < 4.1.3-2 Provides: tightvnc = 1.5.0-0.15.20090204svn3586 Obsoletes: tightvnc < 1.5.0-0.15.20090204svn3586 -Patch4: tigervnc-cookie.patch Patch16: tigervnc-xorg-manpages.patch %description @@ -161,8 +160,6 @@ This package contains static development files necessary to build TigerVNC rm -rf $RPM_BUILD_ROOT %setup -q -n %{name}-%{version}%{?snap:-%{snap}} -%patch4 -p1 -b .cookie - %if %{_bootstrap} tar xzf %SOURCE11 tar xjf %SOURCE13 diff --git a/contrib/packages/rpm/el7/SPECS/tigervnc.spec b/contrib/packages/rpm/el7/SPECS/tigervnc.spec index d99547eb..4420a7f5 100644 --- a/contrib/packages/rpm/el7/SPECS/tigervnc.spec +++ b/contrib/packages/rpm/el7/SPECS/tigervnc.spec @@ -49,7 +49,6 @@ Obsoletes: vnc < 4.1.3-2, vnc-libs < 4.1.3-2 Provides: tightvnc = 1.5.0-0.15.20090204svn3586 Obsoletes: tightvnc < 1.5.0-0.15.20090204svn3586 -Patch4: tigervnc-cookie.patch Patch17: tigervnc-shebang.patch %description @@ -155,7 +154,6 @@ This package contains static development files necessary to build TigerVNC rm -rf $RPM_BUILD_ROOT %setup -q -n %{name}-%{version}%{?snap:-%{snap}} -%patch4 -p1 -b .cookie %if %{_bootstrap} tar xzf %SOURCE11 %endif