Skip to content

[release/2.3] Handle []byte envvar value for CRI - #13454

Merged
samuelkarp merged 2 commits into
containerd:release/2.3from
liggitt:binary-env-2.3
Jul 23, 2026
Merged

samuelkarp merged 2 commits into
containerd:release/2.3from
liggitt:binary-env-2.3

Conversation

@liggitt

@liggitt liggitt commented May 20, 2026 •

Copy link
Copy Markdown
Contributor

Part of recovering from a regression in the ability of v0.34.0+ cri-api being able to transmit binary non-utf8 envvar values

xref

cc @mikebrow @samuelkarp

This updates to a cri-api patch release that switched the proto type of the envvar value field from string to bytes, and adds a []byte → go string cast in the spot that handles this CRI field.

Support non-UTF-8 binary environment variable values in CRI

@liggitt

liggitt commented May 20, 2026

Copy link
Copy Markdown
Contributor Author

(the vendor verification task of the "Project Checks" CI is expected to fail since this is monkeying with a vendored cri-api file ... other compile / test checks should succeed)

@liggitt liggitt changed the title WIP: POC: Handle []byte envvar value WIP: POC: [2.3] Handle []byte envvar value May 20, 2026
@liggitt liggitt changed the title WIP: POC: [2.3] Handle []byte envvar value WIP: POC:[2.3] Handle []byte envvar value Jun 12, 2026
@liggitt liggitt changed the title WIP: POC:[2.3] Handle []byte envvar value [2.3] Handle []byte envvar value Jun 12, 2026
@liggitt

liggitt commented Jun 13, 2026

Copy link
Copy Markdown
Contributor Author

windows test looks unhappy but I don't think it's related

@liggitt

liggitt commented Jun 16, 2026

Copy link
Copy Markdown
Contributor Author

not sure how to trigger retest of the windows bits

@samuelkarp

Copy link
Copy Markdown
Member

/ok-to-test
/retest

@samuelkarp

Copy link
Copy Markdown
Member

Note that we typically want to merge the main PR before any cherry-picks: #13453

The cherry-pick here is also missing -x to track the commit it originate from. That'd be helpful to add later.

@liggitt

liggitt commented Jun 16, 2026

Copy link
Copy Markdown
Contributor Author

Note that we typically want to merge the main PR before any cherry-picks: #13453

👍

The cherry-pick here is also missing -x to track the commit it originate from. That'd be helpful to add later.

I'm not sure what you mean... are you looking for something in the commits, or commit messages, or branch?

@samuelkarp

Copy link
Copy Markdown
Member

I'm not sure what you mean... are you looking for something in the commits, or commit messages, or branch?

https://containerd.io/releases/#backporting

git cherry-pick -xs will insert a "(cherry picked from commit $sha)" into the commit message.

@liggitt

liggitt commented Jun 16, 2026

Copy link
Copy Markdown
Contributor Author

thanks, I'll update once the main PR merges

@samuelkarp samuelkarp changed the title [2.3] Handle []byte envvar value [release/2.3] Handle []byte envvar value for CRI Jun 23, 2026
@samuelkarp
samuelkarp marked this pull request as draft June 23, 2026 19:00
@samuelkarp samuelkarp moved this from Needs Triage to Work In Progress in Pull Request Review Jun 23, 2026
@samuelkarp samuelkarp added area/cri Container Runtime Interface (CRI) and removed do-not-merge/work-in-progress labels Jun 23, 2026
liggitt added 2 commits July 23, 2026 10:46
Signed-off-by: Jordan Liggitt <[email protected]>
(cherry picked from commit 78abbfb)
Signed-off-by: Jordan Liggitt <[email protected]>
Signed-off-by: Jordan Liggitt <[email protected]>
(cherry picked from commit b824ddc)
Signed-off-by: Jordan Liggitt <[email protected]>
@liggitt

liggitt commented Jul 23, 2026

Copy link
Copy Markdown
Contributor Author

Updated from #13453 with cherry-pick origin tracking

@liggitt
liggitt marked this pull request as ready for review July 23, 2026 18:48

