Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ RUN mkdir -p /home/cronos/data && mkdir -p /home/cronos/config
RUN apt-get update -y && apt-get install wget curl procps net-tools jq lz4 -y

# Download and verify tarball
RUN cd /tmp && wget --no-check-certificate https://github.com/crypto-org-chain/cronos/releases/download/v1.4.11/cronos_1.4.11_Linux_x86_64.tar.gz && tar -xvf cronos_1.4.11_Linux_x86_64.tar.gz \
&& rm cronos_1.4.11_Linux_x86_64.tar.gz && mv ./* /home/cronos/
RUN cd /tmp && wget --no-check-certificate https://github.com/crypto-org-chain/cronos/releases/download/v1.5.1/cronos_1.5.1-testnet_Linux_x86_64.tar.gz && tar -xvf cronos_1.5.1-testnet_Linux_x86_64.tar.gz \
&& rm cronos_1.5.1-testnet_Linux_x86_64.tar.gz && mv ./* /home/cronos/
Comment on lines +11 to +12
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

Drop --no-check-certificate to avoid MITM exposure.

Disabling TLS validation when fetching the release tarball lets any man-in-the-middle swap the binary, which is an unacceptable supply-chain risk for production images. Please keep certificate checks enabled (and ideally add checksum verification). Fix by removing the flag:

-RUN cd /tmp && wget --no-check-certificate https://github.com/crypto-org-chain/cronos/releases/download/v1.5.1/cronos_1.5.1-testnet_Linux_x86_64.tar.gz && tar -xvf cronos_1.5.1-testnet_Linux_x86_64.tar.gz \
+RUN cd /tmp && wget https://github.com/crypto-org-chain/cronos/releases/download/v1.5.1/cronos_1.5.1-testnet_Linux_x86_64.tar.gz && tar -xvf cronos_1.5.1-testnet_Linux_x86_64.tar.gz \
🧰 Tools
🪛 Checkov (3.2.334)

[high] 11-12: Ensure that certificate validation isn't disabled with wget

(CKV2_DOCKER_3)

🤖 Prompt for AI Agents
In Dockerfile around lines 11-12, the wget invocation disables TLS certificate
validation via --no-check-certificate which exposes the build to MITM and
supply-chain attacks; remove the --no-check-certificate flag and instead fetch
the release over HTTPS with normal certificate checks enabled, and add
deterministic verification by downloading or embedding a trusted
checksum/signature (e.g., SHA256 or GPG signature) for the tarball and
validating it in the Dockerfile before extracting; ensure the build fails if the
checksum/signature does not match.


# Set permissions
RUN chown -R cronos:cronos /home/cronos && chmod 1777 /tmp
Expand Down