diff options
author | mm <mm@FreeBSD.org> | 2016-05-12 22:51:04 +0000 |
---|---|---|
committer | mm <mm@FreeBSD.org> | 2016-05-12 22:51:04 +0000 |
commit | b47968a7ae5786e5cfa818ec9e8daab9829ffeb5 (patch) | |
tree | 0bc27f1a8f28d44096e91b34a283dcc2bd9188ec /contrib/libarchive | |
parent | aa261389ce59719566d0ad3e7b3aa7665ac6aa6a (diff) | |
download | FreeBSD-src-b47968a7ae5786e5cfa818ec9e8daab9829ffeb5.zip FreeBSD-src-b47968a7ae5786e5cfa818ec9e8daab9829ffeb5.tar.gz |
Fix broken cpio behavior.
Suggested upstream as PR #704.
MFC: 1 month (together with libarchive 3.2.0)
Diffstat (limited to 'contrib/libarchive')
-rw-r--r-- | contrib/libarchive/cpio/bsdcpio.1 | 3 | ||||
-rw-r--r-- | contrib/libarchive/cpio/cpio.c | 2 |
2 files changed, 1 insertions, 4 deletions
diff --git a/contrib/libarchive/cpio/bsdcpio.1 b/contrib/libarchive/cpio/bsdcpio.1 index e52546e..f966aa0 100644 --- a/contrib/libarchive/cpio/bsdcpio.1 +++ b/contrib/libarchive/cpio/bsdcpio.1 @@ -156,8 +156,7 @@ See above for description. .It Fl Fl insecure (i and p mode only) Disable security checks during extraction or copying. -This allows extraction via symbolic links, absolute paths, -and path names containing +This allows extraction via symbolic links and path names containing .Sq .. in the name. .It Fl J , Fl Fl xz diff --git a/contrib/libarchive/cpio/cpio.c b/contrib/libarchive/cpio/cpio.c index f6441aa..413fc87 100644 --- a/contrib/libarchive/cpio/cpio.c +++ b/contrib/libarchive/cpio/cpio.c @@ -171,7 +171,6 @@ main(int argc, char *argv[]) cpio->extract_flags |= ARCHIVE_EXTRACT_NO_OVERWRITE_NEWER; cpio->extract_flags |= ARCHIVE_EXTRACT_SECURE_SYMLINKS; cpio->extract_flags |= ARCHIVE_EXTRACT_SECURE_NODOTDOT; - cpio->extract_flags |= ARCHIVE_EXTRACT_SECURE_NOABSOLUTEPATHS; cpio->extract_flags |= ARCHIVE_EXTRACT_PERM; cpio->extract_flags |= ARCHIVE_EXTRACT_FFLAGS; cpio->extract_flags |= ARCHIVE_EXTRACT_ACL; @@ -257,7 +256,6 @@ main(int argc, char *argv[]) case OPTION_INSECURE: cpio->extract_flags &= ~ARCHIVE_EXTRACT_SECURE_SYMLINKS; cpio->extract_flags &= ~ARCHIVE_EXTRACT_SECURE_NODOTDOT; - cpio->extract_flags &= ~ARCHIVE_EXTRACT_SECURE_NOABSOLUTEPATHS; break; case 'L': /* GNU cpio */ cpio->option_follow_links = 1; |