{"id":"CVE-2023-41057","aliases":["CVE-2023-41057","GHSA-xc27-f9q3-4448","PYSEC-2026-1456"],"related":[],"kind":"vulnerability","state":"published","title":"Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in hyper-bump-it","summary":"hyper-bump-it is a command line tool for updating the version in project files.`hyper-bump-it` reads a file glob pattern from the configuration file. That is combined with the project root directory to construct a full glob pattern that is used to find files that should be edited. These matched files should be contained within the project root directory, but that is not checked. This could result in changes being written to files outside of the project. The default behaviour of `hyper-bump-it` is to display the planned changes and prompt the user for confirmation before editing any files. However, the configuration file provides a field that can be used cause files to be edited without displaying the prompt. This issue has been fixed in release version 0.5.1. Users are advised to upgrade. Users that are unable to update from vulnerable versions, executing `hyper-bump-it` with the `--interactive` command line argument will ensure that all planned changes are displayed and prompt the user for confirmation before editing any files, even if the configuration file contains `show_confirm_prompt=true`.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"hyper-bump-it is a command line tool for updating the version in project files.`hyper-bump-it` reads a file glob pattern from the configuration file. That is combined with the project root directory to construct a full glob pattern that is used to find files that should be edited. These matched files should be contained within the project root directory, but that is not checked. This could result in changes being written to files outside of the project. The default behaviour of `hyper-bump-it` is to display the planned changes and prompt the user for confirmation before editing any files. However, the configuration file provides a field that can be used cause files to be edited without displaying the prompt. This issue has been fixed in release version 0.5.1. Users are advised to upgrade. Users that are unable to update from vulnerable versions, executing `hyper-bump-it` with the `--interactive` command line argument will ensure that all planned changes are displayed and prompt the user for confirmation before editing any files, even if the configuration file contains `show_confirm_prompt=true`.","source":"cvelist"},{"lang":"en","text":"### Summary\n`hyper-bump-it` reads a file glob pattern from the configuration file. That is combined with the project root directory to construct a full glob pattern that is used to find files that should be edited. These matched files should be contained within the project root directory, but that is not checked. This could result in changes being written to files outside of the project.\n\nThe default behaviour of `hyper-bump-it` is to display the planned changes and prompt the user for confirmation before editing any files. However, the configuration file provides a field that can be used cause files to be edited without displaying the prompt.\n\n### Details\n\nThe vulnerability is present in \n\nhttps://github.com/plannigan/hyper-bump-it/blob/49c726201bbdc02c052302e03fd907d2170e1f47/hyper_bump_it/_hyper_bump_it/files.py#L35\n\nThat code joins the project root directory with a string read from the configuration file without checking if the final path is located outside the project root directory.\n\nThe following configuration file contents would cause `hyper-bump-it` to replace every instance of \"hello\" in every file adjacent to the project root directory with \"world\". The line setting  `show_confirm_prompt` to `false` is not required, but will result in the user file edits to occur without the user having a chance to reject the changes (The fact that changes happened would still be displayed). \n\n```toml\n[hyper-bump-it]\ncurrent_version = \"1.2.3\"\nshow_confirm_prompt=false\n\n[[hyper-bump-it.files]]\nfile_glob = \"../*\"\nsearch_format_pattern = \"hello\"\nreplace_format_pattern = \"world\"\n```\n\n### Patches\nA fix that been released as part of v0.5.1. The changes can be view as part of  PR #307.\n\n### Workarounds\nUsers that are unable to update from vulnerable versions, executing `hyper-bump-it` with the `--interactive` command line argument will ensure that all planned changes are displayed and prompt the user for confirmation before editing any files, even if the configuration file contains `show_confirm_prompt=true`.","format":"markdown","source":"ghsa"},{"lang":"es","text":"hyper-bump-it es una herramienta de línea de comandos para actualizar la versión de los archivos del proyecto. Hyper-bump-it lee un patrón glob del archivo de configuración. Esto se combina con el directorio raíz del proyecto para construir un patrón glob completo que se utiliza para encontrar los archivos que deben ser editados. Estos archivos deben estar dentro del directorio raíz del proyecto, pero esto no se comprueba. Esto podría provocar que los cambios se escribieran en ficheros fuera del proyecto. El comportamiento por defecto de hyper-bump-it es mostrar los cambios planeados y pedir confirmación al usuario antes de editar cualquier fichero. Sin embargo, el fichero de configuración proporciona un campo que puede utilizarse para editar ficheros sin que aparezca la pregunta. Este problema se ha solucionado en la versión 0.5.1. Se recomienda a los usuarios que actualicen. Los usuarios que no puedan actualizar desde versiones vulnerables, ejecutando hyper-bump-it con el argumento de línea de comandos \"--interactive\" se asegurarán de que se muestren todos los cambios planificados y pedirán confirmación al usuario antes de editar cualquier archivo, incluso si el archivo de configuración contiene \"show_confirm_prompt=true\".","source":"nvd"}],"published":"2023-09-04T17:02:36.000Z","modified":"2026-09-10T03:50:03.462Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N","score":5.5,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N","score":3.3,"rating":"LOW"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N","score":5.5,"rating":"MEDIUM"},{"scorer":"PyPA Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N","score":3.3,"rating":"LOW"}],"cwes":["CWE-22"],"affected":[{"ranges":[{"version":"< 0.5.1","status":"affected"}],"vendor":"plannigan","product":"hyper-bump-it","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"0.5.1"}],"ecosystem":"PyPI","package":"hyper-bump-it","purl":"pkg:pypi/hyper-bump-it","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"0.5.1"}],"vendor":"plannigan","product":"hyper_bump_it","cpe":"cpe:2.3:a:plannigan:hyper_bump_it:*:*:*:*:*:python:*:*","source":"nvd"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"0.5.1"}],"ecosystem":"PyPI","package":"hyper-bump-it","purl":"pkg:pypi/hyper-bump-it","source":"pysec"}],"references":[{"url":"https://github.com/plannigan/hyper-bump-it/security/advisories/GHSA-xc27-f9q3-4448","tags":["exploit","patch","vendor-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/plannigan/hyper-bump-it/pull/307","tags":["patch","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2023-41057","tags":["advisory"],"sources":["ghsa","pysec"]},{"url":"https://github.com/plannigan/hyper-bump-it","tags":["package"],"sources":["ghsa","pysec"]},{"url":"https://pypi.org/project/hyper-bump-it","tags":["package"],"sources":["pysec"]},{"url":"https://github.com/advisories/GHSA-xc27-f9q3-4448","tags":["advisory"],"sources":["pysec"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2024-09-27T14:34:53.311Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2023-41057","url":"https://www.cve.org/CVERecord?id=CVE-2023-41057","licence":"CVE Terms of Use","modified":"2024-09-27T15:22:50.458Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-xc27-f9q3-4448","url":"https://github.com/advisories/GHSA-xc27-f9q3-4448","licence":"CC-BY-4.0","modified":"2026-09-10T03:50:03.462Z"},{"source":"nvd","name":"NVD","id":"CVE-2023-41057","url":"https://nvd.nist.gov/vuln/detail/CVE-2023-41057","licence":"Public domain","modified":"2026-06-17T06:20:20.680Z"},{"source":"pysec","name":"PyPA Advisory Database","id":"PYSEC-2026-1456","url":"https://osv.dev/vulnerability/PYSEC-2026-1456","licence":"CC-BY-4.0","modified":"2026-07-07T17:47:44.637Z"}],"updatedAt":"2026-11-25T22:58:27.586Z","epss":{"score":0.00365,"percentile":0.32339,"date":"2026-12-01T12:00:22.000Z"}}