17584 Commits
Author SHA1 Message Date
Maksym Pavlenko f09d4e24d9 Merge pull request #14378 from mike-sul/fix/erofs-trim-fsync-comments
erofs: trim fsync_on_commit comments
2026-10-15 19:35:22 +00:00
Samuel Karp 96d26d2476 docs: fix broken documentation links
Exclude the core/runtime/v2/README.md symlink in the links workflow so
lychee does not fail resolving relative links from the symlink path.
docs/runtime-v2.md is already validated directly.

Update broken, moved, and rate-limited links across markdown documents:
- Replace moved Kubernetes cgroup driver and GCP registry docs.
- Replace retired RHEL 6 devmapper docs with kernel.org reference.
- Point NSSM, CRIU, and Ansible references to GitHub repositories.
- Fix relative paths in remote-snapshotter.md and root-relative paths.

Assisted-by: Antigravity
Signed-off-by: Samuel Karp <samuelkarp@google.com>
2026-10-15 11:53:28 -07:00
Maksym Pavlenko 3bd74e226d Merge pull request #14321 from samuelkarp/disable-tmpfiles-clean-timer
script/vm: mask systemd-tmpfiles-clean.timer
2026-10-15 17:51:28 +00:00
Sebastiaan van Stijn 2f0dd596a9 core/content: Copy: restore support for "-1" as unknown size
Restore support for -1 as an unknown-size sentinel for backward
compatibility. Normalize it to 0, the documented value for unknown
sizes in the Writer interface.

Other negative sizes remain invalid, and known-size copies retain
their existing bounds checks.

Updates 91f62bdd77

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-15 13:06:31 +02:00
Sebastiaan van Stijn 4a21f73e84 ctr: push-object: check for negative content size
The size comes from the local content store, but validate it as a
defense-in-depth before passing it to content.Copy.

Updates 91f62bdd77

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-15 13:06:30 +02:00
Sebastiaan van Stijn b13bd74934 remotes: PushHandler: reject negative descriptor sizes
Push depended on content.Copy to invalidate negative sizes. Check for invalid
descriptor sizes in push itself, without relying on the validation in Copy.

Updates 91f62bdd77

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-15 13:06:30 +02:00
Sebastiaan van Stijn 6fbd6d6fa8 core/content: WriteBlob: reject negative descriptor sizes
WriteBlob expects the size of the content to be known in advance, but
currently relies on Copy to validate the descriptor size.

Check for invalid descriptor sizes in WriteBlob itself, without relying
on the validation in Copy.

Updates 91f62bdd77

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-15 13:06:30 +02:00
Sebastiaan van Stijn 05eb29fbe5 content/testsuite: specify blob sizes in WriteBlob tests
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-15 13:06:26 +02:00
Mykhaylo Sul 8f3aafa298 erofs: trim fsync_on_commit comments
Shorten the fsync_on_commit comments as asked in review on #14334.

Signed-off-by: Mykhaylo Sul <mykhaylo.sul@oss.qualcomm.com>
2026-10-15 12:11:10 +02:00
Samuel Karp f0e5cfae13 workflows: pin runner to ubuntu-24.04
Pin workflow runners to ubuntu-24.04 to avoid deprecation warnings and
breaking changes when ubuntu-latest migrates to Ubuntu 26.

Assisted-by: Antigravity
Signed-off-by: Samuel Karp <samuelkarp@google.com>
2026-10-14 15:50:33 -07:00
Samuel Karp 41d81d0828 ci: retry limactl start on VM boot failure
limactl start creates the default instance directory before downloading
the guest image. Delete the stopped instance before retrying so the
second limactl start invocation does not fail on an existing instance.

Assisted-by: Antigravity
Signed-off-by: Samuel Karp <samuelkarp@google.com>
2026-10-14 15:10:11 -07:00
Fu Wei 02771a9d6d Merge pull request #14334 from mike-sul/fix/erofs-commit-durability
erofs: sync a layer before committing its snapshot
2026-10-14 14:59:07 +00:00
Mykhaylo Sul d0ed8ab2a2 erofs: add fsync_on_commit to sync a layer before its commit
Commit records a snapshot in the metadata store, which syncs its own
file, while layer.erofs and the snapshot directory may still be in the
page cache. A power loss shortly after a pull can then leave a committed
snapshot whose blob is corrupt or whose directory is missing. A later
pull does nothing because the chain ID exists, and running the image
fails to mount the layer.

