]> git.ipfire.org Git - thirdparty/libarchive.git/log
thirdparty/libarchive.git
9 years agoFix libarchive/archive_read_support_format_mtree.c:1388:11: error: array subscript... 715/head
mfont [Fri, 10 Jun 2016 14:54:43 +0000 (16:54 +0200)] 
Fix libarchive/archive_read_support_format_mtree.c:1388:11: error: array subscript is above array bounds

9 years agoMerge pull request #714 from finetjul/support-extended-path-in-permissive_name_w
Tim Kientzle [Thu, 9 Jun 2016 01:59:20 +0000 (18:59 -0700)] 
Merge pull request #714 from finetjul/support-extended-path-in-permissive_name_w

Do not preppend \\?\ if it is already there

9 years agoDo not preppend \\?\ if it is already there 714/head
Julien Finet [Wed, 8 Jun 2016 14:39:52 +0000 (16:39 +0200)] 
Do not preppend \\?\ if it is already there

If GetCurrentDirectory() returns \\?\C\a\path or
\\?\UNC\server\a\path, then adding \\?\ would not work.

9 years agoMerge pull request #713 from abhinav-upadhyay/fix-man-page
Joerg Sonnenberger [Mon, 6 Jun 2016 15:00:44 +0000 (17:00 +0200)] 
Merge pull request #713 from abhinav-upadhyay/fix-man-page

Remove .Pp before .Bl

9 years agoRemove .Pp before .Bl 713/head
Abhinav Upadhyay [Mon, 6 Jun 2016 14:46:09 +0000 (20:16 +0530)] 
Remove .Pp before .Bl

9 years agoMerge pull request #603 from Tarsnap/add-entry-allocation-failure-error-xattr
Tim Kientzle [Fri, 3 Jun 2016 13:47:45 +0000 (06:47 -0700)] 
Merge pull request #603 from Tarsnap/add-entry-allocation-failure-error-xattr

Add entry allocation failure error xattr

9 years agoFix the broken test name
Tim Kientzle [Fri, 3 Jun 2016 13:46:40 +0000 (06:46 -0700)] 
Fix the broken test name

9 years agoMerge pull request #712 from maxinbjohn/master
Tim Kientzle [Fri, 3 Jun 2016 13:44:06 +0000 (06:44 -0700)] 
Merge pull request #712 from maxinbjohn/master

configure.ac: check acl/libacl.h and sys/acl.h based on requirement

9 years agoMakefile.am: Remove non-existing file 712/head
Maxin B. John [Fri, 3 Jun 2016 11:09:30 +0000 (14:09 +0300)] 
Makefile.am: Remove non-existing file

Fixes this build error:

CC       libarchive/archive_write_set_format_gnutar.lo
make[1]: *** No rule to make target
'libarchive/archive_write_set_format_gnutar_filenames.c', needed by
'libarchive/archive_write_set_format_gnutar_filenames.lo'.  Stop.
make[1]: Leaving directory '/home/maxin/clone/libarchive'
Makefile:2866: recipe for target 'all' failed
make: *** [all] Error 2

Signed-off-by: Maxin B. John <maxin.john@intel.com>
9 years agoconfigure.ac: check acl/libacl.h and sys/acl.h based on requirement
Maxin B. John [Thu, 2 Jun 2016 13:08:02 +0000 (16:08 +0300)] 
configure.ac: check acl/libacl.h and sys/acl.h based on requirement

acl/libacl.h and sys/acl.h check should not happen when we explicitly
disable it with --disable-acl.

Similarly, update attr/xattr.h for --disable-xattr option.

Update the help texts to reflect what it really does.

Signed-off-by: Maxin B. John <maxin.john@intel.com>
9 years agoIssue 657: Allow up to 8k for the test root directory name
Tim Kientzle [Fri, 3 Jun 2016 03:17:13 +0000 (20:17 -0700)] 
Issue 657: Allow up to 8k for the test root directory name

9 years agoIssue 682: Correctly write gnutar filenames of exactly 512 bytes
Tim Kientzle [Wed, 1 Jun 2016 04:01:59 +0000 (21:01 -0700)] 
Issue 682: Correctly write gnutar filenames of exactly 512 bytes

Previous code omitted the final zero byte for filenames and
linknames.  This is usually okay since the final block is
padded with zero bytes, but if the filename exactly filled
the block, there would be no zero byte.

9 years agoIssue 708: tar should fail if a named input file is missing
Tim Kientzle [Sat, 28 May 2016 19:39:10 +0000 (12:39 -0700)] 
Issue 708: tar should fail if a named input file is missing

Tar was exiting with success if an input file named on the command
line was not present.

Includes tests for both bsdtar and bsdcpio to ensure this does
not regress.

9 years agoIssue 711: Be more careful about verifying filename lengths when writing ISO9660...
Tim Kientzle [Sat, 28 May 2016 18:50:39 +0000 (11:50 -0700)] 
Issue 711:  Be more careful about verifying filename lengths when writing ISO9660 archives

* Don't cast size_t to int, since this can lead to overflow
  on machines where sizeof(int) < sizeof(size_t)
* Check a + b > limit by writing it as
    a > limit || b > limit || a + b > limit
  to avoid problems when a + b wraps around.

9 years agoTypo
Joerg Sonnenberger [Fri, 27 May 2016 14:31:34 +0000 (16:31 +0200)] 
Typo

9 years agoAdd short description of the manpage.
Joerg Sonnenberger [Fri, 27 May 2016 14:30:45 +0000 (16:30 +0200)] 
Add short description of the manpage.

9 years agoFix man page syntax to include a description.
Joerg Sonnenberger [Fri, 27 May 2016 14:28:39 +0000 (16:28 +0200)] 
Fix man page syntax to include a description.

9 years agoMerge pull request #709 from mmatuska/bsdcpio_passthrough
Tim Kientzle [Mon, 16 May 2016 00:40:15 +0000 (17:40 -0700)] 
Merge pull request #709 from mmatuska/bsdcpio_passthrough

Disable ARCHIVE_EXTRACT_SECURE_NOABSOLUTEPATHS in bsdcpio p mode

9 years agoDisable ARCHIVE_EXTRACT_SECURE_NOABSOLUTEPATHS in bsdcpio p mode 709/head
Martin Matuska [Sun, 15 May 2016 08:38:46 +0000 (10:38 +0200)] 
Disable ARCHIVE_EXTRACT_SECURE_NOABSOLUTEPATHS in bsdcpio p mode

9 years agoReject cpio symlinks that exceed 1MB
Tim Kientzle [Sat, 14 May 2016 19:37:37 +0000 (12:37 -0700)] 
Reject cpio symlinks that exceed 1MB

9 years agoMerge pull request #702 from mmatuska/bsdcat_warnings
Tim Kientzle [Thu, 12 May 2016 15:33:27 +0000 (08:33 -0700)] 
Merge pull request #702 from mmatuska/bsdcat_warnings

cat: declare static variables and fix compiler warnings

9 years agoMerge pull request #703 from mmatuska/libarchive_fe_static
Tim Kientzle [Thu, 12 May 2016 15:32:55 +0000 (08:32 -0700)] 
Merge pull request #703 from mmatuska/libarchive_fe_static

libarchive_fe: declare lafe_progname static

9 years agoMerge pull request #701 from mmatuska/const_char_fix
Tim Kientzle [Thu, 12 May 2016 15:32:27 +0000 (08:32 -0700)] 
Merge pull request #701 from mmatuska/const_char_fix

Fix const char warnings

9 years agocat: declare static variables and fix several compiler warnings 702/head
Martin Matuska [Wed, 11 May 2016 09:26:47 +0000 (11:26 +0200)] 
cat: declare static variables and fix several compiler warnings

9 years agoFix const char warning 701/head
Martin Matuska [Wed, 11 May 2016 07:01:43 +0000 (09:01 +0200)] 
Fix const char warning

9 years agoMake some arguments const
Tim Kientzle [Wed, 11 May 2016 01:54:02 +0000 (18:54 -0700)] 
Make some arguments const

9 years agoDeclare lafe_progname static 703/head
Martin Matuska [Wed, 11 May 2016 00:09:53 +0000 (02:09 +0200)] 
Declare lafe_progname static

