Vinzenz Feenstra has posted comments on this change.

Change subject: agent: XML Character filtering improvement
......................................................................


Patch Set 2: (2 inline comments)

....................................................
File vdsm/guestIF.py
Line 44:     def maskRestricted(c):
Line 45:         if ord(c) in __RESTRICTED_CHARS:
Line 46:             return '?'
Line 47:         else:
Line 48:             return c
yes
Line 49:     return ''.join(maskRestricted(c) for c in u)
Line 50: 
Line 51: 
Line 52: class MessageState:


Line 128:             # ovirt-guest-agent reports the following fields in 
'memory-stat':
Line 129:             # 'mem_total', 'mem_free', 'mem_unused', 'swap_in', 
'swap_out',
Line 130:             # 'pageflt' and 'majflt'
Line 131:             if 'memory-stat' in args:
Line 132:                 for (k, v) in args['memory-stat'].iteritems():
Theoretically no. Practically I would filter the whole object, anyway in 
Unicode form as well to be on the safe side.
Line 133:                     k = _filterXmlChars(k)
Line 134:                     # Convert the value to string since 64-bit 
integer is not
Line 135:                     # supported in XMLRPC
Line 136:                     v = _filterXmlChars(str(v))


--
To view, visit http://gerrit.ovirt.org/13809
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I21b970c8552b3f238c6bfe9271c5c5a37d40ea4d
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Vinzenz Feenstra <[email protected]>
Gerrit-Reviewer: Dan Kenigsberg <[email protected]>
Gerrit-Reviewer: Michal Skrivanek <[email protected]>
Gerrit-Reviewer: Peter V. Saveliev <[email protected]>
Gerrit-Reviewer: Vinzenz Feenstra <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to