With fsync_on_commit = true, Commit fsyncs everything in the snapshot
directory, the directory itself and snapshots/ before the snapshot is
recorded. Blobs served from a layer content cache are not synced. The
option is off by default and lives in the snapshotter because the
differ's SyncFs does not reach Commit, where the walking differ's blob
is created.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Mykhaylo Sul <mykhaylo.sul@oss.qualcomm.com>
2026-10-14 16:12:36 +02:00
Tonis Tiigi 9258a49321 remotes/docker: close request body when authorization fails
The pusher creates the upload request body as an io.Pipe. request.do
attaches the pipe reader to the request before calling Authorize. If
Authorize fails, do returns before client.Do, so the reader is never
handed to the HTTP client, which would have closed it, and nothing else
closes it.

A concurrent pushWriter.Write then blocks forever in pipe.Write. It only
reads the error reported by the request goroutine after the pipe is
closed, and it takes no context, so cancelling the caller does not help.
Callers such as content.Copy never return, and anything they hold, for
example a concurrency slot, is never released.

Close the body when authorization fails so the blocked Write returns the
authorization error. Transient errors keep going through the existing
retry and content.ErrReset handling.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-10-13 23:50:15 -07:00
Chengyu Zhu a8c6a88693 cri: honor runtime handler platform during image pull
Use the resolved platform for pulling and image-store updates. Fall back to
local pull when transfer cannot unpack the requested platform and snapshotter.

Signed-off-by: Chengyu Zhu <hudson@cyzhu.com>
2026-10-14 09:38:52 +08:00
15849062c9 sys, dialer: support AF_UNIX sockets on Windows
Windows could only listen on and dial named pipes. Also accept AF_UNIX
sockets (Windows 10 1803+, Server 2019+) as unix://<path>, unix:<path>
or a bare path, next to \\.\pipe\<name>, //./pipe/<name> and npipe://.
A scheme is authoritative and named pipes stay the default.

The address is parsed in internal/localaddr, shared by the listener,
the dialer and the debug server's local/TCP check. os.Chmod and
os.Chown do nothing on Windows, so the parent directory is created with
MkdirAllWithACL and the socket gets a protected DACL for Builtin
Administrators and Local System.

Windows has the 108 byte sun_path limit of Linux, but there is hope,
see https://lwn.net/Articles/987098/

Continues https://github.com/containerd/containerd/pull/12921

Co-authored-by: David Scott <dave@recoil.org>
Co-authored-by: Derek McGowan <derek@mcg.dev>
Assisted-by: OpenCode (claude-sonnet-5-5)
Signed-off-by: Eric Curtin <eric.curtin@docker.com>
2026-10-14 01:03:47 +01:00
Fu Wei 2467f228a0 Merge pull request #14345 from thaJeztah/bump_go
Update to go1.27.2 (security)
2026-10-13 20:29:15 +00:00
Sebastiaan van Stijn 819723a239 vendor: golang.org/x/net v0.60.0
includes various security fixes also fixed in go1.27.2/go1.26.9

full diff: https://github.com/golang/net/compare/v0.58.0...v0.60.0

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-13 21:52:58 +02:00
Sebastiaan van Stijn e4ad708faf Update to go1.27.2
These releases include 15 security fixes following the security policy:

- net/http: HTTP/2 server crash due to HPACK encoder race

  HTTP/2 servers could end up crashing due to inadvertently
  modifying its HPACK encoder concurrently. This happens because the
  server modifies the HPACK encoder from two goroutines without
  synchronization: one uses the encoder to encode a HEADERS frame as part
  of a response sent to a client and the other modifies the encoder's
  table size when handling a SETTINGS frame containing
  SETTINGS_HEADER_TABLE_SIZE that a client sends. A malicious client can
  repeatedly send a request while changing the header table size to crash
  the server.

  Fix this issue by not applying SETTINGS_HEADER_TABLE_SIZE immediately.
  Instead, buffer any SETTINGS_HEADER_TABLE_SIZE received, and only apply
  the new value prior to the next time the server writes a frame.

  Thanks to RyotaK (https://ryotak.net) of GMO Flatt Security Inc. for reporting this issue.

  This is CVE-2026-97032 and Go issue https://go.dev/issue/81867.

- net/http: HTTP/2 server memory exhaustion due to Trailer headers

  When "Trailer" headers are sent by a client, the HTTP server internally
  uses the header values to populate the Request.Trailer map passed to the
  server handler. Because Request.Trailer is a map, each entry incurs
  memory overhead. For HTTP/2 servers, a malicious client can exploit this
  by sending a "Trailer" header that declares a large number of fields,
  causing the server to allocate a disproportionate amount of memory while
  bypassing Server.MaxHeaderValueCount and Server.MaxHeaderBytes limits.
  This exploit is not applicable for HTTP/1 servers, which do not support
  multiplexing a large number of requests over one TCP connection, and
  whose Server.MaxHeaderBytes are calculated differently.

  Server.MaxHeaderValueCount and Server.MaxHeaderBytes limits are now
  applied towards the trailer fields declared in "Trailer" headers.

  Thanks to RyotaK (https://ryotak.net) of GMO Flatt Security Inc. for reporting this issue.

  This is CVE-2026-78659 and Go issue https://go.dev/issue/81857.

- crypto/tls: reject malformed ECH outer extension references

  Multiple ECH outer extension references are not
  permitted under RFC 9849; previously, a client
  could send a well-crafted packet that could
  trigger memory exhaustion in the server process
  by specifying multiple references.

  We now reject these as malformed and curb the
  memory amplification vector as a result.

  This is CVE-2026-97031 and Go issue https://go.dev/issue/81855.

- cmd/go: checksum bypass for golang.org/fips140

  Previously, a user operating inside of a malicious
  Go project that defines a bogus golang.org/fips140
  and operates a malicious GOMODPROXY the user chooses
  to connect to can serve an arbitrary module in its
  place.

  We now unpack the trusted ziphash for the bundled
  golang.org/fips140 module and construct its entry
  in the GOMODCACHE such that it can be verified by
  the toolchain.

  This is CVE-2026-94444 and Go issue https://go.dev/issue/81833.

- cmd/go: checksum database bypass for golang.org/toolchain

  Previously, a user operating inside of a malicious
  Go project that defines a bogus golang.org/toolchain
  go.sum entry and operates a malicious GOMODPROXY the
  user chooses to use can bypass the intended checksum.

  We now ensure that golang.org/toolchain always goes
  to the network for the canonical checksum.

  This is CVE-2026-94447 and Go issue https://go.dev/issue/81834.

- html/template: reset context tracking on consecutive template expressions

  When a JavaScript template literal contains
  consecutive expressions, the context tracking
  state was not properly reset upon entering a
  new expression.

  We now ensure that template-literal expression
  entries correctly reset context variables so all
  subsequent regular expression literals are
  accurately recognized and escaped.

  This is CVE-2026-94448 and Go issue https://go.dev/issue/81821.

- html/template: recognize yield as regexp preceder keyword

  A trusted template author may have previously
  written a valid template wherein the use of
  the yield keyword would not be correctly
  escaped.

  We now ensure that valid keyword uses are
  escaped and non-keyword uses are not escaped.

  This is CVE-2026-97030 and Go issue https://go.dev/issue/81823.

- net/textproto, mime/multipart: memory limit bypass when parsing MIME headers

  Parsing a multipart form could bypass memory limits and read an
  arbitrarily long line into memory when the remaining limit at the
  start of a part was less than 400 bytes.

  Multipart form memory limits are now properly enforced in this situation.

  Thanks to Jakub Ciolek (https://ciolek.dev) for reporting this issue.

  This is CVE-2026-94440 and Go issue https://go.dev/issue/81741.

- net/http: HTTP/1 client connection desynchronization after CONNECT rejection

  When http.Transport sends an HTTP/1 CONNECT request with a non-empty
  Request.Body, it writes the body directly to the connection without
  framing after the request headers. If the server rejects the CONNECT
  request with a non-2xx keep-alive response, Transport returns the
  connection to the idle pool. Because CONNECT requests do not have a
  request body, the server may interpret the trailing body bytes as a
  subsequent pipelined HTTP/1.1 request on the connection, leaving the
  pooled connection desynchronized and causing the next caller that reuses
  it to read the response to the injected request. In reverse proxies
  (including httputil.ReverseProxy) that forward CONNECT requests through
  a shared Transport, this can lead to cross-user response poisoning.

  The HTTP/1 transport now closes a connection after sending a CONNECT
  request, regardless of the response status.

  In addition, ReverseProxy now rejects incoming CONNECT requests
  with a 405 Method Not Allowed response. ReverseProxy has never handled
  CONNECT requests in a useful fashion (it does not convert the
  connection into a bidirectional tunnel), so we do not expect this
  change to negatively affect any current users.

  Thanks to Xclow3n (Rajat Raghav) for reporting this issue.

  This is CVE-2026-56866 and Go issue https://go.dev/issue/81740.

- net/http: HTTP/1 server connection desynchronization after 2xx CONNECT response

  When an HTTP server handler sent a 2xx response to an HTTP/1 CONNECT request
  and returned without hijacking the connection, the server improperly continued
  to read and serve requests from the connection. Since a 2xx response to an
  HTTP/1 CONNECT converts the connection into a tunnel, the server should not
  treat the connection as continuing to contain HTTP.

  The impact of this misbehavior is mostly limited to potential request smuggling,
  where an intermediate proxy considers the data on the connection to be tunneled
  and the server considers it to be HTTP.

  The HTTP/1 server now always closes a connection after responding to a CONNECT
  request, regardless of the response status.

  Thanks to Jakub Ciolek (https://ciolek.dev) for reporting this issue.

  This is CVE-2026-94439 and Go issue https://go.dev/issue/81744.

- net/http: excessive CPU consumption from repeated initial window changes

  A malicious HTTP/2 peer could cause excessive CPU consumption in the
  client or server by opening a large number of streams and then sending
  many small SETTINGS frames containing SETTINGS_INITIAL_WINDOW_SIZE values.

  The HTTP/2 client and server now efficiently handle changes to the
  initial window size (O(1) rather than O(number of streams)).

  Thanks to Jakub Ciolek (https://ciolek.dev) for reporting this issue.

  This is CVE-2026-78669 and Go issue https://go.dev/issue/81742.

- net/http: HTTP/2 transport accepts malformed framing-related headers

  Historically, we have been rather lax about malformed framing-related
  headers in our HTTP/2 implementation, as they cannot interfere with
  HTTP/2 framing. However, this makes it possible for our HTTP/2
  implementation to forward responses containing such headers to an HTTP/1
  client when acting as a reverse proxy. If the HTTP/1 client also does
  not behave strictly enough, this can result in response smuggling.

  We now delete malformed framing-related headers when received by our
  HTTP/2 transport, so they will not be forwarded to a potentially
  vulnerable HTTP/1 client.

  Thanks to TJ Barton for reporting this issue.

  This is CVE-2026-78660 and Go issue https://go.dev/issue/81115.

- os: Root.Mkdir(All) can follow junctions out of the root on Windows

  On Windows, when the target of Root.Mkdir or Root.MkdirAll was a junction
  pointing to an empty location, the operation would create a directory at
  the junction target even when that target was located outside the root.
  This only applies to operations where the last path component is a
  junction (path/to/junction, but not path/junction/target).

  Root.Mkdir and Root.MkdirAll now correctly avoid resolving junctions.

  Thanks to Daniele Ballarini for reporting this issue.

  This is CVE-2026-56857 and Go issue https://go.dev/issue/81739.

- net/http: lack of limit on size of parsed Range headers

  When parsing a Range header containing a large number of small ranges,
  FileServer(FS), ServeContent, and ServeFile(FS) could consume an excessive
  amount of CPU.

  These functions now ignore Range headers containing more than 200 ranges.

  The limit is controlled by the new httpservecontentmaxranges=
  GODEBUG setting. Setting GODEBUG=httpservecontentmaxranges=0
  disables the limit.

  Thanks to Jakub Ciolek (https://ciolek.dev) for reporting this issue.

  This is CVE-2026-78667 and Go issue https://go.dev/issue/81858.

- net/http: double flow control refund on HTTP/2 server streams

  The HTTP/2 server could refund connection-level flow control twice for the same data:
  Once when a client resets a stream (refunding data for any sent-but-unread portion
  of the stream), and again when a request handler reads the buffered data.
  A malicious client could exploit this to bypass the configured connection-level
  flow control limit (MaxReceiveBufferPerConnection). Total buffered data is still
  limited by the concurrent stream limit and stream-level flow control.

  The HTTP/2 server now waits to refund connection-level flow control for reset
  streams until after the request handler is complete.

  Thanks to Ali Sherif (https://www.linkedin.com/in/ali-sherif-13812b276/) for reporting this issue.

  This is CVE-2026-78663 and Go issue https://go.dev/issue/81743.

release notes: https://go.dev/doc/devel/release#go1.27.2

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-13 21:36:18 +02:00
Samuel Karp 2b46e32d7c Merge commit from fork 2026-10-13 11:44:56 -07:00
Samuel Karp 93ba9dece9 Merge commit from fork 2026-10-13 11:44:42 -07:00
Samuel Karp 22aa0aaf08 Merge commit from fork 2026-10-13 11:44:24 -07:00
Samuel Karp 034a51e040 Merge pull request #14346 from thaJeztah/bump_golangci
ci: update to golangci-lint v2.14.0 (go1.27.2 compatibility)
2026-10-13 17:29:36 +00:00
Sebastiaan van Stijn 7328101023 ci: update to golangci-lint v2.14.0 (go1.27.2 compatibility)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-13 16:11:55 +02:00
Chengyu Zhu d1531a1adf cri: resolve runtime handlers for image pulls
Resolve explicit, default, and annotation-based handlers to their configured
platform and snapshotter. Reject unknown handlers and preserve backend platform
defaults when no platform is configured.

Signed-off-by: Chengyu Zhu <hudson@cyzhu.com>
2026-10-13 21:36:21 +08:00
Samuel Karp 6565bbff7a remotes/docker: bound parallel fetch readers
Stream chunks through a chunkReader backed by a channel of capacity
parallelism so at most parallelism pipes are allocated at any time.

Assisted-by: Antigravity
Signed-off-by: Samuel Karp <samuelkarp@google.com>
2026-10-12 23:27:18 -07:00
Akihiro Suda 92f321c8da Merge pull request #14325 from containerd/dependabot/github_actions/containerd/project-checks-1.2.3
build(deps): bump containerd/project-checks from 1.2.2 to 1.2.3
2026-10-13 02:49:31 +00:00
Samuel Karp 8c451c9ce5 Merge pull request #14311 from mxpv/fetcher
remotes/docker: throttle worker chunk buffers
2026-10-13 00:29:47 +00:00
Maksym Pavlenko 0a74f56c12 Merge pull request #14324 from containerd/dependabot/go_modules/golang-x-34f4b4c4f3
build(deps): bump golang.org/x/sync from 0.23.0 to 0.24.0 in the golang-x group
2026-10-11 20:15:46 +00:00
Akihiro Suda b05f02e2a6 Merge pull request #14323 from samuelkarp/2.5-planning
releases: add 2.5 planned date
2026-10-10 18:57:22 +00:00
Sebastiaan van Stijn b9ed50f4ea vendor: github.com/Microsoft/go-winio v0.6.3
full diff: https://github.com/microsoft/go-winio/compare/ad3df93bed29...v0.6.3

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-10 15:20:59 +02:00
dependabot[bot] 3591d39ca9 build(deps): bump containerd/project-checks from 1.2.2 to 1.2.3
Bumps [containerd/project-checks](https://github.com/containerd/project-checks) from 1.2.2 to 1.2.3.
- [Release notes](https://github.com/containerd/project-checks/releases)
- [Commits](https://github.com/containerd/project-checks/compare/d7751f3c375b8fe4a84c02a068184ee4c1f59bc4...9d887fad80ae4e40d6f10a68529082e7fc06a9af)

---
updated-dependencies:
- dependency-name: containerd/project-checks
  dependency-version: 1.2.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-10-09 23:58:12 +00:00
dependabot[bot] 97bc5f4235 build(deps): bump golang.org/x/sync
Bumps the golang-x group with 1 update: [golang.org/x/sync](https://github.com/golang/sync).


Updates `golang.org/x/sync` from 0.23.0 to 0.24.0
- [Commits](https://github.com/golang/sync/compare/v0.23.0...v0.24.0)

---
updated-dependencies:
- dependency-name: golang.org/x/sync
  dependency-version: 0.24.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: golang-x
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-10-09 23:57:33 +00:00
Samuel Karp eb0413e046 releases: add 2.5 planned date
Signed-off-by: Samuel Karp <samuelkarp@google.com>
2026-10-09 15:22:53 -07:00
Samuel Karp 91ca8d3ab4 script/vm: mask systemd-tmpfiles-clean.timer
systemd-tmpfiles-clean.timer runs 15 minutes after boot and removes
empty directories under /tmp with mtimes older than 10 days. Some
integration tests place containerd's root in t.TempDir() and unpack
image layers with older directory timestamps under /tmp. If the timer
fires during extraction, systemd-tmpfiles removes newly created empty
directories before the final directory timestamp pass.

Assisted-by: Antigravity
Signed-off-by: Samuel Karp <samuelkarp@google.com>
2026-10-09 13:49:41 -07:00
Samuel Karp 91f62bdd77 content, remotes: bound reads to expected size
Reject negative sizes in content.Copy, remotes.Fetch,
dockerFetcher.Fetch, and newHTTPReadSeeker.

Bound reads in content.Copy and httpReadSeeker.Read to the remaining
expected size from the current offset, returning
errdefs.ErrFailedPrecondition if the source yields extra bytes.

Assisted-by: Antigravity
Signed-off-by: Samuel Karp <samuelkarp@google.com>
2026-10-08 16:55:37 -07:00
Jacob Gabrielson 0fa68e85e5 runc-shim: release terminal I/O on delete
A terminal exec or init process has no processIO. The shim keeps a writer
on the stdin FIFO (openStdin) so the console's stdin copier never sees a
premature EOF, and keeps the console master in `console`. delete closed
the closers only under `if io != nil`, which is never true on the
terminal path, and never closed the console. When a client exits without
calling CloseIO, the stdin copier therefore stays blocked on the FIFO and
the FIFO handles, the console master and the goroutine stay alive until a
later garbage collection finalizes the dropped process object, and for as
long as the client holds its own writer on the FIFO, past that too.

Release the I/O on every path and through one owner. delete shuts the
console down, drains, then closes closers, console and io regardless of
io; a process deleted from the created state never ran setExited, so this
is its only shutdown. CopyConsole returns a console that owns its
teardown: shutdown and deregistration from the epoller happen once, while
the fd is still open, and Close then closes the master, wakes a writer
parked on it, and closes the stdin FIFO reader, which ends a copier
blocked reading stdin. The copier, the setup-error path, ShutdownConsole
and both deletes go through it, so a bare Close can no longer leave a
copier asleep, and a late ShutdownConsole is a no-op instead of a
deregistration by a fd number that a newer console may own. CopyConsole
also closes the received master when registering it fails and the stdout
FIFO writer when opening its reader fails.

Six regression tests cover the delete ordering, the setup-error paths,
the copier wake-up and the fd reuse; each fails before its part of this
change.

Assisted-by: Claude Code
Signed-off-by: Jacob Gabrielson <jacob.gabrielson@docker.com>
2026-10-08 16:13:39 +00:00
Maksym Pavlenko 45bfbac3ef remotes/docker: limit chunk buffers per layer
With max_concurrent_downloads and concurrent_layer_fetch_buffer set,
containerd can use far more memory than intended. The download limiter
bounds how many requests run at once. A downloaded chunk stays in
memory until the reader consumes it. When the registry is faster than
the content store write, chunks accumulate up to the size of the layer.

Add a per-layer sliding window of max_workers chunks. Download a new
chunk only after the reader has consumed the oldest chunk in the
window. A layer then holds at most chunk_size * max_workers of chunk
buffers. When the fetch is cancelled, close the writers of chunks that
never reached a worker, as a reader would otherwise block on them
forever. Pooled buffers and other overhead add to total memory use.

Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2026-10-07 20:16:05 -07:00
Fu Wei 3ea5bdbfbd Merge pull request #14255 from ChengyuZhu6/runtimeclass
cri: reject unknown runtime handler in PullImage
2026-10-07 14:18:08 +00:00
Chengyu Zhu 24d6742390 cri: reject unknown runtime handlers and unify runtime updates
CRI requires PullImage to reject an unknown runtime handler. Validate it
against the handlers configured in the CRI runtime service; an empty handler
is unchanged.

Part of #14252

Signed-off-by: Chengyu Zhu <hudson@cyzhu.com>
2026-10-07 17:36:00 +08:00
Samuel Karp e851c87063 Merge pull request #14293 from fuweid/no-follow-on-log
cri: should not follow log file
2026-10-06 18:22:28 +00:00
Wei Fu 4b0a074f53 cri: should not follow log file
Test it in local kubernetes cluster and it passes.

```yaml
apiVersion: v1
kind: Pod
metadata:
  name: reopen-log-test
  labels:
    app: reopen-log-test
spec:
  restartPolicy: Never
  terminationGracePeriodSeconds: 0
  containers:
    - name: logger
      image: busybox:1.36
      imagePullPolicy: IfNotPresent
      command:
        - /bin/sh
        - -c
        - |
          while true; do
            dd if=/dev/zero bs=1024 count=1024 2>/dev/null | tr '\000' x
            printf '\n'
            sleep 0.5
          done
```

Signed-off-by: Wei Fu <fuweid89@gmail.com>
2026-10-06 10:02:04 -04:00
Samuel Karp ebefff91ad Merge pull request #14284 from containerd/dependabot/go_modules/k8s-09aab42a12
build(deps): bump the k8s group with 4 updates
2026-10-05 17:07:22 +00:00
dependabot[bot] 278333782e build(deps): bump the k8s group with 4 updates
Bumps the k8s group with 4 updates: [k8s.io/apimachinery](https://github.com/kubernetes/apimachinery), [k8s.io/client-go](https://github.com/kubernetes/client-go), [k8s.io/cri-client](https://github.com/kubernetes/cri-client) and [k8s.io/cri-streaming](https://github.com/kubernetes/cri-streaming).


Updates `k8s.io/apimachinery` from 0.37.0 to 0.37.1
- [Commits](https://github.com/kubernetes/apimachinery/compare/v0.37.0...v0.37.1)

Updates `k8s.io/client-go` from 0.37.0 to 0.37.1
- [Changelog](https://github.com/kubernetes/client-go/blob/master/CHANGELOG.md)
- [Commits](https://github.com/kubernetes/client-go/compare/v0.37.0...v0.37.1)

Updates `k8s.io/cri-client` from 0.37.0 to 0.37.1
- [Commits](https://github.com/kubernetes/cri-client/compare/v0.37.0...v0.37.1)

Updates `k8s.io/cri-streaming` from 0.37.0 to 0.37.1
- [Commits](https://github.com/kubernetes/cri-streaming/compare/v0.37.0...v0.37.1)

---
updated-dependencies:
- dependency-name: k8s.io/apimachinery
  dependency-version: 0.37.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: k8s
- dependency-name: k8s.io/client-go
  dependency-version: 0.37.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: k8s
- dependency-name: k8s.io/cri-client
  dependency-version: 0.37.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: k8s
- dependency-name: k8s.io/cri-streaming
  dependency-version: 0.37.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: k8s
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-10-02 23:23:10 +00:00
Mike Brown 81af89b1d4 Merge pull request #14268 from AkihiroSuda/go1.27
go.mod: bump minimum Go version to 1.27.0
2026-10-02 22:25:44 +00:00
Maksym Pavlenko 250501a5db Merge pull request #14273 from mxpv/erofs-docs
Correct erofs docs
2026-10-02 15:57:35 +00:00
Akihiro Suda 7c359a8cba go.mod: bump minimum Go version to 1.27.0
Corresponds to the minimum version required by Kubernetes 1.38
https://github.com/kubernetes/cri-api/blob/v0.38.0-alpha.1/go.mod#L5

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2026-10-02 15:38:42 +09:00
Akihiro Suda 836180376d golangci: modernize: disable embedlit
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2026-10-02 15:38:41 +09:00
Maksym Pavlenko 46e01308a8 Correct erofs docs
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2026-10-01 11:38:40 -07:00
Maksym Pavlenko eb4dbd872d Merge pull request #14272 from samuelkarp/eol-1.7
releases: 1.7 EOL, update the rest to current
2026-10-01 16:20:06 +00:00