CVE-2020-5262: GitHub personal access token leaking into temporary EasyBuild (debug) logs
(updated )
The GitHub Personal Access Token (PAT) used by EasyBuild for the GitHub integration features (like --new-pr
, --from-pr
, etc.) is shown in plain text in EasyBuild debug log files.
Scope:
- the log message only appears in the top-level log file, not in the individual software installation logs (see https://easybuild.readthedocs.io/en/latest/Logfiles.html);
- as a consequence, tokens are not included in the partial log files that are uploaded into a gist when using
--upload-test-report
in combination with--from-pr
, nor in the installation logs that are copied to the software installation directories;
- the message is only logged when using
--debug
, so it will not appear when using the default EasyBuild configuration (only info messages are logged by default); - the log message is triggered via
--from-pr
, but also via various other GitHub integration options like--new-pr
,--merge-pr
,--close-pr
, etc., but usually only appears in the temporary log file that is cleaned up automatically as soon as eb completes successfully; - you may have several debug log files that include your GitHub token in
/tmp
(or a different location if you’ve set the--tmpdir
EasyBuild configuration option) on the systems where you use EasyBuild, but they are located in a subdirectory that is only accessible to your account (permissions set to 700); - the only way that a log file that may include your token could have been made public is if you shared it yourself, for example by copying the contents of the log file into a gist manually, or by sending a log file to someone;
- for log files uploaded to GitHub, your token would be revoked automatically when GitHub notices it;
References
- github.com/advisories/GHSA-2wx6-wc87-rmjm
- github.com/easybuilders/easybuild-framework
- github.com/easybuilders/easybuild-framework/commit/210743d0e3618a8ac0a56eb9c0f4fa4fd8ae53b9
- github.com/easybuilders/easybuild-framework/pull/3248
- github.com/easybuilders/easybuild-framework/pull/3249
- github.com/easybuilders/easybuild-framework/security/advisories/GHSA-2wx6-wc87-rmjm
- github.com/pypa/advisory-database/tree/main/vulns/easybuild-framework/PYSEC-2020-41.yaml
- github.com/pypa/advisory-database/tree/main/vulns/easybuild/PYSEC-2020-268.yaml
- nvd.nist.gov/vuln/detail/CVE-2020-5262
Detect and mitigate CVE-2020-5262 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →