上一页 1 ··· 66 67 68 69 70 71 72 73 74 ··· 164 下一页

2020年12月8日

摘要: 背景 最近在阅读 runc 的实现,发现在 runc 中比较重要的一个逻辑是在设置 namespace 过程中的 nsenter 模块,其中逻辑有些绕,也发现了一段很长很有意思的注释,分享一下。 What 什么是 nsenter,nsenter 是 runc 中的一个 package,它包含了一个特 阅读全文
posted @ 2020-12-08 10:20 tycoon3 阅读(486) 评论(0) 推荐(0)
摘要: default_vcpus = 1 root@ubuntu:/# lscpu Architecture: aarch64 Byte Order: Little Endian CPU(s): 1 On-line CPU(s) list: 0 Thread(s) per core: 1 Core(s) 阅读全文
posted @ 2020-12-08 09:56 tycoon3 阅读(106) 评论(0) 推荐(0)

2020年12月7日

摘要: #define _GNU_SOURCE #include<sched.h> #include<stdio.h> #include<stdlib.h> #include<sys/wait.h> #include<unistd.h> #include<errno.h> #include<string.h 阅读全文
posted @ 2020-12-07 19:15 tycoon3 阅读(950) 评论(0) 推荐(0)
摘要: One of the building blocks to implement containers is Linux namespaces. Namespaces control what a process can see. It can be the processes IDs, mount 阅读全文
posted @ 2020-12-07 17:48 tycoon3 阅读(121) 评论(0) 推荐(0)
摘要: root@cloud:~# ps -elf | grep nsexec 0 S root 57368 56786 0 80 0 - 420 wait 14:23 pts/0 00:00:00 ./nsexec 0 S root 57387 57371 0 80 0 - 1418 pipe_r 14: 阅读全文
posted @ 2020-12-07 14:51 tycoon3 阅读(297) 评论(0) 推荐(0)

2020年12月6日

摘要: https://x3fwy.bitcron.com/post/runc-malicious-container-escape The `nsenter` package will `import "C"` and it uses [cgo](https://golang.org/cmd/cgo/) 阅读全文
posted @ 2020-12-06 18:16 tycoon3 阅读(342) 评论(0) 推荐(0)
摘要: C 库宏 - setjmp 描述 C 库宏 int setjmp(jmp_buf environment) :创建本地的jmp_buf缓冲区并且初始化,用于将来跳转回此处。这个子程序保存程序的调用环境于env参数所指的缓冲区,env将被longjmp使用。如果是从setjmp直接调用返回,setjm 阅读全文
posted @ 2020-12-06 11:33 tycoon3 阅读(191) 评论(0) 推荐(0)

2020年12月4日

摘要: https://github.com/haslm/toolchain/tree/a29fb3909141887df1d898181010f71ac011876f/runc / finalizeRootfs sets anything to ro if necessary. You must call 阅读全文
posted @ 2020-12-04 20:15 tycoon3 阅读(389) 评论(0) 推荐(0)
摘要: https://www.jianshu.com/p/c48e6cd84ff5 nsenter/nsenter.go 1、怎么获取mydocker_pid 2、怎么获取mydocker_cmd package nsenter /* #include <errno.h> #include <sched. 阅读全文
posted @ 2020-12-04 17:18 tycoon3 阅读(132) 评论(0) 推荐(0)
摘要: https://segmentfault.com/a/1190000017576314 root@ubuntu:/# ls /run/libcontainer/ -al total 0 drwx 3 root root 60 Dec 4 06:37 . drwxr-xr-x 11 root root 阅读全文
posted @ 2020-12-04 15:56 tycoon3 阅读(397) 评论(0) 推荐(0)
上一页 1 ··· 66 67 68 69 70 71 72 73 74 ··· 164 下一页

导航