9 years agoMerge pull request #700 from xtraeme/lzma-xz-mt
Tim Kientzle [Fri, 6 May 2016 02:34:21 +0000 (19:34 -0700)] 
Merge pull request #700 from xtraeme/lzma-xz-mt

configure.ac: declare HAVE_LZMA_STREAM_ENCODER_MT properly

9 years agoconfigure.ac: define HAVE_LZMA_STREAM_ENCODER_MT if it is detected properly. 700/head
Juan RP [Thu, 5 May 2016 05:55:57 +0000 (07:55 +0200)] 
configure.ac: define HAVE_LZMA_STREAM_ENCODER_MT if it is detected properly.

... otherwise HAVE_LZMA_STREAM_ENCODER_MT is undefined and the code
for multithreaded xz compression is skipped completely.

9 years agoMerge pull request #698 from bradking/fix-spelling-typos
Joerg Sonnenberger [Mon, 2 May 2016 16:07:05 +0000 (18:07 +0200)] 
Merge pull request #698 from bradking/fix-spelling-typos

Fix spelling typos in comments

9 years agoFix spelling typos in comments 698/head
Brad King [Mon, 2 May 2016 14:56:28 +0000 (10:56 -0400)] 
Fix spelling typos in comments

The Debian package checker tool (lintian) detected a few typos.

Reported-by: Felix Geyer <fgeyer@debian.org>
9 years agoLibarchive 3.2.0 v3.2.0
Tim Kientzle [Sat, 30 Apr 2016 17:26:35 +0000 (10:26 -0700)] 
Libarchive 3.2.0

9 years agoSync up test harnesses
Tim Kientzle [Sat, 30 Apr 2016 04:49:34 +0000 (21:49 -0700)] 
Sync up test harnesses

9 years agoMerge branch 'vu862384'
Tim Kientzle [Sat, 30 Apr 2016 04:41:49 +0000 (21:41 -0700)] 
Merge branch 'vu862384'

Fixes Issue 656
Fixes CVE-2016-1541
Fixes VU#862384
Fixes TALOS-CAN-155

9 years agoIssue 585: archive.h needs time.h
Tim Kientzle [Fri, 29 Apr 2016 02:54:47 +0000 (19:54 -0700)] 
Issue 585: archive.h needs time.h

9 years agoIssue 695: check fwrite return value, sync up test harnesses
Tim Kientzle [Fri, 29 Apr 2016 02:44:20 +0000 (19:44 -0700)] 
Issue 695: check fwrite return value, sync up test harnesses

9 years agoIssue 693: assert() wants a boolean, not a pointer
Tim Kientzle [Thu, 28 Apr 2016 06:27:43 +0000 (23:27 -0700)] 
Issue 693: assert() wants a boolean, not a pointer

9 years agoIssue 690: Document the possible need for -lacl on some Linux systems
Tim Kientzle [Thu, 28 Apr 2016 06:20:40 +0000 (23:20 -0700)] 
Issue 690: Document the possible need for -lacl on some Linux systems

9 years agoIssue 692: More robust check for lzma_stream_encoder_mt
Tim Kientzle [Thu, 28 Apr 2016 06:15:08 +0000 (23:15 -0700)] 
Issue 692: More robust check for lzma_stream_encoder_mt

9 years agoIssue 692: Fix typo in newc cpio test
Tim Kientzle [Thu, 28 Apr 2016 06:10:02 +0000 (23:10 -0700)] 
Issue 692: Fix typo in newc cpio test

9 years agoIssue 685: Just verify the body of the error message; ignore the program name
Tim Kientzle [Thu, 28 Apr 2016 06:05:19 +0000 (23:05 -0700)] 
Issue 685: Just verify the body of the error message; ignore the program name

9 years agoMerge branch 'master' of github.com:libarchive/libarchive
Tim Kientzle [Thu, 28 Apr 2016 05:48:41 +0000 (22:48 -0700)] 
Merge branch 'master' of github.com:libarchive/libarchive

9 years agoIssue 686: Correctly retry if the buffer needs to be grown
Tim Kientzle [Thu, 28 Apr 2016 05:48:20 +0000 (22:48 -0700)] 
Issue 686: Correctly retry if the buffer needs to be grown

9 years agoDefault to Windows 7 SDK
Tim Kientzle [Mon, 25 Apr 2016 03:41:12 +0000 (20:41 -0700)] 
Default to Windows 7 SDK

Some of our current crypto bindings require the Win7 SDK.
Once we can rework those, this could reasonably be changed
to Win Vista or possibly Win Server 2003.

I'd like to completely remove support for WinXP and earlier.

9 years agoDefine NTDDI_VERSION on Windows, default to Windows Server 2003 instead of WinXP
Tim Kientzle [Mon, 25 Apr 2016 03:39:15 +0000 (20:39 -0700)] 
Define NTDDI_VERSION on Windows, default to Windows Server 2003 instead of WinXP

9 years agoAccomodate different return codes on Windows
Tim Kientzle [Mon, 25 Apr 2016 03:35:45 +0000 (20:35 -0700)] 
Accomodate different return codes on Windows

9 years agoArithmetic with void * pointers is a bad idea
Tim Kientzle [Mon, 25 Apr 2016 01:45:58 +0000 (18:45 -0700)] 
Arithmetic with void * pointers is a bad idea

9 years agoIssue #656: Fix CVE-2016-1541, VU#862384
Tim Kientzle [Mon, 25 Apr 2016 00:13:45 +0000 (17:13 -0700)] 
Issue #656:  Fix CVE-2016-1541, VU#862384

When reading OS X metadata entries in Zip archives that were stored
without compression, libarchive would use the uncompressed entry size
to allocate a buffer but would use the compressed entry size to limit
the amount of data copied into that buffer.  Since the compressed
and uncompressed sizes are provided by data in the archive itself,
an attacker could manipulate these values to write data beyond
the end of the allocated buffer.

This fix provides three new checks to guard against such
manipulation and to make libarchive generally more robust when
handling this type of entry:
 1. If an OS X metadata entry is stored without compression,
    abort the entire archive if the compressed and uncompressed
    data sizes do not match.
 2. When sanity-checking the size of an OS X metadata entry,
    abort this entry if either the compressed or uncompressed
    size is larger than 4MB.
 3. When copying data into the allocated buffer, check the copy
    size against both the compressed entry size and uncompressed
    entry size.

9 years agoEnsure that cryptor, hmac, and xxhash always define at least one symbol. This preven...
Tim Kientzle [Sun, 24 Apr 2016 22:16:10 +0000 (15:16 -0700)] 
Ensure that cryptor, hmac, and xxhash always define at least one symbol.  This prevents headaches with compilers and linkers that choke on empty object files.

9 years agoDefine INT32_MAX and INT32_MIN for older compilers
Tim Kientzle [Sun, 24 Apr 2016 21:46:36 +0000 (14:46 -0700)] 
Define INT32_MAX and INT32_MIN for older compilers

9 years agoUpdates
Tim Kientzle [Sun, 24 Apr 2016 21:45:00 +0000 (14:45 -0700)] 
Updates

9 years agoMove variable declarations to beginning of block for non-C99 compilers
Tim Kientzle [Sun, 24 Apr 2016 18:59:46 +0000 (11:59 -0700)] 
Move variable declarations to beginning of block for non-C99 compilers

9 years agoMerge pull request #683 from flandr/fix-invalid-loop
Tim Kientzle [Thu, 14 Apr 2016 06:10:10 +0000 (23:10 -0700)] 
Merge pull request #683 from flandr/fix-invalid-loop

Fix C99 build error

9 years agoMerge pull request #684 from flandr/test-workaround
Tim Kientzle [Thu, 14 Apr 2016 06:09:14 +0000 (23:09 -0700)] 
Merge pull request #684 from flandr/test-workaround

Remove now-unnecessary test workaround

9 years agoRemove now-unnecessary test workaround 684/head
Nate Rosenblum [Wed, 13 Apr 2016 23:29:05 +0000 (16:29 -0700)] 
Remove now-unnecessary test workaround

9 years agoFix C90 build errors 683/head
Nate Rosenblum [Wed, 13 Apr 2016 23:14:02 +0000 (16:14 -0700)] 
Fix C90 build errors

