Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:82402 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 84255 invoked from network); 11 Feb 2015 00:10:24 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 11 Feb 2015 00:10:24 -0000 Authentication-Results: pb1.pair.com smtp.mail=yohgaki@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=yohgaki@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.216.42 as permitted sender) X-PHP-List-Original-Sender: yohgaki@gmail.com X-Host-Fingerprint: 209.85.216.42 mail-qa0-f42.google.com Received: from [209.85.216.42] ([209.85.216.42:51496] helo=mail-qa0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id AC/19-32490-EED9AD45 for ; Tue, 10 Feb 2015 19:10:23 -0500 Received: by mail-qa0-f42.google.com with SMTP id dc16so281860qab.1 for ; Tue, 10 Feb 2015 16:10:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=dPBz3SuyEB6sXutjksEBezLoju2eYi4dCyCDXV900/Q=; b=z14BlOoDvQEDpxGJmZMiPeaeEzxQkWp68VkuqzTR6wBH0956oFZotjIYA84UJ5sH2n F3qITVF6lzordOmZI6sPAXLZZB5SYHxDTN0/IDHgn4ytCREjWd6GrA1fHol0YwKU9Lyk 4M/3sPYhjYoSs0+Pop8+eYFrA4fWQ4iaHDtCbkNtPNM/pml1js/3IMd0WhSa2HJbN0W3 v507nUNfDJbKjUOxUqsUHzKvfPrPkHVQgGJor4hROyDPlEBJaXxobk1KhEOW16Zpx0Ai TYqLlh7tewClQ/YpQpCGFwxKkofrSdGGgTaVRrMZeorFdJlBKr8ZO2qoPtM2CA1C0syv AbVg== X-Received: by 10.224.53.194 with SMTP id n2mr14737080qag.21.1423613419580; Tue, 10 Feb 2015 16:10:19 -0800 (PST) MIME-Version: 1.0 Sender: yohgaki@gmail.com Received: by 10.229.250.195 with HTTP; Tue, 10 Feb 2015 16:09:39 -0800 (PST) In-Reply-To: <54D9C867.9030107@fischer.name> References: <54D9C867.9030107@fischer.name> Date: Wed, 11 Feb 2015 09:09:39 +0900 X-Google-Sender-Auth: TZQeOdUipmyo81FzUWt0ZsKaEaQ Message-ID: To: Markus Fischer Cc: "internals@lists.php.net" Content-Type: multipart/alternative; boundary=001a1132f7442bf0aa050ec4d437 Subject: Re: [PHP-DEV] [RFC][DISCUSSION] Script only includes From: yohgaki@ohgaki.net (Yasuo Ohgaki) --001a1132f7442bf0aa050ec4d437 Content-Type: text/plain; charset=UTF-8 Hi Markus, On Tue, Feb 10, 2015 at 5:59 PM, Markus Fischer wrote: > What constitutes "first token" in this context? > > Would this be detected as a PHP file? > > -----8<---- > root:x:0:0:root:/root:/bin/bash > daemon:x:1:1:daemon:/usr/sbin:/usr/sbin/nologin > bin:x:2:2:bin:/bin:/usr/sbin/nologin > phpinfo(); > -----8<---- > Yes. Since we have custom script loader, file content cannot be used for "pure" PHP script detection. However, parser can detect if it's a "pure" PHP script. i.e. Detect in the file. Regards, -- Yasuo Ohgaki yohgaki@ohgaki.net --001a1132f7442bf0aa050ec4d437--