Commit Graph

1856 Commits

Author SHA1 Message Date
Sebastiaan van Stijn 957044825f
update to go1.20.8
go1.20.8 (released 2023-09-06) includes two security fixes to the html/template
package, as well as bug fixes to the compiler, the go command, the runtime,
and the crypto/tls, go/types, net/http, and path/filepath packages. See the
Go 1.20.8 milestone on our issue tracker for details:

https://github.com/golang/go/issues?q=milestone%3AGo1.20.8+label%3ACherryPickApproved

full diff: https://github.com/golang/go/compare/go1.20.7...go1.20.8

From the security mailing:

[security] Go 1.21.1 and Go 1.20.8 are released

Hello gophers,

We have just released Go versions 1.21.1 and 1.20.8, minor point releases.

These minor releases include 4 security fixes following the security policy:

- cmd/go: go.mod toolchain directive allows arbitrary execution
  The go.mod toolchain directive, introduced in Go 1.21, could be leveraged to
  execute scripts and binaries relative to the root of the module when the "go"
  command was executed within the module. This applies to modules downloaded using
  the "go" command from the module proxy, as well as modules downloaded directly
  using VCS software.

  Thanks to Juho Nurminen of Mattermost for reporting this issue.

  This is CVE-2023-39320 and Go issue https://go.dev/issue/62198.

- html/template: improper handling of HTML-like comments within script contexts
  The html/template package did not properly handle HMTL-like "<!--" and "-->"
  comment tokens, nor hashbang "#!" comment tokens, in <script> contexts. This may
  cause the template parser to improperly interpret the contents of <script>
  contexts, causing actions to be improperly escaped. This could be leveraged to
  perform an XSS attack.

  Thanks to Takeshi Kaneko (GMO Cybersecurity by Ierae, Inc.) for reporting this
  issue.

  This is CVE-2023-39318 and Go issue https://go.dev/issue/62196.

- html/template: improper handling of special tags within script contexts
  The html/template package did not apply the proper rules for handling occurrences
  of "<script", "<!--", and "</script" within JS literals in <script> contexts.
  This may cause the template parser to improperly consider script contexts to be
  terminated early, causing actions to be improperly escaped. This could be
  leveraged to perform an XSS attack.

  Thanks to Takeshi Kaneko (GMO Cybersecurity by Ierae, Inc.) for reporting this
  issue.

  This is CVE-2023-39319 and Go issue https://go.dev/issue/62197.

- crypto/tls: panic when processing post-handshake message on QUIC connections
  Processing an incomplete post-handshake message for a QUIC connection caused a panic.

  Thanks to Marten Seemann for reporting this issue.

  This is CVE-2023-39321 and CVE-2023-39322 and Go issue https://go.dev/issue/62266.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-09-11 15:53:03 +02:00
CrazyMax 42a0f3d504
Merge pull request #2037 from kd-collective/fix_broken_link
docs: remove broken link
2023-09-09 09:03:15 +02:00
Kijima Daigo 84ad208985 docs: remove broken link
Signed-off-by: Kijima Daigo <norimaking777@gmail.com>
2023-09-09 11:51:56 +09:00
CrazyMax 3631dc17c9
Merge pull request #2027 from thaJeztah/swap_reference
migrate reference github.com/distribution/reference
2023-09-08 15:49:08 +02:00
Sebastiaan van Stijn bafdc63b8c
migrate to github.com/distribution/reference v0.5.0
The "reference" package was moved to a separate module, which was extracted
from b9b19409cf

Also update compose-go, which also switched to distribution/reference;

full diff: https://github.com/compose-spec/compose-go/compare/v1.18.3...v1.18.4

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-09-06 17:41:35 +02:00
Sebastiaan van Stijn 51c94cd2a6
vendor: github.com/compose-spec/compose-go v1.18.3
- Parse service device count to int if possible
- introduce ResourceResolver to accept remote resources
- use include.env_file to resolve variables in included compose.yaml file
- remove potential dependencies to disabled services in ForServices
- ability to convert a mapping (back) to KEY=VALUE strings
- load: include details about included files on Project
- include disabled services
- local environment to override included .env
- load: move env var profile detection to option
- add support for multi-document yaml

full diff: https://github.com/compose-spec/compose-go/compare/v1.17.0...v1.18.3

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-09-06 17:41:35 +02:00
Tõnis Tiigi 31d88398bc
Merge pull request #2031 from thaJeztah/bump_notary
vendor: github.com/theupdateframework/notary v0.7.0
2023-09-06 08:37:17 -07:00
Justin Chadwell fbf6594758
Merge pull request #2034 from tonistiigi/trace-delegate-driver 2023-09-06 11:20:56 +01:00
Tonis Tiigi f54a67de6d
enable trace delegation for docker/remote driver
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2023-09-05 22:04:57 -07:00
CrazyMax f35b2b7cab
Merge pull request #2032 from docker/dependabot/github_actions/actions/checkout-4
build(deps): bump actions/checkout from 3 to 4
2023-09-05 08:36:03 +02:00
dependabot[bot] 29ba5ecef6
build(deps): bump actions/checkout from 3 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-04 18:51:00 +00:00
Sebastiaan van Stijn fb50d82fd8
vendor: github.com/theupdateframework/notary v0.7.0
update the dependency to v0.7.0 to be closer to what docker/cli uses;
https://github.com/theupdateframework/notary/compare/v0.6.1...v0.7.0

Note that docker/cli is slightly ahead of v0.7.0, and uses bf96a202a09a;
https://github.com/theupdateframework/notary/compare/v0.7.0...bf96a202a09a

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-09-04 15:37:45 +02:00
Justin Chadwell 87e8e4b847
Merge pull request #2029 from testwill/loop
chore: slice loop replace
2023-08-31 07:10:10 +02:00
guoguangwu a71a24c0f4 chore: slice loop replace
Signed-off-by: guoguangwu <guoguangwu@magic-shield.com>
2023-08-31 12:24:02 +08:00
Tõnis Tiigi 76119b0f61
Merge pull request #2026 from ktock/fix-invoke-flag
debug: fix short-form custom command name on `--invoke` isn't used
2023-08-30 10:05:49 -07:00
Kohei Tokunaga 7843b5f417
debug: fix short-form custom command name on `--invoke` isn't used
Signed-off-by: Kohei Tokunaga <ktokunaga.mail@gmail.com>
2023-08-30 18:41:16 +09:00
Justin Chadwell da6662975f
Merge pull request #2019 from jedevc/chore-bake-field-reorder 2023-08-24 14:17:55 +01:00
Justin Chadwell de4dbb7d00 chore: reorder target fields
Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-24 14:01:14 +01:00
Justin Chadwell 3bd4bca994
Merge pull request #2013 from jedevc/tests-add-imagetools-create
tests: add imagetools tests for copying manifests and indexes
2023-08-23 13:31:45 +01:00
CrazyMax 296832c90e
Merge pull request #2014 from crazy-max/fix-compose-test
test: fix non-deterministic compose context path
2023-08-23 11:27:47 +02:00
CrazyMax 56d55a4137
test: fix non-deterministic compose context path
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
2023-08-23 11:15:50 +02:00
CrazyMax 626e6f8fa3
Merge pull request #1905 from thaJeztah/cgroup_parent_description
update flag-description for --cgroup-parent
2023-08-23 10:15:47 +02:00
Justin Chadwell 5941bf0494 tests: add imagetools tests for copying manifests and indexes
Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-22 17:38:36 +01:00
CrazyMax 29a496cdab
Merge pull request #2012 from jedevc/git-propogate-errors
git: propogate failure to locate git binary
2023-08-22 13:30:36 +02:00
Justin Chadwell a43d9a67c7 git: fix error wrapping to ensure internal errors are propogated
Also, tidy up the error printing, so that now we always print out the
"current commit information was not captured by the build" message,
instead of just for not locating the git binary.

Before:

	WARNING: buildx: git was not found in the system. Current commit information was not captured by the build

After:

	WARNING: current commit information was not captured by the build: git was not found in the system: <error message>

Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-22 12:17:17 +01:00
Justin Chadwell c47eb3bf5a git: propogate failure to locate git binary
Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-22 12:16:19 +01:00
CrazyMax a97e1641a4
Merge pull request #2000 from jedevc/fix-race-container-creation
docker-container: avoid fail if container conflict
2023-08-21 16:11:02 +02:00
Akihiro Suda 86ae8ea854
Merge pull request #1999 from crazy-max/update-k8s
vendor: bump k8s to v0.26.7
2023-08-10 23:26:24 +09:00
Justin Chadwell d37d483097 docker-container: avoid fail if container conflict
Fixes the race condition where two boots are executed simultaneously
across multiple processes.

