On 11/11/2010 05:39 AM, Gerd Hoffmann wrote:
Hi,
If anything goes wrong in the mgmt tool at step 2 though,
then it may never to step 3, leaving the VNC server accessible.
I think the point is that you can expire the password by just changing
it through the monitor.
Well, you can't really expire it, you can only set it to $randomvalue.
Unsetting the vnc password also disables authentication (in unstable),
which is *not* what you want here ...
Having an expiration policy builtin to QEMU (as
opposed to libvirt) seems like the wrong place.
IMHO it doesn't build policy into qemu. It is still up to libvirt (or
the management app building on top of libvirt) to decide if and when
the password will expire.
Except if you want to cancel the expiration because the expiration
policy changes. You'd have to set the password without an expiration
time and you may not have ready access to the password.
qemu will just do what libvirt asks for.
Instead of passing a expire time as implemented by the patches:
set-password $protocol $secret $time
we could add a expire-password command, then ask management to do
set-password $protocol $secret
[ let $time pass ]
expire-password $protocol
I fail to see why this is better though. The former is more robust
and easier to implement in the management. The amount of code needed
in qemu is probably quite similar ...
But the later let's a management tool implement arbitrarily complex
expiration policies. It can also be used to generically disable any
login which is effectively expiration but it may not be directly because
of a timeout but rather because of some other operation. For instance,
a management tool might want to implement a login policy whereas you're
only allowed to log into a VM during business hours (9-5). Setting an
expiration time for 8 hours is quite a bit less straight forward than
just unsetting the password during the off hours.
Regards,
Anthony Liguori
cheers,
Gerd