Sisyphus repositório
Última atualização: 1 outubro 2023 | SRPMs: 18631 | Visitas: 37404094
en ru br
ALT Linux repositórios
S:1.11.0-alt1

Group :: Rede/Acesso Remoto
RPM: tigervnc

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs e FR  Repocop 

Patch: tigervnc-stdinpasswd.patch
Download


diff -ur tigervnc-1.3.1/vncviewer/parameters.cxx tigervnc-1.3.1.new/vncviewer/parameters.cxx
--- tigervnc-1.3.1/vncviewer/parameters.cxx	2013-07-01 14:00:20.000000000 +0000
+++ tigervnc-1.3.1.new/vncviewer/parameters.cxx	2014-06-25 12:19:01.529927256 +0000
@@ -59,6 +59,7 @@
 StringParameter passwordFile("PasswordFile",
                              "Password file for VNC authentication", "");
 AliasParameter passwd("passwd", "Alias for PasswordFile", &passwordFile);
+BoolParameter passwdInput("passwdInput", "Gets password from stdin", false);
 
 BoolParameter autoSelect("AutoSelect",
                          "Auto select pixel format and encoding. "
diff -ur tigervnc-1.3.1/vncviewer/parameters.h tigervnc-1.3.1.new/vncviewer/parameters.h
--- tigervnc-1.3.1/vncviewer/parameters.h	2013-02-15 08:33:39.000000000 +0000
+++ tigervnc-1.3.1.new/vncviewer/parameters.h	2014-06-25 12:19:01.529927256 +0000
@@ -26,6 +26,7 @@
 extern rfb::BoolParameter dotWhenNoCursor;
 
 extern rfb::StringParameter passwordFile;
+extern rfb::BoolParameter passwdInput;
 
 extern rfb::BoolParameter autoSelect;
 extern rfb::BoolParameter fullColour;
diff -ur tigervnc-1.3.1/vncviewer/UserDialog.cxx tigervnc-1.3.1.new/vncviewer/UserDialog.cxx
--- tigervnc-1.3.1/vncviewer/UserDialog.cxx	2012-04-25 15:43:56.000000000 +0000
+++ tigervnc-1.3.1.new/vncviewer/UserDialog.cxx	2014-06-25 12:29:19.717191042 +0000
@@ -22,7 +22,8 @@
 
 #include <assert.h>
 #include <stdio.h>
-#include <string.h>
+#include <string>
+#include <iostream>
 
 #include <FL/Fl.H>
 #include <FL/fl_ask.H>
@@ -82,6 +83,15 @@
     return;
   }
 
+  // QnD hack for reading password from stdin
+  if (passwdInput) {
+    std::string s;
+    std::cin >> s;
+    *password = strdup(s.c_str());
+    if (user) *user = 0;
+    return;
+  }
+
   Fl_Window *win;
   Fl_Box *banner;
   Fl_Input *username;
diff -ur tigervnc-1.3.1/vncviewer/vncviewer.man tigervnc-1.3.1.new/vncviewer/vncviewer.man
--- tigervnc-1.3.1/vncviewer/vncviewer.man	2014-06-25 12:31:45.837386688 +0000
+++ tigervnc-1.3.1.new/vncviewer/vncviewer.man	2014-06-25 12:19:01.529927256 +0000
@@ -160,6 +160,10 @@
 Accept clipboard changes from the server (default).
 
 .TP
+.B \-passwdInput
+Get vnc password from standard input instead of showing dialog window (the default).
+
+.TP
 .B \-Shared
 When you make a connection to a VNC server, all other existing connections are
 normally closed.  This option requests that they be left open, allowing you to
Только в tigervnc-1.3.1.new/vncviewer: vncviewer.man.orig
 
projeto & código: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
mantenedor atual: Michael Shigorin
mantenedor da tradução: Fernando Martini aka fmartini © 2009