audit: ignore virtual hdisk and coprocessor noise

This commit is contained in:
Mikhail Chusavitin
2026-04-02 09:56:17 +03:00
parent dbab43db90
commit b2b0444131
8 changed files with 154 additions and 12 deletions

View File

@@ -91,7 +91,11 @@ func discoverStorageDevices() []lsblkDevice {
// These have zero reported size, a generic fake serial, and a model name that
// starts with "Virtual HDisk".
func isVirtualBMCDisk(dev lsblkDevice) bool {
model := strings.ToLower(strings.TrimSpace(dev.Model))
return isVirtualHDiskModel(dev.Model)
}
func isVirtualHDiskModel(model string) bool {
model = strings.ToLower(strings.TrimSpace(model))
return strings.HasPrefix(model, "virtual hdisk")
}