9 years agoMerge pull request #681 from prehistoric-penguin/master
Tim Kientzle [Mon, 11 Apr 2016 13:24:13 +0000 (06:24 -0700)] 
Merge pull request #681 from prehistoric-penguin/master

fix missing archive_write_close for write object

9 years agofix missing archive_write_close for write object 681/head
prehistoric-penguin [Mon, 11 Apr 2016 09:29:05 +0000 (17:29 +0800)] 
fix missing archive_write_close for write object

fix missing archive_write_close and archive_write_free

9 years agoManpage updates
Tim Kientzle [Mon, 11 Apr 2016 01:32:13 +0000 (18:32 -0700)] 
Manpage updates

9 years agoUpdate list of supported filters
Tim Kientzle [Sun, 10 Apr 2016 20:28:15 +0000 (13:28 -0700)] 
Update list of supported filters

9 years agoTag libarchive 3.1.901a v3.1.901a
Tim Kientzle [Sun, 10 Apr 2016 18:33:06 +0000 (11:33 -0700)] 
Tag libarchive 3.1.901a

9 years agoBe more accurate about finding tests
Tim Kientzle [Sun, 10 Apr 2016 18:32:43 +0000 (11:32 -0700)] 
Be more accurate about finding tests

9 years agoDisable some troublesome LZ4 tests.
Tim Kientzle [Sun, 10 Apr 2016 04:56:22 +0000 (21:56 -0700)] 
Disable some troublesome LZ4 tests.

9 years agoIssue #655: Be more careful verifying sparse file reading
Tim Kientzle [Sun, 10 Apr 2016 01:10:37 +0000 (18:10 -0700)] 
Issue #655:  Be more careful verifying sparse file reading

The old logic took a number of shortcuts; this now does a careful
comparison of the template used to generate the file with
the contents read back, verifying that the read blocks reflect
the expected pattern of zero and non-zero bytes and that the
expected number of holes actually appear.

9 years agoMerge pull request #679 from ericvw/cmake_aix
Tim Kientzle [Tue, 5 Apr 2016 03:40:38 +0000 (20:40 -0700)] 
Merge pull request #679 from ericvw/cmake_aix

Support CMake build on AIX

9 years agoSupport CMake build on AIX 679/head
Eric N. Vander Weele [Tue, 5 Apr 2016 00:20:59 +0000 (20:20 -0400)] 
Support CMake build on AIX

This change introduces support for building on AIX via CMake.  `gcc`
warning options are mapped to equivalent options in the `xlc` suite
where possible.  The compiler is overridden to be `xlc_r` instead of
`cc` for thread-safe compilation and linking.

Signed-off-by: Eric N. Vander Weele <ericvw@gmail.com>
9 years agoUpdate test to use more modern assertions
Tim Kientzle [Mon, 4 Apr 2016 02:03:14 +0000 (19:03 -0700)] 
Update test to use more modern assertions

9 years agoIssue 550: Fix out-of-bounds read in mtree.
Tim Kientzle [Sun, 3 Apr 2016 18:03:22 +0000 (11:03 -0700)] 
Issue 550:  Fix out-of-bounds read in mtree.

The mtree parser scanned from the end of the string to identify
the filename when the filename is the last element of the line.
If the filename was the entire line, the logic would scan back
to before the start of the string.

The revised logic scans from the beginning of the string
and remembers the last separator position to locate the
trailing filename.

9 years agoFix recognition of dirs when only MSDOS file attributes are available.
Tim Kientzle [Sun, 3 Apr 2016 04:10:42 +0000 (21:10 -0700)] 
Fix recognition of dirs when only MSDOS file attributes are available.

9 years agoCheck for memory allocation errors in archive_entry_xattr_add_entry 603/head
Graham Percival [Wed, 23 Mar 2016 17:20:23 +0000 (10:20 -0700)] 
Check for memory allocation errors in archive_entry_xattr_add_entry

Sponsored by: Tarsnap Backup Inc.

9 years agoIssue 675: SIGRTMAX can be non-constant, so allocate the signal tracking array at...
Tim Kientzle [Wed, 23 Mar 2016 03:28:42 +0000 (20:28 -0700)] 
Issue 675: SIGRTMAX can be non-constant, so allocate the signal tracking array at runtime

