Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:66737 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 99507 invoked from network); 21 Mar 2013 14:59:14 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 21 Mar 2013 14:59:14 -0000 Authentication-Results: pb1.pair.com header.from=ralph@ralphschindler.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=ralph@ralphschindler.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain ralphschindler.com from 209.85.214.177 cause and error) X-PHP-List-Original-Sender: ralph@ralphschindler.com X-Host-Fingerprint: 209.85.214.177 mail-ob0-f177.google.com Received: from [209.85.214.177] ([209.85.214.177:35074] helo=mail-ob0-f177.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 1A/23-07112-F302B415 for ; Thu, 21 Mar 2013 09:59:13 -0500 Received: by mail-ob0-f177.google.com with SMTP id eh20so2871261obb.8 for ; Thu, 21 Mar 2013 07:59:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:message-id:date:from:user-agent:mime-version:to:subject :content-type:content-transfer-encoding:x-gm-message-state; bh=tXgwynh6VtsYwtVNdlCqMzHtPRPP6jEZ4muree9UzyQ=; b=nnsE3Q1jjVCiNZr+jbAK5kqgNC/0c20Qg4X12Y9CLLP3b9+UakEjk5TrZa+zEv58NG LMXYZ+y0essInoFXo9/GR8NsPCv6KOqCxmpGX+hau9mGqT8YT6/ujqXmlSfEXpFYPNCU QbT1/VBDSMluUQndy+GWi3iHMrHXss7ObOy+InkM1nadpcPaOefI3PEjpo2s8MvXxx1G 5dZQvlRLTyQqNo7MAyVj1ln2otBk3zQ5J7NKCnUlPuRMU0+df1UZ08Mix8GuhYhUNZXq VFcNcN0VEz5VRJQUacpRN2j6IIOpdiT/I5tNN7GNsknrg7ooaofCsBzU1hBAMaSNZCEo RMLg== X-Received: by 10.60.19.228 with SMTP id i4mr7162097oee.45.1363877949485; Thu, 21 Mar 2013 07:59:09 -0700 (PDT) Received: from Ralphs-Mac-Pro.local (ip174-73-14-247.no.no.cox.net. [174.73.14.247]) by mx.google.com with ESMTPS id qk4sm7120847obc.5.2013.03.21.07.59.07 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 21 Mar 2013 07:59:08 -0700 (PDT) Message-ID: <514B203A.80502@ralphschindler.com> Date: Thu, 21 Mar 2013 09:59:06 -0500 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130307 Thunderbird/17.0.4 MIME-Version: 1.0 To: internals Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Gm-Message-State: ALoCoQltRTlPO1TR3rs3BmooH7vvcjTc3EjkyLuHN58WQAKsdURbGRPod6M9PGRxD3AgTatf1Z1/ Subject: Phar Bug #60953 From: ralph@ralphschindler.com (Ralph Schindler) Hi all, I'd like to get some closure on this PR: https://github.com/php/php-src/pull/297 which fixes: https://bugs.php.net/bug.php?id=60953 I've discussed it in brief with both cjones and lawerence. I don't have commit karma for the phar extension, so someone will have to merge this for me. In a nutshell, phar_rename_archive(), which is called from Phar::convertToExecutable(), incorrectly assumes anything after the first dot is a file extension. This causes problems where file names have dots in them, and you attempt to run convertToExecutable(). This patch attempts to fix the problem by making educated guesses as to which the extension is (should be). In most cases, the extension should include a .phar, or some known single or compound format for an extension (like tar.gz). You'll notice some existing tests have changed. This is because the incorrect assumption was propagated through existing tests, and that was fixed, all the tests pass. Finally, if there is a file name extension Phar doesn't already understand, it will simply take the part after the first dot, like it did previously (for BC). Anyone want to assist getting this fix into 5.3-5.5? Or are there any lingering questions on the patch? Thanks, Ralph