Skip to content

Commit

Permalink
Apply mitigation for CVE-2021-44228
Browse files Browse the repository at this point in the history
Mitigation documented here; https://logging.apache.org/log4j/2.x/security.html

Signed-off-by: Wade Barnes <[email protected]>
  • Loading branch information
WadeBarnes committed Dec 14, 2021
1 parent 3834ed8 commit 6b4565d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
10 changes: 9 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM sonarqube:8-community
MAINTAINER Erik Jacobs <[email protected]>
MAINTAINER Siamak Sadeghianfar <[email protected]>
MAINTAINER Roland Stens ([email protected])
MAINTAINER Wade Barnes (wade.barnes@shaw.ca)
MAINTAINER Wade Barnes (wade@neoterictech.ca)
MAINTAINER Emiliano Sune ([email protected])
MAINTAINER Alejandro Sanchez ([email protected])

Expand All @@ -21,6 +21,14 @@ LABEL summary="$SUMMARY" \
# Define Plug-in Versions
ARG SONAR_ZAP_PLUGIN_VERSION=1.2.0
ENV SONARQUBE_PLUGIN_DIR="$SONARQUBE_HOME/extensions/plugins"
# ===============================================================================================
# Mitigation for CVE-2021-44228
#
# References:
# - https://logging.apache.org/log4j/2.x/security.html
# -----------------------------------------------------------------------------------------------
ENV LOG4J_FORMAT_MSG_NO_LOOKUPS=true
# ===============================================================================================

# Switch to root for package installs
USER 0
Expand Down
2 changes: 2 additions & 0 deletions sonarqube-postgresql-template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,8 @@ objects:
value: sonar
- name: SONAR_FORCEAUTHENTICATION
value: "true"
- name: LOG4J_FORMAT_MSG_NO_LOOKUPS
value: "true"
volumeMounts:
- mountPath: /opt/sonarqube/data
name: sonar-data
Expand Down

0 comments on commit 6b4565d

Please sign in to comment.