Skip to content

Commit 47dda4a

Browse files
authored
Update packages for CVEs (#4516) (#4517)
(cherry picked from commit 547e5bf)
1 parent 591747f commit 47dda4a

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

build/Dockerfile

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# syntax=docker/dockerfile:1.5
1+
# syntax=docker/dockerfile:1.6
22
ARG BUILD_OS=debian
33
ARG NGINX_PLUS_VERSION=R30
44
ARG DOWNLOAD_TAG=edge
@@ -27,8 +27,8 @@ FROM nginx:1.25.2-alpine AS alpine
2727

2828
RUN --mount=type=bind,from=alpine-opentracing-lib,target=/tmp/ot/ \
2929
apk add --no-cache libcap libstdc++ \
30-
# temp fix for CVE-2023-3138
31-
&& apk upgrade --no-cache libx11 \
30+
# temp fix for CVE-2023-38545 and CVE-2023-44487
31+
&& apk upgrade --no-cache curl nghttp2-libs \
3232
&& cp -av /tmp/ot/usr/local/lib/libopentracing.so* /tmp/ot/usr/local/lib/libjaegertracing*so* /tmp/ot/usr/local/lib/libzipkin*so* /tmp/ot/usr/local/lib/libdd*so* /tmp/ot/usr/local/lib/libyaml*so* /usr/local/lib/ \
3333
&& cp -av /tmp/ot/usr/lib/nginx/modules/ngx_http_opentracing_module.so /usr/lib/nginx/modules/ \
3434
&& ldconfig /usr/local/lib/
@@ -181,6 +181,8 @@ RUN --mount=type=secret,id=nginx-repo.crt,dst=/etc/ssl/nginx/nginx-repo.crt,mode
181181
&& sed -i "0,/centos/s;;${NGINX_PLUS_VERSION}/centos;" /etc/yum.repos.d/nginx-plus.repo \
182182
&& dnf --nodocs install -y nginx-plus nginx-plus-module-njs nginx-plus-module-fips-check \
183183
## end of duplicated code
184+
## fix for CVEs
185+
&& dnf upgrade -y curl dbus libcap libssh platform-python python3-requests libxml2 systemd sqlite-libs dnf-plugin-subscription-manager dmidecode subscription-manager-rhsm-certificates glibc subscription-manager \
184186
&& sed -i 's/\(def in_container():\)/\1\n return False/g' /usr/lib64/python*/*-packages/rhsm/config.py \
185187
&& subscription-manager register --org=${RHEL_ORGANIZATION} --activationkey=${RHEL_ACTIVATION_KEY} || true \
186188
&& subscription-manager attach \
@@ -197,7 +199,7 @@ RUN --mount=type=secret,id=nginx-repo.crt,dst=/etc/ssl/nginx/nginx-repo.crt,mode
197199
dnf --nodocs install -y app-protect-dos; \
198200
fi \
199201
# fix for CVEs
200-
&& dnf upgrade -y curl dbus libcap libssh platform-python python3-requests libxml2 systemd sqlite-libs dmidecode dnf-plugin-subscription-manager ncurses \
202+
&& dnf upgrade -y curl ncurses \
201203
&& rm /etc/yum.repos.d/app-protect*.repo \
202204
&& subscription-manager unregister \
203205
&& dnf clean all && rm -rf /var/cache/dnf

0 commit comments

Comments
 (0)