DragonFlyBSD Kernel Audit
DF-3049 / run.sh
← back to finding ↓ download raw
#!/bin/sh
# DF-3049 run (guest, root): three mount attempts with heap churn between
set -e
kldload ext2fs
/root/vntool attach 0 /root/df3049.img
mount -t ext2fs -o ro /dev/vn0 /mnt/e2 || echo RC-A=$?
/root/vntool detach 0; /root/vntool attach 0 /root/df3049.img
newfs /dev/vn1 >/dev/null 2>&1 || true
mount /dev/vn1 /mnt/churn 2>/dev/null && umount /mnt/churn
mount -t ext2fs -o ro /dev/vn0 /mnt/e2 || echo RC-B=$?
/root/vntool detach 0; /root/vntool attach 0 /root/df3049.img
mount -t ext2fs -o ro /dev/vn0 /mnt/e2 || echo RC-C=$?
# inspect serial console / dmesg for 'bad gd=NN ... expected=0xNNNN'