Skip to contentSkip to conversation

x86/msr: Filter MSR writes

PATCH In review Gyan Gupta 2 participants 2 messages Jun 22, 2020

lore
Share & tools
lore

Gyan Gupta

author
#0 lore raw

PATCH 1/1 x86/msr: Filter MSR writes

From: Borislav Petkov <[email protected]>

Quoted 3 lines

The whitelist is still TBD, I might be able to remove it competely and defer the whole whitelisting to the future. when people start reporting MSRs (see pr_err_ratelimited() call below).

I am also working on a similar functionality where we allow specific MSRs(whitelisted MSRs) to be allowed to read & write. Additionally, writes are subjected to checks where only certain bits can be allowed to be modified. This is to increase security & safety of system. For example, MCi_CTL can be used to enable/disable error reporting of hw unit. So in our use case once error reporting is enabled, it must not be disabled. Also we want to have restrictions on rdmsr for security purposes.

- Gyan

#1 lore raw
Quoted 9 lines · Gyan Gupta

I am also working on a similar functionality where we allow specific MSRs(whitelisted MSRs) to be allowed to read & write. Additionally, writes are subjected to checks where only certain bits can be allowed to be modified. This is to increase security & safety of system.

For example, MCi_CTL can be used to enable/disable error reporting of hw unit. So in our use case once error reporting is enabled, it must not be disabled. Also we want to have restrictions on rdmsr for security purposes.

IInstead of defining whitelists, you should design proper interfaces through sysfs or so which control the functionality you want.

If you want to do some internal testing, you don't need the whitelists either - you simply enable writing to all MSRs like it is the case now.

Signature · 4 lines
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette