Upon start of a VM, it gets its initial time from the host.* Therefore we can conclude by logic, that the virtualizer must somehow provide access of the information (the host time) to the VM.
There are two different mechanisms not to be confused
- kvmclock - which Whonix KVM libvirt xml files are explicitly not using because of this
- wall clock
Quote http://lists.xen.org/archives/html/xen-users/2015-08/msg00019.html
there is also a pv wallclock (i.e. date and time) interface, but I don't think that's what Linux's clocksource is about
An adversary with the capability to compromise a Whonix-Workstation VM + observer local clock leaks can run a clock correlation attack. Described in more detail here:
https://www.whonix.org/wiki/Dev/TimeSync#Clock_Correlation_Attack
*Unless advanced users reading advanced security guide apply Spoof the Initial Virtual Hardware Clock Offset instructions. (Probably very few are doing this.)
TODO research:
- gather more information on the wall clock interface
- find out if the wall clock information is only provided to the VM upon start of the VM or if the wall clock is continuously updated
- figure out what can be done about this
- perhaps enable some "only update wallclock at VM start time" feature if available
- see if KVM has something similar to what Xen [had|has](?) /proc/sys/xen/independent_wallclock
- if applicable, explain upstream and write feature requests