A simple cli tool to monitor the file opening of application processes.
# zcat /proc/config.gz | grep CONFIG_BPF=y
CONFIG_BPF=y
# zcat /proc/config.gz | grep CONFIG_KPROBES=y
CONFIG_KPROBES=y
$ uname -m
aarch64 or x86_64
# ./file-monitor
m, err := monitor.NewMonitor()
if err != nil {
println(err.Error())
return
}
defer m.Close()
m.Launch()
for {
event, ok := <-m.Events():
// handle events
}
make
, clang
, Android NDK
ANDROID_NDK=/path/to/android-ndk make all