Hello Nir Soffer, Nijin Ashok,

I'd like you to do a code review.  Please visit

    https://gerrit.ovirt.org/63678

to review the following change.

Change subject: kvm2ovirt: Fixes issue in importing VMs with libvirt uri 
qemu+tcp
......................................................................

kvm2ovirt: Fixes issue in importing VMs with libvirt uri qemu+tcp

Current implemenation fails with following error

V2VProcessError: Job u'03751e96-bc69-410b-b8c5-7df5ca166d6c'
process failed exit-code: 1, stderr: Traceback (most recent call last):
  File "/lib/python2.7/site-packages/vdsm/libvirtconnection.py", line 91, in req
    cred[4] = passwd.value if passwd else None
AttributeError: 'str' object has no attribute 'value'
libvirt: Remote Driver error : authentication failed: Failed to collect auth 
credentials

We are incorrectly passing password as string to open_connection.

Bug-Url: https://bugzilla.redhat.com/1365051
Change-Id: Ifcd111f8b490ac64893afecf3ec1aad4b4d05b09
Signed-off-by: Nijin Ashok <[email protected]>
Reviewed-on: https://gerrit.ovirt.org/62052
Reviewed-by: Francesco Romani <[email protected]>
Tested-by: Francesco Romani <[email protected]>
Reviewed-by: Nir Soffer <[email protected]>
Continuous-Integration: Jenkins CI
---
M helpers/kvm2ovirt
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/78/63678/1

diff --git a/helpers/kvm2ovirt b/helpers/kvm2ovirt
index 41da464..ff22682 100755
--- a/helpers/kvm2ovirt
+++ b/helpers/kvm2ovirt
@@ -29,7 +29,7 @@
 from vdsm import concurrent
 from vdsm import libvirtconnection
 from vdsm import utils
-
+from vdsm.password import ProtectedPassword
 
 _start = utils.monotonic_time()
 
@@ -113,7 +113,7 @@
         write_output('>>> Reading password from file %s' %
                      options.password_file)
     with open(options.password_file, 'r') as f:
-        return f.read()
+        return ProtectedPassword(f.read())
 
 
 def main():


-- 
To view, visit https://gerrit.ovirt.org/63678
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifcd111f8b490ac64893afecf3ec1aad4b4d05b09
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-4.0
Gerrit-Owner: Francesco Romani <[email protected]>
Gerrit-Reviewer: Nijin Ashok <[email protected]>
Gerrit-Reviewer: Nir Soffer <[email protected]>
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/admin/lists/[email protected]

Reply via email to