Skip to content

Commit

Permalink
Merge pull request #25 from coreruleset/fix-variables
Browse files Browse the repository at this point in the history
fix: unused variables
  • Loading branch information
fzipi authored Oct 18, 2024
2 parents 0808ea5 + 2910f32 commit 73b87aa
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 14 deletions.
13 changes: 7 additions & 6 deletions caddy/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -142,19 +142,17 @@ USER "${CADDY_USER}:${CADDY_GROUP}"

# Set env variables for config/data directories
ENV \
XDG_CONFIG_HOME="$CADDY_CONFIG_DIR" \
XDG_DATA_HOME="$CADDY_DATA_DIR" \
ACCESSLOG=/var/log/caddy/access.log \
BACKEND=localhost:80 \
CORAZA_ARGUMENTS_LIMIT=1000 \
CORAZA_AUDIT_ENGINE="RelevantOnly" \
CORAZA_AUDIT_LOG=/dev/stdout \
CORAZA_AUDIT_LOG='/dev/stdout' \
CORAZA_AUDIT_LOG_FORMAT=JSON \
CORAZA_AUDIT_LOG_PARTS='ABIJDEFHZ' \
CORAZA_AUDIT_LOG_RELEVANT_STATUS="^(?:5|4[0-9][0-35-9])" \
CORAZA_AUDIT_LOG_TYPE=Serial \
CORAZA_AUDIT_STORAGE_DIR=/var/log/coraza/audit/ \
CORAZA_DATA_DIR=/tmp/coraza/data \
CORAZA_AUDIT_LOG_TYPE='Serial' \
CORAZA_AUDIT_STORAGE_DIR='/var/log/coraza/audit/' \
CORAZA_DATA_DIR='/tmp/coraza/data' \
CORAZA_DEBUG_LOG=/dev/null \
CORAZA_DEBUG_LOGLEVEL=1 \
CORAZA_DEFAULT_PHASE1_ACTION="phase:1,pass,log,tag:'\${CORAZA_TAG}'" \
Expand All @@ -174,7 +172,10 @@ ENV \
CORAZA_TMP_SAVE_UPLOADED_FILES="on" \
CORAZA_UPLOAD_DIR=/tmp/coraza/upload \
CORAZA_UPLOAD_FILE_MODE=0600 \
CORAZA_UPLOAD_KEEP_FILES="Off" \
PORT=8080 \
XDG_CONFIG_HOME="${CADDY_CONFIG_DIR}" \
XDG_DATA_HOME="${CADDY_DATA_DIR}" \
# CRS specific variables
PARANOIA=1 \
ANOMALY_INBOUND=5 \
Expand Down
8 changes: 0 additions & 8 deletions src/templates/coraza.conf
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ SecRequestBodyNoFilesLimit ${CORAZA_REQ_BODY_NOFILES_LIMIT}
SecRequestBodyLimitAction ${CORAZA_REQ_BODY_LIMIT_ACTION}
# SecRequestBodyJsonDepthLimit ${CORAZA_REQ_BODY_JSON_DEPTH_LIMIT}
# SecArgumentsLimit ${CORAZA_ARGUMENTS_LIMIT}
SecPcreMatchLimit ${CORAZA_PCRE_MATCH_LIMIT}
SecPcreMatchLimitRecursion ${CORAZA_PCRE_MATCH_LIMIT_RECURSION}
SecResponseBodyAccess ${CORAZA_RESP_BODY_ACCESS}
SecResponseBodyMimeType ${CORAZA_RESP_BODY_MIMETYPE}
SecResponseBodyLimit ${CORAZA_RESP_BODY_LIMIT}
Expand All @@ -19,18 +17,12 @@ SecAuditLogRelevantStatus "${CORAZA_AUDIT_LOG_RELEVANT_STATUS}"
SecAuditLogParts ${CORAZA_AUDIT_LOG_PARTS}
SecAuditLogType ${CORAZA_AUDIT_LOG_TYPE}
SecAuditLog ${CORAZA_AUDIT_LOG}
SecArgumentSeparator ${CORAZA_ARGUMENT_SEPARATOR}
SecCookieFormat ${CORAZA_COOKIE_FORMAT}
# SecUnicodeMapFile unicode.mapping ${CORAZA_UNICODE_MAPPING}
# SecStatusEngine ${CORAZA_STATUS_ENGINE}

# Additional directives
SecAuditLogFormat ${CORAZA_AUDIT_LOG_FORMAT}
SecAuditLogStorageDir ${CORAZA_AUDIT_STORAGE_DIR}
SecDebugLog ${CORAZA_DEBUG_LOG}
SecDebugLogLevel ${CORAZA_DEBUG_LOGLEVEL}
# SecDisableBackendCompression ${CORAZA_DISABLE_BACKEND_COMPRESSION}
# SecTmpSaveUploadedFiles ${CORAZA_TMP_SAVE_UPLOADED_FILES}
SecUploadDir ${CORAZA_UPLOAD_DIR}
SecUploadFileMode ${CORAZA_UPLOAD_FILE_MODE}
SecUploadKeepFiles ${CORAZA_UPLOAD_KEEP_FILES}
Expand Down

0 comments on commit 73b87aa

Please sign in to comment.