We initially check to see if the container exists, but if during
container creation we get a name conflict, we don't treat this error as
a hard failure, and instead move immediately into waiting for the node
to boot.

Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-10 14:29:36 +01:00
CrazyMax 4e96faa201
vendor: bump k8s to v0.26.7
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
2023-08-10 15:22:24 +02:00
Tõnis Tiigi e5419ef6d7
Merge pull request #1927 from crazy-max/fix-load-status
build: read body response to check for erroneous image export to docker
2023-08-10 12:29:03 +03:00
CrazyMax 14747a490a
Merge pull request #1971 from glours/bump-compose-go-v1.17.0
bump compose-go version to v1.17.0 to fix issue with depends_on
2023-08-08 21:03:59 +02:00
Justin Chadwell e5cee892ed
Merge pull request #1965 from mqasimsarfraz/qasim/oci-annotations 2023-08-08 14:36:26 +01:00
CrazyMax ef4b984df4
build: read body response to check for erroneous image export to docker
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
2023-08-08 06:34:24 +02:00
CrazyMax a8f402e28d
Merge pull request #1993 from kenyon/typo-fix
README: fix typo
2023-08-08 06:32:44 +02:00
Kenyon Ralph 2eba99b40b README: fix whitespace
Signed-off-by: Kenyon Ralph <quic_kralph@quicinc.com>
2023-08-07 11:34:13 -07:00
Kenyon Ralph 7686fa1f16 README: fix typo
Signed-off-by: Kenyon Ralph <quic_kralph@quicinc.com>
2023-08-07 11:33:54 -07:00
Justin Chadwell 51b9bab245
Merge pull request #1987 from jedevc/vendor-buildkit-master-tests 2023-08-07 17:08:16 +01:00
CrazyMax 6b5758f4cd
Merge pull request #1821 from jedevc/allow-debug-env
commands: consume DEBUG environment variable
2023-08-07 15:06:47 +02:00
CrazyMax bd375a14a8
Merge pull request #1940 from kenyon/patch-1
README: clarify the Linux package install instructions
2023-08-07 14:43:29 +02:00
CrazyMax b01693f63e
bake: test compose include
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
2023-08-04 17:24:30 +02:00
Guillaume Lours 4a059d5144
adapt compose unit tests, build context is now transformed to absolute paths by compose-go
Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2023-08-04 17:23:12 +02:00
Guillaume Lours f3775c0046
bump compose-go version to v1.17.0 to fix issue with depends_on
Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2023-08-04 17:23:04 +02:00
Justin Chadwell 50fbdd86f9
Merge pull request #1985 from jsternberg/integration-test/version 2023-08-04 16:14:42 +01:00
Justin Chadwell 1f61de0fcc
Merge pull request #1988 from jedevc/fix-attests-on-docker-driver 2023-08-04 16:07:21 +01:00
Justin Chadwell e206c585bb build: error on attests on non-multiplatform driver
On drivers that do not support multi-platform builds (the default
`docker` driver), we do not support building attestations (unless using
the containerd store).

We need to check this feature before attempting to build using
attestations.

Also adds a test to ensure that attestations can be pushed to registries
at all, and that it adequately fails on the docker driver.

Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-04 15:28:32 +01:00
Justin Chadwell 5e46d8057d tests: add unsupported features detection skeleton
Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-04 12:00:18 +01:00
Justin Chadwell 4e7709e54c vendor: update buildkit to master@b49a8873179b
Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-04 12:00:18 +01:00
Justin Chadwell 5ed8f1b7d9 tests: avoid hardcoded driver check in testImageIDOutput
To detect if there is a docker daemon available, we can use the sandbox
.DockerAddress() function.

Signed-off-by: Justin Chadwell <me@jedevc.com>
2023-08-04 11:22:10 +01:00
Jonathan A. Sternberg 1d12c1f5b3
Integration test for docker buildx version
An integration test for `docker buildx version` has been created. The
integration test checks that there is one line output, the output is
composed of three sections, and that these sections could feasibly be
the package path, version, and revision information.

The intention of the checks is to find obvious errors in the output like
the package path not existing or the version and revision being swapped.
It is not intended to assert that these values must be certain values
because it is assumed these values may vary depending on the build
process for buildx.

Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
2023-08-03 09:51:03 -05:00