Skip to content

Commit 98e7904

Browse files
[universal] Address GHSA-jm77-qphf-c4w8 and GHSA-r9hx-vwmv-q579 vulnerabilities (#753)
* Patch GHSA-jm77-qphf-c4w8 * Patch GHSA-r9hx-vwmv-q579 * Update tests - Update check for `cryptography` package; - Rename tests to make them more explicit; - Update tests to use a separate conda's environment; * Restart checks * Restart checks
1 parent d1d821b commit 98e7904

File tree

3 files changed

+7
-6
lines changed

3 files changed

+7
-6
lines changed

src/universal/.devcontainer/local-features/patch-conda/install.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,10 @@ sudo_if /opt/conda/bin/python3 -m pip install --upgrade pip
5050
# Temporary: Upgrade python packages due to security vulnerabilities
5151
# They are installed by the conda feature and Conda distribution does not have the patches.
5252

53-
# https://github.com/advisories/GHSA-5cpq-8wj7-hf2v
53+
# pyopenssl should be updated to be compatible with latest version of cryptography
5454
update_conda_package pyopenssl "23.2.0"
55-
update_conda_package cryptography "41.0.2"
55+
# https://github.com/advisories/GHSA-jm77-qphf-c4w8
56+
update_conda_package cryptography "41.0.3"
5657

5758
# https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2023-32681
5859
update_conda_package requests "2.31.0"

src/universal/.devcontainer/local-features/patch-python/install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ update_package() {
3434
PACKAGE=$2
3535

3636
sudo_if "$PYTHON_PATH -m pip uninstall --yes $PACKAGE"
37-
sudo_if "$PYTHON_PATH -m pip install --user --upgrade --no-cache-dir $PACKAGE"
37+
sudo_if "$PYTHON_PATH -m pip install --upgrade --no-cache-dir $PACKAGE"
3838
}
3939

4040
# Temporary: Upgrade python packages due to security vulnerabilities

src/universal/test-project/test.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -196,13 +196,13 @@ checkPythonPackageVersion "/usr/local/python/3.9.*/bin/python" "setuptools" "65.
196196

197197
## Conda Python
198198
checkCondaPackageVersion "requests" "2.31.0"
199-
checkCondaPackageVersion "cryptography" "41.0.2"
199+
checkCondaPackageVersion "cryptography" "41.0.3"
200200
checkCondaPackageVersion "pyopenssl" "23.2.0"
201201

202202
## Test Conda
203203
check "conda-update-conda" bash -c "conda update -y conda"
204-
check "conda-install" bash -c "conda install -c conda-forge --yes tensorflow"
205-
check "conda-install" bash -c "conda install -c conda-forge --yes pytorch"
204+
check "conda-install-tensorflow" bash -c "conda create --name test-env -c conda-forge --yes tensorflow"
205+
check "conda-install-pytorch" bash -c "conda create --name test-env -c conda-forge --yes pytorch"
206206

207207
# Report result
208208
reportResults

0 commit comments

Comments
 (0)