Commit Graph

224 Commits

Author SHA1 Message Date
Greg Beaver
c6fe26af37 windows fixes (thanks Steph you rule) 2007-12-14 05:39:20 +00:00
Greg Beaver
38bf150e4d remove stupid*$(# debug code 2007-12-14 05:00:59 +00:00
Greg Beaver
8a614e30db use thread-safe global var to store zend_compile_file, and restore the current zend_compile_file, not the one we
found in MINIT
2007-12-11 19:28:35 +00:00
Greg Beaver
47d859ced2 use stream_copy_to_stream again, figured out how to make the stupid filters work 2007-12-11 19:21:01 +00:00
Greg Beaver
688aef57f8 add the ability to automatically resolve includes inside a phar to files within that phar, so
no code modification is needed to include/require
2007-12-09 21:57:44 +00:00
Greg Beaver
4bcb68a4e8 fix errors found in delMetaData(), add get/delMetaData() to MetaData read test 2007-11-25 05:04:40 +00:00
Greg Beaver
e34be4f8bc preliminary work on using gnupg to verify/create signatures - no implementation, just phpinfo() output and build rules 2007-11-24 04:30:08 +00:00
Greg Beaver
a72251be6e experimental support for optional bz2 extension - should make windows users a whole lot happier 2007-11-24 04:06:44 +00:00
Greg Beaver
b21f49c7c7 MFB fixes for tests 2007-11-22 05:47:28 +00:00
Greg Beaver
43c7e6fa3b fix faulty logic on verification of phar 2007-11-20 05:34:35 +00:00
Greg Beaver
be023d6f62 much better fix for the problem of phar://c:\path\to\blah.phar
don't use php_parse_url() at all, and always unixify paths on copied strings.
our modification was modifying the zval original string, so a user would pass in
phar://c:\path\to\blah.phar

and their string would change to phar://c:/path/to/blah.phar - bad.

Now using

include 'phar://' . __FILE__ . '/index.php';

works on both unix and windows seamlessly, as well as $a = new Phar(__FILE__)

for use in the loader stub
2007-11-19 23:10:05 +00:00
Greg Beaver
4a86b3d6ea Ensure that the same phar can be referenced in multiple logical ways:
1) full path, with \ or / path separator
2) relative path to getcwd()

This should fix the last remaining windows-related quirks as well as similar problems
on unix
2007-11-15 05:21:11 +00:00
Greg Beaver
999961f080 begin win32 fixes for Phar object - still have a problem I can't track down yet, but it's only a matter of time before it is killed too
when passing in a full path with drive letter to the Phar object, we were
then passing "phar://C:/path/to/blah.phar" to php_parse_url(), which
thinks it is getting a valid url scheme "phar", host "C" path "/path/to/blah.phar"

