Re:Abusing Privileged and Unprivileged Linux Containers
by gshulegaard on Wednesday June 01, 2016 @05:04PM
(#11818147)
That's interesting...it was my impression that some of the kernel features were added specifically as a result of the kernel patches that were originally part of the OpenVZ project. Once the kernel adopted official primatives the original OpenVZ patches were deprecated. It was also at this time that LXC started with some of the same developers from the OpenVZ project.
I could be wrong...but that path dependency seems to indicate that while they were implemented as more general kernel features...one of their motivating use cases was container isolation.
Can anyone more informed clarify the history for me?
Re:Abusing Privileged and Unprivileged Linux Containers
by tptacek on Wednesday June 01, 2016 @06:27PM
(#11818762)
I'm not evaluating the container features in isolation. Considered by themselves, they might be perfectly coherent. The problem is that every feature of the kernel with a namespace of any sort needs to be aware of those container features, and namespaces leak into each other unexpectedly, because most of them are very old and were implemented long before anyone considered containerization.
Re:Abusing Privileged and Unprivileged Linux Containers
by duskwuff on Wednesday June 01, 2016 @08:46PM
(#11819550)
To the best of my knowledge, the container features in the vanilla kernel today (cgroups, as used by LXC, docker, etc) originated at Google, where they were used more for resource allocation than for containerization per se. The kernel patches developed by Virtuozzo/Parallels for OpenVZ were never upstreamed, and were considerably different in design from cgroups.
Re:Abusing Privileged and Unprivileged Linux Containers
by cyphar on Thursday June 02, 2016 @07:29AM
(#11821686)
They're talking about namespaces. Cgroups are not an isolation mechanism, and there have been significant rewrites of the core since Google worked on them. Most of the namespace work came from Odin (Parallels) as well as Virtuozzo and others.
You can just skim this paper to see the problems: non-namespaced identifiers leak in procfs, UID "slides" expose containers to each others resource limits, there are non-namespaced non-containerized kernel functions exposed to root inside of containers, and so on.