准备:环境
| 2025-6-18
Words 113Read Time 1 min

kernel

克隆,defconfig,menuconfig
kernel hacking → compile-time checks → debug info→ rely on toolchain
→ enable full section mismatch analysis

buildroot

Buildroot - Making Embedded Linux Easy
下载后解压,defconfig,menuconfig,开ext4

qemu

 
qemu-system-x86_64 -kernel arch/x86_64/boot/bzImage -nographic -append "console=ttyS0”
qemu-system-x86_64 -kernel arch/x86_64/boot/bzImage -nographic -append "console=ttyS0 nokaslr root=/dev/vda rw" -drive file=/home/hezhengyu/program/git/buildroot/buildroot-2025.02/output/images/rootfs.ext4,if=virtio,format=raw

gdb

gdb vmlinux
target remote :1234

gef

Loading...