SUMMARY: ipcs perission denied

From: John W. Cieply (JWC@icf.hrb.com)
Date: Wed May 12 1993 - 15:27:48 CDT


I seem ask the question at the right time. Sun came out with a patch to
this problem on Friday, May 8, 1993. I'm in the process of obtaining this
patch. Thanks to everone that replied:
        Steve Hanson <hanson@pogo.fnal.gov>
        dtb@otto.bf.rmit.OZ.au (David Bath)
        Geoff Halprin <Geoff.Halprin@fulcrum.oz.au>
        cc_koper@rcvie.co.at (Koper Zangocyan)
        leclerc@epsu10.Clamart.EST.SLB.com (Leclerc Francois)
        Andy Bartram - TECNODATA <ABARTRAM%ESOC.BITNET@vm.gmd.de>
        Robert Andersson <robert@gar.no>
        David Sansom <david@camscan.co.uk>
        Bruce Rossiter <AROSSITE@us.oracle.com>
        katz@rpal.rockwell.com (Morry Katz)
        pauline@uniq.com.au (Pauline van Winsen - Uniq Professional Services)
        jamest@sybase.com (James Terry)

The following is the copy of the patch description.

----- Begin Included Message -----

Patch-ID# 100650-02
Synopsis: 4.1.1,4.1.2,4.1.3: ipcs aborts with "shmctl: Permission denied"
Date: May/07/93

SunOS release: 4.1.1, 4.1.2, 4.1.3

Unbundled Product:

Unbundled Release:

Topic: This patch fixes some anomalies in the way 4.1.x ipcs handles
       checking permissions of shared memory segments and semaphores

BugId's fixed with this patch: 1046490

Changes incorporated in this version: ported to 4.1.3

Architectures for which this patch is available: sun3, sun4

Patches which may conflict with this patch:

Obsoleted by:

Files included with this patch: /usr/bin/ipcs

Problem Description:

        For a non-root user, the ipcs program abnormally terminates
        with "shmctl: Permission denied" when there exists a shared
        memory segment "owned" by another user and its permission bits
        don't allow read access by the user executing "ipcs". This patch
        fixes the ipcs command in this regard.

Install Instructions:

        1) Save the original ipcs:
                mv /usr/bin/ipcs /usr/bin/ipcs.FCS
         
        2) cd to the appropriate SunOS release subdirectory (4.1.1,
           4.1.2, 4.1.3) and copy the patched ipcs to /usr/bin:

                cp OS-rel/`arch`/ipcs /usr/bin/ipcs

        3) fix the ownership and permissions of the new ipcs:

                chown root /usr/bin/ipcs
                chgrp kmem /usr/bin/ipcs
                chmod 2755 /usr/bin/ipcs

----- End Included Message -----

The following is my original question:
> I have a Sun SPARCstation 10 running SunOS 4.1.3. We have oracle 7.0.12
> initializing itself at boot. oracle uses shared memory. One of the
> developers is creating an independent shared memory area. If I
> enter the command, ipcs from the developers account, I get
>
> shmctl(): permission denied
>
> But, from the oracle account, I can see all the oracle and the user's
> shared memory, but the user cannot see their own allocation. The
> user needs to remove it, but is unable to get the ID for the shared
> memory.
>
> Anyone have any Ideas?
>
> Does oracle take ownership of some file containing the share memory allocation
> information?



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:07:50 CDT