[PATCH RFC 10/11] um: Delay timer_read only in possible busy loops in TT-mode

Benjamin Berg benjamin at sipsolutions.net
Fri Nov 10 08:39:39 PST 2023


On Fri, 2023-11-10 at 16:54 +0100, Benjamin Beichler wrote:
> At the moment, we haven't patched the random device that fetches random 
> bytes from the host (do you already have a patch for this?),
> so complete repeatability isn't guaranteed at the moment. However, that 
> could be a logical next step.

Right, we have the attached kernel patches internally. This simply
disables some of the random sources and replaces os_getrandom with
returning static random from the UML_RANDOM environment variable.

I doubt that it makes sense to upstream these patches, but may we can
include them as patch files in USFSTL or so.

The second piece is using a mount namespace to ensure that the linux
command line is identical between runs and that the location of all
files that are accessed directly from the host through hostfs never
changes.

The last piece was setting GLIBC_TUNABLES=-AVX512CD in the environment
just in case the CPU feature set is slightly different. That would
cause ld.so to search for a different set of optimized library versions
(affecting syscalls and with that randomness).

Benjamin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-um-Use-fixed-random-seed-if-UML_RANDOM-is-set.patch
Type: text/x-patch
Size: 1758 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-um/attachments/20231110/244b1b75/attachment-0003.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-random-disable-interrupt-random-source.patch
Type: text/x-patch
Size: 1057 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-um/attachments/20231110/244b1b75/attachment-0004.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-random-do-not-include-utsname-in-early-random.patch
Type: text/x-patch
Size: 1021 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-um/attachments/20231110/244b1b75/attachment-0005.bin>


More information about the linux-um mailing list