docker-cli/docker-bake.hcl
Paweł Gronowski fe7fc2ff7f
update to go1.24.4
- https://github.com/golang/go/issues?q=milestone%3AGo1.24.4+label%3ACherryPickApproved
- full diff: https://github.com/golang/go/compare/go1.24.3...go1.24.4

This release includes 3 security fixes following the security policy:

- net/http: sensitive headers not cleared on cross-origin redirect

    Proxy-Authorization and Proxy-Authenticate headers persisted on cross-origin redirects potentially leaking sensitive information.

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

    This is CVE-2025-4673 and Go issue https://go.dev/issue/73816.

- os: inconsistent handling of O_CREATE|O_EXCL on Unix and Windows

    os.OpenFile(path, os.O_CREATE|O_EXCL) behaved differently on Unix and Windows systems when the target path was a dangling symlink. On Unix systems, OpenFile with O_CREATE and O_EXCL flags never follows symlinks. On Windows, when the target path was a symlink to a nonexistent location, OpenFile would create a file in that location.

    OpenFile now always returns an error when the O_CREATE and O_EXCL flags are both set and the target path is a symlink.

    Thanks to Junyoung Park and Dong-uk Kim of KAIST Hacking Lab for discovering this issue.

    This is CVE-2025-0913 and Go issue https://go.dev/issue/73702.

- crypto/x509: usage of ExtKeyUsageAny disables policy validation

    Calling Verify with a VerifyOptions.KeyUsages that contains ExtKeyUsageAny unintentionally disabledpolicy validation. This only affected certificate chains which contain policy graphs, which are rather uncommon.

    Thanks to Krzysztof Skrzętnicki (@Tener) of Teleport for reporting this issue.

    This is CVE-2025-22874 and Go issue https://go.dev/issue/73612.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2025-06-09 16:25:41 +02:00

198 lines
3.8 KiB
HCL

variable "GO_VERSION" {
default = "1.24.4"
}
variable "VERSION" {
default = ""
}
variable "USE_GLIBC" {
default = ""
}
variable "STRIP_TARGET" {
default = ""
}
variable "IMAGE_NAME" {
default = "docker-cli"
}
# Sets the name of the company that produced the windows binary.
variable "PACKAGER_NAME" {
default = ""
}
target "_common" {
args = {
GO_VERSION = GO_VERSION
BUILDKIT_CONTEXT_KEEP_GIT_DIR = 1
}
}
target "_platforms" {
platforms = [
"darwin/amd64",
"darwin/arm64",
"linux/amd64",
"linux/arm/v6",
"linux/arm/v7",
"linux/arm64",
"linux/ppc64le",
"linux/riscv64",
"linux/s390x",
"windows/amd64",
"windows/arm64"
]
}
group "default" {
targets = ["binary"]
}
target "binary" {
inherits = ["_common"]
target = "binary"
platforms = ["local"]
output = ["build"]
args = {
BASE_VARIANT = USE_GLIBC == "1" ? "debian" : "alpine"
VERSION = VERSION
PACKAGER_NAME = PACKAGER_NAME
GO_STRIP = STRIP_TARGET
}
}
target "dynbinary" {
inherits = ["binary"]
args = {
GO_LINKMODE = "dynamic"
}
}
target "plugins" {
inherits = ["_common"]
target = "plugins"
platforms = ["local"]
output = ["build"]
args = {
BASE_VARIANT = USE_GLIBC == "1" ? "debian" : "alpine"
VERSION = VERSION
GO_STRIP = STRIP_TARGET
}
}
target "cross" {
inherits = ["binary", "_platforms"]
}
target "dynbinary-cross" {
inherits = ["dynbinary", "_platforms"]
}
target "plugins-cross" {
inherits = ["plugins", "_platforms"]
}
target "lint" {
inherits = ["_common"]
dockerfile = "./dockerfiles/Dockerfile.lint"
target = "lint"
output = ["type=cacheonly"]
}
target "shellcheck" {
inherits = ["_common"]
dockerfile = "./dockerfiles/Dockerfile.shellcheck"
target = "shellcheck"
output = ["type=cacheonly"]
}
target "validate-vendor" {
inherits = ["_common"]
dockerfile = "./dockerfiles/Dockerfile.vendor"
target = "validate"
output = ["type=cacheonly"]
}
target "update-vendor" {
inherits = ["_common"]
dockerfile = "./dockerfiles/Dockerfile.vendor"
target = "update"
output = ["."]
}
target "mod-outdated" {
inherits = ["_common"]
dockerfile = "./dockerfiles/Dockerfile.vendor"
target = "outdated"
no-cache-filter = ["outdated"]
output = ["type=cacheonly"]
}
target "validate-authors" {
inherits = ["_common"]
dockerfile = "./dockerfiles/Dockerfile.authors"
target = "validate"
output = ["type=cacheonly"]
}
target "update-authors" {
inherits = ["_common"]
dockerfile = "./dockerfiles/Dockerfile.authors"
target = "update"
output = ["."]
}
target "test" {
inherits = ["_common"]
target = "test"
output = ["type=cacheonly"]
}
target "test-coverage" {
inherits = ["_common"]
target = "test-coverage"
output = ["build/coverage"]
}
target "e2e-image" {
inherits = ["_common"]
target = "e2e"
output = ["type=docker"]
tags = ["${IMAGE_NAME}"]
args = {
BASE_VARIANT = USE_GLIBC == "1" ? "debian" : "alpine"
VERSION = VERSION
}
}
target "e2e-gencerts" {
inherits = ["_common"]
dockerfile = "./e2e/testdata/Dockerfile.gencerts"
output = ["./e2e/testdata"]
}
target "docker-metadata-action" {
tags = ["cli-bin:local"]
}
target "bin-image" {
inherits = ["binary", "docker-metadata-action"]
target = "bin-image"
output = ["type=docker"]
}
target "bin-image-cross" {
inherits = ["bin-image"]
output = ["type=image"]
platforms = [
"darwin/amd64",
"darwin/arm64",
"linux/amd64",
"linux/arm/v6",
"linux/arm/v7",
"linux/arm64",
"linux/ppc64le",
"linux/s390x",
"windows/amd64",
"windows/arm64"
]
}