9 years agoMerge branch 'master' of github.com:libarchive/libarchive
Tim Kientzle [Wed, 23 Mar 2016 02:29:26 +0000 (19:29 -0700)] 
Merge branch 'master' of github.com:libarchive/libarchive

9 years agoMerge pull request #617 from chenxiaolong/ifdef-statvfs-usage
Tim Kientzle [Tue, 22 Mar 2016 03:33:21 +0000 (20:33 -0700)] 
Merge pull request #617 from chenxiaolong/ifdef-statvfs-usage

Avoid statvfs/fstatvfs calls on systems where it is not available

9 years agoMerge pull request #663 from vapier/master
Tim Kientzle [Tue, 22 Mar 2016 03:27:16 +0000 (20:27 -0700)] 
Merge pull request #663 from vapier/master

add missing _PC_NAME_MAX checks

9 years agoMerge pull request #672 from ericvw/nsig_sigrtmax
Tim Kientzle [Tue, 22 Mar 2016 03:24:43 +0000 (20:24 -0700)] 
Merge pull request #672 from ericvw/nsig_sigrtmax

Replace usage of _NSIG with SIGRTMAX

9 years agoMerge pull request #655 from flandr/fully-sparse
Tim Kientzle [Tue, 22 Mar 2016 03:23:37 +0000 (20:23 -0700)] 
Merge pull request #655 from flandr/fully-sparse

Support efficient creation of fully-sparse files

9 years agoReplace usage of _NSIG with SIGRTMAX 672/head
Eric N. Vander Weele [Fri, 18 Mar 2016 21:31:12 +0000 (14:31 -0700)] 
Replace usage of _NSIG with SIGRTMAX

POSIX specification defines SIGRTMAX.  _NSIG is not defined on all
platforms (e.g, AIX).

Signed-off-by: Eric N. Vander Weele <ericvw@gmail.com>
9 years agoUpdate MSDOS file attribute test
Tim Kientzle [Mon, 14 Mar 2016 03:10:24 +0000 (20:10 -0700)] 
Update MSDOS file attribute test

9 years agoIssue 422: Add archive_xxx_version() calls so tests can more accurately query libarc...
Tim Kientzle [Sun, 13 Mar 2016 01:38:21 +0000 (17:38 -0800)] 
Issue 422:  Add archive_xxx_version() calls so tests can more accurately query libarchive support

Rework some of the Zip, Cab, and LZ4 tests to use these
to determine what behavior they should expect.

9 years agoMerge pull request #668 from dosomder/android-compile
Tim Kientzle [Sat, 12 Mar 2016 21:09:44 +0000 (13:09 -0800)] 
Merge pull request #668 from dosomder/android-compile

Add api level check for android config

9 years agoAdd api level check for android config 668/head
dosomder [Sat, 12 Mar 2016 10:34:01 +0000 (11:34 +0100)] 
Add api level check for android config

Some features are only included since api level 21

9 years agoMerge pull request #666 from dosomder/android-compile
Tim Kientzle [Sat, 12 Mar 2016 05:26:18 +0000 (21:26 -0800)] 
Merge pull request #666 from dosomder/android-compile

Fix compiling for android

9 years agoAdd ST_MTIME_NSEC case to archive_entry_copy_stat 666/head 667/head
dosomder [Fri, 11 Mar 2016 19:06:17 +0000 (20:06 +0100)] 
Add ST_MTIME_NSEC case to archive_entry_copy_stat

Android uses st_mtime_nsec

9 years agoFix android intmax compiler warnings
dosomder [Fri, 11 Mar 2016 19:02:37 +0000 (20:02 +0100)] 
Fix android intmax compiler warnings

9 years agoadd missing _PC_NAME_MAX checks 663/head
Mike Frysinger [Sun, 28 Feb 2016 18:10:16 +0000 (13:10 -0500)] 
add missing _PC_NAME_MAX checks

This file looks for _PC_NAME_MAX in a few places, but not all.
Add some ifdefs in setup_current_filesystem too.

9 years agoMerge pull request #645 from andrewgregory/check_symlinks
Tim Kientzle [Fri, 26 Feb 2016 03:01:33 +0000 (19:01 -0800)] 
Merge pull request #645 from andrewgregory/check_symlinks

