summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorR David Murray <rdmurray@bitdance.com>2013-09-18 01:28:17 (GMT)
committerR David Murray <rdmurray@bitdance.com>2013-09-18 01:28:17 (GMT)
commit4750fa8369407a2a77d40f5aa3e681e80ca08f42 (patch)
treefc36fa0a52f36670eece4bf9deb32c4e83066ec4 /Doc
parent935349406aeb9d43fecea447f0309ce63ed3a406 (diff)
parentfb9dc0b3ae1e048c89988fcf4c570cd73da2f455 (diff)
downloadcpython-4750fa8369407a2a77d40f5aa3e681e80ca08f42.zip
cpython-4750fa8369407a2a77d40f5aa3e681e80ca08f42.tar.gz
cpython-4750fa8369407a2a77d40f5aa3e681e80ca08f42.tar.bz2
Merge #14984: On POSIX, enforce permissions when reading default .netrc.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/netrc.rst8
1 files changed, 8 insertions, 0 deletions
diff --git a/Doc/library/netrc.rst b/Doc/library/netrc.rst
index 3f38cbc..23ffed6 100644
--- a/Doc/library/netrc.rst
+++ b/Doc/library/netrc.rst
@@ -22,6 +22,14 @@ the Unix :program:`ftp` program and other FTP clients.
no argument is given, the file :file:`.netrc` in the user's home directory will
be read. Parse errors will raise :exc:`NetrcParseError` with diagnostic
information including the file name, line number, and terminating token.
+ If no argument is specified on a POSIX system, the presence of passwords in
+ the :file:`.netrc` file will raise a :exc:`NetrcParseError` if the file
+ ownership or permissions are insecure (owned by a user other than the user
+ running the process, or accessible for read or write by any other user).
+ This implements security behavior equivalent to that of ftp and other
+ programs that use :file:`.netrc`.
+
+ .. versionchanged:: 3.4 Added the POSIX permission check.
.. exception:: NetrcParseError