Skip to content

Commit

Permalink
Missing docs def
Browse files Browse the repository at this point in the history
  • Loading branch information
barneygale committed Aug 3, 2024
1 parent b84b0e0 commit 1e5ad10
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions Doc/library/pathlib.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1671,13 +1671,20 @@ Copying, renaming and deleting
.. note::

When deleting non-empty directories on platforms that lack the necessary
file descriptor-based functions, the :meth:`Path.delete` implementation
file descriptor-based functions, the :meth:`~Path.delete` implementation
is susceptible to a symlink attack: given proper timing and
circumstances, attackers can manipulate symlinks on the filesystem to
delete files they would not be able to access otherwise. Applications
can use the :data:`Path.delete.avoids_symlink_attacks` method attribute
can use the :data:`~Path.delete.avoids_symlink_attacks` method attribute
to determine whether the implementation is immune to this attack.

.. attribute:: delete.avoids_symlink_attacks

Indicates whether the current platform and implementation provides a
symlink attack resistant version of :meth:`~Path.delete`. Currently
this is only true for platforms supporting fd-based directory access
functions.

.. versionadded:: 3.14


Expand Down

0 comments on commit 1e5ad10

Please sign in to comment.