⬢ DragonFlyBSD Kernel Audit
DF-5198 / trigger.sh
← back to finding ↓ download raw
#!/bin/sh
# DF-5198 — live-path exercise of fire_saver (the set_video_mode twin of
# DF-5114/DF-5197). Run as root on the DragonFly guest (vm.sh run_root).
# Exercises: module load gate (get_mode_info), blank dispatch, ~13s of fire
# rendering across two cycles, unblank restore, module unload.
# Success criterion on stock kernel: all markers printed, guest stays up,
# no panic on the serial console. The latent OOB branch itself cannot fire.
set -x
kldload fire_saver && echo KLDLOAD_OK
vidcontrol -t 1 < /dev/ttyv0 && echo ARMED
sleep 5
vidcontrol -t 600 < /dev/ttyv0 && echo REARMED_OK
sleep 2
echo STILL_ALIVE
vidcontrol -t 3 < /dev/ttyv0
sleep 8
vidcontrol -t 600 < /dev/ttyv0
sleep 2
echo SECOND_CYCLE_DONE
kldunload fire_saver && echo UNLOADED
kldstat | grep -c fire
echo CLEAN