From 3efeef969ebc344c993ce0fc46f557c7d8560525 Mon Sep 17 00:00:00 2001 From: We-unite <3205135446@qq.com> Date: Wed, 31 Jul 2024 11:46:01 +0800 Subject: Use netlink connector to recv pid info, fix exec For some reasons, kernel-connector can catch exec event, but it doesn't tell me about what the process exec and what're its args. So we should use audit to collect these infomations, and complete in the database. However, there's different delays between connector and audit, although they both use netlink socket, as a result of which, exec may comes before fork. we deal with it the same way. But, there's also exec event lost, may because of the check for ppid in exec event, but it's necessary, and if is deleted, too much irrelavent infomation would flood into database, i've tried. So make it there, just go forward. Besides, what's newly discovered is that pthread_create also use clone syscall, but if pid 1 has a thread 2, the exec info will say that pid 2 execs. So i shouldn't ignore connector msg that childPid ne childTgid. This is my first attempt to use git-submodule function in my own pro- ject, also golang local package. Congratulations! Now, fight to fix about file operations. Hope that there wouldn't be too many fucking bugs. --- .gitmodules | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .gitmodules (limited to '.gitmodules') diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..6a63c7b --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "src/netlink"] + path = src/netlink + url = https://github.com/We-unite/netlink -- cgit v1.2.3-70-g09d2