Update vendor/libarchvie to git commit 860ec63
Integrates my pull request #709
This commit is contained in:
parent
cf8cc1c884
commit
8eb6639196
@ -295,6 +295,7 @@ main(int argc, char *argv[])
|
|||||||
"Cannot use both -p and -%c", cpio->mode);
|
"Cannot use both -p and -%c", cpio->mode);
|
||||||
cpio->mode = opt;
|
cpio->mode = opt;
|
||||||
cpio->extract_flags &= ~ARCHIVE_EXTRACT_SECURE_NODOTDOT;
|
cpio->extract_flags &= ~ARCHIVE_EXTRACT_SECURE_NODOTDOT;
|
||||||
|
cpio->extract_flags &= ~ARCHIVE_EXTRACT_SECURE_NOABSOLUTEPATHS;
|
||||||
break;
|
break;
|
||||||
case OPTION_PASSPHRASE:
|
case OPTION_PASSPHRASE:
|
||||||
cpio->passphrase = cpio->argument;
|
cpio->passphrase = cpio->argument;
|
||||||
|
@ -401,6 +401,11 @@ archive_read_format_cpio_read_header(struct archive_read *a,
|
|||||||
|
|
||||||
/* If this is a symlink, read the link contents. */
|
/* If this is a symlink, read the link contents. */
|
||||||
if (archive_entry_filetype(entry) == AE_IFLNK) {
|
if (archive_entry_filetype(entry) == AE_IFLNK) {
|
||||||
|
if (cpio->entry_bytes_remaining > 1024 * 1024) {
|
||||||
|
archive_set_error(&a->archive, ENOMEM,
|
||||||
|
"Rejecting malformed cpio archive: symlink contents exceed 1 megabyte");
|
||||||
|
return (ARCHIVE_FATAL);
|
||||||
|
}
|
||||||
h = __archive_read_ahead(a,
|
h = __archive_read_ahead(a,
|
||||||
(size_t)cpio->entry_bytes_remaining, NULL);
|
(size_t)cpio->entry_bytes_remaining, NULL);
|
||||||
if (h == NULL)
|
if (h == NULL)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user