Skip to content
Merged
Show file tree
Hide file tree
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
7 changes: 7 additions & 0 deletions Dockerfile.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,13 @@ RUN pip freeze | grep -E 'tensorflow|keras|torch|jax' > /colab_requirements.txt
RUN cat /colab_requirements.txt >> /requirements.txt
RUN cat /kaggle_requirements.txt >> /requirements.txt

# GHSA-hq85-5cpj-mr62: uv < 0.13.4 vendors a CA bundle that trusts emSign intermediates with compromised keys.
# Upgrade it first so the patched uv performs all subsequent installs.
# The base image's uv may not be the pip-managed one, so point every uv on PATH at the new binary.
RUN uv pip install --system --no-cache "uv>=0.13.4" && \
NEW_UV="$(python -c 'import uv; print(uv.find_uv_bin())')" && \
for old in $(which -a uv); do [ "$old" -ef "$NEW_UV" ] || ln -sf "$NEW_UV" "$old"; done

# Install Kaggle packages
RUN uv pip install --system --no-cache -r /requirements.txt

Expand Down
4 changes: 4 additions & 0 deletions kaggle_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ bayesian-optimization
boto3
catboost
category-encoders
# GHSA-6q48-6c7w-9gw2: older bundles trust emSign intermediates with compromised keys.
certifi>=2026.10.19
cesium
comm
cytoolz
Expand Down Expand Up @@ -108,6 +110,8 @@ pdf2image
# The base image ships pillow 11.3; pin up to a newer release.
# Remove once the base image ships >=12.2 itself.
pillow>=12.2
# pip < 26.2.2 always loads its vendored certifi, so it needs the GHSA-6q48-6c7w-9gw2 fix separately.
pip>=26.2.2
plotly-express
pudb
pyLDAvis
Expand Down
22 changes: 22 additions & 0 deletions tests/test_certifi.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import subprocess
import unittest

import certifi
import pip
from packaging.version import Version


class TestCertifi(unittest.TestCase):
# GHSA-6q48-6c7w-9gw2: emSign ECC Root CA - G3 intermediates have compromised keys.
def test_emsign_ecc_g3_root_removed(self):
self.assertGreaterEqual(Version(certifi.__version__), Version("2026.10.19"))
with open(certifi.where()) as f:
self.assertNotIn("emSign ECC Root CA - G3", f.read())

def test_pip_vendored_certifi_patched(self):
self.assertGreaterEqual(Version(pip.__version__), Version("26.2.2"))

# GHSA-hq85-5cpj-mr62: uv vendors its own CA bundle.
def test_uv_vendored_certs_patched(self):
version = subprocess.check_output(["uv", "--version"], text=True).split()[1]
self.assertGreaterEqual(Version(version), Version("0.13.4"))
Loading