File disable_PreferredAuthentications_password.patch of Package virt-test

diff -rau virttest/remote.py virttest.ssh/remote.py
--- virttest/remote.py	2014-03-06 22:46:05.700843968 +0100
+++ virttest.ssh/remote.py	2014-03-18 15:59:25.856005541 +0100
@@ -216,7 +216,7 @@
         host = "%s%%%s" % (host, interface)
     if client == "ssh":
         cmd = ("ssh -o UserKnownHostsFile=/dev/null "
-               "-o PreferredAuthentications=password -p %s %s@%s" %
+               "-p %s %s@%s" %
                (port, username, host))
     elif client == "telnet":
         cmd = "telnet -l %s %s %s" % (username, host, port)
@@ -408,7 +408,7 @@
         host = "%s%%%s" % (host, interface)
 
     command = ("scp -v -o UserKnownHostsFile=/dev/null "
-               "-o PreferredAuthentications=password -r %s "
+               "-r %s "
                "-P %s %s %s@\[%s\]:%s" %
                (limit, port, local_path, username, host, remote_path))
     password_list = []
@@ -443,7 +443,7 @@
         host = "%s%%%s" % (host, interface)
 
     command = ("scp -v -o UserKnownHostsFile=/dev/null "
-               "-o PreferredAuthentications=password -r %s "
+               "-r %s "
                "-P %s %s@\[%s\]:%s %s" %
                (limit, port, username, host, remote_path, local_path))
     password_list = []
@@ -485,7 +485,7 @@
         dst = "%s%%%s" % (dst, dst_inter)
 
     command = ("scp -v -o UserKnownHostsFile=/dev/null -o "
-               "PreferredAuthentications=password -r %s -P %s"
+               "-r %s -P %s"
                " %s@\[%s\]:%s %s@\[%s\]:%s" %
                (limit, port, s_name, src, s_path, d_name, dst, d_path))
     password_list = []
diff -rau virttest/utils_env.py virttest.ssh/utils_env.py
--- virttest/utils_env.py	2014-03-06 22:46:05.706843929 +0100
+++ virttest.ssh/utils_env.py	2014-03-18 16:00:27.606545435 +0100
@@ -327,7 +327,7 @@
         cmd = cmd_template % utils_misc.find_command("tcpdump")
         if self._params.get("remote_preprocess") == "yes":
             login_cmd = ("ssh -o UserKnownHostsFile=/dev/null -o "
-                         "PreferredAuthentications=password -p %s %s@%s" %
+                         "-p %s %s@%s" %
                          (port, username, address))
 
             self._tcpdump = aexpect.ShellSession(
diff -rau virttest/virsh.py virttest.ssh/virsh.py
--- virttest/virsh.py	2014-03-06 22:46:05.710843903 +0100
+++ virttest.ssh/virsh.py	2014-03-18 15:59:50.242823838 +0100
@@ -139,7 +139,7 @@
         # Special handling if setting up a remote session
         if ssh_remote_auth:  # remote to remote
             if remote_pwd:
-                pref_auth = "-o PreferredAuthentications=password"
+                pref_auth = ""
             else:
                 pref_auth = "-o PreferredAuthentications=hostbased,publickey"
             # ssh_cmd is not None flags this as remote session
openSUSE Build Service is sponsored by