Re: [PATCH v3 20/35] x86/bugs: Define attack vectors

Borislav Petkov
2025-02-27T15:37:28Z

On Thu, Feb 27, 2025 at 03:22:08PM +0000, Kaplan, David wrote:
> In this case, I think it is clearer to say
> mitigations=auto;no_guest_guest
>
> That way, the admin is explicitly saying they don't want certain protection.
> This seems much harder to mess up.

So if we want to protect *only* against malicious VMs, the cmdline should be

mitigations:off;no_guest_guest

off being the policy to disable the other vectors because admin wants to have
her performance back.

Right?

Which then makes this one:

mitigations=off;guest_host

equivalent.

Uff.

> My argument is it's probably better to err on the side of security.

Probably. As you can realize, I'm playing the devil's advocate in all this
so that we can see how we feel about it.

> To me this seems like an unlikely use case, so maybe it's ok to be a bit more verbose.

Right, that use case is for benchmarkers. :)

> Ok, I can add that to the series.

Thx.

> But there's already an 'auto,nosmt' option. So I thought we wanted to leave
> that alone and use it as the base.

There's that. And "nosmt" is actually the cross-thread attack vector.

I guess what we should do here is to leave "auto,nosmt" alone and use
"cross_thread" for the attack vector and not allow "nosmt" in the new
mitigations specification scheme.

IOW, the set of the attack vectors will be:

list_of_vectors = {user_kernel, user_user, guest_host, guest_guest,
cross_thread }

Or the no_ versions of them respectively.

Hmmm.

--
Regards/Gruss,
Boris.