we now pass "phar:///C:/path/to/blah.phar" to make it fail, and then properly
parse the url inside phar
2007-11-13 05:57:14 +00:00
Greg Beaver
6d98d843af fix TSRM, a couple of compile warnings on windows, and test 2007-10-18 19:47:24 +00:00
Greg Beaver
eb67969b73 fix Bug #12124: Phar object cannot be iterated over
remove unused variables
fix jit file open sprintf calls
2007-10-04 03:33:21 +00:00
Greg Beaver
07c509935c fix phar to work with PHP 5.3 2007-10-04 02:24:49 +00:00
Greg Beaver
33347b19f2 when opening an internal file read-only, recycle the phar archive's fp. This makes phar twice as fast (2.21x according to callgrind) 2007-08-30 02:30:16 +00:00
Greg Beaver
5d8919938d fix issue with large number of open file handles killing php with large phars on creation
- close file handles that have no references for entries
- add just-in-time re-processing of file handles
- make sure file size is set in renaming
- add old_flags to phar_entry_info so we can decompress when flushing a modified entry whose fp is closed
2007-08-17 04:47:50 +00:00
Greg Beaver
d3426be1c3 fix several mis-spelled 'temporary's add missing space in comment, and change 'script end' to 'stub end' in manifest read error messages 2007-06-01 03:48:17 +00:00
Marcus Boerger
7ecc0f7fad - Fix memory issue 2007-05-31 06:55:14 +00:00
Marcus Boerger
38bb8cb5af - Fix invalid efree() call 2007-05-28 21:04:42 +00:00
Marcus Boerger
096e123f2d - Verify stub
- Automatically cut off stub after __HALT_COMPILER();
- Always write longest stub ending, so there is no issue with length field
- Add test for setStub from file
- Fix tests
2007-05-27 16:54:37 +00:00
Marcus Boerger
ac05df4759 - For errors "internal corruption of phar ... (truncated manifest)" be more
precise about reason of failure, seperating all error strings
- Fix issue with writing compressed entries
- Fix issue with uncompressing entries
2007-05-27 15:47:52 +00:00
Marcus Boerger
7e1ba8bffb - Fix the fix 2007-05-20 22:14:07 +00:00
Marcus Boerger
73ddcc1fd2 - Fix shutdown 2007-05-20 21:46:54 +00:00
Marcus Boerger
6cbfd2271f - Drop RINIT completely (as discussed @ php|tek) 2007-05-18 04:31:39 +00:00
Marcus Boerger
4313bce995 - Get rid of RINIT completely 2007-05-16 23:20:31 +00:00
Marcus Boerger
5e3af23d20 - Reduce overhead of Phar's RINIT 2007-05-16 23:16:51 +00:00
Marcus Boerger
004932e11d - Add Phar::delMetadata()
- Add Phar::hasMetadata()
- Add Phar::isValidPharFilename()
2007-05-15 20:21:19 +00:00
Marcus Boerger
1ab96f2d04 - Drop commented line 2007-05-14 19:36:44 +00:00
Marcus Boerger
16e27c5aad - Fix main metadata handling, prefix main metadata with main 2007-05-14 19:36:09 +00:00
Marcus Boerger
440691899c - Optimize flushing, don't generate metadata twice 2007-05-14 19:14:00 +00:00
Marcus Boerger
c9c5dbbd8d - Unoptimized fix for metadata writing 2007-05-14 18:59:04 +00:00
Marcus Boerger
7aa7448a32 - Fix Phar::canWrite(), had inverted logic
- Support PHP & builds
2007-05-09 18:09:41 +00:00
Marcus Boerger
ab15beebbf - Compatibility with suhosin 2007-03-27 21:28:22 +00:00
Marcus Boerger
c84b870472 - Prevent rename on extracted archieves 2007-03-26 19:51:22 +00:00
Marcus Boerger
f1684e4735 - Fix return value of unlink/rename handlers
- Add extract_list support to all wrapper handlers but rename
2007-03-26 19:20:00 +00:00
Greg Beaver
e97b1aefbf fix memleak in external dirs
update package.xml
move API to 1.1.0
update package version to 1.1.0RC1
update API test
2007-03-26 16:42:47 +00:00
Greg Beaver
a92eeb61c4 [DOC]
implement setSignatureAlgorithm() and add class constants Phar::MD5, Phar::SHA1, Phar::SHA256, Phar::SHA512, Phar::PGP
2007-03-26 00:00:56 +00:00
Greg Beaver
c3b317f44c default must be SHA1 or we get a BC break 2007-03-25 23:42:49 +00:00
Marcus Boerger
c42a870b7e - Add general SHA-2 support by optional pecl/hash dependency
# We actually need support to select the signature type somehow
2007-03-25 21:43:49 +00:00
Marcus Boerger
b983973a1d - Add ini: phar.extract_list
- Add Phar::getExtractList
- Both allow to set a mapping <phar-file> to <extract-dir>
[[DOC]]
2007-03-25 19:03:38 +00:00
Greg Beaver
e53980587f minor typo s/whetehr/whether/ 2007-03-21 17:14:46 +00:00
Marcus Boerger
94c3896f73 - Provide dedicated hex function for digests 2007-02-24 02:08:08 +00:00
Marcus Boerger
0bd3f367de - Fix issues found with solaris 2007-02-06 23:19:10 +00:00
Marcus Boerger
8f11f4875d - Avoid direct tsrm manipulating in ini setting 2007-02-06 22:41:39 +00:00
Marcus Boerger
bed7c1167d - Fix potential read issues 2007-02-06 22:12:21 +00:00
Antony Dovgal
ea40c23358 fix macros for bigendian platforms 2007-02-06 21:43:46 +00:00
Antony Dovgal
65b47ce346 add missing closing marker 2007-02-06 21:04:22 +00:00
Marcus Boerger
3f3c8fcd10 - Drop another superflous stream close 2007-02-06 20:30:33 +00:00