Skip to content

Commit c3eb552

Browse files
[miniconda] Update requests package due to GHSA-j8r2-6x86-q33q (devcontainers#680)
* Address GHSA-j8r2-6x86-q33q * Add tests
1 parent 4913fb2 commit c3eb552

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

src/miniconda/.devcontainer/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@ RUN if [ -f "/tmp/conda-tmp/environment.yml" ]; then umask 0002 && /opt/conda/bi
4444
RUN conda install \
4545
# https://github.com/pyca/cryptography/security/advisories/GHSA-5cpq-8wj7-hf2v
4646
pyopenssl=23.2.0 \
47-
cryptography=41.0.2
47+
cryptography=41.0.2 \
48+
# https://github.com/advisories/GHSA-j8r2-6x86-q33q
49+
requests=2.31.0
4850

4951
# [Optional] Uncomment this section to install additional OS packages.
5052
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \

src/miniconda/test-project/test-utils.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,6 @@ checkCondaPackageVersion()
177177
{
178178
PACKAGE=$1
179179
REQUIRED_VERSION=$2
180-
current_version=$(conda list "${PACKAGE}" | grep -w "${PACKAGE}" | awk '{print $2}')
180+
current_version=$(conda list "${PACKAGE}" | grep -E "^${PACKAGE}\s" | awk '{print $2}')
181181
check-version-ge "conda-${PACKAGE}-requirement" "${current_version}" "${REQUIRED_VERSION}"
182182
}

src/miniconda/test-project/test.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ checkCondaPackageVersion "cryptography" "41.0.0"
2626
checkCondaPackageVersion "pyopenssl" "23.2.0"
2727
checkCondaPackageVersion "setuptools" "65.5.1"
2828
checkCondaPackageVersion "wheel" "0.38.1"
29+
checkCondaPackageVersion "requests" "2.31.0"
2930

3031
check "conda-update-conda" bash -c "conda update -y conda"
3132
check "conda-install-tensorflow" bash -c "conda install -c conda-forge --yes tensorflow"

0 commit comments

Comments
 (0)