{"id":"GHSA-qf34-qpr4-5pph","summary":"docusaurus-plugin-content-gists vulnerability exposes GitHub Personal Access Token","details":"## GitHub Personal Access Token Exposure in docusaurus-plugin-content-gists\n\n### Summary\n\ndocusaurus-plugin-content-gists versions prior to 4.0.0 are vulnerable to exposing GitHub Personal Access Tokens in production build artifacts when passed through plugin configuration options. The token, intended for build-time API access only, is inadvertently included in client-side JavaScript bundles, making it accessible to anyone who can view the website's source code.\n\n### Affected Versions\n\n- All versions \u003c 4.0.0\n\n### Patched Versions\n\n- Version 4.0.0 and later\n\n### Impact\n\nWhen using the affected versions with the recommended configuration pattern:\n\n```javascript\nplugins: [\n  [\n    'docusaurus-plugin-content-gists',\n    {\n      personalAccessToken: process.env.GITHUB_PERSONAL_ACCESS_TOKEN,\n    },\n  ],\n]\n```\n\nThe GitHub Personal Access Token is included in the webpack bundle and exposed in production builds at:\n- `/build/assets/js/main.[hash].js`\n\nThis allows malicious actors to:\n- Extract the GitHub Personal Access Token from the website's JavaScript files\n- Use the stolen token to access the token owner's GitHub account with the granted permissions\n- Potentially access private gists, repositories, or perform other actions depending on the token's scope\n\n## Mitigation steps\n\n  1. Immediately revoke access to the GitHub PAT that was used: https://github.com/settings/tokens\n\n### Migration steps\n\n  1. Update to version 4.0.0+: `npm install docusaurus-plugin-content-gists@^4.0.0`\n  3. Remove `personalAccessToken` from your plugin configuration\n  4. Ensure `GH_PERSONAL_ACCESS_TOKEN` is set in your build environment","aliases":["CVE-2025-53624"],"modified":"2025-07-09T23:12:26.754530Z","published":"2025-07-09T22:40:06Z","database_specific":{"github_reviewed":true,"github_reviewed_at":"2025-07-09T22:40:06Z","nvd_published_at":"2025-07-09T21:15:27Z","cwe_ids":["CWE-200"],"severity":"CRITICAL"},"references":[{"type":"WEB","url":"https://github.com/webbertakken/docusaurus-plugin-content-gists/security/advisories/GHSA-qf34-qpr4-5pph"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-53624"},{"type":"WEB","url":"https://github.com/webbertakken/docusaurus-plugin-content-gists/commit/8d4230b82412edb215ddfa9e609d178510a5fe31"},{"type":"PACKAGE","url":"https://github.com/webbertakken/docusaurus-plugin-content-gists"}],"affected":[{"package":{"name":"docusaurus-plugin-content-gists","ecosystem":"npm","purl":"pkg:npm/docusaurus-plugin-content-gists"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"4.0.0"}]}],"database_specific":{"source":"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2025/07/GHSA-qf34-qpr4-5pph/GHSA-qf34-qpr4-5pph.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H"}]}