HomeAbout Us A-Z IndexSearch * Contact Us Register LoginPress Shop

The Open Brand -- Problem Reporting and Interpretations System


Problem Report 0673 Details

Help Show help | Quick Search | Submit a Test Suite Support Request | Click here to view your privileges

This page provides all information on Problem Report 0673.


Report 0673 Actions


    Problem Report Number 0673
    Submitter's Classification Specification problem
    State Resolved
    Resolution Permanent Interpretation (PIN)
    Problem Resolution ID PIN.X.0066
    Raised 1970-01-01 08:00
    Updated 2003-03-13 08:00
    Published 1999-05-10 08:00
    Product Standard Commands and Utilities V2 (UNIX 95)
    Certification Program The Open Brand certification program
    Test Suite VSC version 5.0.2
    Test Identification POSIX.cmd/mkdir 31
    Specification Commands and Utilities Issue 4 Version 2
    Location in Spec See Problem Text
    Problem Summary PIN4C.00048 This test may fail on implementations since the -m mode interaction with umask has been ruled unclear.
    Problem Text
    Mkdir's interaction with the current umask setting is undefined,
    therefore, we request a temporary interpretation allowing historical
    practice.

    mkdir assertion #31:
    umask 26
    mkdir -m -wx dirmkdir0311.tmp

    The VSC5.0.2 formula and result:
    rwxrwxrwx & ~(-wx-wx-wx & ~(----w-rw-)) =
    rwxrwxrwx & ~(-wx--x--x) = r--rw-rw-

    Using the following formula we obtain the VSC4.1.6 result:
    (rwxrwxrwx & ~(----w-rw-)) & ~(-wx-wx-wx & ~(----w-rw-)) =
    (rwxr-x--x) & ~(-wx--x--x) = r--r-----
    The umask is applied to the initial permissions as well as
    to the -m option-argument.

    Note: the VSC5.0.2 testsuite was the first suite we ran after VSC4.1.6
    testing. Therefore, we do not know in which testsuite the above
    described change first occurred.
    Test Output
    ***********************************************************************
    /tset/POSIX.cmd/mkdir/mkdir.ex 1 Failed


    Test Information:
    Assertion #31 (A): When a single mode clause has op '-' and
    <LC> only param are specified
    Note: The behavior associated with this assertion is curre
    <LC> ntly
    the subject of an IEEE POSIX.2 interpretation request and
    <LC> may
    change in a future revision of POSIX.2.
    Command failed: 'expr "Xdr--r-----" : 'Xdr-[A-Z-]rw[A-Z-]r
    <LC> w[A-Z-]' >/dev/null 2>&1'

    ***********************************************************************


    Review Information

    Review Type TSMA Review
    Start Date null
    Completed null
    Status Complete
    Review Recommendation No Resolution Given
    Review Response
    A permanent interpretation is recommended.

    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.


    Review Type SA Review
    Start Date null
    Completed null
    Status Complete
    Review Resolution Permanent Interpretation (PIN)
    Review Conclusion
    A Permanent Interpretation is granted.

    Problem Reporting System Options:

     

    Back   


Contact the Certification Authority