Debian Codegraph @

testsuite/systemtap.examples/security-band-aids/cve-2011-4127.stp

raw
1 #!/usr/sbin/stap -g
2 # Requires guru mode (-g) for target variable writes
3 probe syscall.ioctl {
4 SG_IO = 0x2285
5 if($cmd == SG_IO && execname() == "qemu-kvm") {
6 printf("filtering SG_IO ioctl request from qemu-kvm process %d\n", pid())
7 $cmd = 0x0
8 $fd = -1
9 }
10 }