未验证 提交 dfd7ebdc 编写于 作者: Z Zhenxu Ke 提交者: GitHub

Add shasum verification to Codecov Bash Uploader (#6843)

According to https://about.codecov.io/security-update/
上级 9de37243
......@@ -41,4 +41,13 @@ for exec_data in "${JACOCO_HOME}"/*.exec; do
"${JACOCO_HOME}"/"$exec_data".exec
done
bash <(curl -s https://codecov.io/bash) -X fix -f /tmp/report-*.xml || true
# Download codecov bash uploader and verify the sha sums before using it.
curl -s https://codecov.io/bash > codecov
VERSION=$(grep -o 'VERSION=\"[0-9\.]*\"' codecov | cut -d'"' -f2)
for i in 1 256 512
do
shasum -a $i -c --ignore-missing <(curl -s "https://raw.githubusercontent.com/codecov/codecov-bash/${VERSION}/SHA${i}SUM") ||
shasum -a $i -c <(curl -s "https://raw.githubusercontent.com/codecov/codecov-bash/${VERSION}/SHA${i}SUM")
done
bash codecov -X fix -f /tmp/report-*.xml || true
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册