fix check_symlinks

9 years agoAdd more sample zip files to the fuzz test
Tim Kientzle [Wed, 24 Feb 2016 04:36:37 +0000 (20:36 -0800)] 
Add more sample zip files to the fuzz test

9 years agoadd test for SECURE_SYMLINKS with absolute path 645/head
Andrew Gregory [Tue, 23 Feb 2016 02:17:20 +0000 (21:17 -0500)] 
add test for SECURE_SYMLINKS with absolute path

9 years agoSkip root directory symlink check
Andrew Gregory [Fri, 15 Jan 2016 07:39:41 +0000 (02:39 -0500)] 
Skip root directory symlink check

The first time check_symlinks is called on an absolute path it will use
the entry pathname directly, blanking the leading slash.  This leads to
calling lstat on an empty string, which returns ENOENT, terminating the
loop early and falsely marking the path as safe.

9 years agoadd test for SECURE_SYMLINKS for first child
Andrew Gregory [Tue, 23 Feb 2016 02:18:02 +0000 (21:18 -0500)] 
add test for SECURE_SYMLINKS for first child

9 years agoRestore modified path after lstat
Andrew Gregory [Fri, 15 Jan 2016 07:40:00 +0000 (02:40 -0500)] 
Restore modified path after lstat

check_symlinks is intended to check each component of a path, but failed
to restore the stripped trailing components after each iteration,
leaving a NUL byte in the middle of the path.

9 years agoFix for issue #623.
Tim Kientzle [Sun, 21 Feb 2016 20:34:57 +0000 (12:34 -0800)] 
Fix for issue #623.

Apparently, people have come to expect that the following
is sufficient to get bit-for-bit identical output from tar:
   * Same filenames
   * Same contents
   * Same uid, gid
   * Same mtime (forced via "touch -t <timestamp>")
   * Sorting entries

Bsdtar's "restricted pax" format violated this by including
ctime, atime, and birthtime (which are not updated by
'touch -t).  So we should only emit those additional time
values in the full pax format.

People who are really serious about generating bit-for-bit
identical archives should really build their own command-line
interface: You can still use libarchive to build the output,
but your custom CLI could sort the entries and strip everything
except a bare minimum of basic metadata.

9 years agoClarify the limit on number of filters
Tim Kientzle [Sun, 21 Feb 2016 19:43:03 +0000 (11:43 -0800)] 
Clarify the limit on number of filters

9 years agoFix globbing error v3.1.900a
Tim Kientzle [Sun, 21 Feb 2016 16:51:18 +0000 (08:51 -0800)] 
Fix globbing error

9 years agoSupport fully-sparse files 655/head
Nate Rosenblum [Sat, 6 Feb 2016 01:39:03 +0000 (17:39 -0800)] 
Support fully-sparse files

Avoids an edge condition where fully-sparse files would not trigger
sparse file handling, leading to large tar files full of zeros.

9 years agoFix -c test: we forced uid/gid to 1000, so we should not compare against the current...
Tim Kientzle [Sun, 14 Feb 2016 06:13:22 +0000 (22:13 -0800)] 
Fix -c test:  we forced uid/gid to 1000, so we should not compare against the current user

9 years agoFix stringification here
Tim Kientzle [Sun, 14 Feb 2016 06:06:09 +0000 (22:06 -0800)] 
Fix stringification here

9 years agoMerge branch 'master' of github.com:libarchive/libarchive
Tim Kientzle [Sat, 19 Mar 2016 18:34:03 +0000 (11:34 -0700)] 
Merge branch 'master' of github.com:libarchive/libarchive

9 years agoIssue #377: Help cpio tests pass on systems with large UIDs
Tim Kientzle [Sat, 19 Mar 2016 18:29:37 +0000 (11:29 -0700)] 
Issue #377: Help cpio tests pass on systems with large UIDs

9 years agoMerge pull request #630 from bjacke/vv-verbose-write
Tim Kientzle [Sat, 19 Mar 2016 18:19:11 +0000 (11:19 -0700)] 
Merge pull request #630 from bjacke/vv-verbose-write

Vv verbose mode for write write