[node-patches] Change in ovirt-node[master]: Deprecate ovirtfunctions.rng_status()

fabiand at redhat.com fabiand at redhat.com
Fri Mar 13 10:18:56 UTC 2015


Fabian Deutsch has posted comments on this change.

Change subject: Deprecate ovirtfunctions.rng_status()
......................................................................


Patch Set 2: Code-Review+1 Verified-1

(1 comment)

I like that patch! We need it, but a a small comment.

https://gerrit.ovirt.org/#/c/34951/2/src/ovirt/node/utils/security.py
File src/ovirt/node/utils/security.py:

Line 169:             rng_status["rng_bytes"] = f.findall(r'SSH_USE_STRONG_RNG=\d+'
Line 170:                                                 )[0].split('=')[1]
Line 171:         if f.findall(r'DISABLE_AES_NI='):
Line 172:             rng_status["disable_aes_ni"] = True
Line 173:         return rng_status
I see that you often use rng_status().values(), but as rng_status() returns a dict, values() is never guaranteed to have a specific value order.

Thus I suggest that we change the return value of rng_status() from -> dict to -> tuple(bytes, aesni_enabled)
Line 174: 
Line 175:     def restart(self):
Line 176:         self.logger.debug("Restarting SSH")
Line 177:         system.service("sshd", "restart")


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I98730b91618a2f3cb65c7058c9fbe2ad50b80f11
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-node
Gerrit-Branch: master
Gerrit-Owner: Ryan Barry <rbarry at redhat.com>
Gerrit-Reviewer: Fabian Deutsch <fabiand at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes



More information about the node-patches mailing list