Skip to content

Commit 75c78eb

Browse files
Merge pull request #26990 from mheon/final_backports_561
Final backports for v5.6.1
2 parents 2a1a4df + 9812c1f commit 75c78eb

File tree

6 files changed

+37
-7
lines changed

6 files changed

+37
-7
lines changed

.cirrus.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ env:
3131
DEBIAN_NAME: "debian-13"
3232

3333
# Image identifiers
34-
IMAGE_SUFFIX: "c20250627t155202z-f42f41d13"
34+
IMAGE_SUFFIX: "c20250812t173301z-f42f41d13"
3535

3636
# EC2 images
3737
FEDORA_AMI: "fedora-aws-${IMAGE_SUFFIX}"

RELEASE_NOTES.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,21 @@
11
# Release Notes
22

33
## 5.6.1
4+
### Security
5+
- This release addresses CVE-2025-9566, where Kubernetes YAML run by `podman play kube` containing `ConfigMap` and `Secret` volumes can use crafted symlinks to overwrite content on the host.
6+
47
### Bugfixes
58
- Fixed a bug where network creation and removal events were displayed incorrectly when the `journald` events driver was in use.
69
- Fixed a bug where the `--security-opt seccomp=unconfined` option was broken on Windows ([#26855](https://github.com/containers/podman/issues/26855)).
710
- Fixed a bug where containers created with a name longer than 64 characters, no explicit hostname, the the `container_name_as_hostname` option in `containers.conf` set to `true` would fail to start.
811
- Fixed a bug where Podman would fail to start containers when runc 1.3.0 or later was used as the OCI runtime ([#26938](https://github.com/containers/podman/issues/26938)).
912

13+
### Misc
14+
- Adjusted the systemd-tmpfiles script to recursively remove temporary files directories placed in `/tmp`, ensuring proper operation of Podman after a reboot if `/tmp` is not a tmpfs.
15+
- Updated Buildah to v1.41.4
16+
- Updated the containers/storage to v1.59.1
17+
- Updated the containers/common library to v0.64.2
18+
1019
## 5.6.0
1120
### Features
1221
- A new set of commands for managing Quadlets has been added as `podman quadlet install` (install a new Quadlet for the current user), `podman quadlet list` (list installed Quadlets), `podman quadlet print` (print the contents of a Quadlet file), and `podman quadlet rm` (remove a Quadlet). These commands are presently not available with the remote Podman client - we expect support for this to arrive in a future release.

contrib/tmpfile/podman.conf

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,16 @@
11
# /tmp/podman-run-* directory can contain content for Podman containers that have run
2-
# for many days. This following line prevents systemd from removing this content.
2+
# for many days. The following lines prevents systemd from removing this content.
3+
# At the same time, these directories must also be cleaned on reboot.
4+
# Thus, each path has two lines: x to not periodically clean, R! to recursively
5+
# remove on reboot.
36
x /tmp/podman-run-*
7+
R! /tmp/podman-run-*
48
x /tmp/storage-run-*
9+
R! /tmp/storage-run-*
510
x /tmp/containers-user-*
11+
R! /tmp/containers-user-*
612
x /tmp/run-*/libpod
13+
R! /tmp/run-*/libpod
714
D! /var/lib/containers/storage/tmp 0700 root root
815
D! /run/podman 0700 root root
916
D! /var/lib/cni/networks

libpod/container_exec.go

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -859,6 +859,19 @@ func (c *Container) healthCheckExec(config *ExecConfig, timeout time.Duration, s
859859
return -1, err
860860
}
861861
defer func() {
862+
// cleanupExecBundle MUST be called with the parent container locked.
863+
if !unlock && !c.batched {
864+
c.lock.Lock()
865+
unlock = true
866+
867+
if err := c.syncContainer(); err != nil {
868+
logrus.Errorf("Error syncing container %s state: %v", c.ID(), err)
869+
// Normally we'd want to continue here, get rid of the exec directory.
870+
// But the risk of proceeding into a function that can mutate state with a bad state is high.
871+
// Lesser of two evils is to bail and leak a directory.
872+
return
873+
}
874+
}
862875
if err := c.cleanupExecBundle(session.ID()); err != nil {
863876
logrus.Errorf("Container %s light exec session cleanup error: %v", c.ID(), err)
864877
}
@@ -971,7 +984,8 @@ func (c *Container) exec(config *ExecConfig, streams *define.AttachStreams, resi
971984
return session.ExitCode, nil
972985
}
973986

974-
// cleanupExecBundle cleanups an exec session after its done
987+
// cleanupExecBundle cleans up an exec session after completion.
988+
// MUST BE CALLED with container `c` locked.
975989
// Please be careful when using this function since it might temporarily unlock
976990
// the container when os.RemoveAll($bundlePath) fails with ENOTEMPTY or EBUSY
977991
// errors.

test/apiv2/20-containers.at

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -762,14 +762,13 @@ if root && test -e /dev/nullb0; then
762762
t POST libpod/containers/updateCtr/update ${TMPD}/update.json 201
763763

764764
cgroupPath=/sys/fs/cgroup/cpu.weight
765-
# 002 is the byte length
766-
cpu_weight_expect=$'\001\0025'
767765

768766
# Verify CPU weight
769767
echo '{ "AttachStdout":true,"Cmd":["cat", "'$cgroupPath'"]}' >${TMPD}/exec.json
770768
t POST containers/updateCtr/exec ${TMPD}/exec.json 201 .Id~[0-9a-f]\\{64\\}
771769
eid=$(jq -r '.Id' <<<"$output")
772-
t POST exec/$eid/start 200 $cpu_weight_expect
770+
t POST exec/$eid/start 200
771+
like "$(<$WORKDIR/curl.result.out)" $'^\x01.\(20\|5\)$' "cpu.weight is 5 or 20"
773772

774773
BlkioDeviceReadBps_expected='[
775774
{

test/e2e/update_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,8 @@ var _ = Describe("Podman update", func() {
141141
podmanTest.CheckFileInContainerSubstring(ctrID, "/sys/fs/cgroup/memory.swap.max", "1073741824")
142142

143143
// checking cpu-shares
144-
podmanTest.CheckFileInContainerSubstring(ctrID, "/sys/fs/cgroup/cpu.weight", "5")
144+
exec := podmanTest.PodmanExitCleanly("exec", ctrID, "cat", "/sys/fs/cgroup/cpu.weight")
145+
Expect(exec.OutputToString()).To(Or(ContainSubstring("5"), ContainSubstring("20")))
145146

146147
// checking pids-limit
147148
podmanTest.CheckFileInContainerSubstring(ctrID, "/sys/fs/cgroup/pids.max", "123")

0 commit comments

Comments
 (0)