@mikebrow mikebrow left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@github-project-automation github-project-automation Bot moved this from Work In Progress to Review In Progress in Pull Request Review Jul 23, 2026
@samuelkarp
samuelkarp merged commit 4f66182 into containerd:release/2.3 Jul 23, 2026
50 checks passed
@github-project-automation github-project-automation Bot moved this from Review In Progress to Done in Pull Request Review Jul 23, 2026
social4hyq pushed a commit to social4hyq/homebrew-core that referenced this pull request Sep 20, 2026
containerd 2.3.4

Created-by: HarmonybrewBot
Commit-by: HarmonybrewBot
Merged-by: HarmonybrewBot
Description: Created by `brew bump`

---

Created with `brew bump-formula-pr`.<details>
  <summary>release notes</summary>
  <pre>Welcome to the v2.3.4 release of containerd!

The fourth patch release for containerd 2.3 contains various fixes and updates.

### Highlights

#### Container Runtime Interface (CRI)

* Disable checkpoint restore in CreateContainer by default, requiring the enable_experimental_restore_via_create configuration option to enable ([#13913](containerd/containerd#13913))
* Set default runtimeFeatures.UserNamespacesHostNetwork to true in CRI ([#13914](containerd/containerd#13914))
* Deprecate checkpoint restore in CreateContainer ([#13868](containerd/containerd#13868))
* Support non-UTF-8 binary environment variable values in CRI ([#13454](containerd/containerd#13454))
* Enable OCI runtime feature introspection for non-runc runtimes in CRI ([#13778](containerd/containerd#13778))
* Disable checkpoint restore codepaths when CRIU is not installed and add enable_criu configuration option ([#13734](containerd/containerd#13734))
* Normalize sandbox image references in CRI to resolve images without domain prefixes ([#13759](containerd/containerd#13759))

#### Node Resource Interface (NRI)

* Emit deprecation warnings for plugins using deprecated NRI interfaces ([#13935](containerd/containerd#13935))

#### Runtime

* Enable log scrubbing by default on Windows ([#13904](containerd/containerd#13904))
* Fix memory leak in OOM watcher map when stopping container monitoring ([#13870](containerd/containerd#13870))
* Avoid orphaning shims on transient errors when loading process IDs ([#13857](containerd/containerd#13857))
* Fix corruption of binary protobuf shim start responses caused by premature whitespace trimming ([#13803](containerd/containerd#13803))

#### Snapshotters

* Fix EROFS snapshotter dropping lower layers stacked above merged filesystem metadata ([#13876](containerd/containerd#13876))

#### Breaking

* Disable checkpoint restore in CreateContainer by default, requiring the enable_experimental_restore_via_create configuration option to enable ([#13913](containerd/containerd#13913))

#### Deprecations

* Deprecate checkpoint restore in CreateContainer ([#13868](containerd/containerd#13868))

Please try out the release binaries and report any issues at
https://github.com/containerd/containerd/issues.

### Contributors

* Samuel Karp
* Maksym Pavlenko
* Mike Brown
* Akihiro Suda
* Derek McGowan
* Jordan Liggitt
* Paweł Gronowski
* Amir Alavi
* Andrew Halaney
* Bing Hongtao
* Chris Henzie
* Harshal Patel
* Krisztian Litkey
* Phil Estes
* Wei Fu
* ningmingxiao

### Changes
<details><summary>35 commits</summary>
<p>

  * [`c1f5360ef`](containerd/containerd@c1f5360) Prepare release notes for v2.3.4
* cri: disable restore in CreateContainer by default ([#13913](containerd/containerd#13913))
  * [`928c03c68`](containerd/containerd@928c03c) cri: disable restore in CreateContainer by default
* nri,deprecation: record and emit warnings for NRI deprecations. ([#13935](containerd/containerd#13935))
  * [`5966e2edb`](containerd/containerd@5966e2e) nri,deprecation: emit warnings for old NRI plugins.
* Set the default of runtimeFeatures.UserNamespacesHostNetwork to true ([#13914](containerd/containerd#13914))
  * [`ab52c58f1`](containerd/containerd@ab52c58) Set the default of runtimeFeatures.UserNamespacesHostNetwork to true
* Use ScrubLogs by default on Windows ([#13904](containerd/containerd#13904))
  * [`0c255158a`](containerd/containerd@0c25515) ctr: add --scrub-logs flag for Windows
  * [`1c2b13dc9`](containerd/containerd@1c2b13d) cri/config: use ScrubLogs by default on Windows
* snapshots/erofs: keep lowers stacked above a merged fsmeta ([#13876](containerd/containerd#13876))
  * [`0c511e068`](containerd/containerd@0c511e0) snapshots/erofs: keep lowers stacked above a merged fsmeta
* cri: deprecate restore in CreateContainer ([#13868](containerd/containerd#13868))
  * [`dc98141df`](containerd/containerd@dc98141) cri: deprecate restore in CreateContainer
* internal/oom: Fix memory leak by removing watcher from map on Stop ([#13870](containerd/containerd#13870))
  * [`537d82d54`](containerd/containerd@537d82d) internal/oom: Fix memory leak by removing watcher from map on Stop
* shim_load: Consider shim leaked only if we can't find pids ([#13857](containerd/containerd#13857))
  * [`decf97a9c`](containerd/containerd@decf97a) shim_load: Consider shim leaked only if we can't find pids
* core/runtime/v2: Drop checkpointctl module dependency ([#13840](containerd/containerd#13840))
  * [`796f07dc8`](containerd/containerd@796f07d) core/runtime/v2: Drop checkpointctl module dependency
* Handle []byte envvar value for CRI ([#13454](containerd/containerd#13454))
  * [`751fddddb`](containerd/containerd@751fddd) Handle []byte envvar value
  * [`0bce9060e`](containerd/containerd@0bce906) update to v0.36.x kubernetes dependencies
* fix(cri): introspect OCI runtime features for non-runc runtimes ([#13778](containerd/containerd#13778))
  * [`61a8f6f45`](containerd/containerd@61a8f6f) fix(cri): introspect OCI runtime features for non-runc runtimes
* core/runtime/v2: Preserve protobuf shim response bytes ([#13803](containerd/containerd#13803))
  * [`1d28017be`](containerd/containerd@1d28017) core/runtime/v2: Preserve protobuf shim response bytes
* Disable checkpoint restore codepath when CRIU is not installed ([#13734](containerd/containerd#13734))
  * [`374091d67`](containerd/containerd@374091d) github/workflows: install criu in node-e2e
  * [`db03e3968`](containerd/containerd@db03e39) cri: add enable_criu configuration option
  * [`dacd4c7d0`](containerd/containerd@dacd4c7) cri: validate CRIU availability and version early
* ci: bound Go fuzzing by execution count ([#13785](containerd/containerd#13785))
  * [`890a9c86c`](containerd/containerd@890a9c8) ci: bound Go fuzzing by execution count
* cri: auto-add prefix for pause image ([#13759](containerd/containerd#13759))
  * [`0b2f1d078`](containerd/containerd@0b2f1d0) cri: auto-add prefix for pause image
</p>
</details>

### Dependency Changes

* **k8s.io/api**                            v0.36.0 -> v0.36.3
* **k8s.io/apimachinery**                   v0.36.0 -> v0.36.3
* **k8s.io/client-go**                      v0.36.0 -> v0.36.3
* **k8s.io/component-base**                 v0.36.0 -> v0.36.3
* **k8s.io/cri-api**                        v0.36.0 -> v0.36.3
* **k8s.io/cri-client**                     v0.36.0 -> v0.36.3
* **k8s.io/cri-streaming**                  v0.36.0 -> v0.36.3
* **sigs.k8s.io/structured-merge-diff/v6**  v6.3.2 -> v6.3.3

Previous release can be found at [v2.3.3](https://github.com/containerd/containerd/releases/tag/v2.3.3)
### Which file should I download?
* `containerd-<VERSION>-<OS>-<ARCH>.tar.gz`:         ✅Recommended. Dynamically linked with glibc 2.35 (Ubuntu 22.04).
* `containerd-static-<VERSION>-<OS>-<ARCH>.tar.gz`:  Statically linked. Expected to be used on Linux distributions that do not use glibc >= 2.35. Not position-independent.

In addition to containerd, typically you will have to install [runc](https://github.com/opencontainers/runc/releases)
and [CNI plugins](https://github.com/containernetworking/plugins/releases) from their official sites too.

See also the [Getting Started](https://github.com/containerd/containerd/blob/main/docs/getting-started.md) documentation.
</pre>
  <p>View the full release notes at <a href="https://github.com/containerd/containerd/releases/tag/v2.3.4">https://github.com/containerd/containerd/releases/tag/v2.3.4</a>.</p>
</details>
<hr>

See merge request: Harmonybrew/homebrew-core!16411
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants