power4j / vm-detect

import from https://gitlab.com/polloloco/vm-detect

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Basic VM detection for x86 and x86_64

Latest version Documentation License

Usage:

use vm_detect::{vm_detect, Detection};

fn main() {
    // Run detection
    let detection = vm_detect();

    // Inspect detections
    if detection.contains(Detection::HYPERVISOR_BIT) {
        println!("Hypervisor bit set!");
    }
}

About

import from https://gitlab.com/polloloco/vm-detect

License:MIT License


Languages

Language:Rust 100.0%