• Bug#266913: acknowledged by developer (php4: file check operations fail

    From James Strandboge@1:229/2 to Debian Bug Tracking System on Fri Aug 20 16:00:21 2004
    From: [email protected]

    On Fri, 2004-08-20 at 00:18, Debian Bug Tracking System wrote:
    This is an automatic notification regarding your Bug report
    #266913: php4: file check operations fail with safe_mode enabled,
    which was filed against the php4 package.

    It has been closed by one of the developers, namely
    "Adam Conrad" <[email protected]>.

    Their explanation is attached below. If this explanation is
    unsatisfactory and you have not received a better one in a separate
    message then please contact the developer, by replying to this email.

    Debian bug tracking system administrator
    (administrator, Debian Bugs database)

    Received: (at 266913-close) by bugs.debian.org; 20 Aug 2004 04:07:13 +0000 >From [email protected] Thu Aug 19 21:07:12 2004
    Return-path: <[email protected]>
    Received: from mx1.mail.iig.com.au [203.1.68.15]
    by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
    id 1By0gK-0005Xx-00; Thu, 19 Aug 2004 21:07:12 -0700
    Received: by mx1.mail.iig.com.au (Postfix, from userid 10)
    id BE0ED2AE5E; Fri, 20 Aug 2004 14:07:10 +1000 (EST)
    Received: from devix (202-14-148-078-soho.dsl.iig.com.au [202.14.148.78])
    by mx1.mail.iig.com.au (Postfix) with ESMTP id 5662A2A559
    for <[email protected]>; Fri, 20 Aug 2004 14:07:03 +1000 (EST)
    From: "Adam Conrad" <[email protected]>
    To: <[email protected]>
    Subject: php4: file check operations fail with safe_mode enabled
    Date: Fri, 20 Aug 2004 14:06:57 +1000
    Message-ID: <004f01c4866b$23bda3f0$[email protected]> MIME-Version: 1.0
    Content-Type: text/plain;
    charset="us-ascii"
    Content-Transfer-Encoding: quoted-printable
    X-Priority: 3 (Normal)
    X-MSMail-Priority: Normal
    X-Mailer: Microsoft Outlook, Build 10.0.6626
    Importance: Normal
    X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
    Delivered-To: [email protected]
    X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2004_03_25
    (1.212-2003-09-23-exp) on spohr.debian.org
    X-Spam-Status: No, hits=-3.0 required=4.0 tests=BAYES_00 autolearn=no
    version=2.60-bugs.debian.org_2004_03_25
    X-Spam-Level:

    You can't perform ANY file operations on files you don't own when =
    safe_mode
    is enabled, regardless of open_basdir. Since you don't own /tmp, id_dir fails. If you think this isn't sane, please bug upstream. :)

    The fact that it works on OpenBSD points to a bug somewhere in PHP's =
    code in
    dealing with UID checks on OpenBSD, I'd suspect.

    I should have mentioned I checked this prior to sending the bugreport.

    mkdir /tmp/foo
    chown www-data.www-data /tmp/foo
    $ ls -ld /tmp/foo
    drwxr-xr-x 2 www-data www-data 4096 2004-08-20 09:33 /tmp/foo

    in test.php:
    is_dir("tmp/foo")

    fails.

    Apache is running as www-data:
    $ ps auxww|grep apache
    root 5989 0.0 0.8 140880 4168 pts/1 S 09:34 0:00
    /usr/sbin/apache
    www-data 5990 0.0 0.8 141020 4552 pts/1 S 09:34 0:00
    /usr/sbin/apache
    www-data 5991 0.0 0.8 141020 4552 pts/1 S 09:34 0:00
    /usr/sbin/apache
    www-data 5992 0.0 0.8 141020 4560 pts/1 S 09:34 0:00
    /usr/sbin/apache
    www-data 5993 0.0 0.8 140880 4172 pts/1 S 09:34 0:00
    /usr/sbin/apache
    www-data 5994 0.0 0.8 140880 4172 pts/1 S 09:34 0:00
    /usr/sbin/apache
    www-data 6086 0.0 0.8 140880 4184 pts/1 S 09:35 0:00
    /usr/sbin/apache

    Jamie

    --
    Email: [email protected]
    GPG/PGP ID: 26384A3A
    Fingerprint: D9FF DF4A 2D46 A353 A289 E8F5 AA75 DCBE 2638 4A3A



    --
    To UNSUBSCRIBE, email to [email protected]
    with a subject of "unsubscribe". Trouble? Contact [email protected]

    --- SoupGate-Win32 v1.05
    * Origin: you cannot sedate... all the things you hate (1:229/2)