Change in vdsm[master]: iscsicred: Support per-host iscsi credentials database

nsoffer at redhat.com nsoffer at redhat.com
Sun Jul 5 11:04:33 UTC 2015


Nir Soffer has posted comments on this change.

Change subject: iscsicred: Support per-host iscsi credentials database
......................................................................


Patch Set 1:

(1 comment)

https://gerrit.ovirt.org/#/c/43179/1/tests/iscsicred_test.py
File tests/iscsicred_test.py:

Line 56:                              "password": ProtectedPassword("12345678")})
Line 57: 
Line 58:     def test_whitespace(self):
Line 59:         data = "".join(["    username  =  foo:bar   \n",
Line 60:                         "    password  =  12345678  \n"])
> This format is basically the same format of iscsid database (e.g. /var/lib/
I tried to set a password with leading and trailing whitespace:

    iscsiadm -m node -T iqn....a14490eb9836 -o update -n node.session.auth.password -v ' fancy '

The password was saved as specified:

    node.session.auth.password =  fancy 

The leading and trailing space are stored in the file - note the leading space
after the "=", and there was also trailing space after "y".

However, the whitespace is dropped when logging in. I tried to login (the actual
password is "fancy" without leading and trailing whitespace), and the login was
successful.

I think we are safe this this format.
Line 61:         with credfile(self.TARGET, data):
Line 62:             d = iscsicred.get_credentials(self.TARGET)
Line 63:         self.assertEqual(d, {"username": "foo:bar",
Line 64:                              "password": ProtectedPassword("12345678")})


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I8f6a838f6b8e132d6b0c1a8135f2c28ef1e7f847
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Adam Litke <alitke at redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Tal Nisan <tnisan at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list