mirror of
				https://github.com/speed47/spectre-meltdown-checker.git
				synced 2025-10-31 20:50:55 +01:00 
			
		
		
		
	fix(xen): remove xenbus and xenwatch as they also exist in domU
This commit is contained in:
		| @@ -4018,14 +4018,15 @@ check_CVE_2018_3646_linux() | |||||||
| 			# this can always be overridden with --vmm in any case. | 			# this can always be overridden with --vmm in any case. | ||||||
| 			has_vmm=0 | 			has_vmm=0 | ||||||
| 			if command -v pgrep >/dev/null 2>&1; then | 			if command -v pgrep >/dev/null 2>&1; then | ||||||
|  | 				# remove xenbus and xenwatch, also present inside domU | ||||||
| 				if pgrep qemu >/dev/null || pgrep kvm >/dev/null || pgrep libvirtd >/dev/null || \ | 				if pgrep qemu >/dev/null || pgrep kvm >/dev/null || pgrep libvirtd >/dev/null || \ | ||||||
| 					pgrep xenbus >/dev/null || pgrep xenwatch >/dev/null || pgrep xenstored >/dev/null || pgrep xenconsoled >/dev/null; then | 					pgrep xenstored >/dev/null || pgrep xenconsoled >/dev/null; then | ||||||
| 					has_vmm=1 | 					has_vmm=1 | ||||||
| 				fi | 				fi | ||||||
| 			else | 			else | ||||||
| 				# ignore SC2009 as `ps ax` is actually used as a fallback if `pgrep` isn't installed | 				# ignore SC2009 as `ps ax` is actually used as a fallback if `pgrep` isn't installed | ||||||
| 				# shellcheck disable=SC2009 | 				# shellcheck disable=SC2009 | ||||||
| 				if ps ax | grep -vw grep | grep -q -e '\<qemu' -e '/qemu' -e '<\kvm' -e '/kvm' -e '/libvirtd' -e '\[xenbus\]' -e '\[xenwatch\]' -e '/xenstored' -e '/xenconsoled'; then | 				if ps ax | grep -vw grep | grep -q -e '\<qemu' -e '/qemu' -e '<\kvm' -e '/kvm' -e '/libvirtd' -e '/xenstored' -e '/xenconsoled'; then | ||||||
| 					has_vmm=1 | 					has_vmm=1 | ||||||
| 				fi | 				fi | ||||||
| 			fi | 			fi | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user