Austin Group Defect Tracker

Aardvark Mark IV


Viewing Issue Simple Details Jump to Notes ] Issue History ] Print ]
ID Category Severity Type Date Submitted Last Update
0001364 [Issue 8 drafts] Shell and Utilities Comment Clarification Requested 2020-07-06 10:45 2020-07-06 10:46
Reporter geoffclare View Status public  
Assigned To
Priority normal Resolution Open  
Status New   Product Version Draft 1
Name Geoff Clare
Organization The Open Group
User Reference
Section 2.7.2 Redirecting Output
Page Number 2287
Line Number 73909
Final Accepted Text
Summary 0001364: use of noclobber with files in /tmp
Description Some time after bug 0001016 was approved as an interpretation, Note: 0003655 was added in which McDutchie observed that the statement "Performing these operations atomically ensures that the creation of lock files and unique (often temporary) files is reliable" is not true if the file is in a public directory such as /tmp, since another user could create a FIFO or device file with the same name.
Desired Action On page 2287 line 73900 section 2.7.2, and
page 3587 line 124071 section C.2.7.2, add to the "Notes to Reviewers":
If option 2 is adopted in a future draft, note that the change from <URL> will need to be reapplied to the option 2 text.

where <URL> is the URL for this bug.

On page 2287 line 73909 section 2.7.2, change:
Performing these operations atomically ensures that the creation of lock files and unique (often temporary) files is reliable.
to:
Performing these operations atomically ensures that the creation of lock files and unique (often temporary) files is reliable, provided the files are created in a private directory (i.e. not in /tmp or similar).

On page 3588 line 124127 section C.2.7.2, change:
The standard developers consider this to be of less importance than ensuring that the creation of lock files is reliable.
to:
The standard developers consider this to be of less importance than ensuring that the creation of lock files is reliable (in a private directory).

Creation of lock files and unique (often temporary) files with noclobber set is only reliable provided the files are created in a private directory. If a directory such as /tmp is used where other users can create files, then another user could create a FIFO (or a device file, given sufficient privilege) with the same name, causing multiple redirections with noclobber set to open the existing non-regular file instead of one succeeding and the others failing.

Tags No tags attached.
Attached Files

- Relationships
related to 0001016Applied 1003.1(2013)/Issue7+TC1 race condition with set -C 

There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2020-07-06 10:45 geoffclare New Issue
2020-07-06 10:45 geoffclare Name => Geoff Clare
2020-07-06 10:45 geoffclare Organization => The Open Group
2020-07-06 10:45 geoffclare Section => 2.7.2 Redirecting Output
2020-07-06 10:45 geoffclare Page Number => 2287
2020-07-06 10:45 geoffclare Line Number => 73909
2020-07-06 10:46 geoffclare Relationship added related to 0001016


Mantis 1.1.6[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker