|
Home About Us A-Z Index Search * Contact Us Register Login Press ShopThe Open Brand -- Problem Reporting and Interpretations System |
Problem Report 0767 Details
Show help | Quick Search | Submit a Test Suite Support Request | Click here to view your privileges
This page provides all information on Problem Report 0767.
Report 0767 Actions
Problem Report Number 0767 Submitter's Classification Specification problem State Resolved Resolution Temporary Interpretation (TIN) Problem Resolution ID TIN.X.0058 Raised 1970-01-01 08:00 Updated 2003-03-13 08:00 Published 1995-08-24 08:00 Product Standard Commands and Utilities V2 (UNIX 95) Certification Program The Open Brand certification program Test Suite VSC version 4.1.4 Test Identification POSIX.cmd/mkdir 24,25,26,27 Specification Commands and Utilities Issue 4 Version 2 Location in Spec See Problem Text Problem Summary TIN4C.00003 The tests expect that the mkdir -m command will be affected by the current setting of umask. This is not necessary. Problem Text
The behavior of the -m option and its interaction with the umask value
was recently the subject of an interpretation (PASC 1003.2-92 #67)
with the resolution being that the standard was unclear on the matter
and would be referred to the sponsor.Test Output
Assertion #24 (A): When a single mode clause starts with 'u' and nonzero umask
Note: The behavior associated with this assertion is currently
the subject of an IEEE POSIX.2 interpretation request and may
change in a future revision of POSIX.2.
Note: The behavior associated with this assertion is expected
to change in a future revision of POSIX.2.
Command failed: 'expr "Xdr-xr-xrwx" : 'Xdrw[a-z]r-[a-z]rw[a-z]'
Assertion Result: FAIL
Assertion #25 (A): When a single mode clause starts with 'g' and nonzero umask
Note: The behavior associated with this assertion is currently
the subject of an IEEE POSIX.2 interpretation request and may
change in a future revision of POSIX.2.
Command failed: 'expr "Xdr-xr-xrwx" : 'Xdr-[a-z]rw[a-z]rw[a-z]'
Assertion Result: FAIL
Assertion #26 (A): When a single mode clause starts with 'o' and nonzero umask
Note: The behavior associated with this assertion is currently
the subject of an IEEE POSIX.2 interpretation request and may
change in a future revision of POSIX.2.
Command failed: 'expr "Xdrwxr-xr-x" : 'Xdrw[a-z]r-[a-z]rw[a-z]'
Assertion Result: FAIL
Assertion #27 (A): When a single mode clause has op '+' and who and
param are specified
Note: The behavior associated with this assertion is currently
the subject of an IEEE POSIX.2 interpretation request and may
change in a future revision of POSIX.2.
Command failed: 'expr "Xdrwxr-x--x" : 'Xdrw[a-z]r-[a-z]-w[a-z]'
Assertion Result: FAILReview Information
Review Type TSMA Review Start Date null Completed null Status Complete Review Recommendation No Resolution Given Review Response
The pasc-1003.2-67 interpretation request states
Should mkdir -m mode utilize the current umask in setting permissions?
I would propose that it does not.
The test assertion in 2003.2 Draft 9 say it should based on the
DESCRIPTION for mkdir which says it "shall perform actions equivalent
to the POSIX.1 mkdir()"
However, existing practise in System V (on which the rationale
says this option was added) is to set the permission to the explict
value specified by the mode argument to -m; and the text in lines
6950-6956 state that "The mode option-argument shall be the same as
the mode operand defined for the chmod utility". The chmod utility
ignores the umask.
So for an example, say
$ umask 22
$ mkdir -m 456 foodir
$ ls -ld
gives (on System V)
dr--r-xrw- 2 andrew relx 512 Jul 1 04:29 foodir
whereas the 2003.2 draft wants
dr--r-xr-- 2 andrew relx 512 Jul 1 04:29 foodir
The System V behaviour seems more inituitive as a user, and usage has
been to, in a single command set the mode explicitly with the -m option,
rather than call umask followed by mkdir -m xxx.
My understanding of the rationale text lines 7184-7187 "For example,
by default, the mode of the directory is affected by the file mode
creation mask" is that this does not apply to the -m case, which
is not the default.
The official repsonse is
The standard is unclear on this issue, and no conformance distinction can
be made between alternative implementations based on this. This is being
referred to the sponsor.
Anticipating future alignment of the POSIX 2003.2 methods which
the tests are based on with pasc-1003.2-96 a Temporary
Interpretation is recommended.
Our opinion is this interpretation renders mkdir's interaction
with the current umask undefined when the -m option is used.
Anticipating future alignment of the POSIX 2003.2 methods which
the tests listed above are based on with pasc-1003.2-67 a Temporary
Interpretation is recommended.
Review Type SA Review Start Date null Completed null Status Complete Review Resolution Temporary Interpretation (TIN) Review Conclusion
A Temporary Interpretation is granted.
Problem Reporting System Options:
- View Report 0767
- List All PRs
- Search Reports
- Email the System Administrator
- View the The Open Brand Interpretations Database User Manual
Contact the Certification Authority