Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:95510 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 98493 invoked from network); 31 Aug 2016 03:46:13 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 31 Aug 2016 03:46:13 -0000 Authentication-Results: pb1.pair.com smtp.mail=me@daveyshafik.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=me@daveyshafik.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain daveyshafik.com from 209.85.220.179 cause and error) X-PHP-List-Original-Sender: me@daveyshafik.com X-Host-Fingerprint: 209.85.220.179 mail-qk0-f179.google.com Received: from [209.85.220.179] ([209.85.220.179:36550] helo=mail-qk0-f179.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 3B/70-11399-30356C75 for ; Tue, 30 Aug 2016 23:46:12 -0400 Received: by mail-qk0-f179.google.com with SMTP id l2so39556119qkf.3 for ; Tue, 30 Aug 2016 20:46:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=daveyshafik-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=CqKnRSZIglRTQM4EDWy6FYQouLOjcXvt2edc+C6YN/4=; b=z889Gkgu56RbSNweEdYtG1s/EYoU86lHwESrMxv0/cNabpZSgI+fDKKJX9c95AMQmc geQV7CoiwxrM/iGi8Hm8XPRk6RCSLEmDZsZixZVOaVA3fgt08UiTTDC6+IpcBVhwe5RN G0SLgPQQSfkop79ueR4NKuFRj7Tzte+z1mVmqmVeLB6qp1jW2RzyXLbLeRr7WLHtKhOy WYTcJA1vJFWRzw1iDIu2/W3TWWoZdjNWS6lvVVVidiujwYd9L2rk8evdkAjhZUtYsWvY O3rFGrWNutX8SI3JA+fPhbmvkBF5Pqz4tTsmxtFsn4WNqnZaXjTVgvlUeWgcqPZHMStB rfqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=CqKnRSZIglRTQM4EDWy6FYQouLOjcXvt2edc+C6YN/4=; b=duT36YaOAHAxqSpG0jNAevrOaoWKZGjSDS33/GnUs1MV2Iwa6ia0eKwExTNCHvhyBm xq/L9hJpKnPeYmBEKqgYQ+1g+bUcARr7E1DlmzRcrd8IWkEn5aGIJz+INn2Yqp9kVyHq SeeYp6sP6ZXOuF5SatUn4RNgh9X4Wf5n5k6ciT07au6445t3fJI3WJq8UcgrZPBl6JgM gytCG4hW0tYOBe9QoWfohjEHny6tD7IFUkis54ZYwvZw/zqTojCDV+TC4CIGZsk/NPqa yRKVxMVJbAaJYtl7IwxybC1GJYnZBw6k8XdAvHh/Jbnb820ASEJAlD7lp0gIOJL2+HXc 4AmQ== X-Gm-Message-State: AE9vXwNSHctH32xPJaBaSMOAxQtMIWHsVGOwdh1C/6Y0s7rRyJsYdt+AP/4Fr7PUnNuaJUuBVWGfjgUdM0MsYiby X-Received: by 10.55.127.197 with SMTP id a188mr8282960qkd.150.1472615169015; Tue, 30 Aug 2016 20:46:09 -0700 (PDT) MIME-Version: 1.0 Sender: me@daveyshafik.com Received: by 10.237.55.138 with HTTP; Tue, 30 Aug 2016 20:46:08 -0700 (PDT) In-Reply-To: <016101d1fa7a$298a5220$7c9ef660$@belski.net> References: <036401d1f30f$afa85a40$0ef90ec0$@belski.net> <3dc2f23a-c4fb-a63d-ab7f-fa841091b313@gmx.de> <53037294-e8ed-31c8-95ef-522e02333e7c@gmx.de> <016101d1fa7a$298a5220$7c9ef660$@belski.net> Date: Tue, 30 Aug 2016 20:46:08 -0700 X-Google-Sender-Auth: XMH5OM7wydQo1j3a30n7VZN7OHA Message-ID: To: Anatol Belski Cc: "Christoph M. Becker" , "internals@lists.php.net" Content-Type: multipart/alternative; boundary=94eb2c05c08a0a9a0a053b55f099 Subject: Re: [PHP-DEV] SQLite 3.14 From: davey@php.net (Davey Shafik) --94eb2c05c08a0a9a0a053b55f099 Content-Type: text/plain; charset=UTF-8 Sorry, I dropped the ball on this one: ./sapi/cli/php -d "output_handler=" -d "open_basedir=." -d "disable_functions=" -d "output_buffering=Off" -d "error_reporting=32767" -d "display_errors=1" -d "display_startup_errors=1" -d "log_errors=0" -d "html_errors=0" -d "track_errors=1" -d "report_memleaks=1" -d "report_zend_debug=0" -d "docref_root=" -d "docref_ext=.html" -d "error_prepend_string=" -d "error_append_string=" -d "auto_prepend_file=" -d "auto_append_file=" -d "ignore_repeated_errors=0" -d "precision=14" -d "memory_limit=128M" -d "log_errors_max_len=0" -d "opcache.fast_shutdown=0" -d "opcache.file_update_protection=0" -f "/php-src/ext/sqlite3/tests/sqlite3_21_security.php" I think the issue is that the test isn't run in ext/sqlite3/tests, but from the root of the checkout, which means that open_basedir=. would include everything in the repo, including the attempt "../bad" directory. Potential solutions: Change the path to be "../../../../../bad" to ensure it's outside the top-level of the script. Add a: chdir(__DIR__); at the top. Thoughts? On Fri, Aug 19, 2016 at 5:31 PM, Anatol Belski wrote: > Hi Davey, > > > -----Original Message----- > > From: Davey Shafik [mailto:davey@php.net] > > Sent: Friday, August 19, 2016 7:09 PM > > To: Christoph M. Becker > > Cc: Anatol Belski ; internals@lists.php.net > > Subject: Re: [PHP-DEV] SQLite 3.14 > > > > Christophe, > > > > I got the failure multiple times in my Debian Jessie docker container > that I use > > for builds - you can check it out yourself at > https://github.com/dshafik/php-build > > to see the setup. > > > > Thanks for looking into this! > > > > - Davey > > > > On Sat, Aug 20, 2016 at 01:35 Christoph M. Becker > > wrote: > > > > > > Hi Davey! > > > > On 19.08.2016 at 15:32, Davey Shafik wrote: > > > > > I saw this failure while packaging 7.1.0beta3, and assume it > might be > > > related to your update: > > > > > > FAIL SQLite3 open_basedir checks > > > [ext/sqlite3/tests/sqlite3_21_security.phpt] > > > > > > ========DIFF======== > > > 006- > > > 007- Warning: SQLite3::__construct(): open_basedir restriction in > > effect. > > > File(%s) is not within the allowed path(s): (.) in > > > %ssqlite3_21_security.php on line %d > > > 008- Exception: open_basedir prohibits opening %s in > > > %ssqlite3_21_security.php:%d > > > 009- Stack trace: > > > 010- #0 %ssqlite3_21_security.php(%d): SQLite3->__construct('%s') > > > 011- #1 {main} > > > ========DONE======== > > > > > > Can you please look into this in time for RC1? > > > > I've just checked again with the tagged PHP-7.1.0beta3, but the > test > > succeeds on my machine. Therefore it's hard for me to assess what > is > > wrong. According to the diff, it appears that the second DB which > > shouldn't be created according to the open_basedir restriction, is > > actually successfully created. > > > > Anyway, it's rather unlikely that an open_basedir related failure > is > > caused by updating SQLite, as this check is part of the PHP > binding[1], > > which has not been affected by this commit. The issue might be > caused > > by commit cc125f27[2], but that's also somewhat unlikely, because > the > > Travis checks usually succeed generally. > > > > Can you reproduce the test failure? In which enviroment? > > > > [1] sqlite3 > > /sqlite3.c#L125 > 7.1.0beta3/ext/sqlite3/sqlite3.c#L125> > > > [2] > > > I was checking this and saw no failure as well. From the test diff, it > doesn't look like a crash but something with that try/catch block. Maybe > there'll be more luck with a reproducer, if you could post the exact > command line? You can read it from the corresponding .sh file or just by > appending --verbose. > > Regards > > Anatol > --94eb2c05c08a0a9a0a053b55f099--