What is the equivalent to jails in Opensuse?

Hi, im currently installing a server in Opensuse and i was wondering what is the equivalent of FreeBSD jails in OpenSuse?
What are your recomendations to virtualize and separate services?

jails and containers are head2head. Jails/containers are essentially glorified chroots.

The diff lies in the naming mostly, but you have a counterpart on both sides.

Linux uses namespaces,cgroups - FreeBSD jails has head to head equivalents, these are very close.

It should be said that popularity of linux, but also complexity is both good/bad.

Basically if you take away seccomp,mac(selinux,apparmor) then linux is very insecure in sandboxing containers as now its closer to just a chroot. That is why selinux/apparmor is a requirement that shouldn’t be turned off in any production server exposed.

Sandbox escapes are generally a very high value target, but also one with many attack surfaces not immediately obvious. LXC/LXD has less complexity, own network stack but configured correctly both can be secured.

what is the equivalent of FreeBSD jails in OpenSuse?

Linux namespace(s):

https://dev.to/ajinkya_singh_2c02bd40423/understanding-linux-kernel-namespaces-the-magic-behind-containers-919

What are your recomendations to virtualize and separate services?

Hardening systemd services (with linux namespaces and seccomp):
https://forums.opensuse.org/t/measures-to-harden-an-opensuse-install-and-to-run-an-opensuse-system-securely/180953/23

Try bubblewrap:
https://palaimon.io/blog/coding-agents-bubblewrap-deep-dive/

# bwrap --unshare-ipc --unshare-pid --unshare-net --unshare-user --disable-userns --cap-drop ALL --new-session --clearenv --die-with-parent \
   --ro-bind /usr/bin/ /usr/bin --ro-bind /lib64/ /lib64 --ro-bind /usr/lib64/ /usr/lib64 --ro-bind /usr/sbin/ /usr/sbin \
   --proc /proc --dev /dev --remount-ro /dev --remount-ro /proc --remount-ro /dev/random --remount-ro /dev/urandom \
   --tmpfs /tmp --tmpfs /var/tmp --perms 0700 --tmpfs /root --remount-ro / /usr/bin/bash
# lsns --tree
# mount
# ls /proc
# ls /dev
# id
# pscap -a
# export
# ss -lp
# /usr/sbin/ip link show

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.