We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The text was updated successfully, but these errors were encountered:
读取了/proc下的pids后,下图中只把pids遍历一遍就退出了,应该持续监听,直到宿主机再次运行docker exec就可以找到runc了。
这里有持续监听哈
for { writeHandle, _ := os.OpenFile("/proc/self/fd/"+strconv.Itoa(handleFd), os.O_WRONLY|os.O_TRUNC, 0700) if int(writeHandle.Fd()) > 0 { writeHandle.Write([]byte(payload))
Sorry, something went wrong.
5c611b4
1 的问题反馈得好棒,我加了一个 check 来 FIX 这个问题
关于第2个问题, 您说的那个循环是已经获取到pid以及file handle之后持续监听直到成功写入payload,那里没问题。我说的是第一步:获取pid,目前代码在这里是只遍历了一遍/proc就结束了:
应该持续在这里遍历/proc,直到宿主机上执行了docker exec *** /bin/sh,才会抓到runc的pid。比如可以改成这样:
docker exec *** /bin/sh
var found = -1 for found == -1 { pids, err := ioutil.ReadDir("/proc") if err != nil { fmt.Println("err found when reading /proc dir:", err) return } for _, f := range pids { …… …… } }
neargle
No branches or pull requests
建议在外面再加一个for循环
The text was updated successfully, but these errors were encountered: