Skip to content

Commit a68105b

Browse files
authored
Resolve critical and high vulnerabilities in secret-agent docker image. (#283)
* Resolve critical and high vulnerabilities in secret-agent docker image. ref: FORGEOPS-5627 * Update go package checksum.
1 parent f488a42 commit a68105b

File tree

6 files changed

+20
-17
lines changed

6 files changed

+20
-17
lines changed

.github/workflows/ci.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
- name: Set up Go 1.x
1616
uses: actions/setup-go@v2
1717
with:
18-
go-version: 1.22
18+
go-version: 1.23
1919
id: go
2020

2121
- name: Check out code into the Go module directory
@@ -56,7 +56,7 @@ jobs:
5656
- name: Set up Go
5757
uses: actions/setup-go@v2
5858
with:
59-
go-version: 1.22
59+
go-version: 1.23
6060
id: go
6161

6262
- name: Set Go Releaser Environment

Dockerfile

+9-6
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# For building forgerock/secret-agent:tagname
22

33
# Global build arguments
4-
ARG GO_VERSION="1.22.2"
5-
ARG GO_PACKAGE_SHA256="5901c52b7a78002aeff14a21f93e0f064f74ce1360fce51c6ee68cd471216a17"
4+
ARG GO_VERSION="1.23.6"
5+
ARG GO_PACKAGE_SHA256="9379441ea310de000f33a4dc767bd966e72ab2826270e038e78b2c53c2e7802d"
66
ARG KUBEBUILDER_VERSION="3.1.0"
77

8-
FROM openjdk:23-ea-15-jdk-slim-bullseye as tester
8+
FROM openjdk:23-jdk-slim-bookworm AS tester
99

1010
ARG GO_VERSION
1111
ARG GO_PACKAGE_SHA256
@@ -14,6 +14,7 @@ ARG TARGETARCH
1414

1515
ENV CGO_ENABLED=0 GOOS=linux GOARCH=$TARGETARCH DEBIAN_FRONTEND=noninteractive
1616
RUN apt-get update && \
17+
apt-get upgrade -y && \
1718
apt-get install --no-install-recommends -y curl git-core make && \
1819
apt-get clean all
1920

@@ -36,7 +37,7 @@ CMD ["bash"]
3637

3738

3839
# Build the manager binary
39-
FROM golang:${GO_VERSION}-alpine as builder
40+
FROM golang:${GO_VERSION}-alpine AS builder
4041

4142
WORKDIR /workspace
4243
# Copy the Go Modules manifests
@@ -61,10 +62,12 @@ RUN CGO_ENABLED=0 GOOS=linux GOARCH=$TARGETARCH GO111MODULE=on go build -ldflags
6162

6263

6364

64-
FROM openjdk:23-ea-15-jdk-slim-bullseye as release
65+
FROM openjdk:23-jdk-slim-bookworm AS release
6566

67+
ENV DEBIAN_FRONTEND=noninteractive
6668
RUN apt-get update && \
67-
DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y lsof net-tools && \
69+
apt-get upgrade -y && \
70+
apt-get install --no-install-recommends -y lsof net-tools && \
6871
apt-get clean all
6972
RUN addgroup --gid 11111 secret-agent && \
7073
adduser --shell /bin/bash --home /home/secret-agent --uid 11111 --disabled-password --ingroup root --gecos secret-agent secret-agent && \

charts/secret-agent/Chart.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,10 @@ type: application
1515
# This is the chart version. This version number should be incremented each time you make changes
1616
# to the chart and its templates, including the app version.
1717
# Versions are expected to follow Semantic Versioning (https://semver.org/)
18-
version: v1.2.2
18+
version: v1.2.4
1919

2020
# This is the version number of the application being deployed. This version number should be
2121
# incremented each time you make changes to the application. Versions are not expected to
2222
# follow Semantic Versioning. They should reflect the version the application is using.
2323
# It is recommended to use it with quotes.
24-
appVersion: "v1.2.2"
24+
appVersion: "v1.2.4"

charts/secret-agent/values.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
replicaCount: 1
44

55
image:
6-
repository: docker.io/forgerock/secret-agent
6+
repository: us-docker.pkg.dev/forgeops-public/images/secret-agent
77
pullPolicy: IfNotPresent
88
# Overrides the image tag whose default is the chart appVersion.
99
tag: ""

go.mod

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ require (
1515
github.com/aws/smithy-go v1.20.2
1616
github.com/go-logr/logr v1.4.1
1717
github.com/go-playground/validator/v10 v10.15.1
18-
github.com/golang/glog v1.2.1
18+
github.com/golang/glog v1.2.4
1919
github.com/onsi/ginkgo/v2 v2.17.2
2020
github.com/onsi/gomega v1.33.1
2121
github.com/pkg/errors v0.9.1
@@ -109,7 +109,7 @@ require (
109109
go.uber.org/multierr v1.11.0 // indirect
110110
go.uber.org/zap v1.26.0 // indirect
111111
golang.org/x/exp v0.0.0-20231006140011-7918f672742d // indirect
112-
golang.org/x/net v0.25.0 // indirect
112+
golang.org/x/net v0.33.0 // indirect
113113
golang.org/x/oauth2 v0.20.0 // indirect
114114
golang.org/x/sync v0.10.0 // indirect
115115
golang.org/x/sys v0.28.0 // indirect

go.sum

+4-4
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,8 @@ github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w
127127
github.com/golang-jwt/jwt/v4 v4.5.1 h1:JdqV9zKUdtaa9gdPlywC3aeoEsR681PlKC+4F5gQgeo=
128128
github.com/golang-jwt/jwt/v4 v4.5.1/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0=
129129
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
130-
github.com/golang/glog v1.2.1 h1:OptwRhECazUx5ix5TTWC3EZhsZEHWcYWY4FQHTIubm4=
131-
github.com/golang/glog v1.2.1/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w=
130+
github.com/golang/glog v1.2.4 h1:CNNw5U8lSiiBk7druxtSHHTsRWcxKoac6kZKm2peBBc=
131+
github.com/golang/glog v1.2.4/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w=
132132
github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
133133
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE=
134134
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
@@ -281,8 +281,8 @@ golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v
281281
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
282282
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
283283
golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs=
284-
golang.org/x/net v0.25.0 h1:d/OCCoBEUq33pjydKrGQhw7IlUPI2Oylr+8qLx49kac=
285-
golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM=
284+
golang.org/x/net v0.33.0 h1:74SYHlV8BIgHIFC/LrYkOGIwL19eTYXQ5wc6TBuO36I=
285+
golang.org/x/net v0.33.0/go.mod h1:HXLR5J+9DxmrqMwG9qjGCxZ+zKXxBru04zlTvWlWuN4=
286286
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
287287
golang.org/x/oauth2 v0.20.0 h1:4mQdhULixXKP1rwYBW0vAijoXnkTG0BLCDRzfe1idMo=
288288
golang.org/x/oauth2 v0.20.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI=

0 commit comments

Comments
 (0)