[Bug 611] New: ar command fails with "invalid ar header" with archive containing long file names

bugzilla at busybox.net bugzilla at busybox.net
Thu Sep 17 13:42:19 UTC 2009


https://bugs.busybox.net/show_bug.cgi?id=611

           Summary: ar command fails with "invalid ar header" with archive
                    containing long file names
           Product: Busybox
           Version: 1.13.x
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: major
          Priority: P5
         Component: Other
        AssignedTo: unassigned at busybox.net
        ReportedBy: temasp at rit.edu
                CC: busybox-cvs at busybox.net
   Estimated Hours: 0.0


Easy steps to reproduce:

create 2 files with short names (e.g. a.txt and b.txt)
create an archive containing these files: ar -q short.ar a.txt b.txt
busybox ar correctly interprets this file: ar -t short.ar

create 2 files with long names (e.g. thisisalongfilename.txt
thisisanotherlongfilename.txt)
create an archive containing these files: ar -q long.ar thisisalongfilename.txt
thisisanotherlongfilename.txt
busybox ar command fails with "invalid ar header": ar -t long.ar

See source file archival/libunarchive/get_header_ar.c. Function get_header_ar()
attempts to read mode, date, uid, gid and size from the file file header; this
works for "short" headers but fails for "long" headers. Function
get_header_ar() does check for long file headers, but this check is not
performed until after attempting to read the file header.

I created the archive files using Ubuntu 8.04.
I'm using BusyBox v1.13.1 (2009-09-16 11:20:36 EDT) multi-call binary (with
CONFIG_FEATURE_AR_LONG_FILENAMES=y) but a check of the 1.15.1 source code shows
this bug still exists.


-- 
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


More information about the busybox-cvs mailing list