KVM-VMI / kvm

Fork of KVM with Virtual Machine Introspection patches
Other
33 stars 28 forks source link

kvm: introspection: fix suppressed page faults #58

Closed thomasdangl closed 1 year ago

thomasdangl commented 1 year ago

EPT violations on pages are filtered for sub-page write protection so that the introspection library only receives faults on the monitored sub-page. While we ensure that the feature is enabled in practically all other locations of interest, kvmi_restricted_access does not perform this check.

This issue is especially troublesome if the application intends to change the page protection upon such an event. In my case, it caused over 8 million page faults (compared to around 500 after this fix).

I propose to add a check for the feature before using the bitmap.

Best, Thomas