File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -359,3 +359,37 @@ Using :samp:`uv add {PACKAGE}`, you can add further dependencies to your
359359project. This adds the package to the ``dependencies `` section of the
360360:file: `pyproject.toml ` file and writes the exact variant to the :file: `uv.lock `
361361file.
362+
363+ .. _uv-audit :
364+
365+ Vulnerability and malware checks
366+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
367+
368+ ``uv audit `` is a new command introduced in uv≥0.11.19 that checks the
369+ dependencies in your project for known vulnerabilities in the `OSV
370+ <https://osv.dev> `_ database and ‘undesirable’ project statuses, such as
371+ *deprecated *:
372+
373+ .. code-block :: console
374+
375+ $ uv audit
376+ warning: `uv audit` is experimental and may change without warning. Pass `--preview-features audit-command` to disable this warning.
377+ Resolved 115 packages in 16ms
378+ Found 12 known vulnerabilities and no adverse project statuses in 114 packages
379+
380+ Vulnerabilities:
381+
382+ idna 3.12 has 1 known vulnerability:
383+ - GHSA-65pc-fj4g-8rjx: Internationalized Domain Names in Applications (IDNA): Specially crafted inputs to idna.encode() can bypass CVE-2024-3651 fix
384+ Fixed in: 3.15
385+ Advisory information: https://github.com/kjd/idna/security/advisories/GHSA-65pc-fj4g-8rjx
386+ …
387+
388+ ``uv add ``, ``uv sync ``, and so on can now be run during every synchronisation
389+ process to check for previously identified malware. This feature is not enabled
390+ by default, but it can be easily enabled by setting ``UV_MALWARE_CHECK=1 `` in
391+ the shell.
392+
393+ .. seealso ::
394+ * `uv audit <https://docs.astral.sh/uv/reference/cli/#uv-audit >`_
395+ * `uv audit settings <https://docs.astral.sh/uv/reference/settings/#audit >`_
You can’t perform that action at this time.
0 commit comments